Encoder, pully gear ratio and commutation

Hi all,

We are building a custom drive unit consisting of a VESC based PCB → a motor driven in FOC mode → a 16 tooth pulley on the motor axle → a 60 tooth pulley on outgoing pulley wheel → a magnetic high resolution AS40xx encoder on the outgoing pulley (we need this angle to be determined accurately. There are no hall sensors or an encoder in the motor. The motor turns sometime (after calibration), but I have the feeling that due to the ratio (16/60) the commutation goes wrong after a few revolutions. Could this be indeed the issue? Anything I can do to fix this?

You could use a motor with hall sensors or encoders. Or use HFI/sHFI sensorless startup.

I don’t really understand your scenario. Why would you want an encoder on the pulley wheel?

Yes I know. The motor has actually encoders, but we need (very) accurate control of the angle of the pulley wheel. Hence the 14 bit encoder. HFI is not working good enough (not enough resolution between the pole pairs).

A theoretical option would be to use the Hall sensors for commutation and the encoder for angle control. But there is no option to hook it up like that in the VESC firmware/software (as far as I know).

Are you using default HFI settings, or have you tuned them? Jeff Friesen has a very good video for tuning HFI on youtube.

on 6.02 fw, Vedder states that with correct tuning the “Silent HFI” options actually have more accurate position resolution than hall sensors.

Everyone bitches about HFI because it is quite difficult to tune (and frequently works like shit if you don’t tune it), but if you are able to figure out tuning it, it could be a good option for you.

Sounds like you are building a robot or something other than esk8?

Yes indeed! But you could use it as a fancy esk8 :wink:

Silent HFI is in my setup not different than regular (the components/filters are missing), hence the same high pitch noise is audible.

We have tried many tuning options (we are on 6.05 dev), but will try some more based on the vid link. Tnx!

Also ordered a new pulley wheel to make the ratio an integer (4 instead of 3.75).

1 Like

unless you use a vesc hardware design that has phase shunts, you will still have a high pitched noise.

Although, the whine is quieter on silent HFI.

Also, it’s not totally obvious from the way VESC software is setup, but the HFI setup parameters are also critical to silent HFI. You really need to tune both HFI and silent HFI if you want them to work as well as possible.

here is the video that I was referring to. Good luck and let me know how it works for you.

VESC Sensorless HFI Tutorial(FW 4.0) - YouTube

1 Like

Tnx Evan,

I gave it a try yesterday, but unfortunately I cannot get the Realtime Data → Experiment plot to work when I activate:

foc_plot_hfi_en 1

I only get 1 sample instead of a stream. Using Sampled Data does not give me the data that will be shown in Experiment, so that does not help. I will do some digging to find the root cause of that and then tune HFI (silent).

1 Like