Shop OBEX P1 Docs P2 Docs Learn Events
LCD Problems — Parallax Forums

LCD Problems

enowakenowak Posts: 9
edited 2006-02-24 18:59 in General Discussion
I am having problems driving a parallel LCD display with the SX-48 Proto board. I am using the code written Al Williams. It works perfectly when using an SX28, but when the same code is loaded into the SX48 second line feature doesn’t work correctly, the message sometimes has random characters in it, and is not located properly. I have attached the code that I am using for the SX48. I could use some help on what I am doing wrong.

Comments

  • BeanBean Posts: 8,129
    edited 2006-02-23 17:21
    Are you using the latest version of SX/B 1.42.01 ?
    If not you can download it from here: http://forums.parallax.com/showthread.php?p=517621
    Bean.

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

    http://www.parallax.com/detail.asp?product_id=30012

    "SX-Video OSD module" Now available from Parallax for only·$49.95
    http://www.parallax.com/detail.asp?product_id=30015

    Product web site: www.sxvm.com

    "Ability may get you to the top, but it takes character to keep you there."
    ·
  • enowakenowak Posts: 9
    edited 2006-02-23 18:30
    I am using SX/B 1.42 Do you think the .01 revision makes a difference?
  • BeanBean Posts: 8,129
    edited 2006-02-23 18:49
    Why do you ask ?
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2006-02-23 20:07
    It might, and it's always good to use the very latest version of the compiler -- it exists because improvements/fixes have been made. You can get the 1.42.01 version from the sticky note at the top of the SX forum.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
  • RoadsterRoadster Posts: 209
    edited 2006-02-23 21:00
    I have found that going to the latest version cleared up alot of my problems when porting code from SX-28 - SX-48
  • enowakenowak Posts: 9
    edited 2006-02-23 21:26
    I have tried the above program with 1.42.01 and now it will not compile. The error message is “Line 148, error 44, Pass2: Address is not within lower half of memory page” This is mostly associated with the pulsee subroutine.
  • Paul BakerPaul Baker Posts: 6,351
    edited 2006-02-23 21:29
    The beginning address of subroutines must be in the lower 256 bytes of each 512 byte page, so rearrange your program so this is what happens, or place an ORG statement before the subroutine to bump it to the next page.

    PS using indentation in your programs makes it much easier to read for you and us.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·1+1=10
  • enowakenowak Posts: 9
    edited 2006-02-24 14:47
    When writing code in SXB how do I know and control code so that subroutines are called in the lower half of a memory page? I have tried moving some things around but still get the same error messages. How is an ORG instruction implemented in BASIC and would this be wasteful of memory?
  • BeanBean Posts: 8,129
    edited 2006-02-24 15:25
    enowak,
    SX/B DOES automatically handle the code pages, but you have to declare your subroutines using the SUB directive.
    See the template from the help file.
    SX/B has changed quite a bit since Al's book was written.
    Bean.

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

    http://www.parallax.com/detail.asp?product_id=30012

    "SX-Video OSD module" Now available from Parallax for only·$49.95
    http://www.parallax.com/detail.asp?product_id=30015

    Product web site: www.sxvm.com

    "Ability may get you to the top, but it takes character to keep you there."
    ·
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2006-02-24 18:59
    Yes, and it continues to change -- some fun things are coming guys, and we ask that you be flexible when we make updates. Please keep in mind that we update SX/B as feature requests come in.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
Sign In or Register to comment.