ISF  2.1
Intelligent Sensing Framework for Kinetis with Processor Expert
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
fsl_i2c_master_driver.h File Reference

fsl_i2c_master_driver.h defines structures and types for the i2c master driver. More...

#include <stdlib.h>
#include "fsl_i2c_hal.h"
#include "PE_Types.h"
#include "mqxlite.h"
#include "lwevent.h"
Include dependency graph for fsl_i2c_master_driver.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  I2CDeviceInfo
 Information necessary to communicate with an I2C slave device. More...
 
struct  sync_object_t
 Type for an synchronization object. More...
 
struct  I2CMasterState
 Internal driver state information. More...
 

Macros

#define I2C_PEX_WRITE_EVENT_SUCCESS   (1)
 
#define I2C_PEX_WRITE_EVENT_ERROR   (I2C_PEX_WRITE_EVENT_SUCCESS << 1)
 
#define I2C_PEX_READ_EVENT_SUCCESS   (I2C_PEX_WRITE_EVENT_ERROR << 1)
 
#define I2C_PEX_READ_EVENT_ERROR   (I2C_PEX_READ_EVENT_SUCCESS << 1)
 

Typedefs

typedef struct I2CDeviceInfo i2c_device_t
 Information necessary to communicate with an I2C slave device. More...
 
typedef enum I2CDirection i2c_direction_t
 Constants for the direction of an I2C transfer. More...
 
typedef struct I2CMasterState i2c_master_t
 Internal driver state information. More...
 

Enumerations

enum  I2CDirection { kI2CRead = 1, kI2CWrite = 0 }
 Constants for the direction of an I2C transfer. More...
 
enum  _i2c_transfer_flags { kI2CNoStart = 1 << 1, kI2CNoStop = 1 << 2 }
 Optional flags to control a transfer. More...
 

Functions

void i2c_master_init (uint32_t instance, i2c_master_t *master)
 Initialize the I2C master mode driver. More...
 
void i2c_master_shutdown (i2c_master_t *master)
 Shut down the driver. More...
 
i2c_status_t i2c_master_configure_bus (i2c_master_t *master, const i2c_device_t *device)
 Configure the I2C bus to access a device. More...
 
i2c_status_t i2c_master_transfer (i2c_master_t *master, const i2c_device_t *device, i2c_direction_t direction, bool stopAfterTransfer, uint32_t subaddress, size_t subaddressLength, uint8_t *data, size_t dataLength, size_t *actualLengthTransferred, uint32_t timeout_ms)
 Perform a blocking read or write transaction on the I2C bus. More...
 

Detailed Description

fsl_i2c_master_driver.h defines structures and types for the i2c master driver.

File: fsl_i2c_master_driver.h

Copyright (c) 2014, Freescale Semiconductor, Inc.

Definition in file fsl_i2c_master_driver.h.