Re: [Hampshire] C development

Top Page

Reply to this message
Author: James Courtier-Dutton
Date:  
To: Hampshire LUG Discussion List
Subject: Re: [Hampshire] C development
On 12 June 2014 18:56, Roger Munford <rogermunford@???> wrote:
> 100 years ago I wrote a data logging programme for DOS which ran on a Sharp
> pocket PC. It was written in C and assembler. I now have a need for this
> programme and would like to revive it for use with the Raspberry Pi.
>
> I haven't done anything like this for some time and would like some advice
> on current techniques to get the job done as soon as possible.
>
> The first thing is a suitable IDE. I have had some experience with Eclipse
> but it may be a bit heavyweight for quick results. However if extra effort
> pays off in the end it might be worth it.
>
> I will also need a lightweight graphics library. The original plotted data
> on the display which was done with functions like drawline(x1,y1,x2,y2) and
> writechar(x,y,char) etc. That sort of level. Having said that, the Pi has a
> lot more capability and I could use an existing display package.
>
> The data came from various sources, some serial and some small devices which
> were connected to the parallel port. The smallest timing period was 1 second
> and I used the timer interrupt to initiate the read commands because there
> was a lot of processing going on, updating the display and also the logger
> had a modem attached so that data could be collected remotely. Is this the
> way to go with linux or is there a better/easier technique.
>
> Originally I just recorded the data sequentially in a file but I was
> wondering if there was any advantage in using something like sqllite.
>
> I would be grateful to hear for any advice.
>


Hi,

A quick solution would be to use DOSBOX.
It can be run on the raspberry pi and runs old DOS x86 programs
directly. It has good support for serial ports, not used the parallel
support, but it should be ok.

Then, if you wish to re-implement your program natively, then some
things I would do:
1) You won't need assembler any more.
2) Separate out data collection and data visualization into two
separate programs. Maybe use a database in between, or it the data
rates are too high, use CSV files.
3) There are many data visualization programs already out there, you
might not have to do any work in this area.

Kind Regards

James

--
Please post to: Hampshire@???
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--------------------------------------------------------------