From 242182ade746a8112d8652e0068e36b8663d7a64 Mon Sep 17 00:00:00 2001 From: Daniel Agar Date: Thu, 12 Mar 2020 18:27:02 -0400 Subject: [PATCH 1/2] sensors: complete move to uORB::Subscription --- Tools/uorb_graph/create.py | 1 - src/modules/sensors/sensors.cpp | 1 - src/modules/sensors/voted_sensors_update.cpp | 101 ++++--------------- src/modules/sensors/voted_sensors_update.h | 45 +++------ 4 files changed, 34 insertions(+), 114 deletions(-) diff --git a/Tools/uorb_graph/create.py b/Tools/uorb_graph/create.py index a231e3f45752..a9210f911a79 100755 --- a/Tools/uorb_graph/create.py +++ b/Tools/uorb_graph/create.py @@ -220,7 +220,6 @@ def __init__(self, module_whitelist=[], topic_blacklist=[]): # (the expectation is that the previous matching ORB_ID() will be passed # to this, so that we can ignore it) special_cases_sub = [ - ('sensors', r'voted_sensors_update\.cpp$', r'\binitSensorClass\b\(([^,)]+)', r'^meta$'), ('listener', r'.*', None, r'^(id)$'), ('logger', r'.*', None, r'^(topic|sub\.metadata|_polling_topic_meta)$'), diff --git a/src/modules/sensors/sensors.cpp b/src/modules/sensors/sensors.cpp index d52417aa85e1..96fee8ff1f89 100644 --- a/src/modules/sensors/sensors.cpp +++ b/src/modules/sensors/sensors.cpp @@ -441,7 +441,6 @@ void Sensors::Run() sub.unregisterCallback(); } - _voted_sensors_update.deinit(); exit_and_cleanup(); return; } diff --git a/src/modules/sensors/voted_sensors_update.cpp b/src/modules/sensors/voted_sensors_update.cpp index 803ce68c4f80..62be97492e4c 100644 --- a/src/modules/sensors/voted_sensors_update.cpp +++ b/src/modules/sensors/voted_sensors_update.cpp @@ -50,6 +50,7 @@ using namespace sensors; using namespace matrix; +using math::radians; VotedSensorsUpdate::VotedSensorsUpdate(const Parameters ¶meters, bool hil_enabled) : ModuleParams(nullptr), _parameters(parameters), _hil_enabled(hil_enabled), _mag_compensator(this) @@ -86,33 +87,15 @@ int VotedSensorsUpdate::init(sensor_combined_s &raw) void VotedSensorsUpdate::initializeSensors() { - initSensorClass(ORB_ID(sensor_gyro_integrated), _gyro, GYRO_COUNT_MAX); - initSensorClass(ORB_ID(sensor_mag), _mag, MAG_COUNT_MAX); - initSensorClass(ORB_ID(sensor_accel_integrated), _accel, ACCEL_COUNT_MAX); -} - -void VotedSensorsUpdate::deinit() -{ - for (int i = 0; i < _gyro.subscription_count; i++) { - orb_unsubscribe(_gyro.subscription[i]); - } - - for (int i = 0; i < _accel.subscription_count; i++) { - orb_unsubscribe(_accel.subscription[i]); - } - - for (int i = 0; i < _mag.subscription_count; i++) { - orb_unsubscribe(_mag.subscription[i]); - } + initSensorClass(_gyro, GYRO_COUNT_MAX); + initSensorClass(_accel, ACCEL_COUNT_MAX); + initSensorClass(_mag, MAG_COUNT_MAX); } void VotedSensorsUpdate::parametersUpdate() { /* fine tune board offset */ - Dcmf board_rotation_offset = Eulerf( - M_DEG_TO_RAD_F * _parameters.board_offset[0], - M_DEG_TO_RAD_F * _parameters.board_offset[1], - M_DEG_TO_RAD_F * _parameters.board_offset[2]); + const Dcmf board_rotation_offset{Eulerf{radians(_parameters.board_offset[0]), radians(_parameters.board_offset[1]), radians(_parameters.board_offset[2])}}; _board_rotation = board_rotation_offset * get_rot_matrix((enum Rotation)_parameters.board_rotation); @@ -344,7 +327,7 @@ void VotedSensorsUpdate::parametersUpdate() sensor_mag_s report{}; - if (orb_copy(ORB_ID(sensor_mag), _mag.subscription[topic_instance], &report) != 0) { + if (!_mag.subscription[topic_instance].copy(&report)) { continue; } @@ -486,27 +469,14 @@ void VotedSensorsUpdate::accelPoll(struct sensor_combined_s &raw) float *scales[] = {_corrections.accel_scale_0, _corrections.accel_scale_1, _corrections.accel_scale_2 }; for (int uorb_index = 0; uorb_index < _accel.subscription_count; uorb_index++) { - bool accel_updated; - orb_check(_accel.subscription[uorb_index], &accel_updated); - - if (accel_updated) { - sensor_accel_integrated_s accel_report; - int ret = orb_copy(ORB_ID(sensor_accel_integrated), _accel.subscription[uorb_index], &accel_report); + sensor_accel_integrated_s accel_report; - if (ret != PX4_OK || accel_report.timestamp == 0) { - continue; //ignore invalid data - } - - if (!_accel.enabled[uorb_index]) { - continue; - } + if (_accel.enabled[uorb_index] && _accel.subscription[uorb_index].update(&accel_report)) { // First publication with data if (_accel.priority[uorb_index] == 0) { - int32_t priority = 0; - orb_priority(_accel.subscription[uorb_index], &priority); - _accel.priority[uorb_index] = (uint8_t)priority; + _accel.priority[uorb_index] = _accel.subscription[uorb_index].get_priority(); } _accel_device_id[uorb_index] = accel_report.device_id; @@ -567,27 +537,13 @@ void VotedSensorsUpdate::gyroPoll(struct sensor_combined_s &raw) float *scales[] = {_corrections.gyro_scale_0, _corrections.gyro_scale_1, _corrections.gyro_scale_2 }; for (int uorb_index = 0; uorb_index < _gyro.subscription_count; uorb_index++) { - bool gyro_updated; - orb_check(_gyro.subscription[uorb_index], &gyro_updated); - - if (gyro_updated) { - sensor_gyro_integrated_s gyro_report; + sensor_gyro_integrated_s gyro_report; - int ret = orb_copy(ORB_ID(sensor_gyro_integrated), _gyro.subscription[uorb_index], &gyro_report); - - if (ret != PX4_OK || gyro_report.timestamp == 0) { - continue; //ignore invalid data - } - - if (!_gyro.enabled[uorb_index]) { - continue; - } + if (_gyro.enabled[uorb_index] && _gyro.subscription[uorb_index].update(&gyro_report)) { // First publication with data if (_gyro.priority[uorb_index] == 0) { - int32_t priority = 0; - orb_priority(_gyro.subscription[uorb_index], &priority); - _gyro.priority[uorb_index] = (uint8_t)priority; + _gyro.priority[uorb_index] = _gyro.subscription[uorb_index].get_priority(); } _gyro_device_id[uorb_index] = gyro_report.device_id; @@ -646,27 +602,13 @@ void VotedSensorsUpdate::gyroPoll(struct sensor_combined_s &raw) void VotedSensorsUpdate::magPoll(vehicle_magnetometer_s &magnetometer) { for (int uorb_index = 0; uorb_index < _mag.subscription_count; uorb_index++) { - bool mag_updated; - orb_check(_mag.subscription[uorb_index], &mag_updated); - - if (mag_updated) { - sensor_mag_s mag_report{}; - - int ret = orb_copy(ORB_ID(sensor_mag), _mag.subscription[uorb_index], &mag_report); + sensor_mag_s mag_report; - if (ret != PX4_OK || mag_report.timestamp == 0) { - continue; //ignore invalid data - } - - if (!_mag.enabled[uorb_index]) { - continue; - } + if (_mag.enabled[uorb_index] && _mag.subscription[uorb_index].update(&mag_report)) { // First publication with data if (_mag.priority[uorb_index] == 0) { - int32_t priority = 0; - orb_priority(_mag.subscription[uorb_index], &priority); - _mag.priority[uorb_index] = (uint8_t)priority; + _mag.priority[uorb_index] = _mag.subscription[uorb_index].get_priority(); /* force a scale and offset update the first time we get data */ parametersUpdate(); @@ -678,7 +620,6 @@ void VotedSensorsUpdate::magPoll(vehicle_magnetometer_s &magnetometer) */ continue; } - } Vector3f vect(mag_report.x, mag_report.y, mag_report.z); @@ -781,25 +722,21 @@ bool VotedSensorsUpdate::checkFailover(SensorData &sensor, const char *sensor_na return false; } -void VotedSensorsUpdate::initSensorClass(const struct orb_metadata *meta, SensorData &sensor_data, - uint8_t sensor_count_max) +void VotedSensorsUpdate::initSensorClass(SensorData &sensor_data, uint8_t sensor_count_max) { int max_sensor_index = -1; for (unsigned i = 0; i < sensor_count_max; i++) { - if (orb_exists(meta, i) != 0) { - continue; - } max_sensor_index = i; - if (sensor_data.subscription[i] < 0) { - sensor_data.subscription[i] = orb_subscribe_multi(meta, i); + if (!sensor_data.advertised[i] && sensor_data.subscription[i].advertised()) { + sensor_data.advertised[i] = true; if (i > 0) { /* the first always exists, but for each further sensor, add a new validator */ if (!sensor_data.voter.add_new_validator()) { - PX4_ERR("failed to add validator for sensor %s %i", meta->o_name, i); + PX4_ERR("failed to add validator for sensor %s %i", sensor_data.subscription[i].get_topic()->o_name, i); } } } diff --git a/src/modules/sensors/voted_sensors_update.h b/src/modules/sensors/voted_sensors_update.h index 3b4e1177b976..ab89386b9e9f 100644 --- a/src/modules/sensors/voted_sensors_update.h +++ b/src/modules/sensors/voted_sensors_update.h @@ -95,11 +95,6 @@ class VotedSensorsUpdate : public ModuleParams */ void initializeSensors(); - /** - * deinitialize the object (we cannot use the destructor because it is called on the wrong thread) - */ - void deinit(); - void printStatus(); /** @@ -159,31 +154,21 @@ class VotedSensorsUpdate : public ModuleParams private: struct SensorData { - SensorData() - : last_best_vote(0), - subscription_count(0), - voter(1), - last_failover_count(0) - { - for (unsigned i = 0; i < SENSOR_COUNT_MAX; i++) { - enabled[i] = true; - subscription[i] = -1; - priority[i] = 0; - } - } - - bool enabled[SENSOR_COUNT_MAX]; - - int subscription[SENSOR_COUNT_MAX]; /**< raw sensor data subscription */ - uint8_t priority[SENSOR_COUNT_MAX]; /**< sensor priority */ - uint8_t last_best_vote; /**< index of the latest best vote */ - int subscription_count; - DataValidatorGroup voter; - unsigned int last_failover_count; + SensorData() = delete; + explicit SensorData(ORB_ID meta) : subscription{{meta, 0}, {meta, 1}, {meta, 2}, {meta, 3}} {} + + uORB::Subscription subscription[SENSOR_COUNT_MAX]; /**< raw sensor data subscription */ + DataValidatorGroup voter{1}; + unsigned int last_failover_count{0}; + uint8_t priority[SENSOR_COUNT_MAX] {}; /**< sensor priority */ + uint8_t last_best_vote{0}; /**< index of the latest best vote */ + uint8_t subscription_count{0}; + bool enabled[SENSOR_COUNT_MAX] {true, true, true, true}; + bool advertised[SENSOR_COUNT_MAX] {false, false, false, false}; matrix::Vector3f power_compensation[SENSOR_COUNT_MAX]; }; - void initSensorClass(const orb_metadata *meta, SensorData &sensor_data, uint8_t sensor_count_max); + void initSensorClass(SensorData &sensor_data, uint8_t sensor_count_max); /** * Poll the accelerometer for updated data. @@ -215,9 +200,9 @@ class VotedSensorsUpdate : public ModuleParams */ bool checkFailover(SensorData &sensor, const char *sensor_name, const uint64_t type); - SensorData _accel {}; - SensorData _gyro {}; - SensorData _mag {}; + SensorData _accel{ORB_ID::sensor_accel_integrated}; + SensorData _gyro{ORB_ID::sensor_gyro_integrated}; + SensorData _mag{ORB_ID::sensor_mag}; orb_advert_t _mavlink_log_pub{nullptr}; From 3cfae528448004f57b9dfc01df91be013e7bb0fb Mon Sep 17 00:00:00 2001 From: Daniel Agar Date: Fri, 13 Mar 2020 10:47:35 -0400 Subject: [PATCH 2/2] boards: reduce CONFIG_NFILE_DESCRIPTORS 20 -> 15 --- boards/airmind/mindpx-v2/nuttx-config/nsh/defconfig | 2 +- boards/av/x-v1/nuttx-config/nsh/defconfig | 2 +- boards/bitcraze/crazyflie/nuttx-config/nsh/defconfig | 2 +- boards/holybro/durandal-v1/nuttx-config/nsh/defconfig | 2 +- boards/holybro/durandal-v1/nuttx-config/stackcheck/defconfig | 2 +- boards/holybro/kakutef7/nuttx-config/nsh/defconfig | 2 +- boards/intel/aerofc-v1/nuttx-config/nsh/defconfig | 2 +- boards/modalai/fc-v1/nuttx-config/nsh/defconfig | 2 +- boards/mro/ctrl-zero-f7/nuttx-config/nsh/defconfig | 2 +- boards/mro/x21-777/nuttx-config/nsh/defconfig | 2 +- boards/mro/x21/nuttx-config/nsh/defconfig | 2 +- boards/nxp/fmuk66-v3/nuttx-config/nsh/defconfig | 2 +- boards/nxp/fmurt1062-v1/nuttx-config/nsh/defconfig | 2 +- boards/nxp/rddrone-uavcan146/nuttx-config/nsh/defconfig | 2 +- boards/omnibus/f4sd/nuttx-config/nsh/defconfig | 2 +- boards/px4/fmu-v2/nuttx-config/nsh/defconfig | 2 +- boards/px4/fmu-v3/nuttx-config/nsh/defconfig | 2 +- boards/px4/fmu-v3/nuttx-config/stackcheck/defconfig | 2 +- boards/px4/fmu-v4/nuttx-config/nsh/defconfig | 2 +- boards/px4/fmu-v4/nuttx-config/optimized/defconfig | 2 +- boards/px4/fmu-v4/nuttx-config/stackcheck/defconfig | 2 +- boards/px4/fmu-v4pro/nuttx-config/nsh/defconfig | 2 +- boards/px4/fmu-v5/nuttx-config/critmonitor/defconfig | 2 +- boards/px4/fmu-v5/nuttx-config/irqmonitor/defconfig | 2 +- boards/px4/fmu-v5/nuttx-config/nsh/defconfig | 2 +- boards/px4/fmu-v5/nuttx-config/optimized/defconfig | 2 +- boards/px4/fmu-v5/nuttx-config/stackcheck/defconfig | 2 +- boards/px4/fmu-v5x/nuttx-config/nsh/defconfig | 2 +- boards/px4/fmu-v5x/nuttx-config/p2_base_phy_LAN8742Ai/defconfig | 2 +- boards/uvify/core/nuttx-config/nsh/defconfig | 2 +- 30 files changed, 30 insertions(+), 30 deletions(-) diff --git a/boards/airmind/mindpx-v2/nuttx-config/nsh/defconfig b/boards/airmind/mindpx-v2/nuttx-config/nsh/defconfig index 0b535f6aff77..db7fd402ea74 100644 --- a/boards/airmind/mindpx-v2/nuttx-config/nsh/defconfig +++ b/boards/airmind/mindpx-v2/nuttx-config/nsh/defconfig @@ -94,7 +94,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/av/x-v1/nuttx-config/nsh/defconfig b/boards/av/x-v1/nuttx-config/nsh/defconfig index 6597643e77cc..ebc6bff74497 100644 --- a/boards/av/x-v1/nuttx-config/nsh/defconfig +++ b/boards/av/x-v1/nuttx-config/nsh/defconfig @@ -124,7 +124,7 @@ CONFIG_NET_TCPBACKLOG=y CONFIG_NET_TCP_WRITE_BUFFERS=y CONFIG_NET_UDP=y CONFIG_NET_UDP_CHECKSUMS=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/bitcraze/crazyflie/nuttx-config/nsh/defconfig b/boards/bitcraze/crazyflie/nuttx-config/nsh/defconfig index 0cdd78202a09..cfebe17088e1 100644 --- a/boards/bitcraze/crazyflie/nuttx-config/nsh/defconfig +++ b/boards/bitcraze/crazyflie/nuttx-config/nsh/defconfig @@ -87,7 +87,7 @@ CONFIG_MTD=y CONFIG_MTD_AT24XX=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/holybro/durandal-v1/nuttx-config/nsh/defconfig b/boards/holybro/durandal-v1/nuttx-config/nsh/defconfig index 6593d0b2f896..a4af9c38be40 100644 --- a/boards/holybro/durandal-v1/nuttx-config/nsh/defconfig +++ b/boards/holybro/durandal-v1/nuttx-config/nsh/defconfig @@ -100,7 +100,7 @@ CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_PROGMEM=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/holybro/durandal-v1/nuttx-config/stackcheck/defconfig b/boards/holybro/durandal-v1/nuttx-config/stackcheck/defconfig index fb05755b818f..9cf3b5288a81 100644 --- a/boards/holybro/durandal-v1/nuttx-config/stackcheck/defconfig +++ b/boards/holybro/durandal-v1/nuttx-config/stackcheck/defconfig @@ -101,7 +101,7 @@ CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_PROGMEM=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/holybro/kakutef7/nuttx-config/nsh/defconfig b/boards/holybro/kakutef7/nuttx-config/nsh/defconfig index 8200aa8071b5..18e74e7d6f05 100644 --- a/boards/holybro/kakutef7/nuttx-config/nsh/defconfig +++ b/boards/holybro/kakutef7/nuttx-config/nsh/defconfig @@ -96,7 +96,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/intel/aerofc-v1/nuttx-config/nsh/defconfig b/boards/intel/aerofc-v1/nuttx-config/nsh/defconfig index 55ba435bdbc4..b64511952b4e 100644 --- a/boards/intel/aerofc-v1/nuttx-config/nsh/defconfig +++ b/boards/intel/aerofc-v1/nuttx-config/nsh/defconfig @@ -77,7 +77,7 @@ CONFIG_MM_REGIONS=2 CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/modalai/fc-v1/nuttx-config/nsh/defconfig b/boards/modalai/fc-v1/nuttx-config/nsh/defconfig index 2de9df8e17cd..a41694b7c896 100644 --- a/boards/modalai/fc-v1/nuttx-config/nsh/defconfig +++ b/boards/modalai/fc-v1/nuttx-config/nsh/defconfig @@ -98,7 +98,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/mro/ctrl-zero-f7/nuttx-config/nsh/defconfig b/boards/mro/ctrl-zero-f7/nuttx-config/nsh/defconfig index f8afa8d3b490..6eeda940e6f0 100644 --- a/boards/mro/ctrl-zero-f7/nuttx-config/nsh/defconfig +++ b/boards/mro/ctrl-zero-f7/nuttx-config/nsh/defconfig @@ -98,7 +98,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/mro/x21-777/nuttx-config/nsh/defconfig b/boards/mro/x21-777/nuttx-config/nsh/defconfig index 8ab191fa8f99..2caa2d8304ca 100644 --- a/boards/mro/x21-777/nuttx-config/nsh/defconfig +++ b/boards/mro/x21-777/nuttx-config/nsh/defconfig @@ -98,7 +98,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/mro/x21/nuttx-config/nsh/defconfig b/boards/mro/x21/nuttx-config/nsh/defconfig index 6b2aa401de46..80370267b003 100644 --- a/boards/mro/x21/nuttx-config/nsh/defconfig +++ b/boards/mro/x21/nuttx-config/nsh/defconfig @@ -94,7 +94,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/nxp/fmuk66-v3/nuttx-config/nsh/defconfig b/boards/nxp/fmuk66-v3/nuttx-config/nsh/defconfig index 83870cc027a5..58bac929e69c 100644 --- a/boards/nxp/fmuk66-v3/nuttx-config/nsh/defconfig +++ b/boards/nxp/fmuk66-v3/nuttx-config/nsh/defconfig @@ -122,7 +122,7 @@ CONFIG_NET_ICMP_SOCKET=y CONFIG_NET_SOCKOPTS=y CONFIG_NET_TCP=y CONFIG_NET_UDP=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/nxp/fmurt1062-v1/nuttx-config/nsh/defconfig b/boards/nxp/fmurt1062-v1/nuttx-config/nsh/defconfig index d7765ec4d4ab..9095b8282208 100644 --- a/boards/nxp/fmurt1062-v1/nuttx-config/nsh/defconfig +++ b/boards/nxp/fmurt1062-v1/nuttx-config/nsh/defconfig @@ -169,7 +169,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/nxp/rddrone-uavcan146/nuttx-config/nsh/defconfig b/boards/nxp/rddrone-uavcan146/nuttx-config/nsh/defconfig index ad1771e00fc1..304bd78723dc 100644 --- a/boards/nxp/rddrone-uavcan146/nuttx-config/nsh/defconfig +++ b/boards/nxp/rddrone-uavcan146/nuttx-config/nsh/defconfig @@ -43,7 +43,7 @@ CONFIG_LPUART1_TXBUFSIZE=64 CONFIG_MAX_TASKS=16 CONFIG_MAX_WDOGPARMS=2 CONFIG_MOTOROLA_SREC=y -CONFIG_NFILE_DESCRIPTORS=8 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_BUILTIN_APPS=y diff --git a/boards/omnibus/f4sd/nuttx-config/nsh/defconfig b/boards/omnibus/f4sd/nuttx-config/nsh/defconfig index 66484da17cd1..51fd35b7f8c9 100644 --- a/boards/omnibus/f4sd/nuttx-config/nsh/defconfig +++ b/boards/omnibus/f4sd/nuttx-config/nsh/defconfig @@ -67,7 +67,7 @@ CONFIG_MEMSET_OPTSPEED=y CONFIG_MMCSD=y CONFIG_MMCSD_MULTIBLOCK_DISABLE=y CONFIG_MM_REGIONS=2 -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v2/nuttx-config/nsh/defconfig b/boards/px4/fmu-v2/nuttx-config/nsh/defconfig index 4ff113fea079..f238fbe55b83 100644 --- a/boards/px4/fmu-v2/nuttx-config/nsh/defconfig +++ b/boards/px4/fmu-v2/nuttx-config/nsh/defconfig @@ -94,7 +94,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v3/nuttx-config/nsh/defconfig b/boards/px4/fmu-v3/nuttx-config/nsh/defconfig index c86864606ec6..89806549a2ac 100644 --- a/boards/px4/fmu-v3/nuttx-config/nsh/defconfig +++ b/boards/px4/fmu-v3/nuttx-config/nsh/defconfig @@ -94,7 +94,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v3/nuttx-config/stackcheck/defconfig b/boards/px4/fmu-v3/nuttx-config/stackcheck/defconfig index eddf518bbcbd..4ed988dd54d8 100644 --- a/boards/px4/fmu-v3/nuttx-config/stackcheck/defconfig +++ b/boards/px4/fmu-v3/nuttx-config/stackcheck/defconfig @@ -95,7 +95,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v4/nuttx-config/nsh/defconfig b/boards/px4/fmu-v4/nuttx-config/nsh/defconfig index d106400b3aa3..03cfd7b39556 100644 --- a/boards/px4/fmu-v4/nuttx-config/nsh/defconfig +++ b/boards/px4/fmu-v4/nuttx-config/nsh/defconfig @@ -94,7 +94,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v4/nuttx-config/optimized/defconfig b/boards/px4/fmu-v4/nuttx-config/optimized/defconfig index 1f105a891984..ca5031a822dc 100644 --- a/boards/px4/fmu-v4/nuttx-config/optimized/defconfig +++ b/boards/px4/fmu-v4/nuttx-config/optimized/defconfig @@ -95,7 +95,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v4/nuttx-config/stackcheck/defconfig b/boards/px4/fmu-v4/nuttx-config/stackcheck/defconfig index b07f9cfc7ef9..7083c728db74 100644 --- a/boards/px4/fmu-v4/nuttx-config/stackcheck/defconfig +++ b/boards/px4/fmu-v4/nuttx-config/stackcheck/defconfig @@ -95,7 +95,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v4pro/nuttx-config/nsh/defconfig b/boards/px4/fmu-v4pro/nuttx-config/nsh/defconfig index ae6e3719559f..c414f8d5706b 100644 --- a/boards/px4/fmu-v4pro/nuttx-config/nsh/defconfig +++ b/boards/px4/fmu-v4pro/nuttx-config/nsh/defconfig @@ -94,7 +94,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v5/nuttx-config/critmonitor/defconfig b/boards/px4/fmu-v5/nuttx-config/critmonitor/defconfig index 6647bacd5d2f..f60da98fc91e 100644 --- a/boards/px4/fmu-v5/nuttx-config/critmonitor/defconfig +++ b/boards/px4/fmu-v5/nuttx-config/critmonitor/defconfig @@ -98,7 +98,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v5/nuttx-config/irqmonitor/defconfig b/boards/px4/fmu-v5/nuttx-config/irqmonitor/defconfig index f35cb255b224..f7cafb77a42f 100644 --- a/boards/px4/fmu-v5/nuttx-config/irqmonitor/defconfig +++ b/boards/px4/fmu-v5/nuttx-config/irqmonitor/defconfig @@ -98,7 +98,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v5/nuttx-config/nsh/defconfig b/boards/px4/fmu-v5/nuttx-config/nsh/defconfig index 23b68cc9806e..f3f299491c6f 100644 --- a/boards/px4/fmu-v5/nuttx-config/nsh/defconfig +++ b/boards/px4/fmu-v5/nuttx-config/nsh/defconfig @@ -98,7 +98,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v5/nuttx-config/optimized/defconfig b/boards/px4/fmu-v5/nuttx-config/optimized/defconfig index 2edf6f9dc752..61b634dcc45d 100644 --- a/boards/px4/fmu-v5/nuttx-config/optimized/defconfig +++ b/boards/px4/fmu-v5/nuttx-config/optimized/defconfig @@ -99,7 +99,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v5/nuttx-config/stackcheck/defconfig b/boards/px4/fmu-v5/nuttx-config/stackcheck/defconfig index 969cbabbedc1..8c47fc0aa22f 100644 --- a/boards/px4/fmu-v5/nuttx-config/stackcheck/defconfig +++ b/boards/px4/fmu-v5/nuttx-config/stackcheck/defconfig @@ -99,7 +99,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v5x/nuttx-config/nsh/defconfig b/boards/px4/fmu-v5x/nuttx-config/nsh/defconfig index 33178665eef4..413aba44eeee 100644 --- a/boards/px4/fmu-v5x/nuttx-config/nsh/defconfig +++ b/boards/px4/fmu-v5x/nuttx-config/nsh/defconfig @@ -123,7 +123,7 @@ CONFIG_NET_TCPBACKLOG=y CONFIG_NET_TCP_WRITE_BUFFERS=y CONFIG_NET_UDP=y CONFIG_NET_UDP_CHECKSUMS=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/px4/fmu-v5x/nuttx-config/p2_base_phy_LAN8742Ai/defconfig b/boards/px4/fmu-v5x/nuttx-config/p2_base_phy_LAN8742Ai/defconfig index 87bd2b98dd62..5f8cbd71360a 100644 --- a/boards/px4/fmu-v5x/nuttx-config/p2_base_phy_LAN8742Ai/defconfig +++ b/boards/px4/fmu-v5x/nuttx-config/p2_base_phy_LAN8742Ai/defconfig @@ -123,7 +123,7 @@ CONFIG_NET_TCPBACKLOG=y CONFIG_NET_TCP_WRITE_BUFFERS=y CONFIG_NET_UDP=y CONFIG_NET_UDP_CHECKSUMS=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y diff --git a/boards/uvify/core/nuttx-config/nsh/defconfig b/boards/uvify/core/nuttx-config/nsh/defconfig index 895d59de1c6f..52d28d246415 100644 --- a/boards/uvify/core/nuttx-config/nsh/defconfig +++ b/boards/uvify/core/nuttx-config/nsh/defconfig @@ -94,7 +94,7 @@ CONFIG_MTD=y CONFIG_MTD_BYTE_WRITE=y CONFIG_MTD_PARTITION=y CONFIG_MTD_RAMTRON=y -CONFIG_NFILE_DESCRIPTORS=20 +CONFIG_NFILE_DESCRIPTORS=15 CONFIG_NFILE_STREAMS=8 CONFIG_NSH_ARCHINIT=y CONFIG_NSH_ARCHROMFS=y