I3C API

This page aggregates all C++ I3C-related public methods of the class CosmicAsyncSDK.

Note

I3C protocol support, and therefore this I3C API, is available only on the Binho Supernova. The Binho Pulsar does not support I3C.

group CosmicSDK I3C API

Constants and APIs related to I3C operations.

Functions

uint16_t i3cSetBusVoltage(uint16_t id, uint16_t voltage_mV)

Set the I3C bus supply voltage (VTARG).

Configures the output voltage applied to the I3C bus through the Supernova VTARG pin.

Setting the voltage to 0 mV disables the VTARG output and powers off the downstream devices connected to the I3C bus.

This function controls the physical bus supply and does not perform any I3C protocol transaction.

Note

  • Ensure the selected voltage is compatible with all connected devices.

  • Disabling VTARG (0 mV) may reset or power down all downstream targets.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • voltage_mV – Voltage in millivolts to set the I3C bus to. Valid values are 0 mV or any value between 800 mV and 3300 mV.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cUseExternalVoltage(uint16_t id, bool save = false)

Configures the I3C bus to use an externally supplied voltage.

Notify the host adapter that I2C/SPI/UART/GPIO bus voltage comes from an external supply.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • save – If true, the external voltage configuration will be stored in the device non-volatile memory and will persist across power cycles. If false, the setting applies only to the current session.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cControllerInit(uint16_t id, uint8_t pushPullFrequency, uint8_t openDrainFrequency, uint8_t i2cOpenDrainFrequency, uint8_t driveStrength)

Initializes the I3C controller.

This function initializes the I3C peripheral and must be called successfully before any other I3C-related API is used.

Note

  • This function must be called exactly once.

  • To modify the I3C configuration after initialization, use i3cSetParameters instead of reinitializing the interface.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • pushPullFrequency – The I3C SCL frequency in the push-pull phase. See I3cPushPullRate for supported values.

  • openDrainFrequency – The I3C SCL frequency in the open-drain phase. See I3cOpenDrainTransferRate for supported values.

  • i2cOpenDrainFrequency – The I2C SCL open drain frequency. See I2cTransferRate for supported values.

  • driveStrength – The drive strength configuration for the I3C pads. See I3cDriveStrength for supported values.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cSetParameters(uint16_t id, uint8_t pushPullFrequency, uint8_t openDrainFrequency, uint8_t i2cOpenDrainFrequency, uint8_t driveStrength)

Sets the I3C bus parameters.

This function updates the I3C bus parameters after the I3C interface has been successfully initialized using i3cControllerInit. It allows runtime reconfiguration of the I3C without requiring a full deinitialization or reinitialization of the peripheral.

Note

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • pushPullFrequency – The I3C SCL frequency in the push-pull phase. See I3cPushPullRate for supported values.

  • openDrainFrequency – The I3C SCL frequency in the open-drain phase. See I3cOpenDrainTransferRate for supported values.

  • i2cOpenDrainFrequency – The I2C SCL open drain frequency. See I2cTransferRate for supported values.

  • driveStrength – The drive strength configuration for the I3C pads. See I3cDriveStrength for supported values.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cInitBus(uint16_t id, std::vector<I3cTargetInfo> targets = {})

Initializes the I3C bus.

By default, the Supernova acting as the controller issues the RSTDAA followed by the ENTDAA CCCs to discover I3C targets on the bus and automatically assign dynamic addresses.

Optionally, a table of target devices can be provided to control the bus initialization process. When the targets parameter is provided, the controller uses this information to:

  • Assign a specific dynamic address to a known I3C target.

  • Register legacy I2C devices on the bus, which do not respond to the ENTDAA CCC.

This allows mixed I3C/I2C buses to be initialized correctly and enables deterministic dynamic address assignment for selected targets.

If targets is empty, the controller relies solely on the standard I3C discovery mechanism (RSTDAA + ENTDAA) and only I3C targets responding to ENTDAA will be detected.

Note

  • This function must be called exactly once.

  • To modify the I3C configuration after initialization, use i3cSetParameters instead of reinitializing the interface.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • targets – A vector containing information about the target devices connected to the I3C bus. See I3cTargetInfo for valid table entry format.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cResetBus(uint16_t id)

Resets the I3C bus.

Issue the RSTDAA CCC and clear the target device table.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cGetDeviceTable(uint16_t id)

Get the target device table stored internally in the Supernova.

Retrieves the current I3C target device table maintained internally by the Supernova firmware.

The table contains information about the targets discovered or configured on the I3C bus, such as dynamic address, static address (if available), PID (if retrieved), and other relevant attributes.

This function does not perform any bus transaction. It only queries the internal device table maintained by the firmware.

Note

  • The returned table reflects the current internal state of the Supernova.

  • The content of the table depends on previous operations such as ENTDAA, SETDASA, SETAASA, GETPID, etc.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cSetTargetDeviceConfiguration(uint16_t id, uint8_t address, I3cTargetConfiguration targetConfiguration)

Changes de configuration of an I3C target given by a dictionary containing the new target configuration.

Updates the configuration of a target device stored in the Supernova’s internal I3C device table.

Note

  • The target must exist in the internal device table prior to calling this function.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – Target address whose configuration will be set.

  • targetConfiguration – A dictionary containing the new configuration.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cLegacyI2cWrite(uint16_t id, uint8_t address, const std::vector<uint8_t> &subAddress, const std::vector<uint8_t> &inData, I3cTransferFlags flags)

Performs an I3C write using Legacy I2C mode.

Writes data to an I2C target using a Legacy I2C Private Transfer over the I3C bus. This function issues a standard I2C write transaction (Legacy I2C mode), optionally including an internal subaddress on the target device. The transfer may also begin with a broadcast address (0x7E) if required by the higher-level protocol being implemented.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The static address of the I2C target.

  • subAddress – The optional sub-address to write to.

  • inData – The data to be written to the device.

  • flags – Bitmask of transfer options controlling the behavior of the I3C/I2C transaction. Flags can be combined using bitwise OR. See I3cTransferFlags for supported values.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cLegacyI2cRead(uint16_t id, uint8_t address, const std::vector<uint8_t> &subAddress, uint16_t readLength, I3cTransferFlags flags)

Performs an I3C read using Legacy I2C mode.

Reads data from an I2C target using a Legacy I2C Private Transfer over the I3C bus. This function performs a standard I2C read operation (Legacy I2C mode). Optionally, a subaddress may be written first to select a register or memory location prior to performing the read.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The static address of the I2C target.

  • subAddress – The optional sub-address to write to.

  • readLength – The length of data to be read.

  • flags – Bitmask of transfer options controlling the behavior of the I3C/I2C transaction. Flags can be combined using bitwise OR. See I3cTransferFlags for supported values.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cSdrWrite(uint16_t id, uint8_t address, const std::vector<uint8_t> &subAddress, const std::vector<uint8_t> &inData, I3cTransferFlags flags)

Performs an I3C write in SDR mode.

Writes data to an I3C device or to a group of I3C targets through an I3C Private Transfer in SDR mode. Optionally, the internal subaddress of the target memory where the data is written to can be set, especially when writing to a single target.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the I3C target, or the group address.

  • subAddress – The optional sub-address to write to.

  • inData – The data to be written to the device.

  • flags – Bitmask of transfer options controlling the behavior of the I3C/I2C transaction. Flags can be combined using bitwise OR. See I3cTransferFlags for supported values.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cSdrRead(uint16_t id, uint8_t address, const std::vector<uint8_t> &subAddress, uint16_t readLength, I3cTransferFlags flags)

Performs an I3C read in SDR mode.

Reads data from an I3C target through an I3C Private Read transfer in SDR mode. Optionally, the internal subaddress of the target where the data is read from can be also set.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the I3C target.

  • subAddress – The optional sub-address to write to.

  • readLength – The length of data to be read.

  • flags – Bitmask of transfer options controlling the behavior of the I3C/I2C transaction. Flags can be combined using bitwise OR. See I3cTransferFlags for supported values.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cHdrDdrWrite(uint16_t id, uint8_t address, uint8_t command, const std::vector<uint8_t> &inData)

Performs an I3C write in HDR-DDR mode.

Writes data to an I3C target using an HDR-DDR Private Transfer. If the bus is currently operating in SDR mode, this function will automatically issue the ENTHDR0 CCC before starting the HDR-DDR transfer.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the I3C target.

  • command – The HDR-DDR command byte. Must be in the range [0x00, 0x7F].

  • inData – The data payload to be written. The payload length must be a multiple of 2.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cHdrDdrRead(uint16_t id, uint8_t address, uint8_t command, uint16_t readLength)

Performs an I3C read in HDR-DDR mode.

Reads data from an I3C target using an HDR-DDR Private Read Transfer. If the bus is currently operating in SDR mode, this function will automatically issue the ENTHDR0 CCC before starting the HDR-DDR transfer.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the I3C target.

  • command – The HDR-DDR command byte. Must be in the range [0x80, 0xFF].

  • readLength – The length of the data to read. Must be a multiple of 2.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cTargetResetPattern(uint16_t id)

Emit the Target Reset Pattern to trigger the default or configured reset action on the I3C targets.

Emits the I3C Target Reset Pattern on the bus.

All targets that recognize the Target Reset Pattern and support reset functionality will perform the corresponding reset action.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • The reset action executed depends on the most recent RSTACT configuration, or the default reset behavior if none was configured.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cHdrExitPattern(uint16_t id)

Issue the HDR Exit Pattern to leave the current HDR mode and exit back to SDR mode.

Emits the I3C HDR Exit Pattern on the bus.

This pattern terminates the current High Data Rate (HDR) mode and forces all participating devices to return to Standard Data Rate (SDR) mode, as defined by the I3C specification.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • It must be issued while the bus is operating in HDR mode.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccTransfer(uint16_t id, uint8_t address, I3cTransferDirection direction, I3cTransferMode mode, bool nonStop, I3cCccType type, uint8_t payloadLength, CCC ccc, uint8_t definingByte, const std::vector<uint8_t> &inData = std::vector<uint8_t>{})

Perform a CCC transfer.

Sends a Common Command Code (CCC) to one or more I3C targets.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – Target dynamic address on the I3C bus.

  • direction – Data transfer direction (read or write). See I3cTransferDirection for supported values.

  • mode – I3C transfer mode used for the transaction. See I3cTransferMode for supported values.

  • nonStop – If true, the transfer will not issue a STOP condition after completion.

  • type – Type of CCC command, indicating whether a defining byte is used. See I3cCccType for supported values.

  • payloadLength – Length in bytes of the CCC payload.

  • ccc – The specific CCC to send to the target. See CCC for supported values.

  • definingByte – Optional defining byte associated with the CCC, if required by the command type.

  • inData – The data to be transferred for write transfers.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccRSTDAA(uint16_t id)

Reset Dynamic Address Assignment (RSTDAA CCC).

Sends the RSTDAA (Reset Dynamic Address Assignment) Common Command Code (CCC) in broadcast mode.

Unlike the i3cResetBus method, the target device table is not cleared. After successful completion, the SDK updates the internal target device table by clearing only the stored dynamic addresses of all entries. The device information remains present in the table, allowing a new Dynamic Address Assignment (DAA) procedure to be performed without losing device metadata.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • After issuing RSTDAA, a new Dynamic Address Assignment (DAA) procedure must be executed before communicating with targets using dynamic addresses.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENTDAA(uint16_t id)

Enter Dynamic Address Assignment procedure (ENTDAA CCC).

Sends the ENTDAA (Enter Dynamic Address Assignment) Common Command Code (CCC) in broadcast mode to initiate the Dynamic Address Assignment (DAA) procedure.

All unaddressed I3C targets participate in the arbitration process and are sequentially assigned a unique dynamic address by the controller.

During the procedure, each discovered target is identified and added to the internal target device table together with its assigned dynamic address and associated device information.

The procedure continues until no additional targets respond or the maximum number of supported targets is reached.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETDASA(uint16_t id, uint8_t staticAddress, uint8_t dynamicAddress)

Assign a Dynamic Address to a target using its Static Address (SETDASA CCC).

Sends the SETDASA (Set Dynamic Address from Static Address) Common Command Code (CCC) in direct mode to the target identified by its static address.

The target device at staticAddress is instructed to adopt the specified dynamicAddress. Upon successful completion and acknowledgment by the target, the SDK adds a new entry to the internal target device table containing the assigned dynamic address and associated device information.

Prior to issuing the CCC, the SDK validates that:

  • The requested dynamic address is not reserved.

  • The dynamic address is not already in use by another target.

  • There is available space in the internal target device table.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • staticAddress – Static address of the target device.

  • dynamicAddress – Dynamic address to assign to the target.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETAASA(uint16_t id, const std::vector<uint8_t> &staticAddresses)

Set static address as dynamic address (SETAASA CCC).

Sends the SETAASA (Set All Addresses to Static Address) Common Command Code (CCC) in broadcast mode.

Targets that support the SETAASA CCC adopt their own static address as their dynamic address.

The staticAddresses parameter specifies the static addresses of the targets expected to process this command. After successful completion, the SDK adds a new entry to the internal target device table for each responding device, using its static address as its dynamic address.

Prior to issuing the CCC, the SDK validates that:

  • None of the provided addresses are reserved.

  • There is sufficient space in the internal target device table to accommodate all new devices.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • Only targets that support the SETAASA CCC will respond and adopt their static address as dynamic.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • staticAddresses – Array of static addresses of those I3C targets that support SETAASA CCC. If the SETAASA CCC ends successfully, new devices are added to the target device table.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETNEWDA(uint16_t id, uint8_t oldDynamicAddress, uint8_t newDynamicAddress)

Set a new Dynamic Address for a target (SETNEWDA CCC).

Sends the SETNEWDA (Set New Dynamic Address) Common Command Code (CCC) in direct mode to the specified target.

The target identified by oldDynamicAddress is instructed to change its dynamic address to newDynamicAddress.

If the command completes successfully and is acknowledged by the target, the SDK updates the internal target device table by replacing the stored dynamic address with the new value.

Validation of newDynamicAddress is performed before issuing the CCC to ensure that it is not a reserved address and that it is not already assigned to another target on the bus.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • oldDynamicAddress – The dynamic address of the target.

  • newDynamicAddress – The new dynamic address for the target.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENECBroadcast(uint16_t id, uint8_t events)

Enable events for all targets (ENEC broadcast CCC).

Sends the ENEC (Enable Events Command) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus.

Targets that do not support a specific event or the ENEC CCC may ignore the corresponding bits.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • events – Bitmask of I3C events to be enabled. Possible events are defined on I3CEvent. Multiple events may be combined using bitwise OR.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENECDirect(uint16_t id, uint8_t address, uint8_t events)

Enable specific events on a single target (ENEC direct CCC).

Sends the ENEC (Enable Events Command) Common Command Code (CCC) in direct mode to the specified I3C target.

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

  • events – Bitmask of I3C events to be enabled. Possible events are defined on I3CEvent. Multiple events may be combined using bitwise OR.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccDISECBroadcast(uint16_t id, uint8_t events)

Disable events for all targets (DISEC broadcast CCC).

Sends the DISEC (Disable Events) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus.

All targets capable of processing broadcast CCCs will receive and apply the command. Devices that do not support a given event may ignore the corresponding bit.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • events – Bitmask of I3C events to be disabled. Possible events are defined on I3CEvent. Multiple events may be combined using bitwise OR.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccDISECDirect(uint16_t id, uint8_t address, uint8_t events)

Disable specific events on a single target (DISEC direct CCC).

Sends the DISEC (Disable Events) Common Command Code (CCC) in direct mode to a single I3C target identified by its dynamic address.

Only the addressed target processes this command. Unlike the broadcast variant, other devices on the bus are not affected.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

  • events – Bitmask of I3C events to be disabled. Possible events are defined on I3CEvent. Multiple events may be combined using bitwise OR.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENTAS0Broadcast(uint16_t id)

Sends the Broadcast ENTAS0 CCC.

Sends the ENTAS0 (Enter Activity State 0) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus. This command instructs all targets to enter Activity State 0 (normal operating mode).

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENTAS1Broadcast(uint16_t id)

Sends the Broadcast ENTAS1 CCC.

Sends the ENTAS1 (Enter Activity State 1) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus. This command instructs all targets to enter Activity State 1 (limited operating mode).

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENTAS2Broadcast(uint16_t id)

Sends the Broadcast ENTAS2 CCC.

Sends the ENTAS2 (Enter Activity State 2) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus. This command instructs all targets to enter Activity State 2 (slower operating mode).

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENTAS3Broadcast(uint16_t id)

Sends the Broadcast ENTAS3 CCC.

Sends the ENTAS3 (Enter Activity State 3) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus. This command instructs all targets to enter Activity State 3 (lowest activity / sleep mode).

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENTAS0Direct(uint16_t id, uint8_t address)

Sends the Direct Write ENTAS0 CCC.

Sends the ENTAS0 (Enter Activity State 0) Common Command Code (CCC) in direct mode to the specified target. This command instructs the addressed target to enter Activity State 0 (normal operating mode).

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is configured as an I3C controller.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENTAS1Direct(uint16_t id, uint8_t address)

Sends the Direct Write ENTAS1 CCC.

Sends the ENTAS1 (Enter Activity State 1) Common Command Code (CCC) in direct mode to the specified target. This command instructs the addressed target to enter Activity State 1 (limited operating mode).

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is configured as an I3C controller.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENTAS2Direct(uint16_t id, uint8_t address)

Sends the Direct Write ENTAS2 CCC.

Sends the ENTAS2 (Enter Activity State 2) Common Command Code (CCC) in direct mode to the specified target. This command instructs the addressed target to enter Activity State 2 (slower operating mode).

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is configured as an I3C controller.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccENTAS3Direct(uint16_t id, uint8_t address)

Sends the Direct Write ENTAS3 CCC.

Sends the ENTAS3 (Enter Activity State 3) Common Command Code (CCC) in direct mode to the specified target. This command instructs the addressed target to enter Activity State 3 (lowest activity / sleep mode).

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is configured as an I3C controller.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETMWLBroadcast(uint16_t id, uint16_t mwl)

Set the Maximum Write Length (MWL) for all targets (SETMWL broadcast CCC).

Sends the SETMWL (Set Maximum Write Length) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus.

All targets capable of processing broadcast CCCs will receive and apply the command.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • The configured value applies to all targets that support the SETMWL CCC.

  • Devices that do not support this CCC may ignore the command.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • mwl – The Maximum Write Length.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETMWLDirect(uint16_t id, uint8_t address, uint16_t mwl)

Set the Maximum Write Length (MWL) for a specific target (SETMWL direct CCC).

Sends the SETMWL (Set Maximum Write Length) Common Command Code (CCC) in direct mode to the specified I3C target.

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • A return value of SUCCESS indicates that the CCC was transmitted successfully and acknowledged by the addressed target.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

  • mwl – The Maximum Write Length for the target.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETMRLBroadcast(uint16_t id, uint16_t mrl, std::optional<uint8_t> ibiLength = std::nullopt)

Set the Maximum Read Length (MRL) for all targets (SETMRL broadcast CCC).

Sends the SETMRL (Set Maximum Read Length) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus.

If ibiLength is provided, the CCC includes the optional IBI payload length field and configures the maximum IBI payload size supported by the targets. If ibiLength is not set, the CCC is sent without the IBI payload length field and the existing IBI payload configuration remains unchanged.

All targets capable of processing broadcast CCCs will receive and apply the command according to the I3C specification.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • The IBI payload length field is included in the CCC only when ibiLength contains a value.

  • Devices that do not support the optional IBI length field may ignore it.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • mrl – The Maximum Read Length.

  • ibiLength – (optional) When set, configures the maximum IBI payload size for the target; when not set, no IBI payload length is configured.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETMRLDirect(uint16_t id, uint8_t address, uint16_t mrl, std::optional<uint8_t> ibiLength = std::nullopt)

Set the Maximum Read Length (MRL) for a specific target (SETMRL direct CCC).

Sends the SETMRL (Set Maximum Read Length) Common Command Code (CCC) in direct mode to the specified I3C target.

If ibiLength is provided, the CCC includes the optional IBI payload length field and configures the maximum IBI payload size supported by the target. If ibiLength is not set, the CCC is sent without the IBI payload length field and the target IBI payload configuration remains unchanged.

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • The IBI payload length field is included in the CCC only when ibiLength contains a value.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

  • mrl – The Maximum Read Length for the target.

  • ibiLength – (optional) When set, configures the maximum IBI payload size for the target; when not set, no IBI payload length is configured.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccGETMWL(uint16_t id, uint8_t address)

Get the Maximum Write Length (MWL) supported by the target (GETMWL CCC).

Sends the GETMWL (Get Maximum Write Length) Common Command Code (CCC) in direct mode to the specified I3C target.

The retrieved Maximum Write Length value is delivered via the response callback.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccGETMRL(uint16_t id, uint8_t address)

Get the Maximum Read Length (MRL) supported by the target (GETMRL CCC).

Sends the GETMRL (Get Maximum Read Length) Common Command Code (CCC) in direct mode to the specified I3C target.

If the target supports In-Band Interrupt (IBI) payloads, it appends an additional byte to the response indicating the maximum supported IBI payload length.

The retrieved Maximum Read Length (and optional IBI payload length) is delivered via the response callback.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccGETPID(uint16_t id, uint8_t address)

Gets the PID of one target (GETPID CCC).

Sends the GETPID Common Command Code (CCC) in direct read mode to the specified I3C target.

The retrieved Provisional ID is delivered via the response callback.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccGETBCR(uint16_t id, uint8_t address)

Get the Bus Characteristic Register (BCR) value of the target (GETBCR CCC).

Sends the GETBCR (Get Bus Characteristic Register) Common Command Code (CCC) in direct mode to the specified I3C target.

The retrieved BCR value is delivered via the response callback.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccGETDCR(uint16_t id, uint8_t address)

Get the Device Characteristic Register (DCR) value of the target (GETDCR CCC).

Sends the GETDCR (Get Device Characteristic Register) Common Command Code (CCC) in direct mode to the specified I3C target.

The retrieved DCR value is delivered via the response callback.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccGETMXDS(uint16_t id, uint8_t targetAddress)

Get the Maximum Data Speed (MXDS) from a target (GETMXDS CCC).

Sends the GETMXDS (Get Maximum Data Speed) Common Command Code (CCC) in direct read mode to the specified I3C target. Only format 1 is supported for this CCC (without defining byte).

The retrieved Maximum Data Speed data is delivered via the response callback.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • targetAddress – The address of the target device from which to get the MXDS.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccGETXTIME(uint16_t id, uint8_t targetAddress)

Get the Exchange Timing Support (XTIME) from a target (GETXTIME CCC).

Sends the GETXTIME (Get Exchange Timing Support) Common Command Code (CCC) in direct read mode to the specified I3C target.

The retrieved Exchange Timing data is delivered via the response callback.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • targetAddress – The address of the target device from which to get the XTIME data.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccGETCAPS(uint16_t id, uint8_t targetAddress, std::optional<uint8_t> defByte = std::nullopt)

Get the Optional Feature Capabilities (CAPS) from a target (GETCAPS CCC).

Sends the GETCAPS (Get Optional Feature Capabilities) Common Command Code (CCC) in direct read mode to the specified I3C target.

Two formats of the GETCAPS CCC are supported:

  • Format 1: If defByte is not provided, the command is issued without a defining byte and the target returns its default CAPS data.

  • Format 2: If defByte is provided, it is transmitted as the defining byte, and the target returns the CAPS data corresponding to that definition.

The retrieved Optional Feature Capabilities data is delivered via the response callback.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • targetAddress – The address of the target device from which to get the CAPS.

  • defByte – The defining byte for the GETCAPS Format 2 version of the CCC. If not provided, the default value is None and it is assumed the Format 1 of the CCC.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccGETSTATUS(uint16_t id, uint8_t targetAddress, std::optional<uint8_t> defByte = std::nullopt)

Gets the STATUS from a target device on the I3C bus (GETSTATUS CCC).

Sends the GETSTATUS Common Command Code (CCC) in direct read mode to the specified I3C target.

Two formats of the GETSTATUS CCC are supported:

  • Format 1: If defByte is not provided, the command is issued without a defining byte and the target returns its default STATUS data.

  • Format 2: If defByte is provided, it is transmitted as the defining byte, and the target returns the STATUS data corresponding to that definition.

The retrieved STATUS data is delivered via the response callback.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • targetAddress – The dynamic address of the target device from which to get the STATUS.

  • defByte – The defining byte for the GETSTATUS Format 2 version of the CCC. If not provided, the default value is None and it is assumed the Format 1 of the CCC.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETXTIMEBroadcast(uint16_t id, uint8_t subCmdByte, const std::optional<std::vector<uint8_t>> &data = std::nullopt)

Set the exchange timing information for all targets (SETXTIME broadcast CCC).

Sends the SETXTIME (Set Exchange Timing Information) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus.

All targets capable of processing broadcast CCCs will receive and apply the command.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • The configured value applies to all targets that support the SETXTIME CCC.

  • Devices that do not support this CCC may ignore the command.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • subCmdByte – The sub-command byte for the SETXTIME command.

  • data – Additional data for the SETXTIME command, default is an empty list.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETXTIMEDirect(uint16_t id, uint8_t targetAddress, uint8_t subCmdByte, const std::optional<std::vector<uint8_t>> &data = std::nullopt)

Set the exchange timing information for a specific target (SETXTIME direct CCC).

Sends the SETXTIME (Set Exchange Timing Information) Common Command Code (CCC) in direct mode to the specified I3C target.

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • A return value of SUCCESS indicates that the CCC was transmitted successfully and acknowledged by the addressed target.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • targetAddress – The dynamic address of the target device.

  • subCmdByte – The sub-command byte for the SETXTIME command.

  • data – Additional data byte for the SETXTIME command, default is empty.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETBUSCONBroadcast(uint16_t id, uint8_t context, const std::optional<std::vector<uint8_t>> &data = std::nullopt)

Set the bus context for all targets (SETBUSCON broadcast CCC).

Sends the SETBUSCON (Set Bus Context) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus.

All targets capable of processing broadcast CCCs will receive and apply the command.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • The configured value applies to all targets that support the SETBUSCON CCC.

  • Devices that do not support this CCC may ignore the command.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • context – The bus context value to set for the targets.

  • data – Additional data for the SETBUSCON command.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccRSTACTBroadcast(uint16_t id, I3cTargetResetDefByte defByte)

Emits the RSTACT Broadcast CCC to configure the next Target Reset action on all I3C targets.

Sends the RSTACT (Reset Action) Common Command Code (CCC) in broadcast mode.

The RSTACT CCC and the Target Reset Pattern are emitted within the same frame. All targets that support the specified reset action execute it upon receiving the command and the associated reset pattern.

This operation affects all I3C targets on the bus that support RSTACT.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

  • Devices that do not support the specified reset action may ignore the command.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • defByte – The defining byte specifying the reset action to be performed. See I3cTargetResetDefByte for supported values.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccRSTACTDirect(uint16_t id, uint8_t targetAddress, I3cTargetResetDefByte defByte, I3cTransferDirection direction)

Sends the Direct Write or Direct Read RSTACT CCC.

Sends the RSTACT (Reset Action) Common Command Code (CCC) in direct mode to the specified target.

The behavior depends on the selected direction:

  • Write transfer: The defByte specifies the reset action to be configured for the addressed target. The Target Reset Pattern is emitted within the same frame, causing the target to execute the specified reset action.

  • Read transfer: The command retrieves the reset recovery timing information from the addressed target, as defined by the I3C specification. The retrieved value is delivered via the response callback.

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is configured as an I3C controller.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • targetAddress – The dynamic address of the target device.

  • defByte – The defining byte specifying the reset action to be performed. See I3cTargetResetDefByte for supported values.

  • direction – Indicates whether the command is a read or write transfer. See I3cTransferDirection for supported values.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccRSTGRPABroadcast(uint16_t id)

Sends the Broadcast RSTGRPA CCC.

Sends the RSTGRPA (Reset Group Address) Common Command Code (CCC) in broadcast mode to all I3C targets on the bus. This command instructs all targets to clear their group address assignments.

Note

  • This function is valid only when the host is initialized as an I3C controller with i3cControllerInit.

Parameters:

id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccRSTGRPADirect(uint16_t id, uint8_t address)

Sends the Direct Write RSTGRPA CCC.

Sends the RSTGRPA (Reset Group Address) Common Command Code (CCC) in direct mode to the specified target. This command instructs the addressed target to clear its group address assignment.

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is configured as an I3C controller.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • address – The dynamic address of the target device.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.

uint16_t i3cCccSETGRPADirect(uint16_t id, uint8_t targetAddress, uint8_t grpa)

Sends the Direct Write SETGRPA CCC.

Sends the SETGRPA (Set Group Address) Common Command Code (CCC) in direct mode to the specified target. This command assigns a group address to the addressed target.

Only the addressed target processes this command. Other devices on the bus are not affected.

Note

  • This function is valid only when the host is configured as an I3C controller.

Parameters:
  • id – Command Id to identify the request. Values from 1 to 65535 are valid. 0 is reserved for notifications.

  • targetAddress – The dynamic address of the target device.

  • grpa – The group address assignment byte to send to the target.

Return values:
  • SUCCESS – The command was successfully sent to the host adapter.

  • SDK_ERROR_DISCONNECT – The device was disconnected or became unavailable during the operation.