Author | Joep Suijs, Copyright © 2008 Joep Suijs |
Adapted-by | |
Compiler | >=2.4g |
Level1 implementation of I2C (single) master.
No dependency found
i2c_receive_byteaddr(byte in i2c_address, byte in addr, byte in i2c_rx_count) return bit
i2c_send_receive(byte in i2c_address, byte in i2c_tx_count, byte in i2c_rx_count) return bit
i2c_receive_wordaddr(byte in i2c_address, word in addr, byte in i2c_rx_count) return bit
i2c_receive_byteaddr(byte in i2c_address, byte in addr, byte in i2c_rx_count) return bit
i2c_receive_byteaddr - send a byte address and receive a string from an i2c slave
i2c_send_receive(byte in i2c_address, byte in i2c_tx_count, byte in i2c_rx_count) return bit
i2c_send_receive - send a string to an i2c slave and receive bytes back This funtion uses two global i2c buffers, one for transmit (tx) and one for receive (rx). The address of the slave (higher 7 bits), number of bytes to transmit and number of bytes to receive are parameters. returns true if all went well.
i2c_receive_wordaddr(byte in i2c_address, word in addr, byte in i2c_rx_count) return bit
i2c_receive_wordaddr - send a word address and receive a string from an i2c slave