PX4 Firmware
PX4 Autopilot Software http://px4.io
|
Local functions in support of the shell command. More...
Functions | |
int | start (uint8_t rotation) |
Attempt to start driver on all available I2C busses. More... | |
int | start_bus (uint8_t rotation, int i2c_bus) |
Start the driver on a specific bus. More... | |
int | stop () |
Stop the driver. More... | |
int | test () |
Perform some basic functional tests on the driver; make sure we can collect data from the sensor in polled and automatic modes. More... | |
int | reset () |
Reset the driver. More... | |
int | info () |
Print a little info about the driver. More... | |
Variables | |
SF1XX * | g_dev |
Local functions in support of the shell command.
int sf1xx::info | ( | ) |
Print a little info about the driver.
Definition at line 775 of file sf1xx.cpp.
References SF1XX::print_info().
Referenced by sf1xx_main().
int sf1xx::reset | ( | ) |
Reset the driver.
Definition at line 747 of file sf1xx.cpp.
References fd, SF1XX::ioctl(), px4_close(), px4_open(), SENSOR_POLLRATE_DEFAULT, SENSORIOCRESET, SENSORIOCSPOLLRATE, and SF1XX_DEVICE_PATH.
Referenced by sf1xx_main().
int sf1xx::start | ( | uint8_t | rotation | ) |
Attempt to start driver on all available I2C busses.
This function will return as soon as the first sensor is detected on one of the available busses or if no sensors are detected.
Definition at line 585 of file sf1xx.cpp.
References i2c_bus_options, NUM_I2C_BUS_OPTIONS, and start_bus().
Referenced by sf1xx_main().
int sf1xx::start_bus | ( | uint8_t | rotation, |
int | i2c_bus | ||
) |
Start the driver on a specific bus.
This function only returns if the sensor is up and running or could not be detected successfully.
Definition at line 608 of file sf1xx.cpp.
References fd, g_dev, SF1XX::init(), SF1XX::ioctl(), OK, px4_close(), px4_open(), SENSOR_POLLRATE_DEFAULT, SENSORIOCSPOLLRATE, SF1XX::SF1XX(), and SF1XX_DEVICE_PATH.
Referenced by sf1xx_main(), and start().
int sf1xx::stop | ( | ) |
Stop the driver.
Stop the driver.
Definition at line 657 of file sf1xx.cpp.
References g_dev.
Referenced by sf1xx_main().
int sf1xx::test | ( | ) |
Perform some basic functional tests on the driver; make sure we can collect data from the sensor in polled and automatic modes.
Definition at line 677 of file sf1xx.cpp.
References fd, SF1XX::ioctl(), OK, px4_close(), px4_open(), SF1XX::read(), SENSOR_POLLRATE_DEFAULT, SENSORIOCSPOLLRATE, and SF1XX_DEVICE_PATH.
Referenced by sf1xx_main().
SF1XX* sf1xx::g_dev |
Definition at line 566 of file sf1xx.cpp.
Referenced by start_bus(), and stop().