Re: Lua on Microcontrollers
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: Lua on Microcontrollers
- From: "David Hamill" <david@...>
- Date: 2013年12月12日 11:29:43 -0000
>> Have you considered a port of eLua onto Raspberry Pi and/or Beaglebone
Black? Of course, Lua can easily be installed on these under Linux, but I
mean running "bare metal" without an OS. So it would just be a route to
getting a low-cost target board with plenty of RAM. The "microcontroller +
SDRAM" boards all seem to be very poor value compared to these little
Linux
boards.
The Pi is so cheap because of economies of scale: two million produced so
far, mostly in China.
FWIW I'm currently running a datalogging application on a Raspberry Pi,
using an ADC board. I wrote it in C because that's fast and close to the
hardware, and the appropriate libraries and demo code were available. It
runs under Raspbian Linux (using cron, sudo, and negative nice-ness),
logging the time and a single 12-bit value every 4 milliseconds. This
generates 500 megabytes of log files a day. I siphon the files off to a PC
daily via the network, to avoid the 8GB flash card running out of storage.
BTW, Lua 5.2 seems to run nicely on the Pi. :-)
The main disadvantage of the Pi is that it uses an HDLC monitor, which costs
a lot more than the Pi itself. Personally I think this was a bad design
choice; there must be a lot of old VGA monitors around. Apart from this I'm
very happy with the Pi and would recommend it for anyone who needs a cheap
Linux box.
The Pi's Rasbian Linux distro is quite extensive, but it should be possible
to prune it back to a minimalist Linux kernel plus C compiler etc., to form
a specialised Lua machine.
David