ranenbg / Arduino-FFB-wheel

Stand alone directInput USB device recognized in Windows as a joystick with force feedback functionality, based on BRWheel by Fernando Igor from 2017.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Encoder Resolution

etempm opened this issue · comments

Hi, what is your suggested resolution in ppr? I have 400 and 600 ppr with z index. Also I have as5047p magnetic higher resolution. Is bigger is better, or there is a limit for arduino?

I am making some modifications to work with dd wheel foc controlled. If I succeed, I can share it.

Thanks again.

Hi dude, in principle the bigger the encoder PPR the better, but there is a limit in arduino, regarding how fast it can detect pulses at interrupt pins. This limit is at about 100kHz and very much depends on the max desired encoder rpm and PPR. Magnetic hall can be good if 14bit, 12bit is too low, but you have to implement it in the code yourself. There is not enough mcu power to run the FOC loop along side everything I have so far. Even stm32f407 would struggle, so best is to use abother mcu for FOC, stm32 prefferably, but then you run into another issue. You would have to implement some sort of digital communication between two mcu, this is usually CAN bus, arduino does not support it natively. My recommendation is to have a look at openffb firmware, it's open source and already has everything you need, they have a separate board for motor driver running with tmc motor driver chip.

Foc is working on stm32, simplefoc. It takes inputs from arduino(your ffb).
For optical omron like encoders, so 400 - 600 ppr is not good enought, right?

It is good enough. If you don't mind losing the z channel, you can allways mount encoder via a pulley to motor shaft and increase PPR, you don't need more than 5k, 6k PPR.