Shop OBEX P1 Docs P2 Docs Learn Events
Parallax Backlit 2x16 LCD, #27977 — Parallax Forums

Parallax Backlit 2x16 LCD, #27977

PADTPADT Posts: 8
edited 2007-11-16 03:39 in BASIC Stamp
I have a BS2p24.· Am requesting a simple code for getting my 2x16 backlit LCD (#27977)··to display text. Even a successful display of just "Hello World" is fine.· I tried with example code but funny chars displayed instead of the expected text:· No idea what I'm doing wrong. Baud rate? is this code compatible with BS2p?
TxPin CON 0
Baud19200 CON 32
HIGH TxPin ' Set pin high to be a serial port
PAUSE 100 ' Pause for Serial LCD to initialize

SEROUT TxPin, Baud19200, [noparse][[/noparse]"Hello, this text will wrap."]

Thanks in advance,

Anna

Comments

  • RDL2004RDL2004 Posts: 2,554
    edited 2007-11-15 11:40
    This is probably due to the baudmode being set incorrectly, 32 is for a plain BS2.

    For the BS2P you need to change:

    Baud19200 CON 32

    to:

    Baud19200 CON 110

    For more information on how to calculate this number for the various types of Stamps look under the SEROUT command in the editor help files. The tables they give only go up to 9600, but it tells you how to calculate for higher speeds.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    - Rick
  • PADTPADT Posts: 8
    edited 2007-11-16 03:39
    WoW! freaked.gif That's the ticket, 110 works great!!
    Thank you!! roll.gif
Sign In or Register to comment.