mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-27 03:23:33 +08:00
src/platforms: move all headers to platforms/common/include/px4_platform_common
and remove the px4_ prefix, except for px4_config.h.
command to update includes:
for k in app.h atomic.h cli.h console_buffer.h defines.h getopt.h i2c.h init.h log.h micro_hal.h module.h module_params.h param.h param_macros.h posix.h sem.h sem.hpp shmem.h shutdown.h tasks.h time.h workqueue.h; do for i in $(grep -rl 'include <px4_'$k src platforms boards); do sed -i 's/#include <px4_'$k'/#include <px4_platform_common\/'$k/ $i; done; done
for in $(grep -rl 'include <px4_config.h' src platforms boards); do sed -i 's/#include <px4_config.h/#include <px4_platform_common\/px4_config.h'/ $i; done
Transitional headers for submodules are added (px4_{defines,log,time}.h)
This commit is contained in:
@@ -44,7 +44,7 @@
|
||||
#include <lib/drivers/accelerometer/PX4Accelerometer.hpp>
|
||||
#include <lib/drivers/gyroscope/PX4Gyroscope.hpp>
|
||||
#include <perf/perf_counter.h>
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
#include <px4_platform_common/px4_work_queue/ScheduledWorkItem.hpp>
|
||||
|
||||
class ADIS16477 : public device::SPI, public px4::ScheduledWorkItem
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
#include <lib/drivers/accelerometer/PX4Accelerometer.hpp>
|
||||
#include <lib/drivers/gyroscope/PX4Gyroscope.hpp>
|
||||
#include <perf/perf_counter.h>
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
#include <px4_platform_common/px4_work_queue/ScheduledWorkItem.hpp>
|
||||
|
||||
// TODO : This is a copy of the NuttX CRC32 table
|
||||
|
||||
@@ -36,8 +36,8 @@
|
||||
* Driver for the Bosch BMA 180 MEMS accelerometer connected via SPI.
|
||||
*/
|
||||
|
||||
#include <px4_config.h>
|
||||
#include <px4_defines.h>
|
||||
#include <px4_platform_common/px4_config.h>
|
||||
#include <px4_platform_common/defines.h>
|
||||
#include <ecl/geo/geo.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
#include <drivers/device/spi.h>
|
||||
#include <ecl/geo/geo.h>
|
||||
#include <lib/perf/perf_counter.h>
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
#include <px4_platform_common/px4_work_queue/ScheduledWorkItem.hpp>
|
||||
|
||||
#define DIR_READ 0x80
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
#include <ecl/geo/geo.h>
|
||||
#include <lib/conversion/rotation.h>
|
||||
#include <lib/perf/perf_counter.h>
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
#include <px4_platform_common/px4_work_queue/ScheduledWorkItem.hpp>
|
||||
|
||||
#define DIR_READ 0x80
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include <lib/drivers/accelerometer/PX4Accelerometer.hpp>
|
||||
#include <lib/drivers/gyroscope/PX4Gyroscope.hpp>
|
||||
#include <perf/perf_counter.h>
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
#include <px4_platform_common/px4_work_queue/ScheduledWorkItem.hpp>
|
||||
#include <systemlib/conversions.h>
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
#include <drivers/device/spi.h>
|
||||
#include <lib/drivers/gyroscope/PX4Gyroscope.hpp>
|
||||
#include <perf/perf_counter.h>
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
#include <px4_platform_common/px4_work_queue/ScheduledWorkItem.hpp>
|
||||
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
|
||||
#include "FXOS8701CQ.hpp"
|
||||
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
|
||||
/**
|
||||
* Local functions in support of the shell command.
|
||||
|
||||
@@ -40,9 +40,9 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include <px4_config.h>
|
||||
#include <px4_log.h>
|
||||
#include <px4_time.h>
|
||||
#include <px4_platform_common/px4_config.h>
|
||||
#include <px4_platform_common/log.h>
|
||||
#include <px4_platform_common/time.h>
|
||||
#include <lib/perf/perf_counter.h>
|
||||
#include <drivers/drv_hrt.h>
|
||||
|
||||
|
||||
@@ -40,8 +40,8 @@
|
||||
* based on the mpu9250 driver
|
||||
*/
|
||||
|
||||
#include <px4_config.h>
|
||||
#include <px4_time.h>
|
||||
#include <px4_platform_common/px4_config.h>
|
||||
#include <px4_platform_common/time.h>
|
||||
#include <lib/ecl/geo/geo.h>
|
||||
#include <lib/perf/perf_counter.h>
|
||||
#include <systemlib/conversions.h>
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
* I2C interface for ICM20948
|
||||
*/
|
||||
|
||||
#include <px4_config.h>
|
||||
#include <px4_platform_common/px4_config.h>
|
||||
#include <drivers/device/i2c.h>
|
||||
#include <drivers/drv_device.h>
|
||||
|
||||
|
||||
@@ -39,8 +39,8 @@
|
||||
* based on the mpu9250 driver
|
||||
*/
|
||||
|
||||
#include <px4_config.h>
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/px4_config.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
#include <lib/perf/perf_counter.h>
|
||||
#include <lib/systemlib/conversions.h>
|
||||
#include <board_config.h>
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
#include <lib/conversion/rotation.h>
|
||||
#include <lib/drivers/gyroscope/PX4Gyroscope.hpp>
|
||||
#include <perf/perf_counter.h>
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
#include <px4_platform_common/px4_work_queue/ScheduledWorkItem.hpp>
|
||||
|
||||
#define L3GD20_DEVICE_PATH "/dev/l3gd20"
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
|
||||
#include "LSM303D.hpp"
|
||||
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
|
||||
/**
|
||||
* Local functions in support of the shell command.
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
#include <lib/drivers/device/spi.h>
|
||||
#include <lib/ecl/geo/geo.h>
|
||||
#include <lib/perf/perf_counter.h>
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
#include <px4_platform_common/px4_work_queue/ScheduledWorkItem.hpp>
|
||||
#include <systemlib/conversions.h>
|
||||
#include <systemlib/px4_macros.h>
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
* I2C interface for AK8963
|
||||
*/
|
||||
|
||||
#include <px4_config.h>
|
||||
#include <px4_platform_common/px4_config.h>
|
||||
#include <drivers/device/i2c.h>
|
||||
#include <drivers/drv_device.h>
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
#include <lib/drivers/accelerometer/PX4Accelerometer.hpp>
|
||||
#include <lib/drivers/gyroscope/PX4Gyroscope.hpp>
|
||||
#include <lib/ecl/geo/geo.h>
|
||||
#include <px4_getopt.h>
|
||||
#include <px4_platform_common/getopt.h>
|
||||
#include <px4_platform_common/px4_work_queue/ScheduledWorkItem.hpp>
|
||||
#include <systemlib/conversions.h>
|
||||
#include <systemlib/px4_macros.h>
|
||||
|
||||
Reference in New Issue
Block a user