spi_slave_hw

SPI Slav0e Hardware

Author Matthew Schinkel - borntechi.com, copyright © 2009, all rights reserved.
Adapted-by
Compiler 2.4o

Description

SPI Hardware Slave library for exchanging data through SPI bus.


Sources

http://www.justanotherlanguage.org/content/jallib/tutorials/tutorial_spi_introduction
Jallib spi_master_hw library - Written by William Welch
http://ww1.microchip.com/downloads/en/devicedoc/spi.pdf


Dependencies


Summary

Global variables/contants

Procedures

Functions


API details

Global variables/contants

Procedures

  • spi_slave_hw'put(byte in data)

    wait to receive data from the spi port
    (wait for chip select to go low, and clock pulses to come in from master)
    
    

  • spi_slave_initerrupt()

    No documentation found

  • spi_slave_hw_sync()

    Synchronize SPI. Sets SPI bit counter to 0 to sync received data. You should
    use this if you set SPI_SLAVE_HW_SYNCHRONOUS == FALSE, or if you don't use
    pin_ss for chip select. On a stable wire, you don't need to use this but it
    is recommended that you use it once per packet. On an unstable wire, you
    should use this more often. Maybe even after every byte recieved.
    
    

  • spi_slave_init(byte in spi_mode)

    spi slave init
    
    

Functions


Related samples

Here are the list of samples which use this library:

18f462018f4620_spi_to_serial.jal
18f462018f4620_spi_slave_hw.jal