AP_TemperatureSensor: fix TSYS01 warning on SITL

This commit is contained in:
Pierre Kancir 2019-04-15 11:50:05 +02:00 committed by Jacob Walser
parent 98adeafad9
commit f1f784f81d

View File

@ -15,6 +15,9 @@ static const uint8_t TSYS01_CMD_READ_ADC = 0x00;
bool TSYS01::init(uint8_t bus)
{
#if CONFIG_HAL_BOARD == HAL_BOARD_SITL
return false;
#endif
_dev = std::move(hal.i2c_mgr->get_device(bus, TSYS01_ADDR));
if (!_dev) {
printf("TSYS01 device is null!");