Shop OBEX P1 Docs P2 Docs Learn Events
How can I display variables on an lcd screen and how can I share them between c — Parallax Forums

How can I display variables on an lcd screen and how can I share them between c

P!-RoP!-Ro Posts: 1,189
edited 2008-11-06 04:05 in Propeller 1
I would like to display variables on an lcd screen but I don't know how to do it. I can display words, but that is it. Also, I was wondering how to share variables between cogs. Could you help me?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Pi Guy

Comments

  • science_geekscience_geek Posts: 247
    edited 2008-11-04 04:15
    it would help if i knew what kind of display, im getting familiar with the type of displays like those from 4d systems,
  • Mike GreenMike Green Posts: 23,101
    edited 2008-11-04 05:43
    You're probably using a serial LCD display, therefore you're using some kind of serial I/O driver. All of these should have a method (subroutine) called "dec" which takes one expression as an argument, converts it to a variable length string of digit characters and transmits that out the serial port. For example:

    ser.dec(5*a - 3) will display as "7" if a is 2 or "17" if a is 4 or "-3" if a is zero (without the quotes).
  • P!-RoP!-Ro Posts: 1,189
    edited 2008-11-04 23:27
    What about sharing variables between the cogs?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Pi Guy
  • Brian218Brian218 Posts: 92
    edited 2008-11-06 04:05
    I LIKE PI said...
    What about sharing variables between the cogs?

    Shouldn't be a problem with global variables.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    This post is a work of art. Variations in spelling and grammar are intentional, artistic endeavors that add value to all of mankind.
Sign In or Register to comment.