Paparazzi UAS  v5.15_devel-230-gc96ce27
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
i2c_arch.c File Reference

Handling of I2C hardware for LPC21xx. More...

#include "mcu_periph/i2c.h"
#include "std.h"
#include <BOARD_CONFIG>
#include "armVIC.h"
+ Include dependency graph for i2c_arch.c:

Go to the source code of this file.

Functions

static bool i2c_lpc21_idle (struct i2c_periph *p)
 
static bool i2c_lpc21_submit (struct i2c_periph *p, struct i2c_transaction *t)
 
static void i2c_lpc21_setbitrate (struct i2c_periph *p, int bitrate)
 
static void I2cSendStart (struct i2c_periph *p)
 
static void I2cSendAck (void *reg)
 
static void I2cEndOfTransaction (struct i2c_periph *p)
 
static void I2cSendStop (struct i2c_periph *p, struct i2c_transaction *t)
 
static void I2cFail (struct i2c_periph *p, struct i2c_transaction *t)
 
static void I2cSendByte (void *reg, uint8_t b)
 
static void I2cReceive (void *reg, bool ack)
 
static void I2cClearStart (void *reg)
 
static void I2cClearIT (void *reg)
 
static void I2cAutomaton (int32_t state, struct i2c_periph *p)
 
void i2c_event (void)
 i2c_event() function More...
 

Detailed Description

Handling of I2C hardware for LPC21xx.

Definition in file i2c_arch.c.

Function Documentation

static bool i2c_lpc21_idle ( struct i2c_periph p)
static

Definition at line 356 of file i2c_arch.c.

References I2CIdle, and i2c_periph::status.

static void i2c_lpc21_setbitrate ( struct i2c_periph p,
int  bitrate 
)
static

Definition at line 398 of file i2c_arch.c.

References i2c_periph::reg_addr.

static void I2cClearIT ( void *  reg)
inlinestatic

Definition at line 105 of file i2c_arch.c.

References SIC.

static void I2cClearStart ( void *  reg)
inlinestatic

Definition at line 100 of file i2c_arch.c.

References STAC.

Referenced by I2cAutomaton().

+ Here is the caller graph for this function:

static void I2cEndOfTransaction ( struct i2c_periph p)
inlinestatic

Definition at line 57 of file i2c_arch.c.

References I2C_TRANSACTION_QUEUE_LEN, I2CIdle, and I2cSendStart().

Referenced by I2cFail(), and I2cSendStop().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void I2cFail ( struct i2c_periph p,
struct i2c_transaction t 
)
inlinestatic

Definition at line 80 of file i2c_arch.c.

References I2cEndOfTransaction(), I2CTransFailed, and STO.

Referenced by I2cAutomaton().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void I2cReceive ( void *  reg,
bool  ack 
)
inlinestatic

Definition at line 94 of file i2c_arch.c.

References AA, and AAC.

Referenced by I2cAutomaton().

+ Here is the caller graph for this function:

static void I2cSendAck ( void *  reg)
inlinestatic

Definition at line 52 of file i2c_arch.c.

References AA.

static void I2cSendByte ( void *  reg,
uint8_t  b 
)
inlinestatic

Definition at line 89 of file i2c_arch.c.

Referenced by I2cAutomaton().

+ Here is the caller graph for this function:

static void I2cSendStart ( struct i2c_periph p)
inlinestatic

Definition at line 46 of file i2c_arch.c.

References I2CStartRequested, and STA.

Referenced by i2c_lpc21_submit(), I2cAutomaton(), and I2cEndOfTransaction().

+ Here is the caller graph for this function:

static void I2cSendStop ( struct i2c_periph p,
struct i2c_transaction t 
)
inlinestatic

Definition at line 72 of file i2c_arch.c.

References I2cEndOfTransaction(), I2CTransSuccess, and STO.

Referenced by I2cAutomaton().

+ Here is the call graph for this function:

+ Here is the caller graph for this function: