Shop OBEX P1 Docs P2 Docs Learn Events
Propeller / Serial LCD Problem — Parallax Forums

Propeller / Serial LCD Problem

Digital FlowDigital Flow Posts: 3
edited 2007-08-30 19:45 in Propeller 1
Hello All.
I am new to the propeller and am having a problem.
Going through the demo programs and trying to learn the system.
Using demo program, "Debug_lcd_Test.spin"
Using Propeller Demo Board, Rev F.
Connected to the Parallax 4x20· Serial LCD "item # 30058".
No changes·were made·to the LCD or demo program. The LCD displays trash.
Connected to Scott Edwards BBP-420 V4.0 4x20 Serial LCD
Changed Baud to 9600 in demo program. The LCD displays trash.
Both displays connected to my PCs serial port pin #3·and they work just fine.
Have I missed something in the spin demo. Demo's normally work very well and
are good teachers.
Both displays work with the BS2.
Thanks for any help.

Comments

  • Fred HawkinsFred Hawkins Posts: 997
    edited 2007-08-30 01:33
    Can you post a photo of your set-up?
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2007-08-30 01:49
    The demo board doesn't have RS232 so how are you connecting it? Logic level? You will probably need to invert the tx signal either in hardware or very simply in software in the putc routine. This might be one way to do it by using a inverted boolean assignment like this (I think)
    outa[noparse][[/noparse]tx] <>= (txbyte >>= 1) & 1 ' output bit (true mode)

    *Peter*
  • Tom CTom C Posts: 461
    edited 2007-08-30 04:53
    Peter,

    I believe that the "Debug_lcd_Test.spin" uses P0 as the serial output and the Parallax LCD display should accept the serial·output from the the Propeller P0 pin.

    Digital Flow,

    I assume that you have compiled "Debug_lcd_Test.spin" with all of the required objects·shown in the Readme.txt?

    Regards,

    TCIII

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    If you are going to send·a Robot·to save the world, you·better make sure it likes it the way it is!
  • Digital FlowDigital Flow Posts: 3
    edited 2007-08-30 10:28
    Thank you very much for all of the help!
    I will look into these ideas and continue to track down the problem.
    Peter, you are correct I am using P0 as the serial output pin.
    just as stated in the DOC's.
    I will take the data stream apart coming out of P0 with the scope.
    I assumed the demo would be plug and play.
    Thanks for all your post and helpful ideas, I hope I will be able to return the kind deed.

    Keep on pushing

    Digital Flow
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2007-08-30 13:12
    Ok, as I have now looked at the data for the lcd you mentioned I can see where you are going wrong. By default the lcd is setup to interface to RS-232 which indeed works. You have to set the option jumper to make it work with TTL levels which are inverted (idles high). The lcd manual says:

    "The LK204-25 provides a DB-9 Connector to readily interface with serial devices which use the EIA232
    standard signal levels of §12V to §12V. It is also possible to communicate at TTL levels of 0 to +5V by
    setting the Protocol Select Jumpers to TTL."

    You made an "assumption" (a terrible sin which we are all guilty of from time to time) that the demo would work with this lcd. Most other serial lcds are ttl level but the one you picked is RS-232. You should have tweaked to the fact that it worked straight off the PC but not off the demo board, the DB9 connector is also a give-away. In fact, if it was the 2x16 lcd (#27976) then it would not work straight off the PC and you might have damaged it if you had done so.

    *Peter*
  • Digital FlowDigital Flow Posts: 3
    edited 2007-08-30 19:45
    Thanks very much Peter!
    Sometime you just can't see the forest for the trees.
    I will change the input to TTL and retest.
    I will post the results!
    Again, thanks for all of the input.

    Digital Flow
Sign In or Register to comment.