add helper to send command to all devices
This commit is contained in:
parent
8e06b991ac
commit
8cead7ac35
@ -77,6 +77,12 @@ nag_attr static inline HAL_StatusTypeDef ds2482_1w_send_command(ds2482_t * const
|
||||
return ds2482_1w_write_byte(ds2482, command);
|
||||
}
|
||||
|
||||
nag_attr static inline HAL_StatusTypeDef ds2482_1w_send_command_all(ds2482_t * const ds2482, uint8_t command) {
|
||||
HAL_StatusTypeDef status = ds2482_1w_select_all(ds2482);
|
||||
if (status != HAL_OK) return status;
|
||||
return ds2482_1w_write_byte(ds2482, command);
|
||||
}
|
||||
|
||||
#undef nag_attr
|
||||
|
||||
#undef DS2482_1W_ROM_MATCH
|
||||
|
Loading…
x
Reference in New Issue
Block a user