Nexus Embedded Platform 1.0.0
Statically assembled reusable embedded mechanisms
Loading...
Searching...
No Matches
nx_i2c_bus_clear_ops_t Struct Reference

Read-only methods for an authorized two-pin GPIO handoff. More...

#include <i2c_bus_clear.h>

Data Fields

nx_result_t(* acquire )(void *context)
nx_result_t(* drive )(void *context, bool scl_low, bool sda_low)
nx_result_t(* sample )(void *context, bool *scl_high, bool *sda_high)
nx_result_t(* wait_until )(void *context, nx_time_us_t target)
nx_result_t(* release )(void *context)

Detailed Description

Read-only methods for an authorized two-pin GPIO handoff.

Note
Task-only, one executor. acquire is a bounded, nonblocking handoff: success proves the controller, DMA, IRQs, other masters and pin users quiescent, both physical pins exclusively leased in reviewed open-drain GPIO mode, with both lines released. Failure retains no lease or effects. drive only sinks LOW or releases a pin; false never means drive HIGH. When scl_low is true, drive establishes SCL LOW before changing SDA, including a retry from unknown previous pin state. sample reads physical levels, not output latches. Methods are bounded and preserve the lease on errors. release restores the saved peripheral/pin ownership only on success; failure retains all lease/storage responsibility. wait_until uses the injected clock's finite absolute domain and reaches target or reports an error within a caller- proved finite bound, even if the clock stops. Late waits cannot qualify an expired operation. No callback may recursively operate on this session or run a transaction. The adapter must verify reviewed open-drain, pull-up, voltage and two-pin authorization facts before acquire.

Definition at line 43 of file i2c_bus_clear.h.

Field Documentation

◆ acquire

nx_result_t(* nx_i2c_bus_clear_ops_t::acquire) (void *context)

Definition at line 44 of file i2c_bus_clear.h.

◆ drive

nx_result_t(* nx_i2c_bus_clear_ops_t::drive) (void *context, bool scl_low, bool sda_low)

Definition at line 45 of file i2c_bus_clear.h.

◆ release

nx_result_t(* nx_i2c_bus_clear_ops_t::release) (void *context)

Definition at line 48 of file i2c_bus_clear.h.

◆ sample

nx_result_t(* nx_i2c_bus_clear_ops_t::sample) (void *context, bool *scl_high, bool *sda_high)

Definition at line 46 of file i2c_bus_clear.h.

◆ wait_until

nx_result_t(* nx_i2c_bus_clear_ops_t::wait_until) (void *context, nx_time_us_t target)

Definition at line 47 of file i2c_bus_clear.h.


The documentation for this struct was generated from the following file: