Shop OBEX P1 Docs P2 Docs Learn Events
Serial Output problem - FIXED — Parallax Forums

Serial Output problem - FIXED

Mike CookMike Cook Posts: 829
edited 2005-10-15 21:20 in General Discussion

Quick question:

I'm using one of Jon's examples to send serial data out of the SX52 Proto Board to a PC.

Seems to work, however on power up or reset of the SX52 Proto board I am missing the first character of the serial data. I tried putting a delay at beginning of the program but that did not help.

I'm new to SX/B so I'm kinda lost at this point. Is there any other start up code I need to include to prevent this?

Attached is a screen shot of the terminal program capture and the SX/B source code.

Note: for the terminal program I used Windows Hyperterm and also tried ProComm, got the same results with both terminal programs. Both terminal programs were set for 9600,8,N,1 no Flow Control. Also in the *.jpg after the fourth line printed I pressed the reset button, it displayed "est of the SX52 Proto Board" instead of "Test of the SX52 Proto Board", missing the "T"

Further·Testing:

1. Powered off the SX52 Proto Board, disconnected the "SX-Key" and retested with the same dev PC, same results

2. Tried another PC to capture the data, still missing the first character on power up.

Thanks In Advance,

Mike

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"OEM NMEA GPS Module" Now available on ebay for only $19.99

Product web site: http://www.allsurplus.net/Axiom/

Post Edited (Mike Cook) : 10/15/2005 10:46:38 PM GMT

Comments

  • BeanBean Posts: 8,129
    edited 2005-10-15 21:06
    Mike,
    At startup all of the pins on the SX are inputs. So the serial output will be floating until the first bit is transmitted.

    Try putting "HIGH TXD" or "LOW TXD" before the first initial pause. See if one of these fixes the problem.

    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "SX-Video·Module" Now available from Parallax for only $28.95

    http://www.parallax.com/detail.asp?product_id=30012
    Product web site: www.sxvm.com
    Available now... SX-Video OSD module $59.95 www.sxvm.com

    "Save your money. Pay with cash."
    ·
  • Mike CookMike Cook Posts: 829
    edited 2005-10-15 21:20

    Thanks,

    HIGH TxD worked!·I'm using a MAX232 driver chip.

    I'm guessing that SEROUT does not add any "startup code" for the output pin. MORE reading on my part!

    I guess I need to add, to the standard template, a port setup section so this does not byte me again. I used the following and that also worked:

    TRIS_A=%00000000 ' All outputs

    RA=128

    Thanks Again,

    Mike


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "OEM NMEA GPS Module" Now available on ebay for only $19.99

    Product web site: http://www.allsurplus.net/Axiom/

    Post Edited (Mike Cook) : 10/15/2005 10:37:20 PM GMT
Sign In or Register to comment.