Shop OBEX P1 Docs P2 Docs Learn Events
Binary outpit — Parallax Forums

Binary outpit

HumpeHumpe Posts: 10
edited 2007-12-16 18:26 in BASIC Stamp
Hi

Lets say that i got an variable with the binary number of "10010111". How do I make the corresponing pins that have the "1" set to go high?

In my case that would be pins 0,1,2,3,5,8.

Comments

  • PJAllenPJAllen Banned Posts: 5,065
    edited 2007-12-16 16:20


    [color=red]DIRL = $FF[/color]
    humpe  VAR  byte
    OUTL [color=red]= [/color]humpe
    


    Post Edited (PJ Allen) : 12/16/2007 4:30:16 PM GMT
  • HumpeHumpe Posts: 10
    edited 2007-12-16 18:26
    Thanks a lot. Works perfectly.
Sign In or Register to comment.