Shop OBEX P1 Docs P2 Docs Learn Events
HIGHBYTE and LOWBYTE in SX/B — Parallax Forums

HIGHBYTE and LOWBYTE in SX/B

crgwbrcrgwbr Posts: 614
edited 2006-12-21 18:11 in General Discussion
As everyone I'm sure knows, in PBASIC, to send a word variable you use somthing like:

Serout TX, baudmode, [noparse][[/noparse]var_name.LOWBYTE, var_name.HIGHBYTE]

How would you do the same in SX/B?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
NerdMaster
For
Life

Comments

  • BeanBean Posts: 8,129
    edited 2006-12-21 18:11
    Append _MSB or _LSB to get the LOWBYTE or HIGHBYTE.

    SEROUT TX, baudmode, var_name_LSB
    SEROUT TX, baudmode, var_name_MSB

    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Cheap used 4-digit LED display with driver IC·www.hc4led.com

    Low power SD Data Logger www.sddatalogger.com
    SX-Video Display Modules www.sxvm.com
    Stuff I'm selling on ebay http://search.ebay.com/_W0QQsassZhittconsultingQQhtZ-1

    "USA Today has come out with a new survey - apparently, three out of every four people make up 75% of the population." - David Letterman
Sign In or Register to comment.