mirror of
https://gitee.com/xiaohuolufeihua/bizhang_-obav.git
synced 2026-05-21 01:12:11 +00:00
Adding BatMon smart battery as a module and refactoring SMBUS based SBS 1.1 spec to a library
This commit is contained in:
@@ -640,7 +640,13 @@ int I2CSPIDriverBase::module_custom_method(const BusCLIArguments &cli, BusInstan
|
||||
void I2CSPIDriverBase::print_status()
|
||||
{
|
||||
bool is_i2c_bus = _bus_option == I2CSPIBusOption::I2CExternal || _bus_option == I2CSPIBusOption::I2CInternal;
|
||||
PX4_INFO("Running on %s Bus %i", is_i2c_bus ? "I2C" : "SPI", _bus);
|
||||
|
||||
if (is_i2c_bus) {
|
||||
PX4_INFO("Running on I2C Bus %i, Address 0x%02X", _bus, _i2c_address);
|
||||
|
||||
} else {
|
||||
PX4_INFO("Running on SPI Bus %i", _bus);
|
||||
}
|
||||
}
|
||||
|
||||
void I2CSPIDriverBase::request_stop_and_wait()
|
||||
|
||||
Reference in New Issue
Block a user