'///////////////////////////////////////////////////////// '/// FastAVR Basic Compiler for AVR by MICRODESIGN /// '/// RC5 test program /// '/// RC5.bas www.FastAVR.com /// '///////////////////////////////////////////////////////// ' Command displays on LEDs on PORTB ' LEDs are btw PORTB and Vcc via 1k resistors $Device= 2313 ' used device $Stack = 32 ' stack depth $Clock = 12 ' used cristal $RC5=PORTD.7 Dim SysAdr As Byte, Command As Byte PORTB=&hff ' Leds OFF DDRB =&hff ' PORTB is output Enable Timer0 ' needs by RC5 Enable Interrupts Do RC5(SysAdr, Command) ' wait for RC5 PORTB=Not Command ' yes, show it on PORTB Loop