Microchip® Advanced Software Framework

twis.h File Reference
#include <avr32/io.h>
#include <stdint.h>
#include "compiler.h"
#include "status_codes.h"
#include "conf_twis.h"

Data Structures

struct  twis_options_t
 Input parameters when initializing the twi module mode. More...
 
struct  twis_package_t
 Information concerning the data transmission. More...
 
struct  twis_slave_fct_t
 Pointer on TWI slave user specific application routines. More...
 

Macros

TWI Driver Compatibility

Codes for UC3 devices using TWI modules can easily be ported to UC3 devices with TWIM module

#define avr32_twi_t   avr32_twis_t
 
#define twi_options_t   twis_options_t
 
#define twi_package_t   twis_package_t
 
#define twi_slave_fct_t   twis_slave_fct_t
 
#define twi_slave_init   twis_slave_init
 

Functions

void twis_send_data_ack (volatile avr32_twis_t *twis)
 Enable ACK transfer in Slave Receiver Mode. More...
 
void twis_send_data_nack (volatile avr32_twis_t *twis, bool stop_callback)
 Enable NACK transfer in Slave Receive Mode. More...
 
status_code_t twis_slave_init (volatile avr32_twis_t *twis, const twis_options_t *opt, const twis_slave_fct_t *slave_fct)
 Initialize the TWI Slave Module. More...