Synopsis
CTL_STATUS_t ctl_transport_read_registers(CTL_TRANSPORT_t *self,
                                          int reg,
                                          int n,
                                          void *data);
Description

ctl_transport_read_registers wraps a call to the device-specific register read method read_registers of the self instance, passing the parameters through unchanged.

Whilst a client can call self's read_registers method directly, it's better style to use the wrapper function.

Return Value

ctl_transport_read_registers returns a standard status code.

Thread Safety

ctl_transport_read_registers is thread-safe if the transport self has a mutex associated with it. ctl_transport_read_registers ensures an atomic update of the register by locking the transport before writing the register and unlocking it after writing the register.