Re: Datatransfer via serial line
From: Dave Clarke (pinggetridofthisbituino_at_operamail.com)
Date: 01/28/05
- Previous message: Anders Christensen: "Datatransfer via serial line"
- In reply to: Anders Christensen: "Datatransfer via serial line"
- Next in thread: Grant Edwards: "Re: Datatransfer via serial line"
- Reply: Grant Edwards: "Re: Datatransfer via serial line"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Fri, 28 Jan 2005 16:25:32 +0000
On Friday 28 January 2005 14:39 Anders Christensen wrote:
> Hi.
>
> I have a C-application running a while-loop that 10 times per second polls
> a serial port for data. The program maintains some lists according to what
> comes in on the serial port.
>
> I want to synchronize the data lists in my application with lists from a
> remote device (via a serial port used only for that purpose). This
> involves these steps:
> 1) receive data from remote device
> 2) update the data lists in my application
> 3) send the updated lists to the remote device
>
> What is the best way to transfer the data over the serial line?
>
> Do I just rely on the transmission quality or, if not, how do I ensure
> that every piece of data is transmittet correctly?
>
> I'd be glad to hear any kind of idea. Thank you.
Wrap a bit of protocol round the data. Add a checksum, so you can detect
errors, then you can have a simple ACK/NAK protocol. Add a sequence number,
then you can tell if any data got lost on the way.
-- Dave Clarke
- Previous message: Anders Christensen: "Datatransfer via serial line"
- In reply to: Anders Christensen: "Datatransfer via serial line"
- Next in thread: Grant Edwards: "Re: Datatransfer via serial line"
- Reply: Grant Edwards: "Re: Datatransfer via serial line"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|