0
$\begingroup$

I am going to build an autonomous robot with Kalman-filter for localization integrated from Lidar, encoder, IMU and GPS. I will also add obstacle avoidance while moving to the required position.

Is the ATmega32 8-bit suitable for that (or Arduino Mega) or do I have to use avr32, ARM, or PIC32 and which is better?

$\endgroup$
  • $\begingroup$ What size should it be? Should it walk, drive or fly? Or all of them? $\endgroup$ – ott-- Apr 21 '16 at 16:46
  • $\begingroup$ about 2-3 meters wide and 4-6 meters long and it's a ground vehicle. $\endgroup$ – I.Omar Apr 22 '16 at 8:52
  • $\begingroup$ I was thinking of Arduino DUE. $\endgroup$ – I.Omar Apr 22 '16 at 8:54
1
$\begingroup$

One could break down your problem to three areas: memory, speed and I/O.

Memory is pretty straightforward, but you have to estimate it yourself. Things to consider: Are you doing a map? Are you saving past state? If yes how long/much? etc.

Speed is a bit different: Assume you are building a quadcopter: If you have high latency in the controller's feedback loops the thing will not even fly. If you have a ground vehicle on the other hand you could simply drive slower.

Consider how you want to structure the program's control flow: Do you poll for new data all the time or do it interrupt-driven? How fast should your control loop run and what do you need to calculate during it? How many floating point operations do you need? How large is your map for obstacle avoidance?

Lastly what peripherals, sensors, debugging tools etc. do you want to connect and does the uC have enough connections to allow that?

If this is going to be a rather serious project, I would shy away from arduino, because if you need to have more control over the program and write low-level code things are likely to get messy. The learning curve to develop with Atmel Controllers directly is not that high.

With the meager information you provided I feel like the ATmega32 will be suitable, but if you need a fast control loop consider ARM with a floating point unit.

$\endgroup$
  • $\begingroup$ I do really wonder why you are saying that about Arduino. As I know Ardiuno uses gcc compiler, so any lower level (assembly inline etc) can be used or I misunderstand something!! $\endgroup$ – I.Omar Apr 22 '16 at 19:15
  • $\begingroup$ Let's say you have used the standard servo library. If I recall correctly this is done via flipping a digital I/O all the time, which is about the least elegant way. If you build your system on top of such things you later have to refactor all the things if you want to do it properly. But this is much personal opinion of course, I had tried to indicate that. $\endgroup$ – caconyrn Apr 22 '16 at 21:09
  • $\begingroup$ I do agree on that(It was challenging for me and using counter inside timer interrupt solved that). I got an Arduino due :( ,so I may be try Mat lab with it. $\endgroup$ – I.Omar Apr 22 '16 at 21:42
  • $\begingroup$ So would be better if I used tm4c132 for that? $\endgroup$ – I.Omar Apr 25 '16 at 2:46
  • $\begingroup$ I cannot really say that because your exact requirements are not know to me. Just read the datasheet and check if all the peripherals you need are there (SPI, ADC, UART, ... ) The processing power is certainly high enough even for demanding applications. $\endgroup$ – caconyrn Apr 25 '16 at 19:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.