1.1.2.3 Configuring The Library

I2C Driver Library should be configured via MHC. The following figures show the MHC configuration window for I2C driver and brief description.

Common User Configuration for all Instances

  • Driver Mode:

    • Allows User to select the mode of driver(Asynchronous or Synchronous). This setting is common for all the instances.

Instance Specific User Configurations

I2C Driver Configuration in Asynchronous Mode

drv_i2c_mhc_config_async

I2C Driver Configuration in Synchronous Mode

drv_i2c_mhc_config_sync
  • PLIB Used:

    • Indicates the underlying I2C PLIB used by the driver.

    • The I2C driver only supports connecting to the I2C PLIB in master mode.

  • Number Of Clients:

    • The total number of clients that can open the given I2C driver instance

  • Transfer Queue Size:

    • Indicates the size of the transfer queue for the given I2C driver instance

    • Available only in Asynchronous mode of Operations