Home AMX User Forum NetLinx Studio

Hexadecimal codes

Hi

I have to program a Vidikron plasma. In the manual all serial codes are listed as Hexadecimal code ( ex: 9FH 80H 60H 4EH 00H CDH )
How I have to write my code to get correct command ?

SEND_STRING dvPLASMA, "$9FH,$80H,$60H,$4EH,$00H,$CDH" ?

OR

SEND_STRING dvPLASMA, "$9F,$80,$60,$4E,$00,$CD" ?

Comments

  • Joe HebertJoe Hebert Posts: 2,159
    Hi Denis,

    The first option you posted won't compile and will generate a syntax error.

    You're 2nd option is correct:
    SEND_STRING dvPLASMA, "$9F,$80,$60,$4E,$00,$CD"

    The $ denotes Hex for AMX.
  • DenisDenis Posts: 163
    Thanks

    Thanks Joe !

    One thing...I don't know why I don't try this before post this thread, I'm comfused...........
  • Thomas HayesThomas Hayes Posts: 1,164
    The 'H' I believe indicates that it is a Hex value. The letters would be a dead give away but what if the hex value is 15 or 29. Is it hex or deciamal or other.
  • DHawthorneDHawthorne Posts: 4,584
    The 'H' I believe indicates that it is a Hex value. The letters would be a dead give away but what if the hex value is 15 or 29. Is it hex or deciamal or other.
    True, but the NetLinx compiler doesn't recognize that, which is the issue in this example.
  • Thomas HayesThomas Hayes Posts: 1,164
    Yes, you are correct Dave, I was only trying to indicate that the 'H' although written and denotes Hex it is not used with AMX programming. Sorry for the confusion.
  • DenisDenis Posts: 163
    Tanks

    Thanks guys

    I appreciate your specifications for " H "
Sign In or Register to comment.