Baud rate question.
Archiver
Posts: 46,084
I am new to BS2's and got my first one a few weeks ago and have made a
lot of progress making this cool BS2 do what I need.
( Spit out a hex string when I hit a button ).
Anyway, in theory it is working but I ran into a snag. I had some bad
information from the company that makes the gear I am interfacing this
to.
It just wouldn't work. I have the BS2 set at 38.4K, 8, N, 1. It works
wonderful with emulation software on a laptop. But when I hook it to
the actual
box it doesn't work. Problem is I need 38.4K, 8, E, 1. ( The emulation
software lets you change all these parameters, the actual HARDWARE
doesn't!!
Reading the dox today said you can do 8, N, 1 or 7, E, 1.
Does anyone know how ( or IF ) I can get these hex strings spit out on
a serial port at 8, E, 1???
Thanks
Alan
lot of progress making this cool BS2 do what I need.
( Spit out a hex string when I hit a button ).
Anyway, in theory it is working but I ran into a snag. I had some bad
information from the company that makes the gear I am interfacing this
to.
It just wouldn't work. I have the BS2 set at 38.4K, 8, N, 1. It works
wonderful with emulation software on a laptop. But when I hook it to
the actual
box it doesn't work. Problem is I need 38.4K, 8, E, 1. ( The emulation
software lets you change all these parameters, the actual HARDWARE
doesn't!!
Reading the dox today said you can do 8, N, 1 or 7, E, 1.
Does anyone know how ( or IF ) I can get these hex strings spit out on
a serial port at 8, E, 1???
Thanks
Alan
Comments
pro's out
there??? HELP???????????
--- In basicstamps@yahoogroups.com, Alan N. <alann19@c...> wrote:
> I am new to BS2's and got my first one a few weeks ago and have made a
> lot of progress making this cool BS2 do what I need.
> ( Spit out a hex string when I hit a button ).
>
> Anyway, in theory it is working but I ran into a snag. I had some bad
> information from the company that makes the gear I am interfacing this
> to.
>
> It just wouldn't work. I have the BS2 set at 38.4K, 8, N, 1. It works
> wonderful with emulation software on a laptop. But when I hook it to
> the actual
> box it doesn't work. Problem is I need 38.4K, 8, E, 1. ( The emulation
> software lets you change all these parameters, the actual HARDWARE
> doesn't!!
>
> Reading the dox today said you can do 8, N, 1 or 7, E, 1.
>
> Does anyone know how ( or IF ) I can get these hex strings spit out on
> a serial port at 8, E, 1???
>
> Thanks
>
> Alan
The stamp firmware allows 8 data no parity, and
7 data even parity, and that's it.
You might look at:
http://www.rentron.com/Myke7.htm
This site has an EXCELLENT tutorial of how to do
232 "NRZ" signaling. Some options:
1. Get a small PIC (16F629) and program the
above routines into it, modified to support 8 data
Even parity. Control the PIC with the BS2, and
send the data out as "SHIFTOUT" on an SPI
connection to the chip, which will then send
the data out 8 data Even Parity.
2. Get a 16C550 UART (1650, 16450) or
compatible chip, and program it.
You'll need to implement a parallel
out port on the Stamp -- with 16 Stamp I/O pins,
may not be a problem.
3. Check out Black-Box for various protocol
converters -- parallel to serial may let you
set 8 data Even parity.
--- In basicstamps@yahoogroups.com, "vintonalan" <alann19@c...> wrote:
> I asked this a few days ago and I * REALLY * need an answer from
some of you pro's out
> there??? HELP???????????
>
>
> --- In basicstamps@yahoogroups.com, Alan N. <alann19@c...> wrote:
> > I am new to BS2's and got my first one a few weeks ago and have
made a
> > lot of progress making this cool BS2 do what I need.
> > ( Spit out a hex string when I hit a button ).
> >
> > Anyway, in theory it is working but I ran into a snag. I had
some bad
> > information from the company that makes the gear I am interfacing
this
> > to.
> >
> > It just wouldn't work. I have the BS2 set at 38.4K, 8, N, 1. It
works
> > wonderful with emulation software on a laptop. But when I hook it
to
> > the actual
> > box it doesn't work. Problem is I need 38.4K, 8, E, 1. ( The
emulation
> > software lets you change all these parameters, the actual
HARDWARE
> > doesn't!!
> >
> > Reading the dox today said you can do 8, N, 1 or 7, E, 1.
> >
> > Does anyone know how ( or IF ) I can get these hex strings spit
out on
> > a serial port at 8, E, 1???
> >
> > Thanks
> >
> > Alan
a good choice is the MAX3100 (or others in that family of chips from
http://www.maxim-ic.com). It is a UART that connects to the Stamp
via an SPI buss. It has a lot of nice features, including the 8,E,1
that you need. Stamp examples are available:
<http://www.emesys.com/BS2IrDA.htm>
<http://www.wd5gnr.com/suart.htm>
<http://devices.sapp.org/micro/stamp2sx/max3110/>
--regards,
Tracy Allen
http://www.emesystems.com
>I asked this a few days ago and I * REALLY * need an answer from
>some of you pro's out
>there??? HELP???????????
>
>
>--- In basicstamps@yahoogroups.com, Alan N. <alann19@c...> wrote:
>> I am new to BS2's and got my first one a few weeks ago and have made a
>> lot of progress making this cool BS2 do what I need.
>> ( Spit out a hex string when I hit a button ).
>>
>> Anyway, in theory it is working but I ran into a snag. I had some bad
>> information from the company that makes the gear I am interfacing this
>> to.
>>
>> It just wouldn't work. I have the BS2 set at 38.4K, 8, N, 1. It works
>> wonderful with emulation software on a laptop. But when I hook it to
>> the actual
>> box it doesn't work. Problem is I need 38.4K, 8, E, 1. ( The emulation
>> software lets you change all these parameters, the actual HARDWARE
>> doesn't!!
>>
>> Reading the dox today said you can do 8, N, 1 or 7, E, 1.
>>
>> Does anyone know how ( or IF ) I can get these hex strings spit out on
>> a serial port at 8, E, 1???
>>
>> Thanks
>>
>> Alan
>
>
>To UNSUBSCRIBE, just send mail to:
> basicstamps-unsubscribe@yahoogroups.com
>from the same email address that you subscribed. Text in the
>Subject and Body of the message will be ignored.
>
>
>Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
Here's a partial solution that may do you some good depending on what
data you need to transmit.
You can transmit any odd-parity byte in 8-bit, no-parity format and
the receiver will view the data as 8-bit, even parity. The reason is
the stop bit will be interpreted by the receiver as the parity bit,
and this will form correct even parity over the data and "parity"
bits. To add a little insurance, use SEROUT's delay parameter to
extend the idle time between byte transmissions so there's plenty of
time for the follow-on idle line to be interpreted as a stop bit.
Regards,
Steve