117 avr_io_addr_t r_twdr
data register
Definition: avr_twi.h:86
uint8_t state
Definition: avr_twi.h:99
internal state, do not use in irq messages
Definition: avr_twi.h:54
avr_io_addr_t r_twbr
bit rate register
Definition: avr_twi.h:81
uint32_t v
Definition: avr_twi.h:66
uint8_t next_twstate
Definition: avr_twi.h:101
uint32_t msg
Definition: avr_twi.h:59
uint16_t avr_io_addr_t
Definition: sim_avr_types.h:37
avr_regbit_t twsr
status registers, (5 bits)
Definition: avr_twi.h:94
char name
Definition: avr_twi.h:77
struct avr_twi_msg_t avr_twi_msg_t
avr_t * avr
Definition: run_avr.c:54
uint32_t addr
Definition: avr_twi.h:59
avr_io_addr_t r_twsr
status register
Definition: avr_twi.h:83
uint8_t peer_addr
Definition: avr_twi.h:100
avr_io_addr_t r_twar
address register (slave)
Definition: avr_twi.h:84
interrupt vector for the IO modules
Definition: sim_interrupts.h:37
This 'structure' is a packed representation of an IO register 'bit' (or consecutive bits)...
Definition: sim_avr_types.h:47
avr_regbit_t twsto
stop condition
Definition: avr_twi.h:91
struct avr_twi_msg_irq_t avr_twi_msg_irq_t
uint32_t avr_twi_irq_msg(uint8_t msg, uint8_t addr, uint8_t data)
Create a message value for twi including the 'msg' bitfield, 'addr' and data.
Definition: avr_twi.c:476
avr_regbit_t twen
twi enable bit
Definition: avr_twi.h:88
avr_io_addr_t r_twamr
address mask register
Definition: avr_twi.h:85
struct avr_twi_t avr_twi_t
avr_int_vector_t twi
twi interrupt
Definition: avr_twi.h:97
union avr_twi_msg_irq_t::@17 u
avr_regbit_t twps
prescaler bits (2 bits)
Definition: avr_twi.h:95
avr_regbit_t twea
enable acknowledge bit
Definition: avr_twi.h:89
uint32_t data
Definition: avr_twi.h:59
avr_regbit_t twsta
start condition
Definition: avr_twi.h:90
uint32_t unused
Definition: avr_twi.h:59
avr_regbit_t twwc
write collision
Definition: avr_twi.h:92
avr_io_addr_t r_twcr
control register
Definition: avr_twi.h:82
avr_twi_msg_t twi
Definition: avr_twi.h:67
avr_io_t io
Definition: avr_twi.h:76
Main AVR instance.
Definition: sim_avr.h:142
IO module base struct Modules uses that as their first member in their own struct.
Definition: sim_io.h:42
void avr_twi_init(avr_t *avr, avr_twi_t *port)
Definition: avr_twi.c:458
avr_regbit_t disabled
bit in the PRR
Definition: avr_twi.h:79