1103 Commits

Author SHA1 Message Date
Daniel Agar
858a30df21 systemcmds/tests: replace warnx -> PX4_INFO 2021-07-17 10:57:09 -04:00
Daniel Agar
fedf8f0266 world_magnetic_model: move from ecl 2021-07-15 10:38:24 -04:00
Daniel Agar
dbaed99626
cmake remove git_ecl target 2021-07-13 10:03:06 -04:00
Daniel Agar
e4983ab88c
px4_platform_common: atomic support larger types with critical sections (on NuttX) 2021-07-08 10:56:25 -04:00
Beat Küng
e3972d563a cmake: ensure generated source files exist before extracting events
Only needed for Makefile-based builds:
gmake[3]: *** No rule to make target 'src/modules/flight_mode_manager/FlightTasks_generated.hpp', needed by 'events/px4.json'.  Stop.
2021-07-07 21:38:09 -04:00
Beat Küng
38f3b8d356 mavlink & system: add events interface
- sending protocol
- uorb event message & template methods for argument packing
- libevents submodule to send common events and handle json files
- cmake maintains a list of all (PX4) source files for the current build
  (PX4 modules + libs), which is used to extract event metadata and
  generate a json file
2021-07-07 21:38:09 -04:00
David Sidrane
fd68fd2933 tests:Use inttypes 2021-06-16 17:07:47 +02:00
David Sidrane
1b80018f30 systemcmds:Use inttypes 2021-06-16 17:07:47 +02:00
David Sidrane
84dd8839a2 i2c_spi_buses:Track NuttX change to getopts avoid name collision
NuttX #defined optarg and getopt to move to TLS. This fixes the
  name collision.
2021-06-16 17:07:47 +02:00
Hamish Willee
00cc1323ea gpio.cpp: Add backticks around gpio command docs 2021-06-03 12:37:48 +02:00
Peter van der Perk
ecc5154a44 Reflect dynamically allocate block pointers instead of using heap 2021-05-03 14:04:02 -04:00
Beat Küng
51f527d845 param: update 'param show-for-airframe' to use set-default 2021-04-23 16:44:55 -04:00
Daniel Agar
ea902e7f38 systemcmds/tests: split out individual module test commands 2021-03-23 11:39:14 -04:00
Daniel Agar
9b1cf98474 drivers/pwm_out: fix launch for non-multi case
- skip _objects[1] access if only 1 possible instance
 - command line request new mode via atomic
2021-03-23 10:40:22 -04:00
David Sidrane
cc098f9dff netman:Fix setting on first boot 2021-03-19 15:48:25 +01:00
Lorenz Meier
8cc3247d21 PWM command: Switch default to status, leave info 2021-03-17 22:03:18 +01:00
Lorenz Meier
21f5f9fba0 Param: Print failing param name
This is important for any sort of boot logs to know which parameter failed.
2021-03-17 22:03:18 +01:00
Daniel Agar
e7722b11eb pwm_out multi-instance support
PX4 uses banks of 8 outputs as a logical structure. Boards that have
more outputs than 8 get multiple instances. This is an arbitrary choice
that helps with overall structure and enables the mixing of different
device classes (like FMU, IO or UAVCAN).
2021-03-17 22:03:18 +01:00
David Sidrane
ccee36bb68 sd_bench and logger use aligned buffers 2021-03-17 05:27:53 +01:00
Beat Küng
9ceef80e06 param: remove set-default print's during bootup 2021-03-12 13:44:10 +01:00
Daniel Agar
f8eaa6e46b ROMFS handle bl_update generically
- include all available legacy bootloaders
2021-03-11 00:38:18 +01:00
Daniel Agar
ab0d0fd0be
uORB move to PX4 platform layer 2021-02-17 11:25:56 -05:00
Daniel Agar
0614789db3 tests: add simple parameter custom default testing 2021-02-12 08:27:47 -05:00
Daniel Agar
b8b13bb882 parameters runtime defaults 2021-02-12 08:27:47 -05:00
Lorenz Meier
13e875645c Revert "systemcmds/param: use PX4_INFO_RAW directly (delete qurt special case)"
This reverts commit 470f24037e489a2496f98ac77d1b71d36993b08b.
2021-02-02 00:53:45 +01:00
David Sidrane
f9d4bd53ef Apply suggestions from code review
Co-authored-by: Beat Küng <beat-kueng@gmx.net>

Apply suggestions from code review use stdout

Co-authored-by: Beat Küng <beat-kueng@gmx.net>
2021-01-31 14:42:09 +01:00
David Sidrane
39c6229c37 Netman:Data in network order 2021-01-31 14:42:09 +01:00
David Sidrane
d22eb76187 Add a simple network manager
This system command will display, set and save the network
   settings.

   netman show   - Displays the current settings.

   netman update - Will check for a net.cfg file on the SD card.
                   If present, it will update the paramaters,
                   delete the file, and reboot. Using the new settings.

   netman save - Saves the current settings to net.cfg on the SD card.
                 This file shoulf be renamed to preserver it across
                 reboots or editited to chech networkin paramates.

   File format is name<space>value:

   echo DEVICE=eth0           > /fs/microsd/net.cfg
   echo BOOTPROTO=fallback    >> /fs/microsd/net.cfg
   echo IPADDR=192.168.0.4    >> /fs/microsd/net.cfg
   echo NETMASK=255.255.255.0 >>/fs/microsd/net.cfg
   echo ROUTER=192.168.0.254  >>/fs/microsd/net.cfg
   echo DNS=192.168.0.254     >>/fs/microsd/net.cfg

   Valid values for `proto` are `dhcp`, `static`, `falback`
   Both will try dhcp for CONFIG_NETINIT_FALLBACK times
   and fall back to the static address.

   NETMASK - is the network mask.
   IPADDR  - this nodes ip address for static or fall back.
   ROUTER  - The default route.
   DNS     - The address of the dns server.
2021-01-31 14:42:09 +01:00
Daniel Agar
470f24037e systemcmds/param: use PX4_INFO_RAW directly (delete qurt special case) 2021-01-31 11:43:47 +01:00
Beat Küng
704a82aaa6 gpio: extend support for /dev/gp* GPIO's
Note that there's a small CLI interface change.
2021-01-15 10:57:20 -05:00
Lorenz Meier
a282f3df8d CLI test: Disable by default on NuttX
First target is to enable this for POSIX tests and then later to roll them out to NuttX.
2021-01-15 10:57:20 -05:00
Lorenz Meier
03e9e10847 Add CLI tests for basic soak testing
This is in no way a complete test suite but is intended as a starting point to get minimal
test coverage for CLI handling tests in. This is necessary to QA the CLI handling
(e.g. removal of commands) and to ensure that we are exercising these code paths in
stack check and alike tests.
2021-01-15 10:57:20 -05:00
Daniel Agar
02a08c42b7 tests: perf don't bother printing all perf counters 2020-12-27 15:29:45 -05:00
Julian Oes
9b065b4975 Update src/systemcmds/tests/test_dataman.c
Co-authored-by: Beat Küng <beat-kueng@gmx.net>
2020-12-14 09:26:18 +01:00
Julian Oes
5cb1bb7731 systemcmds: fix dataman test 2020-12-14 09:26:18 +01:00
David Sidrane
229f02a4f9 mtd:Reduce functionality on memory constrained systems 2020-12-02 20:40:23 -05:00
David Sidrane
e83a00c604 px4_manifest:Add Queries 2020-12-02 20:40:23 -05:00
David Sidrane
68ab736b16 Refactor mtd to make available to board startup 2020-12-02 20:40:23 -05:00
Alex Mikhalev
378b41af6a tunes: Improve logic for interrupting tunes
src/lib/tunes already knows which tunes are interruptable, so add
return values to expose than and use than in tone_alarm.
This fixes the issue that repeating tunes cannot be interrupted without
tune_override set to true.

Signed-off-by: Alex Mikhalev <alex@corvus-robotics.com>
2020-11-30 16:56:13 -05:00
Daniel Agar
eb3135e79c
systemcmds/tests: always build with optimization
- needed to keep Matrix stack usage reasonable
 - split matrix tests to further minimize stack usage
2020-11-15 19:15:56 -05:00
Matthias Grob
ff801fbc08 FlightTasks: remove FlightTaskManualPositionSmooth
alias first smooth position control version from 2017.

RIP it served well.
2020-11-11 21:16:18 +01:00
Daniel Agar
d33a48eb24
systemcmds/topic_listener: remove excludes
- this is a bit wasteful, but we can afford it for now everywhere listener is enabled
2020-11-10 13:46:48 -05:00
Julian Kent
d7fa5c68aa
Add support for alpha/beta/rc on the vendor version (#16112)
* Add support for versioning the vendor version

* Make regex only allow either alpha/beta/rc, or vendor versions
2020-11-04 13:48:19 +01:00
David Sidrane
e0f6c220b1 hardfault_log:Sanity check stack before dumping it 2020-11-04 08:44:38 +01:00
Daniel Agar
0f411d6820
Multi-EKF support (ekf2)
- ekf2 can now run in multi-instance mode (currently up to 9 instances)
    - in multi mode all estimates are published to alternate topics (eg estimator_attitude instead of vehicle_attitude)
 - new ekf2 selector runs in multi-instance mode to monitor and compare all instances, selecting a primary (eg N x estimator_attitude => vehicle_attitude)
 - sensors module accel & gyro inconsistency checks are now relative to the mean of all instances, rather than the current primary (when active ekf2 selector is responsible for choosing primary accel & gyro)
 - existing consumers of estimator_status must check estimator_selector_status to select current primary instance status
 - ekf2 single instance mode is still fully supported and the default

Co-authored-by: Paul Riseborough <gncsolns@gmail.com>
2020-10-27 10:56:11 -04:00
FengShun
eac9a6b68b Replace PublicationQueued with Publication to automatically configure ORB_QUEUE_LENGTH 2020-10-26 13:01:13 +01:00
Beat Küng
d2644a3bf7 distance_sensor/sf0x: rename to lightware_laser_serial 2020-10-22 11:30:50 -04:00
Daniel Agar
1eb3c59277 systemcmds/topic_listener: use msg_files list from msg/ 2020-10-20 11:05:47 -04:00
David Sidrane
7d6f8dc882 mtd:Allow a Board to set the partition sizes.
To define an N way split this define the following:

        #define BOARD_HAS_MTD_PARTITION_OVERRIDE {"/fs/mtd_params", "/fs/mtd_waypoints","/fs/equal_part" }

	OR
        To define a percentage split this define the following:
        #define BOARD_HAS_MTD_PARTITION_OVERRIDE {"/fs/mtd_params", "/fs/mtd_waypoints","/fs/tiny" }
        #define BOARD_MTD_PARTITION_TABLE_SIZES {50.0f, 49.0f, 1.0f}
2020-10-15 17:22:50 -04:00
David Sidrane
de6d31ef3e hardfault_log:Fix hard fault - while hard fault logging 2020-10-13 18:50:43 -04:00