Shop OBEX P1 Docs P2 Docs Learn Events
Can't get the LCD 4 row to work with my BS2px!!! — Parallax Forums

Can't get the LCD 4 row to work with my BS2px!!!

kingspudkingspud Posts: 128
edited 2006-03-09 04:54 in BASIC Stamp
Hello all,

I recently purchased the LCD 4 row x 20 backlit and I am using the BS2px chip!· I have tried to run the sample programs but nothing seems to work!· The LCD is ok I think... I get the test parallax display when I put it in TEST mode but when I put it in 16200 buad I get garbage on the screen when I run a program.· I tested all the sample programs but none of them work!· Also I am using it on the PDB board!

Is it because the programs are for a BS2 and not the BS2px?

Does anyone have a test program I can use that uses the BS2px chip??

Please help!!!

I want to use this in an application but I can't seem to get it to work period!!

Joe

Comments

  • Adrian SchneiderAdrian Schneider Posts: 92
    edited 2006-03-08 07:38
    Hi Joe

    I assume you have a serial LCD, not a parallel one.

    You probably mean 19200, not 16200 bit/s - as far as I know these LCDs support 1200 and 9600 bit/s only no more, nothing else.

    The serial speed codes of the BS2PX differ from the codes of other BS2 models, because they have different time bases - check
    the manual to select the right serial speed code.

    Regards
    Adrian
  • kingspudkingspud Posts: 128
    edited 2006-03-08 08:37
    Update:

    I have a BS2 chip and the buad rate code works with 32!· I was able to test all the programs but I can't find the code for the BS2px!

    Example:· serout 0, 32, [noparse][[/noparse]"hello"]

    Does anyone know it?

    thanks

    Joe
  • kingspudkingspud Posts: 128
    edited 2006-03-08 08:49
    Figured it out!

    For the BS2px chip you have the 9600 baud setting on the LCD and then you can use the baudmode number 396!

    This worked!

    I was able to see the programs run on the BS2px chip!

    But still a question:

    Why can't I have it set to the 19200 baudrate on the LCD and if I can, what is the baudmode number for this setting?

    thanks

    Joe
  • Adrian SchneiderAdrian Schneider Posts: 92
    edited 2006-03-08 09:36
    Hi Joe

    The serial LCDs (eg. by Parallax or Scott Edwards) are parallel LDS with an additional serial interface. These
    interfaces are usually specified to support only two speeds 1200 and 9600. This is to simplify the serial interface
    design and to reduce extra cost.

    The generic baud mode formula for the px is (hope I am correct):
    baudmode = INT(4000000 / speed) - 20
    eg: speed=19200, baudmode=188

    Adrian
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2006-03-08 12:56
    I've attached a serial LCD demo that works on any BS2 module -- it uses conditional compilation so that you don't have to worry about baud parameters... or put so many exclamation points into a post! tongue.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-03-09 04:54
    Adrian Schneider said...(trimmed)
    The serial LCDs (eg. by Parallax or Scott Edwards) are parallel LDS with an additional serial interface. These
    interfaces are usually specified to support only two speeds 1200 and 9600. This is to simplify the serial interface
    design and to reduce extra cost.
    Actually Parllax Serial LCDs have 2400, 9600 and 19200 bps support.· There are 2 switches with 4 settings, three being those baud rates and the last being the demo mode.· It is important when working with a BASIC Stamp Module other than the stock BS2 to be aware of the differences in timing on several commands.· This information is all available in the Help File, as well as the BASIC Stamp Manual.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
Sign In or Register to comment.