Go Down

Topic: Floating point math with Ardunio DUE (Read 239 times) previous topic - next topic

Dayantha_L

Sep 17, 2015, 10:08 pm Last Edit: Sep 17, 2015, 10:09 pm by Dayantha_L
Hi,

I'm doing a 3-phase AC induction motor control project , and my motor control algorithm has to deal with lot of floating point math (angle calculations etc).

Can anyone tell me how much better the Ardunio DUE can deal with large amount of Floating Point calculations ? (I mean with compared to embedded board with a math coprocessor)

And if I have to choose between Ardunio DUE and STM32F4 Discovery what would be the better option?

Dande80

The DUE has to do floating point math in software as the cortex M3 doesn't support a floating point unit. The STM32F4 uses a Cortex M4F processor (the F stands for the floating point unit). Therefore it will be much faster. The most important question is how fast you need to be. You can google floating point benchmark results for the arduino due. If you know what you need you can check the availbale performance against your requirements.

ArthurD

#2
Sep 19, 2015, 07:29 pm Last Edit: Sep 19, 2015, 07:33 pm by ArthurD
here is a benchmark test about some Arduino (-compatible) boards:

Code: [Select]

HaWe brickbench © test (time: ms)     Arduino         Arduino         Arduino    PJRC Teensy   
Typ, OS, FW, PL, API                  Mega2560          Due             Zero         3.1
MCU, cpu-Takt                        AVR/16MHz      ARM M3/84Mhz    ARM M0/48MHz ARM M4/72MHz
Firmware / vers.                     IDE 1.6x        IDE 1.6x          IDE 1.6x    IDE 1.6x
LCD / TFT                           ILI9225 UTFT    ILI9341_due   (Adafr.ILI9340) ILI9327 NC
===========================================================================================
 0 100000 integer add/subtr                129            8              15           5   
 1 52000 integer multiply/division        1219            7             102           5
 2 5000 float operations                   326          107             397          92   
 3 Mersenne Tw. PRNG (&,^,>>,<<)           313            7              36           4   
-------------------------------------------------------------------------------------------
 4 matrix algebra (prod/determ.)           244           23              92          19   
 5 int array sort [500]                   1366          171             379         110   
-------------------------------------------------------------------------------------------
 6 display text                          80618          973           (9110)       1667                                         
 7 display graphics                     224505         3255          (40675)       3194                 
===========================================================================================                               
execution time                          308720         4551           50806        5096
===========================================================================================


Code reference ported to Arduino
http://www.mindstormsforum.de/viewtopic.php?f=71&t=8095&start=15#p65463

whole benchmark table:
http://www.mindstormsforum.de/viewtopic.php?f=71&t=8095#p64772

Go Up
 


Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

Arduino
via Egeo 16
Torino, 10131
Italy