4 ms·
Could this be adapted to run on arduino? Or does it require too many libs?
by thechut 14y ago
Could this be adapted to run on arduino? Or does it require too many libs?
- ballooney 14y agoI suspect it requires too much everything (cpu, ram, io speed), by several orders of magnitude, to run on an arduino. If you're seriously asking, and this isn't some kind of internet meme/joke I'm not familiar with, you might find it interesting and instructive to have a look at the datasheet of the AtMega328[1], the chip an Arduino Uno uses, and compare it to, say, what you might find in a typical intel desktop machine. Just as one crude scalar comparison to illustrate the sort of differences, the atmega328 doesn't have the ability to do floating point operations in hardware , so you have to emulate them in software using the core's fixed point hardware (the toolchain will do this for you). This means potentially hundreds of cpu cycles per floating point operation. In the past i have managed to get an atmega328, at 16Mhz, to perform about 60,000 floating point multiplications per second. According to the wikipedia[2], a 2010 Intel Core i7 cpu can do about 109 billion floating point operations per second. That's nearly 2 millions times the speed! If you want something of arduino size and arduino price, that will let you play with machine vision, the Raspberry Pi might be far more useful to you. Finally, I'm not saying you can't do CV on an 8-bit embedded micro, I have done some in the past myself, but it's a very different and far more limited beast to what most people would understand as modern CV and required in my case an great deal of hand optimisation and gory bit-hacks. [1] http://www.atmel.com/devices/atmega328.aspx http://www.atmel.com/devices/atmega328.aspx [2] http://en.wikipedia.org/wiki/FLOPS http://en.wikipedia.org/wiki/FLOPS [3] http://www.raspberrypi.org/ http://www.raspberrypi.org/
- thechut 14y agoThanks for your response, and no it was not a troll but a serious (albeit naive) question. Thank you for answering my question with good references and very respectfully. I actually do know a fair amount about Arduino and I should have put it together that the 328 wouldn't be anywhere near fast enough. I'm sure it would be pretty easy to run it on a Raspberry Pi and I have been clamoring to get my hands on a RasPi but am still in the preorder queue :/ But Arduino also has the upcoming Arduino Due which is based on a 32bit ARM Cortex M3, which still may be powerful enough. I guess I would revise my question to be would it be possible to get this (or something similar) running in the Arduino Environment, regardless of speed (without a full OS stack)?
- simcop2387 14y agolooking at the specs for it, there might still be an issue of ram, since the ATSAM3X8E has only 100kb of ram. if you limit what you do you can likely get some form of it working but to be honest i'm not sure how limited that would be at the moment. You'd certainly have to lower the resolution to something like 160x120, since even 320x240 would take up 192kb of ram in raw rgb. so limited resolution, possibly even doing it in yuv with 4:2:0 like it's a low quality jpeg would probably be possible, but you would end up having some things more difficult to work with e.g. find the red ball. speed wise at 84-85mhz it ought to be good enough to do the processing at a few frames per second which for lots of things would likely be good enough. all of this is just speculation based off of what i found googling the chip on it, and then the libccv might not even fit on the 512kb flash it has for the program you put on it. my thought would be, bight the bullet and go with a raspberry pi or something like that for doing image processing, faster cpu, more ram, and you could hook it up to something like the arduino due, to do other logic, and have the due ask it questions like, "where is the ball" etc. source: http://www.linkedin.com/groups/Arduino-Due-featuring-Atmel-ATSAM3X8E-1268377.S.118786784?qid=a35402e3-76b7-48df-ac40-3ce85e5e08e9&trk=group_most_popular_guest-0-b-ttl&goback=.gmp_1268377 http://www.linkedin.com/groups/Arduino-Due-featuring-Atmel-A...
- tibbon 14y agoThe Raspberry Pi has my interested, as it does seem to have significantly more power for this type of thing (in a limited sense)
- platz 14y agoOr for a bit more power, check out the APC for $49: http://www.geek.com/articles/chips/via-launch-a-49-android-pc-20120522/ http://www.geek.com/articles/chips/via-launch-a-49-android-p... "The APC’s spec includes a VIA WonderMedia ARM 11 processor at its core, 512MB DDR3 RAM, 2GB of on-board flash storage, 4 USB 2.0 ports, a microSD slot, Ethernet port, and both VGA and HDMI display ports. As for power consumption, it tops out at 13 watts under load and 4 watts when idle."