Ordering a batch of RP2040 drivers?

I’m planning to buy a batch of @Taylor_Alexander RP2040 boards:

It looks likely they will be ~£47 each + Onward postage cost from the UK.

Is anyone interested in ordering one at that price?

Also getting some CM4 carriers likely ~£70 each plus onward postage from the UK

If I were looking for a dual motor driver with current sensing, I wouldn’t choose the RP2040 as MCU, unless I’m happy with slow loop times and limited RPM.
I wonder if they managed to use the ROM-based QFPlib floating point, or is this depending on the sFOC implementation?

1 Like

The use case for this is driving a robot, so I don’t think low RPM is a problem.

Firmware is largely stock Sfoc I think

It’s a cool board and I know the person a little bit and they are cool, but just a word of warning, none of this is “stock”, if you are thinking it’s all going to be plug and play you may be disappointed. I’m sure you will have to get in there and go over everything and make sure it does what you need, which will take time.

The code base for SimpleFOC for the RP2040 is less developed and it doesn’t have floating point math, but it’s a very good MCU in general and IMO you can’t go too far wrong using it because you will save work with compatibility and so on in the future. My experience with it has been very good. It was also pretty good with the STM32 chips I tried, though, in terms of the actual MCU, but the code base to access the peripherals etc. is considerably harder for me to puzzle out and actually make use of, wherease you won’t have that problem with the RP2040, they did a good job making it all arduino compatible.

Don’t forget it has two cores, too, which imo could be pretty handy. I was never able to get the second core working in micropython, but people tell me it works good under arduino. So you could get the waveform generation stage all done by one core, which could really help a lot to make things more tractable in terms of timing and stuff.

To give you an idea of the impact of floating point math, an M0 core was 1/3.5 times the loop speed in open loop mode with a simple repeated call to motor.move(), compared to an M4 core, already compensated for the differences in clock speed, I think. The G431 was 7 times faster than the MCU in the lepton 2.0 with that test. The M4 has the hardware for floating point math, M0 does not. I don’t know what other differences but I think that’s the main reason for the difference in loop time.

1 Like