mikroBASIC
- Basic Compiler for Microchip PIC microcontrollers
program RS232com
dim Received_byte as byte
main:
USART_init(2400)
' initialize USART module
while true
if USART_data_ready = 1 then
' if data is received
Received_byte = USART_read
' read received data,
USART_write(Received_byte)
' send data via USART
end if
wend
end.
Figure: RS232 HW connection
MikroElektronika:
Development
tools
-
Books
-
Compilers
mikroBASIC
making it simple...
163
page
Kommentare zu diesen Handbüchern