MikroElektronika PIC Microcontrollers PIC16 Ficha de datos Pagina 149

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 194
  • Tabla de contenidos
  • SOLUCIÓN DE PROBLEMAS
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 148
Programming PIC Microcontrollers in BASIC - mikroElektronika
Prototype
sub procedure Soft_UART_Init(dim byref Port as byte, const RX, const TX,
const Baud_Rate)
Description Initializes PIC MCU UART at specified pins establishes communication at <Baud_Rate>.
If you specify the unsupported baud rate, compiler will report an error.
Example
Soft_UART_Init(PORTB, 1, 2, 9600)
5.2.20.2 Soft_UART_Read – Receives a byte
Prototype sub function Soft_UART_Read(dim byref Msg_received as byte) as byte
Description Function returns a received byte. Parameter <Msg_received> will take true if transfer was succesful.
Soft_UART_Read is a non-blocking function call, so you should test <Msg_received> manually (check the
example below).
Example
Received_byte = Soft_UART_Read(Rec_ok)
5.2.20.4 Soft_UART_Write – Transmits a byte
http://www.mikroelektronika.co.yu/english/product/books/picbasicbook/05.htm (107 sur 112)05/11/2004 02:20:55
Vista de pagina 148
1 2 ... 144 145 146 147 148 149 150 151 152 153 154 ... 193 194

Comentarios a estos manuales

Sin comentarios