Stacking simpleFOC mini board on Arduino Uno

Hi,
I´m a mechanical engineer writing my thesis so not much (to not at all) experience on electronics, so please excuse possible stupid questions :smiley:
Is it possible to use multiple SimpleFOC mini boards in combination with an Arduino UNO (2 shields) or even DUO (4 shields)? I know that you can stack two “normal” boards on one UNO but I didn´t find info to the mini shield.

Hey, @Kai , and welcome to SimpleFOC!

You would have to connect them with wires, but it should be possible to connect two to an UNO. You can try it and see how it goes.

Running two motors well is really a different question… for this the original UNO is not fast enough. To run two motors you should choose a faster MCU like a ESP32 or fast STM32.

Running 3 motors becomes quite challenging, both from a software speed point of view but also from the interfacing with the MCU pins and peripherals. Certainly many ready made development boards like Arduinos or Feathers don’t offer enough pins for 3 motors and 3 sensors.

1 Like

The mini is not a shield. Shields typically are the same size as uno with their pins are all lined up.

The mini is about about 20% the area of an uno, so you can’t stack it.

Perhaps you can describe what you are working on and we can give you advice.

1 Like

Thanks a lot for your answers!
I have to do a workaround with the mini board since the big ones are troublesome in shipping from china…

Plan is to run two gimbals with AS5048a encoders by one Arduino UNO and two stacked FOC shields (big ones). Only one motor is driven at a time. The gimbals are used as filament feeders and will be used in torque control mode. This system is mirrored so there will be 4 Gimbals in total.
Minimum for my thesis is to get one out of two gimbals running to prove the concept. As it is a constructive thesis, I only have to get the motor running forwards and backwards. More functions will be implemented later from my coworkers.
So since the shields got lost once from the delivery and the mini board is available in the SimpleFOC shop, I try my luck with at least a mini board until another shipment is coming from china in two weeks.

1 Like

Take note that on the “shield” board, there are some pullups provided for I2C encoders (maybe 5k) that are not present if you just wire the sensor direct to the UNO. You need to add these to the bus will not work!

1 Like

I have the possibility to use SPI or PWM signal from the encoder. My plan was to use the PWM signal, which should be suitable to be connected directly to a digital PWM IN?

If you have the option for SPI you should use that.
PWM is the slowest and least accurate method for reading the sensor.

1 Like