[Lazarus] Using Lazarus on Embedded Linux?
mschnell at lumino.de
Mon Sep 27 09:42:48 CEST 2010
On 09/25/2010 09:07 AM, Bo Berglund wrote:
> 1) Can I work in Windows or Ubuntu on the same project?
Yes. You can do the same source code for both targets, but you need to
be aware of certain differences regarding some system calls and things
like thread synchronizing. You can even cross compile (and supposedly
> 2) Can I compile in either environment for a third runtime platform?
> I am especially looking for a GUI programming environment where the target system
> is Embedded Linux on ARM or Atom platform boards.
You can cross compile for ARM and, AFAIK, you can compile FPC and
Lazarus to run on ARM/Linux.
But what ARM system is the target ? I suppose it's hard to make a
Lazarus program that needs the LCL run on a non-MMU ARM. If you don't
install X and KDE or GNOME on your embedded system you need to use a LCL
"Widget type" that has no GUI binding and same are as well restricted as
not in the same level of perfection as the GUI based Widget Types.
> 3) I need to access the serial communications channel from my programs, so what is
> the support available for RS232 communications in Lazarus/FPC?
You just open the COM device :). In fact it makes a lot of sense to do
this in a thread (such as Async Pro does). But Async Pro is not yet
ported to Lazarus and handling threads is not really portable,
especially with non-GUI widget sets that (at the moment) don't have
built-in portable Message handling for thread synchronizing.
> The target is an embedded board that is intended to communicate with a data acquisition
> system via RS232 (38400 baud, binary proprietary protocol).
I'm doing a similar research since long :) In fact the market for
"embedded ARM/Linux boards" is moving to MMU-based ARMs and lots of
memory, so that installing X is not a problem any more ant thus you can
use the KDE or Gnome widget set and with that doing software with
Lazarus is _very_ viable.
> 4) The programs planned will also need to produce graphic rendering of the data
> retrieved from the acquisition system, so what is the graphic capabilities of
> Lazarus/FPC on the Linux platform?
If the ARM has X, same as in Windows. The user program sees the LCL API,
which is very similar to the Delphi VCL API <just beware of Unicode!> ).
Regarding Graphics this of course is not a very high level. But (like
with Delphi you can use things like SDL and other graphics libraries
that have portable backands). What specifics do you need ?
> 5) Can data be stored on memory cards/hard disk on an embedded system?
With Linux you should store data in files ! There are several flash file
systems you can install.
More information about the Lazarus