HTBasic Help
×
Menu
Index

BYTE and WORD

 
When BYTE is included in the ASSIGN statement, the data is sent and received as bytes, even if the interface is capable of 16-bit transfers. The upper 8 bits are zeros. (Note: The "W" IMAGE specifier will send a word on a 16-bit interface, even if BYTE is specified in the I/O path.) The WORD attribute can only be included in the ASSIGN statement if the interface is capable of 16-bit transfers. The data is then transferred a word at a time. The WORD attribute is primarily intended for transfer of FORMAT OFF data and can have unexpected side effects with FORMAT ON.
 
When neither BYTE nor WORD is included in the ASSIGN statement, the default is BYTE. Syntax examples including the BYTE and WORD attributes are:
 
ASSIGN @Gpio TO 15;FORMAT OFF,WORD
ASSIGN @Meter TO 711,712;BYTE