mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-27 07:43:33 +08:00
HMC5883: Always report as internal sensor in SPI mode, since the sensor is fixed to the autopilot assembly.
This commit is contained in:
@@ -138,15 +138,12 @@ HMC5883_SPI::ioctl(unsigned operation, unsigned &arg)
|
|||||||
switch (operation) {
|
switch (operation) {
|
||||||
|
|
||||||
case MAGIOCGEXTERNAL:
|
case MAGIOCGEXTERNAL:
|
||||||
|
/*
|
||||||
#ifdef PX4_SPI_BUS_EXT
|
* Even if this sensor is on the external SPI
|
||||||
if (_bus == PX4_SPI_BUS_EXT) {
|
* bus it is still internal to the autopilot
|
||||||
return 1;
|
* assembly, so always return 0 for internal.
|
||||||
} else
|
*/
|
||||||
#endif
|
return 0;
|
||||||
{
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
case DEVIOCGDEVICEID:
|
case DEVIOCGDEVICEID:
|
||||||
return CDev::ioctl(nullptr, operation, arg);
|
return CDev::ioctl(nullptr, operation, arg);
|
||||||
|
|||||||
Reference in New Issue
Block a user