Shop OBEX P1 Docs P2 Docs Learn Events
Xbee/serial issue while using an old rayman 4.3" display — Parallax Forums

Xbee/serial issue while using an old rayman 4.3" display

JonathanJonathan Posts: 1,023
edited 2013-12-20 14:17 in Propeller 1
Hi All,

So I have been monkeying around with some xbees. I'm unwiring my system and using the xbees to transmit data from my well/water system, power system, hot tub, garden timer etc. I'm getting it to work just fine when using PST to see the data. But when I switch over to using rayman's 4.3" display I get errors in the data stream, even with just one device on the network. I have checked for cog collisons and everything I can think of.

So here is my question: For some reason the code that runs the display has to use _clkmode = xtal1+pll16x
_clkfreq = 80_000_000. I forget why, but it does. I'm wondering if the odd freq/pll is causing timing errors with the data stream? When running at a freq. of 5mHz and using PST, no problems. Switch over to the display and I get errors.

I have to way clean up the code before I can post a snip. Any and all opinions welcome! :-)

Jonathan

Comments

  • RaymanRayman Posts: 14,662
    edited 2013-12-20 11:43
    I'd suspect you're running low on memory somewhere...
    Are you starting new Spin cogs without sufficient stack ram reserved maybe?

    I doubt it could be the clock, buy you could always try that clock setting with your old PST code and see what happens...

    That 4.3" display driver does need a fast clock, same as the VGA driver on which it was based.
  • Duane DegnDuane Degn Posts: 10,588
    edited 2013-12-20 13:38
    I use several of Rayman's screens and I've had trouble with when some of my wireless modules are near the backlight voltage booster. If you can move the XBee away from the screen, it might help.
  • JonathanJonathan Posts: 1,023
    edited 2013-12-20 14:17
    Ray, I think you nailed it. Increased my xbee cog stack from 100 to 200 longs and so far no errors. Kinda surprised it needs that much, it isn't doing very much. In the pst code i was just running it in the main cog, not launching another cog so I guess that must be it. I will go and do the PST code in it's own cog with a 100 long stack and see if I get errors there.

    Thanks a lot! Not only did you rush me a display during a busy time for you but then ya help me get it running too!

    Jonathan
Sign In or Register to comment.