CVRBytecode
Additional CAVRIT Opcodes
To use the new opcodes, add the following line to the CricketLogo configuration file:
print c 1 hexprint c 1 pattern c 2 clearlcd c 0 setpin c 1 clearpin c 1 sensor r 1 switch r 1
Name: print
Bytecode: 0x49, 73
Arguments: One, 16-bit number to print
Returns: None
Description: Prints the decimal value of a 16-bit number to the LCD.
Name: hexprint
Bytecode: 0x4A, 74
Arguments: One, 16-bit number to print
Returns: None
Description: Prints the hexadecimal value of a 16-bit number to the LCD.
Name: pattern
Bytecode: 0x4B, 75
Arguments: Two in the form: pattern <character> <digit>
Where <character> is a 16-bit number constructed to
display a certain pattern (see section on LCD programming)
and <digit> is a value between 1 and 6.
Returns: None
Description: Writes the specified pattern to the LCD at the digit
specified. It is recommended that the user run the
clearlcd opcode prior to this command to ensure
that the screen will properly display the character.
Name: clearlcd
Bytecode: 0x4C, 76
Arguments: None
Returns: None
Description: Clears all data from the LCD screen and the text buffer.
Name: setpin
Bytecode: 0x4D, 77
Arguments: One number from 0-3. The actual pin that is modified will be from
pins 4-7 on PORTB.
Returns: None
Description: Sets one of the pins from 4-7 on PORTB to output a digital one.
Name: clrpin
Bytecode: 0x4E, 78
Arguments: One number from 0-3. The actual pin that is modified will be from
pins 4-7 on PORTB.
Returns: None
Description: Sets one of the pins from 4-7 on PORTB to output a digital zero.