MikroElektronika PIC Microcontrollers PIC16 Manual de usuario Pagina 163

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 172
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 162
Parameter lth_htl determines transmit edge for data. It can have the following val-
ues:
In order to keep this working, you shouldn't override the settings made by the pro-
cedures spi_init or spi_init_ordinary as it uses some of the PIC MCU resources.
Pins RC3, RC4, RC5 are configured as needed (don't change TRISC settings for
these pins - procedure will set them automatically).
The following routines are provided for comfortable use of master mode :
sub procedure SPI_write(dim Data as byte)
Write byte b to SSPBUF, and immediately starts the transmission.
sub function SPI_read(dim Buffer as byte)
Provide clock by sending data (byte b) and read the received data at the end of the
period.
mikroBASIC
- Basic Compiler for Microchip PIC microcontrollers
158
mikroBASIC
MikroElektronika: Development tools - Books - Compilers
making it simple...
page
Note
Read and
Write
Value Meaning
LOW_2_HIGH Data transmit on low to high edge
HIGH_2_LOW Data transmit on high to low edge
Vista de pagina 162
1 2 ... 158 159 160 161 162 163 164 165 166 167 168 ... 171 172

Comentarios a estos manuales

Sin comentarios