piclist 2001\01\11\142547a >
Thread: Bit banging Asynchronous Serial Communication
face BY : mike.....@EraseMEwhitewing.co.uk

On Thu, 11 Jan 2001 07:55:19 +0100, you wrote:

{Quote hidden}

Either will work. Edge-detection will be more susceptible to noise,
but this won't be a problem for most apps. Edge detect is also the
only option for very high baudrates, where you can't get a
sufficiently high sample rate for polling. Edge-det also uses no CPU
time until data comes along.
Polling has the advantage of only needing one interrupt source, which
can be shared with other timer int functions.
As with most of these things, there is no 'best' way - it depends on
your application.
>> 2) Once you think the start byte is coming, what is the best way to be
>> sure.  ie, do you look for a pulse that is equal to 1/baud rate? or do you
>> assume that any transition is the beginning of the Start Byte?
Depends on how much noise you expect. You should allow margins for
baud errors, so if you do check the length, check for at least, say,
0.5 or 0.75/baudrate. An easy way is to have a timer int at
baudrate*2, and check for startbit on 2 successive ints.
{Quote hidden}

http://www.piclist.com hint: To leave the PICList

<j02r5t0r1co6u24gl53f9n1bgps1k1f34m@4ax.com> quoted-printable

In reply to: <Pine.LNX.4.21.0101110752450.455-100000@prof.pmmf.hu>
See also: www.piclist.com/techref/io/serials.htm?key=serial
Reply You must be a member of the piclist mailing list (not only a www.piclist.com member) to post to the piclist. This form requires JavaScript and a browser/email client that can handle form mailto: posts.
Subject (change) Bit banging Asynchronous Serial Communication

month overview.

new search...