Compare commits

...

6200 Commits

Author SHA1 Message Date
Lorenz Meier 50bd148f53 Aero: Update maintainer 2018-01-06 12:19:31 +01:00
Lorenz Meier ea545f2813 ROMFS: Exclude FMUv2 in Stampede 2018-01-06 11:35:53 +01:00
Lorenz Meier 6213b2266b ROMFS: Exclude FMUv2 in Axial Racing 2018-01-06 11:35:53 +01:00
Lorenz Meier f79c3bb5ea ROMFS: Exclude FMUv2 in ground vehicle 2018-01-06 11:35:53 +01:00
Lorenz Meier 25141ce184 ROMFS: Exclude FMUv2 in obscure airframe 2018-01-06 11:35:53 +01:00
Lorenz Meier 1930cc2fbe ROMFS: Exclude FMUv2 in VTOL 2018-01-06 11:35:53 +01:00
Lorenz Meier 90e7ce1b96 ROMFS: Remove reference to non-existent board 2018-01-06 11:35:53 +01:00
Lorenz Meier 1cfb441527 ROMFS: Reduce verbosity level 2018-01-06 11:35:53 +01:00
Lorenz Meier 59f56f4a5b Add support for Pixhack detection
This allows to boot a Pixhack 3.0 which is the same as Pixhawk 2.0 / 2.1
2018-01-06 11:35:53 +01:00
Lorenz Meier 01e1bac365 FMUv2: Fix Pixhawk Mini boards while hopefully retaining HK Pixhawk units. 2018-01-06 11:35:53 +01:00
Lorenz Meier 0cd24874f3 MPU6K: Provide more clear output which buses are being probed 2018-01-06 11:35:53 +01:00
Lorenz Meier 8c647f11d0 Revert "Revert "Fix for HobbyKing boards.""
This reverts commit b7189012dc.
2018-01-06 11:35:53 +01:00
Daniel Agar 37e3234e49 Jenkins uorb graphs set docker arguments 2018-01-05 23:20:04 -05:00
Daniel Agar 1f63d85869 NuttX generate Make.defs per config from PX4 cmake (#8573) 2018-01-05 22:47:10 -05:00
Daniel Agar f86d4b18f8 Jenkins generate uorb graphs (#8571) 2018-01-05 17:20:39 -05:00
Lorenz Meier 31ab496f31 ROMFS: Free additional space 2018-01-05 23:03:02 +01:00
Lorenz Meier dd5524da3d Make boot slightly less verbose 2018-01-05 22:45:12 +01:00
Matthias Grob c0c0666d5c Cygwin: use absolute path with cygpath conversion to the linker script again
because the relative path is interpreted differently on linux, mac and windows
2018-01-05 14:47:33 -05:00
Daniel Agar 275f462136 cmake determine relative path for firmware linking 2018-01-05 14:47:33 -05:00
Daniel Agar bf84cf0dcf Cygwin: use relative paths where needed 2018-01-05 14:47:33 -05:00
Matthias Grob be8adbfdf3 Cygwin: refactored & simplified some of the OS define logic 2018-01-05 14:47:33 -05:00
Matthias Grob 2186f7b1b1 Cygwin: Enable ARM build of px4fmu-vX_default under Windows Cygwin Environment 2018-01-05 14:47:33 -05:00
Matthias Grob 70de169f15 Cygwin: Enable build of SITL jMAVsim under Windows using the Cygwin Unix-like environment
Most of the incompatitbilities are luckily similar to the darwin build.
- New target OS __PX4_CYGWIN added because in other build environments on Windows defines will very likely be completely different
- added all necessary exeptions to the defines
- disabled priorities completely because on Windows they are defined 1-32 and with all the arbitrary +40 -40 priority settings there were a lot of problems
  not only did some threads/"virtual tasks" not start because of out of bound priorities but also the resulting scheduling was totally random and inadequate
  with default priorities it ran toally fine during my first tests, should be rethought when windows is used onboard in the future
2018-01-05 14:47:33 -05:00
Daniel Agar 02c4ec9b2a move nuttx-configs to platforms/nuttx 2018-01-05 14:21:31 -05:00
Daniel Agar 62c2fbb443 move Images to platforms/nuttx 2018-01-05 14:21:31 -05:00
Daniel Agar 2dcd617a8f move Debug to platforms/nuttx 2018-01-05 14:21:31 -05:00
Daniel Agar 7178f8416d delete obsolete Vagrantfile 2018-01-05 14:21:31 -05:00
Daniel Agar f2cd5e3e9f move src/firmware/ to platforms 2018-01-05 14:21:31 -05:00
Daniel Agar e5b784736f delete unused cmake/test 2018-01-05 14:21:31 -05:00
Daniel Agar 678e2c415d move cmake/${OS} to platforms 2018-01-05 14:21:31 -05:00
Nuno Marques 3fcffe1f3b Tools: update sitl_gazebo (#8597) 2018-01-05 14:09:31 -05:00
Amir Melzer 51437a89e1 remove coning compensation for the accelerometers (#8594) 2018-01-05 14:08:33 -05:00
Julian Oes 14cc9e9919 mavlink_messages: fix length of NAV_CONTROLLER msg
This was caught in an unrelated review.
2018-01-05 19:53:41 +01:00
ChristophTobler 3ffc1fd25b Stream scaled IMU for Snapdragon Flight using VISLAM
This is temporary (and for Snapdragon Flight + VISLAM only) until there is a proper solution to get unfiltered IMU data for VIOs etc.
2018-01-05 18:45:50 +01:00
Daniel Agar 545f8c4452 RTL optionally use planned mission landing (#8487)
- adds new RTL_LAND_TYPE parameter
2018-01-04 23:42:01 -05:00
Julian Oes f3bd241dbe jMAVSim: update to latest master
This brings some support for mavlink 2, and various other bugfixes.
2018-01-04 21:27:16 +01:00
Daniel Agar 430cdada60 param_export use bson encoder buffer 2018-01-04 09:21:17 +01:00
Daniel Agar 08443c0bfc params add param_find perf counter 2018-01-04 09:21:17 +01:00
Daniel Agar ec65ff7c5e sensors remove unnecessary param set notification 2018-01-04 09:21:17 +01:00
Daniel Agar 627788c93c mavlink remove unnecessary param set notification 2018-01-04 09:21:17 +01:00
Daniel Agar 2bb4644180 camera_trigger remove unnecessary param set notification 2018-01-04 09:21:17 +01:00
Daniel Agar 45441d62b1 sensors thermal calibration only get params if enabled 2018-01-04 09:21:17 +01:00
Daniel Agar 7af3cb9df8 param group "Sensors Thermal Calibration" shorten 2018-01-04 09:21:17 +01:00
Daniel Agar f87402b16c navigator remove redundant param updates 2018-01-04 09:21:17 +01:00
Daniel Agar 49180de27c commander remove continuous param_get in arm_auth_update 2018-01-04 09:21:17 +01:00
Daniel Agar 641129ad4e param add perf counters 2018-01-04 09:21:17 +01:00
keenanjohnson c8590e0fb1 Main Readme: Spelling correction
Signed-off-by: keenanjohnson <keenan.johnson@gmail.com>
2018-01-03 12:06:35 -05:00
Daniel Agar c7b5a6f463 FW delete unused yaw coordination parameters 2018-01-03 16:28:50 +01:00
Daniel Agar 757d905089 FW improve FW_ARSP_MODE metadata options
- fixes #8563
2018-01-03 08:18:22 +01:00
CarlOlsson 1cd0ca9c6c updated ecl 2018-01-02 22:36:42 +01:00
Paul Riseborough 96d04af6e8 ecl: adds sideslip to innovation test status reporting 2018-01-02 22:36:42 +01:00
CarlOlsson 84d7eb2900 ekf2: added beta test ratio to estimator_status
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2018-01-02 22:36:42 +01:00
Daniel Agar 573fbeda04 Jenkins add flight review email for failures 2018-01-02 16:00:35 -05:00
Daniel Agar 14e8ee75e7 Jenkins ROS tests fetch all git tags for correct version reporting 2018-01-02 16:00:35 -05:00
Daniel Agar 5af4704aac Jenkins ROS tests set CI=true and set CCACHE_BASEDIR 2018-01-02 12:25:10 -05:00
Lorenz Meier 1f4bad0624 MAVLink: Harden home position usage
This should ensure that the home position / altitude is only being used when valid.
2018-01-02 16:52:10 +01:00
Daniel Agar d67cbfba3a Jenkins add descriptions to flight review post 2018-01-02 10:38:12 -05:00
Daniel Agar 5db534849a Jenkins ROS tests archive all failure logs 2018-01-02 10:38:12 -05:00
Daniel Agar 4d08f56fae cmake add missing generate_px4muorb_stubs dependency (#8559) 2018-01-02 10:18:00 -05:00
Lorenz Meier 92540fc6d8 IO: Remove hint that parameter change requires reboot
The change is effective immediately so no reboot is required. This makes the whole configuration a lot easier.
2018-01-02 10:48:09 +01:00
Lorenz Meier f4362c5ae5 FMU: Remove hint that parameter change requires reboot
The change is effective immediately so no reboot is required. This makes the whole configuration a lot easier.
2018-01-02 10:47:38 +01:00
Daniel Agar b8e6fc2730 Makefile tests_coverage run ROS tests 2018-01-02 01:35:57 +01:00
Daniel Agar 6bdc18df6d sitl launch default ekf2 everywhere 2018-01-02 01:35:57 +01:00
Daniel Agar 734a6c8a42 Jenkins update mission test naming 2018-01-02 01:35:57 +01:00
Daniel Agar cd60fb6102 ledsim remove debug print 2018-01-02 01:35:57 +01:00
Daniel Agar e9960b5532 Jenkins add title and url for flight review upload 2018-01-02 01:35:57 +01:00
Daniel Agar 202c29154a simulator optimize GPS and battery
- GPS and battery were publishing at > 800Hz
2018-01-02 01:35:57 +01:00
Daniel Agar 66f614435f vtol_att avoid unnecessary work and delete unused 2018-01-02 01:35:57 +01:00
Daniel Agar d3a220f807 vtol_att only set fw_permanent_stab on param change 2018-01-02 01:35:57 +01:00
Daniel Agar 75e4a856a5 Jenkins post mission test logs to flight review 2018-01-02 01:35:57 +01:00
Daniel Agar 3f67ddbdba ROS mission_test.py send mission before starting
- update to latest sitl_gazebo
2018-01-02 01:35:57 +01:00
Daniel Agar 63deb40a76 ROS tests move to test/ and new Jenkins 2018-01-02 01:35:57 +01:00
Anthony Lamping f46db40b10 make sure FCU is connected to mavros before state topic is marked ready 2018-01-02 01:35:57 +01:00
Anthony Lamping ab5a268ca5 simplify vtol transition check, more log msgs 2018-01-02 01:35:57 +01:00
Anthony Lamping f9e7c66718 thread for offboard publishers, add asserts for topics to come up (simulation ready) and set mode and arming, use home_position topic as better indicator of when the simulation is ready, add more feedback to rosinfo, make timeouts meaningful (in seconds), add land and extended state values 2018-01-02 01:35:57 +01:00
Anthony Lamping 5ce381dfc7 update sitl tests 2018-01-02 01:35:57 +01:00
TSC21 fefed35dfe Tools: update sitl_gazebo 2018-01-01 21:06:00 +01:00
Daniel Agar 9d61febd39 tfmini remove obsolete IOCTLs 2018-01-01 17:38:41 +01:00
Lorenz Meier 49bed47924 Add TFMini to autostart 2018-01-01 17:38:41 +01:00
Ayush 91cedcaba3 Added tfmini driver to build configs 2018-01-01 17:38:41 +01:00
Ayush 9f2bb6c7f9 Added support for TFmini-LiDAR 2018-01-01 17:38:41 +01:00
Daniel Agar ad532d0510 docker_run.sh update container versions to match Jenkins 2018-01-01 10:27:43 -05:00
Daniel Agar 386c34a563 Jenkins update all containers to latest (except NuttX) 2018-01-01 10:19:00 -05:00
Daniel Agar 33266ef2c8 cmake use ccache if found and not disabled 2018-01-01 10:19:00 -05:00
Daniel Agar 1468d4ed39 muorb add generation dependency 2018-01-01 10:19:00 -05:00
Lorenz Meier 3b71c70583 Commander: Do not switch land detection state when not armed
This is important to have the probation times set up correctly and to silence land detected messages for systems that are not actually flying and just on the bench.
2018-01-01 15:32:37 +01:00
Lorenz Meier e7fe8f7268 Uploader: Enforce matching maximum flash sizes
The goal is to force developers to use the correct target with the correct flash size. This prevents criticial functionality missing and is in particular important for FMUv2/FMUv3 boards. It is unmaintainable otherwise for the Pixhawk series.
2018-01-01 09:29:55 -05:00
Lorenz Meier 3041438132 Zubax GNSS: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier e2b2f97d0d TAPv1: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 9a7f99f3cd S2740VC: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 0bfd2925bf Nucleo: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier d1d367011e IOv2: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier d26e037df4 FMUv5: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 3bfa194933 FMUv4PRO: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 18715ebd80 FMUv4: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier c0efaa4ca9 FMUv3: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 6fbfde9ec3 FMUv2: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier d22398f733 PX4 FLOW: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier cd0fbb3cd2 PX4 ESC: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 03c5e9172d PX4 CAN Node: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier bb3746e710 STM32 Disco: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier c3f630ca14 SAMe70: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 18d13498de NXPPHlite: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier ca472ebfaf MindPX: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 7277d72db5 ESC35: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 5d186f374b Crazyflie: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier f7b4f13e81 AUAV x2.1: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 2ba7b41f5c Aero: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 5072c0b5ae Aerocore: Store maximum flash size 2018-01-01 09:29:55 -05:00
Lorenz Meier 32aa8d4f51 FMUv3: Use its own proper prototype for the image 2018-01-01 09:29:55 -05:00
Lorenz Meier 40702b36ee NuttX: Allow different board prototype names from main build config 2018-01-01 09:29:55 -05:00
acfloria 1aebc69fed commander: Allow manual override in stabilized mode for a fixed-wing. 2018-01-01 14:28:36 +01:00
Lorenz Meier 715b571dac Commander: Add hint about ongoing rewrite
It's important that any reader of the file knows about the ongoing refactoring.
2018-01-01 13:11:52 +01:00
Anass Al dc6e47f777 Update SITL Gazebo for magnetic declination fix 2018-01-01 11:52:35 +01:00
Dennis Mannhart a649bbebb7 commander: switch to hold or mission once takeoff is finished (#8020)
* add COM_TAKEOFF_ACT to optionally switch to mission after takeoff
2017-12-31 13:58:20 -05:00
Lorenz Meier cf55901ac9 Calibration timeout: Triple to 90 seconds as the user can now cancel the routine
We timed out earlier to allow users to abort, but now that we can cancel we do not need to enforce such a time limit.
2017-12-31 16:37:02 +01:00
Lorenz Meier 2167457e2e VTOL status: Do not force a commander status change
Before the VTOL status would automatically force a commander state update all the time. This saves effort and makes sure the system only updates when it should.
2017-12-31 16:37:02 +01:00
Lorenz Meier 90b4afebb5 Commander: properly separate preflight check and prearm checks
We were running pre-arm checks before when not arming, which led to annoying error messages on vehicles that were on the bench or serviced on the ground. Now we really only run them when trying to arm.
2017-12-31 16:37:02 +01:00
Lorenz Meier ddf0ecfc38 Airspeed calibration: Ensure that the calibration state is stored correctly
This is necessary due to sensors that are so accurate that they have no offset at all.
2017-12-31 16:37:02 +01:00
Lorenz Meier 074636a8ae Commander: Check for preflight errors in order 2017-12-31 16:37:02 +01:00
Lorenz Meier c06251f3be IO serial: Code style 2017-12-31 16:36:34 +01:00
Lorenz Meier 1f21256f6a IO safety switch: Code style 2017-12-31 16:36:34 +01:00
Lorenz Meier 0013f641aa IO comms: Code style 2017-12-31 16:36:34 +01:00
Lorenz Meier ac113d71af IO main loop: Code style 2017-12-31 16:36:34 +01:00
Lorenz Meier 7d44567fab IO Proto: Code style 2017-12-31 16:36:34 +01:00
Lorenz Meier 2c148236ae IO Mixer: Code style 2017-12-31 16:36:34 +01:00
Lorenz Meier 0ef245aee1 IO ADC: Code style 2017-12-31 16:36:34 +01:00
Lorenz Meier 168e070f94 IO CMake file: Formatting 2017-12-31 16:36:34 +01:00
Lorenz Meier 51111fc6e3 IO Firmware: Document override behavior for manual override. 2017-12-31 16:36:34 +01:00
Daniel Agar d7aaab07fc delete unused SENSORIOCGQUEUEDEPTH 2017-12-31 09:47:51 -05:00
Daniel Agar 6ad9e59a7a delete unused GPIO_SET_INPUT 2017-12-31 09:47:51 -05:00
Daniel Agar b8b9f15a34 delete unused GPIO_PERIPHERAL_RAIL_RESET 2017-12-31 09:47:51 -05:00
Daniel Agar d61e0651ab delete unused GPIO_SET_OUTPUT_HIGH 2017-12-31 09:47:51 -05:00
Daniel Agar 4c041f12ea delete unused GPIO_SET_OUTPUT_LOW 2017-12-31 09:47:51 -05:00
Daniel Agar f550c8735a delete unused GPIO_SENSOR_RAIL_RESET 2017-12-31 09:47:51 -05:00
Daniel Agar c65db00914 delete unused GPIO_SET_ALT_4 2017-12-31 09:47:51 -05:00
Daniel Agar db5e932f48 delete unused GPIO_SET_ALT_3 2017-12-31 09:47:51 -05:00
Daniel Agar 17e58dc08b delete unused GPIO_SET_ALT_2 2017-12-31 09:47:51 -05:00
Daniel Agar c6760cc6fb delete unused GPIO_SET_ALT_1 2017-12-31 09:47:51 -05:00
Daniel Agar d91b2347dd mpu6000 delete dummy 2017-12-31 09:47:51 -05:00
Daniel Agar badcddc29a delete unused GYROIOCGEXTERNAL 2017-12-31 09:47:51 -05:00
Daniel Agar 98ca693298 delete unused GYROIOCGLOWPASS 2017-12-31 09:47:51 -05:00
Daniel Agar 85e879a574 delete unused GYROIOCSLOWPASS 2017-12-31 09:47:51 -05:00
Daniel Agar 1b4a224223 delete unused GYROIOCGHWLOWPASS 2017-12-31 09:47:51 -05:00
Daniel Agar cc2cf40e6e delete unused GYROIOCSHWLOWPASS 2017-12-31 09:47:51 -05:00
Daniel Agar 8b591aa13a delete unused ACCELIOCGHWLOWPASS 2017-12-31 09:47:51 -05:00
Daniel Agar 0f8f319411 delete unused ACCELIOCSHWLOWPASS 2017-12-31 09:47:51 -05:00
Daniel Agar 63d24a9e1e delete unused ACCELIOCGLOWPASS 2017-12-31 09:47:51 -05:00
Daniel Agar 417351390f delete unused ACCELIOCSLOWPASS 2017-12-31 09:47:51 -05:00
Daniel Agar be930d4372 delete unused PWM_SERVO_CLEAR_OVERRIDE_OK 2017-12-31 09:47:51 -05:00
Daniel Agar dacc45c3d1 delete unused PWM_SERVO_SET_OVERRIDE_OK 2017-12-31 09:47:51 -05:00
Daniel Agar ca6f6b27a5 delete unused PWM_SERVO_SET_RC_CONFIG 2017-12-31 09:47:51 -05:00
Daniel Agar ff6928fb63 delete unused GPIO_GET 2017-12-31 09:47:51 -05:00
Daniel Agar 65f9005bc6 delete unused RC_INPUT_GET 2017-12-31 09:47:51 -05:00
Daniel Agar 32a450f5dd detect_orientation make constants constexpr 2017-12-31 09:47:51 -05:00
Daniel Agar 344cf83549 delete unused SENSORIOCCALTEST 2017-12-31 09:47:51 -05:00
Daniel Agar 4980b93830 delete unused SENSORIOCGROTATION 2017-12-31 09:47:51 -05:00
Daniel Agar 9c378a7ca1 delete unused SENSORIOCSROTATION 2017-12-31 09:47:51 -05:00
Daniel Agar 3ead5c2afd delete unused MAGIOCSLOWPASS/MAGIOCGLOWPASS 2017-12-31 09:47:51 -05:00
Daniel Agar 301be5ed8a delete unused range finder IOCTLs 2017-12-31 09:47:51 -05:00
Daniel Agar 859b19db9a uORB.h reduce orb_metadata field sizes 2017-12-31 09:47:51 -05:00
Lorenz Meier 34ea229a78 Update Gazebo with GUI fix 2017-12-30 20:14:33 +01:00
Lorenz Meier ab30532f52 Update SITL Gazebo with build system fixes 2017-12-30 20:10:00 +01:00
Lorenz Meier 3cc356a703 Gazebo: Update repository to enable video streaming support 2017-12-30 18:17:25 +01:00
Lorenz Meier ab2f85d4ff SITL: Search MAVLink locally 2017-12-30 14:47:37 +01:00
Lorenz Meier 5d4086309f Gazebo: Fix build for Gazebo 8 and tune down GPS noise 2017-12-30 13:05:51 +01:00
Lorenz Meier e3f5f8e475 Update Gazebo submodule to include gimbal fixes 2017-12-30 11:46:55 +01:00
Daniel Agar cbc8b50aa1 sensors don't store diff_pres in class 2017-12-30 11:30:34 +01:00
Daniel Agar 4445ffc70e sensors don't store airspeed in class 2017-12-30 11:30:34 +01:00
Daniel Agar 6623fd0212 sensors don't keep battery_status messages 2017-12-30 11:30:34 +01:00
Ramón Hernán Roche Quintana d57ed6d17f Changelog generator default params 2017-12-30 11:27:57 +01:00
Lorenz Meier 6a701adf3c HITL: Remove hard requirement for airframes 2017-12-30 11:24:22 +01:00
Lorenz Meier 2eb3392c39 PWM out sim: Increase stack as needed 2017-12-30 11:24:22 +01:00
Lorenz Meier bb516be61e Commander: Enforce correct system configuration for HITL
This is important to ensure that users are not trying to use HITL with airframes that will not work.
2017-12-30 11:24:22 +01:00
Lorenz Meier 0ae1737e85 Commander: Fix HITL state initialization that prevented pre-flight checks to pass in HITL mode on v1.7.2
This is a minor change that fixes the ordering of the initialization.
2017-12-30 11:24:22 +01:00
Lorenz Meier 644db1b03f State machine helper: Fix typo 2017-12-30 11:24:22 +01:00
Lorenz Meier c31e31bf5e Voted sensors: Better error messages 2017-12-30 11:24:22 +01:00
Lorenz Meier f69a6af989 Commander: increase stack to ensure enough margin remains 2017-12-30 11:24:03 +01:00
Lorenz Meier fa8222e188 Logger: Free some RAM to leave space for mag calibration 2017-12-30 11:24:03 +01:00
Daniel Agar 370da89573 fw_pos_control fix parameter sanity check (#8521)
- the sanity check result wasn't being sent to the user and prevents landing slope, runway takeoff, and launch detector parameter updates.
2017-12-26 16:02:31 -05:00
Lorenz Meier 1cab556ddb Topic listener: Depend on messages, not just on headers
This ensures that the listener is re-built when the message spec changes.
2017-12-26 16:01:11 -05:00
Lorenz Meier 23d15c1365 Platform: Depend on messages, not just on headers
This ensures that platform is re-built if messages change.
2017-12-26 16:01:11 -05:00
Lorenz Meier 72823e6eb4 MicroRTPS bridge: Depend on messages, not just on headers
This ensures that an update of the message spec re-generates the bridge.
;
2017-12-26 16:01:11 -05:00
Daniel Agar fc7c8b4b89 vehicle_status delete engine_failure_cmd 2017-12-27 02:41:10 +08:00
Daniel Agar 17e17d79dd commander delete unused vtol_transition_failure_cmd 2017-12-27 02:41:10 +08:00
Daniel Agar d0fba8bf8b commander delete unused data_link_lost_cmd 2017-12-27 02:41:10 +08:00
Daniel Agar c0be801b5c commander delete unused rc_signal_lost_cmd 2017-12-27 02:41:10 +08:00
Daniel Agar 5a6cde41d5 commander delete unused gps_failure_cmd 2017-12-27 02:41:10 +08:00
Daniel Agar ca804a2308 commander delete unused sensors check 2017-12-27 02:41:10 +08:00
Daniel Agar 294fbc46a9 commander initial class structure 2017-12-27 02:41:10 +08:00
Amir Melzer 55be098e3b adis16448 bmlz fixes (#8519)
* small bit mask fix

* Restore factory calibration values in drivers start-up sequence

* Restore factory calibration values in drivers start-up sequence (reverted from commit 09ba45501f87f77e53d670fcf880b3cfc419fe38)

* Restore factory calibration values in drivers start-up sequence

* Initialization of the Adis16448 report struct

* Add stall time after write and read cycle

* Increasing the stall time for being compatible with the B sensor version

* small clean up

* Add settling time after initialization
2017-12-22 13:17:54 -05:00
Daniel Agar 5d6edcc15d commander consolidate periodic state publishing 2017-12-22 10:42:14 -05:00
Daniel Agar 1ea5de43cf logger add vehicle_status_flags 2017-12-22 10:42:14 -05:00
Daniel Agar 043ad3c33e commander vehicle_status_flags only publish if changed 2017-12-22 10:42:14 -05:00
Paul Riseborough 176738c688 commander: add missing px4_close (#8513) 2017-12-22 08:57:06 +11:00
Daniel Agar ec57832a8f FW land detector increase trigger time and cleanup (#8486) 2017-12-21 12:17:32 -05:00
Daniel Agar 7dab5d4380 mission feasibility full home position isn't always needed 2017-12-21 15:28:45 +08:00
Daniel Agar b7189012dc Revert "Fix for HobbyKing boards."
This reverts commit 75b93b0728.
2017-12-21 15:25:25 +08:00
Hamish Willee 2f50a07afb Delete redundant documentation files (#8505) 2017-12-21 02:06:41 -05:00
CarlOlsson 925c65b4d5 ekf2: add beta innovation gate to parameters
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2017-12-21 04:02:10 +08:00
Daniel Agar 58d1cdc733 Allow MAV_CMD_DO_SET_HOME as a mission command 2017-12-20 10:19:07 +01:00
sanderux a8c26265b5 Check manual home set when setting during arming 2017-12-20 10:19:07 +01:00
Daniel Agar 964cb486a9 home_position delete unused direction_{x, y, z} 2017-12-20 10:19:07 +01:00
Daniel Agar 375ae991bc commander DO_SET_HOME populate local coordinates
- unify commander home update
2017-12-20 10:19:07 +01:00
sanderux cf7ad67678 Check home reset in local frame 2017-12-20 10:19:07 +01:00
sanderux 4e175d13c4 Set manual_home when home set manually 2017-12-20 10:19:07 +01:00
sanderux 74868f8c2b Reset home position when landed and disarmed 2017-12-20 10:19:07 +01:00
Daniel Agar 6172315cf7 navigator mission_result fix increment sign 2017-12-20 17:05:25 +08:00
Daniel Agar a4be7ae7d0 commander mission_result check time and instance 2017-12-20 17:05:25 +08:00
Hamish Willee 7a9f7eb424 Updates to README
- Link supported airframes to the Airframe reference rather than portfolio pages (they may look pretty, but nowhere near as useful for developers. Add portfolio link up top.
- Change the somewhat empty "Project Milestones" to "Project Roadmap" and link to the high level roadmap. I removed the only milestone about Lorenz creating the software. If we end up adding a more detailed milestone section that could go in. 
- Added clear guidelines for users vs developers.
2017-12-20 05:22:43 +08:00
ChristophTobler 4bd7d62b5c ekf2: update AID_MASK bitmask comment for QGC 2017-12-20 05:22:11 +08:00
Pietro De Nicolao aea8985c8d Fix links to supported hardware in README.md (#8476) 2017-12-18 11:23:32 -05:00
Beat Küng 3da8031e8e uorb graph: improve error output 2017-12-18 10:19:15 +01:00
Beat Küng eeff52cda7 uorb_graph: add .gitignore, change graph file for sitl runtime config 2017-12-18 10:19:15 +01:00
Beat Küng ec50193d6c Makefile: add uorb_graphs target 2017-12-18 10:19:15 +01:00
Beat Küng 5195210893 CMakeLists.txt: add custom target uorb_graph to generate the graph JSON files
Use like this:
	  make px4fmu-v2_default uorb_graph
2017-12-18 10:19:15 +01:00
Beat Küng 57f92250b3 uorb graph create.py: sort modules & topics by name length for JSON output 2017-12-18 10:19:15 +01:00
Beat Küng 9bff0c8c04 uorb graphs: add script to create graph from a posix startup script 2017-12-18 10:19:15 +01:00
Beat Küng e2d6c0a8f9 uorb_graph: add script to generate uORB pub/sub graphs
2 possible output formats:
- JSON (can be used with D3.js)
- Graphviz

Not covered yet: Publication & Subscription classes
2017-12-18 10:19:15 +01:00
Daniel Agar d5bb948cbb README fix LICENSE link 2017-12-17 11:33:19 -05:00
Daniel Agar a4b127960b README switch travis-ci build status to Jenkins 2017-12-17 11:33:19 -05:00
Daniel Agar e8624f8afe navigator takeoff alt check use altitude acceptance (#8480) 2017-12-17 01:39:53 -05:00
Daniel Agar 28d1ec8afe VTOL defaults set MIS_TAKEOFF_ALT 20 and remove tuning (#8481) 2017-12-17 00:58:23 -05:00
Daniel Agar 642aeccd1e logger add home_position to the default set 2017-12-17 00:57:17 -05:00
James Goppert 75b93b0728 Fix for HobbyKing boards. 2017-12-16 21:05:18 +00:00
Daniel Agar a15ca72288 Jenkins add posix_sitl_default and posix_sitl_rtps 2017-12-15 14:31:25 -05:00
Daniel Agar 4beeb7f560 delete obsolete s3 upload helpers 2017-12-15 14:31:25 -05:00
Daniel Agar baff0832bc Jenkins clang scan-build output publisher 2017-12-15 14:31:25 -05:00
Daniel Agar c398c95fd5 Jenkins px4io-v2 build in same directory 2017-12-15 14:31:25 -05:00
Daniel Agar b1315a71ec Jenkins add cppcheck build 2017-12-15 14:31:25 -05:00
Daniel Agar 670111875e Jenkins add clang static analyzer (scan-build) 2017-12-15 14:31:25 -05:00
Daniel Agar e4180f6a72 Jenkins split GCC 7 posix & nuttx tests
- this groups the builds together properly
2017-12-15 14:31:25 -05:00
Daniel Agar 868ff42f47 check_submodules.sh handle CI forced update only if directory exists 2017-12-15 14:31:25 -05:00
Daniel Agar cebe7add8b Jenkins move style check to tests 2017-12-15 14:31:25 -05:00
Daniel Agar d7aa5df3cd Jenkins enable clang-tidy build 2017-12-15 14:31:25 -05:00
Daniel Agar cbdb08bb61 mavlink receiver delete unused orb_adverts 2017-12-12 11:25:09 -05:00
Daniel Agar d2457467e7 mavlink delete unimplemented and deprecated handle_message_request_data_stream 2017-12-12 11:25:09 -05:00
Daniel Agar c8aa262e85 mavlink delete unimplemented handle_message_quad_swarm_roll_pitch_yaw_thrust 2017-12-12 11:25:09 -05:00
Paul Riseborough 3c667bb4f5 mc_pos_control: format fixes 2017-12-12 12:14:24 +00:00
Paul Riseborough deaa83bba0 mc_pos_control: Use vertical position derivative when in velocity control mode
Stops vertical velocity bias errors preventing the vehicle from landing.
Use of the vertical derivative is blended in so that for zero vertical velocity set point, the  local_position.vz is used and when the magnitude of the vertical velocity setpoint exceeds the landing speed, the  local_position.z_deriv is used.
2017-12-12 12:14:24 +00:00
Dennis Mannhart 26e85736a5 land_detector: Reduce and detection false negatives due to estimator bias
Using the vertical derivative estimate prevents vertical velocity offsets caused by estimation vertical velocity errors preventing the vehicle disarming.
2017-12-12 12:14:24 +00:00
Paul Riseborough 64a06d8523 commander: Fix pre-flight delta velocity bias check level (#8446)
Previous check level was less than the max achievable by the estimator using current default parameters making the check ineffective.
2017-12-12 11:41:42 +11:00
Daniel Agar cc216ef918 Jenkinsfile set CI env variable in docker builds 2017-12-11 16:48:39 -05:00
Daniel Agar f01400d407 check_submodules.sh force update if in CI 2017-12-11 16:48:39 -05:00
Florian Achermann 87646c4ea4 Update the Description of the estimator_status Message (#8346)
* Fix description of GPS check fail bits in estimator status message
2017-12-11 11:15:34 -05:00
Daniel Agar 86ad2ada71 Jenkins remove fast fail
- this saves build resources, but makes finding the actual failure rather hard (with the current blue ocean gui).
2017-12-11 02:15:14 -05:00
Daniel Agar 32cba41bed cmake handle mavlink v1 submodule only where used 2017-12-10 19:24:05 -05:00
Daniel Agar 1886c8d983 check_submodules try harder when fetching to work around various issues 2017-12-10 19:24:05 -05:00
Daniel Agar aef7a3cd9a cmake only init uavcan_board_ident if used 2017-12-10 19:24:05 -05:00
Daniel Agar ded055f71d cmake only init cmake_hexagon if used 2017-12-10 19:24:05 -05:00
Daniel Agar ddc544aabe Jenkinsfile parallel builds fail fast 2017-12-10 15:58:01 -05:00
Daniel Agar 7aeea62e21 px4fmu-v3_rtps override default naming 2017-12-10 15:58:01 -05:00
Daniel Agar 5bdc6a4eab Jenkins correctly archive artifacts and print sizes 2017-12-10 15:58:01 -05:00
Daniel Agar a452554bdf Jenkins add eagle_default build with docker credentials (#8442) 2017-12-10 03:27:48 -05:00
Daniel Agar 5c54449063 Jenkinsfile small optimizations (#8441)
- combine default and rtps builds (ccache)
 - set CCACHE_BASEDIR
2017-12-10 02:32:21 -05:00
Daniel Agar c56b0a0e7c Mavlink only stream HOME_POSITION if valid (#8440) 2017-12-10 02:31:42 -05:00
lamping7 63718bf27b fix MISSION_ITEM REACHED message broadcast (#8332) 2017-12-10 02:30:58 -05:00
Daniel Agar bc9a8e4432 cmake nuttx base .px4 file naming on elf binary 2017-12-09 20:35:44 -05:00
Daniel Agar df4ab8b59e px4fmu-v3_default name binary appropriately
- fixes #8436
2017-12-10 01:07:41 +00:00
Julien Lecoeur 99920c84fe Jenkins: update arch image to tag 2017-12-08 2017-12-10 01:07:02 +00:00
Julien Lecoeur ed10921a67 [TO REVERT] Archlinux docker image: use tag pr-archlinux 2017-12-10 01:07:02 +00:00
Julien Lecoeur 0bd5744ebb Jenkins: build posix_sitl_default and nuttx_px4fmu-v5_default under ArchLinux (GCC7) 2017-12-10 01:07:02 +00:00
Sander Smeets 423241e7e2 Add forwarding on telem2 normal telemetry option (#8434) 2017-12-09 19:45:47 -05:00
Paul Riseborough 324c5151e7 ekf2: use local scope for control mask variable 2017-12-08 07:43:13 +00:00
Paul Riseborough b812f95a77 ekf2: Adjust pre-flight check level
Reduce max yaw error when not using global frame aiding data to prevent large yaw yaw changes after takeoff.
2017-12-08 07:43:13 +00:00
Paul Riseborough ded9ca13e4 ekf2: Reduce sensitivity of preflight yaw check when not doing absolute aiding
When the EKF is not fusing in observations from the NE global reference frame, the tolerance to yaw errors is much higher. This changes will prevent false triggering of the preflight fail check when operating indoors without GPS where mag field errors can be high.
2017-12-08 07:43:13 +00:00
Daniel Agar 9819068ee9 Jenkins fetch git tags 2017-12-08 00:17:19 -05:00
Beat Küng fa929322ab load_mon: remove usage of CONFIG_RAM_SIZE
The define should not be used, as it might be wrong.
This is the case on fmu-v5, which meant that the used RAM was always 1.
2017-12-07 20:28:17 +00:00
Daniel Agar f1bd94e25b cmake add git submodule replace . in target name 2017-12-07 20:27:46 +00:00
Dennis Mannhart 4f8f0d8645 mc_pos_control: set triplets to NAN if not in auto mode 2017-12-07 20:27:11 +00:00
Daniel Agar 769fef1d9a delete leftover px4io-v1 files 2017-12-07 14:48:28 -05:00
Daniel Agar aef8bf2ce8 delete incomplete nuttx sim config 2017-12-07 14:48:28 -05:00
Daniel Agar 3506f7b828 delete non-functional aerocore 1 remains 2017-12-07 14:48:28 -05:00
Daniel Agar b4f570e459 NuttX update to latest 7.22+ with pipes poll fix
https://github.com/PX4-NuttX/nuttx/pull/7
2017-12-07 14:09:59 -05:00
Beat Küng c4ee5c318f px4fmu-v5: make sure the internal ist8310 is detected as internal mag 2017-12-07 17:17:17 +00:00
Beat Küng a791adf3b9 ist8310: enable internal/external distinction 2017-12-07 17:17:17 +00:00
Beat Küng a0afc370d0 land detector: move arming state into base class & set param when disarming
Before that, different modules (ekf2, commander & land detector) changed
params upon different events:
- ekf2 & commander set params after disarm
- land detector set params on land detected
If the 2 events were several 100ms appart, it led to 2 param saves, and
the latter param set could have been blocked by an ongoing save. And if
the land detector was blocked, it could lead to mag timeouts.

This patch makes all modules use the same event, thus only a single param
save will happen.

If we want to have guarantees to never block, we should introduce a
param_try_set() API method.
2017-12-07 11:55:51 +00:00
Beat Küng 1dbeec6a19 logger: do not write param changes if _should_stop_file_log is set
_should_stop_file_log is set after disarming: logging continues for 1s
to measure the CPU usage.
During that time, other modules might change params (such as ekf), and
we don't need to have these the log. However currently all modules do
not notify the system when setting params after disarming.
Meaning this patch is not strictly needed, it's more a preventive
measure.
2017-12-07 11:55:51 +00:00
Paul Riseborough b5be990109 lpe: fix incorrect setting of local_position.z_global 2017-12-07 08:20:16 +00:00
Paul Riseborough 8d89e5e40b commander: rework centralise home position publication
This fixes a bug preventing use of auto and RTL when taking off with GPS.
2017-12-07 08:20:16 +00:00
Paul Riseborough 41f3e1f9b4 commander: centralise home position publication 2017-12-07 08:20:16 +00:00
Paul Riseborough 934a7af579 commander: Set home alt to EKF origin if global navigation commences in-flight
The EKF origin height is calculated to be where the vehicle was at takeoff and is suitable as a surrogate home altitude.
2017-12-07 08:20:16 +00:00
Paul Riseborough 49d82164c6 navigator: check home position horizontal and vertical validity 2017-12-07 08:20:16 +00:00
Paul Riseborough 024589d63d msg: Add separate vertical and horizontal validity flags to home_position
If we have taken off without GPS and gained it in flight, the home vertical position can be set, but not the horizontal.
2017-12-07 08:20:16 +00:00
Paul Riseborough a81c49014f mc_pos_control: reset height reference when global position available
This enables the reference height to be reset when global vertical position becomes available in-flight.
2017-12-07 08:20:16 +00:00
Daniel Agar db8900fffc cmake improve git submodule dependencies 2017-12-06 21:15:32 -05:00
Daniel Agar 1086d4a1e4 Jenkins clear ccache stats before each build 2017-12-06 20:33:06 -05:00
Daniel Agar 2fa1702c71 Jenkins temporarily disable coverage and clang-tidy
- check format first to reduce build utilization
2017-12-06 19:46:56 -05:00
Daniel Agar 8d39f4e4a1 px4io only update params and bind if not armed 2017-12-06 10:08:00 +00:00
Daniel Agar f748b38b3a mc_att_control set timestamp_sample from gyro 2017-12-06 10:08:00 +00:00
Paul Riseborough f6b108c2b6 ecl: Use branch Release_1.7.0 (#8406)
This branch fixes a reported bug, fixes tow potential bugs and fixes a minor documentation error.

1) Removes code un-used under normal conditions that would prevent a height reset if a negative height variance was present. Potential bug.
2) Fix error in parameter documentation.
3) Adds missing initialisations for class variables . Potential bug.
4) Prevents the EKF loss of navigation message being output on startup. Reported bug.
2017-12-06 00:04:34 -05:00
Beat Küng 2f18a3699c micrortps_bridge: add optical_flow to the set of received topics
Required for Optical Flow on the Aero via RTPS
2017-12-05 23:48:15 -05:00
Julien Lecoeur bcceadcb85 NuttX: silence warnings -Wimplicit-fallthrough and -Wnonnull-compare 2017-12-05 22:51:43 -05:00
Julien Lecoeur 9fb98dad3e Fix warning -Wimplicit-fallthrough 2017-12-05 22:51:43 -05:00
Sander Smeets b21af471ac QuadChute monitor tecs height rate (#8395) 2017-12-04 13:12:44 -05:00
Paul Riseborough fa5010109e commander: Reset nav test when vehicle is disarmed
Previously, the only way to clear a failed nav test was to reboot. This hindered testing.
2017-12-04 09:09:54 +00:00
Paul Riseborough d783bc8ae1 commander: Check for nav divergence due to bad yaw at takeoff
This check is performed for up to 30 seconds after takeoff or until  a horizontal speed of 5 m/s has been achieved.
If the vehicle is not landed and the check is active, then the yaw will be declared as failed if the velocity innovations fail for a continuous period of 1 second.
This will cause the local and global position and velocity validity to be latched false to prevent unsafe use of position control modes.
2017-12-04 09:09:54 +00:00
Paul Riseborough afe857dfe6 commander: rework preflight GPS checks
Fix the bug allowing arming without GPS checks passed in the first 20 seconds after gaining GPS lock when COM_ARM_WO_GPS is set to 0
Allow 10 seconds after boot for EKF quality checks to pass before reporting failure to allow EKF to stabilise.
Move GPS quality checking and reporting to after all innovation and bias checks.
Make messages more informative.
Add missing GPS speed accuracy check.
2017-12-04 09:09:54 +00:00
Paul Riseborough c09eecbab1 commander: prevent ekf checking being bypassed if GPS checking is disabled 2017-12-04 09:09:54 +00:00
Paul Riseborough ddfe077f7c commander: strengthen pre-flight fail checking
The commander checks use instantaneous values which are vulnerable to false negatives  or positives with noisy data or transient faults.

This patch checks the estimators published pre flight check status which is based on persistent checks using filtered data.
2017-12-04 09:09:54 +00:00
Paul Riseborough fc80be0917 ekf2: improve preflight checks and publish status
Separate the vertical and horizontal checks for use by local position validity reporting
Add checking of yaw using a decaying envelope filter to the horizontal checks.
Publish the check result to estimator_status topic.
2017-12-04 09:09:54 +00:00
Paul Riseborough 92bcc63418 msg: add pre flight check status message 2017-12-04 09:09:54 +00:00
David Sidrane c0a94cda07 px4-same70xplained-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane 23cfef5753 px4-same70xplained-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane c621965a2b zubaxgnss-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane 1812d677c5 tap-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane c4b2f39cf4 s2740vc-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane 58af82312b px4nucleoF767ZI-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane b85fbd496f px4io-v2:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane e9a318e4f7 px4fmu-v5:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane 093563efb0 px4fmu-v4pro:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane c9ed286874 px4fmu-v4:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane ad687cde62 px4fmu-v2:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane 096b25550d px4fmu-v2:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane e4f7b76296 px4flow-v2:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane c1ae7c76df px4esc-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane 6b30a41da2 px4cannode-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane c76f90f078 px4-stm32f4discovery:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane e15e9ba5c7 px4-same70xplained-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane fea11f1d47 nxphlite-v3:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane 9879bea611 mindpx-v2:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane 8b6e447875 esc35-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane d9cd9183db crazyflie:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane 687dbea572 auav-x21:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane 66d2509670 aerofc-v1:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
David Sidrane db02eac009 aerocore2:Ensure _ebss will be 4 byte aligned 2017-12-03 14:11:35 +00:00
Hamish Willee 6bb3e65d23 Make non-wrapping/scrolling table 2017-12-03 14:10:50 +00:00
Hamish Willee c551496a41 Stop parameter names from wrapping in markdown table 2017-12-03 14:10:50 +00:00
ChristophTobler 2ca2382dbb tap_esc: replace FILE with file_t from base class device 2017-12-03 14:10:20 +00:00
ChristophTobler 06a9f54796 tap_esc: changes needed to run on qurt 2017-12-03 14:10:20 +00:00
Lorenz Meier 0e1c7eb2d2 IO driver: Reflect availability of override state in safety topic
This allows other components to correctly configure for potential manual override states if the pilot chooses to enable them.
2017-12-02 11:39:52 +00:00
Lorenz Meier 1b7d3883a4 Commander: Obey override / manual reversion mode from external override device
This change will force commander into manual reversion mode when an external override device (like PX4IO) overrides the system externally. This is not a functional change on the outputs, as they were in override mode even without this patch. However, this change ensures that the system state is consistent with the output state and also ensures that the pilot and operator has better situational awareness when he / she triggers the manual reversion without realizing it.
2017-12-02 11:39:52 +00:00
Lorenz Meier 4abc578932 Commander: State machine helper documentation
Future contributors need to know about the time constraints that the execution of this function needs to satisfy.
2017-12-02 11:39:52 +00:00
Lorenz Meier 67fa220d61 IO driver: Report override device state
This allows other components to correctly register the IO override status.
2017-12-02 11:39:52 +00:00
Lorenz Meier 39f4b205e7 Safety: Add field for override inputs
This is helpful for safety devices that have an external override input. This helps to put the autopilot in an override scenario into a sane state, instead of letting it believe its still in control.
2017-12-02 11:39:52 +00:00
Avinash Reddy Palleti b1a16840c7 Fix typo error in micrortps_client module
Fixed the typo error in micrortps_client which was causing issue to update
baudrate and other options.
2017-12-01 12:56:45 +01:00
Daniel Agar 1a9e2ac789 cmake NuttX wrapper work around windows cygwin path issues 2017-12-01 02:04:28 -05:00
Daniel Agar fedc9abb02 vtol_att_control increase stack by 30 Bytes (1200 -> 1230) 2017-11-29 16:01:40 -05:00
Daniel Agar f63c8218e4 Jenkins increase test timeout 2017-11-28 23:50:17 -05:00
Daniel Agar 66d4a1b3fd Jenkins increase timeout to 30 minutes for now 2017-11-28 19:46:54 -05:00
Daniel Agar ba8153afd9 px4fmu-v5_rtps fix config type (v4 -> v5) 2017-11-28 19:46:54 -05:00
Daniel Agar 23d7c687fe Jenkins add rtps builds and cleanup 2017-11-28 19:46:54 -05:00
Daniel Agar 376908b025 travis-ci remove tests, coverage, clang-tidy (#8383)
- these builds have migrated to ci.px4.io
2017-11-28 15:39:40 -05:00
Daniel Agar 0c10dc714d Jenkinsfile add all NuttX, Raspberrypi, Bebop, Ocpoc builds (#8381) 2017-11-28 12:32:26 -05:00
Daniel Agar 42e01cde43 RC params delete incorrect comment 2017-11-27 20:05:12 -05:00
Daniel Agar f19faca78b delete unused RC_TH_USER 2017-11-27 20:05:12 -05:00
Daniel Agar a398ffd7d9 delete unused RC_RL1_DSM_VCC 2017-11-27 20:05:12 -05:00
Nicolas de Palezieux a6ae1fbcaa vehicle command ROI: do not erroneously report command unsupported; handle VEHICLE_CMD_DO_SET_ROI and VEHICLE_CMD_NAV_ROI identically (#8377) 2017-11-27 15:43:39 -05:00
Daniel Agar ed7f333fe8 sensors delete disabled ATT_VIBE_THRESH (#8372) 2017-11-26 17:25:45 -05:00
Daniel Agar 1d1da12859 delete exampales ekf_att_pos_estimator 2017-11-26 16:42:26 -05:00
Daniel Agar d5ea688f00 delete exampales attitude_estimator_ekf 2017-11-26 16:42:26 -05:00
Daniel Agar dd7e82389c delete examples mc_pos_control_multiplatform 2017-11-26 16:42:26 -05:00
Daniel Agar 53e6d7eb9f delete examples mc_att_control_multiplatform 2017-11-26 16:42:26 -05:00
Daniel Agar b8e24b5d2f uORB delete unused vehicle_force_setpoint 2017-11-26 16:39:30 -05:00
Daniel Agar d3c87c77d2 uORB delete unused pwm_output 2017-11-26 16:39:30 -05:00
Daniel Agar 6ca86c3608 uORB delete unused filtered_bottom_flow 2017-11-26 16:39:30 -05:00
Amir Melzer a8787e8fe3 Add a driver for the Analog Devices ADIS16448 IMU (#8301) 2017-11-26 14:52:22 -05:00
Daniel Agar 246c47e0db RTL land use mavlink critical and log when starting landing 2017-11-26 14:40:13 -05:00
Daniel Agar 8567e3b924 RTL fix RTL_LAND_DELAY check and simplify logic 2017-11-26 14:40:13 -05:00
Julien Lecoeur 9439eaa5fa Python import error: Recommend pip over apt-get
closes #8297

The package python-toml does not exist in older (<= 14.04) versions of ubuntu.
2017-11-26 14:07:08 -05:00
Andreas Antener 4f5d70bbe5 Increase fixed-wing l1 navigation radius limit 2017-11-26 14:43:25 +01:00
Daniel Agar d6a609c552 FW enable EKF2 synthetic sideslip fusion by default 2017-11-25 21:01:00 -05:00
Daniel Agar ae42923025 uORB msg delete unused hil_sensor 2017-11-24 19:46:33 -05:00
Daniel Agar 2a6f915dfe px4io delete old v1 battery current and voltage 2017-11-24 22:22:14 +01:00
Daniel Agar 04fa54a077 Jenkins clean before building 2017-11-24 14:33:03 -05:00
sanderux b305900cae Scale FW cruise throttle based on baro presure 2017-11-24 16:33:57 +01:00
Martina a61974709b mc_pos_control_main: wrap yaw attitude setpoint for offboard mode 2017-11-24 09:10:31 +01:00
Daniel Agar ec27865184 px4fmu-v2 add additional modules and sync with v3 2017-11-24 09:02:17 +01:00
Daniel Agar 01691e626b Merge FMUv3 into FMUv2 2017-11-24 09:02:17 +01:00
Daniel Agar 08a108ee1b restore FMUv2 board versioning 2017-11-24 09:02:17 +01:00
Robbie Sharma ab51a41793 Removed [cal] references from calibration_log_critical() routines. 2017-11-24 08:12:37 +01:00
Daniel Agar b569a8c2b9 fw_pos_control_l1 increase stack by 110 Bytes (#8348) 2017-11-23 17:09:05 -05:00
Daniel Agar d6b455bb06 nuttx-configs remove unused aerocore 2017-11-23 12:35:55 -05:00
Daniel Agar f170b28fbc nuttx-configs remove cu and mount example 2017-11-23 12:35:55 -05:00
ChristophTobler a0f935916a add killswitch (manual_lockdown) to Snapdragon uart ESC 2017-11-23 07:10:44 +01:00
Daniel Agar d1a4c2dcd0 cmake handle git submodule depdencies 2017-11-23 00:22:45 -05:00
Daniel Agar cea2c36000 gitmodules add branch tracking
- update mavlink, cmake_hexagon, uavcan_board_ident to latest
2017-11-23 00:22:45 -05:00
Daniel Agar 7a5a497725 version lib find correct directory when used as a submodule 2017-11-23 00:22:45 -05:00
Florian Achermann a5cc4bcd08 Update SDP3x Airspeed Correction (#8242)
Update the model for the standard configuration based on the model from Sensirion and add also an option to do the tube pressure loss correction from Sensirion for other configurations.
2017-11-22 22:03:26 -05:00
Daniel Agar 85a7a0a86a parameters.xml sort parameters by name, sort enums by value 2017-11-22 13:42:54 -05:00
Daniel Agar 698bc7d848 qurt fc_addon fix missing library linking and cleanup 2017-11-22 10:36:51 +01:00
Daniel Agar 822fc5725c cmake px4_add_module() make properties private 2017-11-22 10:36:51 +01:00
Daniel Agar fc80846825 simplify param scoping and centralize dependencies 2017-11-22 10:36:51 +01:00
Daniel Agar e5cc1237e3 travis-ci fix coverity build 2017-11-22 02:23:07 -05:00
Avinash Reddy Palleti 456227f39e Add RTPS cmake config for AeroFC
Adding a seperate cmake config to support RTPS messaging on AeroFC. This will
include compiling protocol_splitter and micrortps_client, and starting both
of them at boot time.
2017-11-21 16:51:46 +01:00
Daniel Agar 8873d2d696 travis-ci coverity build install python-toml python-numpy 2017-11-21 00:39:53 -05:00
Daniel Agar 1a4f4b083c cmake nuttx keep builtins generated by nuttx apps (#8323) 2017-11-20 20:20:05 -05:00
Daniel Agar 00a47ba542 drivers device I2C consistency between nuttx/posix 2017-11-20 23:44:31 +01:00
Daniel Agar 8738fe8daf drivers device naming consistency 2017-11-20 23:44:31 +01:00
Daniel Agar 53595bac0e board support add px4_i2c_bus_external/px4_spi_bus_external 2017-11-20 23:44:31 +01:00
Daniel Agar 2aeb4aa55f drivers device move locking to cdev 2017-11-20 23:44:31 +01:00
Daniel Agar bf435fc520 drivers device merge nuttx and posix Device and CDev 2017-11-20 23:44:31 +01:00
Daniel Agar c6b6164cf7 drivers device nuttx remove unused interrupt support 2017-11-20 23:44:31 +01:00
Daniel Agar 5d20cf6b57 drivers device organize by nuttx/posix 2017-11-20 23:44:31 +01:00
Daniel Agar c1c176d65b cmake nuttx build net if enabled 2017-11-18 20:52:10 +01:00
makekam 3c252d973d mpu9250 test command use correct mag units (#8313) 2017-11-18 11:54:35 -05:00
Daniel Agar 7608cec1ed cmake NuttX improve builtin generation dependencies 2017-11-18 11:52:55 -05:00
Daniel Agar d35de9b4e3 cmake nuttx copy source into build with relative paths
- this works around cygwin path issues on windows
2017-11-18 11:52:55 -05:00
sanderux a07a2ebd73 Better scaling for reverse mixer 2017-11-18 13:51:46 +01:00
makekam 6ddbe91f42 Change the name of sdlog file in case of differential gps
The fix_type variable in ubx.cpp may be assigned to 4(DGPS) or 5(Float RTK) or 6(Fixed RTK). So if we use differential gps, the value of the fix_type variable may not be 3. But gps still has 3d data and gps time. So The name of the file should named with gps time.My ublox differential gps fix_type is 5 (Float RTK).
2017-11-18 13:49:58 +01:00
makekam e9e663432b bmm150 fix I2C bus define (#8261)
According to the board_config.h shown. bmm150 only on the external i2c bus
2017-11-15 23:30:09 -05:00
Daniel Agar cc0be3e150 README remove gitter badge 2017-11-15 22:47:58 -05:00
Beat Küng 3744cac1bb fix mc_att_control: re-add dropped acro parameters (#8293)
and make sure the vtol params are always initialized

This got lost in 4416c4ddb3
2017-11-15 10:08:22 -05:00
Paul Riseborough 44a71ad6c9 ekf2: Update parameter descriptions (#8292)
Make it clearer that the gate parameters control innovation consistency checks and that the gate size is specified in standard deviations.
Also make it clear that the EKF2_BARO_GATE also controls the GPS height fusion.
2017-11-15 09:19:08 -05:00
Matthias Grob 26171df9fc mc_pos_control: save previous velocity setpoint after constraining, fix smooth takeoff to be still excluded from slewrate 2017-11-15 10:38:57 +01:00
Julien Lecoeur 26d95ef674 Mixers: Include mixer_multirotor_normalized.generated.h everywhere 2017-11-15 09:56:10 +01:00
Julien Lecoeur 2ca00f1a65 Docker: update images to tag 2017-10-23 2017-11-15 09:56:10 +01:00
Julien Lecoeur 4be4ad86a0 Mixers: Add geometry quad_s250aq 2017-11-15 09:56:10 +01:00
Julien Lecoeur 3a1c5f8a94 Mixers: do not allow several mixers with same name or key 2017-11-15 09:56:10 +01:00
Julien Lecoeur 76447b0f4e Mixers: Use geometry filename as mixer name 2017-11-15 09:56:10 +01:00
Julien Lecoeur d43b33b1c4 Move src/lib/mixer/geoms to src/lib/mixer/geometries 2017-11-15 09:56:10 +01:00
Julien Lecoeur b6911c2266 Mixers: Rename geom -> geometry(ies) 2017-11-15 09:56:10 +01:00
Julien Lecoeur c95229faab Mixers: add --verbose option to print matrices 2017-11-15 09:56:10 +01:00
Julien Lecoeur 142cd7ee75 Mixers: write to stdout if no output file is provided 2017-11-15 09:56:10 +01:00
Julien Lecoeur 679f33b406 Mixers: raise exception if no input geometry is provided 2017-11-15 09:56:10 +01:00
Julien Lecoeur 9e045e3b2a Mixers: use os.path.join 2017-11-15 09:56:10 +01:00
Julien Lecoeur 89642a9203 Move src/module/systemlib/mixer to src/lib/mixer 2017-11-15 09:56:10 +01:00
Julien Lecoeur d46c37be79 Mixers: raise exception when geom file is incomplete
pylint format
2017-11-15 09:56:10 +01:00
Julien Lecoeur cb8d951a7e Mixers: add geoms quad_vtail (tilted props) and quad_y (rear coax props)
quad_vtail: reverse prop direction (same quad_h) to combine yaw torque induced by propellers and yaw torque induced by tilted rotors.
2017-11-15 09:56:10 +01:00
Julien Lecoeur 3e35dcb7dd Mixers: Use geometry of SK450 deadcat for both quad_wide (centered CG) and quad_deadcat (off-centered CG) 2017-11-15 09:56:10 +01:00
Julien Lecoeur 758d214dd1 Mixers: Add geometries
Mixers: add quad_x, quad_h, quad_plus

Mixers: add quad_deadcat

Set quad_deadcat.toml according to dimensions of SK450 deadcat

Mixers: add hex_x, hex_plus, hex_cox and hex_t

Mixers: add geoms octa_x, octa_plus, octa_cox

Mixers: add wide geoms

Mixers: add tri_y and twin_engine geoms

Mixers: add dodeca geoms

Mixers: Add geom quad_x_pusher
2017-11-15 09:56:10 +01:00
Julien Lecoeur 2c4228ce98 Mixers: generate all versions (new,normalized,6dof,legacy) 2017-11-15 09:56:10 +01:00
Julien Lecoeur 99f6c4dbc3 Mixers: Generate from geometry description files
Mixers: List geom files in CMakeLists.txt

Mixers: add option to normalize like legacy script

Fix py2 compatibility
2017-11-15 09:56:10 +01:00
Julien Lecoeur f06695c7b1 CircleCI: install python-toml 2017-11-15 09:56:10 +01:00
Julien Lecoeur 4991ab5362 Mixers: use key list to select multirotor mixer 2017-11-15 09:56:10 +01:00
Daniel Agar aa789f5e8a voted sensors set enabled by default 2017-11-15 01:34:59 -05:00
Daniel Agar fabab8ac4d sensors remove barometer enabled check for now 2017-11-15 01:34:59 -05:00
Daniel Agar 8d27925443 change CAL_MAG_SIDES param group 2017-11-14 15:54:37 -05:00
Daniel Agar 1ccbaf4cd2 sensors params split by sensor index 2017-11-14 15:54:37 -05:00
Daniel Agar 273742aa0d add boolean parameters to enable/disable each sensor 2017-11-14 15:54:37 -05:00
Daniel Agar 84f07c64b0 Navigator RTL fully initialize mission item in each state 2017-11-14 14:57:34 -05:00
Daniel Agar 98cbd44526 RTL check alt_max before using
- fixes #8257
2017-11-14 14:57:34 -05:00
Dennis Mannhart 05c00855c4 navigator: reset triplets if navigation mode changes (#8285) 2017-11-14 11:32:21 -05:00
Julien Lecoeur ef906d08d3 Jenkins: update docker image (#8286) 2017-11-14 10:01:07 -05:00
Paul Riseborough a410893080 ecl: Update ekf2 to version that addresses known vulnerabilities
See:

https://github.com/PX4/ecl/pull/350
https://github.com/PX4/ecl/pull/354

Note the amount of stack allocation has had to be increased to accomodate pr350
2017-11-13 22:50:12 +01:00
Beat Küng c2c8ed6f5c navigator: make FollowTarget::_follow_position_matricies constexpr (#8281)
The matrix is never changed and has a size of 144 bytes.
2017-11-13 12:30:33 -05:00
ChristophTobler f2e8aabda4 use int32_t instead of int 2017-11-13 16:59:03 +01:00
Julian Oes 585b03898f vtol_att_control: ack transition commands
Previously transition commands were not acked at all which meant that a
mavlink consumer such as a ground station would not get feedback if the
command arrived.

This solution is not optimal because it does not take into account if
the transition actually happened but at least it is feedback that the
command has arrived at the destination.
2017-11-13 09:56:11 -05:00
Lorenz Meier 4028692bfe Navigator: Limit string copy to length of target array 2017-11-13 09:59:54 +01:00
korigod c3fe7e989e integrationtests: upgrade numpy before px4tools install (#8274)
During px4tools installation, the latest version of pandas is
installed, which requires numpy>=1.9.0. Pandas installs the required
version, however, due to the presence of the old numpy in the docker
image, the present version 1.8.2 is used, which leads to an error
when importing pandas.

This commit fixes the problem by explicitly upgrading numpy before
px4tools installation.

Signed-off-by: Andrey Korigodsky <akorigod@gmail.com>
2017-11-12 23:33:36 -05:00
garfieldG cddea6f4b3 Fixed version firmware type (#8250)
* Fixed the version tag to number and version tag to vendor version number to return dev version in case of any local modifications or in case there's a dash before firmware type in tags that support vendor  version.
2017-11-11 20:04:16 -05:00
Julien Lecoeur 4e7bd576cb generate_listener.py: generate one function per topic to fit function sizelimit 2017-11-09 10:54:35 +01:00
Julien Lecoeur 8f2759ba79 topic_listener: allow multi-topic messages 2017-11-09 10:54:35 +01:00
Beat Küng cf7140526a jMAVSim: update submodule to include fix for VMware driver 2017-11-08 10:47:57 +01:00
Daniel Agar 0a58bd309c EKF2 always publish status message (#8234)
* EKF2 always publish status message

* EKF2 fix comment typo

* EKF2 time slip use signed int and consolidate

* EKF2 minor readability improvements
2017-11-08 07:55:50 +11:00
Daniel Agar aa699cf4b7 Jenkins track test results (#8236) 2017-11-05 15:04:14 -05:00
TSC21 5a17f6b2d5 lpe: update _sensorTimeout init on constructor 2017-11-03 23:45:43 +01:00
TSC21 483f0d55e0 lpe: style fix 2017-11-03 23:45:43 +01:00
TSC21 051822eee1 lpe: remove unneeded subscriber to manual_control_setpoint 2017-11-03 23:45:43 +01:00
TSC21 691c35f47e lpe: small fixes 2017-11-03 23:45:43 +01:00
TSC21 e6efb5ec0a lpe: update _sensorTimeout and _sensorFault to handle support of more sensors 2017-11-03 23:45:43 +01:00
TSC21 392999c2df lpe: fix innovation covariance publishing 2017-11-03 23:45:43 +01:00
avinash-palleti 76fcd99241 Fix protocol_splitter compilation issues (#8230)
Fixing compilation warnings which are treated as errors.
2017-11-03 15:35:46 +05:30
Beat Küng 459a71a6f1 mavlink_receiver: directly pass the result to acknowledge()
And use denied in case ulog streaming fails.
2017-10-31 22:16:06 +01:00
Beat Küng a2db639289 mavlink_receiver: disable ulog streaming via Telemetry links
Telemetry links don't have enough bandwidth for that feature. The vehicle
will return a NACK when trying to enable log streaming on such a link.
2017-10-31 22:16:06 +01:00
Beat Küng 8f7a5d0e0c mavlink_receiver: merge handle_message_command_{long,int} into a common method 2017-10-31 22:16:06 +01:00
Beat Küng 29af2343e1 fix NAV_TRAFF_AVOID param definition: needs a ;
Without that the parameter was not in parameters.xml, producing the error:
ERROR [lib__controllib] error finding param: NAV_TRAFF_AVOID
2017-10-31 11:18:49 +01:00
Lorenz Meier a1a002f9b6 Navigator: Add the ability to do a low-altitude RTL to avoid traffic
This is a first baseline implementation for collision avoidance with aircraft equipped with transponders. Since the drone-to-drone and drone-to-airplane system will be regulated by a standard, we do carefully avoid to do anything too fancy. This implementation allows to reduce altitude to get close to ground and land immediately or RTL. This is similar to what a human pilot would do and allows to get out of manned airspace which is at higher altitudes.
2017-10-31 09:10:32 +01:00
Daniel Agar 330eed2bd6 circleci parallel compile 2017-10-31 08:13:38 +01:00
Daniel Agar 56bbe541ae travis-ci remove tests under UBSAN 2017-10-31 08:13:38 +01:00
Daniel Agar 9ff7f05d94 travis-ci remove tests under ASAN 2017-10-31 08:13:38 +01:00
Daniel Agar 43c0622819 travis-ci remove scan-build 2017-10-31 08:13:38 +01:00
Daniel Agar c4fd467c19 travis-ci remove cppcheck 2017-10-31 08:13:38 +01:00
Daniel Agar a567b94802 travis-ci remove check_stack 2017-10-31 08:13:38 +01:00
Daniel Agar 02339055e7 travis-ci remove check_format 2017-10-31 08:13:38 +01:00
Daniel Agar 14fefca85e vmount delete InputTest on error
- fixes CID 139488
2017-10-31 08:12:12 +01:00
Daniel Agar 0931efb3f0 vmount initialize params
- fixes CID 199479
2017-10-31 08:12:12 +01:00
Daniel Agar ce78f254c2 mavlink parameters initialize struct
- fixes CID 141890
2017-10-31 08:11:18 +01:00
Daniel Agar 5436801435 esc_calib properly cleanup on failure
- fixes CID 139514
2017-10-31 08:10:51 +01:00
Daniel Agar 21995bd4b7 sensors ignore invalid failover index
- fixes CID 199478
2017-10-31 08:10:04 +01:00
sanderux dd9179efc9 Adaptive QuadChute disabled in manual modes 2017-10-30 20:57:47 +01:00
sanderux fc16a31f89 Adaptive quadchute 2017-10-30 20:57:47 +01:00
Beat Küng 9c8dc3941d commander: fix 'commander arm' not working in HIL mode
This got introduced with 61b0a81bf9. Due to the removed startup_in_hil flag,
this check does not work anymore, so remove it completely.
2017-10-30 20:53:58 +01:00
davidaroyer f6693f1f17 drivers: remove ocpoc_sbus_rc_in 2017-10-30 20:53:28 +01:00
davidaroyer 2fab183731 posix-configs: use linux_sbus on ocpoc 2017-10-30 20:53:28 +01:00
davidaroyer b0942e996b cmake: use linux_sbus for ocpoc target 2017-10-30 20:53:28 +01:00
davidaroyer 090b668075 cmake: add missing vehicle control modules to ocpoc 2017-10-30 20:53:28 +01:00
Daniel Agar 466eb9ceb4 travis-ci remove metadata build and s3 uploads 2017-10-30 15:25:08 -04:00
PX4 Build Bot 642c2ca2f5 don't update devguide and user guide from pipeline 2017-10-30 15:25:08 -04:00
Lorenz Meier afc8503260 PX4IO Firmware: Fix usage of new operator in IRQ
The mixer was creating a new class in interrupt context, which is not valid use in NuttX. This change copies the mixer into the buffer and runs the mixer management section of the code outside of interrupt context in the normal task.
2017-10-30 20:03:19 +01:00
Daniel Agar 509ac10ccc JenkinsFile updates (#8210)
- check format first
 - build on nuttx_px4fmu-v2_default
 - generate all metadata
 - stubs for deploying metadata and binaries
2017-10-30 10:20:23 -04:00
Paul Riseborough b3d045d4d0 Revert "add boolean parameters to enable/disable each sensor"
This reverts commit 9fde19259e.
2017-10-30 20:49:36 +11:00
Paul Riseborough 3a57712d2b ecl: Use commit on master
This is a non-functional change that point to a commit on master instead of the merged branch.
2017-10-30 08:21:09 +01:00
Paul Riseborough 589d58ce87 ekf2: Fix bug preventing first IMU failover bias reset 2017-10-30 08:21:09 +01:00
Paul Riseborough 0c9e07c95a ekf2: repeat IMU bias reset until successful 2017-10-30 08:21:09 +01:00
Daniel Agar 9fde19259e add boolean parameters to enable/disable each sensor 2017-10-29 16:24:31 +01:00
Daniel Agar e1e3c9fca9 sensors split accel/gyro/mag calibration parameters 2017-10-29 16:24:31 +01:00
Daniel Agar 8b7de092a2 sensors delete unused CAL_BOARD_ID 2017-10-29 16:24:31 +01:00
Daniel Agar 2a1ecaa13e sensors reduce priority of a failed sensor 2017-10-29 16:24:31 +01:00
Daniel Agar e5ead354f0 EKF2 reset IMU bias if the accel or gyro changes 2017-10-29 16:24:31 +01:00
Julian Oes 6d8d6323cb navigator: bring follow me back to life
The function `mission_item_to_position_setpoint()` is called in
`FollowTarget::update_position_sp()`. The nav_cmd is a
NAV_CMD_DO_FOLLOW_REPOSITION as set earlier in `set_follow_target_item`.

Since `mission_item_to_position_setpointi` returns early because the item
presumably contains no position, the lat/lon of the mission_item are
not copied over to the position_setpoint and therefore the vehicle will
never move in follow me position mode.
2017-10-29 12:58:00 +01:00
Julian Oes 10de946cdf navigator: remove leftover debug variable 2017-10-29 12:58:00 +01:00
Matthew Dailey bcb8852c99 Use fabsf instead of fabs for floats 2017-10-29 12:57:10 +01:00
Matthew Dailey e95410882b Fix type of MNT_OB_LOCK_MODE and MNT_OB_NORM_MODE parameters
Fixes issue #8178
2017-10-29 12:57:10 +01:00
Daniel Agar f4b7a1911e circleci fix build reconfigure loop (#8202)
- use make instead of ninja on OSX for now
2017-10-27 11:45:00 -04:00
Daniel Agar db6e2d17ce initial Jenkinsfile (#8201) 2017-10-27 10:47:38 -04:00
Beat Küng 44839208f7 jmavsim_run.sh: add more aggressive GC option
This reduces memory usage by roughly 100MB on my laptop
2017-10-27 10:43:45 +02:00
Beat Küng 083a59ebc0 Tools/jMAVSim: update submodule (updated textures & rendering) 2017-10-27 10:43:45 +02:00
Beat Küng 9b85b39c07 syslink_main: fix int type passed to param_get() 2017-10-27 10:43:15 +02:00
Beat Küng a2fd9ef2d0 PreflightCheck: use correct type for params (int -> int32_t) 2017-10-27 10:43:15 +02:00
Beat Küng 207fdc0f12 mc_att_control_main: use correct type for params (int -> int32_t) 2017-10-27 10:43:15 +02:00
Beat Küng c3b47b71de temperature_compensation: use correct type for params (int -> int32_t) 2017-10-27 10:43:15 +02:00
Beat Küng 96616d831e sensors: fix parameter type int -> int32_t 2017-10-27 10:43:15 +02:00
Beat Küng 8a693fa13d param: undefine CHECK_PARAM_TYPE after it's used 2017-10-27 10:43:15 +02:00
Beat Küng dbb0414e01 commander: remove unused SYS_AUTOSTART param 2017-10-27 10:43:15 +02:00
Beat Küng 8cbd772489 commander: fix wrong parameter types (these are defined as float, not int) 2017-10-27 10:43:15 +02:00
Beat Küng d74f792784 commander: fix type passed to param_get() 2017-10-27 10:43:15 +02:00
Beat Küng f9dedd627f camera_feedback: fix type passed to param_get() 2017-10-27 10:43:15 +02:00
Beat Küng ca7e6fc918 camera_trigger: fix type passed to param_get() 2017-10-27 10:43:15 +02:00
Beat Küng 530fdb0b61 arm_auth: make type passed to param_get() explicit 2017-10-27 10:43:15 +02:00
Beat Küng 861f5a3d11 mag_calibration: fix type passed to param_get() 2017-10-27 10:43:15 +02:00
Beat Küng 0dcf9775f1 LandDetector: make type passed to param_get() explicit 2017-10-27 10:43:15 +02:00
Beat Küng 41a4d07e4f logger: make type passed to param_get() explicit 2017-10-27 10:43:15 +02:00
Beat Küng c997698030 mavlink: fix type passed to param_get() 2017-10-27 10:43:15 +02:00
Beat Küng 07d7b29729 simulator_mavlink: fix type passed to param_get() 2017-10-27 10:43:15 +02:00
Beat Küng c35b0aa270 param: redefine type-safe versions for param_get() when used in C++ code 2017-10-27 10:43:15 +02:00
Daniel Agar 4416c4ddb3 navigator move parameters out of MissionBlock
- MissionBlock is an interface with > 10 implementations
2017-10-26 22:43:53 +02:00
ChristophTobler 8e457b6037 reset setpoint to current position
avoid abrupt position changes as the delta can be quite big depending on deadreckoning/imu
2017-10-26 21:36:36 +02:00
Daniel Agar bd84061ea5 px4fmu-v2_default add sf1xx driver (#8185)
- closes #8177
2017-10-26 09:42:09 -04:00
mirkix 69231ea249 SDP3X: fix comment 2017-10-26 00:58:27 +02:00
Daniel Agar 48cfb37c5a move bottle_drop to examples (#8187) 2017-10-25 16:05:39 -04:00
TSC21 2a2d968b2c modules: lpe: fix double correction on lidar 2017-10-25 19:39:33 +01:00
Matthew Edwards 335c319b2e vmount: Use MNT_DO_STAB parameter for defaults in InputMavlinkCmdMount as well. 2017-10-25 11:30:31 +02:00
Matthew Edwards fdf4eb0bd6 vmount: Store offset in radians and calculated scale factor in OutputConfig instead of raw parameters. 2017-10-25 11:30:31 +02:00
Matthew Edwards ccf3e71b56 Bump parameter.xml minor version (#8120). 2017-10-25 11:30:31 +02:00
Matthew Edwards 2f40bc3a78 vmount: Add parameters for servo range and offset and whether to stabilize (#8120).
Adds MNT_DO_STAB for whether to stabilize by default.
Adds MNT_RANGE_{PITCH,ROLL,YAW} for the output range of each output channel in AUX mode (instead of hardcoded 360 degrees).
Adds MNT_OFF_{PITCH,ROLL,YAW} for adjusting the zero point of each output channel.
2017-10-25 11:30:31 +02:00
Beat Küng 8ec59f0bc9 status_display: remove unused vehicle_attitude topic 2017-10-24 13:15:14 +02:00
Beat Küng 5f1debd431 px4fmu-v2 cmake config: disable mpu9250
out of flash again...
2017-10-24 13:15:14 +02:00
ChristophTobler 9be8d6acc9 add subscriber handler and status displays 2017-10-24 13:15:14 +02:00
Finwood ba11e0dc44 use tabs for indentation 2017-10-22 22:05:56 +02:00
Lasse e2a359143d use altitude acceptance radius for MC takeoff check
When checking a mission, the takeoff altitude is being checked
against the waypoint acceptance radius to ensure the MAV being
clear from ground before heading to the next waypoint.
However, until now the _horizontal_ acceptance radius was being
used, instead of the altitude reference value.

Targets PX4/Firmware/#7379
2017-10-22 22:05:56 +02:00
Daniel Agar 812f9ea11d update ECL to latest master (includes tecs) 2017-10-22 21:56:06 +02:00
Daniel Agar a133b12635 delete fw_pos_control_l1/mtecs 2017-10-22 21:56:06 +02:00
Daniel Agar 729e721ef3 update LICENSE for github 2017-10-22 21:56:06 +02:00
Daniel Agar fa8629f6c7 nxphlite config remove external_lgpl 2017-10-22 21:56:06 +02:00
Paul Riseborough 3fc7aba178 TECS: Use version in ECL library
This change updates a number of interfaces to use the new TECS implementation from the ECL library.
2017-10-22 21:56:06 +02:00
Lorenz Meier 4923d0cba3 Remove TECS from system codebase
The TECS controller belongs really into the ECL (estimation & control library) where we have collected a number of vehicle control systems. It is being replaced by a new implementation of the algorithm, contributed by Paul Riseborough.
2017-10-22 21:56:06 +02:00
DonLakeFlyer 8693c51cba Fix bad meta data 2017-10-21 20:17:41 +02:00
Paul Riseborough c9f44531c2 logger: Add logging profile to support comparison of multiple sensors (#8134) 2017-10-20 09:30:55 -04:00
Daniel Agar 136d259876 travis-ci fix coverity scan and px4_metadata (#8156) 2017-10-20 09:20:30 -04:00
Beat Küng aa92ef3ca6 airframe 4040_reaper: fix type to quad h 2017-10-19 07:45:40 +02:00
Paul Riseborough 85c076d54e update ecl/ekf submodule 2017-10-18 11:08:58 +02:00
ChristophTobler d7c8d53489 use get() for BlockParam 2017-10-18 11:08:58 +02:00
ChristophTobler 2a23162f8d update ecl/ekf submodule 2017-10-18 11:08:58 +02:00
ChristophTobler 40b8d8bd48 use distance to ground if on ground an distance is out of range 2017-10-18 11:08:58 +02:00
Julian Oes 787931f04f navigator: check distances between waypoints
Instead of just checking whether the first waypoint is too far away from
home it makes sense to also check between waypoints.
This can prevent
- flyaways due to user errors, or
- catch the corner case where a takeoff waypoint is added to a mission
  and therefore the first waypoint is not too far away, however, the
  subsequent waypoints are still too far away.
2017-10-18 08:42:20 +02:00
Beat Küng 8b797d9b05 logger: use int for loop counter 2017-10-18 08:40:32 +02:00
Beat Küng d930ad4e9e mavlink_orb_subscription: reduce orb_exists() check from 10Hz to 3Hz
Checking with 3Hz for new topics should be fast enough.
2017-10-18 08:40:32 +02:00
Beat Küng 7381ea8222 logger: remove unused topics commander_state & rc_channels
flight review now uses vehicle_status & manual_control_setpoint
2017-10-18 08:40:32 +02:00
Beat Küng d096ec0b61 vdev_posix: change filemap into a static list of objects instead of pointers
to avoid dynamic memory allocations & frees (specifically in orb_exists)
2017-10-18 08:40:32 +02:00
Beat Küng 2668055358 vdev: remove unused fileds from file_t 2017-10-18 08:40:32 +02:00
Beat Küng deaf125c81 logger: check for newly published topics while not logging
If logger is started very early, orb_exists() will fail for a lot of
topics, they will be advertised within the next few seconds.
Logger already dynamically adds subscriptions during logging, but if we
do that before as well, we'll avoid any delays and having to subscribe
to a lot of topics all at once.
2017-10-18 08:40:32 +02:00
Beat Küng 3be252289a logger: use orb_exists to check if we need to subscribe to the first instance
To keep track of the configured interval, we store it as negative file
descriptor, until we do the subscription.

This frees up a considerable amount of file descriptors in most use-cases.
2017-10-18 08:40:32 +02:00
Beat Küng 4c4b528842 uORBManager: fix code style 2017-10-18 08:40:32 +02:00
Beat Küng 2f2c0440c4 orb_exists: change semantics from (is published or subscribed) to (is published)
Existing users of orb_exists:
- logger (dynamic subscribe to multi-instances)
- mavlink (orb subscription)
- sdlog2
- preflightcheck (check for home_position)
- wait_for_topic shell command (it's not used)
- orb_group_count() (sensors: dynamic sensor addition)

All use-cases benefit from the changed semantics: they are really only
interested if there is a publisher, not another subscriber.
2017-10-18 08:40:32 +02:00
Daniel Agar d83073f016 move RTPS to dedicated px4fmu-v{3,4,4pro,5}, posix, sdflight builds (#8113) 2017-10-17 16:29:55 -04:00
Daniel Agar 979d092628 travis-ci enable tests under address sanitizier (#8095) 2017-10-17 16:26:17 -04:00
Daniel Agar c607805154 travis-ci allow coverage failures (#8145) 2017-10-17 10:54:45 -04:00
Matthias Grob e12bfa30d4 mc_att_control: defualt parameters set maximal acro rates to 2/1.5 turns per second for roll,pitch/yaw 2017-10-17 16:54:16 +02:00
Matthias Grob 8b09eaf124 mc_att_control: use SuperExpo input curve for acro mode to further enhance the stick feel 2017-10-17 16:54:16 +02:00
Matthias Grob 455ba0e1b5 mathlib Functions: added SuperExpo function for stick feel enhancement 2017-10-17 16:54:16 +02:00
Matthias Grob 3ce5525b7c mc_att_control: use expo input for acro mode to allow for high input rates without loosing input sensitivity 2017-10-17 16:54:16 +02:00
Beat Küng 747e392be6 px4fmu-v2 cmake config: disable team blacksheep telemetry driver
we're out of flash again :/
2017-10-17 09:56:01 +02:00
Beat Küng 291872a28d mavlink: fix flight_information: use COM_FLIGHT_UUID instead of the board id
The board id was used as flight id which does not make sense.
2017-10-17 09:56:01 +02:00
Beat Küng 85e82dca0d commander: add COM_FLIGHT_UUID param, increased upon disarm 2017-10-17 09:56:01 +02:00
Beat Küng fa8453443f fix commander: remove arming_state_changed, check for was_armed != armed.armed instead
arming_state_changed was not set in all places where an arming transition
occurred, for example when calling arm_disarm() from auto-disarm.

We did not notice because the state is published with at least 5 Hz already.
2017-10-17 09:56:01 +02:00
José Roberto de Souza 239de7191f dataman: Prevent database corruption
The size in g_per_item_size[item] is the real struct size
+ DM_SECTOR_HDR_SIZE bytes of header and the backend functions were
not taking in care it. So a call to dm_write() with more bytes than
the real struct is allowed, causing corruption in the header of the
next item.

Kudos to jeonghwan-lee for finding it. https://github.com/PX4/Firmware/issues/7927
2017-10-16 23:38:03 +02:00
Luís Felipe Strano Moraes cc724438f9 Adding Sugnan as maintainer for Intel Aero (#8133)
Adding Sugnan Prabhu as maintainer for Intel Aero.
With great power comes great responsibility!
2017-10-16 11:25:32 -04:00
rde-mato 78a9658163 define SDP3X_SCALE_PRESSURE_SDP3X corrected 2017-10-15 15:54:08 +02:00
sanderux fd6f2192ac Code style 2017-10-15 15:34:59 +02:00
sanderux b01d887700 When switching to land in VTOL, update land target during back transition 2017-10-15 15:34:59 +02:00
Khoi Tran ff6ffa73b5 Fix typos in MPU6000 driver comments 2017-10-15 15:33:25 +02:00
Khoi Tran 1594c80bf4 Add icm20602 to auav-x21 sensors startup 2017-10-15 15:33:25 +02:00
Beat Küng 98e6ba858d logger: change SDLOG_PROFILE into a bitset
This is more flexible, allowing a combination of sets.

The default enables the same set & rates as before
2017-10-14 14:21:11 +02:00
Beat Küng be6079bc52 logger: add high rate & debug profiles 2017-10-14 14:21:11 +02:00
Julian Oes 07ae1e4044 posix-configs: attitude quaternion for DroneCore
DroneCore uses the attitude quaternion, and not the attitude
Euler angles.
2017-10-13 18:11:33 +02:00
Julian Oes 2837870733 posix-configs: send gimbal attitude to mavros port
The gimbal attitude is required by DroneCore.
2017-10-13 18:11:33 +02:00
Julian Oes 1e91b8cd32 posix-configs: send gimbal attitude over mavlink 2017-10-13 18:11:33 +02:00
Beat Küng 30bc248138 rc_check: cleanup mavlink log messages 2017-10-13 15:50:37 +02:00
Daniel Agar c47cd972a8 attitude_estimator_q remove unused (#8106) 2017-10-13 00:54:52 -04:00
Beat Küng 4da4093839 logger status output: print 'Not logging' if not actually logging 2017-10-12 16:40:47 +02:00
Beat Küng e65547b6af mpu6000: add support for revision 1 2017-10-12 14:27:04 +02:00
acfloria 3929afd617 Fix format in test_mixer.cpp 2017-10-12 12:03:22 +02:00
acfloria 5f165e8b3e Add the flaperons again to the AAERTWF mixer 2017-10-12 12:03:22 +02:00
acfloria 9d2da611f6 Fix mixer issue with undefined return in callback and non value initialized variables. 2017-10-12 12:03:22 +02:00
Lucas De Marchi fdc1a2fd39 aerofc-v1: fix mentions to tap board 2017-10-12 10:00:51 +02:00
Lucas De Marchi 4a0ee8be6e aerofc-v1: fix chip selection
aerofc-v1 uses a STM32F429V not STM32F427V.
2017-10-12 10:00:51 +02:00
Lucas De Marchi 3a84d4cfeb build: fix NuttX menuconfig
There was and extra "nuttx" dir:
	cp: cannot stat '/home/lucas/p/dronecode/PX4/Firmware/build/aerofc-v1_default/NuttX/nuttx/nuttx/.config': No such file or directory
	FAILED: NuttX/CMakeFiles/menuconfig

And the board fixup being executed from the wrong working directory:
	nuttx-configs/aerofc-v1/nsh/defconfig
	fatal: Path 'nuttx-configs/aerofc-v1/nsh/defconfig' does not exist in 'HEAD'
2017-10-12 10:00:51 +02:00
Beat Küng 0247d7bdd7 fmu: minor refactoring & fixes
- initialize rc lost with true
- refactor for simpler downstream code-plugin
- allow for the addition of different binding commands
- fix st24 RC lost logic
2017-10-12 08:55:24 +02:00
Daniel Agar bb78931e69 cmake fix ctest output on failure for coverage (#8112) 2017-10-11 14:08:40 -04:00
Daniel Agar 5ddd95e18f circleci force make distclean before build (#8111) 2017-10-11 13:33:22 -04:00
Daniel Agar 651df03f76 RTPS and micro-CDR build system cleanup (#8084) 2017-10-11 13:05:44 -04:00
Dennis Mannhart bb9f8c3b44 navigator set cruising speed/throttle for reposition (#8096) 2017-10-11 10:30:03 -04:00
Dave Royer d1500dca6f df_hmc5883_wrapper: set mag device path from input argument (#8079) 2017-10-11 10:27:25 -04:00
Sugnan Prabhu 81809be7cd Add include guard in headers files (#8108)
Signed-off-by: Sugnan Prabhu S <sugnan.prabhu.s@intel.com>
2017-10-11 09:47:52 -04:00
Beat Küng 553c8b38d2 rcS: start mavlink in normal mode on Pixracer for the WiFi module
The config mode uses high rates for many streams, leading to high CPU usage
(9-10% for the mavlink sender). The normal mode contains almost the same
set of messages but at lower rates.
This reduces the CPU load on a Pixracer by 3-4%.
2017-10-11 11:55:59 +02:00
Daniel Agar 577a8ef05c circleci fix homebrew by updating first (#8104) 2017-10-10 15:14:07 -04:00
Dennis Mannhart 8a0a8e20e1 mc_pos_control: use correct altitude as limit
fadfdasf
2017-10-10 10:28:07 +02:00
Dennis Mannhart 115e7246b0 battery: only propagate warning state in upwards 2017-10-10 10:28:07 +02:00
Dennis Mannhart f9b8afc006 Navigator: Use maximum flight altitude to limit missions
This change limits all mission items to the maximum flight altitude. The mission will still be executed and flown,
but the vehicle will never exceed the mission altitude. This ensures the vehicle can always reach the mission
items. Wether or not the entire mission should be rejected if it falls outside of the fenced area is enforced
in the mission feasibility checker function.
2017-10-10 10:28:07 +02:00
Dennis Mannhart 29cdb655c3 landdetector: remove outdated comment 2017-10-10 10:21:09 +02:00
Martina ef07c3be20 st24: move decode state to header file 2017-10-10 09:06:09 +02:00
Martina a7956c401b st24: move decode state to header file 2017-10-10 09:06:09 +02:00
Lorenz Meier 5278791f3d IST8310 driver: Fix startup / calibration order
The IST driver did not optimally check the calibration result and could trigger false positives if the mag data aligned with wrong signs
2017-10-09 19:05:46 +02:00
Dennis Mannhart 44a71d90f5 mc_pos_control: takeoff threshold to 0.65 2017-10-09 19:05:15 +02:00
Julian Oes 7229ec2a37 Move throttle check from land detector to posctrl
This commit is an attempt to fix a race condition happening on takeoff
between the land detector and the multicopter position controller.

Previously, an auto-takeoff leads to the following events:

1. A takeoff setpoint is given.
2. The thrust setpoint spikes because we don't enter smooth takeoff yet.
3. The land detector detects a takeoff because of the high thrust.
4. The position controller sees the landed state transition and
   initiates the smooth takeoff. Thrust goes back down.
5. Depending on control gains the takeoff is successful or fails
   if the smoothing takes too long which causes thrust to be too low, so
   the land detector detects land again.

The two obvious problems with this are:
- The intermittent spike.
- The failed takeoff because of the smoothing leads to a delay..

With this change, the logic for a takeoff detection is moved from the
land detector to the position controller.

The events are now:

1. A takeoff setpoint is given.
2. The position controller detects the takeoff setpoint and initiates
   the smooth takeoff.
3. As thrust ramps up, the land detector detects the take off.

In the same way, we now detect the intent to takeoff in manual,
altitude, control, position control in the position controller instead
of in the land detector.
2017-10-09 19:05:15 +02:00
Dario Röthlisberger 3edc5942e4 versioning: fix style 2017-10-09 14:41:58 +02:00
Dario Röthlisberger e3b8c0512e versioning: refactor unit tests
Use one function which tests flight and vendor version tag parsing.
2017-10-09 14:41:58 +02:00
Dario Röthlisberger 6abe198226 versioning: tag must contain patch, minor & major 2017-10-09 14:41:58 +02:00
Dario Röthlisberger 3dd4454a87 version: include FIRMWARE_TYPE in vendor version 2017-10-09 14:41:58 +02:00
Dario Röthlisberger 257e54b304 logger: write vendor version if existent 2017-10-09 14:41:58 +02:00
Dario Röthlisberger bb644ee087 unittests: add versioning test 2017-10-09 14:41:58 +02:00
Dario Röthlisberger 28ca3b8d4c version: add support for vendor version
This adds support for parsing git tags which include a vendor version.
E.g. vX.Y.Z-A.B.Crc1, whereas X.Y.Z are numbers defining the upstream
version and A.B.C is the vendor version.
2017-10-09 14:41:58 +02:00
Dennis Mannhart 0d7d6e59f5 mc_pos_control: description fix 2017-10-09 10:20:29 +02:00
Matthias Grob 2b7dcd3f34 mc_pos_control: multiple small fixes in position controller we acumulated over time during our PX4 deployment and want to contribute back 2017-10-09 10:20:29 +02:00
Matthias Grob c177d6491a mc_pos_control: simplify unnecessary complicated boolean conditions 2017-10-09 10:20:29 +02:00
Beat Küng e1b970c30d ver hwcmp: allow to specify multiple hardware identifiers
E.g: ver hwcmp PX4FMU_V4 PX4FMU_V5
2017-10-09 09:34:31 +02:00
Daniel Agar a88203cec2 travis-ci codecov add unittests flag (#8092) 2017-10-09 03:23:49 -04:00
ChristophTobler 791e420d42 increase max num params per block because of ekf2 2017-10-09 08:58:01 +02:00
Paul Riseborough ed950d70ce ekf2: Add missing documentation 2017-10-09 08:58:01 +02:00
Paul Riseborough dbc3a13236 ekf2: remove unused parameter
The logging of replay data is now controlled by the logging module
2017-10-09 08:58:01 +02:00
Paul Riseborough 6cfee65060 ekf2: Add parameters to tune accelerometer bias learning
These parameters enable the accel bias limiting and learning inhibit logic in the ecl EKF to be easily tuned during testing and replay.
2017-10-09 08:58:01 +02:00
Paul Riseborough 66277d0c02 ekf2: Added @reboot_required to parameters 2017-10-09 08:58:01 +02:00
Daniel Agar 6f52d8a4e3 Makefile fix scan-build path (#8091) 2017-10-09 02:38:57 -04:00
Daniel Agar 6f3fe3f3ec travis-ci enable codecov (#8090) 2017-10-09 02:13:43 -04:00
Lorenz Meier 1947a9a176 Devices: Update submodule to include GPS driver improvements 2017-10-07 16:18:00 +02:00
Lorenz Meier eb2c9fbef1 GPS: Remove unnecessary warning message
This warning message would often be printed during normal configuration and does not represent a good indicator for true GPS lost states. Instead the system flags should be used, which are available through the normal logging system.
2017-10-07 15:01:14 +02:00
Lorenz Meier dd7b72dfb0 MAVLink app: Fix boot-time race between receive thread and instantiation. 2017-10-07 13:56:30 +02:00
Lorenz Meier 2246b54e2b FMUv5: Increase USB buffer to increase transfer rates 2017-10-07 13:56:30 +02:00
Bart Slinger adba797323 Helicopter mixer scale throttle to -1 .. +1
Not sure why it worked for me without this change. I cannot test it myself. Should fix https://github.com/PX4/Firmware/issues/8013
2017-10-07 10:59:18 +02:00
Beat Küng 353caec1af temperature_calibration: check if no sensor is found 2017-10-07 10:57:53 +02:00
Florian Achermann 6b97470106 SDLOG2: Fix definition of DPRS log format. (#8058) 2017-10-06 18:57:43 -07:00
Paul Riseborough 2a4336b6ef commander: EKF2 GPS requirement 20 sec after 3D lock 2017-10-06 16:22:53 -07:00
Daniel Agar 2495f8942b preflightcheck EKF2 GPS requirement after 20s 2017-10-06 16:22:53 -07:00
Daniel Agar 9a9923c517 commander simplify sensors PreflightCheck 2017-10-06 16:22:53 -07:00
David Sidrane 391d103bfd hardfault_log:Not having a ulog file to append to is not an error
The hardfault keeps track of the number of reboot without a
   commit to disk. A commit to disk is the act of writing the
   fault data from the bbsram to the hardfault file, not the
   ulog file. The sucessful commit rearms the hardfault system.

   When ulog appending was added it treated the lack of a ulog
   file as an error. This prevented the hardfault_log reset
   from being called because the hardfault_log commit returned
   an error.

   	if hardfault_log check
	then
		if hardfault_log commit
		then
			hardfault_log reset
		fi
	fi

   This change treats the lack a a ulog as a non error.
2017-10-06 12:16:08 -10:00
Beat Küng cdf17c5447 led: add MODE_FLASH 2017-10-06 20:40:02 +02:00
Daniel Agar 263b7ea009 commander battery failsafe only error if TRANSITION_DENIED 2017-10-06 20:11:59 +02:00
Daniel Agar 80dd87536e navigator fix vehicle_command_ack (don't copy external) 2017-10-06 20:11:19 +02:00
Daniel Agar aa2566970e FW landing abort remove message comma (read as a pause) 2017-10-06 20:11:19 +02:00
Beat Küng efb170d91d tap_esc: some cleanup
- use select_responder from tap_esc_common namespace (same definition)
- switch pwm output to uint16, that's what's used in send_esc_output()
- use SCHED_PRIORITY_ACTUATOR_OUTPUTS instead of SCHED_PRIORITY_MAX
2017-10-06 19:32:53 +02:00
Daniel Agar 38f45d1a9d airspeed sensor startup improvements (#7903) 2017-10-05 14:29:44 -07:00
Daniel Agar 123a0b584a cmake fix posix upload targets 2017-10-05 11:28:10 -10:00
Daniel Agar 87a1b15509 NuttX build restore old .px4 file naming (drop nuttx_ prefix) 2017-10-05 11:28:10 -10:00
Daniel Agar 8d07c647f7 NuttX improve apps builtins dependencies 2017-10-05 11:28:10 -10:00
davidaroyer ed9e798f86 docker_run.sh: add ocpoc target 2017-10-05 09:34:14 -07:00
davidaroyer 89f8956ae3 boards: update ocpoc board_config defines 2017-10-05 09:34:14 -07:00
Paul Riseborough 0def4ace5f commander: check magnetometers for inconsistency preflight 2017-10-05 09:30:26 -07:00
Paul Riseborough 60a68d30c7 sensors: Calculate and publish magnetometer inconsistency 2017-10-05 09:30:26 -07:00
Paul Riseborough c7097085fa msg: publish magnetometer inconsistency level 2017-10-05 09:30:26 -07:00
Beat Küng 20e987faa9 estimator_status: add missing descriptions for control_mode_flags 2017-10-05 10:04:02 +02:00
ChristophTobler 8541555e13 gpssim: add possibility to change parameters
fix_type, satellites_used and a noise parameter can now be set manually for testing purposes
2017-10-05 07:18:20 +02:00
ChristophTobler b41c471090 accelsim/gyrosim: fix seg fault if not enough arguments
happens with 'accelsim/gyrosim -R'
2017-10-05 07:18:20 +02:00
ChristophTobler 6843155357 gpssim: fix seg fault if not enough arguments
happens with e.g. 'gpssim -f'
2017-10-05 07:18:20 +02:00
ChristophTobler 2436a27848 gpssim: use px4_getopt 2017-10-05 07:18:20 +02:00
David Sidrane bed4714cfe kinetis:adc fix typo vailid->valid (#8054)
Fix typo on master
2017-10-04 08:05:18 -10:00
David Sidrane 86389930be drv_sensor:Part number changed to fxos8701cq 2017-10-04 04:49:35 -10:00
David Sidrane b363b794b1 fxos8700cq:Part number change fxos8701cq 2017-10-04 04:49:35 -10:00
David Sidrane 390f93724c nxphlite-v3:Fixed USB PRODUCTSTR. CONFIG_CDCACM_PRODUCTID Still needs update 2017-10-04 04:49:35 -10:00
David Sidrane e1496a6d57 kinetis:io_timer Added SYC on CCR setting
Fixes error in fmu test "servo 0 readback error, got 900
                          expected 1002"
2017-10-04 04:49:35 -10:00
David Sidrane 10f418a272 nxphlite-v3:rcS move mavlink to UART4 connector P10 2017-10-04 04:49:35 -10:00
David Sidrane b6c15d7223 nxphlite-v3:Manage Spektrum power & bind 2017-10-04 04:49:35 -10:00
David Sidrane e11b08aa68 nxphlite-v3:ADC 12 use bit 2017-10-04 04:49:35 -10:00
David Sidrane 3e863dff5d nxphlite-v3:ADC digital USB connected 2017-10-04 04:49:35 -10:00
David Sidrane 7a0254d9f3 nxphlite-v3:Use BOARD_HAS_CONTROL_STATUS_LEDS 2017-10-04 04:49:35 -10:00
David Sidrane 1615d5642e kinetis:drv_io_timer ensure the Mod register is updated 2017-10-04 04:49:35 -10:00
David Sidrane ccc83dde33 nxphlite-v3:Build rgbled_pwm driver 2017-10-04 04:49:35 -10:00
David Sidrane 99dc1b17e2 nxphlite-v3:Add PWM RGB LEDs 2017-10-04 04:49:35 -10:00
David Sidrane 36d4619045 nxphlite-v3:Define RGB LED timer assignments 2017-10-04 04:49:35 -10:00
David Sidrane 9c7fd0ab9c nxphlite-v3:Use LED D9 and D10, remove RGB LEDs (going to PWM) 2017-10-04 04:49:35 -10:00
David Sidrane f68da76701 kinetis:PWM LED driver 2017-10-04 04:49:35 -10:00
David Sidrane e11af2bc27 fmu:Add PWM6 mode for nxphlite v3.5 2017-10-04 04:49:35 -10:00
David Sidrane 2eaf0c8c0a fxos8700cq:Drop SCLK to 1 Mhz 2017-10-04 04:49:35 -10:00
David Sidrane b9c13b86cb nxphlite-v3:Refreshed Config 2017-10-04 04:49:35 -10:00
David Sidrane 812128d565 nxphlite-v3:V3.5 HW changes 2017-10-04 04:49:35 -10:00
David Sidrane 9ce3fc6700 nxphlite-v3 cmake:Bring inline with master 2017-10-04 04:49:35 -10:00
Julien Lecoeur 5d01eac5de Fix check_stack target (#8050) 2017-10-04 10:02:23 -04:00
Jonas Vautherin 93c1ad3103 sitl: add possibility to not run gazebo when running make 2017-10-04 15:38:37 +02:00
Beat Küng dd98ed565e protocol_splitter: fix type comparison 2017-10-04 14:13:14 +02:00
ChristophTobler ec61ae0003 ekf2: add some comments 2017-10-04 13:11:11 +02:00
Beat Küng 8016d69ba4 mavlink_log_handler: set current_log_filep to NULL after closing the file
It probably did not cause further issues, except that fclose() was called
on an invalid file handle later on.
2017-10-04 07:33:47 +02:00
José Roberto de Souza c47e541d02 AeroFC: Disable UART8 (#8046)
* AeroFC: Update defconfig

defconfig generated using: make aerofc-v1_default oldconfig

* AeroFC: Disable UART8

It is not used but it share the same pinout in the FC connector with
other pin used as I2C2, so it needs to stay in high-z.
2017-10-03 18:14:50 -10:00
Beat Küng 2dd34d639d commander: ignore internal commands during calibration
if vmount was enabled in mavlink mode, it was continuously sending mavlink
commmands, which lead to 'command denied during calibration: 205' messages
during calibration.
2017-10-03 07:50:27 +02:00
Beat Küng 29e85edac8 Revert "param MPC_MAN_TILT_MAX: decrease maximum from 90 to 85 degrees"
This reverts commit d6df692b7a.

The changes to attitude controller improve this a lot.
2017-10-01 15:36:21 +02:00
Beat Küng 98893c9f4f mc_att_control params: increase max roll/pitch/yaw rates to 1800
If you want to go to the limit of what the vehicle can do, you need to be
able to set it so large that it is guaranteed that it's never limited by
software.

Tests showed that it's not a problem to increase it to very high numbers.
2017-10-01 15:36:21 +02:00
Beat Küng f5d9155ab2 mc_att_control params: reduce default max acro rates from 360 to 120 deg/s
360 is too fast if you just want to hover. Next step is to add expo(),
so that we still have fine-grained control at the center and high rates
at the edges.
2017-10-01 15:36:21 +02:00
Beat Küng 55da07d3c4 mc_att_control: fix computation of yaw weight for attitude control
Previously, the yaw weight was based on the tilt angle of the attitude
setpoint (R_sp(2, 2) == cos(tilt angle)). This makes no sense, it means
the weight is low for high tilt angles even if there is no roll-pitch error
at all.

This patch changes the weight computation to be based on the tilt angle
error: the yaw weight is 1 if there is no roll-pitch error (independent
from current tilt angle), and is reduced for higher tilt angle errors.

The weight was added in 05e9a30573, without any explanation or
derivation of how and why the weight is chosen that way.

However this patch works much better in practice. The yaw control is
improved, though it can be a bit slow to converge if you do continuous &
fast roll-pitch motions (which is expected).
2017-10-01 15:36:21 +02:00
Beat Küng 2f1ca409b7 mc_att_control: add more comments to the code, better explaining what it does
No semantic changes.
2017-10-01 15:36:21 +02:00
Beat Küng 69b1bfca6c mc_att_control: fix yaw feedforwarding
The feedforwarding was applied in the wrong frame: the term is given in
global coordinates, but was directly applied to body coordinates. This
patch adds the missing transformation from global to body frame.

In addition, it moves the feedforwarding before the rate limitation, so
that we cannot exceed the configured rates.
2017-10-01 15:36:21 +02:00
Beat Küng 2cc18d2d52 mc_att_control: move the board_rotation computation to the parameters_update
It's not necessary to do this computation in each loop iteration.
2017-10-01 15:36:21 +02:00
Beat Küng 27f020af05 mc_att_control: remove the hardcoded max throttle limit of 0.9 for ACRO 2017-10-01 15:36:21 +02:00
José Roberto de Souza 0d5480e540 driver: ll40ls: Correctly instantiate with the right parameters (#8032)
It was setting the rotation value to the I2C slave address
causing it to not be successfully probe.

Changing the constructor paramters order instead of
just fix line instantiating to keep consistency with
the other lidars and sonars.
2017-09-29 20:25:09 -04:00
Lucas De Marchi fa458cdf0e build: get rid of annoying CMake warning (#8033)
Depending on the CMake version when we are configuring it emits a
warning about deprecation of CMAKE_FORCE_CXX_COMPILER. However we
rely on this macro and don't want to do what CMAKE_CXX_COMPILER
is doing. Here is what I get with CMake 3.9.1:

	CMake Deprecation Warning at /usr/share/cmake/Modules/CMakeForceCompiler.cmake:83 (message):
	  The CMAKE_FORCE_CXX_COMPILER macro is deprecated.  Instead just set
	  CMAKE_CXX_COMPILER and allow CMake to identify the compiler.
	Call Stack (most recent call first):
	  cmake/toolchains/Toolchain-arm-none-eabi.cmake:37 (cmake_force_cxx_compiler)
	  /usr/share/cmake/Modules/CMakeDetermineSystem.cmake:94 (include)
	  CMakeLists.txt:263 (project)

Avoid the warning by passing -Wno-deprecated to cmake.
2017-09-29 20:24:14 -04:00
David Sidrane a9bd3aeb85 Fixed typo usb_vaild -> usb_valid 2017-09-29 10:46:50 -10:00
Daniel Agar 9ce3412a93 NuttX board build not needed (#8029) 2017-09-29 06:48:25 -10:00
Daniel Agar 352d65a14a navigator delete unused attitude setpoint (#8028) 2017-09-29 11:51:00 -04:00
Daniel Agar 3ac6d1aa27 px4fmu-v2 and px4fmu-v3 boards cleanup 2017-09-29 10:13:51 -04:00
David Sidrane 95cea13090 Updated nuttx and apps submodules for 1.7 Release
Tied to nuttx, apps  px4_firmware_nuttx-master
     rebased on upstream nuttx master @ 3647ace55958c094cfe93f07092d308a768f5ca3
     rebased on upstream apps master @ 21c9b793e2ca6f4e86388c80d7af5c466de5e71c
2017-09-29 10:13:51 -04:00
Daniel Agar 2113772443 improve nuttx verbose build 2017-09-29 10:13:51 -04:00
Daniel Agar 48f1e3ed1c uORB generation move to msg/ 2017-09-29 10:13:51 -04:00
Daniel Agar 03784c6b01 nuttx fix px4 builtin generation dependency 2017-09-29 10:13:51 -04:00
Daniel Agar e38136fc9f NuttX build re-enable hard link copy and improve builtin_list 2017-09-29 10:13:51 -04:00
Lorenz Meier f9c9890a49 EKF2: Add minimal stack for M7 targets 2017-09-29 10:13:51 -04:00
David Sidrane bb71e47ddf Updated nuttx submoulde 7.22+ w/i2c fix ==px4_firmware_nuttx-master
Latest nuttx 7.22+ with PX4 contrib for stm32 f4 I2C hang.
2017-09-29 10:13:51 -04:00
David Sidrane 0f028fda3b Update nuttx and apps submodule to 7.22+ ==px4_firmware_nuttx-master
Prep for Nuttx Upgrade - still needs i2c fix
2017-09-29 10:13:51 -04:00
David Sidrane f79d06dae4 px4-same70xplained-v1:Update to master rename trone to teraranger 2017-09-29 10:13:51 -04:00
David Sidrane 8f78f57f14 nxphlite-v3:Update to master rename trone to teraranger 2017-09-29 10:13:51 -04:00
David Sidrane 986607b37d PX4_SAME70XPLAINED_V1:Remove unnesasary conditional for FMU mode 2017-09-29 10:13:51 -04:00
David Sidrane e967e02c4d HW Rev & Ver:0 for no value, -1 for not supported 2017-09-29 10:13:51 -04:00
David Sidrane 7698c08eb7 HW Rev & Ver:0 for no value, -1 for not supported 2017-09-29 10:13:51 -04:00
David Sidrane 7ae999ecb3 HW Rev & Ver:0 for no value, -1 for not supported 2017-09-29 10:13:51 -04:00
David Sidrane 13c4a6cced HW Rev & Ver:0 for no value, -1 for not supported 2017-09-29 10:13:51 -04:00
David Sidrane 0b70a8cc44 px4fmu-v5:Add FMUv5 HW revision and version 2017-09-29 10:13:51 -04:00
David Sidrane 8451cb324e board_common: Add BOARD_HAS_HW_VERSIONING control 2017-09-29 10:13:51 -04:00
David Sidrane 04f7a7a47a stm32:Add board Revision and version API for FMUv5 HW detection 2017-09-29 10:13:51 -04:00
David Sidrane d4892bf179 stm32 adc:Create board accessible API for using the ADC prior to boot
board_adc_init()    - initalise the ADC HW once.
   board_adc_sample()  - read a given channel dn
2017-09-29 10:13:51 -04:00
David Sidrane f3e925497d board_common:Break into internal and public api.
Internal functions are public functions that should realy only
   be called by the board config.
2017-09-29 10:13:51 -04:00
David Sidrane 9cc7148211 board_common:Documentation clean up merged 2017-09-29 10:13:51 -04:00
David Sidrane 3c384f1890 Updated nuttx and apps submudule 7.22+ ==px4_firmware_nuttx-master 2017-09-29 10:13:51 -04:00
David Sidrane 7dc8f215f6 samv7 board identity:fix sign-compare 2017-09-29 10:13:51 -04:00
David Sidrane 83d870900c kinetis board identity:fix sign-compare 2017-09-29 10:13:51 -04:00
David Sidrane 7c5f3ea623 kinetis io timer:fix sign-compare 2017-09-29 10:13:51 -04:00
David Sidrane c44cfbf87e nxphlite-v3 spi:fix sign-compare 2017-09-29 10:13:51 -04:00
David Sidrane f83df2a9a6 Updated nuttx submodule 7.22+
Updated to latest upstream with PX4 contrib for STM32 I2C that
  fixes an hang in driver.
2017-09-29 10:13:51 -04:00
David Sidrane 1c6dc4b84c Updated nuttx and apps submodules to Nuttx 7.22+ ==px4_firmware_nuttx-master 2017-09-29 10:13:51 -04:00
David Sidrane c6eec29dec sensors:Rework battery connected logic
A battery is considered connected when a) V > BOARD_ADC_OPEN_CIRCUIT_V
   and if BOARD_ADC_OPEN_CIRCUIT_V > BOARD_VALID_UV connected
   is further qualifed by the Valid signal.
2017-09-29 10:13:51 -04:00
David Sidrane d95e985f59 px4fmu-v5:Set non default BOARD_ADC_OPEN_CIRCUIT_V
Due to higher bias, V open circuit on the ADC is high with a 1M
   termination. This override the default connected threshold on
   V5 HW. Revist once lowe termination is chosen.
2017-09-29 10:13:51 -04:00
David Sidrane ef5d808f6d px4fmu-v4pro:Override default BOARD_VALID_UV
Based on the R values on the LTC4411 the px4fmu-v4pro has a
   UV of 4.01 Volts.
2017-09-29 10:13:51 -04:00
David Sidrane 5018723eb2 board_common:Define defaults for Open circuit max and UV min
BOARD_ADC_OPEN_CIRCUIT_V is the voltage present on an ADC due
   to the bias current on the terminition resistor.

   BOARD_VALID_UV is the under voltage min set by resistors on a
   board's Power selector.

   A battery is considered connected when the Voltage measures is
   greater than BOARD_ADC_OPEN_CIRCUIT_V.

   In the case where BOARD_ADC_OPEN_CIRCUIT_V is greater then
   BOARD_VALID_UV we can use the HW to qualify connected.
2017-09-29 10:13:51 -04:00
David Sidrane 25fef84f98 px4fmu-v5:board.h fixed typo in comment 2017-09-29 10:13:51 -04:00
David Sidrane 24eb56aa27 battery:Only change the warning level on a connected battery.
Connected is assumed when the battery voltages is greater than
   a predefined level.
2017-09-29 10:13:51 -04:00
David Sidrane 63ac56aeb0 smt32 adc:Ensure the the ADC clock is not out of spec
The data sheet for the F4, F7 indicate a maximum of 36 Mhz
   in the 2.4-3.3 volt Soc operating range. This change sets
   the clock based on the STM32_PCLK2_FREQUENCY.
2017-09-29 10:13:51 -04:00
David Sidrane dcf8d82f8c px4fmu-v5:Update to use CONFIG_STM32F7_FLASH_ART_ACCELERATOR
Upstream change on F7 CONFIG_STM32F7_FLASH_PREFETCH and
   CONFIG_ARMV7M_ITCM are now contorled by
   CONFIG_STM32F7_FLASH_ART_ACCELERATOR
2017-09-29 10:13:51 -04:00
David Sidrane 822b390420 Update nuttx and apps submodule 7.21+==px4_firmware_nuttx-master 2017-09-29 10:13:51 -04:00
Daniel Agar 474f216a0a UAVCAN bootloaders split into separate repository (#7878) 2017-09-29 10:13:51 -04:00
David Sidrane f641c1e15e Updated nuttx submodule 7.21+ ==px4_firmware_nuttx-master 2017-09-29 10:13:51 -04:00
David Sidrane 8b2ee2cb33 Updated nuttx submodule 7.21+ 2017-09-29 10:13:51 -04:00
David Sidrane 8fe1abf8ff nxphlite-v3:Add fxas21002c to rc.sensors 2017-09-29 10:13:51 -04:00
David Sidrane d0853092f5 nxphlite-v3:add fxas21002c driver to board build 2017-09-29 10:13:51 -04:00
David Sidrane 3d6ebc0081 Added NXP fxas21002c 2017-09-29 10:13:51 -04:00
David Sidrane 9bc1884e83 nxphlite-v3:Init and control Sensor reset pins in board init 2017-09-29 10:13:51 -04:00
David Sidrane 929c5d9b5e Updated NuttX submodule with upstream 7.21+ 2017-09-29 10:13:51 -04:00
David Sidrane 32d434fa8f fxos8700cq:Fixed typo 2017-09-29 10:13:51 -04:00
Daniel Agar 01b3e6fd25 NuttX upgrade cmake wrapper (#7873)
* NuttX cmake

* px4_macros:Pass the stringified predicate as second arg to static assert

   CC_ASSERT mapes to the c++ static_assert or provides the same
   funtionality for c via the other macros. The c++ static assert
   takes 2 argumants the prdicate and a message. This fixes the
   lacking second argument.

* Updated nuttx and apps submodule to upstream nuttx 7.21+==master

   This is the latest uptake of upstream nuttx and apps.

* ROMFS generate with xxd instead of objcopy

* delete nuttx-patches

* NuttX update submodules to latest px4_nuttx-master

* fix nuttx apps and board dependency

* docker_run update to latest container 2017-08-29

* cmake ROMFS portable sed usage

* NuttX update submodules to latest px4_nuttx-master
2017-09-29 10:13:51 -04:00
David Sidrane 11e518f494 nxphlite-v3:Schedule work queue with higher priority as on master
was:CONFIG_SCHED_HPWORKPRIORITY=192
    is:CONFIG_SCHED_HPWORKPRIORITY=249
2017-09-29 10:13:51 -04:00
David Sidrane bb78e71452 Using master README 2017-09-29 10:13:51 -04:00
David Sidrane f7d42a9e41 px4-same70xplained-v1:Moved px4-same70xplained-v1 specific README to board dir 2017-09-29 10:13:51 -04:00
David Sidrane 7a5f58a607 px4-same70xplained-v1 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane a61b7203bf px4-same70xplained-v1 nsh:Refreshed config 2017-09-29 10:13:51 -04:00
David Sidrane bff33ba9dc px4-same70xplained-v1:Refreshed config 2017-09-29 10:13:51 -04:00
David Sidrane 4fdce9bf21 px4-same70xplained-v1 nsh: increase CONFIG_NFILE_DESCRIPTORS from 53 to 54
Updated to match master
   This is needed when logger is logging to file and ulog streaming gets
   activated
2017-09-29 10:13:51 -04:00
David Sidrane 6a4120c44c px4-same70xplained-v1:Schedule work queue with higher priority as on master
was:CONFIG_SCHED_HPWORKPRIORITY=192
    is:CONFIG_SCHED_HPWORKPRIORITY=249
2017-09-29 10:13:51 -04:00
David Sidrane 442f79dac6 same70xplained-v1:use px4_micro_hal PX4_BUS_NUMBER_{TO|FROM}_PX4 mapping 2017-09-29 10:13:51 -04:00
David Sidrane 5d33b602f3 px4-same70xplained-v1:Updated to upstream master
Airspeed changes
   add FastRTPS
2017-09-29 10:13:51 -04:00
David Sidrane 4b5d585e57 kinetis:Add define for PX4_NUMBER_I2C_BUSES 2017-09-29 10:13:51 -04:00
David Sidrane f56940e654 README for px4-same70xplained-v1 2017-09-29 10:13:51 -04:00
David Sidrane f04ddf4368 Inital Commit of px4-same70xplained-v1 2017-09-29 10:13:51 -04:00
David Sidrane 0da1c79aa3 Adding Kinetis board common identity to micro hal 2017-09-29 10:13:51 -04:00
David Sidrane 69ac5adf89 drv_sensor:Fix merge by adding new NXP sensors after what was on master 2017-09-29 10:13:51 -04:00
David Sidrane 96b4e5b512 zubaxgnss-v1 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 17bf776af3 tap-v1 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane e53a06429c s2740vc-v1 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 3f267a5cb2 px4nucleoF767ZI-v1 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane c71e01bd44 px4fmu-v5 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane e4f47d4faa px4fmu-v4pro nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 68679a3e8e px4fmu-v4 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 24446f0c88 px4fmu-v3 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 6955a4c040 px4fmu-v2 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane c760278d0f px4esc-v1 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane c7f3e84bf4 px4cannode-v1 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 92411e7195 px4-stm32f4discovery nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 1a98f3c149 nxphlite-v3 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 3c25e8d899 mindpx-v2 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 0d82e807fe esc35-v1 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane ad6d0304a9 crazyflie nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 202377dd4e auav-x21 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 04a61d47cb aerofc-v1 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane e95b760257 aerocore2 nsh:Optimize memset for speed 2017-09-29 10:13:51 -04:00
David Sidrane 24d1481bfb zubaxgnss-v1:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 33c4a759d4 zubaxgnss-v1:bootloader Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 8063451a97 tap-v1:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 973def1a91 s2740vc-v1:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 25b7a7fa6c s2740vc-v1:bootloader Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 859a694d42 px4-stm32f4discovery:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane b3c973f3ae px4nucleoF767ZI-v1:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 813bb29511 px4fmu-v5:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 80101f8882 px4fmu-v4pro:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane bdc2397238 px4fmu-v4:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 9b326b1c8a px4fmu-v2:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 9e6dcf7261 px4flow-v2:bootloader Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 4483c1756f px4esc-v1:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 9368c2e675 px4esc-v1:bootloader Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane c637191e8f px4cannode-v1:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 8beb30db99 px4cannode-v1:bootloader Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane c6c636c8b2 nxphlite-v3:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane f22ea147ec mindpx-v2:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane bcd832893f esc35-v1:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane d882a39de4 esc35-v1:bootloader Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane caf06ef6fa crazyflie:nsh Refreshed config 2017-09-29 10:13:51 -04:00
David Sidrane 3c626424b1 auav-x21:nsh Refreshed config 2017-09-29 10:13:51 -04:00
David Sidrane 8a8448ee82 aerofc-v1:nsh Refresh config 2017-09-29 10:13:51 -04:00
David Sidrane 770a27d47c aerocore2:nsh Refreshed config 2017-09-29 10:13:51 -04:00
David Sidrane d12e1bc0ab px4fmu-v3:nsh Refreshed defconfig 2017-09-29 10:13:51 -04:00
David Sidrane 86c52e2ecf Tools:nuttx_defconf_tool upstream has CONFIG_START_YEAR etal
Re insetion of CONFIG_START_{YEAR|NONTH|DAY} is not needed as
   CONFIG_START_{YEAR|NONTH|DAY} have been defined always in
   upstream NuttX
2017-09-29 10:13:51 -04:00
David Sidrane 1991c27749 px4fmu-v2:Removed commented out unit_test module removed on master 2017-09-29 10:13:51 -04:00
David Sidrane 65210ff1e5 nxphlite-v3:Removed unit_test module removed on master 2017-09-29 10:13:51 -04:00
David Sidrane 78e2aef7b5 Update Nuttx Submodule ==upstream
Latest uptake from upstream.
2017-09-29 10:13:51 -04:00
David Sidrane edd741ea76 tap-v1 nsh: increase CONFIG_NFILE_DESCRIPTORS from 53 to 54
Updated to match master
   This is needed when logger is logging to file and ulog streaming gets
   activated
2017-09-29 10:13:51 -04:00
David Sidrane 72cdf1de12 sim nsh: increase CONFIG_NFILE_DESCRIPTORS from 53 to 54
Updated to match master
   This is needed when logger is logging to file and ulog streaming gets
   activated
2017-09-29 10:13:51 -04:00
David Sidrane 4e86bc7620 px4nucleoF767ZI-v1 nsh: increase CONFIG_NFILE_DESCRIPTORS from 53 to 54
Updated to match master
   This is needed when logger is logging to file and ulog streaming gets
   activated
2017-09-29 10:13:51 -04:00
David Sidrane 0f5c75b4c6 px4esc-v1 nsh: increase CONFIG_NFILE_DESCRIPTORS from 53 to 54
Updated to match master
   This is needed when logger is logging to file and ulog streaming gets
   activated
2017-09-29 10:13:51 -04:00
David Sidrane 054d489b96 px4-stm32f4discovery nsh: increase CONFIG_NFILE_DESCRIPTORS from 53 to 54
Updated to match master
   This is needed when logger is logging to file and ulog streaming gets
   activated
2017-09-29 10:13:51 -04:00
David Sidrane c239405383 nxphlite-v3 nsh: increase CONFIG_NFILE_DESCRIPTORS from 53 to 54
Updated to match master
   This is needed when logger is logging to file and ulog streaming gets
   activated
2017-09-29 10:13:51 -04:00
David Sidrane ea0dd5827b esc35-v1 nsh: increase CONFIG_NFILE_DESCRIPTORS from 53 to 54
Updated to match master
   This is needed when logger is logging to file and ulog streaming gets
   activated
2017-09-29 10:13:51 -04:00
David Sidrane 8e1e67d8af Updated NuttX submodule to upstream 7.21+ ==upstream
Bugfix for random SD card failures on px4fmu-v5 (STM32F7)

    Update to upstream with PX4 contrib for STM32F7 DMA preflight
    on SDMMC (SDIO) and DMA add dcache alignment check in
    stm32_dmacapable when needed: The case were dcache is in
    write-buffed mode.
2017-09-29 10:13:51 -04:00
David Sidrane 306f3c5331 px4fmu-v5:Updated defconfig to latest NuttX 2017-09-29 10:13:51 -04:00
David Sidrane e02f1a8d0f Update NuttX submodule ==upstream
Updated to upstream with C++14 fix
2017-09-29 10:13:51 -04:00
David Sidrane c4dae5e36e px4nucleoF767ZI-v1:Schedule work queue with higher priority as on master
was:CONFIG_SCHED_HPWORKPRIORITY=192
is:CONFIG_SCHED_HPWORKPRIORITY=249
2017-09-29 10:13:51 -04:00
David Sidrane 20866ad1af px4-stm32f4discovery:Schedule work queue with higher priority as on master
was:CONFIG_SCHED_HPWORKPRIORITY=192
is:CONFIG_SCHED_HPWORKPRIORITY=249
2017-09-29 10:13:51 -04:00
David Sidrane 27e68160fb crazyflie:Schedule work queue with higher priority as on master
was:CONFIG_SCHED_HPWORKPRIORITY=192
is:CONFIG_SCHED_HPWORKPRIORITY=249
2017-09-29 10:13:51 -04:00
David Sidrane 69744de5dd auav-x21:Schedule work queue with higher priority as on master
was:CONFIG_SCHED_HPWORKPRIORITY=192
is:CONFIG_SCHED_HPWORKPRIORITY=249
2017-09-29 10:13:51 -04:00
David Sidrane a7269fb5a3 aerofc-v1:Schedule work queue with higher priority as on master
was:CONFIG_SCHED_HPWORKPRIORITY=192
is:CONFIG_SCHED_HPWORKPRIORITY=249
2017-09-29 10:13:51 -04:00
David Sidrane 09083345c8 aerocore2:Schedule work queue with higher priority as on master
was:CONFIG_SCHED_HPWORKPRIORITY=192
is:CONFIG_SCHED_HPWORKPRIORITY=249
2017-09-29 10:13:51 -04:00
David Sidrane 683ac7e1f7 aerocore:Schedule work queue with higher priority as on master
was:CONFIG_SCHED_HPWORKPRIORITY=192
is:CONFIG_SCHED_HPWORKPRIORITY=249
2017-09-29 10:13:51 -04:00
David Sidrane 8ac43c9988 nxphlite-v3:use px4_micro_hal PX4_BUS_NUMBER_{TO|FROM}_PX4 mapping 2017-09-29 10:13:51 -04:00
David Sidrane 64b9f687c0 px4_micro_hal:Provide PX4_BUS_NUMBER_{TO|FROM}_PX4 mapping
For historical reasons (NuttX STM32 numbering) PX4 bus numbering is
   1 based. All PX4 code, including, board code is written to assuming 1
   based numbering. In the PX4 I2C driver the 1 is subtracted from the
   buss number to address the freqency array.  These  macros are used to
   allow the board config to define the bus  numbers in terms of the NuttX
   driver numbering. 1,2,3 for one based numbering (STM32)  or 0,1,2
   for zero based (Kinetis)
2017-09-29 10:13:51 -04:00
David Sidrane 5889b4d89c Updated NuttX submodule to upstream 7.21+ ==upstream
Latest upstream. With PX4 contrib for Wide Char fix.

   cwchar:Use CONFIG_LIBC_WCHAR to only export the wc/mb functions

       When a build does not want to use wide or multibyte char
       CONFIG_LIBC_WCHAR is not set. Therefore we should to only
       export the wc/mb functions when defined.

       Regardless of the stat of CONFIG_LIBC_WCHAR the non mb/wc
       definitions such as mbstate_t, wint_t, wctype_t need to be
       exported.
2017-09-29 10:13:51 -04:00
David Sidrane f5ed7586bf boards common:Fix formating 2017-09-29 10:13:51 -04:00
David Sidrane 8e4e4fae36 rc.sensors:Align with master 2017-09-29 10:13:51 -04:00
David Sidrane f52338143b nxphlite-v3:Updated to upstream master
Add FastRTPS
2017-09-29 10:13:51 -04:00
David Sidrane c05429a70c samv7:Add PX4_NUMBER_I2C_BUSES 2017-09-29 10:13:51 -04:00
David Sidrane 01c1228b21 kinetis:Add define for PX4_NUMBER_I2C_BUSES 2017-09-29 10:13:51 -04:00
David Sidrane c7823ffc58 spi:Print only device index (mask bus in _device
Print only the PX4_SPI_DEV_ID portion of the _device
2017-09-29 10:13:51 -04:00
David Sidrane a5297074c6 zubaxgnss-v1 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane b405657e86 zubaxgnss-v1 bootloader: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane b08da5397c sim nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 99242b549c s2740vc-v1 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 89640fbdfd s2740vc-v1 bootloader: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane bafc00c8fa px4nucleoF767ZI-v1 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 8191196efd px4io-v2 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 4073e3aa40 px4fmu-v5 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 5180f01ef2 px4fmu-v4pro nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane f83ea86698 px4fmu-v4 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 3f7301956e px4fmu-v3 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 1d99c507ef px4fmu-v2 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 18572c10ac px4fmu-v1 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 932e06b2f3 px4flow-v2 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 5d5b91fb5f px4flow-v2 bootloader: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 89ab7456c0 px4esc-v1 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane f3790dc8d1 px4esc-v1 bootloader: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane a920d8e305 px4cannode-v1 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane ccc474abbe px4cannode-v1 bootloader: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 23d980bf19 px4-stm32f4discovery nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane e1562e0d67 nxphlite-v3 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane e1dd4677ca mindpx-v2 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane d7c5419f57 esc35-v1 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane c5aea5640b esc35-v1 bootloader: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane f15c7a60cd crazyflie nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 5e220ea3f2 auav-x21 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane e3c57ea656 aerofc-v1 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane cb65b39c49 aerocore2 nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane b3c614c573 aerocore nsh: Upstream NuttX removed setenv.sh 2017-09-29 10:13:51 -04:00
David Sidrane 713ccb01be Update Nuttx Submodule ==upstream
Latest uptake from upstream.
2017-09-29 10:13:51 -04:00
David Sidrane d2bc3a534f px4nucleoF767ZI-v1:Fixed STM32_RCC_DCKCFGR2_DSISRC
C&P error in upstream was:RCC_DCKCFGR2_DSISEL_48MHZ is
       RCC_DCKCFGR2_DSISEL_PHY
2017-09-29 10:13:51 -04:00
David Sidrane e6cc4530b4 px4fmu-v5:Fixed STM32_RCC_DCKCFGR2_DSISRC
C&P error in upstream was:RCC_DCKCFGR2_DSISEL_48MHZ is
   RCC_DCKCFGR2_DSISEL_PHY
2017-09-29 10:13:51 -04:00
David Sidrane c264cb3224 erofc-v1:Updated to new NuttX IRQ API changes 2017-09-29 10:13:51 -04:00
David Sidrane ae2e1da93a px4_impl_nuttx:PX4 does not used compressed defconfigs nor configure.sh
The new upstream nuttx defconfig format is compressed. This
   will not work well for board configs that are out of the
   upstream NuttX tree.

   The reconstitution step will not replace all the non default
   settings. I.E. CONFIG_ARCH_BOARD_PX4xxxx and will remove
   setting that are not defined from the config/KConfig. Like
   CONFIG_ARCH_BOARD_PX4xxxx=y.

   Also the configure script will fail if run without
   and intervening make distclean

   The only 2 steps from configure that re needed are
   Copying the defconfig to .config and Make.defs
2017-09-29 10:13:51 -04:00
David Sidrane cb21aced5e PX4 System: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 724e4f9e39 px4cannode-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 65c66d664f zubaxgnss-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 9a6158e291 zubaxgnss-v1 bootloader: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane a039a7635c s2740vc-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 2f5da07b9c s2740vc-v1 bootloader: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 34d87bbddd px4io-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane f7f2ecacd4 px4fmu-v4pro nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 8cbd7a9290 px4fmu-v4 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 6d5ac6ada9 px4fmu-v3 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 9b5acf694b px4fmu-v2 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane e382a97273 px4fmu-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 7bcd37b065 px4flow-v2 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane c59d9e08a7 px4flow-v2 bootloader: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 3cd605e734 px4esc-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane fb758e86d0 px4esc-v1 bootloader: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane afa7dd518b px4cannode-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane fee1e87fb1 px4cannode-v1 bootloader: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 94d4a8577b px4-stm32f4discovery nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 62aff9f2c6 mindpx-v2 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 7339b957fe esc35-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 43c90e64af esc35-v1 bootloader: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 7048b068a8 crazyflie nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 1f0a4e8aa9 auav-x21 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 076a8713f8 aerofc-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 5ea00ff4e6 aerocore2 nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 7265523f40 aerocore nsh: Upstream NuttX defconfig changes
was:CONFIG_STM32_STM32F40XX is:CONFIG_STM32_STM32F4XXX
2017-09-29 10:13:51 -04:00
David Sidrane 5aee418e59 nxphlite-v3:Updated config with upstream naming changes
Reordering and renaming to match master for v3 config
2017-09-29 10:13:51 -04:00
David Sidrane be9c107309 NXPHLITE_V3:Start fxos8700cq 2017-09-29 10:13:51 -04:00
David Sidrane ffffad352f nxphlite-v3:add usb_connected command 2017-09-29 10:13:51 -04:00
David Sidrane 58a6e57452 nxphlite-v3:Use ADC reading for VBUS
On this HW the VBUS detection is on the ADC. The ADC module
   reads the value and sets a global flag as well as publishing
   the value via uOrb.
2017-09-29 10:13:51 -04:00
David Sidrane 57892805e2 Sensors:add ID for fxos8700c mag and accel 2017-09-29 10:13:51 -04:00
David Sidrane 3b42d30623 fxos8700c:Inital commit mag and accel driver 2017-09-29 10:13:51 -04:00
David Sidrane a7422dc9b6 nxphlite-v3:Define and use sensor reset pins
Define and use the Sensor reset pins. Added the cide to reset
   the nxphlite-v3 sensors.
2017-09-29 10:13:51 -04:00
David Sidrane c66c830909 Updated NuttX submodule to upstream 7.21+ ==upstream
PX4 contrib for Kientis I2C driver
2017-09-29 10:13:51 -04:00
David Sidrane 1682101cff mpl3115a2:Rework per data sheet
The driver appeared to not be finished and was a clone
   of another driver that did not work.
2017-09-29 10:13:51 -04:00
David Sidrane e8f2f33911 Updated NuttX submodule to upstream 7.21+ ==upstream
PX4 contrib for samv7 twihs (i2c) driver ref counting.
2017-09-29 10:13:51 -04:00
David Sidrane 526f07b527 gpio_led:Define GPIO_MAX_SERVO_PIN down to 4
Support boards with less than 6 (GPIO_SERVO_n) where
   n is now 16..4
2017-09-29 10:13:51 -04:00
David Sidrane f4992e64f7 mtd:24xxxx_mtd add AT24C02 - AT24C16 2017-09-29 10:13:51 -04:00
David Sidrane 5f9b23b475 same70 micro hal 2017-09-29 10:13:51 -04:00
David Sidrane c536bf95f0 px4-same70xplained-v1:ROMFS changes 2017-09-29 10:13:51 -04:00
David Sidrane 2de54da648 nxphlite-v3:Updates for latest master 2017-09-29 10:13:51 -04:00
David Sidrane 7cb2319221 mavlink:Hardfaulting usage at 2552 - set to 2840 2017-09-29 10:13:51 -04:00
David Sidrane eab69fafe1 Updated NuttX submodule to upstream 7.21+ ==upstream
PX4 contrib for Kientis SPI
2017-09-29 10:13:51 -04:00
David Sidrane ad5f166c75 nxphlite-v3:Removes spi stubs 2017-09-29 10:13:51 -04:00
David Sidrane 1af3ea322c BUGFIX:mtd hardfault in no SPI
NULL check needed to be done before SPI_XXXX calls
2017-09-29 10:13:51 -04:00
David Sidrane 01f520dfd2 Kinetis SPI is zero based 2017-09-29 10:13:51 -04:00
David Sidrane 30653226ed nxphlite-v3:Add MTD to defconfig 2017-09-29 10:13:51 -04:00
David Sidrane 72ea7ae8f6 px4cannode-v1:Updated board_button to match upstream NuttX
upstren widened board_buttons ti 32 bit
2017-09-29 10:13:51 -04:00
David Sidrane 7a0d6174e2 nxphlite-v1:Removed from PX4
Superceeded by nxphlite-v3 before released
2017-09-29 10:13:51 -04:00
David Sidrane 19313728b0 Updated NuttX submodule to upstream 7.21+ ==upstream
PX4 contrib for Kientis USB-FS and MPU fixes. Fixed warning
2017-09-29 10:13:51 -04:00
David Sidrane 39632a67d9 nxphlite-v3:Removed usb init, there is none needed to be done by board 2017-09-29 10:13:51 -04:00
David Sidrane f48d3f05c2 Updated NuttX submodule to upstream 7.21+ ==upstream
PX4 contrib for Kientis USB-FS and MPU fixes.
2017-09-29 10:13:51 -04:00
David Sidrane d4d8f744e1 Updated NuttX submodule to upstream 7.20+ ==upstream
Latest uptake. PX4 contrib for Kinetis ADC definition fixes
2017-09-29 10:13:51 -04:00
David Sidrane 1bc760c194 Kinetis:Added PX4 ADC Driver.
PX4 Driver for Kinetis uisng just ADC1.

   On V3 HW RC00 the USB_VBUS_VALID on pin 36 of the MCU
   ADC0_SE16/ADC1_SE22 is bridged to pin 29 ADC1_DP0 and read
   there. But because of missing schottky diodes on V3 HW RC00
   the signal is true (3.3V) when powered by the Power Module.
2017-09-29 10:13:51 -04:00
David Sidrane 160f5cc67d Removed px4cannode from build as it does not fit in flash. 2017-09-29 10:13:51 -04:00
David Sidrane eb9ebb26ea px4fmu-v4pro:Had wrong bus ID for SPI5, SPI6 2017-09-29 10:13:51 -04:00
David Sidrane 906d7e7acd Using Upstream NuttX up_cxxinitialize from app/platform/gnu
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 4fbcfae367 px4io firmware: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 143750d60c zubaxgnss-v1: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 2a66de9452 tap-v1: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 9156fa09e3 s2740vc-v1: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 601ec364e8 px4nucleoF767ZI-v1: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 06b21b60de px4io-v1: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 1e25a61b37 px4fmu-v5: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 0bf10f02c9 px4fmu-v4pro: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane caaf2f8e6c px4fmu-v4: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 834ec95198 px4fmu-v2: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane db442ed26b px4flow-v2: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane dce72003fe px4esc-v1: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 1bbab7b219 px4cannode-v1: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 193a22288a px4-stm32f4discovery: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 2a266266c6 nxphlite-v3: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 8fa8835a6f nxphlite-v3: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 3e26c861a2 nxphlite-v1: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane eca7e0aff7 mindpx-v2: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane ce3bcd0402 esc35-v1: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 554fb822e6 crazyflie: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 6829855b1f auav-x21: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 0e6c7890c0 aerofc-v1: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 9bfee14be0 aerocore2: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 4b87fac11a aerocore: Upstream NuttX up_cxxinitialize moved
was:<nuttx/arch.h> is:platform/cxxinitialize.h
   Removed PX4 version:src/modules/systemlib/up_cxxinitialize.c
   in favor of nuttx platform/gnu/gnu_cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane 069408bc6e Updated NuttX submodule to upstream 7.20+ ==upstream
Latest uptake. defconfig changes and common cxxinitialize.c
2017-09-29 10:13:51 -04:00
David Sidrane b4887e55a8 zubaxgnss-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane f9b5f92268 zubaxgnss-v1 bootloader: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 440141872b sim nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane d21115ef15 s2740vc-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 6b6833e353 s2740vc-v1 bootloader: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane f7852cb68c px4nucleoF767ZI-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 5fb8774377 px4io-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane d509838b49 px4fmu-v5 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane d44d21a669 px4fmu-v4pro nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 4692b66f49 px4fmu-v4 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 72efdf5fab px4fmu-v3 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane f165f6b4fc px4fmu-v2 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 82c441031c px4fmu-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 9c48d1006c px4flow-v2 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 18148bcd31 px4flow-v2 bootloader: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 15748f9275 px4esc-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane fadf9d417c px4esc-v1 bootloader: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 7d8185591e px4cannode-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 2c37d20a22 px4cannode-v1 bootloader: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 2d477c8f07 px4-stm32f4discovery nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane c6c391b4c7 nxphlite-v3 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane a1fa11e6a3 nxphlite-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 34e08be910 mindpx-v2 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 7657a40c41 esc35-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane c09fefa5bb esc35-v1 bootloader: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane caa5e337da crazyflie nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 63cdc56c5f auav-x21 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane ad4ec948a2 aerofc-v1 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane bcfdc81892 aerocore2 nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 7d76e3f987 aerocore nsh: Upstream NuttX defconfig changes
was:CONFIG_ARM_TOOLCHAIN_IAR is:CONFIG_ARCH_TOOLCHAIN_IAR
   was:CONFIG_ARM_TOOLCHAIN_GNU is:CONFIG_ARCH_TOOLCHAIN_GNU
   was:CONFIG_MUTEX_TYPES is:CONFIG_PTHREAD_MUTEX_TYPES
2017-09-29 10:13:51 -04:00
David Sidrane 7d8eee202b Kinetis:Hack for imediate PWM update 2017-09-29 10:13:51 -04:00
David Sidrane 2b54ef458b Kinetis:PWM 2017-09-29 10:13:51 -04:00
David Sidrane 58c3c8a94b fmu:Fix stack overwrite 2017-09-29 10:13:51 -04:00
David Sidrane 444a7a2aec PX4 System changes to support 14 Timer IO channels 2017-09-29 10:13:51 -04:00
David Sidrane df2b5e420f nxphlite-v3:Define PWM and Capture 2017-09-29 10:13:51 -04:00
David Sidrane 681a862b65 Updated NuttX submodule to upstream 7.20+ ==upstream
Latest uptake. PX4 contrib for Kinetis K66  pin map fixes.
2017-09-29 10:13:51 -04:00
David Sidrane 6979588486 Patch tracks upsteam NuttX change to apps/Makefile
A recent change in upstream Nuttx apps/Makefile to fix external
  pathing required the patch to be updated.
2017-09-29 10:13:51 -04:00
David Sidrane 2982f7f53a s2740vc-v1: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane 6dfa55af45 px4fmu-v4pro: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane 0ed964ef78 px4fmu-v4: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane 5708f5f945 px4fmu-v1: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane b46e586293 px4flow-v2: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane 5fe857b188 px4cannode-v1: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane 830780f93e nxphlite-v3: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane c02848dfb9 nxphlite-v1: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane feb4aaa551 mindpx-v2: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane 85fcd55908 auav-x21: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane e4583e0ec7 aerocore2: Upstream NuttX reloaction of can.h
can.h was moved in upstream NuttX from nuttx/drivers/can.h
   to nuttx/include/nuttx/can/can.h
2017-09-29 10:13:51 -04:00
David Sidrane 5bace5d0fe nxphlite-v3:Configure Tone Alarm 2017-09-29 10:13:51 -04:00
David Sidrane 520850f5f4 kinetis:Implemented Tone Alarm using TPM timers 2017-09-29 10:13:51 -04:00
David Sidrane 6e2885cc4e nxphlite-v3:Board mods to support 1 Mhz FTM 2017-09-29 10:13:51 -04:00
David Sidrane 24edfbcbca nxphlite-v3:GPIO_TRI set as output 2017-09-29 10:13:51 -04:00
David Sidrane d8513afcc0 nxphlite-v3:Init TONE ALARM IDLE 2017-09-29 10:13:51 -04:00
David Sidrane e172328f26 nxphlite-v3:Init GPIO_SPEKTRUM_P_EN pin 2017-09-29 10:13:51 -04:00
David Sidrane 9342c81cf2 nxphlite-v3:Using new SPEKTRUM API 2017-09-29 10:13:51 -04:00
David Sidrane 9ec37a78ff nxphlite-v3:Add mpl3115a2 (stubed out) 2017-09-29 10:13:51 -04:00
David Sidrane 32cd31c814 sensors: Add mpl3115a2 2017-09-29 10:13:51 -04:00
David Sidrane f21025aac7 mpl3115a2: Added stubbed out driver to validate whoami 2017-09-29 10:13:51 -04:00
David Sidrane c17949a1d1 Update submodule NuttX ==upstream 2017-09-29 10:13:51 -04:00
David Sidrane 80293d312f Update submodule NuttX ==upstream
PX4 NuttX Kinetis contrib for Kinetis I2C pin definitions
   inclding the Open drain configuration
2017-09-29 10:13:51 -04:00
David Sidrane 39a34c5b62 Update submodule NuttX ==upstream
PX4 NuttX Kinetis contrib now in upstream for:

        TPM support
        OSC Updated fro K66
        UART and LPUART HW flow control and temios
        BOARD_OSC_CR derived by board

        RC input
          PPM
          SBUS

       I suspect non exsitent sensors fails  are using way to much cpu
       resulting in PPM decode fails.
2017-09-29 10:13:51 -04:00
David Sidrane 0e55a9e868 micro hal:Kinetis I2C busses are numbered from 0 2017-09-29 10:13:51 -04:00
David Sidrane eace382da9 nxphlite-v3: Indicate use of TMP for tone alarm 2017-09-29 10:13:51 -04:00
David Sidrane b9e71ea8d1 Update submodule NuttX ==upstream_kinetis
PX4 NuttX Kinetis contrib for

    TPM support
    OSC Updated fro K66
    UART and LPUART HW flow control and temios
    BOARD_OSC_CR derived by board

    RC input
      PPM
      SBUS

   I suspect non exsitent sensors fails  are using way to much cpu
   resulting in PPM decode fails.
2017-09-29 10:13:51 -04:00
David Sidrane 2b853ea00e nxphlite-v3:Using termios and HW flow control
Using PX4 contrib of termios and HW flow control in NuttX
   Kinetis.

   Removed stubs and updated defconfig.
2017-09-29 10:13:51 -04:00
David Sidrane 2f2f1ff8ea nxphlite-v3:Use 8bit io on usart access for inversion
Fix comment
  Use 8bit io on usart access for inversion, 32 bit
  on odd address was causwing BUS access hard fault.
2017-09-29 10:13:51 -04:00
David Sidrane 5ed8955db7 Update submodule NuttX ==upstream_kinetis
Wip - HRT RC IN
2017-09-29 10:13:51 -04:00
David Sidrane f1e8b532d9 ADC hack to get comd prompt 2017-09-29 10:13:51 -04:00
David Sidrane 69661df783 tap-v1:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane dad290a8fc px4nucleoF767ZI-v1:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for s
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane 9dbaa001d3 px4fmu-v5:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane e332bfa726 px4fmu-v4pro:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane 3ade7c303a px4fmu-v4:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macr
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane e38d5853ad px4fmu-v2:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane a0b6b90abf px4cannode-v1:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane 6894425fa6 nxphlite-v3:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane a9e58df215 nxphlite-v1:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane bc856df03b mindpx-v2:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane 0232a24ae6 auav-x21:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane 40a6de5821 aerofc-v1:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane 5613a2f4e4 aerocore2:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane c12f9943ab aerocore:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
2017-09-29 10:13:51 -04:00
David Sidrane 25c8ceaf91 mtd:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane 0d2124ce13 ms5611:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane fcbb99200f mpu9250:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane 487315af19 mpu6000:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane 1e4113ee37 lsm303d:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane 7e24ec12d9 lps25h:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane 7df27aa344 lis3mdl:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane 44a07e7084 l3gd20:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane 3cef14482a hmc5883:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane 81bd05d49c bmp280:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane a5ea55cc5c bmi160:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane 045771ffcb bmi055:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane bd185ceb22 bma180:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane b4a9c1578b board common:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device and macros
   that define a PX4 device on a given BUS and Chip Select
   Refactored to pack the PX4 format in the new NuttX format
2017-09-29 10:13:51 -04:00
David Sidrane fa0ae6386d device:spi_dev_e is now uint32_t in NuttX
Using new type of uint32_t for spi device
2017-09-29 10:13:51 -04:00
David Sidrane c9040257ec Update submodule NuttX ==upstream
Latest upstream with SPI chip select changes
2017-09-29 10:13:51 -04:00
David Sidrane c977536671 nxphlite-v3:Assign TPM1 CH0 to HRT, CH1 PPM 2017-09-29 10:13:51 -04:00
David Sidrane ebaf8479c5 nxphlite-v3:Clock configuration for TPM 2017-09-29 10:13:51 -04:00
David Sidrane 8fd5fb00a3 nxphlite-v1:Add Debug probes 2017-09-29 10:13:51 -04:00
David Sidrane f6cacfc586 Kinteis:HRT Driver using TPM Timer
This is the PX4 HRT driver fir the Kinetis K family with TPM
   timers.

   The requirements for use are an input frequency divisible by
   N = {2^0-2^7}. To get a 1 MHz frequency. We currently use
   the OCSERCLK of 16 MHz /16.
2017-09-29 10:13:51 -04:00
David Sidrane 26d65f9369 Update submodule NuttX ==upstream_kinetis
Wip - HRT RC IN
2017-09-29 10:13:51 -04:00
David Sidrane 5aa449f226 nxphlite-v3:Set FRDIV to 512 to keep clock in spec 2017-09-29 10:13:51 -04:00
David Sidrane 5608b8ca76 nxphlite-v3:Refreashed config
Removed Networking until upstream settels down
2017-09-29 10:13:51 -04:00
David Sidrane fba425c168 Updated patch list for rebase on PX4/Firmware master 2017-09-29 10:13:51 -04:00
David Sidrane 417b853f77 Update submodule NuttX ==upstream_kinetis
Latest upstream
   with minor warning fixed
2017-09-29 10:13:51 -04:00
David Sidrane e2bd3b31d2 Kinetis:tone_alarm updated copyright 2017-09-29 10:13:51 -04:00
David Sidrane bc4102bf3f Added pwm_trigger from master 2017-09-29 10:13:51 -04:00
David Sidrane 2295bdcdf2 Update submodule NuttX ==upstream 2017-09-29 10:13:51 -04:00
David Sidrane 3cf820ffd8 Update submodule NuttX ==upstream
Latest upstream
2017-09-29 10:13:51 -04:00
David Sidrane 4db220d980 Update submodule NuttX ==upstream_kinetis
Latest upstream_kinetis rebased on upstream
2017-09-29 10:13:51 -04:00
David Sidrane 7ab29a38bf Kinetins ADC wip just to built and boot. Still Stubs 2017-09-29 10:13:51 -04:00
David Sidrane 790da4dec3 Kinetis:hrt stub - to get to command prompt 2017-09-29 10:13:51 -04:00
David Sidrane 9a0fbe5623 Inital commit of nxphlite-v3 per v3 schematic 2017-09-29 10:13:51 -04:00
David Sidrane deecf98f6e Update submodule NuttX ==upstream_kinetis
Latest Upstrem
   removed back ports for i2c-hotfix, stm32f7-serial-dma, and
   add-set-ex-to-nsh in upstream
2017-09-29 10:13:51 -04:00
David Sidrane 5922e08f5e nxphlite-v1:incorperate master's led changes and fit 2017-09-29 10:13:51 -04:00
David Sidrane e281958b43 nxphlite-v3:incorperate master's led changes 2017-09-29 10:13:51 -04:00
David Sidrane 53e9ce8352 incorperate master's oneshot api - not functional 2017-09-29 10:13:51 -04:00
David Sidrane f50b9ddbae Removed BACKPORT patches in upstream 2017-09-29 10:13:51 -04:00
David Sidrane 5f92fe7e51 Renamed for ordering and classification 2017-09-29 10:13:51 -04:00
David Sidrane 81d3c9a5e1 Removed patch - uptream was fixed 2017-09-29 10:13:51 -04:00
David Sidrane 10f84b4687 Updated NuttX submodule to upstream 7.20+ ==upstream 2017-09-29 10:13:51 -04:00
David Sidrane 4c1e397a51 Baseline defconfig 2017-09-29 10:13:51 -04:00
David Sidrane d0d4024cc8 Baseline defconfig 2017-09-29 10:13:51 -04:00
David Sidrane 7a4c5c3475 Added board_read_VBUS_state to board_common API 2017-09-29 10:13:51 -04:00
David Sidrane 67abeaf182 Fixed PX4_MK_GPIO macro 2017-09-29 10:13:51 -04:00
David Sidrane 83aa569f0b Updated NuttX submodule to upstream 7.20- ==upstream_kinetis 2017-09-29 10:13:51 -04:00
David Sidrane 1f5e0907d5 Updated NuttX submodule to upstream 7.20- ==upstream 2017-09-29 10:13:51 -04:00
David Sidrane 21caf63e13 Update px4iofirmware, px4io and drivers to uses NuttX IRQ API changes 2017-09-29 10:13:51 -04:00
David Sidrane bc81339a68 Update stm32 to uses NuttX IRQ API changes 2017-09-29 10:13:51 -04:00
David Sidrane e5eab6854c Update Kinetis stubs to uses NuttX IRQ API changes 2017-09-29 10:13:51 -04:00
David Sidrane 3bdbd53441 Update tap-v1 tap_pwr to uses NuttX IRQ API changes 2017-09-29 10:13:51 -04:00
David Sidrane 8f24b1c6e0 Update libuavcan Submodule to uses PX4 contrib to uavcan for NuttX IRQ API changes 2017-09-29 10:13:51 -04:00
David Sidrane 49ccaa6597 Shrink FLASH to fit with Upstream NuttX 2017-09-29 10:13:51 -04:00
David Sidrane 21dec52be0 px4io-v1 nsh add CONFIG_NOARQARG to reduse RAM size 2017-09-29 10:13:51 -04:00
David Sidrane 99f694598e Updated NuttX submodule to upstream 7.19+ ==upstream
The has the upstream irq dispatch changes and PX4 contrib fixes
   There is now a  large static (4*NR_IRQ) NR_IRQ is > 77 on most SoS
   that is uses to save and pass args to an interrupt service.
   The problem this introduces is running out of ram on the
   STM32F100 devices. So we will carry a set patches to at
   COMPILE time use the oldstyle dispatch.
2017-09-29 10:13:51 -04:00
David Sidrane fe3398300b nxphlite-v1 Changes to provides USB clocking
Support the PX4 contrib to upstream Nuttx for SIM. MCG and PMC
  clocking. Now sets the USB clock correctly.

  Refit in FLASH
2017-09-29 10:13:51 -04:00
David Sidrane 73944daf75 nuttx_nxphlite update config for changes on master 2017-09-29 10:13:51 -04:00
David Sidrane 7cde985e27 WIP nxphlite-v3
Configure Clocking, USB and Console on LPUART
2017-09-29 10:13:51 -04:00
David Sidrane 6dfae5bfac Refreshed nxphlite-v3 nsh config 2017-09-29 10:13:51 -04:00
David Sidrane 8f8159fba6 Updated NuttX submodule to upstream 7.19+ ==upstream
With PX4 contrib for USB, Clocking, LPUART and UART
   console selection and reordering
2017-09-29 10:13:51 -04:00
David Sidrane 1d8b0f14df Updated NuttX submodule to upstream 7.19+ ==upstream_kinetis
With PX4 contrib and numerous fixes from Greg adding
      Kinetis LPUART
2017-09-29 10:13:51 -04:00
David Sidrane 55cd301dac Updated NuttX submodule to upstream 7.19+ ==upstream
With PX4 contrib adding Kinetis feature selection for
  SIM and PCM
2017-09-29 10:13:51 -04:00
David Sidrane 46e57a51a3 Updated NuttX submodule to upstream 7.19+ ==upstream 2017-09-29 10:13:51 -04:00
David Sidrane 63af555c50 Updated NuttX submodule to upstream 7.19+ ==upstream_kinetis
Fixes strings.h index macro colliding with c++ classes with
   that have index as an initalized member variable.
2017-09-29 10:13:51 -04:00
David Sidrane 343f05e1bc zubaxgnss-v1 bootloader Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 0ccf3e0c9e tap-v1 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane d5774b3179 s2740vc-v1 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 0b5f7a4d4b s2740vc-v1 bootloader Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 741191e842 px4nucleoF767ZI-v1 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 99c66115e5 px4io-v1 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane ccb2bcf7c1 px4fmu-v5 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane a81889a1c5 px4fmu-v4pro nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 3a4013440a px4fmu-v4 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 63812b847a px4fmu-v3 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 3e6abf0812 px4fmu-v2 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 981f673084 px4flow-v2 bootloader Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 3ea3450feb px4esc-v1 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane a0f1dbe554 px4esc-v1 bootloader Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane d5795f4467 px4cannode-v1 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 1d9933796d px4cannode-v1 bootloader Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 210495d263 px4-stm32f4discovery nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 2f792dcfcd nxphlite-v3 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 431a107138 nxphlite-v1 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 82f566f941 mindpx-v2 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 01699b32bc esc35-v1 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 74aeff4d04 esc35-v1 bootloader Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane b379249a31 crazyflie nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 37c556eb0b auav-x21 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 5f3c31e6c5 aerofc-v1 nsh Update for upstream NuttX removed CONFIG_LIBC_ARCH_BZERO 2017-09-29 10:13:51 -04:00
David Sidrane 770fab470d Updated NuttX submodule to upstream 7.19+ ==upstream
Fixes strings.h index macro colliding with c++ classes with
   that have index as an initalized member variable.
2017-09-29 10:13:51 -04:00
David Sidrane 287219e197 Update NuttX submodule 7.19+ ==upstream
Pickes up upstream changes that define fully define
  include/cxx/cwchar - we no longer need the PX4 patch
2017-09-29 10:13:51 -04:00
David Sidrane 5e96053651 Updated NuttX submodule to upstream 7.19+ ==upstream_kinetis
With PX4 contrib adding Freedom-K66 and Kinetis K66 Support
   and pending updates to upstream
2017-09-29 10:13:51 -04:00
David Sidrane a611fcdeeb Update submodule NuttX ==upstream_kinetis
Picks up stat() etal
2017-09-29 10:13:51 -04:00
David Sidrane 509b1ec1c5 Updated Shadow patch for addition of stat() in upstream 2017-09-29 10:13:51 -04:00
David Sidrane 16714e3991 Updated NuttX submodule for kinetis WIP ==upstream_kinetis
With stat() from upstream
2017-09-29 10:13:51 -04:00
David Sidrane 2a7514194b Updated NuttX submodule for kinetis WIP ==upstream_kinetis
With setvbuf() and up_timer_initialize became arm_timer_initialize
2017-09-29 10:13:51 -04:00
David Sidrane 60bda1627a zubaxgnss-v1 bootloader Update for upstream NuttX up_timer_initialize changes
up_timer_initialize became arm_timer_initialize
2017-09-29 10:13:51 -04:00
David Sidrane 44bfd797b7 s2740vc-v1 bootloader Update for upstream NuttX up_timer_initialize changes
up_timer_initialize became arm_timer_initialize
2017-09-29 10:13:51 -04:00
David Sidrane 92c0e6861f px4flow-v2 bootloader Update for upstream NuttX up_timer_initialize changes
up_timer_initialize became arm_timer_initialize
2017-09-29 10:13:51 -04:00
David Sidrane c59817a622 px4esc-v1 bootloader Update for upstream NuttX up_timer_initialize changes
up_timer_initialize became arm_timer_initialize
2017-09-29 10:13:51 -04:00
David Sidrane 068e026ed1 px4cannode-v1 bootloader Update for upstream NuttX up_timer_initialize changes
up_timer_initialize became arm_timer_initialize
2017-09-29 10:13:51 -04:00
David Sidrane 2d00fdf630 esc35-v1 bootloader Update for upstream NuttX up_timer_initialize changes
up_timer_initialize became arm_timer_initialize
2017-09-29 10:13:51 -04:00
David Sidrane 4062061e59 zubaxgnss-v1 bootloader Update for upstream NuttX setvbuf changes 2017-09-29 10:13:51 -04:00
David Sidrane 3c8f31772d s2740vc-v1 bootloader Update for upstream NuttX setvbuf changes 2017-09-29 10:13:51 -04:00
David Sidrane 75b8770214 px4io-v1 nsh Update for upstream NuttX setvbuf changes 2017-09-29 10:13:51 -04:00
David Sidrane 57fb4ccec9 px4flow-v2 bootloader Update for upstream NuttX setvbuf changes 2017-09-29 10:13:51 -04:00
David Sidrane b389a4cd2d px4esc-v1 bootloader Update for upstream NuttX setvbuf changes 2017-09-29 10:13:51 -04:00
David Sidrane 893313f352 px4cannode-v1 bootloader Update for upstream NuttX setvbuf changes 2017-09-29 10:13:51 -04:00
David Sidrane 0308b1d363 esc35-v1 bootloader Update for upstream NuttX setvbuf changes 2017-09-29 10:13:51 -04:00
David Sidrane 227658c9ef Updated NuttX submodule for kinetis WIP ==upstream_kinetis 2017-09-29 10:13:51 -04:00
David Sidrane fb7b8d475a Updated NuttX submodule for kinetis WIP ==upstream_kinetis 2017-09-29 10:13:51 -04:00
David Sidrane c0d6918737 Updated Nuttx Submodule to use kinetis WIP ==upstream_kinetis 2017-09-29 10:13:51 -04:00
David Sidrane 9fd3eac282 Updated submodule NuttX for kinetis WIP ==upstream_kinetis 2017-09-29 10:13:51 -04:00
David Sidrane d409ca3e46 Inital commit of nxphlite-v3 2017-09-29 10:13:51 -04:00
David Sidrane 0e23df28ea Removed STM32 references from Kinetis 2017-09-29 10:13:51 -04:00
David Sidrane 23e45cb4b3 nxphlite-v1 Refreshed nuttx SDIO changes for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 91f14435d7 px4nucleoF767ZI-v1 Refreshed nuttx SDIO changes for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane f9aa9f29e3 px4fmu-v5 Refreshed nuttx SDIO changes for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 983c436f5d px4fmu-v4pro Refreshed nuttx SDIO changes for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 63b9c03e53 px4fmu-v4 Refreshed nuttx SDIO changes for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 0a25cc2254 px4fmu-v3 Refreshed nuttx SDIO changes for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane afad39fa14 px4fmu-v2 Refreshed nuttx SDIO changes for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 6ffcec48ba mindpx-v2 Refreshed nuttx SDIO changes for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 61e45ebb48 auav-x21 Refreshed nuttx SDIO changes for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 8ac9e82ac4 Updated NuttX submodules to upstream 7.19+ ==upstream
These changes add arch namespace to some SDIO related CONFIG defines
    in support of per channel capabilities for SDIO
    The SDIO api addes SDIO_CAPABILITIES(dev)
    and define SDIO_CAPS_1BIT_ONLY and SDIO_CAPS_DMASUPPORTED

  STM32
  -----

  WAS:
  CONFIG_SDIO_DMA=y

  IS:

  WAS:
  CONFIG_SDIO_DMAPRIO=0x00010000

  IS:
  CONFIG_STM32_SDIO_DMA=y
  CONFIG_STM32_SDIO_DMAPRIO=0x00001000

  WAS:
  CONFIG_ARCH_HAVE_SDIO=y
  CONFIG_ARCH_HAVE_SDIOWAIT_WRCOMPLETE=y
  CONFIG_MMCSD_SDIO=y
  CONFIG_SDIO_PREFLIGHT=y
  CONFIG_MMCSD_SDIOWAIT_WRCOMPLETE=y

  IS:
  CONFIG_ARCH_HAVE_SDIO=y
  CONFIG_SDIO_DMA=y
  CONFIG_ARCH_HAVE_SDIOWAIT_WRCOMPLETE=y
  CONFIG_MMCSD_SDIO=y
  CONFIG_SDIO_PREFLIGHT=y
  CONFIG_MMCSD_SDIOWAIT_WRCOMPLETE=y

  STM32F7
  -------
  WAS:

  IS:

  was CONFIG_SDMMC1_DMA
  is:Delketed
  was CONFIG_SDMMC2_DMA
  is:Delketed

  was:
  CONFIG_SDMMC1_PRI
  is:
  CONFIG_STM32F7_SDMMC1_PRI

  was:
  CONFIG_SDMMC2_PRI
  is:
  CONFIG_STM32F7_SDMMC2_PRI

  was:
  CONFIG_SDMMC1_DMAPRIO
  is:
  CONFIG_STM32F7_SDMMC1_DMAPRIO

  was:
  CONFIG_SDMMC2_DMAPRIO
  is:
  CONFIG_STM32F7_SDMMC2_DMAPRIO
2017-09-29 10:13:51 -04:00
David Sidrane c837096268 sim nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 9daa8ec3c7 zubaxgnss-v1 bootloader Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 13157b3e6c zubaxgnss-v1 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane cad85784a2 s2740vc-v1 bootloder Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 277f117ba4 s2740vc-v1 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 954c0bd601 px4nucleoF767ZI-v1 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 29437e1972 px4io-v1 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane bd87fb4f09 px4-stm32f4discovery nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 9871495e64 px4fmu-v5 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 10f9ec5400 px4fmu-v4pro nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane d3e9a54b4f px4fmu-v4 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 3f2b1a9d59 px4fmu-v3 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane af4ab31d61 px4fmu-v2 nsh refreshed config for Nuttx 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane b717a71e86 px4flow-v2 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane dcaba7d3d1 px4flow-v2 bootloader Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 9e746012a3 px4esc-v1 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 60c8424af4 px4esc-v1 bootloader Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane a32c3ee93d px4cannode-v1 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 47ccb3fa1c px4cannode-v1 bootloader Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane e2b8d3b043 nxphlite-v1 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 2b07444f0d mindpx-v2 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 3ea7083601 esc35-v1 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 6187769746 esc35-v1 bootloader Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane df0057e791 crazyflie nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 9ff583f690 auav-x21 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane 74cb3d6a66 aerofc-v1 nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane ff4ad00496 aerocore nsh Refreshed nuttx config for 7.19+ 2017-09-29 10:13:51 -04:00
David Sidrane cab44bfa01 Updated NuttX submodule to 7.19+ ==upstream 2017-09-29 10:13:51 -04:00
David Sidrane addaf84f7f zubaxgnss-v1 bootloader uses upstream NuttX's new struct packing 2017-09-29 10:13:51 -04:00
David Sidrane a47770250e px4flow-v2 bootloader uses upstream NuttX's new struct packing 2017-09-29 10:13:51 -04:00
David Sidrane 69ba0b8925 px4esc-v1 bootloader uses upstream NuttX's new struct packing 2017-09-29 10:13:51 -04:00
David Sidrane 2c9a6eb727 px4cannode-v1 bootloader uses upstream NuttX's new struct packing 2017-09-29 10:13:51 -04:00
David Sidrane 364551b6f5 esc35-v1 bootloader uses upstream NuttX's new struct packing 2017-09-29 10:13:51 -04:00
David Sidrane 187482c1ba flashfs uses Upstream NuttX's new struct packing 2017-09-29 10:13:51 -04:00
David Sidrane f6e82afff8 bootloader UAVCAN uses upstream NuttX's new struct packing 2017-09-29 10:13:51 -04:00
David Sidrane bf9a8a0bee Nuttx patches are now in upstream 2017-09-29 10:13:51 -04:00
David Sidrane 2aa8674f86 fmu Allow for using a common format 2017-09-29 10:13:51 -04:00
David Sidrane c168bd248f Use Proper ponter conversion
When PX4_CPU_UUID_BYTE_FORMAT_ORDER is not defined properly
 cast the arument for calling board_get_uuid_raw
2017-09-29 10:13:51 -04:00
David Sidrane 34627ac7b9 REVERT: To fit in FLASH
Conflicts:
	cmake/configs/nuttx_nxphlite-v1_default.cmake
2017-09-29 10:13:51 -04:00
David Sidrane fcb57afd3d Add Kinetis impelmantation Skeleton for board common SoC version api 2017-09-29 10:13:51 -04:00
David Sidrane ca9ac66b77 Add new lib/version 2017-09-29 10:13:51 -04:00
David Sidrane 1dbe8b8605 Adding Kinetis board common identity to micro hal 2017-09-29 10:13:51 -04:00
David Sidrane da178e8693 Adding Kinetis board common identitiy api 2017-09-29 10:13:51 -04:00
David Sidrane 0c576426b2 Add nxphlite-v1_default to alt builds for CI 2017-09-29 10:13:51 -04:00
David Sidrane b2b6509ee0 Use micro hal fir px4_savepanic
To keep board_crashdump.c as common code we create a
  wrapper around the arch depandant call to
  stm32_bbsram_savepanic.
2017-09-29 10:13:51 -04:00
David Sidrane 6669aa058d hardfault_log should has hal
remove stm32_bbsram.h and use px4_config.h
2017-09-29 10:13:51 -04:00
David Sidrane e93a5002a1 Updated Micro HAL for kinetis
Added px4_ abstraction macros
 Removed stm32.h reference
2017-09-29 10:13:51 -04:00
David Sidrane c1812af45e Inital commit of NXPhlite-v1 2017-09-29 10:13:51 -04:00
David Sidrane ec11b943a8 Allow an alternate startup file independent of bootloader builds
In support of bootloader builds the nuttx_v3 builds previously had a
facility to set the start up files: Non Bootloader STM32 builds uses
the common vectors facility in NuttX. The bootloaders use a fixed
minimum set of vectors.

Since other architectures my need to include a start up file or
set of files, this PR allow an alternate startup file to be
selected independent of if this is bootloader build.
2017-09-29 10:13:51 -04:00
Daniel Agar 28a9e32753 test perf use stdout, not stdin 2017-09-28 16:50:47 +01:00
Daniel Agar 4e5b223a08 hrt test decrease time 2017-09-28 16:50:47 +01:00
Daniel Agar af9690cf08 add simple posix tests to SITL 2017-09-28 16:50:47 +01:00
Daniel Agar 5eb3e695bb fix and enable mavlink ftp tests 2017-09-28 09:29:04 +02:00
Daniel Agar 3c18be387c ROI - move handling to navigator (#7939) 2017-09-26 12:25:02 -04:00
James Goppert e72769c924 Imu filter (#7606)
* Add adjustable driver level cutoff freq for accel/gyro.

* Fix copy and paste error.

* Updated print_info.

* imu filter minor cleanup
2017-09-25 13:55:56 -04:00
Lorenz Meier a945cd9fc2 Sensors: Clean up boot output (#8005)
Various sensors had too verbose or confusing boot output that would make the boot log hard to read. This patch ensures all output is consistently indicating if there is a real error or an optional sensor just not present. It also removed redundant error messages and adds an indication on which bus the sensor was probed.
2017-09-25 11:19:11 -04:00
Daniel Agar d04d62c37e airframe metadata sort by SYS_AUTOSTART and minor cleanup (#8009) 2017-09-25 11:17:50 -04:00
Daniel Agar 420df9d88a mavlink receiver remove undocumented CMD_PREFLIGHT_REBOOT_SHUTDOWN link shutdown (#8008) 2017-09-25 11:09:16 -04:00
Daniel Agar 4e0ddf86e1 rcS print full version 2017-09-25 10:30:22 -04:00
Daniel Agar 414b4d4a40 ver silence hwcmp 2017-09-25 10:30:22 -04:00
Daniel Agar 0da2dca8c1 drivers remove device _debug_enabled 2017-09-25 10:30:22 -04:00
ChristophTobler e5f46856c4 update submodule sitl_gazebo to include new range orientation 2017-09-25 11:46:44 +02:00
ChristophTobler 16825e6460 inav: subscribe to multi dist instances and check orientation 2017-09-25 08:52:21 +02:00
ChristophTobler bfe28c1df3 lpe: check for distance sensor orientation 2017-09-25 08:52:21 +02:00
ChristophTobler ee82e80517 ekf2: subscribe to multi dist instances and check orientation 2017-09-25 08:52:21 +02:00
ChristophTobler 58e09faf9b df trone wrapper: update for new orientation convention
add possibility to specify distance sensor orientation
2017-09-25 08:52:21 +02:00
ChristophTobler de0c196b2b Bebop rangefinder: update for new orientation convention 2017-09-25 08:52:21 +02:00
ChristophTobler 07e6738586 mavlink receiver: update for new orientation convention 2017-09-25 08:52:21 +02:00
ChristophTobler c315aa659e ulanding: update for new orientation convention
add possibility to specify orientation and adapt to new defaults and use px4_getopt
2017-09-25 08:52:21 +02:00
ChristophTobler 018aa8e535 srf02: update for new orientation convention
add possibility to specify orientation and adapt to new defaults and use px4_getopt
2017-09-25 08:52:21 +02:00
ChristophTobler d5ddc2b489 srf02_i2c: update for new orientation convention
add possibility to specify orientation and adapt to new defaults and use px4_getopt
2017-09-25 08:52:21 +02:00
ChristophTobler 4ed78595e7 sf1xx: update for new orientation convention
add possibility to specify orientation and adapt to new defaults and use px4_getopt
2017-09-25 08:52:21 +02:00
ChristophTobler 4f683db732 sf0x: update for new orientation convention
add possibility to specify orientation and adapt to new defaults and use px4_getopt
2017-09-25 08:52:21 +02:00
ChristophTobler 0fcc54f95f mb12xx: update for new orientation convention
add possibility to specify orientation and adapt to new defaults and use px4_getopt
2017-09-25 08:52:21 +02:00
ChristophTobler 21f97cfce6 LidarLite: update for new orientation convention
add possibility to specify orientation and adapt to new defaults and use px4_getopt
2017-09-25 08:52:21 +02:00
ChristophTobler 286d8f2bff teraranger: add possibility to specify orientation and adapt to new defaults 2017-09-25 08:52:21 +02:00
ChristophTobler a4d37f7120 PX4Flow: add possibility to specify sonar orientation and adapt to new defaults 2017-09-25 08:52:21 +02:00
ChristophTobler a45ed5f776 add constants for distance orientation convention 2017-09-25 08:52:21 +02:00
Paul Riseborough f0e8abe783 mc_pos_control: Use arming state to prevent unsafe reference point changes 2017-09-24 03:46:42 -07:00
Paul Riseborough ef0e47ee63 mc_pos_control: Fix bug causing flyaway when GPS gained after takeoff
The change in origin when GPS was gained after takeoff was being used to shift the set point despite the previous origin being invalid.
2017-09-24 03:46:42 -07:00
Daniel Agar 24f056d2bb mavlink receiver sync command_int/command_long 2017-09-24 03:45:21 -07:00
James Goppert 13e64d00a8 commander handle shutdown command (#8000) 2017-09-23 10:35:36 -04:00
José Roberto de Souza d82806869f cmake: AeroFC: Remove unused apps and libs (#7993)
We are running out of flash space in AeroFC so a cleanup is necessary.

Tools not used in Aero RTF, INAV, fixed wing control, vtol control and
unused libs was removed.

before
$ size build_aerofc-v1_default/src/firmware/nuttx/firmware_nuttx
   text    data     bss     dec     hex filename
 956880    3524   14608  975012   ee0a4 firmware_nuttx

after
$ size build_aerofc-v1_default/src/firmware/nuttx/firmware_nuttx
   text    data     bss     dec     hex filename
 832200    3508   14616  850324   cf994 build_aerofc-v1_default/src/firmware/nuttx/firmware_nuttx
2017-09-22 21:24:00 -04:00
eric 557559cd85 set _triplet_lat_lon_finite true to avoid landing to not the current location, see #7990 2017-09-22 15:20:13 +02:00
Daniel Agar b4755297ec delete control_state and cleanup vehicle_attitude (#7882) 2017-09-21 16:24:53 -04:00
Matthias Grob 5bea264a5f Matrix Quaternions: Apply simpler call for constructor and copying to all remaining modules 2017-09-21 17:44:57 +02:00
Matthias Grob 2941cea384 matrix: Switch to hamilton convention for quaternion product order and according ecl changes
Note: ecl needs to be updated at the same time
because as soon as the ecl is compiled within PX4 Firmware
the matrix submodule checked out by PX4 Firmware is used
for every call to a matrix or quaternion.
2017-09-21 17:44:57 +02:00
Beat Küng 26e4756055 mavlink_ftp_test: fix unit-tests 2017-09-21 07:33:09 +02:00
Beat Küng ebd2acfc43 posix-configs: enable ftp for all mavlink instances 2017-09-21 07:33:09 +02:00
Beat Küng 5b85b26351 mavlink_ftp: keep a copy of the last reply & resend it upon duplicated seq num 2017-09-21 07:33:09 +02:00
Beat Küng b072599679 mavlink_ftp: fix alignment issue 2017-09-21 07:33:09 +02:00
Beat Küng ea587d585f mavlink_ftp: add & handle kErrFailFileExists error
This error definitions already existed in QGC
2017-09-21 07:33:09 +02:00
Henry Zhang 4778c79201 commander: removed CONFIG_ARCH_BOARD_xxx usage 2017-09-20 18:40:55 -10:00
Henry Zhang d2a37ff9d5 MindPX: Schedule work queue with higher priority 2017-09-20 10:34:29 -04:00
Henry Zhang 12384f3ffb MindPX: Enable DDS 2017-09-20 10:34:29 -04:00
Henry Zhang 42627777a0 cmake configs : add camera_feedback module 2017-09-20 10:34:29 -04:00
sanderux b5c3bc7b0f Remove thrust_sp from pusher assist calculation 2017-09-20 10:51:06 +02:00
Daniel Agar 4e6ca271e7 more px4fmu-v1 cleanup (#7981) 2017-09-20 00:04:23 -04:00
Lorenz Meier 0780e430fd Sensors params: Adjust tube length to better default 2017-09-19 09:01:11 -07:00
Lorenz Meier 1880abdac5 Airspeed: Base sensor model on device ID from sensor 2017-09-19 09:01:11 -07:00
Andreas Antener 4ea49242d3 SDP3x pitot compensation: fixed the compensation and protect agains negative compensation values 2017-09-19 09:01:11 -07:00
Lorenz Meier b59aefc989 Airspeed measurement: Add accurate models for dynamic pressure
This allows to get very accurate readings from the SDP3x sensor series from Sensirion using a complete sensor model.
2017-09-19 09:01:11 -07:00
Daniel Agar 9cd915949a FW raise min airspeed based on commanded bank (#7575) 2017-09-19 11:06:40 -04:00
Daniel Agar 3498fe0c6f delete sdlog2 EKF2 replay (#7982) 2017-09-19 10:20:41 -04:00
Beat Küng b00c93ac21 mc_pos_control_main: add clarification that we're in world frame 2017-09-19 11:44:29 +02:00
Beat Küng 05e3c58e18 mc_pos_control_main: simplify manual control handling 2017-09-19 11:44:29 +02:00
Beat Küng d6df692b7a param MPC_MAN_TILT_MAX: decrease maximum from 90 to 85 degrees
At 90 degrees the yaw is extremely unstable (tested with HIL), it
overshoots and only very slowly converges to the correct value.
This behavior is also noticable with lower angles, but not so extreme.
It definitely needs to be looked into further, but for now this makes it
safer.
2017-09-19 11:44:29 +02:00
Beat Küng 55bd35cba6 mc_pos_control_main: improve the manual input setpoints 2017-09-19 11:44:29 +02:00
Beat Küng fc51c42280 mc_pos_control_main: fix types for parameter values 2017-09-19 11:44:29 +02:00
Daniel Agar 26f00609ac multirotor_motor_limits only publish for MC 2017-09-19 02:25:30 +01:00
Daniel Agar 9cacd3f994 BMP280 fix /dev/baroX unregister 2017-09-18 12:01:59 -07:00
Dennis Mannhart 82f25453a7 mc_pos_control: smooth position control from stick input 2017-09-18 13:30:16 +02:00
Daniel Agar fb5cb87e9b enable -Wlogical-op and fix bmi160 2017-09-16 21:29:52 +01:00
Daniel Agar a031552756 systemcmds remove extra semicolons 2017-09-16 21:29:52 +01:00
Daniel Agar 681f019ac3 platforms remove extra semicolons 2017-09-16 21:29:52 +01:00
Daniel Agar 545ce9ae24 modules remove extra semicolons 2017-09-16 21:29:52 +01:00
Daniel Agar 08fbd022af lib remove extra semicolons 2017-09-16 21:29:52 +01:00
Daniel Agar 9f44279488 include remove extra semicolons 2017-09-16 21:29:52 +01:00
Daniel Agar a1418c56ad examples remove extra semicolons 2017-09-16 21:29:52 +01:00
Daniel Agar 58268c832c drivers remove extra semicolons 2017-09-16 21:29:52 +01:00
Daniel Agar a87b6befbb ignore .vscode IDE directory 2017-09-16 21:29:52 +01:00
Daniel Agar aab91af05b unit_test add missing definition 2017-09-16 21:29:52 +01:00
Daniel Agar 79869c848f drivers fix missing field initializers 2017-09-16 21:29:52 +01:00
Daniel Agar 35e15ed540 cmake add -Wmissing-field-initializers and a few others 2017-09-16 21:29:52 +01:00
Daniel Agar d3ed773838 sensors coverity fix 143426 2017-09-16 21:28:24 +01:00
Daniel Agar 086ddf5078 logger coverity fix 143427 2017-09-16 21:28:24 +01:00
Daniel Agar 91cda08081 temperature calibration coverity fix 141891 2017-09-16 21:28:24 +01:00
Daniel Agar 5331768cb3 ekf2_reply_main coverity fix 143425 2017-09-16 21:28:24 +01:00
Daniel Agar 8ddd071f18 temperature_calibration coverity fix 141892 2017-09-16 21:28:24 +01:00
Daniel Agar 6341299062 ekf2_replay_main coverity fix 143428 2017-09-16 21:28:24 +01:00
Daniel Agar a766cb6722 px4io remove unused printf arg (#7974) 2017-09-16 14:50:59 -04:00
Daniel Agar 7e90716661 motor_ramp remove unreachable code (#7973) 2017-09-16 14:50:28 -04:00
Julian Oes 98de8c85a4 vmount: accept mavlink input from [0..360] degrees
This enables mavlink user input not only in the range of [-180..180]
degrees but also [0..360] degrees.
2017-09-15 14:41:07 +02:00
Mateusz Sadowski 8ba6c209d4 drivers: fix codestyle for teraranger driver
Signed-off-by: Mateusz Sadowski <msadowski90@gmail.com>
2017-09-15 12:07:16 +01:00
Mateusz Sadowski e439070f25 drivers: refactor trone driver to work with Evo
This commit changes old trone driver into a generic
TeraRanger driver that supports both TeraRanger One
and TeraRanger Evo.

As a part of the change a new parameter was created
SENS_EN_TRANGER that allows to specify the following
modes of operation:

0 - sensors disabled
1 - autodetect sensors
2 - use TeraRanger One rangefinder
3 - use TeraRanger Evo rangefinder

Signed-off-by: Mateusz Sadowski <msadowski90@gmail.com>
2017-09-15 12:07:16 +01:00
Mateusz Sadowski d5f8a300df Revert "drivers: add support for TeraRanger Evo"
This reverts commit d1da112334a875d83abbd04c50fd3bed3b069886.
2017-09-15 12:07:16 +01:00
Mateusz Sadowski ee72931190 drivers: add support for TeraRanger Evo
This commit adds i2c support for TeraRanger Evo sensor
by Terabee

Signed-off-by: Mateusz Sadowski <msadowski90@gmail.com>
2017-09-15 12:07:16 +01:00
Karl Schwabe 6d1aa4cad2 Bugfix: corrects the ARR calculation for the LED PWM timer
The calculation of the ARR on the LED PWM timer did not subtract 1
from the timer period calculation to get the ARR value.
2017-09-14 04:10:41 -10:00
ChristophTobler 8f7e2158f1 update ecl submodule to include flow fixes 2017-09-14 16:02:01 +02:00
David Sidrane b4eb6e4492 Makefile:distclean should not delete an local eclipse .settings 2017-09-14 09:52:27 +02:00
Karl Schwabe 38a4c1e90b Bugfix: corrects the ARR calculation for the PWM timer
The calculation of the ARR on the PWM timer did not subtract 1
from the timer period calculation to get the ARR value.
2017-09-13 08:25:06 -10:00
sanderux 919b3a218a Factor in reverse pusher delay on mission acceptance radius 2017-09-13 17:25:41 +02:00
NRottmann 5352cffe3f Changing Names 2017-09-13 06:20:05 -07:00
NRottmann e1eceda5f2 Change start up script
Now the start up script starts a GPS simulator as well as the ekf in order
to estimate position and orientation
2017-09-13 06:20:05 -07:00
NRottmann af58ccf173 Adding launch file to lpe folder 2017-09-13 06:20:05 -07:00
NRottmann 989b1484cc HippoCampus AUV: Enable start without ROS wrappers 2017-09-13 06:20:05 -07:00
NRottmann 81782444e4 Update sitl_gazebo to latest version 2017-09-13 06:20:05 -07:00
CarlOlsson 6a9f47b31e msg: Fix documentation of filter_fault_flag in estimator status msg
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2017-09-13 05:48:35 -07:00
David Sidrane 67679e56d0 [BACKPORT] stm32:stm32f40xxx I2C ensure proper error handling.
Injecting data errors would cause the driver to
  continually reenter the isr with BERR an RxNE.
  This fix allows the error to be cleared and
  propagated to the waiting task.
2017-09-13 05:40:50 -07:00
Daniel Agar f26933fc55 delete unused RC_DSM_BIND param 2017-09-13 05:30:14 -07:00
Julian Oes ee6a79279f commander: require local position for home
This fixes (or at least works around) a race condition where the
`status_flags.condition_local_position_valid` is still `false` but the
`status_flags.condition_global_position_valid` is already `true`.

The way to reproduce it is t:
1. Poll home position to check if home is initialized
2. Send arm and takeoff command as soon as home is initialized

Then arming will succeed but takeoff will fail because there is a check
for `status_flags.condition_local_position_valid` in
`main_state_transition()` to enter TAKEOFF.
2017-09-13 10:06:40 +02:00
Beat Küng 19e7ba63ee param: use separate param save lock
param save is an expensive operation that can take several 100ms. And
previously it was possible that a param_get() caller was blocked on a
save operation. If this happened due to a param change notification,
important modules, such as sensors, could have been blocked for a longer
period (and affecting the flight performance).
With this patch, this situation is not possible anymore, because a param
save now uses the reader lock and a separate file lock.

However it is still possible that a param_set() needs to wait for a save
operation, thus blocking for a longer time. param_set() thus needs to be
avoided in important modules when the system is armed.
In the case of mavlink it works, since it does not affect the flight if
the mavlink receiver is blocked over a longer time. It is only problematic
if a joystick is used as input or in offboard control.
2017-09-12 08:46:10 +02:00
James Goppert 4ce803b321 Update LPE init script. 2017-09-11 21:40:42 +01:00
Karl Schwabe 47d7465476 Bugfix: corrects orientation of magnetometer raw values
The magnetomer raw values were not being rotated in the same direction as
the scaled values. This meant that if the rotation was set to ROTATION_NONE,
the raw values and scaled values were off by 180 degrees.
2017-09-11 10:24:35 -07:00
sanderux 07a995a621 Code style 2017-09-11 12:08:39 +02:00
sanderux 1d2a08bd2d VTOL back transition: check only forward velocity 2017-09-11 12:08:39 +02:00
Dennis Mannhart a398dc09c7 mc_pos_control: set curr_pos_sp(0:1) to pos(0:1) if non-finite 2017-09-11 02:08:22 -07:00
Dennis Mannhart 22be99da3e mc_pos_control: change name _pos_first_nofinite to _triplet_lat_lon_finite 2017-09-11 02:08:22 -07:00
Dennis Mannhart cdb610a453 mc_pos_control: remove _limit_vel_xy 2017-09-11 02:08:22 -07:00
Dennis Mannhart 9ea465b66b mc_pos_control auto: fix curr pos sp mapping to local frame 2017-09-11 02:08:22 -07:00
Dennis Mannhart cb9efd7119 mc_pos_control: remove unused defines and add SIGMA 2017-09-11 02:08:22 -07:00
Dennis Mannhart 352f86fff4 mc_pos_control reintegration fixes of duplicates, unused parameter and order 2017-09-11 02:08:22 -07:00
Dennis Mannhart bf5e81a34f mc_pos_control param: acceleration parameters adjustment and addition 2017-09-11 02:08:22 -07:00
Dennis Mannhart 10a9c410e3 mc_pos_control: parameter for maximum horizontal velocity 2017-09-11 02:08:22 -07:00
Dennis Mannhart 8eca82022c mc_pos_control: sub param.acc with block param 2017-09-11 02:08:22 -07:00
Dennis Mannhart 44e4beeeec mc_pos_control: check if triplets are valid, otherwise ignore 2017-09-11 02:08:22 -07:00
Dennis Mannhart 5b03c5f68e navigator: reset triplets during onboard/offboard mission update 2017-09-11 02:08:22 -07:00
Dennis Mannhart c84c7cdcb4 mc_pos_control: set previous triplet point to invalid when switching to manual 2017-09-11 02:08:22 -07:00
Dennis Mannhart 2ceb703613 mc_pos_control: use math::constrain 2017-09-11 02:08:22 -07:00
Dennis Mannhart 947d63fb11 mc_pos_control auto: replace min_cruise_speed with cruise_speed_90; take care of case when cruise_speed_90 is exactly in the middle of max and min 2017-09-11 02:08:22 -07:00
Dennis Mannhart 3538f028b4 mc_pos_control: use 0.5 of acceleration for auto 2017-09-11 02:08:22 -07:00
Dennis Mannhart 807d45c99c mc_pos_control slowing down close to target take over previous setpoint if low 2017-09-11 02:08:22 -07:00
Dennis Mannhart ac3321dc6c mc_pos_control: distinguish between up and down acceleration 2017-09-11 02:08:22 -07:00
Dennis Mannhart c1199d1202 mission don't apply slewrate for altitude 2017-09-11 02:08:22 -07:00
Dennis Mannhart 9ec0d72f3c mc_pos_control: make sure that passing waypoint only allowed if altitude is reached 2017-09-11 02:08:22 -07:00
Dennis Mannhart b769d1cee0 mc_pos_control auto: apply auto logic for z-direction 2017-09-11 02:08:22 -07:00
Dennis Mannhart 2655c72cea mission: remove altitude foh for rotarywing 2017-09-11 02:08:22 -07:00
Dennis Mannhart 8e99c73f49 mc_pos_control: don't divide by zero 2017-09-11 02:08:22 -07:00
Dennis Mannhart cb820a168a mc_pos_control: use original targethreshold when computing target_velocity 2017-09-11 02:08:22 -07:00
Dennis Mannhart 08d15f5402 mc_pos_control: remove target threshold from auto 2017-09-11 02:08:22 -07:00
Dennis Mannhart dbed42a720 mc_pos_control auto: ensure the order of cruise speeds during mission 2017-09-11 02:08:22 -07:00
Dennis Mannhart 3f73a56f5a mc_pos_control: accelerate faster in auto and increase speed at 90degrees angle 2017-09-11 02:08:22 -07:00
Dennis Mannhart 540c0bdafb mc_pos_control: accelerate faster 2017-09-11 02:08:22 -07:00
Dennis Mannhart 7a822c9db2 mc_pos_control: don't use slewrate in mission 2017-09-11 02:08:22 -07:00
Dennis Mannhart 267dbe9b7a mc_pos_control: when close to current and previous, ajdust target velocity 2017-09-11 02:08:22 -07:00
Dennis Mannhart 0a37d8dc42 mc_pos_control: clarify speed params 2017-09-11 02:08:22 -07:00
Dennis Mannhart 9cfc57e4a6 mc_pos_control: rebase fix 2017-09-11 02:08:22 -07:00
Dennis Mannhart 3e4ab5ed59 mc_pos_control: when close to current and previous, ajdust target velocity 2017-09-11 02:08:22 -07:00
Dennis Mannhart c4c18caed4 mc_pos_control auto: set speed at 90degrees to 1 2017-09-11 02:08:22 -07:00
Lorenz Meier 38f796f991 mc pos control: More sign checks 2017-09-11 02:08:22 -07:00
Lorenz Meier a6108cc951 mc_pos_control: Use proper boundary checking when taking the norm of a vector
The previous method made too optimistic assumptions about the resolution of 32 bit floating point numbers.
2017-09-11 02:08:22 -07:00
Dennis Mannhart 4c4ee1af14 mc_pos_contol: sub eplsion with sigma, treat current behind independently 2017-09-11 02:08:22 -07:00
Dennis Mannhart 7734279f61 mc_pos_control: smooth transition between waypoint updates 2017-09-11 02:08:22 -07:00
Dennis Mannhart 3053b24761 mc_pos_control: auto remove min dist 2017-09-11 02:08:22 -07:00
Dennis Mannhart 8c5b1d33da mc_pos_contol: add break when printing warning 2017-09-11 02:08:22 -07:00
Dennis Mannhart 13f8936cf1 mc_pos_control: warning for invalid thrust sp 2017-09-11 02:08:22 -07:00
Lorenz Meier e58766c394 MC pos controller: log exceptions but rate-limit them 2017-09-11 02:08:22 -07:00
Dennis Mannhart 11a4410500 mc_pos_control: revert protection against nan thrust sp 2017-09-11 02:08:22 -07:00
Dennis Mannhart dae1093bec mc_pos_control: auto logic description and sanity check for thrust setpoint 2017-09-11 02:08:22 -07:00
Dennis Mannhart 6e5fe947fe mc_pos_control: add clarification to auto function and auto angle computation 2017-09-11 02:08:22 -07:00
Dennis Mannhart e51e52f425 mc_pos_control: reorder auto logic and ensure that nan gets caught 2017-09-11 02:08:22 -07:00
Dennis Mannhart 5d4486c920 mc_pos_control: only follow line if longer than 0.1 2017-09-11 02:08:22 -07:00
Dennis Mannhart 50e3c4067a mc_pos_control: update _curr_pos_sp all the time 2017-09-11 02:08:22 -07:00
Dennis Mannhart 9dc5051504 mc_pos_control auto: use current velocity if smaller than velocity setpoint when slowing down 2017-09-11 02:08:22 -07:00
Dennis Mannhart a84baa1dcc mc_pos_control auto: adjust velocity only along track; use vector instead of point 2017-09-11 02:08:22 -07:00
Dennis Mannhart 2735280ffc mc_pos_control auto: treat off the track differently depending on position 2017-09-11 02:08:22 -07:00
Dennis Mannhart a7be9854d9 mc_pos_control: remove scaling in auto and remove limit_velocity function; update auto logic 2017-09-11 02:08:22 -07:00
Beat Küng c82deaf26f dataman: fix test for return value of px4_task_spawn_cmd
And destroy the semaphore if startup fails.

Credits for finding this go to @jeonghwan-lee
2017-09-11 02:04:27 -07:00
David Sidrane 694de32740 ROMFS::Removed ardrone_interface from PX4 only used PX4v1
Removed that driver was only referenced from the now depricated
      px4fmuv-1
2017-09-10 13:37:23 -04:00
David Sidrane ca9e323b13 ardrone_interface:Removed ardrone_interface from PX4 only used PX4v1
Removed that driver was only referenced from the now depricated
  px4fmuv-1
2017-09-10 13:37:23 -04:00
David Sidrane 1e0489f48b PX4 System gpio_led:Code cleanup
Use PX4 log and module documantation
   Fixed memory leaks
2017-09-10 13:37:23 -04:00
David Sidrane bcb89f54e2 px4iofirmware:Removed FMUv1 and px4io-v1
Removed FMUv1 and px4io-v1, defaulting to px4io-v2
   were appicable.
2017-09-10 13:37:23 -04:00
David Sidrane e07cb71a11 px4io:Removed FMUv1 hardware dependancies
Removed conditional compilation for FMUv1 and defaulted to
   FMUv2.
2017-09-10 13:37:23 -04:00
David Sidrane 5782e5c5fd uavcan:Removed PX4FMUv1 support 2017-09-10 13:37:23 -04:00
David Sidrane 34cd7563fb commander:Removed PX4FMUv1 LED support 2017-09-10 13:37:23 -04:00
David Sidrane acb51aeda3 rgbled:Updated comment, removing reference to PX4FMUv1
Comment expressly referenced PX4FMUv1, but the EEPROM,
  could be used on any board.
2017-09-10 13:37:23 -04:00
David Sidrane f5e9ae6682 px4fmu:Removed FMUv1 only modes 2017-09-10 13:37:23 -04:00
David Sidrane 60ac35b0ac pwm_out_sim:Removed FMUv1 only modes 2017-09-10 13:37:23 -04:00
David Sidrane 8c8ea0754a PX4 System gpio_led:Removed FMUv1 2017-09-10 13:37:23 -04:00
David Sidrane 901af8d02c Removed PX4FMUv1 from eclipse.cproject 2017-09-10 13:37:23 -04:00
David Sidrane 7c88cb18c6 Removed PX4FMUv1 from readme 2017-09-10 13:37:23 -04:00
David Sidrane 3811ed0926 Removed PX4FMUv1 auto completions 2017-09-10 13:37:23 -04:00
David Sidrane 802fc415ed Debug Scripts:Removed FMUv1 2017-09-10 13:37:23 -04:00
David Sidrane 99bce71003 board_common:px4io-v1:Removed px4io-v1 board from PX4
Only provide paths to px4io-v2 bin files.
2017-09-10 13:37:23 -04:00
David Sidrane f6a0765d3c ROMFS:px4io-v1:Removed px4io-v1 board from PX4
Only support px4io-v2 px4io
2017-09-10 13:37:23 -04:00
David Sidrane 7123777e0e px4io-v1:Removed px4io-v1 board from PX4 2017-09-10 13:37:23 -04:00
David Sidrane 62a2351a72 ROMFS:Removed FMUv1 from rcS etal 2017-09-10 13:37:23 -04:00
David Sidrane c0bff500fe ROMFS:Removed fmuv1 exclude from mixers 2017-09-10 13:37:23 -04:00
David Sidrane c01889ea4f ROMFS:Removed fmuv1 exclude from Air Frames 2017-09-10 13:37:23 -04:00
David Sidrane 2cbd411a53 nuttx-configs:Removed errant comments referencing px4fmu-v1 2017-09-10 13:37:23 -04:00
David Sidrane a7ba7af89a FMUv1:Removed FMUv1 board from PX4 2017-09-10 13:37:23 -04:00
Julien Lecoeur ceeae7587e worst case analysis of stack usage (#7883)
* Makefile target "check_stack"
2017-09-10 13:34:34 -04:00
tops4u 24ed06156e Update sf1xx.cpp
Spaces to Tabs.
2017-09-09 17:36:59 +01:00
tops4u 2b700975f2 Added basic support for Lightware SF20/LW20 I2C connected LIDAR Devices 2017-09-09 17:36:59 +01:00
Nicolas de Palezieux a6ce2b320c mission: add heading towards ROI mode for multicopters 2017-09-08 12:50:15 -04:00
Daniel Agar 7a42424411 Navigator resurrect FW GPS failure navigation (#7762) 2017-09-08 12:18:59 -04:00
Daniel Agar e15afcca7a vehicle_command commands are uint16, not uint32 2017-09-08 09:06:30 +02:00
Larry Wang 0ae76aff32 updated to use rc driver from PX4, instead of from FC addons (#7798)
* updated to use rc driver from PX4, instead of from FC addons

* fixed format

* update per comments

* fix format

* fix format

* remove duplicated __PX4_QURT
2017-09-08 07:09:53 +02:00
Daniel Agar 8f1355c325 docker_run.sh add default port (14556 udp) and remove X11 setup (#7936) 2017-09-07 22:21:18 -04:00
Hancheol Choi 43667b240e mavlink fix incorrect attitude_sp subscription in HIGH_LATENCY (#7928) 2017-09-07 09:32:42 -04:00
Daniel Agar 665ab03f5c muorb fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar a3ccfe52ee pwm_out_rc_in fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar dd70892cb8 qshell fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar e6f2ba9864 bebop_fix fix sign compare 2017-09-07 10:27:36 +02:00
Daniel Agar 661b36df6b px4nucleo_spi fix sign compare 2017-09-07 10:27:36 +02:00
Daniel Agar 9b3b83f1ac uavcanesc ignore sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 3289fa292b px4flow fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 8e3efc5135 gpssim fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar d4502349fb syslink fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 33ee4fc453 linux_pwm_out fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar dd6892443c px4fmu-v5 fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar fc4a8ebb2a ulanding fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 5fedab7531 controllib fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 57cffa82f1 posix main fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 494e03000d tap_esc fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 6b2fa1127f iridiumsbd fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 275d81d4d5 stm32 common fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 4070abc132 gps fix sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 9b5fe8c476 ignore -Wsign-compare per module 2017-09-07 10:27:36 +02:00
Daniel Agar 35d908b453 cmake stop ignoring sign-compare 2017-09-07 10:27:36 +02:00
Daniel Agar 4e557e0f14 logger add manual_control_setpoint 2017-09-06 05:32:35 +02:00
Lucas De Marchi 9d6aee82dd aerofc: switch companion baud to 921600 2017-09-05 20:28:15 +01:00
Lucas De Marchi fd3b0eafb2 aerofc: allow to use 921600 baud to reboot 2017-09-05 20:28:15 +01:00
Daniel Agar 0c38f89b23 commander params wording 2017-09-05 12:57:25 -04:00
Daniel Agar 2fc29cf68f rc.fw_defaults FW position failsafe defaults 2017-09-05 12:57:25 -04:00
Daniel Agar dc18112697 EKF2 limit map reprojection (#7900) 2017-09-05 12:56:53 -04:00
Beat Küng 201b2bd75e logger: remove non-existing topics arm_auth_ack & arm_auth_request 2017-09-05 18:40:53 +02:00
Daniel Agar 49dceb2bff logger update topics (#7914)
- fixes #7911
2017-09-05 10:43:38 -04:00
Eric Wang 2b714e079b driver: vdev_posix, increase PX4_MAX_FD (#7905)
- avoid "exceeded maximum number of file descriptors" when "make posix gazebo_typhoon_h480"
 - closes #7892
2017-09-03 11:55:44 -04:00
Daniel Agar 962cdcf837 ulanding delete VDev usage (#7893) 2017-09-01 13:01:22 -04:00
Paul Riseborough c3b1ec8b24 commander: Changes resulting from code review
Change units of parameters from uSec to sec.
Change recommended FW value for COM_POS_FS_GAIN from 2 to 0
Fix error in parameter description for COM_POS_FS_PROB
Fix error in unit for COM_POS_FS_GAIN
2017-09-01 11:53:41 +02:00
Paul Riseborough 684a598d9f commander: Improve position failsafe parameter documentation 2017-09-01 11:53:41 +02:00
Paul Riseborough 491ba08af1 commander: Add parameters to control position failsafe behaviour
This is required because the hardcoded values were too sensitive for fixed wing use and bad initial mag heading could trigger the failsafe and lead to crashes on launch. The defaults have been left unchanged. Suitable values for fixed wing use will need to be implemented in the airframe specific config file.
2017-09-01 11:53:41 +02:00
Daniel Agar f67ac8ba00 land detector clang-tidy trivial changes 2017-08-31 22:49:44 -04:00
Daniel Agar 6e402bd6f4 land detector uniform initialization cleanup 2017-08-31 22:49:44 -04:00
Daniel Agar cb8cc9a795 land detector add cycle perf 2017-08-31 22:49:44 -04:00
Daniel Agar c250fb0a9e land detector FW round get_max_altitude()
- this prevents constant land detector publications
2017-08-31 22:49:44 -04:00
Daniel Agar 18d29d5a73 land detector FW uniform initialization 2017-08-31 22:49:44 -04:00
Daniel Agar 90819b2852 land detector move hysteresis constants into FW and MC 2017-08-31 22:49:44 -04:00
Daniel Agar fd8a5644e8 ets_airspeed posix port 2017-08-31 09:27:36 +02:00
Daniel Agar 15407afc6e ms4525_airspeed update test helpers 2017-08-31 09:27:36 +02:00
Daniel Agar 641a90708c sdp3x_airspeed posix port 2017-08-31 09:27:36 +02:00
Daniel Agar 9cd25d604b ms5525_airspeed posix port 2017-08-31 09:27:36 +02:00
Daniel Agar 676946c324 eagle add I2C defines 2017-08-31 09:27:36 +02:00
Daniel Agar 3a5ae7d1bb bebop add PX4 I2C defines 2017-08-31 09:27:36 +02:00
Daniel Agar 07619cf723 Make NuttX drivers cross platform (VDev -> CDev) 2017-08-31 09:27:36 +02:00
Sugnan Prabhu S 6562dd496b mavlink: implement MAV_CMD_REQUEST_FLIGHT_INFORMATION
Signed-off-by: Sugnan Prabhu S <sugnan.prabhu.s@intel.com>
2017-08-31 09:26:39 +02:00
jgs2185 8a1d8f2162 Ulanding: fix formatting issues 2017-08-30 14:53:25 +01:00
jgs2185 f59530ec1f Ulanding: remove unnecessary posix/nuttx platform differences 2017-08-30 14:53:25 +01:00
jgs2185 085540d5de Ulanding: clarify changes made due to ulanding versions 2017-08-30 14:53:25 +01:00
jgs2185 d23fb63c96 Ulanding: remove redundant lines in Radar constructor 2017-08-30 14:53:25 +01:00
jgs2185 e3ff2df7a0 Ulanding: add POSIX support for Aerotenna ulanding radar 2017-08-30 14:53:25 +01:00
jgs2185 f9d219b187 Ulanding: add ulanding to cmake driver lists 2017-08-30 14:53:25 +01:00
Julien Lecoeur b0c57fd65b Return bool in added MavlinkStream*::send() 2017-08-30 14:45:02 +01:00
Julien Lecoeur be74a1a4ed Log debug topics 2017-08-30 14:45:02 +01:00
Julien Lecoeur 798c6d0f56 Use char* for names of debug messages 2017-08-30 14:45:02 +01:00
Julien Lecoeur 1a445c9c76 Add debug_value and debug_vect to example px4_mavlink_debug 2017-08-30 14:45:02 +01:00
Julien Lecoeur 0e6e0f4cb0 Wrong indentation 2017-08-30 14:45:02 +01:00
Julien Lecoeur 12353f4da7 Add support for mavlink message DEBUG_VECT 2017-08-30 14:45:02 +01:00
Julien Lecoeur eeb966d375 Add support for mavlink message DEBUG 2017-08-30 14:45:02 +01:00
Julien Lecoeur b6c30cf9b2 Add support for incoming NAMED_VALUE_FLOAT mavlink messages 2017-08-30 14:45:02 +01:00
sanderux 595d706eaf Reverse pusher delay
Thist adds a delay for the reverse thrust to allow the motor to brake and avoid sync issues.
2017-08-30 08:08:25 +02:00
José Roberto de Souza 3fd7e3f89c modules: commander: Implement arm authorization request
If the second bit of COM_ARM_MIS_EXT_REQ is set the vehicle
will only arm after receive an authorization.

The authorization flow:
vehicle/external -> command: arm authorization request -> arm authorizer
vehicle <- command ack with result in progress <- arm authorizer
vehicle <- any data request <- arm authorizer
vehicle -> data response -> arm authorizer
vehicle <- command ack authorizing or denying <- arm authorizer

Right now there is 2 ways to start the arm authorization request,
that can be configured by COM_ARM_AUTH parameter.
- One arm: When pilot request the vehicle to arm, it will request
authorization blocking the arm process up to the timeout defined in
COM_ARM_AUTH parameter.
- Two arms request: The first arm request will request the
authorization and will deny the first arm request, if authorizer
approved the request, pilot can arm again within the authorized
time and arm without any block.

The arm authorizer can be running anywhere(compute board or PX4
itself) and it is responsible to request the mission list or any
other information to vehicle before send a final response, it
should send to vehicle a COMMAND_ACK with
result = MAV_RESULT_IN_PROGRESS as soon as it receive the arm
authorization request and the final result
as after it got all the data that it needs authorize or deny the
request.
2017-08-28 08:28:57 +02:00
José Roberto de Souza 66170d1c01 mavlink: Do not miss a vehicle_command
If 2 or more vehicle_command are queued a call to update() will
return the oldest vehicle_command and set the _cmd_time to the
timestamp of the last vehicle_command queued losing it.
Using update_if_changed() fix this causing all item being consumed
one at each call of send().
2017-08-28 08:28:57 +02:00
José Roberto de Souza dddac6c85a msg: Add arm authorization request command id 2017-08-28 08:28:57 +02:00
José Roberto de Souza 7e3ab95975 modules: commander: Group arm requirements in just one byte and add a new requirement
Instead of having several bools to each requirement to arm, lets group then
in a byte and use bitmask.
This also add a new arm requirement "arm authorization" that
will be implemented in another patch.
2017-08-28 08:28:57 +02:00
acfloria e5924f8172 ROMFS: Remove flaperons from AAERTWF mixer. 2017-08-26 22:37:51 +02:00
CarlOlsson 6135179202 generate_listener: Add support for uint16, int32 and int16 arrays
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2017-08-26 22:34:25 +02:00
CarlOlsson 49c0947cc2 generate_listener: Add space in array output
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2017-08-26 22:34:25 +02:00
David Sidrane cde3545560 px4fmu-v5:Configure PWM LED polarity, and swapping
Test HW has R and G LED swapped and drives the UI LED's active
  high. The changes support all the configuratons of FMUv5 on
  RC00 and RC01 HW for PWM status and UI LEDs.
2017-08-26 03:44:59 -10:00
David Sidrane 3e46b5d02f px4fmu-v5:Extend PWM LED definitions to suport polarity, drive and swaps
Added palarity mask to support active low drive on per channel
   bassis.

   Added open drain drive type when the enables are active low to
   ensure the LED are off when supplied form 5 volts.
   For active Push Pull is used. Active low drive is recomended.

   Added support for test HW that had the R and G LED signals
   swapped.
2017-08-26 03:44:59 -10:00
David Sidrane 2ef472d796 drv_led_pwm:Use hardware to support active hight or active low LED
Use the timer's polarity control bits to enable active low
   drive as apposed to inverting the counts.
2017-08-26 03:44:59 -10:00
David Sidrane 8dd05dadfd rgbled_pwm:Expand support for FMUv5 on board status and UI LEDs
FMUv5 can have 2 RGB LED's
2017-08-26 03:44:59 -10:00
David Sidrane dd00858ca7 px4fmu_common:FMUv5 start ist8310 on I2C1, I2C2 & I2C3 2017-08-26 03:44:59 -10:00
David Sidrane 3b5ca4257b px4fmu-v5:Add ist8310 to build for FMUv5 2017-08-26 03:44:59 -10:00
David Sidrane 9c68783c54 px4fmu-v5:Reorder I2C busses int 1-4 order
This alows the -b option map 1-to-1 with the 12C bus numbers
2017-08-26 03:44:59 -10:00
David Sidrane 8d21764dec ist8310:Use px4_getops 2017-08-26 03:44:59 -10:00
David Sidrane 24522ca885 ist8310:Expand suported busses to External I2C 1-4 2017-08-26 03:44:59 -10:00
David Sidrane a3b39394b8 px4fmu-v5:Added support for I2C LED driver 2017-08-26 03:44:59 -10:00
David Sidrane b54e1875ea mindpx-v2:Removed unsed and commented out rgbled_pwm driver 2017-08-26 03:44:59 -10:00
David Sidrane a14d256a2f tap_common:Add passivly starting the PWM rgbled driver
Board builds may now inclulde both the PWM and I2C RGB LED
    To add the PWM RGB LED driver:The board must define
    BOARD_HAS_LED_PWM and include rgbled_pwm the moulde list.

    This change attempts to start the either rgbled driver, that
    may or may not be present. If it is not present the +e
    setting allows the start up to continue.
2017-08-26 03:44:59 -10:00
David Sidrane 5c3f2b783f px4fmu_common:Add passivly starting the PWM rgbled driver
Board builds may now inclulde both the PWM and I2C RGB LED
   To add the PWM RGB LED driver:The board must define
   BOARD_HAS_LED_PWM and include rgbled_pwm the moulde list.

   This change attempts to start the PWM rgbled driver, that
   may or may not be present. If it is not present the +e
   setting allows the start up to continue.
2017-08-26 03:44:59 -10:00
David Sidrane 50e83ac33e rgbled:Allow I2C and PWM rgb led drivers to be used on the same board
Added RGBLED_PWM0_DEVICE_PATH path
  Renamed the main of the PWM rgbled driver to create a seperate command
2017-08-26 03:44:59 -10:00
Jasmine 8bf12f512b vtol tailsitter attitude control (#7841)
* revise pitch transition start and actuator_out_1 in transition

* update with new matrix math library
2017-08-26 12:05:17 +02:00
Daniel Agar edea4a369e uavcan start enforcing code style (#7856) 2017-08-25 13:07:21 -04:00
Daniel Agar de6a552b53 clang-tidy ignore clang-analyzer-cplusplus.NewDelete due to false positives 2017-08-24 19:03:58 +02:00
Beat Küng dd4be8aecf mavlink: only enable FTP if -x flag is provided 2017-08-24 19:03:58 +02:00
Beat Küng 12f1c342d0 mavlink_main: do not use message_buffer if _ftp_on
if _ftp_on is true, message_buffer was created and read, but it was
actually never written to, so this is not needed. It can only ever be
written to if _forwarding_on is true.
2017-08-24 19:03:58 +02:00
Beat Küng ca24c8e2b6 printload: add a column for the number of used file descriptors
And the maximum number of configured file descriptors.

Note that this is per group, not per thread, so that e.g. logger and
log_writer_file show the same number.
2017-08-23 08:11:44 +02:00
Beat Küng bc30a808ab DriverFramework: update submodule to latest master 2017-08-23 08:10:16 +02:00
Beat Küng 5f5dca4804 vdev: replace static list with an std::map
VDev::getDev() is used in px4_access, which is used in orb_exists. And if
the topic does not exist, it iterates over all 500 indexes, which is slow.
It was slow even if the topic existed, the map reduces runtime from linear
to logarithmic (there are around 80 items in the container).
This is only used on posix.
2017-08-23 08:10:16 +02:00
Beat Küng 409a1ce7d7 param SITL_BAT_DRAIN: add @unit s 2017-08-23 08:10:16 +02:00
Beat Küng 575e7be540 fix linux_pwm_out: return correct value for PCA9685::init() 2017-08-23 08:10:16 +02:00
Beat Küng 7a409cf843 vdev: remove unneeded devList & topicList methods 2017-08-23 08:10:16 +02:00
Daniel Agar 47eb371c01 delete Tools/make_color.sh 2017-08-23 08:07:36 +02:00
Daniel Agar c8bc6f961f topic_listener move generator to same directory 2017-08-23 08:07:36 +02:00
Daniel Agar 9f15c572a3 astyle scripting move to Tools/astyle 2017-08-23 08:07:36 +02:00
Daniel Agar a02caff1bc unit_test inline implementation and remove module build 2017-08-23 08:06:55 +02:00
Daniel Agar f282f50cff vmount run at default priority 2017-08-23 08:06:20 +02:00
Daniel Agar 47987f7e36 delete dummy tone alarm 2017-08-23 08:05:48 +02:00
Daniel Agar fd6499baca cmake simplify uavcan linking 2017-08-23 08:05:13 +02:00
PeterDuerr fb7b33e755 Use updated micro-CDR with memory leak fix (#7838)
* Fixed memory leak (indicated by cppcheck) upstream
2017-08-22 10:50:00 -04:00
Dennis Mannhart e39b38ba96 landdetector groundcontact: adjust climbrate if landing speed is low 2017-08-21 20:38:07 +02:00
Vicente Monge a9b12cc8b4 Changed the default behavior for the client launching as a infinite loop 2017-08-21 16:48:37 +02:00
ChristophTobler a2cf87b3ab run px4flow for v4 pro 2017-08-21 16:47:59 +02:00
Daniel Agar 1e42d523da mavlink main return main loop delay proper size 2017-08-21 01:31:27 +02:00
Daniel Agar 4b97e15714 commander remove orb_exists telemetry check 2017-08-21 01:30:17 +02:00
Lorenz Meier 52ba62d6c4 Navigator: Pause and unpause camera triggering on entering and exiting a mission 2017-08-20 22:47:48 +02:00
Lorenz Meier 447c167d3e Navigator: Add on_inactivation() interface.
This allows to run a command / function once when being deactivated. This avoids having flight modes which are not active run unnecessary code all the time.
2017-08-20 22:47:48 +02:00
NRottmann 0f8f5d29be Enable Simulation of the Hippocampus (AUV from TUHH)
Adding files which enable a simulation with the autonomous underwater
vehicle (AUV) from the Technical University Hamburg-Harburg
2017-08-20 20:59:15 +02:00
Lorenz Meier e33a2b6c8d Simulator: Add missing parameter_update topic 2017-08-20 20:54:58 +02:00
Daniel Agar b620da8f01 BlockParam update() and commit() add returns 2017-08-20 20:42:42 +02:00
Daniel Agar 633102e7ca List and ListNode cleanup 2017-08-20 20:42:42 +02:00
Daniel Agar b70b8288b9 px4_includes cleanup incomplete list 2017-08-20 20:42:42 +02:00
Daniel Agar e63da5860e uORB cleanup Subscription/Publication c++ 2017-08-20 20:42:42 +02:00
Lorenz Meier 7223780563 Simulator: Make battery discharging configurable. 2017-08-20 20:37:31 +02:00
AndresRengifo 641f2f856b fix: battery prearm check ignored when CBRK_SUPPLY_CHK is disabled 2017-08-20 19:36:54 +02:00
davidaroyer 0761d220b1 cmake: fix conflict in ocpoc ubuntu config 2017-08-20 19:35:55 +02:00
Julien Lecoeur 41cc679258 PX4Flow: allow restart directly after stop 2017-08-20 19:31:24 +02:00
Julien Lecoeur 7a3a9a75d5 Add command line options to PX4Flow app for I2C address and sampling rate 2017-08-20 19:31:24 +02:00
crossa 17ba5dd04a 1.Add sbus driver for linux . This driver can be used to read the
inverted S.bus signal and fetch the data of each channel and publish it

2. Fix the bug of linux_pwm_out, when the protocol is pca9685,
after the init method is executed,the method of determining the return
value of init method is incorrect,this will cause the driver to fail

3. Add linux_sbus driver to other posix prefixes cmake files
2017-08-20 16:51:04 +01:00
Daniel Agar b2a81ed35b multi diff pres sensor publication and logging 2017-08-19 22:49:29 +02:00
Daniel Agar 8db2883d84 delete unused tones 2017-08-19 09:50:41 +02:00
Mark Charlebois 295ffdc1b6 Use specific vesions
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-19 09:42:50 +02:00
Mark Charlebois 326445ba83 Removed support for astyle 2.05.1
There are bugs in version 2.05.1 (default version in Ubuntu 16.04)

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-19 09:42:50 +02:00
José Roberto de Souza 4462869432 Add support to new fields in command_ack 2017-08-19 09:04:52 +02:00
José Roberto de Souza d640d1aaf1 submodules: sitl_gazebo: Update to newest version 2017-08-19 09:04:52 +02:00
José Roberto de Souza 5136ccc647 submodules: mavlink: Update to newest version 2017-08-19 09:04:52 +02:00
José Roberto de Souza b7c705e790 msg: Add missing value of MAV_RESULT 2017-08-19 09:04:52 +02:00
José Roberto de Souza c200d0e9a4 Keep initialization of outgoing vehicle_command_s consistent
All others are initialized this way.
2017-08-19 09:04:52 +02:00
David Sidrane 79f49fd851 bugfix:px4fmu-v5 (STM32F7) random sd write failures
This is a back port of upstream NuttX PX4 contrib of

   ef42c25 stm32f7:SDMMC add dcache alignment check in dma{recv|send}setup
                   In the where CONFIG_SDIO_PREFLIGHT is not used and dcache
                   write-buffed mode is used (not write-through) buffer alignment
                   is required for DMA transfers because a) arch_invalidate_dcache
                   could lose buffered writes data and b) arch_flush_dcache could
                   corrupt adjacent memory if the buffer and the bufflen, are not on
                   ARMV7M_DCACHE_LINESIZE boundaries.

   1e7ddfe  stm32f7:SDMMC remove widebus limitation on DMA
                    There is no documantation for the STM32F7 that limits DMA on
                    1 bit vrs 4 bit mode.

   dffab2f  stm32f7:DMA add dcache alignment check in stm32_dmacapable
                    In the case dcache write-buffed mode is used (not write-through)
                    buffer alignment is required for DMA transfers because
                    a) arch_invalidate_dcache could lose buffered writes data and
                    b) arch_flush_dcache could corrupt adjacent memory if the
                    maddr and the mend+1, the next next address are not on
                    ARMV7M_DCACHE_LINESIZE boundaries.

   38cbf1f  stm32f7:DMA correct comments and document stm32_dmacapable
            Updated comment to proper refernce manual for STM32F7 not STM32F4.
            Added stm32_dmacapable input paramaters documentation.
2017-08-18 09:21:55 +02:00
Beat Küng 236021cc01 vmount mavlink input: fix polling for position_setpoint_triplet
The code was violating the rule 'every successfull poll must be followed
by an orb_copy'.
The result was a busy loop.
2017-08-17 07:47:48 +02:00
bresch 25bbe76530 FW att ctrl - Fix vehicle_attitude_setpoint timestamp logging when in stabilized (#7803) 2017-08-16 20:38:19 -04:00
CAI Dongcai 63306ada92 FW attitude and position control minor code cleanup (#7802)
- change a little bit to make the code more readable
2017-08-16 10:51:41 -04:00
Beat Küng 83643a719a nuttx config: increase CONFIG_NFILE_DESCRIPTORS from 53 to 54
This is needed when logger is logging to file and ulog streaming gets
activated.
2017-08-16 16:46:56 +02:00
Beat Küng ebafa5698d log_writer_file: register hardfault handler before opening the log file
hardfault_store_filename() opens and closes a file descriptor, so if we do
it before opening the log file, we need one file descriptor less
2017-08-16 16:46:56 +02:00
Beat Küng 9e01842c6a mavlink ulog: advertise ulog_stream topic before subscribing to ulog_stream_ack
This reduces the maximum number of needed file descriptors by 1 when using
ulog streaming.
2017-08-16 16:46:56 +02:00
Julian Oes ba150566c6 mavlink_command_sender: add some log printfs
This improves the printfs which will be logged. This should improve to
debug the camera triggering. The debug printfs are disabled by default.
2017-08-16 09:47:50 +02:00
Julian Oes 31edab6d6d mavlink_command_sender: remove unused include 2017-08-16 09:47:50 +02:00
sanderux 33e67fd527 Disable PA during landing 2017-08-16 08:19:06 +02:00
sanderux e6c942033b Disable pusher assist when descending 2017-08-16 08:19:06 +02:00
sanderux 8f5293d7b0 Remove explicit pusher throttle setting 2017-08-16 08:19:06 +02:00
sanderux 33efd89ef8 Disable pusher assist for quadchute failsafe 2017-08-16 08:19:06 +02:00
sanderux 66bb7adc4c simplify back transition throttle scaling 2017-08-16 03:06:13 +02:00
sanderux 6b9a8daceb Correctly name b_trans_thr and remove contraint 2017-08-16 03:06:13 +02:00
sanderux ff669ee645 Move vtol standard params 2017-08-16 03:06:13 +02:00
sanderux 7a8d3c4ab2 Correctly check reverse thrust conditions 2017-08-16 03:06:13 +02:00
sanderux 4396e78d12 Allow negative thrust on reverse throttle 2017-08-16 03:06:13 +02:00
sanderux 01d9212a29 Widen pusher throttle constraint 2017-08-16 03:06:13 +02:00
sanderux e5a55cd142 Support negative thrust for back transition 2017-08-16 03:06:13 +02:00
sanderux 59d81ee0f1 Clarify parameters 2017-08-16 03:06:13 +02:00
sanderux fbbe3d1f41 Check velocity valid and param description 2017-08-16 03:06:13 +02:00
sanderux 50894e8615 VTOL control back transition ramp up time 2017-08-16 03:06:13 +02:00
sanderux 560e9e88dc Apply slew rate to reverse thrust 2017-08-16 03:06:13 +02:00
sanderux e9516db5b0 Back transition duration based on deceleration m/s/s 2017-08-16 03:06:13 +02:00
sanderux 2e481867e5 Consider back transtition complete when MPC_XY_CRUISE is reached 2017-08-16 03:06:13 +02:00
sanderux 1a0c23d8b3 Support thrust reversal for vtol back transition 2017-08-16 03:06:13 +02:00
Dennis Mannhart f50052f290 landdetector mc: widen acceptance threshold after landing instead of arming 2017-08-15 10:30:29 +02:00
Daniel Agar 3c26c11144 circleci force git to use git:// 2017-08-14 17:03:06 -04:00
Daniel Agar a3645b1ed1 travis-ci force git to use git:// 2017-08-14 17:03:06 -04:00
Lorenz Meier 891b2f640d TAPv1: Schedule sensor priority higher 2017-08-13 11:40:54 +02:00
Lorenz Meier 00b65f38aa FMUv5: Schedule work queue with higher priority 2017-08-13 11:40:54 +02:00
Lorenz Meier c2341ad7f6 FMUv4PRO: Schedule work queue with higher priority 2017-08-13 11:40:54 +02:00
Lorenz Meier 6f5499af7d FMUv4: Schedule work queue with higher priority 2017-08-13 11:40:54 +02:00
Lorenz Meier c6f9cd84d0 FMUv4: Schedule work queue with higher priority 2017-08-13 11:40:54 +02:00
Lorenz Meier b2572a5795 FMUv2: Schedule work queue with higher priority 2017-08-13 11:40:54 +02:00
Lorenz Meier fa482b4ebd Racing boards: Default FMU to task as there is plenty of RAM to do this. 2017-08-13 11:39:44 +02:00
Lorenz Meier 9af9475541 RTPS: Ignore example processes 2017-08-13 11:39:00 +02:00
Lorenz Meier 23c790650a FMUv5: Enable DDS 2017-08-13 11:38:14 +02:00
Lorenz Meier 0e661e5a84 FMUv4PRO: Enable DDS 2017-08-13 11:38:00 +02:00
Lorenz Meier 2adb9e8c4f FMUv4: config style 2017-08-13 11:37:34 +02:00
Lorenz Meier fa123db5c3 FMUv3: Enable DDS 2017-08-13 11:37:15 +02:00
Lorenz Meier 9e312e8dba Uploader: Do not show timeout for larger binaries when everything is still as expected. 2017-08-13 11:36:12 +02:00
Lorenz Meier 861879c6d3 Widen threshold for standard gyro consistency check
Without temperature compensation the default is too narrow.
2017-08-12 12:50:46 +02:00
David Sidrane 67e470b0e1 px4fmu-v5:Use arch/polarity agnostic Power control macros
Use the board supplied Power control macros, in the
   the board_peripheral_reset.

   This abstacts the polarity from the code. Therefore changes
   in signal sense can be made, just in the board config.
2017-08-12 08:02:41 +02:00
David Sidrane 5506588a31 px4fmu-v5:Add conditional support for Test RC00 HW
RC00 had an active high VDD_5V_PERIPH_EN
   PC01 has an active low  VDD_5V_PERIPH_EN

   RC00 Test hardware did not use an LTC4417

   While RC00 HW is still in circulation you can build with
   PX4_FMUV5_RC00 defined and BOARD_HAS_LTC4417 undefined.

   The default is PX4_FMUV5_RC01 and BOARD_HAS_LTC4417 defined.
2017-08-12 08:02:41 +02:00
Nicolas de Palezieux 55a2930cdb vmount: reduce stack size to 1900 as recommended by @bkueng (maximum used memory observed: 1552) 2017-08-11 14:37:48 +02:00
Nicolas de Palezieux b702daf40e vmount: virtual destructor 2017-08-11 14:37:48 +02:00
Nicolas de Palezieux c3faf587cc vmount: make the parameter descriptions a little nicer 2017-08-11 14:37:48 +02:00
Nicolas de Palezieux 281ee5e5af vmount: increase stack size 2017-08-11 14:37:48 +02:00
Nicolas de Palezieux b8d389ca4e vmount: properly unadvertise uorb topics when stopping or re-configuring vmount. Othwerise subsequent advertise calls may fail (only ever witnessed for _mount_orientation_pub) 2017-08-11 14:37:48 +02:00
Nicolas de Palezieux cbe3627b8c vmount: set more sensible default parameters for the mount system and component IDs 2017-08-11 14:37:48 +02:00
Nicolas de Palezieux 89aeea7e8e vmount: publish mount angle commands in proper order and units 2017-08-11 14:37:48 +02:00
Beat Küng 4eb0ffc554 vmount: update control_data if already_active is true
control_data needs to be able to be set to nullptr in case if the input
is already active. Otherwise the output will think there's always new
requests and reset it's state.
2017-08-11 14:37:48 +02:00
Beat Küng 73d23742ea vmount: rate-limit the update of the outputs
This avoids a busy-loop if the input is listening for vehicle commands and
the output publishes vehicle commands.
2017-08-11 14:37:48 +02:00
Beat Küng 923cdbcbfb vmount mavlink input: process commands only if the target matches our sys & comp id 2017-08-11 14:37:48 +02:00
Beat Küng fd05c09447 vmount: fix param types, use int32_t 2017-08-11 14:37:48 +02:00
Julien Lecoeur 6e35cb002f PX4IO interface protocol: Fix rounding error
Issue: This conversion test failed with gcc 7.1.1 and clang 4.0.1:
```
ERROR [tests] conversion fail: input:  -0.8188, intermediate: -8187, result:  -0.8187
conv FAILED
Command 'tests' failed, returned -1
```

Fix: explicit rounding
2017-08-10 03:09:33 -04:00
Daniel Agar 02cee07469 travis-ci add GCC7 SITL build and tests
-closes #7539
2017-08-10 03:09:33 -04:00
Daniel Agar b9c1d87876 docker_run respect PX4_DOCKER_REPO env variable 2017-08-10 03:09:33 -04:00
Daniel Agar aa9023b72e COM_RC_STICK_OV fix broken metadata 2017-08-09 22:28:05 +02:00
Daniel Agar 1cc7f47003 COM_FLTMODE* add param group 2017-08-09 22:28:05 +02:00
Daniel Agar 6ddd7ea8ab RC_MAP_FAILSAFE add missing group 2017-08-09 22:28:05 +02:00
Daniel Agar 353f637e92 move SYS_FMU_TASK to px4fmu 2017-08-09 22:28:05 +02:00
Daniel Agar 928fdf34a6 sensors move THR_MDL_FAC and MOT_SLEW_MAX to px4fmu 2017-08-09 22:28:05 +02:00
Daniel Agar 95631439f1 sensors move PWM params to pwm_params.c 2017-08-09 22:28:05 +02:00
Daniel Agar 110d2968d8 sensors move RC params to rc_params.c 2017-08-09 22:28:05 +02:00
sanderux 2f1327540a DeltaQuad mixer upgrade 2017-08-09 22:28:05 +02:00
sanderux 220bd82b93 Per channel PWM disarmed values 2017-08-09 22:28:05 +02:00
Lorenz Meier 462f1346bd Add motor_test command to FMUv3 2017-08-09 22:12:25 +02:00
Daniel Agar bd7284634d land_detector add missing header and init all vtol fields (#7754) 2017-08-09 11:43:36 -04:00
sanderux 3ccf3bf2a8 Consistent capitalization 2017-08-09 10:35:44 +02:00
sanderux 2c4bbf3f44 Consistent capital use 2017-08-09 10:35:44 +02:00
sanderux e8a84b4faa Typo 2017-08-09 10:35:44 +02:00
sanderux a2ec771f78 Widen first waypoint max setting for FW 2017-08-09 10:35:44 +02:00
sanderux 75c3d92142 typo 2017-08-09 10:35:44 +02:00
sanderux 6ee24a0c80 Move land detector changes to vtol 2017-08-09 08:12:54 +02:00
sanderux 49d2e8a3ff Land detector fix for VTOL in FW mode 2017-08-09 08:12:54 +02:00
Beat Küng 72f9371ca4 micrortps_client_main: remove unnecessary sleep(1);
... and some strange reformatting due to astyle...
2017-08-08 21:47:17 +02:00
Beat Küng 77785c01ef micrortps_client.cpp.template: avoid 0-init & check result of orb_copy 2017-08-08 21:47:17 +02:00
Beat Küng de8e0b54b6 micrortps_client_main: use new module documentation & check param range 2017-08-08 21:47:17 +02:00
Beat Küng e7d19f0a1a micrortps_client_main: add status command 2017-08-08 21:47:17 +02:00
Beat Küng 55f65b4aff Tools/message_id.py: rename to uorb_rtps_message_ids.py for clarity 2017-08-08 21:47:17 +02:00
José Roberto de Souza 925efe990d Initialize all outgoing vehicle_command_ack_s and vehicle_command_s
This will initialize those structs with zero in all fields not set
and all fields set will only be change once to the final value not
wasting CPU time zeroing it.

This will guarantee that no non-unitialized structs will have
a trash value on from_external causing it to be sent to the
MAVLink channel without need it.
2017-08-08 21:46:30 +02:00
José Roberto de Souza 7c268f4fa1 mavlink: Safely avoid send the same vehicle_command and vehicle_command_ack back
The previous approach was checking system id and component id but it
will not work in 100% of cases as external devices can send MAVLink
message with the right system id but with broadcast component id.
2017-08-08 21:46:30 +02:00
José Roberto de Souza 89a428fbfe commander: Keep vehicle_command_ack_s local
No need to keep this struct as global or alive while looping.
2017-08-08 21:46:30 +02:00
José Roberto de Souza 7082cc13e0 mavlink: Allow vehicle to receive a command_ack message and publish it to listeners 2017-08-08 21:46:30 +02:00
José Roberto de Souza a8cfd6f36a msg: Use the correctly data types on vehicle_command
Lets save a few bytes using the right data types.
2017-08-08 21:46:30 +02:00
David Sidrane 1af5ed9024 crazyflie: Use BOARD_NUMBER_I2C_BUSES and BOARD_I2C_BUS_CLOCK_INIT 2017-08-08 21:45:01 +02:00
David Sidrane 8c1f506944 tapv1:Use BOARD_NUMBER_I2C_BUSES and BOARD_I2C_BUS_CLOCK_INIT 2017-08-08 21:45:01 +02:00
David Sidrane b4f5e36fb1 px4fmu-v5:Add all I2C defines for all busses
Define BOARD_NUMBER_I2C_BUSES and BOARD_I2C_BUS_CLOCK_INIT
   for I2C1-4
2017-08-08 21:45:01 +02:00
David Sidrane 64aaec4419 i2c_nuttx:Use BOARD_NUMBER_I2C_BUSES and BOARD_I2C_BUS_CLOCK_INIT
Used the board overrideable vlaues to define the _bus_clocks
   array and initalize it.
2017-08-08 21:45:01 +02:00
David Sidrane 9644f855e3 common:Define default BOARD_NUMBER_I2C_BUSES and BOARD_I2C_BUS_CLOCK_INIT
Define the default I2C buss frequncies that are backward compatible
   with the existing code. While allowing it the defaults to be overridden
   by a board config.

   Based on the legacy STM32 code, the I2C buss numbering starts at 1.
   The bus frequency is stored in a 0 based array. If px4_i2cbus_initialize
   returns a valid device, then the _bus-1 will act as the index to the
   busses frequency.

   A board may define BOARD_NUMBER_I2C_BUSES - the number of I2C busses
   it supports* and BOARD_I2C_BUS_CLOCK_INIT to initalize the bus
   clocks for a given busses.

   BOARD_NUMBER_I2C_BUSES - the number of busses including the *highest
                            number bus. If the board has 2 I2C
                            busses I2C1 and I2C3 BOARD_NUMBER_I2C_BUSES
                            would be set to 3

   BOARD_I2C_BUS_CLOCK_INIT - Initalization for the bus frequencies
                              by bus. A call init, with a frequency
                              less then the value used for the
                              Initalization will result in the device
                              not starting becuase the buss runs too
                              fast for it.
2017-08-08 21:45:01 +02:00
David Sidrane 9a21969189 px4_micro_hal:Define PX4_NUMBER_I2C_BUSES based on the arch/chip
PX4_NUMBER_I2C_BUSES number of busses that the HW can support
  not all of them my be usesd. I.E. The STM32F427 has 3 I2C
  busses but only I2C1 and I2C3 are used.
2017-08-08 21:45:01 +02:00
Beat Küng 98396a0bc5 frsky_telemetry: cleanup static vars, use less memory & fix process priority 2017-08-08 14:47:01 +02:00
Beat Küng cb23817317 frsky_telemetry: send flight mode & gps info
This uses the TEMP1 & TEMP2 fields, which probably were used for something
else initially. However this implementation matches with OpenTX and APM.
2017-08-08 14:47:01 +02:00
Beat Küng a2bfcb94ef frsky_telemetry D protocol: refactor to use less memory & allocations
Also add the vehicle_gps_position & flight mode information
2017-08-08 14:47:01 +02:00
Beat Küng 9dea515eaa frsky_telemetry S.Port: refactor to use less memory & allocations 2017-08-08 14:47:01 +02:00
Beat Küng cf8b6a9de1 frsky_telemetry: use new module documentation 2017-08-08 14:47:01 +02:00
Beat Küng 4e5c6fc805 frsky_telemetry: fix heading for D protocol 2017-08-08 14:47:01 +02:00
Beat Küng 1d40336723 airframes parser: add dodecarotor image 2017-08-08 11:59:00 +02:00
Peter Duerr 453937a89a Fix va_arg calls (always call va_end)
From the manpage: "Each invocation of va_start() must be matched by a
corresponding invocation of va_end() in the same function."
2017-08-07 22:05:54 +02:00
Peter Duerr b845edba64 Yet another erroneous call to px4_close instead of close
* As indicated by @bkueng
2017-08-07 22:05:17 +02:00
Peter Duerr 6e808ad0a6 Fix additional erroneous px4_close call
* As indicated by @bkueng
2017-08-07 22:05:17 +02:00
Peter Duerr 73ef772537 Fix erroneous use of px4_close
* Close handle opened with `open` with `close` as indicated by @bkueng
2017-08-07 22:05:17 +02:00
Peter Duerr 40dff737c5 Fix uninitialized values identified by cppcheck
* Replace `malloc` by `calloc` for c-string initialization
* Add initializer braces for structs
2017-08-07 22:05:17 +02:00
Peter Duerr 7cf2a49948 Cosmetic fix (silencing cppcheck)
* For some reason cppcheck complains with `fp != nullptr` but accepts truthiness
  of handle by itself.
* Note that the expressions are equivalent according to the C++ standard ("A
  prvalue of arithmetic, unscoped enumeration, pointer, or pointer to member
  type can be converted to a prvalue of type bool. A zero value, null pointer
  value, or null member pointer value is converted to false; any other value is
  converted to true. A prvalue of type std::nullptr_t can be converted to a
  prvalue of type bool; the resulting value is false.")
2017-08-07 22:05:17 +02:00
Peter Duerr cc1b766824 Fix memory leaks identified by cppcheck
* Add `free` / `delete`
* Add comment explaining the (presumed) motivation for the use of new instead of
  allocating on the stack
2017-08-07 22:05:17 +02:00
Peter Duerr 5be23060e7 Fix resource leaks identified by cppcheck
* Where possible rearrange error checks to avoid branching
* Otherwise add missing `fclose`, `close`, `px4_close` calls before return
2017-08-07 22:05:17 +02:00
Vicente Monge 0a61e9b279 micro RTPS CMakeLists.txt identation 2017-08-07 12:00:35 +02:00
Vicente Monge a93174dee4 Fix for manual/automatic micro RTPS bridge generation 2017-08-07 12:00:35 +02:00
Beat Küng 4ee9cb2e2f px4airframes markdown: always use '/' for path separation
Because it's an URL and os.path.join() will use '\' on windows.
2017-08-07 11:12:51 +02:00
Vicente Monge d1e39ed9e0 Added link to documentation and suppress local doc 2017-08-07 09:46:56 +02:00
Lorenz Meier 490f40bee1 Sensors: Use temperature for airspeed validation to avoid false positives for high-performance airspeed sensors
This is required to enable new high-performance sensors which otherwise would provide incorrect readings.
2017-08-06 20:52:37 +02:00
Lorenz Meier 45f2a52a7d Sensor startup: Simplify and fix Pixhawk 2.1
This change simplifies the sensor startup and fixes the detection of airspeed sensors on Pixhawk 2.1
2017-08-06 20:52:23 +02:00
Sander Smeets c81dd46b02 land detector VTOL inherit MC maybe_landed (#7738)
* maybe_landed state for VTOL inherited from MC
* set correct land detector for SITL
2017-08-06 10:02:56 -04:00
David Sidrane 102003c664 rc.sensors:Use HW type to refine startup / deprecate mpu9250 on PixhawkMini
Using the hwvercmp on FMUv2 HW derivatives built with px4fmu_v3_default
   to ues a more targeted startup approach:

  1) Detect V3 and V2M

  2) On V3 use the external mpu9250 to further discriminate between 2.0
     and 2.1. Then only start the devices that are on that version of
     the board.

 3) Due to HW errata on PixhawkMini deprecate mpu9250.
     The mpu9250 will not start reliably on the PixhawkMini
     Since we have an ICM20608 and an External Mag the
     mpu9250 is not to be used.
2017-08-05 19:26:20 +02:00
David Sidrane ed74530da8 mpu9250:More cleanup 2017-08-05 19:26:20 +02:00
David Sidrane 5bb084408d bmi160_main:Make the internal interface conditional on PX4_SPIDEV_BMI
px4fmuv2 had PX4_SPIDEV_BMI defined, for the v3 cmake, but never
   provided a Chip select decoded by PX4_SPIDEV_BMI. PX4_SPIDEV_BMI
   has been removed from V2, but PX4_SPIDEV_EXT_BMI still remains
   and has a chip select assigned to it.
2017-08-05 19:26:20 +02:00
David Sidrane 43843b753d px4fmu-v2, px4fmu-v3:Restruture SPI Selects and DRDY
The removes the alias so it is clear what bus and port bit
    is associated with as CS or DRDY signal.

    This becomes important when varients of V2 a) use the CS on differnt
    busses or b) swap a RDY (in) for a CS (out). In both cases,
    a CS on once buss, can back feed and cause sensor reset to not be
    able to turn off the power if all the pins are not tunered
    off
2017-08-05 19:26:20 +02:00
David Sidrane d58a802eaa px4fmu-v2:Use versioning API to only change a GPIO for pixhawkmini
Pixhawk mini has reused the GPIO_SPI_CS_EXT1 signal that was associated
   with SPI4. We can not in good faith assert a CS on a bus wer are not resetting.
   So we must do this only on HW_VER_FMUV2MIN
2017-08-05 19:26:20 +02:00
David Sidrane 553c649252 px4fmu-v2:Init GPIO_VDD_3V3_SENSORS_EN off at reset
Insure a 0.0 voltage initial condition on VDD_3V3_SENSORS
  By starting the GPIO_VDD_3V3_SENSORS_EN, low and deferring
  the GPIO init of the slave selects and drdy signals until
  board_app_initialize. We get ~ 80 ms of power off time
  with 0.00 voltage applied to the sensors.
2017-08-05 19:26:20 +02:00
David Sidrane 60ce1bc5c5 px4fmu-v2:Add GPIO_VDD_USB_VALID and initalize it 2017-08-05 19:26:20 +02:00
David Sidrane 5fd8ef1055 px4fmu-v2:Insure the discharge of the pins PWM pins on rest.
On resets invoked from system (not boot) insure we establish a low
  output state (discharge the pins) on PWM pins before they become
  inputs.
2017-08-05 19:26:20 +02:00
David Sidrane 4832ad3191 ver:Add support for HW versioning
1) Add hwtypecmp command to allow rc to further enumerate PX4FMU_V2
      for sub types of 'V2' -FMUv2  'V2M' PixhawkMini, 'V30' Cube

   2) Extend hw to report to display
      HW type
      HW version
      HW revision
2017-08-05 19:26:20 +02:00
David Sidrane afb01d015e px4fmu-v2:Use simple HW versioning API to differentiate V2 variant at runtime.
There are several boards that share the px4fmu-v2 build as px4fmu-v3 build.

   It was initially envisioned, that the build would be binary compatable and
   the RC script would probe different sensors and determine at runtime the
   HW type. Unfortunately, a failed sensor, can result in mis-detection
   of the HW and result in an improper start up and not detect the HW
   failure.

   All these boards's bootloader report board type as px4fmu-v2.
   This precludes and automated selection of the correct fw if it
   had been built, by a different build i.e. px4fmu-cube etc.

   We need a way to deal with the slight differences in HW that effect
   the operations of drivers and board level functions that are different
   from the FMUv2 pinout and bus utilization.

   1) FMUv3 AKA Cube 2.0 and Cube 2.1 Bothe I2C busses are external.
      This effected the mag on GPS2 not reporting Internal and
      having the wrong rotation applied.

   2) FMUv3 does not performa a SPI buss reset correctly.
      FMUv2 provides a SPI1 buss reset. But FMUv3 is on
      SPI4. To complicate matters the CS cross bus
      boundries.

   3) PixhawkMini reused a signal that was associated with SPI4
      as a SPI1 ready signal.

   Based on hardware differnce in the use of PB4 and PB12 this code
   detects: FMUv2,  the Cube, and PixhawkMini and provides the
   simple common API for retriving the type, version and revision.

   On FmuV5 this same API will be used.
2017-08-05 19:26:20 +02:00
David Sidrane dfdb61d2a7 board_common:Add support for simple hardware versioning
Define methods to get:
    1) The sub type of the hardware as a string.
    2) The version as an integer
    3) The revision as an integer
2017-08-05 19:26:20 +02:00
David Sidrane c8bd60bef8 Mpu9250:Allow internal reset to complete, when started from VDD of 0V
Per the data sheet: Start-up time for register read/write from power-up is
   Typically 11 ms and the Maximum is 100 ms.

   It seems the power up reset is only triggered at VDD < 150 mV. So the
   symptom reported: Failure is only happening after a long power down is
   consistent with VDD not dropping below 150 mV, therefore not generating
   a POR and being ready to be written with out delay.

  This fix adds a delay of 110 ms to ensure the reset has ended with some.
  margin.
2017-08-05 19:26:20 +02:00
Lorenz Meier d10116e54a Update MAVLink version 2017-08-05 16:00:00 +02:00
José Roberto de Souza 1a3315e397 msg: Fix build in python3
We can afford a slower performance in this parsers with python2 to
keep compability with python3.
http://sebastianraschka.com/Articles/2014_python_2_3_key_diff.html#xrange
2017-08-05 11:04:44 +02:00
David Sidrane 5e0a25c9c7 nuttx-patches:Removed unused patchs 2017-08-04 11:31:50 -10:00
David Sidrane a31e626bb9 stm32f7:Backport of pinmap changes.
Juha Niskanen  committed 326ab01 2017-06-20
         STM32 F7: Set I2C4 SDA and SCL pins to open drain mode

       Titus von Boxberg  committed f3267dd 2017-07-17
         I2C4_SDA can also be on GPIO PB7

      Titus von Boxberg  committed 28eab90 2017-07-27
         No FSMC, only FMC for STM32F7
2017-08-04 11:31:50 -10:00
Beat Küng a2ef611a30 dataman: improve error reporting 2017-08-04 18:08:51 +02:00
Beat Küng 45e185f8e3 mavlink: document verbose command 2017-08-04 18:08:51 +02:00
Beat Küng 843cb05ef4 mavlink_mission: fix send_mission_count: must always use MAV_MISSION_TYPE_MISSION
Because it's only used for missions
2017-08-04 18:08:51 +02:00
Beat Küng 34e31641ab mavlink_mission: print mission_type on clear_all verbose output 2017-08-04 18:08:51 +02:00
Beat Küng 25cc64947a mavlink_mission: add check for fence & safe point on regular mission upload 2017-08-04 18:08:51 +02:00
Beat Küng b1730b67e4 mission: keep 'offboard mission updated' printf as a warning
Useful to see when a in-flight mission update happens from the log.
2017-08-04 18:08:51 +02:00
Beat Küng fde1c061ed fix mavlink_mission: mission_set_current message only applies to MISSION_TYPE_MISSION
and thus the current _mission_type does not matter.
2017-08-04 18:08:51 +02:00
Beat Küng 6d85a3c4e4 geofence: lock geofence items during a write transfers
- avoids race conditions when geofence data is updated in flight. During
  a transfer, the geofence module will not check for violations, which
  is done with the new dm_trylock method.
- there is an update counter stored in dataman, and for each write
  transaction this is increased, so that the geofence module can reload
  the data upon data change (after it's unlocked).
- single dm item updates are atomic already, so resetting the polygons
  to 0 does not need locking.
2017-08-04 18:08:51 +02:00
Beat Küng cb580c5268 navigator/mission.cpp: check result of dm_lock
and remove duplicated output, mavlink_log_critical already outputs to the
console
2017-08-04 18:08:51 +02:00
Beat Küng 3d3e6428c2 msg/geofence_update.msg: remove this topic
We'll use dataman to check for geofence data updates.
2017-08-04 18:08:51 +02:00
Beat Küng 72501df88e dataman: add dm_trylock & add lock for FENCE_POINTS items 2017-08-04 18:08:51 +02:00
Beat Küng 1942641ff6 semaphore: add px4_sem_trywait
directly mapped to the posix method sem_trywait
2017-08-04 18:08:51 +02:00
Beat Küng ed478f40fd geofence: implement circular areas 2017-08-04 18:08:51 +02:00
Beat Küng 6667b6434b mavlink_mission: replace warnx, add mission_type to verbose output 2017-08-04 18:08:51 +02:00
Beat Küng cf3b068179 mavlink: add 'verbose [on|off]' command 2017-08-04 18:08:51 +02:00
Beat Küng 371586be2c MAVLink: Add verbose command 2017-08-04 18:08:51 +02:00
Beat Küng 32491626b6 mavlink mission: set mission_type in mavlink_mission_count_t message 2017-08-04 18:08:51 +02:00
Beat Küng 401d6a1a6f navigator status: print how many polygons there are currently loaded 2017-08-04 18:08:51 +02:00
Beat Küng 4c1328483d geofence: disable altitude check if not configured
It currently cannot be configured via mavlink mission protocol.
2017-08-04 18:08:51 +02:00
Beat Küng 2981ece921 geofence: do not show an error for MAV_FRAME_GLOBAL_RELATIVE_ALT{,_INT} items
Since the altitude is not used, we can ignore this as well.
2017-08-04 18:08:51 +02:00
Beat Küng e52491c023 geofence: there is no altitude for geofence vertices, remove the TODO 2017-08-04 18:08:51 +02:00
Julian Oes 0ed29192b8 mavlink_mission: don't reset vertex_count
Since vertex_count is in a union with do_jump_current_count, we can't
always reset the current count, otherwise the vertex_count ends up being
0.
2017-08-04 18:08:51 +02:00
Beat Küng c4cdaa48e0 dataman, mission_feasibility_checker: remove unneeded uorb includes 2017-08-04 18:08:51 +02:00
Beat Küng 82716012bd geofence_update.msg: notify navigator on geofence update 2017-08-04 18:08:51 +02:00
Beat Küng 328e84117e navigator geofence: switch to new dataman data structure, support multiple polygons
This also removes the 'navigator fence <lon> <lat>' command to simplify
code (I don't think there's still use for that anymore). However the
file loading is still supported.

If goefence.txt does not exist, navigator will not clear the geofence
anymore on startup.
2017-08-04 18:08:51 +02:00
Beat Küng a987886ca3 mavlink: add fence & rally to protocol capabilities 2017-08-04 18:08:51 +02:00
Beat Küng 54d8e245c0 mavlink_mission: fix dm_read check
... and init to 0 is not needed, since already done in constructor
2017-08-04 18:08:51 +02:00
Beat Küng b9cddfb75b dataman: account for new geofence & rally point structs 2017-08-04 18:08:51 +02:00
Beat Küng b8fb8c610e mavlink_mission: implement geofence & rally point protocol
- retrieve & store the geofence & rally point data from/to dataman
- interleaved transmissions (of different types) are not possible. trying
  to do so will NACK the new transmission
- only one storage backend for polygons & rally points (not alternating
  between 2 as the mission does)
2017-08-04 18:08:51 +02:00
Beat Küng 40c696ff49 navigation.h: add dataman structs for fence & save points 2017-08-04 18:08:51 +02:00
Beat Küng 65e0d63ba6 commander: avoid duplicated publish, cleanup log output for offboard_mission update
- orb_advertise already publishes a struct, no need for orb_publish
- mavlink_log_critical goes to the console too
2017-08-04 18:08:51 +02:00
Beat Küng 7206bf86dc navigator mission: fix printf log levels 2017-08-04 18:08:51 +02:00
Beat Küng 52ca49c682 geofence: remove fence & fence_vertex messages
- this was never read
- it was implemented wrong, leading to memory access violations in
  publishFence (an integer was passed instead of the fence_s struct)
2017-08-04 18:08:51 +02:00
Lorenz Meier b82975f73d UAV CAN ESC: Use new task header 2017-08-02 21:18:35 +02:00
Lorenz Meier 36b5795625 UAV CAN node main: Use new task header 2017-08-02 21:18:35 +02:00
Lorenz Meier 22d4178ebc UAVCAN: Use new task header 2017-08-02 21:18:35 +02:00
Lorenz Meier d3aaee65c0 Iridium: Use new task header 2017-08-02 21:18:35 +02:00
Lorenz Meier 144a030676 IO: Use default scheduling priorities 2017-08-02 21:18:35 +02:00
Lorenz Meier a2b23bf23a FMU: Use default scheduling priorities 2017-08-02 21:18:35 +02:00
Lorenz Meier 482a98facb MC pos control: Use default scheduling priorities 2017-08-02 21:18:35 +02:00
Lorenz Meier 727bb4886d Fixed wing: Use default scheduling priorities 2017-08-02 21:18:35 +02:00
Lorenz Meier 08e49806c8 Logger: use default scheduling priorities 2017-08-02 21:18:35 +02:00
Lorenz Meier 60c96d9dd6 Navigator: Use default scheduling priorities 2017-08-02 21:18:35 +02:00
Lorenz Meier 017a29cba1 Sensors hub: Use default scheduling priorities 2017-08-02 21:18:35 +02:00
Lorenz Meier b07dde78e3 Move scheduling priorities into px4_tasks to simplify header usage 2017-08-02 21:18:35 +02:00
Lorenz Meier b26c771ea6 MC attitude controller: Use default scheduling order 2017-08-02 21:18:35 +02:00
Lorenz Meier 5f12259dfd FW att controller: Use attitude controller scheduling order 2017-08-02 21:18:35 +02:00
Lorenz Meier cae4694d6a EKF: Use estimator scheduling order 2017-08-02 21:18:35 +02:00
Lorenz Meier 49198af6c7 FMU driver: Use default actuator output scheduling order 2017-08-02 21:18:35 +02:00
Lorenz Meier 494f7e4efb Properly document scheduling priorities 2017-08-02 21:18:35 +02:00
Lorenz Meier 501cec2469 Scheduling priorities: Formatting and sorting according to current system usage
this reflects what the system is currently using.
2017-08-02 21:18:35 +02:00
Lorenz Meier 3ca474f045 Ground rover: Use standard scheduling setup 2017-08-02 21:18:35 +02:00
Lorenz Meier d8cc38728d Multicopter attitude controller: Run at maximum priority.
This allows for a quicker update from sensors if the estimator runs at the default priority of the estimator class. If there is no direct sensor pass-through then it will wait for an estimator update.
2017-08-02 21:18:35 +02:00
Lorenz Meier 8dd96e960d Fixed wing attitude controller: Run at maximum priority.
This ensures attitude control runs first before any other system component.
2017-08-02 21:18:35 +02:00
Lorenz Meier c94e54bbab Commander: Handle HITL state in all places consistently 2017-08-02 15:12:25 +02:00
Lorenz Meier 9d49690f17 GPS simulation: Manage delays correctly
The GPS simulation now mimicks the real driver more closely and should provide even GPS delays. The delays themselves are set by the simulator, and default to 120 ms for Gazebo
2017-08-02 13:06:59 +02:00
José Roberto de Souza 7d46858ae4 aerofc: Use the additional I2C
This change plus the new FPGA RTL(version 0xC1 or higher) will make
use of the new I2C bus, this new bus will be shared between aerofc_adc
and ll40ls(if connected) and leaving the old bus just to IST8310.
2017-08-02 11:49:10 +02:00
José Roberto de Souza 66e77c49ae ll40ls: Refactor interface(PWM and I2C) selection and allow probe in more I2C buses 2017-08-02 11:49:10 +02:00
José Roberto de Souza fb3d60850e aerofc_adc: Add support to use others I2C besides PX4_I2C_BUS_EXPANSION 2017-08-02 11:49:10 +02:00
José Roberto de Souza 18626661b6 aerofc: Enable I2C bus 2
Now that UART3 is no longer in use we can use this I2C bus.
2017-08-02 11:49:10 +02:00
José Roberto de Souza 79b84a08f5 nuttx-configs: aerofc: Remove GPIO_I2C*_S**_GPIO
Nothing use this define right now so lets remove it.
Several other boards also have this defines that can also
be removed.
2017-08-02 11:49:10 +02:00
José Roberto de Souza ce180af4ca aerofc: Move GPS to UART7
The UART3 also have the I2C bus 2 functions so moving GPS to UART7 to
have one additional I2C.
To keep GPS working is also necessary update the FPGA RTL to version
0xC1 or higher.
2017-08-02 11:49:10 +02:00
Julien Lecoeur 2c0539ae9c Move selected power source to inst 0 only if nb bricks > 1
When trying to move the selected power source to the first publication instance
on systems where there is only one power source, the compiler issued the warning
```
../src/modules/sensors/sensors.cpp:512:54: error: array subscript is outside array bounds [-Werror=array-bounds]
         tmp_h = _battery_pub[_battery_pub_intance0ndx];
```
because it could not verify that _battery_pub_intance0ndx would always be 0.

Wrap the block between `#if BOARD_NUMBER_BRICKS > 1 [...] #endif`
to ensure no out of bound subscript and to remove the warning.

Remove unused _battery_pub_intance0ndx variable when nb bricks = 1
2017-08-01 12:59:40 -10:00
Daniel Agar 9fb5c4f0e9 navigator land abort use reposition (#7574) 2017-08-01 18:59:12 -04:00
David Sidrane 6bd4e84636 BACKPORT:stm32_serial consolidate patches.
This patch brings stm32_serial eqivilent to upstream Nuttx
   without the IRQ changes.
2017-08-02 00:45:13 +02:00
David Sidrane 9867ce455d Backport of upstream NuttX MTD FLASH driver: Flash corruption fix
0a85a41 MTD FLASH driver: Clone Sebastien Lorquet's m25px change to at25, is25xp, ramtron, and sst25xx.

 Clone Sebastien Lorquet's m25px change to at25, is25xp, ramtron, and sst25xx.
2017-08-02 00:45:13 +02:00
Vicente Monge e7b7b27ef8 Adding src/lib/micro-CDR to files_to_check_code_style.sh 2017-08-01 22:32:43 +02:00
Vicente Monge bcf9930e32 Updating micro CDR submodule 2017-08-01 22:32:43 +02:00
Vicente Monge 7ffdde8938 Back to eProsima micro CDR repo 2017-08-01 22:32:43 +02:00
Vicente Monge c5e2745a19 Fixes for manual bridge generation
Fix for some forgot .cxx extensions
Fix for 'print' python 2 3 compatibility
Fix for topic ID type change
2017-08-01 22:32:43 +02:00
Mark Charlebois c05ea542d9 Added requested information about generate_microRTPS_bridge.py
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois 131496ce79 Reverted change to stack size for mavlink module
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois e933d4667f Fixed code format
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois 0f758fc50a Fixed copyright on microRTPS_client_dummy.cpp
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois be090c0109 Fix GENERATE_RTPS_BRIDGE logic
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois f3e2648747 Use dummy bridge stub if fastrtpsgen not found
If the build config specifies RTPS topics to import/export and fastrtpsgen is not installed
on the build machine, then a dummy stub is used for the RTPS bridge.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois d24503242e Extracted non-template code from template
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois b31006dd78 Converted os.system calls to python methods
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois 2ed2403d04 Improved comment language
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois 049c769293 Converted cxx to cpp
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois b313bfdaa9 Only run fastrtpsgen if needed
If no RTPS import or export messages defined, then don't call fastrtpsgen

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois fc3d49240e Added missing "%"
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Daniel Agar 1e3fa64eff microRTPS_client printf PRIu64 2017-08-01 22:32:43 +02:00
Mark Charlebois 187cbbcfe6 Updated src/lib/micro-CDR
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois 02e9063089 Remove src/lib/micro-CDR
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Mark Charlebois 5feaa92bf7 Fixed eagle_default build
Was missing topics to send and receive vis RTPS

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Daniel Agar 30f8e5751d Makefile simplify colorecho for CI 2017-08-01 22:32:43 +02:00
Daniel Agar 3eea8eb301 circleci follow latest OSX documentation 2017-08-01 22:32:43 +02:00
Daniel Agar bfc9ed107e circleci install cmake 2017-08-01 22:32:43 +02:00
Daniel Agar 81d596c15f circleci xcode 8.2 -> 8.3.3 (macOS 10.12 Sierra) 2017-08-01 22:32:43 +02:00
Mark Charlebois fd86ab7f69 Fixed clock_gettime to be portable to OSX
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Daniel Agar 319c1d2046 microRTPS_transport.cxx fix code style 2017-08-01 22:32:43 +02:00
Daniel Agar 17727b5a82 clang-tidy ignore clang-analyzer-unix.API 2017-08-01 22:32:43 +02:00
Daniel Agar 5b1e3b3257 microRTPS readability braces 2017-08-01 22:32:43 +02:00
Daniel Agar 2151890e50 urtps microRTPS_transport.h code style 2017-08-01 22:32:43 +02:00
Daniel Agar 62fc3fb5ab microRTPS_transport use uint8_t for topic_ID 2017-08-01 22:32:43 +02:00
Daniel Agar e6633da832 microRTPS_client printf format fix 2017-08-01 22:32:43 +02:00
Daniel Agar b79e682630 circleci brew install fastrtps 2017-08-01 22:32:43 +02:00
Daniel Agar 1fcca041f3 docker_run.sh update px4-dev-snapdragon to FastRTPS 2017-07-28 tag 2017-08-01 22:32:43 +02:00
Daniel Agar 95a496d121 docker_run.sh update to FastRTPS 2017-07-27 tag 2017-08-01 22:32:43 +02:00
Mark Charlebois b19dc0650e Fixed format issues and missing micro-CDR in a config file
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-08-01 22:32:43 +02:00
Vicente Monge 2b86dd1fdb Added RTPS/ROS2 maintainer 2017-08-01 22:32:43 +02:00
Vicente Monge c85039e413 Fixing rebase conflicts 2017-08-01 22:32:43 +02:00
Lorenz Meier d69c53827f HRT sim: Remove outputs that smash simulator stack 2017-08-01 20:25:38 +02:00
Lorenz Meier 587f4d8f33 jMAVSIm: Explicitely configure to 500 Hz 2017-08-01 19:50:35 +02:00
Lorenz Meier 879356c25b SITL gazebo plugin: Harden dynamics of delta quad 2017-08-01 19:50:35 +02:00
Lorenz Meier d1973a6c7f jMAVSim: Update submodule to use new timestamp API 2017-08-01 19:50:35 +02:00
Lorenz Meier 1c0dd8ba49 Simulator: Add scaling API to adjust for slow simulators
The simulation engine had the ability to pause already and properly handled load spikes, however, it was not hardened against constant drift. This addition enables it to run at a constant slower-than-realtime rate successfully.
2017-08-01 19:50:35 +02:00
Lorenz Meier cf7d4fc1a7 GPS sim: Adjust delay closer to what real u-blox devices do 2017-08-01 19:50:35 +02:00
Lorenz Meier afb40a761d Simulator: Compensate scale error, not just message drops. This makes the whole simulation a lot more stable 2017-08-01 19:50:35 +02:00
Lorenz Meier 94684899a5 Gazebo: Fix usage of timestamps 2017-08-01 19:50:35 +02:00
Lorenz Meier 292dce04aa Gazebo client: Reduce priority to avoid affecting other processes 2017-08-01 19:50:35 +02:00
Dennis Mannhart a95f02b4a1 land-detector description fix 2017-08-01 19:31:34 +02:00
Dennis Mannhart f26972704e style fix 2017-08-01 19:31:34 +02:00
Dennis Mannhart e6f7af2dcf landdetector + mc_pos_control cherry-pick fix 2017-08-01 19:31:34 +02:00
Dennis Mannhart 69ecfef8a4 landdetector: consider 8 second maybe_landed case only if no rotation present 2017-08-01 19:31:34 +02:00
Dennis Mannhart ec04577e3a mc_pos_control: consider landing if not auto takeoff and valid 2017-08-01 19:31:34 +02:00
Dennis Mannhart 4692ccf287 mc_pos_control: ignore maybe_landed and ground_contact for takeoff setpoint 2017-08-01 19:31:34 +02:00
Dennis Mannhart 03d86054a4 landdetector: decrease land detection to 0.3 2017-08-01 19:31:34 +02:00
Dennis Mannhart 10c41e2624 land xy max: set it back to 1.5 2017-08-01 19:31:34 +02:00
Dennis Mannhart 50ef2d0e52 landdetector: adjust time to 3 stage detection 2017-08-01 19:31:34 +02:00
Dennis Mannhart 9baf41bef1 landdetector: check horizontal movement as criteria to enter ground contact 2017-08-01 19:31:34 +02:00
Dennis Mannhart bc46f13d90 landdetector: use control mode, add minimum speed to detect hit-ground 2017-08-01 19:31:34 +02:00
Dennis Mannhart 549d8da6ee landdetector: hit ground logic 2017-08-01 19:31:34 +02:00
Dennis Mannhart 363ed43d38 mc_pos_control: remove additional land-ground contact logic 2017-08-01 19:31:34 +02:00
Dennis Mannhart 2405abd859 mc landdetector description 2017-08-01 19:31:34 +02:00
Dennis Mannhart 4e204e00cb landdetector: maybe_landed for rover 2017-08-01 19:31:34 +02:00
Dennis Mannhart 8f7ebc1f3a mc landdetector: simplify return 2017-08-01 19:31:34 +02:00
Dennis Mannhart 8a76bd07d0 mc_pos_control: change if to else if 2017-08-01 19:31:34 +02:00
Dennis Mannhart f75dd37326 landdetector: delete or for ground_contact detection 2017-08-01 19:31:34 +02:00
Dennis Mannhart 2890af7305 mc_pos_control: set thrust to zero once maybe_landed is reached 2017-08-01 19:31:34 +02:00
Dennis Mannhart 411ceaa6b3 multicopter landdetector: delete PX4_INFO 2017-08-01 19:31:34 +02:00
Dennis Mannhart 97b5cc77b8 landdetector: reduce maybe_landed trigger time to 1s 2017-08-01 19:31:34 +02:00
Dennis Mannhart f8e9f380d0 landdetector: add additional landdetection state 2017-08-01 19:31:34 +02:00
Lorenz Meier 529def11e8 CMake / Clang: Increase warning level 2017-08-01 12:46:59 +02:00
Lorenz Meier ef233d29f0 VMount: use correct doube interface 2017-08-01 12:46:59 +02:00
Lorenz Meier 91c982758e GEO: Fix double promotion warning 2017-08-01 12:46:59 +02:00
Lorenz Meier 340432e2cf legacy EKF: Use correct constants 2017-08-01 12:46:59 +02:00
Lorenz Meier 576ad4b521 Sensors update: use correct constants 2017-08-01 12:46:59 +02:00
Lorenz Meier f4eaea99c5 Temp cal: Use correct constants 2017-08-01 12:46:59 +02:00
Lorenz Meier ae737d8df0 Camera trigger: use double per interface spec 2017-08-01 12:46:59 +02:00
Daniel Agar fa18c3d6e6 delete vtol_quad_x (replaced with quad_x) 2017-08-01 09:59:26 +02:00
Paul Riseborough 08059caf89 EKF: Enable compensation for static pressure positional error (#7264)
* msg: add reporting of multi rotor drag fusion

* ekf2: add reporting of multi rotor drag fusion

* ekf2: Add parameters required to tune multi-rotor wind estimation

* ekf2: Add correction for static pressure position error

* ekf2: Use correct air density for position error corrections

* ekf2: fix parameter documentation error

* ekf2: Add separate forward and reverse position error correction factors

* ekf2: Fix formatting and parameter descriptions

* ekf2: Improve comments
2017-08-01 07:29:08 +10:00
ChristophTobler 02ea10ed99 range finder: reject if min/max value 2017-07-31 17:33:02 +02:00
Beat Küng e3b61f22f2 Tools/upload_log.py: use https 2017-07-31 14:15:28 +02:00
Lorenz Meier 3c89059199 Update SITL version to fix image triggering 2017-07-31 12:26:08 +02:00
Lorenz Meier 1eb10e431f Create CODE_OF_CONDUCT.md 2017-07-30 19:18:49 +02:00
Daniel Agar 6ae2d22b9a WIP: github issue template (#7701)
* WIP: github issue template

* Update issue_template.md
2017-07-30 19:16:49 +02:00
Daniel Agar d5a890041b commander RTL failsafe should be sticky 2017-07-30 01:51:27 +02:00
Jan Liphardt 11508e080a Create 3037_parrot_disco_mod (#7621)
* Create 3037_parrot_disco_mod

Add support for the Parrot Disco airframe. Tested with both Pixhawk Mini and Pixracer, using a generic 30A ESC and a Cobra 2221/16 motor.

* Update 3037_parrot_disco_mod

fixed indentation per @Dagar

* Use new generic FW wing mixer (fw_generic_wing.main.mix)
2017-07-29 23:12:14 +02:00
Beat Küng 6e4ba1196b nuttx_px4fmu-{v1,v2}_default.cmake: disable sdlog2
Due to flash overflow
2017-07-29 23:10:47 +02:00
Beat Küng b1215a6ddd px4_shutdown_request: make sure we release the lock in every case
board_shutdown should not return, but just in case
2017-07-29 23:10:47 +02:00
Beat Küng b89deaf8e3 tap-v1/tap_pwr.c: make sure to invoke the button notification on registering the cb 2017-07-29 23:10:47 +02:00
Beat Küng c5a1d1928d px4_shutdown_unlock: check that counter is > 0 2017-07-29 23:10:47 +02:00
Beat Küng 007b6dd8d7 commander: make sure the power_button_state topic is advertised on startup
Otherwise the publication from IRQ context won't work
2017-07-29 23:10:47 +02:00
Beat Küng 8923664f30 param: seek to the beginning of the file before re-trying a failed export attempt 2017-07-29 23:10:47 +02:00
Beat Küng 9d924bea3f reboot command: add lock/unlock commands to test the shutdown lock
If needed it could be used in scripts as well.
2017-07-29 23:10:47 +02:00
Beat Küng dcb5f80180 shutdown: increase the max timeout to 5s
To make sure slow param writes will finish before we hit the timeout. I've
seen param write durations of around 2s.
2017-07-29 23:10:47 +02:00
Beat Küng 931ef189b5 param: grab the shutdown lock while writing params to the file 2017-07-29 23:10:47 +02:00
Beat Küng 898a8dcd57 shutdown: add px4_shutdown_{lock,unlock} API methods
Prevents the system from shutting down.
2017-07-29 23:10:47 +02:00
Beat Küng 2815c62acf fix power button shutdown: use an orb topic instead of a work queue call
px4_shutdown_request() was called from the power button IRQ callback, which
invoked a work queue callback. But on NuttX, the work queue uses a
semaphore, and thus it cannot be called from IRQ context.
This patch switches to publishing an uORB msg instead, which is handled in
the commander main thread.

To increase failure resistance, we could subscribe to the same topic in
another module for redundancy, in case commander runs wild.
2017-07-29 23:10:47 +02:00
Lorenz Meier 61b0a81bf9 HITL startup: Further simplification of boot logic in commander 2017-07-29 23:06:50 +02:00
Lorenz Meier 03324e0fb1 ROMFS: Remove stale HITL config 2017-07-29 23:06:50 +02:00
Lorenz Meier 5838556742 HITL handling: Enforce the use of the activation parameter for HITL configuration 2017-07-29 23:06:50 +02:00
Lorenz Meier 8aa1382e08 ROMFS: Switch HIL to a setting orthogonal to airframes
This makes it easy to flip any airframe config over to HIL.
2017-07-29 23:06:50 +02:00
Lorenz Meier 8878be5741 MC land speed: Ensure that the difference between land speed and land detection is high enough 2017-07-29 22:25:09 +02:00
Lorenz Meier 6f249472e0 FMUv5: Ensure there is enough UART buffer space - since the board has plenty of RAM, all UARTs are treated equally 2017-07-29 16:12:41 +02:00
Lorenz Meier 235a789a47 FMUv4 configs: ensure there is enough TX buffer space 2017-07-29 16:12:41 +02:00
Lorenz Meier ad21dc3f50 Pixhawk configs: Ensure there is enough TX space on high-speed UART links 2017-07-29 16:12:41 +02:00
Lorenz Meier dc4faa81de MAVLink: Only initialize where required 2017-07-29 16:12:41 +02:00
Lorenz Meier 6b17db35b0 MAVLink: Fix vibration message timestamp 2017-07-29 16:12:41 +02:00
Lorenz Meier 3f048e8a87 MAVLink stream: Do not override interval too much 2017-07-29 16:12:41 +02:00
Lorenz Meier af451ce638 MAVLink time sync: Better output handling 2017-07-29 16:12:41 +02:00
Lorenz Meier f0e8ebb2ac MAVLink: Remove link termination command
This is no longer required as we have a full shell available now and there is no reason to let the remote terminate the instance.
2017-07-29 16:12:41 +02:00
Lorenz Meier 37657cf99b MAVLink FTP: Use modern output printing to capture errors in system log 2017-07-29 16:12:41 +02:00
Lorenz Meier 68d70cc8c0 MAVLink: Use modern PX4 output format to enable system logging for errors. 2017-07-29 16:12:41 +02:00
Lorenz Meier 09f1373a08 MAVLink: Adjust stream rates to match real usage 2017-07-29 16:12:41 +02:00
Lorenz Meier 07ced9895c MAVLink: Improve message handling / tracking
The message handling was not obeying action focused messages and high-rate messages properly before. With this change update rates track the desired rates closely. Critical high-rate messages such as ADS-B are queued additionally to guarantee that all received packets are being correctly forwarded.
2017-07-29 16:12:41 +02:00
stmoon 556eb9e45a fix the bug for posix_sitl_inav 2017-07-29 11:01:21 +02:00
Daniel Agar 1867573b02 VTOL don't poll parameter_update 2017-07-29 09:15:52 +02:00
Daniel Agar 66f0912b9d FW attitude don't poll parameter_update 2017-07-29 09:15:52 +02:00
Daniel Agar efafc17b0c FW position don't poll parameter_update 2017-07-29 09:15:52 +02:00
Daniel Agar cf87096b05 EKF2 don't poll parameter_update 2017-07-29 09:15:52 +02:00
Daniel Agar ddc4500753 FW landing optionally disable heading hold (#7617) 2017-07-28 20:28:54 -04:00
Paul Riseborough 5324f30cb6 ekf2: Let the EKF know if the vehicle is operating as a fixed wing type. (#7667)
Setting this enables the EKF to use the GPS velocity to recover from bad compass yaw at launch.
2017-07-29 07:18:58 +10:00
ChristophTobler a240eeb86a update sitl gazebo to include tranformation fix 2017-07-28 17:23:22 +02:00
ChristophTobler 44cd65798b update sitl_gazebo to use the vision position estimate 2017-07-28 09:09:56 +02:00
Lorenz Meier dc8caeaedf MAVLink: Default to standard stream config 2017-07-27 10:15:53 +02:00
sanderux 1eda66c9ba Code format 2017-07-27 10:15:53 +02:00
sanderux 7612b94c72 Allow relaying from same system ID or with target component 0 2017-07-27 10:15:53 +02:00
Lorenz Meier 9124617315 MAVLink: Always enable forwarding for companion link 2017-07-27 10:15:53 +02:00
Lorenz Meier c44322ca15 MAVLink app: Use more advanced forwarding logic 2017-07-27 10:15:53 +02:00
Lorenz Meier 98bd6e43e8 SDP3x: Add model for pitot pressure drop 2017-07-26 09:27:32 +02:00
stmoon ae1f8381ce disable uavcan build to make space for other modules 2017-07-26 07:59:50 +02:00
Lorenz Meier f746f9a9b3 UAVCAN: Reduce memory footprint 2017-07-26 07:55:31 +02:00
José Roberto de Souza 0b9e32ca3e aerofc: Reboot board when force bootloader pin is set
This can help "unbrick" AeroFC when a bad firmware is loaded
and it keeps rebooting or it spinning in some loop.

No need to request to stay in booloader as it will stay
in bootloader because the pin is set.
2017-07-26 07:14:13 +02:00
Beat Küng 0109154c43 logger: avoid logging the UUID if the system does not provide it
The linux targets don't have it and setting a fixed constant causes
wrong vehicle associationss in Flight Review.
2017-07-24 09:01:02 +02:00
Lorenz Meier 286c3d41d3 MAVLink app: Send GPS uncertainty via MAVLink 2
This is needed by some consumers like transponders.
2017-07-23 00:16:00 +02:00
Lorenz Meier d83e54cde5 MAVLink v2: Update version 2017-07-23 00:16:00 +02:00
Daniel Agar 2939bd9c96 Partial Revert "MAVLink: Add capture command to command queue"
This reverts commit dde5781142.
2017-07-22 11:36:35 +02:00
davidaroyer d5cbbba341 ocpoc_adc: handle return from fscanf 2017-07-22 10:51:49 +02:00
davidaroyer d01150990b cmake: add ubuntu build for OcPoC hardware 2017-07-22 10:51:49 +02:00
ChristophTobler bc951f6f15 add constraint to ground distance to avoid values below rng_gnd_clearance (#7662) 2017-07-22 07:49:00 +10:00
Beat Küng a6c682ce50 mavlink_ftp: fix stack overflow & add root dir prefix
- change memory allocation from stack to a malloc'd buffer. This avoids
  increasing the stack size. And since FTP is rarely used, the buffers
  are only allocated upon use and freed after a time of 2s inactivity.
- adds PX4_ROOTFSDIR as root directory prefix. This does not change
  anything on NuttX, but in SITL it will avoid enumerating the whole
  disk tree when using QGC (which enumerates all files recursively).
2017-07-21 19:59:45 +02:00
Beat Küng 29f23a390f mavlink_ftp: avoid using seekdir()
The provided argument payload->offset is in range [0, num_file_entries-1],
but seekdir might use a completely different range. It is not defined
by the API spec. It is only useful in conjunction with telldir().
2017-07-21 19:59:45 +02:00
Beat Küng 5a2723ab9c test_mixer.cpp: remove bogus comments 2017-07-21 19:59:45 +02:00
Beat Küng 42f7e6bca3 px4_defines: make sure that PX4_ROOTFSDIR is a string 2017-07-21 19:59:45 +02:00
Beat Küng ced700adf2 cmake px4fmu-v1 config: remove pwm_out_sim from build
To reduce flash space usage
2017-07-20 18:49:38 +02:00
Beat Küng 7fc20049e0 param_shmem import: don't fail on type mismatch 2017-07-20 18:49:38 +02:00
Beat Küng 88b515390a flashparams import: don't fail on type mismatch 2017-07-20 18:49:38 +02:00
Beat Küng 2340e7073d param import: don't fail on type mismatch
This can happen for example when a param type is changed from int32 to
float. The type check will then fail if the param is stored and the param
import will be aborted.
Now we just skip the entry and continue loading the rest.
2017-07-20 18:49:38 +02:00
Dennis Shtatnov ca82d36c3f Support platforms like CF2 without capture ioctl 2017-07-20 03:37:58 -10:00
Paul Riseborough f93be992ce ekf2: Update documentation for compatibility with Doxygen (#7657) 2017-07-20 22:05:29 +10:00
Lorenz Meier c1f5feac83 MAVLink: Queue transponder reports and send them at full data rate
This will ensure that no transponder reports are dropped and that all received reports are passed on to the GCS and other devices.
2017-07-20 09:13:53 +02:00
Dennis Shtatnov 6081435801 Fixes #7282 2017-07-19 19:51:55 -10:00
Dennis Shtatnov 2e85a4363e MPU9250: Separate mpu and mag resets 2017-07-19 19:51:55 -10:00
ChristophTobler 03e11c4d18 update ecl and add param for innovation consistency checks for range aid fusion (#7585) 2017-07-19 18:25:12 +10:00
Paul Riseborough 1dbac79c1b ecl: Compatibility update for PR #7602 2017-07-18 23:06:14 +02:00
Lorenz Meier dde5781142 MAVLink: Add capture command to command queue 2017-07-18 23:05:43 +02:00
Lorenz Meier cb3222d131 Navigator: Be less verbose 2017-07-18 23:05:43 +02:00
Lorenz Meier 0d30d817b8 Update SITL Gazebo to default triggering to MAVLink 2 2017-07-18 23:05:43 +02:00
Lorenz Meier 8bc0a8aece Geotagging config: Default vehicle to MAVLink 2 2017-07-18 23:05:43 +02:00
Lorenz Meier b1a987f06b Enable camera triggering and gimbal control via MAVLink 2017-07-18 23:05:43 +02:00
Lorenz Meier efba7fa7b9 Update SITL gazebo 2017-07-18 23:05:43 +02:00
Lorenz Meier 8706525d70 Update MAVLink rev 1 2017-07-18 23:05:43 +02:00
Lorenz Meier 6e97aec8ce MAVLink app: Do not warn about required reboot but rely on param meta. Fixes #7642 2017-07-18 22:51:42 +02:00
Beat Küng 0668d61665 SYS_FMU_TASK: add param to start fmu as task (default=work queue) 2017-07-18 20:06:10 +02:00
Beat Küng 07b7a153f3 fmu: add ifdef for dsm_deinit() 2017-07-18 20:06:10 +02:00
Beat Küng 2193afd0a0 fix fmu: lower polling timeout to 5ms when running as task
With the previous value of 20ms, we dropped RC input when not armed. The
result was that some RC channels jumped randomly between min & max.
2017-07-18 20:06:10 +02:00
Beat Küng e6adfa6b6b fix fmu: call dsm_deinit() in destructor
This closes the fd and cleans up a static variable used in the dsm parser.
2017-07-18 20:06:10 +02:00
Beat Küng 1130bc129c fix fmu: make sure init() is called on the new task
This was only a problem when running as a task not on the work queue.
The problem was that init() opened the RC serial device, which was then
read in the main loop, which is a different context when run as a task.
2017-07-18 20:06:10 +02:00
Beat Küng 56cc5e11cc simulator: initialize sensor data buffers 2017-07-18 12:54:28 +02:00
Beat Küng bb3b11e87a battery.cpp: initialize _current_filtered_a 2017-07-18 12:54:28 +02:00
Beat Küng bcca17204b mc_pos_control_main: initialize _in_takeoff 2017-07-18 12:54:28 +02:00
Beat Küng d419537a72 ekf2_main: initialize _mag_time_sum_ms & _balt_time_sum_ms 2017-07-18 12:54:28 +02:00
David Sidrane 9635ec42e9 system_power:Add blank line per review 2017-07-17 21:02:50 -10:00
David Sidrane 5ebe5010ac Bugfix:Sensors battery_status Intance 0 voltage was 0V for Brick 2
Both PX4Test and Beat noted if only Brick to was connected
  battery_status Intance 0 voltage was 0V for Brick2

  The priority selection logic is run prior to the subscription
  creation and only updated the priority on a change. Before the
  subscriotions were created.

  _battery_pub_intance0ndx is suposed track the location in
  the _battery_pub array that is instance 0. It is then used
  to associate (move) instance 0 with (to)  the lowest brick
  (highest priority in HW) brick that is selected in HW.

  The Bug was that before the subscriptions are created,
  _battery_pub_intance0ndx set to 1. And then and never updated.

  The fix was to only run the priority selection logic once
  the subscriptions are created.
2017-07-17 21:02:50 -10:00
David Sidrane fc38bc4144 px4fmu-v5:Added Muti Brick support definitions
BOARD_HAS_LTC44XX_VALIDS - 0 -> No LTC44xx IC, N is the number of
                              Power Bricks connected to the LTC44xx
                              For a LTC4417 this would be 2 as the
                              third prioriy is used for USB

   BOARD_HAS_USB_VALID     - If defied as 1 imples that infact
                             the USB has a priority connection
                             on the LTC44XX

   BOARD_HAS_NBAT_V       - the number of battery voltage sensing chennels
                            on the ADC

   BOARD_HAS_NBAT_I      - the number of battery current  sensing chennels
                            on the ADC

   A super simple (non FMUv5 compliant) board with no LTC44xx and just one battery
   that have no current sense:

    BOARD_HAS_LTC44XX_VALIDS = 0
    BOARD_HAS_USB_VALID      = 0
    BOARD_HAS_NBAT_V         = 1
    BOARD_HAS_NBAT_0         = 0

   A fully FMUv5 compliant design would use:

    BOARD_HAS_LTC44XX_VALIDS = 2
    BOARD_HAS_USB_VALID      = 1
    BOARD_HAS_NBAT_V         = 2
    BOARD_HAS_NBAT_0         = 2

   These setting properly condition the ADC channles and all the Power
   module valid sensing logic in the ADC module.
2017-07-17 21:02:50 -10:00
David Sidrane 53a04f3ba7 px4fmu-v5:board_config clean up
Removed unused headers and placed the __BEGIN_DECLS where it belonged
2017-07-17 21:02:50 -10:00
David Sidrane f13682223a Added FMUv5 System Power related system_power.msg fields
voltage3V3_v - the sensor 3.3V voltage rail
   v3v3_valid   - the value of voltage3V3_v  may be 0. This
                  field is a 1 when the HW provides voltage3V3_v

   brick_valid - is now a bit mask. A 1 in the postion inticate the
                 Power controler HW has a valid supply voltage
                 present (in V window) on that priority
                 (channel V1..Vn).
                 The mapping is formed by 1<<battery_status.msg.priority
                 or using the manifest constanst BRICKn_VALID_MASK

   usb_vaild - is now indicated from the Power controler HW or
               the usb_connected if Power controler is
               not present.

   brick_valid == 0 and usb_vaild = 1 implies the FMU is powered
   from USB only

   brick_valid != 0  and usb_vaild = 1 implies the FMU is powered
   from the higest priority brick, providing a 1 bit in brick_valid
   and from USB
2017-07-17 21:02:50 -10:00
David Sidrane 4b63d629a9 sensors:Added Backward compatible N Brick Support FMUV4pro & FMUv5
This change implements the publishing of batery_status messages
   for each brick on the system, using multi-pub.

   Backward compatiblity is achived by always publishing the
   batery_status of the bick that has been selected by the HW
   Power Controller (PC) on instance 0.

   The batery_status.system_source will be true in one and
   only one batery_status publication when a valid bit is
   set in system_power.brick_valid. However, if USB is connected,
   and both brikcs are not providing voltages to the PC
   that are in the Under/Over Voltage Window (set in HW)
   the system_source may be false in all publications.
2017-07-17 21:02:50 -10:00
David Sidrane 910948cd7e board_common:Define defaults for Power Bricks and Sensor rail volatage
FMUv4Pro and FMUv5 Spec added multi brick support
   FMUv5 added SCALED_VDD_3V3_SENSORS

   This change provides legacy (FMUv2) defaults for Power Bricks and
   Sensor rail volatage source.
2017-07-17 21:02:50 -10:00
David Sidrane 8e8510f398 Added Power Brick related battery_status.msg fields
system_source - This battery status is for the brick that is
                   supplying VDD_5V_IN
   priority      - Zero based, This battery status is for the brick
                   that is connected to the Power controller's
                   N-1 priority input. V1..VN. 0 would normally be
                   Brick1, 1 for Brick2 etc

  Battery now assigns connected from the api in the
  updateBatteryStatus, as well as system_source and priority
2017-07-17 21:02:50 -10:00
David Sidrane 579b55f2cb px4fmu-v5:There will be variants that will [not]have the PX4IO.
The PX4IO is an population option on some varients. To have
   1) FMU only control
   2) IO Only control
   3) FMU fall back control

   These pins need to come up as inputs, until the configuration
   is determined.
2017-07-17 21:02:50 -10:00
David Sidrane f7e3f34f48 px4fmu-v5:Insure the VBUS signal is low if USB is not connected.
Dispite what the ref manaul says. Some HW needs the added pull
   down to insure the pin reads low when not plugged in to USB.
2017-07-17 21:02:50 -10:00
David Sidrane 15f9f6c06f px4fmu-v5:formatting 2017-07-17 21:02:50 -10:00
David Sidrane ddddedf410 px4fmu-v5:Define Tone Alarm in terms of the FMUv5 Spec 2017-07-17 21:02:50 -10:00
David Sidrane 90fd7734bb px4fmu-v5:Define UI LEDs per the FMUv5 Spec 2017-07-17 21:02:50 -10:00
David Sidrane a254b0dca5 px4fmu-v5:Define the FMU_CAP[1:3] per FMUv5 Spec 2017-07-17 21:02:50 -10:00
David Sidrane 14ce28b1f3 px4fmu-v5:GPIO Clean up per FMUv5 Spec.
Added comments to ADC defines with Pin numbers.
  Added the GPIO_HW_{REV:VER}_DRIVE signals
  Define the GPIO_nPOWER_IN_{A:C] and assign them to
  BRICK1, BRICK2 and USB Valid.
  Regroupped power signals and defined true logic Power Control macros
  in the arch agnostic form.
  Defined the same IOCTL defines for FMU GPIO IOCTL
  Use the power Control macros on board_app_initialize
2017-07-17 21:02:50 -10:00
David Sidrane d33b945db6 px4fmu-v5:SPI chip selects per FMUv5 Spec 2017-07-17 21:02:50 -10:00
David Sidrane 8607b72805 px4fmu-v5:Removed unused LED alias defines. 2017-07-17 21:02:50 -10:00
David Sidrane 892ae1436c px4fmu-v4pro::Insure the discharge of the PWM pins on rest.
As done on fmuV4 on resets invoked from system (not boot) insure
  we establish a low output state (discharge the pins) on PWM pins
  before they become inputs as a result of the pending reset.

  We also delay the reset by 400 MS to insure the 3.1 Ms pulse is
  not too close to the last PWM pulse.
2017-07-17 21:02:50 -10:00
David Sidrane b23e6fc87c px4fmu-v4pro:Define GPIO xxx_VALIDs and initalize them.
The LTC4417 provides a valid signals for brick1, brick 2 and USB
  This change  configures the GIOP and provides 1) a MACRO to read
  the pin and 2) the IOCTL defines to read it from the FMU.

  The macro's result is true logic: It is true when the signal is active.
  (Active low on the the LTC4417). The IOCTL read would be the actual
  pin state.
2017-07-17 21:02:50 -10:00
David Sidrane 258faeee03 px4fmu-v4:Define GPIO GPIO_VDD_USB_VALID and initalize it.
The V4 HW replaced the LTC4417 provided valid signal for USB.
  with an active high, version. This commit configures the GIOP
  and provides 1) a MACRO to read the pin and the IOCTL defines
  to read it from the FMU. The macro result true logic: true
  when the signal is high. The IOCTL read would be the actual
  pin state.
2017-07-17 21:02:50 -10:00
David Sidrane f7cc78bffe px4fmu-v2:Define GPIO GPIO_VDD_USB_VALID and initalize it.
The LTC4417 provides a valid signal for USB. This change
   configures the GIOP and provides 1) True logic macro to
   read the pin and the IOCTL defines to read it from the FMU.
   The macro will return true when the signal is active (low
   on the LTC4417). The IOCTL will read be the actual pin state.
2017-07-17 21:02:50 -10:00
David Sidrane 30aca6677f px4fmu-v2:nuttx config fix typo GPIO_USART6_CTT->GPIO_USART6_CTS
Since Hardware flow control has not been enabled this typo
   survived.
2017-07-17 21:02:50 -10:00
David Sidrane 4188c4d0d5 px4fmu-v5:Turn On SD card 2017-07-17 21:02:50 -10:00
David Sidrane a09bc63747 px4fmu-v5:Use PX4_ERR in board init, spi init and sdio init 2017-07-17 21:02:50 -10:00
David Sidrane 2a61518c9f px4fmu-v5:Enable SPI5 in NuttX 2017-07-17 21:02:50 -10:00
David Sidrane 229c5d482f px4fmu-v5:More GPIO_VDD_3V3V_SD_CARD_EN -> GPIO_VDD_3V3_SD_CARD_EN 2017-07-17 21:02:50 -10:00
David Sidrane 46daebfb6c px4fmu-v5:Removed a SPI 5 reeady signal from board_spi_reset
board_spi_reset is used to reset the internal SPI bus.
   therefore GPIO_SPI5_DRDY7_EXTERNAL1 should not have been
   minipulated, as it is on SPI5
2017-07-17 21:02:50 -10:00
David Sidrane 59d020fba3 px4fmu-v5:Added comment block to board_spi_reset 2017-07-17 21:02:50 -10:00
David Sidrane 85b6986079 px4fmu-v5:Fix board_peripheral_reset to use correct polarity
GPIO_nVDD_5V_PERIPH_EN is Active low. board_peripheral_reset
   need to tune it OFF then ON
2017-07-17 21:02:50 -10:00
David Sidrane ebc8b47fad px4fmu-v5:Added board_on_reset api to reset PWM 2017-07-17 21:02:50 -10:00
David Sidrane 54bd0a9f2a px4fmu-v5:Using arch agnostic gpio init
Define the GPIO pin list use the board_gpio_init
2017-07-17 21:02:50 -10:00
David Sidrane 044b845c40 px4fmu-v5:Match GPIO_VDD_3V3_SD_CARD_EN and polarity to FMUv5 Pin Spec RC01
Removed extra V GPIO_VDD_3V3[V]_SD_CARD_EN and it is active High
2017-07-17 21:02:50 -10:00
David Sidrane 82dc6de19f px4fmu-v5:Define the BOARD_NUMBER_BRICKS for future enumeration
When BOARD_NUMBER_BRICKS exists it will enable multiple
   power source testing and reporting.
2017-07-17 21:02:50 -10:00
David Sidrane b9f43068af px4fmu-v5:Define the existance of the UI PWM LED and it's polarity
Per https://docs.google.com/spreadsheets/d/1-n0__BYDedQrc_2NHqBenG1DNepAgnHpSGglke-QQwY/edit#gid=730959725
  Usage of the PWM UI led is optional and if used it's polaity may
  be set ot Active low or high.
2017-07-17 21:02:50 -10:00
David Sidrane 33cd8c7093 px4fmu-v5:Fixed comment 8 PWM 2017-07-17 21:02:50 -10:00
David Sidrane e20d685f40 px4fmu-v5:Add Timer and Channel to comment for HEATER 2017-07-17 21:02:50 -10:00
David Sidrane c1eac11823 px4fmu-v5:Match signals names to FMUv5 Pin Spec RC01 2017-07-17 21:02:50 -10:00
David Sidrane 5669434585 px4fmu-v5:Define ADC GPIO and Channels clearly
Moving forward we want all the board configs to drive the
   configuration. This is just cleanup to give a clear
   example of how ADC should be defined by a simple list,
   based on ADC pin number as related to the GPIO and
   channel number. Then the xxx_CHANNEL bit are
   used to form the ADC_CHANNELS (mask). The GPIO
   will are used to for a list for initalization.
2017-07-17 21:02:50 -10:00
David Sidrane 5ba02d740c px4fmu-v5:Group SPI signals by bus 2017-07-17 21:02:50 -10:00
David Sidrane 88c1521b5e px4fmu-v5:Status LED's are driven open drain
Allows Anaode of LEDs to be tied to V5 or V3.3
2017-07-17 21:02:50 -10:00
David Sidrane 68e5764dbc board common:Add arch agnostic gpio init 2017-07-17 21:02:50 -10:00
Simone Guscetti ada48571d7 fmu-v5: fix timer config 2017-07-17 21:02:50 -10:00
Simone Guscetti a00441ecf4 fmu-v5 timer_config: timer io channels for FMU_CH7/8 2017-07-17 21:02:50 -10:00
Simone Guscetti a4d8bf56cc fmu-v5 timer_config: set up the timers for v5 board
FMU_CH7/8 use timer 12 ch1/2
FMU_CAP use timer 2
Buzzer use timer 9
2017-07-17 21:02:50 -10:00
Simone Guscetti bc793d15cf fmu-v5 board_config: add FMU_CH7 and FMU_CH8 2017-07-17 21:02:50 -10:00
Simone Guscetti db9bef352a fmu-v5 board_config: config SPI5 sync and reset pins 2017-07-17 21:02:50 -10:00
Simone Guscetti 1e86f24cf9 fmu-v5 board_config: set up external spi 2017-07-17 21:02:50 -10:00
Simone Guscetti 74dfa8805f fmu-v5 board_config: power A is the brick voltage sensing 2017-07-17 21:02:50 -10:00
Simone Guscetti 518383ada8 fmu-v5: update board config to the newest pin assigment 2017-07-17 21:02:50 -10:00
Simone Guscetti 308295f648 fmu-v5: fix compiling errors 2017-07-17 21:02:50 -10:00
Simone Guscetti 30f9c61e67 fmu-v5: started updating board config to newest specs 2017-07-17 21:02:50 -10:00
Julien Lecoeur 71136dcedf Log_writer_file: Increase stack size
Test flights reported the warning `[load_mon] log_writer_file low on stack! (292 bytes left)`

Increase stack size from 1060  to 1072 (=8 + 1060 rounded to next multiple of 8).
2017-07-18 08:24:37 +02:00
Julien Lecoeur bc006b81fc can_boot_descriptor: python3 compatibility 2017-07-18 08:24:37 +02:00
Julien Lecoeur 87e9ad0caa Patch NuttX/nuttx and NuttX/apps for new arm-none-eabi-gcc 7.1.0 warnings
Rename nuttx patch

Add nuttx patch for unused variable error

Pending nuttx patch

Backport nuttx fix for unused variables in nsh_proccmds.c

Fix Patch format

Modify pending patch to match new nuttx PR

Move accepted nuttx changes from pending patch to backport patch
2017-07-18 08:24:37 +02:00
Julien Lecoeur 940f2c3cca Update libuavcan submodule, fix arm-none-eabi-gcc 7.1.0 warnings 2017-07-18 08:24:37 +02:00
Julien Lecoeur 61d6903b40 Fix -Werror=stringop-overflow on gcc 7
The error was:
Firmware/src/systemcmds/hardfault_log/hardfault_log.c:312:7: error: specified bound 30 equals the size of the destination [-Werror=stringop-overflow=]
       strncat(marker, sp_name, sizeof(marker));
       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2017-07-18 08:24:37 +02:00
Julien Lecoeur abcb920df4 Fix -Werror=implicit-fallthrough on arm-none-eabi-gcc 7.1.0
BMP280: fix -Werror=implicit-fallthrough on arm-none-eabi-gcc 7

gnss: fix -Werror=implicit-fallthrough on arm-none-eabi-gcc 7

fmu: fix -Werror=implicit-fallthrough on arm-none-eabi-gcc 7

timer.c: fix -Werror=implicit-fallthrough on arm-none-eabi-gcc 7

px4cannode_led: fix -Werror=implicit-fallthrough on arm-none-eabi-gcc 7

Fix -Werror=implicit-fallthrough on gcc7
2017-07-18 08:24:37 +02:00
Julien Lecoeur d477b1f0f4 Fix -Werror=stringop-overflow on gcc 7
This prevents the compiler from optimising pdump. The error was:
Firmware/src/drivers/boards/common/board_crashdump.c:41:2: error: 'memset' writing 3240 bytes into a region of size 4 overflows the destination [-Werror=stringop-overflow=]
  memset(pdump, 0, sizeof(fullcontext_s));
2017-07-18 08:24:37 +02:00
David Sidrane 4349f49610 PX4 System:Expunge the nuttx adc structure from the system
This PR is preliminary ground work for FMUv5.

   PX4 does not use the NuttX adc driver. But used the same format
   for the data returned by the nuttx ADC driver.

   There was a fixme:in src/platforms/px4_adc.h "this needs to be
   a px4_adc_msg_s type" With this PR the need for
   src/platforms/px4_adc.h goes away as the driver drv_adc.h now
   describes the px4_adc_msg_t.
2017-07-17 22:28:29 +02:00
Carl Olsson d92377a6e6 ekf2: remove unused function (#7529)
* ekf2: remove unused function

Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>

* ekf2: removed unused variable _mag_decl_saved

Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2017-07-17 17:24:23 +10:00
Beat Küng c59d7baad8 replay: add backward compatibility for updated sensor_combined topic 2017-07-16 14:08:37 +02:00
Beat Küng cef3a29ac9 refactor replay: split timestamp offset into separate method 2017-07-16 14:08:37 +02:00
Nicolae Rosia 950273dbcf msg: ekf: switch to uin32_t for deltas, should be more than enough
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-07-16 14:08:37 +02:00
Nicolae Rosia f1740bbf54 msg: ekf: fix comment, dt is in uS now
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-07-16 14:08:37 +02:00
Nicolae Rosia 0a22a9c47c change gyro & accel dt from float to uint64. This has the benefit of
calculating the estimator timeslip correctly.

Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-07-16 14:08:37 +02:00
Nicolae Rosia 5618f34f3b Remove usage of waitForUpdate/updateNotify, there are no users of this feature.
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-07-15 09:50:24 +08:00
Nicolae Rosia 67987d27d8 barosim: revamp driver
Current driver was copy pasted from a MS5611 driver.
The existing driver takes data from Simulator, not from
an actual device.

Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-07-15 09:50:24 +08:00
Beat Küng 4ccbeb47c0 land_detector_main: fix documentation: rover -> ugv 2017-07-14 11:57:11 +02:00
Beat Küng 0949599f0a dataman: fix compilation error
error: invalid conversion from ‘int’ to ‘dm_item_t’
and
error: no ‘operator++(int)’ declared for postfix ‘++’
2017-07-14 11:57:11 +02:00
Beat Küng 1c7941fc89 land_detector: fix too long lines in module documentation 2017-07-14 11:57:11 +02:00
Dennis Mannhart eb17d4b5f3 MC landdetector: update description 2017-07-14 11:57:11 +02:00
Beat Küng cf5df4489f dataman: extend module documentation 2017-07-14 11:57:11 +02:00
Beat Küng 913cbc773e px4moduledoc: extend validation: limit max line length to 120 2017-07-14 11:57:11 +02:00
Beat Küng 318c4497bd dataman: fix typo 2017-07-14 11:57:11 +02:00
Beat Küng 620d37bc1c fmu: remove tautology, fix pwm2cap2 mode for status 2017-07-14 11:57:11 +02:00
Beat Küng 8b64fc8a5e Tools/px4moduledoc: add some comments, describe the regexes 2017-07-14 11:57:11 +02:00
Beat Küng 8a83fb7dc2 land_detector: use ModuleBase & add module documentation 2017-07-14 11:57:11 +02:00
Beat Küng 8d7481f9ac load_mon: use ModuleBase & add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 5aa8b455c2 crazyflie airframe: add maintainer 2017-07-14 11:57:11 +02:00
Beat Küng 69f0288649 aerofc airframe: RTF -> Ready to Fly Drone & add maintainer 2017-07-14 11:57:11 +02:00
Beat Küng a63699060d ekf2: use ModuleBase & add module documentation 2017-07-14 11:57:11 +02:00
Beat Küng 47073e9c32 vmount: add module documentation 2017-07-14 11:57:11 +02:00
Beat Küng 28e5268497 dataman: rename to .cpp & add module documentation 2017-07-14 11:57:11 +02:00
Beat Küng 682dabded1 replay: use module base class & add module documentation 2017-07-14 11:57:11 +02:00
Beat Küng 674ae5292e markdown module doc script: write how to generate the modules documentation 2017-07-14 11:57:11 +02:00
Beat Küng 05b0c412c8 sensors: extend module doc a bit 2017-07-14 11:57:11 +02:00
Beat Küng 36c9400de4 gps: use ModuleBase class & add documentation
Note: it changes the interface slightly: instead uf -dualgps, use -e now.

This also fixes 2 bugs:
- nullptr access when doing 'gps status' with fake gps running
- close(fd) was called on an uninitialized fd when gps fake was running
2017-07-14 11:57:11 +02:00
Beat Küng 6463bd4f6f sensors: use ModuleBase & add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 5923a2e9d0 src/mainpage.dox: remove this file, it's not used anymore & completely outdated 2017-07-14 11:57:11 +02:00
Beat Küng a43f135ad4 minor documentation updates to some commands 2017-07-14 11:57:11 +02:00
Beat Küng 7d50f3df0a Makefile: add module_documentation target 2017-07-14 11:57:11 +02:00
Beat Küng 7a4f557a7a px_process_module_doc: separate page into one page per category 2017-07-14 11:57:11 +02:00
Beat Küng 05c3b711f3 fix bl_update: move definition of print_usage into the ifdef
fixes the compile error:
error: 'print_usage' defined but not used [-Werror=unused-function]
2017-07-14 11:57:11 +02:00
Beat Küng a4ca3fc607 ver: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 68d754b65e usb_connected: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 8e965a7a2a topic_listener: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 1b4467f674 sd_bench: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 06178392ce reboot: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 16e0e1f7ca perf: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng ba1a483cd6 nshterm: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 65b11d39a9 mtd: add documentation & do cleanup (remove err(), ...) 2017-07-14 11:57:11 +02:00
Beat Küng e362f760c4 motor_test: add documentation & do cleanup (remove err(), ...) 2017-07-14 11:57:11 +02:00
Beat Küng 4839ed8498 motor_ramp: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 3a880a09d6 mixer: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng b18a148129 led_control: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 50d1ed99b0 i2c commmand: remove errx 2017-07-14 11:57:11 +02:00
Beat Küng 6b99b3412e esc_calib: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 0fdd2b9fea dumpfile: add documentation & do cleanup (remove err(), ...) 2017-07-14 11:57:11 +02:00
Beat Küng 7893623d75 fix dumpfile: specify stack size 2017-07-14 11:57:11 +02:00
Beat Küng 4ea44e51b7 config.c: add documentation & do cleanup (remove err(), ...)
Also changes the order of the arguments for consistency.
2017-07-14 11:57:11 +02:00
Beat Küng be25c337f9 bl_update: add documentation & do cleanup (remove err(), ...) 2017-07-14 11:57:11 +02:00
Beat Küng 35aa95c25f perf_counter.c: mention that the latency buckets are in us 2017-07-14 11:57:11 +02:00
Beat Küng 872049dc57 pwm.cpp: extend documentation for Oneshot 2017-07-14 11:57:11 +02:00
Beat Küng fac6a829c4 pwm.cpp: fix issues by clang tidy (nullptr & void) 2017-07-14 11:57:11 +02:00
Beat Küng 37ff267b68 param.cpp: fix issues by clang tidy (nullptr & void) 2017-07-14 11:57:11 +02:00
Beat Küng b32b0d9b17 hardfault_log: add documentation 2017-07-14 11:57:11 +02:00
Beat Küng 488bc9d7f3 hardfault_log.h: fix comments 2017-07-14 11:57:11 +02:00
Beat Küng 3b0da512a5 px_process_module_doc: add --no-validation flag
and make sure the command failed if there's a validation error.
2017-07-14 11:57:11 +02:00
Beat Küng d309617998 param.c: rename to cpp and add module documentation
use c++ so that raw string literals can be used
2017-07-14 11:57:11 +02:00
Beat Küng 647bdef855 pwm.c: rename to pwm.cpp and add module documentation
use c++ so that raw string literals can be used
2017-07-14 11:57:11 +02:00
Beat Küng 3f6769d41e uorb: add module documentation 2017-07-14 11:57:11 +02:00
Beat Küng f25549169c fmu: wait until running, and handle mode_rcin properly
when the fmu was already running in a pwm mode, changing to mode_rcin would
not have any effect.
2017-07-14 11:57:11 +02:00
Beat Küng 3b64be44f4 ModuleBase: add wait_until_running() method 2017-07-14 11:57:11 +02:00
Beat Küng 6778be2c6e mavlink: remove 'p' from px4_getopt()
It is not handled and not documented.
2017-07-14 11:57:11 +02:00
Beat Küng 0909b58981 fmu.cpp: fix wrong command usage mode_pwm3cap2 -> mode_pwm2cap2 2017-07-14 11:57:11 +02:00
Beat Küng 053eb12329 Module documentation: switch to Markdown 2017-07-14 11:57:11 +02:00
Beat Küng 6c9574b336 Tools/px_process_module_doc.py: add script to extract documentation
And turn it into a markdown page.
It also does some simple validation, to check that the getopt() arguments
match the documentation.
2017-07-14 11:57:11 +02:00
Beat Küng c22b79ece5 pwm.c: fix wrong comment 2017-07-14 11:57:11 +02:00
Beat Küng 45bc882f5d px_process_params: fix scope when script is called from repo root
If called with ./Tools/px_process_params.py, the path would start with
src/<module>, and thus not match the regex "^.*/src/"
2017-07-14 11:57:11 +02:00
Beat Küng 41e53ef949 px_process_airframes: add image path as optional argument for markdown output
usage:
./px_process_airframes.py -m -i ../image/path
2017-07-14 11:57:11 +02:00
Beat Küng 63af349bba px4_module.h: include <cstring> for strcmp() 2017-07-14 11:57:11 +02:00
Beat Küng 59bde454b5 ModuleBase: instanciate -> instantiate 2017-07-14 11:57:11 +02:00
Beat Küng f691ae2a4f mavlink: update usage & module description 2017-07-14 11:57:11 +02:00
Beat Küng 2ad7194ed3 pwm command: update usage 2017-07-14 11:57:11 +02:00
Beat Küng 9e4d1235ac pwm command: fix -e param (it was just ignored)
to keep the behavior the same, remove the -e flags from all pwm commands
that use it in the scripts.
2017-07-14 11:57:11 +02:00
Beat Küng 317c8bf557 uorb: update usage 2017-07-14 11:57:11 +02:00
Beat Küng 7b7836de05 param command: update usage 2017-07-14 11:57:11 +02:00
Beat Küng c1788c4e43 top: add module description & usage 2017-07-14 11:57:11 +02:00
Beat Küng 6ea9762117 fmu: convert to ModuleBase
Sorry for the large patch :)

- move cleanup into destructor (this was done on the wrong task before)
- move init into init() method
- sensor & peripheral reset do not start/stop fmu anymore
- remove err & errx (they do not release the lock and could lead to dead-
  locks)
2017-07-14 11:57:11 +02:00
Beat Küng 2da0ae45e5 fmu: some cleanup
g_port_mode was never changed.
2017-07-14 11:57:11 +02:00
Beat Küng 16740dd5cd io timers: fix some typos 2017-07-14 11:57:11 +02:00
Beat Küng 7361244359 logger: convert to use ModuleBase 2017-07-14 11:57:11 +02:00
Beat Küng 5bdbfa9b5c send_event: convert to use ModuleBase 2017-07-14 11:57:11 +02:00
Beat Küng 04c4339ca3 module: add a common module base class with usage printf methods
Provides:
- thread-safety for module start/stop
- some shared code for module start/stop. Should also be less prone to
  errors.
- constructor & destructors are called from within the new module thread
- can be used for work queue & thread modules
- strutured & formal way for module printf usage & module documentation

Limitation:
- supports only modules with one instance (eg. not mavlink)
2017-07-14 11:57:11 +02:00
David Sidrane b5275ecd52 ver:The recent changes to version.c return values in base10
This is part 2 of the fix. The tool that extracts the nuttx
   git tag was broken by a new tag added the did not match
   the form nuttx-M.mm. To the value was printed as

   OS: NuttX
   OS version: 0.0.0 c0 (192)

  Once that issue was fixed, it was apparent that recent
  changes to version.c return the values as base 10, before
  it was hex. This fixes the formatting.
2017-07-14 10:46:30 +02:00
David Sidrane de97ff163b NuttX/nuttx got tagged and broke git version version exraction
This is part one of a fix for cascading failure. The NuttX
  nuttx repos was tagged with upstream_7.18+ and broke the tag
  extraction that was expecting nuttx-M.mm
2017-07-14 10:46:30 +02:00
Beat Küng eeb1895922 i2c_posix: fix simulate variable cannot be assigned on QuRT 2017-07-13 16:53:28 +02:00
Beat Küng 46a7287178 linux_pwm_out: add support for ESC calibration 2017-07-13 16:53:28 +02:00
Beat Küng bf11362dae i2c_posix: fix use of wrong device path
previously, get_devname() was used as the I2C device path, but on NuttX,
get_devname() is the device file which the driver creates. This patch
changes it, so the sematics are the same as on NuttX: both now use _bus
to decide to which I2C bus device to talk to.

I did not see any other use-cases than the led on ocpoc.
2017-07-13 16:53:28 +02:00
Beat Küng fc4affbb5f ocpoc_mmap_pwm_out: remove this driver, it's in linux_pwm_out now 2017-07-13 16:53:28 +02:00
Beat Küng d17a7b46e8 linux_pwm_out: add ocpoc_mmap mode 2017-07-13 16:53:28 +02:00
Beat Küng 8527c8276f drivers: rename rpi_pwm_out to linux_pwm_out 2017-07-13 16:53:28 +02:00
Beat Küng 5cbee15309 ocpoc_adc: make xadc_fd a local variable instead of a class member 2017-07-13 16:53:28 +02:00
Beat Küng 2cf88156a9 cmake: remove -Os from COMPILE_FLAGS in px4_add_module()
This is already added to the global list, and we already removed this
flag previously, but some of them sneaked back in.
2017-07-13 16:53:28 +02:00
Beat Küng d3f76262da RPI px4_no_shield.config: add documentation for connected HW 2017-07-13 16:53:28 +02:00
Beat Küng 243ae00e4e rpi_pca9685_pwm_out: remove this driver, it's now in rpi_pwm_out 2017-07-13 16:53:28 +02:00
Beat Küng 51dc988914 rpi_pwm_out: fix mixing output handling (use correct number of outputs) 2017-07-13 16:53:28 +02:00
Beat Küng b6942115e1 rpi_pwm_out: add support for PCA9685 output 2017-07-13 16:53:28 +02:00
Beat Küng 723f67b39a refactor navio_sysfs_pwm_out: rename to rpi_pwm_out 2017-07-13 16:53:28 +02:00
Beat Küng 8ccbc068c2 RPI PCA9685: code cleanup 2017-07-13 16:53:28 +02:00
Beat Küng d898b555d3 rpi_rc_in: code cleanup 2017-07-13 16:53:28 +02:00
Beat Küng 785b997a2e posix_rpi_cross_no_shield.cmake: move -D__DF_RPI_SINGLE from commons to this file 2017-07-13 16:53:28 +02:00
crossa 4bde004474 1. Add parameter name in head file
2. Remove printf in the cpp
2017-07-13 16:53:28 +02:00
crossa 917d520378 Check _rcinput_pub is null. 2017-07-13 16:53:28 +02:00
crossa ef587c9593 Add -D__DF_RPI_SINGLE in posix_rpi_common.cmake
Add -D__DF_RPI in posix_rpi_common.cmake
Add rpi_rc_in and rpi_pca9685_pwm_out  driver in posix_rpi_common.cmake
Rename posix_rpi_cross_without_navio_or_pxfmini to posix_rpi_cross_no_shield.cmake
2017-07-13 16:53:28 +02:00
crossa 0340f96ad0 Rename px4_rpi.config to px4_no_shield.config 2017-07-13 16:53:28 +02:00
crossa d37280e99b REMOVE DEBUG INGO 2017-07-13 16:53:28 +02:00
crossa 18298f861d Remove duplicated configs 2017-07-13 16:53:28 +02:00
crossa b4032f6290 Remove duplicated config 2017-07-13 16:53:28 +02:00
crossa 6a9aa60ad7 Add rpi_pca9685_pwm_out command 2017-07-13 16:53:28 +02:00
crossa ed319ce5d5 1. Add comment written in English
2. Rewrite and rebase pca9685 driver
3. Try to fix issue when push the stick of channel 3 to the maxmum position, 0uswill be output to channel 1, should be maxmum pwm signal
4. Fix the code style
2017-07-13 16:53:28 +02:00
crossa 78b853431d change gps command 2017-07-13 16:53:28 +02:00
crossa ea2a3acbd8 This driver has been tested and finished first flight
Now I've fixed style of the code
2017-07-13 16:53:28 +02:00
zhangfan 8a691d9bfb Add CMake file for raspberry pi without shield 2017-07-13 16:53:28 +02:00
crossa c89351c453 Add PWM output driver with raspberry pi+pca9685 module 2017-07-13 16:53:28 +02:00
crossa 6ee6165592 PX4 RASPBERRY PI CONFIG 2017-07-13 16:53:28 +02:00
crossa 4839e5cd19 Fix code style 2017-07-13 16:53:28 +02:00
crossa 7b108eb879 Reading the pwm signal from shared image.
Both 8 channels PPM encoder and 8 channels revicer are required.
Before launch px4, ppmdeocde programe should be launched.
To download ppmdecode programe,
visit https://github.com/crossa/raspberry-pi-px4firmware.
Pxfmini and navio are not popular autopilot hardware in china,
I can handly to purchase it.
So that I use raspberry pi to build autopilot separately.
This dirver help us to decode ppm single to pwm and pushlish it
2017-07-13 16:53:28 +02:00
José Roberto de Souza ac7127ff0f systemcmds: dataman: Check for errors in tasks 2017-07-13 15:21:26 +02:00
José Roberto de Souza 2f2e3a7e7c modules: dataman: ram_flash: No need to write/erase data that do not need to persist
Just update in RAM is enough.
2017-07-13 15:21:26 +02:00
José Roberto de Souza 10f54e718e modules: dataman: Optimize memory usage
Use the size of each item type instead of the biggest one.

In AeroFC that runs is constrained mode it was using 7860 bytes
and now it uses 6930 bytes almost 1KB less.
2017-07-13 15:21:26 +02:00
Ramón Hernán Roche Quintana f160743df4 Join us on Slack README badge 2017-07-12 07:19:20 +02:00
ChristophTobler add78a4b04 stream distance sensor at 10Hz for SITL-EKF testing 2017-07-11 13:59:12 +02:00
Lorenz Meier dbc7d805f2 Navigator: Fix pause mode to not continue to next waypoint if already set 2017-07-11 13:23:12 +02:00
Henry Zhang 8f391a6eae MindPX: update NuttX config 2017-07-11 09:52:51 +02:00
Henry Zhang 145c05acc7 Add support for the mpu6k to the MindPXv2 2017-07-11 09:52:51 +02:00
José Roberto de Souza 9a05c5f137 mavlink: Send command long when component id is broadcast
Check for the broadcast systemd id to block forward of broadcast
commands.
2017-07-11 09:52:22 +02:00
David Sidrane fc30f2906f mpu9250:Use a cpu speed independant _reset_wait generations.
This change first pushes out the _reset_wait by 100 Ms.
   which is about 3 time longer then the code take to execute.

   Then it does the reset of the accel, gyro and mag and
   the ends the wait by setting _reset_wait to now+10 us.
2017-07-11 09:51:31 +02:00
David Sidrane 3f0d26c949 mpu6000:Support different clock freq per IC type 2017-07-11 09:51:31 +02:00
David Sidrane 3c42c8f7fa mpu9520:Use maximum clock rate
The MPU9250 and MPU6500 buth support 1 Mhz and 20 Mhz. Buy upping the clocc we will get the maximum clock rate the driver
   supports that is <= 20 Mhz. This will boost the FMUv4Pro SPI speed to 11.25 Mhz (it was half that)
2017-07-11 09:51:31 +02:00
David Sidrane 22d0ea15de px4fmu-v3:Add ICM20608 aliased to the PX4_SPIDEV_ACCEL_MAG to the v3 build
The Pixkhawk mini was not chip selecting the ICM20608 as it did
   not define PX4_SPIDEV_ICM_20608. This allow the fmu V2 rc code
   to init the ICM20608.
2017-07-11 09:49:22 +02:00
David Sidrane 195468bf06 px4fmuv4pro:Init GPIO_VDD_3V3_SENSORS_EN off at reset
Insure a 0.0 voltage initial condition on VDD_3V3_SENSORS
  By starting the GPIO_VDD_3V3_SENSORS_EN, low and deferring
  the GPIO init of the slave selects and drdy signals until
  board_app_initialize. We get ~ 180 ms of power off time
  with 0.00 voltage applied to the sensors.
2017-07-11 08:34:26 +02:00
Lorenz Meier 6a3e27fe18 PWM command: Be less verbose 2017-07-11 08:15:44 +02:00
Sander Smeets 48be61160d Float value correction 2017-07-10 21:15:08 +02:00
Sander Smeets 70178266f0 VTOL pusher assist: return vehicle to level position 2017-07-10 21:15:08 +02:00
bresch 81c46b6f92 VTOL Standard - Disable pusher-for-pitch strategy in manual control 2017-07-10 21:13:28 +02:00
Anup Parikh 1cff86025e Fix issue #7525
Add missing `.py` extension to Tools/px4 to fix #7525
2017-07-10 18:48:27 +02:00
Lorenz Meier 57a2ea0cd1 Navigator: Do not change target position if user is only changing altitude
This is important for multicopters for drift-free altitude changes and important for fixed wing to keep the current loiter center.
2017-07-10 18:36:03 +02:00
Lorenz Meier c89bd5c8fd HMC5883: Fix range setup 2017-07-10 08:32:19 +02:00
Daniel Agar 164010ea4c standard plane consistent metadata 2017-07-09 16:36:44 -04:00
Lorenz Meier f2b8291587 Logger: Run at lower priority than core control pipeline
This should ensure that controllers run first and log data copying happens after.
;
2017-07-09 21:59:01 +02:00
Lorenz Meier df173d4d8a Sensors: Do not update calibration when armed. Run at lower priority than attitude control and estimator
This ensures that the massive (several hundred params if temperature compensation is enabled) param load is not done in flight. We also lower the priority to ensure that attitude controllers and estimators which might consume sensor data directly execute immediately, which should reduce their latency.
2017-07-09 21:58:48 +02:00
Lorenz Meier 3bdd0e95dd EKF2: Show time slip on console 2017-07-09 21:58:41 +02:00
Daniel Agar 8ff40d8048 consolidate standard plane configurations 2017-07-09 21:05:03 +02:00
Daniel Agar 585984fa0c fmuservo increase stack 2017-07-09 18:02:55 +02:00
Lorenz Meier 75faf5c7bd Preflight checks: Increase accel warn limit range 2017-07-09 16:38:56 +02:00
Lorenz Meier 80461fad6b Camera trigger: Support triggering one image immediately.
This allows to re-enable the distance trigger and immediately take a picture. This is helpful to ensure survey areas are covered on entry and exit.
2017-07-09 14:49:21 +02:00
Lorenz Meier 1a12326d7d Reserve value in ENUM for simple mode 2017-07-09 14:43:24 +02:00
Lorenz Meier 099a6dfd3e Mission feasibility checker: Improve output messages for humans
Text to speech will work better with these messages and some of them exceeded the 50 character limit.
2017-07-09 14:43:24 +02:00
Lorenz Meier eb5b153d10 MAVLink app: send status text only if connected to something that can actually handle it.
This increases the chance that the operator gets to see the messages that the vehicle emitted before telemetry was connected.
2017-07-09 14:43:24 +02:00
Lorenz Meier 5a8062e646 MAVLink app: Provide function for connected state
If we have not received an inbound heartbeat we are probably not connected and so user-facing output (which is even buffered) should go only out once we are connected.
2017-07-09 14:43:24 +02:00
Lorenz Meier 4ca7187e42 Commander: Do not allow to set mission mode if the mission is failing feasibility checks. Provide clear feedback if telemetry is online and home is set about an invalid mission state. 2017-07-09 14:43:24 +02:00
Michael Schaeuble d53598ed58 UAVCAN: Publish actuator outputs 2017-07-09 14:41:48 +02:00
Daniel Agar 61fd6f4c8a uorb failure print topic name 2017-07-09 14:40:11 +02:00
Daniel Agar f45b9048aa GPS driver increase stack (244 bytes left) 2017-07-09 13:09:22 +02:00
garfieldG a9750f7ccb Fixed formatting 2017-07-09 13:08:49 +02:00
garfieldG be41cf8ba1 Fixed parameters naming and type and added comments 2017-07-09 13:08:49 +02:00
garfieldG 44e148151b Fixed the version naming 2017-07-09 13:08:49 +02:00
Daniel Agar 7a9e31f440 delete unused MPC_XY_FF and MPC_Z_FF (#7563) 2017-07-08 20:57:10 -04:00
Daniel Agar 75a528e061 FW EKF2 and ublox defaults
- closes #7550
2017-07-09 00:24:00 +02:00
Daniel Agar e0aa2e2391 RTL reduce verbosity 2017-07-08 21:54:04 +02:00
Daniel Agar fbebec5d0f navigator log RTL messages and don't print global timeout 2017-07-08 21:54:04 +02:00
Daniel Agar f396224d41 mag calibration add notifications to rotate 2017-07-08 21:54:04 +02:00
Daniel Agar 1a6a871689 commander properly set boot timestamp 2017-07-08 21:54:04 +02:00
Daniel Agar b804616ad0 preflight check airspeed use differential_pressure 2017-07-08 21:54:04 +02:00
Daniel Agar e303c2ad89 eagle tree airspeed allow negative differential pressure 2017-07-08 21:54:04 +02:00
Rogelio 9d9da229cc Add GPS command to all eagle configs 2017-07-08 20:28:30 +02:00
Daniel Agar f11bb401f4 CMD_MISSION_START allow first_item=-1 to leave index unchanged 2017-07-08 19:49:52 +02:00
Lorenz Meier 49bbd0e58d Navigator: Be less verbose 2017-07-08 19:36:58 +02:00
Lorenz Meier d80be2e4ff MAVLink: better output handling 2017-07-08 19:36:58 +02:00
Lorenz Meier 24ffada340 MPU9250: Hold off from reboot a little longer. Fixes #7555 2017-07-08 16:38:18 +02:00
Lorenz Meier 9cd93dcf03 MPU9250: Fix boot on Pixhawk Mini
This requires further investigation. Hotfix.
2017-07-08 16:31:12 +02:00
David Sidrane f722614ec0 mpu9250:Stop per counter on failed read 2017-07-08 15:37:46 +02:00
David Sidrane fbf6532c25 mpu9250:reset the mag on the reset operation
This commit fixed a bug were the mag was orphened on a reset.
   That resulted in MAG timeouts on reset or test operations and
   left the mag in a broken state.
2017-07-08 15:37:46 +02:00
David Sidrane 8bd044e80e mpu9250:mag rework the setup to veify HW first
If the setup is unsucessful fo not register the devices or
   allocate resources.
2017-07-08 15:37:46 +02:00
David Sidrane aec109ac2c mpu9250:mag restructure to have proper retires for setup
We want to setup the mag interface with retries and report
  failurs.

  Move retry logic to contol point, instead of hiding re-reading
  the ID in ak8963_check_id.

  Allow it to fail once to overcome a read of 0 on firt read.
  after 2 failure report error to console and reset the
  mpu9250's I2C master (SPI to I2C bridge)

  The same retry logic is used on the ak8963_read_adjustments
  with a reset of the I2C master module after 5 fails. If it
  fails fter 10 retires. Disabel the mad and report the failure
  on the console, stating it is disabled.
2017-07-08 15:37:46 +02:00
David Sidrane 270dd5282a mpu9250:Add modify checked register api
Provide an API for the mag to use read-modify-write
2017-07-08 15:37:46 +02:00
David Sidrane ef67b75057 mpu9250:Added comment on BYPASSING the internal i2c master bridge 2017-07-08 15:37:46 +02:00
David Sidrane c3addd931c mpu9250:Issue error on console when a device fails to take initialization
On initialization, if after 3 retries to re-init the mpu9250 from
   the checked registers values, it fails. Ensure thath the fact the
   driver is exitting is logged to console.
2017-07-08 15:37:46 +02:00
David Sidrane 3272cc62d4 mpu9250: Do a reasonable post chip init validations, reporting errors
Check that the mpu9250's configured registers match the settings
   written to them. Attempt to fix any that do not up to 3 times.
   printing erros to the console on mismatches and returning
   faliure if after 3 attempts the any of the values are
   still wrong.
2017-07-08 15:37:46 +02:00
David Sidrane 7e293ab1d3 mpu9250:Fix errant comment 2017-07-08 15:37:46 +02:00
David Sidrane 5a53d92f22 mpu9250:Remove foklore delays
Remove delays on each register write in the
   reset function. Leaving only the delay
   following chip reset prior to configurations.
2017-07-08 15:37:46 +02:00
David Sidrane b4d23a3f2c mpu9250:Rmove magic number, add ACCEL_RANGE_G 2017-07-08 15:37:46 +02:00
Lorenz Meier 90fdc544fd MAVLink app: Code style fix 2017-07-08 15:34:36 +02:00
Lorenz Meier ddf32e14de MAVLink app: More print improvements 2017-07-08 15:23:46 +02:00
Lorenz Meier d15dd061f9 MAVLink app: More debug string formatting 2017-07-08 14:36:08 +02:00
Lorenz Meier e8aa5a3172 MAVLink app: Fix non-enabled debug string output 2017-07-08 14:23:46 +02:00
Lorenz Meier 6f368f34d1 MAVLink: Remove non-required safety check 2017-07-08 13:59:35 +02:00
Lorenz Meier 8d8174ea0c MAVLink command retransmission: Reduce RAM footprint and make debug output optional 2017-07-08 12:46:28 +02:00
Julian Oes a13f23f244 timestamped_list: use const ref 2017-07-08 11:52:23 +02:00
Julian Oes 7e1e98b258 timestamped_list: fix comment syntax 2017-07-08 11:52:23 +02:00
Julian Oes 1576094d9f mavlink_command_sender: use const ref 2017-07-08 11:52:23 +02:00
Julian Oes 893b7b5d46 mavlink_command_sender: instantiate in initialize 2017-07-08 11:52:23 +02:00
Julian Oes c66af00753 mavlink_command_sender: fix NuttX build 2017-07-08 11:52:23 +02:00
Julian Oes e6d31f951c mavlink_command_sender: fix logic after first test
- change/add a few printfs so they make more sense
- don't accidentally ignore command_acks
- don't forward commands to the same component id, and don't forward
  commands that are broadcast to all components (target component 0)
2017-07-08 11:52:23 +02:00
Julian Oes af0107ae0a mavlink: add class for command retransmission
This adds a class to allow for retransmission of outgoing commands.
The sent commands are kept in a timestamped list to check if they are
acked as required by the mavlink protocol.
If they are not acked within a timeout, they can be retransmitted.
2017-07-08 11:52:23 +02:00
Julian Oes 9854fc0d84 Set timestamp with vehicle commands
The vehicle_command uORB messages had the timestamp unset at 0.
2017-07-08 11:52:23 +02:00
Julian Oes d64b7706f5 check_code_style_all: accept astyle version 3.0.1 2017-07-08 11:52:23 +02:00
ChristophTobler a5e435808f mavlink log if camera unsuccessful 2017-07-08 11:52:23 +02:00
Lorenz Meier b42c1123a2 ROMFS: Add flaps and gear mixers to all standard planes
It makes sense to have this for all standard planes and our default PWM outputs for MAIN are always 6 wide, so this should scale to all known HW platforms.
2017-07-08 11:50:48 +02:00
David Sidrane 6eff7deb7e Extend the delay ensure post reset pulse delayed.
Given the original poster's comment that "It happens very consistently for us." I suspect the motor spin observed in https://github.com/PX4/Firmware/issues/7457 is not caused by the original issue of slow decay on the PWM pins at reset, but the post reset pulse of 3.1 Ms arriving in a window that the ESC considers it valid.

The results from testing, indicated that the if the PWM pins were clamped low for > 300 Ms, prior to reset the motors did not spin. This would delay the the post reset pulse of 3.1 Ms out by > 300 Ms. 

This change delays the reset and therefore the pulse by at least 400 Ms.
2017-07-08 10:51:43 +02:00
David Sidrane 65d8b5c9cd px4fmu-v4:Insure the discharge of the pins PWM pins on rest.
On resets invoked from system (not boot) insure we establish a low
  output state (discharge the pins) on PWM pins before they become
  inputs.
2017-07-08 10:51:43 +02:00
Jan Liphardt 38fa6dcad5 Clipping of the battery current due to Int*Float
Note that Type buf_adc[i].am_data = int32_t, but everything else are floats. Suggest (float)(buf_adc[i].am_data), precisely as was done a few lines later for the voltage.
2017-07-08 10:23:36 +02:00
Matthias Grob 60c760280e mc_pos_control: fix comment typo "hight" 2017-07-07 18:25:35 +02:00
Matthias Grob b511ccd9fe mc_pos_control: integrate complete order and limits of velocity setpoint calculation
- one warn_rate_limited was missing
- vel_sp_slewrate was in the wrong order for smooth slowdown/speedup on takeoff and landing
- slow_land_gradual_velocity_limit was replaced by calls to math::gradual
- smooth takeoff speed got controllable by user input
- comments were corrected
- an additional check for the sanity of velocity setpoints was added
2017-07-07 18:25:35 +02:00
Matthias Grob 1d7f760a96 mathlib, mc_pos_control: rename functions file and add gradual linear function 2017-07-07 18:25:35 +02:00
Dennis Mannhart 1c2d54397f mc_pos_control: move constraints to the end 2017-07-07 18:25:35 +02:00
Dennis Mannhart 2758a4a6fa mc_pos_control: add warn_rate limit function 2017-07-07 18:25:35 +02:00
Beat Küng c8b9f8afa8 F7 nuttx configs: increase CONFIG_STM32F7_BBSRAM_FILES to 5 2017-07-07 17:06:48 +02:00
Beat Küng 9141bf8386 replay: handle INFO_MULTIPLE & FLAG_BITS ULog messages 2017-07-07 17:06:48 +02:00
Beat Küng c775b07b43 logger: use INFO_MULTIPLE for top & perf output 2017-07-07 17:06:48 +02:00
Beat Küng 209f220288 hardfault_log: move hardfault_store_ulog_filename to logger module 2017-07-07 17:06:48 +02:00
Beat Küng eac657f4b3 hardfault_log: append crash log to last ULog file upon commit
This keeps the separate .txt around, since it's possible that the ULog file
gets corrupt during the crash.
2017-07-07 17:06:48 +02:00
Beat Küng b515873bee ULog: add INFO_MULTIPLE & FLAG_BITS messages
This requires support in the parsers, and thus the ULog file version is
increased.
As long as no data is appended, both, existing pyulog & FlightPlot, can
still read the new logs (they will output a warning).
The replay module will print an error, but still continue.
2017-07-07 17:06:48 +02:00
Beat Küng 1be089cf0c BBSRAM: add another partition and store the last ulog path 2017-07-07 17:06:48 +02:00
Beat Küng 18ea5ec1f8 logger: add git branch name to the log 2017-07-07 17:06:48 +02:00
Lorenz Meier 91144f502f EKF2 build fix 2017-07-07 08:29:10 +02:00
Hamish Willee 5af62c8e49 Fix up so image links work properly 2017-07-06 22:21:46 +02:00
Hamish Willee 02b1048752 Make default output file name airframes_reference.md, which is expected by our gitbooks 2017-07-06 22:21:46 +02:00
Hamish Willee 8edc70d150 Add anchors for every vehicle in airframes reference 2017-07-06 22:21:46 +02:00
Hamish Willee 7775953289 Fix up airframe URLS to point to the PX4 user guide airframe build info 2017-07-06 22:21:46 +02:00
Paul Riseborough 63cbce6bd3 ekf2: Increase RAM to remove stack space warnings 2017-07-06 22:20:48 +02:00
Paul Riseborough ee75f0eb0e ekf2: Use updated quaternion type def 2017-07-06 22:20:48 +02:00
Paul Riseborough b7a5fd3147 ecl: update to latest master with bug fixes 2017-07-06 22:20:48 +02:00
Lorenz Meier f7ba70a032 MPU6K driver: Ensure that default range is always 16g by default 2017-07-06 22:15:53 +02:00
Daniel Agar 1c7833e3b1 airspeed calibration simplify logic 2017-07-06 10:05:07 -04:00
Daniel Agar eb067291bf airspeed sensors apply offset separately 2017-07-06 10:05:07 -04:00
Daniel Agar c45d369004 ms5525 use int64 for calculation 2017-07-06 10:05:07 -04:00
Daniel Agar b66b734a74 rcS move additional sensors to rc.sensors 2017-07-06 10:05:07 -04:00
Daniel Agar 95eaac6876 bmp280 properly cleanup if failed 2017-07-06 10:05:07 -04:00
Daniel Agar 936f92fd0b airspeed verify using filtered differential pressure 2017-07-06 10:05:07 -04:00
Daniel Agar 72969f00d7 airspeed calibration error_count is uint64_t 2017-07-06 10:05:07 -04:00
Daniel Agar 32068dcd17 px4io increase stack 2017-07-06 10:05:07 -04:00
Daniel Agar 85d7c7d165 add sdp3x_airspeed to px4fmu configs 2017-07-06 10:05:07 -04:00
Daniel Agar 73d9358b1d meas_airspeed rename to ms4525_airspeed 2017-07-06 10:05:07 -04:00
Daniel Agar 7029be87c0 MS5525 differential pressure driver 2017-07-06 10:05:07 -04:00
James Goppert 66a890d428 Remove mode enum since not used and declare enum type. 2017-07-06 09:02:13 +02:00
James Goppert 9f20730d7e Remove unused sdlog mode handle. 2017-07-06 09:02:13 +02:00
James Goppert 57e0051c42 Fix enum. 2017-07-06 09:02:13 +02:00
James Goppert ac8ef5f338 Formatting. 2017-07-06 09:02:13 +02:00
James Goppert 16f46c15d3 Switch to class enum and cleanup log profiles. 2017-07-06 09:02:13 +02:00
James Goppert 034c0c702a Remove estimator replay log profile. 2017-07-06 09:02:13 +02:00
James Goppert 82d7332f1a Remove log profile set to thermal calibration for PX4FMU_V5. 2017-07-06 09:02:13 +02:00
Beat Küng 784cec1cae logger: check if topic already added & if so only update the interval 2017-07-06 09:02:13 +02:00
James Goppert 15ae3a9eb7 Add estimator replay topics to default. 2017-07-06 09:02:13 +02:00
James Goppert d10a491243 Add logging profiles to logger module. 2017-07-06 09:02:13 +02:00
Nicolae Rosia 2092770361 Integrator: fix comparison
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-07-06 08:48:44 +02:00
Lorenz Meier 9bb3ab4a71 Update SITL module 2017-07-06 07:42:17 +02:00
Lorenz Meier 72e452ba32 Add missing Iris config 2017-07-06 07:42:06 +02:00
imcnanie 629844adff Dodeca mixer using the AUX channels (#7532)
* Added Dodecarotor Mixer

* fixed formatting style

* Renamed dodeca mixers to top and bottom
2017-07-05 22:17:33 +02:00
Beat Küng 1e2ce51c6d LandDetector: fix vehicle flight time
The problem was signed vs unsigned mixing together with 64bit conversion:
int32_t flight_time = ...;
uint64_t _total_flight_time = ...;
_total_flight_time |= flight_time;
When flight_time is negative, the last line would first extend the sign
bit to the upper 32bits of the 64bit uint and then apply the bitwise OR.
The fix is to use an unsigned 32 bit value.
2017-07-04 14:13:18 +02:00
Lorenz Meier f54a6c2999 VTOL Controller: Always read ready topics
When poll returns a ready FD we have to read it, no matter which flight mode the system is in.
2017-07-02 21:52:18 +02:00
Lorenz Meier 1acf547e8b POSIX: Move C/C++ separation 2017-07-02 21:50:42 +02:00
Lorenz Meier ca7c71b759 Update SITL version 2017-07-02 21:50:02 +02:00
Lorenz Meier 5724bef14d VTOL att controller: Code style fix 2017-07-02 20:59:25 +02:00
Lorenz Meier 792b03628f CMake: more clear instructions for python dependencies 2017-07-02 17:15:12 +02:00
Lorenz Meier 5a4714fef2 Track Gazebo submodules more closely 2017-07-02 17:00:08 +02:00
Lorenz Meier 4cae86dc1a Update jMAVSim 2017-07-02 16:59:55 +02:00
Lorenz Meier 82bd13bfe0 Update SITL Gazebo interface version 2017-07-02 16:46:13 +02:00
Lorenz Meier 6ea9c1877b Add version command to PX4 tools directory 2017-07-02 14:43:13 +02:00
Hamish Willee 071cfc2d31 Ensure groups have unique names in TOC 2017-07-01 20:04:46 +02:00
Hamish Willee 6f3b6bf55b Update parser to get class information and create separate groups for each class 2017-07-01 20:04:46 +02:00
Hamish Willee 50140b3d90 Group by vehicle type and add headings 2017-07-01 20:04:46 +02:00
Hamish Willee d88e387013 Fix typo in exported text 2017-07-01 20:04:46 +02:00
Daniel Agar af5256c454 GPS ublox add dynamic model parameter 2017-06-30 08:02:25 +02:00
Daniel Agar c8189b9c23 navigator mission_block check range for loiter exit
- fixes #7510
2017-06-29 21:28:26 +02:00
Beat Küng 6fcd7d9529 estimator_status.msg: fix documentation of innovation_check_flags 2017-06-29 16:06:06 +02:00
Daniel Agar 40d40330b8 delete unused pio 2017-06-29 03:23:39 -10:00
David Sidrane fc25213811 auav-x21:Delete PX4_I2C_BUS_ONBOARD 2017-06-29 07:59:56 +05:30
Mohammed Kabir 0bda4a7edd rc.sensors : correctly start up sensors on AUAV-X2.1 2017-06-29 07:59:56 +05:30
Daniel Agar cd8c8ea5de FW default PWM_RATE 50 2017-06-28 09:13:19 +02:00
Jan Liphardt d5eab23f53 airspeed error message clarification (#7497)
In day to day practice, there are two reasons for fabsf(airspeed.differential_pressure_filtered_pa) > 15.0f

1/ The sensor has not been calibrated. In this case, the sensor needs to be calibrated.
2/ It's a windy day, and the operator has powered up the system without covering the pitot tube. In that case, you need to reboot with the pitot cover in place.

The original message ('Check calibration') is ok, but why not be more direct? The user does not have to "check the calibration" - the user has to (a) either calibrate the system in the first place, or (b) not forget the pitot tube cover when powering up the system.
2017-06-28 00:28:33 -04:00
Lorenz Meier a6ef6c6e33 SITL Launcher: gzserver must be running when gzclient connects 2017-06-27 11:59:29 +02:00
Lorenz Meier dea467bdbd POSIX: Make sure we do not run out of PX4 file descriptors 2017-06-27 11:59:29 +02:00
Beat Küng 0cfa99436f fix 13001_caipirinha_vtol: class should be VTOL 2017-06-27 11:19:55 +02:00
Lorenz Meier 04f9b0400e Add airframe class to hexa 2017-06-27 11:07:03 +02:00
Lorenz Meier f5ff283f17 Quad: Add vehicle class 2017-06-27 11:07:03 +02:00
Lorenz Meier 2ba65a0dcc Various experimental configs: Add class field 2017-06-27 11:07:03 +02:00
Lorenz Meier 51c7d01a19 Plane configs: Add class field 2017-06-27 11:07:03 +02:00
Lorenz Meier 01c074d9e5 Rover configs: add class field 2017-06-27 11:07:03 +02:00
Lorenz Meier 86acaf0159 Quad configs: add class field 2017-06-27 11:07:03 +02:00
Lorenz Meier 49d6853219 VTOL Configs: Add class field 2017-06-27 11:07:03 +02:00
Lorenz Meier ccc4f24ae8 Wing configs: Add class field 2017-06-27 11:07:03 +02:00
Lorenz Meier b78a138f16 Multicopter configs: Add class field 2017-06-27 11:07:03 +02:00
Lorenz Meier 53cda2de79 HIL configs: Add HIL field 2017-06-27 11:07:03 +02:00
Lorenz Meier 968fa39158 Copter configs: Add airframe class field 2017-06-27 11:07:03 +02:00
Lorenz Meier ad624c4a0a Airframes parser: Add new class field 2017-06-27 11:07:03 +02:00
Daniel Agar d641d776f7 mc_pos_control delete unused velocity feed forwards 2017-06-26 11:31:25 -04:00
Daniel Agar f947205cbe delete vehicle_global_velocity_setpoint 2017-06-26 11:31:25 -04:00
Julien Lecoeur fc860140f1 Fix internal compiler error with GCC 7
Here is the error message:
PX4/Firmware/src/systemcmds/tests/test_matrix.cpp:641:1: internal compiler error: in trunc_int_for_mode, at explow.c:55
 }
 ^
Please submit a full bug report,
with preprocessed source if appropriate.
2017-06-26 15:50:44 +02:00
Julien Lecoeur 7929287f73 Fix -Werror=format-truncation on GCC 7
Fix formatting

Check snprintf return for error AND overflow
2017-06-26 15:50:44 +02:00
Julien Lecoeur 407b403e68 Fix -Werror=maybe-uninitialized on GCC7 2017-06-26 15:50:44 +02:00
Julien Lecoeur 06c6a0cdec Fix -Werror=implicit-fallthrough errors on GCC7 2017-06-26 15:50:44 +02:00
Daniel Agar ca480ff868 ms4525 treat max temperature as an error 2017-06-24 22:40:51 +02:00
Daniel Agar f82e85f8ff cmake remove -fno-math-errno and -fmerge-all-constants (#7462) 2017-06-23 11:38:31 -04:00
Daniel Agar 58ca307c9d move -fno-math-errno to nuttx only 2017-06-23 07:56:24 +02:00
Daniel Agar 75a91f79ae compiler optimizations add -fmerge-all-constants 2017-06-21 20:07:36 -04:00
Daniel Agar aeb1fe5a55 compiler optimizations add -fno-math-errno 2017-06-21 20:07:36 -04:00
Lorenz Meier 13bf312263 Commander: Be less verbose 2017-06-21 21:43:28 +02:00
Paul Riseborough d68dd6ae1e ekf2: Fix parameter description typo 2017-06-21 09:28:42 +02:00
Paul Riseborough b3ceb37272 ekf2: Add parameter to set range dependant noise 2017-06-21 09:28:42 +02:00
ChristophTobler 929ecd0e94 change to uint32 to match updated type from ecl 2017-06-21 09:28:42 +02:00
Roman 0007096007 updated ecl
Signed-off-by: Roman <bapstroman@gmail.com>
2017-06-21 09:28:42 +02:00
Roman 33495e8143 ekf2: added parameters to specify horizontal speed and absolute altitude
thresholds for range aid mode

Signed-off-by: Roman <bapstroman@gmail.com>
2017-06-21 09:28:42 +02:00
Roman b5a94481a8 ekf2_main: support range aid feature
Signed-off-by: Roman <bapstroman@gmail.com>
2017-06-21 09:28:42 +02:00
Roman 68c2eb9dec ekf2_params: added range aid parameter
Signed-off-by: Roman <bapstroman@gmail.com>
2017-06-21 09:28:42 +02:00
Khoi Tran 355205554a Use format to properly format file for process_logdata_parser.py 2017-06-20 08:24:30 +02:00
Daniel Agar 8b3fb1e999 param fix parameters.xml dependency 2017-06-19 20:24:09 +02:00
Daniel Agar e1a3c53930 cmake posix and qurt impl fix whitespace 2017-06-19 20:24:09 +02:00
Daniel Agar 61da642cc8 cmake fix airframes.xml dependency 2017-06-19 20:24:09 +02:00
Daniel Agar 6a443765a5 cmake only include mavlink where used 2017-06-19 20:24:09 +02:00
Martina 5984e3d330 mission: clean up mavlink log messages style 2017-06-19 19:34:18 +02:00
Beat Küng 410e822775 px4fmu-v4pro board_config: swap BRICK1 with BRICK2
problem: previously when connecting power to Power 1, commander refused
to arm (no power source error), and when connecting to Power 2, arming
works, but power consumption was not measured (& shown in QGC).
Swapping Brick1 with Brick2 makes sure both works when connecting to
power 1.

Ideally we will have support for both power sources (including fail-over)
2017-06-19 16:52:41 +02:00
ChristophTobler 91a94ce874 check for NAN -> use curr pos and check if first to avoid drifting 2017-06-19 13:26:11 +02:00
Lorenz Meier 7d23a52871 Commander: Remove debug output 2017-06-19 09:28:38 +02:00
Lorenz Meier 0a8b9061cf SDP3x driver: Minor cleanup in driver 2017-06-19 09:26:27 +02:00
Paul Riseborough 28017105f4 position_estimator_inav: publish vertical position derivative 2017-06-19 09:09:52 +02:00
Paul Riseborough a147179ad8 local_position_estimator: publish vertical position derivative 2017-06-19 09:09:52 +02:00
Paul Riseborough 7aec94d4d6 ekf_att_pos_estimator: publish vertical position derivative 2017-06-19 09:09:52 +02:00
Paul Riseborough 4b7ae78fda ekf2: publish vertical position derivative 2017-06-19 09:09:52 +02:00
Paul Riseborough 2e008dfbc4 msg: Add vertical derivative to vehicle position messages
This enables control loops that are sensitive to vertical velocity offsets to use a vertical velocity that is kinematically consistent with the vertical position.
2017-06-19 09:09:52 +02:00
Paul Riseborough 862201cc4c ecl: EKF update
Adds interface for vertical position derivative
2017-06-19 09:09:52 +02:00
Beat Küng 4afa931d80 voted_sensors_update: fix mag rotation
fixes a wrong index for _mag_device_id: previously, driver_index was used
(the CAL_MAG param index), but the correct index is the uorb topic
instance.
2017-06-17 06:36:54 +02:00
Mohammed Kabir 4d6c1b5749 Add second barometer to thermal compensation fitting script 2017-06-16 21:15:09 +05:30
Todd Stellanova fd47e0cbb3 Set system real time clock once from GNSS data.
Fixes #7421

Tested with Pixracer and Zubax GNSS2.0
2017-06-16 07:46:39 +05:30
ChristophTobler bc406a122e disable min loiter altitude 2017-06-15 09:18:35 +02:00
Sean Matthews 1c56cad3b1 Uses astyle 2.06 2017-06-15 08:56:49 +02:00
Sean Matthews 08891526fd Fixes #6484: Bug in Offboard mode incorrect use of type_mask 2017-06-15 08:56:49 +02:00
Lorenz Meier d5c923c7ef Navigator: Fix RTL backtransition for VTOL
A recent change removed the command forwarding required for VTOL transitions. This change brings this back.

Partially reverts https://github.com/PX4/Firmware/pull/7249
2017-06-15 08:27:23 +02:00
Matthias Grob e28f8bff67 commander: make commonly spoken strings more user friendly
these technical messages might not be suitable for the user of a product
2017-06-15 07:50:41 +02:00
Mohammed Kabir 5a96490c68 sensors : fix race condition triggered by slow-to-boot external sensors 2017-06-14 19:53:07 +02:00
Mohammed Kabir 51b23f0b57 sensors : add parameters for 4th mag into used parameters list 2017-06-14 19:53:07 +02:00
Beat Küng 90df55123b lps25h_spi.cpp: remove MAGIOCGEXTERNAL ioctl
Because it's a baro driver, not a mag.
2017-06-14 19:53:07 +02:00
Beat Küng ce7d8d2270 sensor_mag.msg: add is_external flag & set it in the mag drivers
With this we don't have to use the ioctl MAGIOCGEXTERNAL, which does not
work on POSIX (eg. RPi).
2017-06-14 19:53:07 +02:00
Beat Küng 19cdbcfd4f sdp3x_airspeed: fix shadowing warning for crc 2017-06-14 19:53:07 +02:00
Beat Küng ba3d66abba voted_sensors_update: fix invalid/stale mag data on posix
Problem: _mag_device_id is used to get the correct rotation matrix for each
mag. But on POSIX, _mag_device_id was always 0, leading to invalid rotation
matrices.
This resulted in stale mag error messages (rot matrix=0 ==> mag data=0).
_mag_device_id was 0 because there are no /dev/magX devices (eg. on RPi),
thus the mag driver could not be opened.

This patch does: get the device id from the uorb topic instead. We still
need the device handle on certain platforms to apply the calibration params
and to check if the mag is internal or external.

Problem left: on POSIX, the check for external mag does not work.
2017-06-14 19:53:07 +02:00
Beat Küng 76f593afb0 fix voted_sensors_update: remove DevMgr::releaseHandle(h);
the 'continue' continues with the inner loop, whereas the outer loop is
responsible for opening the handle. Thus the inner loop needs to keep it
open.
2017-06-14 19:53:07 +02:00
Beat Küng af6846b9a8 fix voted_sensors_update: use int32 for param_get() 2017-06-14 19:53:07 +02:00
Beat Küng ce27e75a76 sensors: better status output 2017-06-14 19:53:07 +02:00
Beat Küng 1392e25652 Tools/jMAVSim: update submodule
allows setting gps origin via ENV variable
2017-06-14 13:12:10 +02:00
Sean Matthews c41185a277 Fixes valid yaw check 2017-06-14 01:23:37 +05:30
Sean Matthews d9cec600ed Fixes #7313: Invalid setpoint yaw after takeoff 2017-06-14 01:23:37 +05:30
Julien Lecoeur 89a8c656f2 Unneeded includes 2017-06-13 11:50:00 +02:00
Julien Lecoeur 1a6d2c491b Remove explicit template instantiation of Subscription<T> 2017-06-13 11:50:00 +02:00
Julien Lecoeur 550aee4da3 Remove explicit template instantiation of Publication<T> 2017-06-13 11:50:00 +02:00
Julien Lecoeur 3ff1f4d16f Move uORB::Subscription template implementation to header 2017-06-13 11:50:00 +02:00
Nicolae Rosia 0dc4f1f96d Fix strip target and bebop upload
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-06-13 08:16:37 +02:00
Nicolae Rosia 5e57594fba update docker_run.sh
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-06-13 08:16:37 +02:00
Nicolae Rosia 3dd32492de Move find of STRIP_TOOL to toolchain
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-06-13 08:16:37 +02:00
Nicolae Rosia a50a87928f navio_adc: add override flag to init
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-06-13 08:16:37 +02:00
Nicolae Rosia a6acb2e68e ARM Toolchain: search compiler in PATH
Add CMake target for strip since these changes break adb_upload_to_bebop.

GCC users should add the cross compiler bin path to PATH (location of arm-linux-gnueabihf-g++).
Clang user should do the following:
* set CMAKE_CXX_COMPILER to clang++ by providing -DCMAKE_CXX_COMPILER=clang++ to cmake
* get GCC cross compiler - needed because Clang does not ship a CRT
* create a symlink for clang and clang++ in GCC cross compiler bin dir.
* add GCC bin dir to PATH

Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-06-13 08:16:37 +02:00
Nicolae Rosia 8f9ca9b45e Commit 8797a090dc06cd0c9f4cf132b67e4872af1ff8f1 relocated __DF_RPI
but missed to move it from *-clang.cmake Toolchain

Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-06-13 08:16:37 +02:00
Kabir Mohammed f266b91cc9 bebop uploader : kill and restart autostarted PX4 daemon 2017-06-13 08:16:37 +02:00
Kabir Mohammed cd902d32ef Relocate DF_RPI define 2017-06-13 08:16:37 +02:00
Kabir Mohammed 8b1ca2ea9b Rename RPi/Bebop toolchain locations to PX4_TOOLCHAIN_DIR 2017-06-13 08:16:37 +02:00
Kabir Mohammed f123ade6d3 Rename to generic arm toolchain 2017-06-13 08:16:37 +02:00
Daniel Agar bd60f87283 move param jinja templates into relevant module 2017-06-12 12:18:53 -04:00
Daniel Agar 46101b483b QuRT follow CMAKE_BUILD_TYPE 2017-06-12 12:18:53 -04:00
Daniel Agar a04d7989b1 eagle and excelsior fix UART_ESC_BAUD param 2017-06-12 12:18:53 -04:00
Daniel Agar 846435cd97 BlockParam<int> -> BlockParam<int32_t> for qurt 2017-06-12 12:18:53 -04:00
Daniel Agar 4937449890 move parameter unittest into systemcmds 2017-06-12 12:18:53 -04:00
Daniel Agar f26cd01d16 param gen reorganize and fix DISABLE_PARAMS_MODULE_SCOPING 2017-06-12 12:18:53 -04:00
ChristophTobler 9b5de23553 add ref_timestamp (time when origin was set) to lpe 2017-06-12 09:39:41 +05:30
Lorenz Meier a1a0dd37dc Commander: Only report GPS lost errors if armed 2017-06-11 11:19:25 +02:00
Lorenz Meier a25330762a Commander: Adjust airspeed checks on prearm condition
The previous approach would work with old low-end sensors, but with new high-end sensors we get a lot of false alarms on the bench. Relaxing the check to only apply pre-arm will ensure its now only run when the user intents to take off, at which point the airframe should be with pitot covers off in the field.
2017-06-11 11:19:25 +02:00
Lorenz Meier d104f984d4 Sensors: print airspeed validator status 2017-06-11 11:19:25 +02:00
Lorenz Meier 77ee8d5fb9 SDP3X: Lowpass the signal significantly less as it is far less noisy 2017-06-11 11:19:25 +02:00
Lorenz Meier 0cd954e382 Start SDP3X with priority over the legacy devices 2017-06-11 11:19:25 +02:00
Lorenz Meier fd9f6e9415 ROMFS: Rework airspeed start to include SDP3X 2017-06-11 11:19:25 +02:00
Lorenz Meier a5581c6f25 ROMFS: Fix whitespace in rc.sensors 2017-06-11 11:19:25 +02:00
Lorenz Meier b93e1de883 ROMFS: Do not abort on error 2017-06-11 11:19:25 +02:00
Lorenz Meier c6cece52d3 Sensirion SDP3X airspeed / differential pressure sensor driver 2017-06-11 11:19:25 +02:00
Daniel Agar 5ee79648b7 FixedwingPositionControl cleanup comment spacing 2017-06-08 22:04:30 -04:00
Daniel Agar 35864841ba FixedwingPositionControl remove engine failure thrust sp
- this is already done in fw_att_control
2017-06-08 22:04:30 -04:00
Daniel Agar 9511dfa577 FixedwingPositionControl combine TECS resets 2017-06-08 22:04:30 -04:00
Daniel Agar 0e8b0fe013 FixedwingPositionControl clang tidy fixes 2017-06-08 22:04:30 -04:00
Daniel Agar 47ec291340 FixedwingPositionControl add header guard 2017-06-08 22:04:30 -04:00
Daniel Agar 376fdd4206 FixedwingPositionControl unnecessary struct 2017-06-08 22:04:30 -04:00
Daniel Agar 3313ade291 FixedwingPositionControl update copyright and control_task 2017-06-08 22:04:30 -04:00
Daniel Agar 77eaa3ae61 fw_pos_control_l1 rename Landingslope to match case 2017-06-08 22:04:30 -04:00
Daniel Agar 23dd2e537b fw_pos_control_l1 rename to match class 2017-06-08 22:04:30 -04:00
Daniel Agar ea448e7fc2 fw_pos_control_l1 extract FixedwingPositionControl header 2017-06-08 22:04:30 -04:00
Daniel Agar 8d5c955af4 remove partial CMD_OVERRIDE_GOTO implementation (#7356)
- closes #7326
2017-06-08 22:03:50 -04:00
Daniel Agar 3b7e57a5b2 navigator/follow_target remove unused 2017-06-08 22:03:08 -04:00
Daniel Agar d6e9287f51 mc_att_control comment out unused rates_i_scaled 2017-06-08 22:03:08 -04:00
Daniel Agar 70a485826d attitude_estimator_q remove unused and small publish cleanup 2017-06-08 22:03:08 -04:00
Daniel Agar 9b08cf686f mathlib remove Matrix and Vector virtual destructors 2017-06-08 22:03:08 -04:00
Julien Lecoeur 38fff6546d Fix python 3 compatibility in px_uploader.py 2017-06-08 07:57:00 +02:00
Dennis Mannhart e0d81b4c5e mc_pos_control: if triplet not valid in z ignore it 2017-06-07 16:43:36 +02:00
Dennis Mannhart 2a943f4bd0 mc_pos_control: only set current_setpoint to true if triplet valid 2017-06-07 16:43:36 +02:00
Kabir Mohammed 5cbaaa633b FINALLY fix mag rotation issues. (#7366)
* sensors : second cut at fixing mag calibration - remove old problematic code

* sensors : use more intuitive naming for loop variables
2017-06-07 10:49:57 +02:00
Anton Matosov 890c415ff2 Set acro to allowed max values 2017-06-07 12:20:05 +05:30
Anton Matosov f692b87232 Replace tab with space between param name and value to prevent bricking 2017-06-07 12:20:05 +05:30
Daniel Agar 829e88587b SITL unit tests don't run perf (#7367) 2017-06-06 17:28:30 -04:00
Marco Zorzi aef522553e unmanned ground vehicle (UGV) controllers and Traxxas Stampede configuration (#7175) 2017-06-06 13:26:51 -04:00
davidaroyer 184b190513 DF_MPU9250_Wrapper: move mag rotation prior to calibration application 2017-06-06 21:32:06 +05:30
Nicolae Rosia 6ddc0b3fef linux_gpio: open fd once, and reuse it
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-06-06 09:59:49 +02:00
Nicolae Rosia 92ac6f0c89 navio_adc: open fd once and reuse it
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-06-06 09:59:49 +02:00
Lorenz Meier 5f4fb744ca Uploader: Signal GCS or other connected devices that a FiFirmware upload is pending and requires device access. 2017-06-05 22:44:21 +02:00
Lorenz Meier e60fbccbee MAVLink app: Add ability to output packets for training and inspection 2017-06-05 22:44:21 +02:00
Daniel Agar 3aa502ba25 travis-ci remove code coverage build and upload (#7357) 2017-06-05 09:17:16 -04:00
Daniel Agar 833cdc9236 EKF2 update GPS and airspeed delay defaults (#7353)
* update ecl to latest

* EKF2_GPS_DELAY change default 200ms -> 110ms

 - 110msec is more representative of what most users are flying

* EKF2_ASP_DELAY change default 200ms -> 100ms

The EKF is relatively insensitive to airspeed sensor delays and the effective delay is installation specific, so it has been set to a value that does not cause the data buffers to be longer than is required to accomodate GPS delays.
2017-06-05 10:31:46 +10:00
Lorenz Meier 6fbf09d8da Fix LPE exception handling in ROMFS 2017-06-04 16:59:25 +02:00
Nacho Carnicero e6670d7926 Drone yaw set to destination waypoint yaw in LOITER mode if MIS_YAWMODE=0 (#7269)
* Drone does not change orientation while in LOITER mode if MIS_YAWMODE=0

* Fix code style

* Some more code style fixes

* Format checks passed
2017-06-04 20:01:40 +08:00
Lorenz Meier c80fd2c317 FMUv4: ENable PCA9685 driver so it is compiled at least in one config by default 2017-06-04 12:52:41 +02:00
Lorenz Meier ad05a6a7ec PCA9685 driver: Fix define 2017-06-04 12:52:18 +02:00
Lorenz Meier c9a28fc0eb ROMFS: Reset the estimator param to EKF2 if LPE fails to start 2017-06-04 12:43:28 +02:00
Daniel Agar 69ba69f30c controllib split blocks into separate files 2017-06-04 18:22:42 +08:00
Daniel Agar 3d6792c019 Block and SuperBlock minor cleanup 2017-06-04 18:22:42 +08:00
Daniel Agar 1671c32238 BlockParamExt replace with BlockParam reference types 2017-06-04 18:22:42 +08:00
Daniel Agar b03818cd0e controllib move old blocks to segway 2017-06-04 18:22:42 +08:00
Daniel Agar db816982cd px4params don't search recursively for params
- move controllib_test under controllib
2017-06-04 18:22:42 +08:00
CAI Dongcai 0dfd8cd039 Update fw_att_control_main.cpp
Make the declarations of the  variables "roll_sp, pitch_sp, yaw_sp, throttle_sp," in the main loop more readable.
2017-06-04 18:17:29 +08:00
Lorenz Meier d9dd1b231d UAVCAN server: Use correct MAVLink header version 2017-06-04 10:16:33 +02:00
Lorenz Meier 8c3b90007c MAVLink app: Enable protocol version handshaking
This allows the ground control station or any other communication partner to query the supported versions. The key aspect is to send the response in MAVLink 2 framing to test the link with a MAVLink 2 framed message.
2017-06-04 16:14:00 +08:00
Lorenz Meier 990ae93cae Version: Add MAVLink git hash to available versions 2017-06-04 16:14:00 +08:00
Lorenz Meier ea223505ae Tools: Add MAVLink libary git hash to exported symbols 2017-06-04 16:14:00 +08:00
Lorenz Meier 752623f26d Update MAVLink 2.0 headers to latest 2017-06-04 16:14:00 +08:00
Daniel Agar b4e2360070 uORB generation use constexpr (#7348) 2017-06-03 18:02:42 -04:00
Fredmcc 96cffd4077 Fixed some formatting 2017-06-04 04:43:07 +08:00
Fredmcc 4ffbaed500 Fixed GPS Date on frsky SPort 2017-06-04 04:43:07 +08:00
Fredmcc 90a05a0f55 Fixed SPort heading scale and sourced from vehicle_local_pos 2017-06-04 04:43:07 +08:00
Fredmcc 5290e6cfe1 Fixed SPort scale for GPS coords and Altitude 2017-06-04 04:43:07 +08:00
Beat Küng 0c3a34fb7f mavlink log handler: remove code to delete the msgs_ mavlink txt log files 2017-06-04 04:35:21 +08:00
Beat Küng a5485c97e0 mavlink: remove _log_enabled flag
It's obsolete since we removed the mavlink log file
2017-06-04 04:35:21 +08:00
Lorenz Meier e2fa5c2857 MAVLink: Remove status text output
The MAVLink app was logging the status to a file on the SD card, however, this has been integrated into the ulog format since. Having these in multiple locations is unnecessarily confusing to the user and induces load to the system.
2017-06-04 04:35:21 +08:00
davidaroyer 8be3985524 rc: remove unnecessary board ifdef 2017-06-04 04:24:50 +08:00
davidaroyer 7b5753f426 drivers: use relative path for ocpoc pwm out mixer file 2017-06-04 04:24:50 +08:00
davidaroyer 2b73c977a1 drivers: remove unnecessary compile flags 2017-06-04 04:24:50 +08:00
davidaroyer 59057184ce posix-configs: update ocpoc config file 2017-06-04 04:24:50 +08:00
davidaroyer 078d13e45e toolchains: remove unnecessary definition 2017-06-04 04:24:50 +08:00
davidaroyer 99799d83b1 ocpoc support: update copyright dates 2017-06-04 04:24:50 +08:00
davidaroyer 8e0b8314c6 drivers: move board specific device path to board_config.h 2017-06-04 04:24:50 +08:00
davidaroyer 68983f7ee2 fix code style 2017-06-04 04:24:50 +08:00
davidaroyer 0de70af78d mixers: add default mixer for Aerotenna OcPoC-Zynq hardware 2017-06-04 04:24:50 +08:00
davidaroyer 0b6fd4f8a2 rc: add support for Aerotenna OcPoC-Zynq hardware 2017-06-04 04:24:50 +08:00
davidaroyer 0510cd5992 drivers: add support for Aerotenna OcPoC-Zynq hardware 2017-06-04 04:24:50 +08:00
davidaroyer dbbe3c0863 commander: add support for Aerotenna OcPoC-Zynq hardware 2017-06-04 04:24:50 +08:00
davidaroyer a236bd1015 sensors: add support for Aerotenna OcPoC-Zynq hardware 2017-06-04 04:24:50 +08:00
davidaroyer 0e6db671da posix-configs: add support for Aerotenna OcPoC-Zynq hardware 2017-06-04 04:24:50 +08:00
davidaroyer c5ac73e87e cmake: add support for Aerotenna OcPoC-Zynq hardware 2017-06-04 04:24:50 +08:00
Julien Lecoeur 70ccfe80a7 Fuse flow only if it is activated in param LPE_FUSION 2017-06-04 04:20:46 +08:00
Simone Guscetti a64e9bfa03 tap_esc: add board_config.h for completeness 2017-06-04 04:20:05 +08:00
Simone Guscetti d59e9e2958 tap_esc: minor refractoring
- the definition of ESC_HAS_CURRENT_SENSOR is now in drv_tap_esc
- add tap_esc_common move crc table there
- header guards are applied to the header files
2017-06-04 04:20:05 +08:00
Daniel Agar 625dc67f84 commander offboard loss rc act unreachable
- coverity fix 145492
2017-06-04 02:37:09 +08:00
Daniel Agar beaa758605 lcov ignore src/examples (#7341) 2017-06-02 23:22:50 -04:00
Daniel Agar 24b26e53b9 cmake organize code coverage handling and base 2017-06-02 19:35:18 -04:00
Daniel Agar 17c1114b3e clang-tidy readability-named-parameter 2017-06-02 19:35:18 -04:00
Daniel Agar 0d0cbd8243 clang-tidy ignore cert-flp30-c only in tests 2017-06-02 19:35:18 -04:00
Daniel Agar 94f5df8611 param and pwm ignore -Warray-bounds for clang 2017-06-02 19:35:18 -04:00
Daniel Agar 17a3b195fa cppcheck start with errors only 2017-06-02 19:35:18 -04:00
Daniel Agar de9c39447c cppcheck ignore examples 2017-06-02 19:35:18 -04:00
Daniel Agar c56df948ee mathlib expo template style 2017-06-02 19:35:18 -04:00
Daniel Agar 78205b25c9 gyrosim remove unused work handle 2017-06-02 19:35:18 -04:00
Daniel Agar e4f55e4526 travis-ci upload cppcheck, scan-build, and coverage to s3 2017-06-02 19:35:18 -04:00
Daniel Agar 1ebe215c60 check_submodules.sh only sync selected submodule 2017-06-02 19:35:18 -04:00
Daniel Agar 5d626bd940 clang-tidy remove redundant init 2017-06-02 19:35:18 -04:00
Daniel Agar 8a681397bf travis-ci lazy init submodules 2017-06-02 19:35:18 -04:00
Daniel Agar 768faa1ae3 clang-tidy param avoid malloc(0) 2017-06-02 19:35:18 -04:00
Daniel Agar 2e0ed3b47b travis-ci add cppcheck 2017-06-02 19:35:18 -04:00
Daniel Agar 560bfd2b00 clang-tidy only list excluded checks 2017-06-02 19:35:18 -04:00
Daniel Agar f1079e3382 mission block remove unread value 2017-06-02 19:35:18 -04:00
Daniel Agar 4e21b2378f travis-ci coverity optimization 2017-06-02 19:35:18 -04:00
Daniel Agar ef7295affb travis-ci split quick_check into tests and check_format 2017-06-02 19:35:18 -04:00
Daniel Agar 5434ae670b OSX build travis-ci -> circleci 2017-06-02 19:35:18 -04:00
Daniel Agar d731558286 Makefile prepare to split qgc_firmware 2017-06-02 19:35:18 -04:00
Daniel Agar 621651fefa travis-ci quick_check replaces check_format and tests 2017-06-02 19:35:18 -04:00
Daniel Agar 0ac237f3df travis-ci coverity abort early 2017-06-02 19:35:18 -04:00
Daniel Agar 6a249c742b travis-ci add tests coverage to coveralls 2017-06-02 19:35:18 -04:00
Daniel Agar a3078c63ab travis-ci stop deploying to s3 2017-06-02 19:35:18 -04:00
Daniel Agar 64ed96d81a clang-tidy readability-simplify-boolean-expr 2017-06-02 19:35:18 -04:00
Daniel Agar 3c06641897 clang-tidy config list all checks 2017-06-02 19:35:18 -04:00
Daniel Agar fffd3d4c4c clang-tidy ignore google-global-names-in-headers and misc-redundant-expression 2017-06-02 19:35:18 -04:00
Daniel Agar 180ec59255 clang-tidy ignore mathlib assignment signatures for now 2017-06-02 19:35:18 -04:00
Daniel Agar 6e1113ae4d clang-tidy mathlib remove redundant void 2017-06-02 19:35:18 -04:00
Daniel Agar e112161a04 clang-tidy fix mathlib headers and format 2017-06-02 19:35:18 -04:00
Daniel Agar ac4a706da0 build system fixes and improvements
- deploy px4 metadata using target
 - clang scan-build upload output to s3
 - clang-tidy properly check headers
 - add cppcheck helper
 - force gcc color
2017-06-02 19:35:18 -04:00
Julian Oes 723a6bf6ac mavlink: new MAV_CMD_IMAGE_START_CAPTURE spec
The spec of the mavlink command MAV_CMD_IMAGE_START_CAPTURE has changed.
2017-06-03 02:53:58 +08:00
Mohammed Kabir 0cb3eb99dc sensors : correctly handle internal magnetometer rotations 2017-06-03 02:16:58 +08:00
Lorenz Meier 0b43546c6a BMI055: Ensure the accel driver sets the device ID in the report 2017-06-02 18:44:21 +02:00
Lorenz Meier aecfe38f65 BMI055: Allow the independent use of just the gyro driver 2017-06-02 18:41:54 +02:00
Lorenz Meier d12421b9eb BMI055: Ensure gyro device ID gets copied to report 2017-06-02 18:41:32 +02:00
Lorenz Meier 49b1bd597e FMUv4 config: Ensure enough stack space in user main function
There was enough margin with 200 bytes, but this change widens that to the default of 300.
;
2017-06-02 18:31:50 +02:00
Lorenz Meier 5e1490b8a1 BMI055: Ensure that accel and gyro start consistently.
This was required on a BOSCH board which otherwise could end up mis-detecting the 055 and not running properly
2017-06-02 18:30:51 +02:00
Lorenz Meier 9736c08e49 uORB listener: Expand command to allow selecting the instance to print
listener sensor_gyro 1 2

will now print one report of the third gyro (index 2). The syntax needs further polishing, but this is a valid intermediate step.
2017-06-02 18:30:01 +02:00
Lorenz Meier b1670e7e6c BMI160 driver: Minor code style fix 2017-06-02 18:28:48 +02:00
Daniel Agar 7b861572a5 travis-ci fix s3 metadata upload (#7321) 2017-05-30 21:17:58 -04:00
ChristophTobler 680cebcb08 fix qgc flow takeoff -> use min takeoff alt if no home position 2017-05-30 10:22:09 +02:00
bresch cdd7c57ded Multicopter mixer: When saturating, compute the new yaw value based on
the reduced thrust value
2017-05-30 12:01:42 +07:00
Nicolae Rosia a0ee07e357 commander: enable partial preflight checks on RPI
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-05-29 21:38:21 +02:00
Simone Guscetti 6201fb5641 commander: arming with critical battery is not allowed 2017-05-29 18:40:57 +08:00
Lorenz Meier 29b0043455 Update README 2017-05-27 13:49:45 +02:00
Lorenz Meier a9ad826b08 Commander: Relax gyro consistency check as users without temperature compensation do suffer from it. 2017-05-27 13:43:57 +02:00
Mohammed Kabir ed5cf9f729 commander : simplify platform defines 2017-05-27 00:31:05 +02:00
Mohammed Kabir 49890c61f5 sensors : require reboot for all sensor orientation changes 2017-05-27 00:31:05 +02:00
Mohammed Kabir 62b7645130 sensors : remove deprecated (since 2015) mag rotation parameter 2017-05-27 00:31:05 +02:00
Mohammed Kabir 6ee09ca16f sensors : map between driver rotation order and uORB instance order when recieving first mag message 2017-05-27 00:31:05 +02:00
Mohammed Kabir 769fa7134a commander : make gyro calibration correctly lock-in to corresponding uORB topic 2017-05-27 00:31:05 +02:00
Mohammed Kabir 937efd3472 commander : make accel calibration correctly lock-in to corresponding uORB topic 2017-05-27 00:31:05 +02:00
Mohammed Kabir 302e2372cf mpu9250 : fill correct device ID into uORB topic 2017-05-27 00:31:05 +02:00
Mohammed Kabir d7611cac89 commander : make mag calibration correctly lock-in to corresponding uORB topic 2017-05-27 00:31:05 +02:00
Mohammed Kabir 52f1718bb8 commander : warn if excess accels are connected 2017-05-27 00:31:05 +02:00
Mohammed Kabir d177ccc9a7 commander : warn if excess gyros are connected 2017-05-27 00:31:05 +02:00
Mohammed Kabir a11ef6be10 lis3mdl : fill device ID, scale and range into uORB topic properly 2017-05-27 00:31:05 +02:00
Mohammed Kabir f97822155a rc.sensors : start external compass on v4Pro and v5 with temperature compensation and self-calibration at startup 2017-05-27 00:31:05 +02:00
Daniel Agar dde605fc4a Tools/docker_run.sh pick appropriate container if not set (#7297) 2017-05-26 09:28:37 -04:00
Daniel Agar 1b2c54836f nuttx-patches FATAL_ERROR if patch isn't included 2017-05-25 13:28:10 -04:00
David Sidrane 6b3a665e33 Backport Upstream SDIO 1-bit and 16G Size Fixes
This backports upstrem NuttX
    ea7b673 - Allow dma in 1 bit mode in STM32F4xxx
    17cbec1 - fix warning from ea7b673
    4795d58 - Only the decoded.oid    = (cid[0] >> 8) change.
2017-05-25 13:28:10 -04:00
David Sidrane 635d861b76 Backport Upstream SDIO 1-bit and 16G Size Fixes
This backports upstrem NuttX
  ea7b673 - Allow dma in 1 bit mode in STM32F4xxx
  4795d58 - Only the decoded.oid    = (cid[0] >> 8) change.
2017-05-22 21:48:49 +02:00
Lorenz Meier 05b21958e7 Update README.md
Refresh team list.
2017-05-20 11:02:17 +02:00
David Sidrane 6bf19d2a06 BACKPORT of upstream NuttX stm32_serial: fix freezing serial port.
Thanks to Jussi Kivilinna

   https://bitbucket.org/nuttx/nuttx/commits/9169ff6a15fe65ba4af134b470dbf89220274c19

   stm32_serial: fix freezing serial port.  Serial interrupt enable/disable functions
   do not disable interrupts and can freeze device when serial interrupt is received
   while execution is at those functions.

   Trivially triggered with two or more threads write to regular syslog stream and to
   emergency stream. In this case, freeze happens because of mismatch of priv->ie
   (TXEIE == 0) and actually enabled interrupts in USART registers (TXEIE == 1),
   which leads to unhandled TXE interrupt and causes interrupt storm for USART.
2017-05-20 10:26:20 +02:00
Paul Riseborough ec3fe09602 ekf2: format fix 2017-05-20 10:24:08 +02:00
Paul Riseborough 889fb30029 ekf2: Improve control of magnetometer bias learning
Adds parameters so that the motion checks used to switch between magnetic yaw and 3-axis fusion can be adjusted.
Modifies the check used to determine if learned mag biases  can be saved. A cumulated calibration time is used rather than continuous calibration time to allow for for switching in and out of 3-axis fusion mode that is required to do calibration.
2017-05-20 10:24:08 +02:00
Paul Riseborough aa69ae0ee6 ekf2: Add preflight checking of velocity and height innovations
Filters the vertical position and 3-axis velocity innovations and sets the local and global position as invalid if they exceed limits during ARMING_STATE_STANDBY.
2017-05-20 10:24:08 +02:00
Paul Riseborough 2d34a3e096 ekf2: monitor estimator time slip
Used to check if the ekf2 module is failing to keep up with the IMU data
2017-05-20 10:24:08 +02:00
Paul Riseborough e2242f87c9 msg: update estimator_status
Reduce unnecessary length of state and covariance arrays
Add time slip monitor
2017-05-20 10:24:08 +02:00
Paul Riseborough e7a225bf48 ecl: use latest master 2017-05-20 10:24:08 +02:00
Kevin Lopez Alvarez cdf941e78b Fix code style 2017-05-20 10:23:28 +02:00
Kevin Lopez Alvarez 588a8d3841 px4fmu-v4pro : Add support for ICM20602 2017-05-20 10:23:28 +02:00
Lorenz Meier 74b0e485e7 MAVLink stream: Ensure the message is not sent again if it was already dispatched. 2017-05-19 10:34:43 +02:00
Lorenz Meier c84611f0f5 MAVLink: Fix rate handling for camera trigger messages 2017-05-19 10:34:43 +02:00
Nicolae Rosia ee637952ba aerofc_adc: fix error handling in init
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-05-19 10:34:18 +02:00
Kabir Mohammed 410577bb27 Update README.md 2017-05-19 10:13:39 +02:00
Lorenz Meier 2ad92dd144 Update README.md
Added maintainers / corrected formatting.
2017-05-19 10:10:55 +02:00
Lorenz Meier 6094ceade1 Update README.md 2017-05-19 10:08:10 +02:00
Lorenz Meier 654a8cb43a Update README.md 2017-05-19 10:07:54 +02:00
Luís Felipe Strano Moraes 9935aeba16 Add Jose as maintainer for Intel Aero.
With great power comes great responsibility!
2017-05-19 08:43:49 +02:00
Nicolae Rosia 7d1dfb37a5 linux_gpio: pin should be unsigned int
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-05-18 23:09:44 +02:00
Nicolae Rosia 99d4f70ef8 linux_gpio: check if pin is already exported
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-05-18 23:09:44 +02:00
Nicolae Rosia b82a0f988e linux_gpio: use nullptr
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-05-18 23:09:44 +02:00
Nicolae Rosia 4af7036a8a replace navio_gpio with linux_gpio
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-05-18 23:09:44 +02:00
Beat Küng 3d77102653 mavlink_main: remove MISSION_ITEM from streams configuration 2017-05-18 09:48:14 +02:00
Beat Küng 2a79ddd621 MavlinkLogHandler: increase MAX_BYTES_SEND to 256kb
It increases the throughput on UDP (from around 2Mb to 2.5Mb), while the
rate via USB & telemetry stay the same.
2017-05-18 09:48:14 +02:00
Beat Küng a89980f440 MavlinkParametersManager: update sending rate
This is an adjustment due to the changed calling frequency of send()
(was 300 Hz, is now 100 Hz)
2017-05-18 09:48:14 +02:00
Beat Küng cfa61c5841 MavlinkReceiver: add mission manager, param manager, ftp and log handler
This makes also a slight stack size increase necessary (was 284 bytes left)
2017-05-18 09:48:14 +02:00
Beat Küng d70caeb24b MavlinkParametersManager: remove MavlinkStream inheritance 2017-05-18 09:48:14 +02:00
Beat Küng a761c4189e MavlinkMissionManager: remove MavlinkStream inheritance 2017-05-18 09:48:14 +02:00
Beat Küng 99b29777ba MavlinkLogHandler: remove MavlinkStream inheritance 2017-05-18 09:48:14 +02:00
Beat Küng e6c3b29aa6 MavlinkFTP: remove MavlinkStream inheritance 2017-05-18 09:48:14 +02:00
Beat Küng 78c1f51f11 mavlink main: remove mission_manager, param manager, ftp & log handler
Will be moved to the receiver thread
2017-05-18 09:48:14 +02:00
Beat Küng 4105394234 mavlink_receiver: check for allocation failure
Also remove the start() declration (there's no definition of that)
2017-05-18 09:48:14 +02:00
Beat Küng 2c548f84a7 refator mavlink: prefix class members with _ 2017-05-18 09:48:14 +02:00
Daniel Agar ef5bc526de Tools/ecl_ekf mark executable 2017-05-17 09:02:52 +02:00
David Sidrane 3c62f7a3eb stm32:drv_input_capture bug fixes.
Filter for channel 4 was modifying channel 1
   capture and overflow reads were using wrong paramaters
   in macros and addressing junk in memory.
   up_input_capture_get_filter was shifing results the wrong way.
2017-05-17 08:34:57 +02:00
David Sidrane a15b8565ef Removed wrong comment 2017-05-17 08:34:57 +02:00
Lorenz Meier 9be5193965 Navigator: Fix RTL command lnd logic for missions
The navigator was sending RTL commands in the wrong circumstances leading to a cycle between Navigator and Commander.
2017-05-16 08:40:53 +02:00
Dennis Mannhart 32685338c9 mc_pos_control: simplify transition with just using triplets 2017-05-15 15:41:47 +02:00
Dennis Mannhart a98c0ef25d mc_pos_control: during transition set vel_sp to zero 2017-05-15 15:41:47 +02:00
Dennis Mannhart 1ee160a5ff navigator takeoff: use global yaw instead of home yaw 2017-05-15 15:41:47 +02:00
ChristophTobler 14f860090a remove empty line and fix typo 2017-05-15 15:41:47 +02:00
Dennis Mannhart 00c9e4b79f mc_pos_control: set triplets.valid to first time when landed 2017-05-15 15:41:47 +02:00
Dennis Mannhart 9e383f2cd3 navigator: when landed only exit idle if mission/takoff 2017-05-15 15:41:47 +02:00
Nicolae Rosia a55f97503e navio_adc: fix formatting
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-05-14 17:51:02 +02:00
Nicolae Rosia 5467beed93 posix-configs rpi: add default values for Navio2 Power Module
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-05-14 17:51:02 +02:00
Nicolae Rosia 32498009a3 navio_adc: add driver for Navio2 ADC
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-05-14 17:51:02 +02:00
Lorenz Meier 31006eb43c Update SITL repository 2017-05-14 15:53:31 +02:00
Mohamed Abdelkader Zahana cd1e04d43c support of multi uav simulation in SITL 2017-05-14 15:46:18 +02:00
Lorenz Meier 669e580f0a Land detector max altitude: Adjust max limit 2017-05-14 14:24:06 +02:00
Lorenz Meier cdb8146af5 Land detector: Choose a default alt limit parameter value that ensures regular users are not running into it 2017-05-14 13:27:57 +02:00
yaoling 3ad23a44c5 navigator fix takeoff insidetime = 0 (#7199) 2017-05-13 12:16:55 -04:00
Lorenz Meier 55697e08e2 GPS driver: Add more stack to suit data definition increases 2017-05-13 11:44:49 +02:00
Daniel Agar 447bea3ce0 circleci completely remove git submodules 2017-05-12 22:11:17 +02:00
Mohammed Kabir 773d1ec6a8 camera_feedback : only use global position subscription to fill geotagging packet 2017-05-12 22:11:17 +02:00
Mohammed Kabir c623e64f96 camera_trigger : remove relocated feedback parameter 2017-05-12 22:11:17 +02:00
Mohammed Kabir ad5fe5f44a Add support for SET_CAMERA_MODE command; Not used yet. 2017-05-12 22:11:17 +02:00
Mohammed Kabir 2a057c6f79 Update MAVLink submodule 2017-05-12 22:11:17 +02:00
Mohammed Kabir 6a38118c73 camera_trigger : reset distance counters to ensure consistent triggering after pausing/disabling 2017-05-12 22:11:17 +02:00
Mohammed Kabir 0b93568aa3 camera_trigger : add transitional support for QGC 2017-05-12 22:11:17 +02:00
Mohammed Kabir 83888e3e7f camera_feedback : move class definitions into hpp 2017-05-12 22:11:17 +02:00
Mohammed Kabir 97ceaf404c camera_trigger : remove debugging 2017-05-12 22:11:17 +02:00
Mohammed Kabir b146e7afde logger : log geotagging packet 2017-05-12 22:11:17 +02:00
Mohammed Kabir a19a5804e7 cmake configs : add camera_feedback module 2017-05-12 22:11:17 +02:00
Mohammed Kabir d79750a06c camera_feedback : inital module import 2017-05-12 22:11:17 +02:00
Mohammed Kabir 192e8b48d1 mavlink : send camera_image_captured message 2017-05-12 22:11:17 +02:00
Mohammed Kabir b665737aca camera_trigger : do not log test shots from GCS 2017-05-12 22:11:17 +02:00
Mohammed Kabir 2e92a3946d camera_trigger : completely refactor state handling 2017-05-12 22:11:17 +02:00
Lorenz Meier 7af7c86384 mavlink : send camera capture information 2017-05-12 22:11:17 +02:00
Mohammed Kabir de19af456d msg : add camera feedback message 2017-05-12 22:11:17 +02:00
Dennis Mannhart 29795fa95f mc_pos_control: switch to auto only if triplets have been updated 2017-05-09 11:54:50 +02:00
lovettchris 47faaa5d78 Add loiter option to COM_OBL_RC_ACT (#7170) 2017-05-08 14:17:29 -04:00
Paul Riseborough 341bd6e836 commander: add timeout test for global position data 2017-05-08 09:21:38 +02:00
Paul Riseborough 00a42abc69 commander: Add parameter to control postal fallback after loss of navigation accuracy
Also remove else if branch that cannot be accessed.
2017-05-08 09:21:38 +02:00
Paul Riseborough b85c8fa135 commander: fix bug in pos vel validity transition
This ensures that a mode change will occur immediately when the EKF reports the solution as invalid.
2017-05-08 09:21:38 +02:00
Lorenz Meier d31ee73354 FMUv5: Set sdlog mode param 2017-05-07 18:02:24 +02:00
Lorenz Meier 68e76d8ed3 FMUv5: Increase logging throughput considerably.
This will help to understand the sensor selection on FMUv5 in different airframes. We do have the RAM and CPU to do this on this platform.
2017-05-07 18:01:51 +02:00
Lorenz Meier 981dac8e95 Navigator: Increase RAM size 2017-05-06 12:34:28 +02:00
Lorenz Meier 0dac78b48f FMUv4PRO and FMUv5: Enable auto-build 2017-05-05 18:11:44 +02:00
Lorenz Meier da566506eb MAVLink: Update submodule for new versions 2017-05-05 14:24:47 +02:00
Lorenz Meier dc2a2a9552 IO: Better formatting 2017-05-04 22:57:47 +02:00
Julian Oes bcd66f1408 mc_pos_control: ignore a NaN/inf position setpoint (#7186)
* mc_pos_control: ignore a NaN/inf position setpoint

This is a hotfix that prevents the position controller from trying to
do velocity control with a position setpoint that isn't valid in the
first place.

This is only a workaround, ideally the controls later should not scale
down throttle to the minimum just because the position setpoint is far
away if they still have valid setpoint in z.

* mc_pos_control: use PX4_ISFINITE and not isfinite
2017-05-04 22:55:53 +02:00
Lorenz Meier 1bb56e775e IO: Fix access to free memory
The free memory was accessed from interrupt context where it should not be accessed from. We build the statistic now at a fixed rate while not armed.
2017-05-04 22:32:52 +02:00
Beat Küng 8bfa84f73f log_writer_file: make sure to close the file
and avoid doing a loop iteration when the thread is requested to exit
(as it could access _buffer).
2017-05-04 08:44:11 +02:00
Nate Weibley 50740ef813 Improve FW landing predictability
- Use the course over ground as loiter exit criteria (better wind behavior)
 - Compute the tangent origin coordinate explicitly instead of using immediate position
2017-05-04 07:51:46 +02:00
Lorenz Meier 3d2d6c4fdc IO: Add lazy atomic OR, AND and CLEAR functions for flags
IO needs atomic updates of a few critical status flags, but doing these always atomic (with interrupts disabled) might cause a too high interrupts disabled interval. In order to avoid this only operations that change the state of the target variable are done with interrupts disabled, while operations without an effect on the target variable are not executed.
2017-05-04 07:46:57 +02:00
Werner Stern dc6b688a6a fixed px4io firmware read-modify-write bug 2017-05-04 07:46:57 +02:00
Lorenz Meier 65baf99832 Logger hotfix: Allocate buffer on logging
This enables to use the RAM normally consumed by the log buffer to be used for calibration and other memory-intense tasks.
These run typically only disarmed when logging is not enabled.
2017-05-03 21:52:04 +02:00
ChristophTobler dce28454c8 use current local position for land and not GPS -> e.g. flow 2017-05-03 16:52:37 +02:00
Paul Riseborough 5bfe6d7fec ekf2: Fix failure to save mag declination 2017-05-03 08:37:14 +02:00
Paul Riseborough 0d7f475bd0 ecl: minor updates
Initialisation changes to address valgrind errors
Change to default GPS and Airspeed time delay (these are overwritten by ekf2_main parameter settings)
Increase sensitivity of bad accelerometer checks
2017-05-03 08:37:14 +02:00
Paul Riseborough b64e40b5da ekf2: format fixes 2017-05-03 08:37:14 +02:00
Paul Riseborough 1a2ef45a4b commander: remove unused pos vel validity check functions 2017-05-03 08:37:14 +02:00
Paul Riseborough 625cc4aa83 commander: Use generic function for checking position and velocity validity 2017-05-03 08:37:14 +02:00
Paul Riseborough 46ece548cd ekf2: Changes following code review 2017-05-03 08:37:14 +02:00
Paul Riseborough 8421ad3dfd commander: Changes following code review 2017-05-03 08:37:14 +02:00
Paul Riseborough 57de9eccf5 msg: Code review recommendations for estimator_status 2017-05-03 08:37:14 +02:00
Paul Riseborough 6473f1458f commander: reset learned ekf2 mag biases when performing a mag cal
The learned ekf2 mag bias values are invalidated when the sensor calibration is updated and must be reset.
2017-05-03 08:37:14 +02:00
Paul Riseborough 6474922224 ekf2: Save learned magnetometer biases 2017-05-03 08:37:14 +02:00
Beat Küng b4178e0388 BlockParam: add BlockParam::commit_no_notification() 2017-05-03 08:37:14 +02:00
Paul Riseborough 3bcb710da9 voted_sensors_update: publish sensor selections (+3 squashed commits)
Squashed commits:
[290660d] voted_sensors_update: revert the new_accel_data check (and others)

The check removed the ability to detect sensor timeouts.
[c8dc7ad] sensors: publish changes to sensor selection
[dd90dec] sensors: ensure all sensor selections published first time
2017-05-03 08:37:14 +02:00
Paul Riseborough 3d3e04cb48 msg: create uORB topic for sensor selection data 2017-05-03 08:37:14 +02:00
priseborough 8ea0b2d3c5 commander: rework posvel validity checks
Move into functions.
Reset probation time and recalculate checks if a mode change is demanded to give the operator ability to regain control as soon as possible after nav performance is regained. (+11 squashed commits)
Squashed commits:
[a4bb800] commander: enable pilot to quickly recover from loss of position accuracy
[19e16a0] commander: rework postal probation time
[f96284e] commander: rework bad pos and vel test probation time
[00d5f0c] commander: Allow EKF preflight checks to pass with moving vehicle

Separates the 'is using GPS' and the GPS quality checks.
Uses a reasonable subset of the GPS quality checks which allows checks to pass if the vehicle is moving.
[4cdfb5c] commander: remove unused variable
[349385a] commander: add EKF GPS quality checks to pre-arm checking

Only perform check if GPs checking is activated by parameter setting.
Display fault messages that makes it clear if EKF quality checks are failing or the EKF is not using GPS for another reason. We do not want to confuse this with GPS lock.
[340ae29] commander: make position invalid fail-safe more sticky

Require check to pass for 7 seconds before exiting failsafe. This is required because if GPs is failing innovation tests for a prolonged period, the EKF will periodically reset to the GPS and report good accuracy at the time of reset.
Adding this delay gives time for an underlying error condition (eg bad IMU or compass) to be re-detected.
[b04ac95] commander: Increase RAM allocation to eliminate low stack warnings
[9dca12f] commander: add missing position invalid fail-safe responses
[69f264d] commander: Update position invalid fail-safe responses

Replace separate logic for each case with a generic function
Add velocity checks.
[8e8cef1] commander: rework position validity checks

Consolidate existing checks for global and local position validity and add checking of velocity accuracy.
Enable checks to be bypassed using the CBRK_VELPOSERR parameter.
2017-05-03 08:37:14 +02:00
Paul Riseborough 40160c4488 integrationtests: add wait time before arming to allow checks to pass 2017-05-03 08:37:14 +02:00
priseborough 519e903347 systemlib: Add circuit breaker parameter for position error checks 2017-05-03 08:37:14 +02:00
priseborough e61e733d1d local_position_estimator: publish placeholder values for velocity accuracy 2017-05-03 08:37:14 +02:00
priseborough 3680057e6d ekf_att_pos_estimator: publish placeholder values for accuracy reporting 2017-05-03 08:37:14 +02:00
priseborough 68c1ffd3e5 position_estimator_inav: publish placeholder values for velocity accuracy 2017-05-03 08:37:14 +02:00
priseborough 1f5908786e ekf2: don't publish estimator status and innovations unless updated 2017-05-03 08:37:14 +02:00
priseborough fb6e050b06 ekf2: Improve error reporting
Add missing velocity accuracy reporting
Add missing dead reckoning reporting
2017-05-03 08:37:14 +02:00
Lorenz Meier 9efb1a59f2 msg: Add GPS check fail definitions to estimator_status 2017-05-03 08:37:14 +02:00
priseborough e9a3eca751 msg: add velocity accuracy reporting to local position topic 2017-05-03 08:37:14 +02:00
priseborough d0d2c9dcba msg: add velocity accuracy reporting to global position topic 2017-05-03 08:37:14 +02:00
David Sidrane e86d9adb93 px4fmu-v4:Implement board_on_reset API
Added board_on_reset, to force timer GPIO to output low on reset
   This will stop the motors.
2017-05-03 08:33:05 +02:00
David Sidrane e967c2b340 board_common:Added new API point board_on_reset
This optionally provided function called on entry to
  board_system_reset. It should perform any house keeping
  prior to retunring to do the rest.
2017-05-03 08:33:05 +02:00
David Sidrane 33f2897f00 px4fmu-v4:Configure timer IO pins with pull downs
When the CCER is cleared the IO pin tends to float. The FMUV4
  HW has no TXS0108 and if cut off while high will decay.

  By adding the pull down the pins will seek the low state faster.
  13.8 us from off to decabe below threshold.
2017-05-03 08:33:05 +02:00
Lorenz Meier be375e25d3 Update GPS driver submodule. Fixes #7173 2017-05-03 08:30:29 +02:00
David Sidrane 95fd2cd184 Create NuttX git hash and tag 2017-05-03 08:18:47 +02:00
David Sidrane f66f024e3a ver:Print vMM.mm.pp format 2017-05-03 08:18:47 +02:00
David Sidrane bf570dee2f Added use of SPI_LOCK in the ms5611 driver on any HW where the
PX4_SPI_BUS_BARO == PX4_SPI_BUS_RAMTRON
2017-05-03 08:17:12 +02:00
David Sidrane 6aadc75d18 Removed interrupt based locking on FMUv4 HW
The ramtron driver already calls SPI_LOCK when accessing the
  FRAM.

  Removed the interrupt lockout and anabled the SPI_LOCK
  in the ms5611 driver on any HW where the
  PX4_SPI_BUS_BARO == PX4_SPI_BUS_RAMTRON
2017-05-03 08:17:12 +02:00
Lorenz Meier 00efbc8049 ROMFS: Start EKF2 if no vehicle config is loaded
This allows to at least have a look at the attitude and check that the board is functional on a basic level.
2017-05-02 11:56:45 +02:00
David Sidrane 5d70f74e36 px4fmu-v4:SPI and init clean up 2017-05-02 11:55:11 +02:00
Henry Zhang 92fc82da33 MindPX: Remove MPU6500 driver, use MPU9K driver instead 2017-05-02 11:52:12 +02:00
Lorenz Meier 40eb5df8de UAVCANCAN: Better param documentation and reboot requirements where appropriate 2017-05-02 07:42:14 +02:00
Lorenz Meier dbf754eab1 ROMFS: If UAVCAN is enabled, reduce log buffer size
This is necessary to make the space for UAVCAN in memory and doing it this way avoids negatively impacting users who do not use UAVCAN.
2017-05-02 07:42:14 +02:00
David Sidrane 3ecb07f5db px4io-v1:Sync with px4io-v1 CONFIG_USERMAIN_STACKSIZE 2017-05-02 07:40:50 +02:00
David Sidrane f77a9bb897 px4io-v1:Limit CONFIG_USART1_TXBUFSIZE to max debug size 2017-05-02 07:40:50 +02:00
David Sidrane 0d7c290f89 px4io-v1:Reduce Number of tasks and name 2017-05-02 07:40:50 +02:00
David Sidrane de9e63d506 px4io-v1:Refreshed defconfig (no changes) 2017-05-02 07:40:50 +02:00
David Sidrane 8cce1bd078 px4io-v2:Reduce Number of tasks and name 2017-05-02 07:40:50 +02:00
David Sidrane 3eb909823e px4io-v2:Limit CONFIG_USART1_TXBUFSIZE to max debug size 2017-05-02 07:40:50 +02:00
David Sidrane 85973f69d7 px4io-v2:Refreshed defconfig (no changes) 2017-05-02 07:40:50 +02:00
David Sidrane 05ceeec1ba piofirmware:Base the debug message buffer size on the defconfig
Recover 16 bytes. Size of debug max message is 40 so limit
  the usart tx buffer to same size.
2017-05-02 07:40:50 +02:00
David Sidrane f7835a8677 io_timer driver:Only support capture if DIRECT_INPUT_TIMER_CHANNELS > 0
This removes the unused input capture capabilities from the px4io
   and saves 128 bytes of ram.
2017-05-02 07:40:50 +02:00
Lorenz Meier d1dd6a16f2 IO v2: disable interrupt stack
This avoids burning significant memory in a configuration that is not actually using parallel tasks
2017-05-02 07:40:50 +02:00
Lorenz Meier 60a022329f IO Firmware: Use new RC lib format 2017-05-02 07:40:50 +02:00
Lorenz Meier 71731d17a9 RC C library: Use same buffer as the protocols do not decode in parallel. 2017-05-02 07:40:50 +02:00
Lorenz Meier 118b9aad19 MC pos control: Document the reference update handling function better 2017-05-01 17:23:11 +02:00
Paul Riseborough 9983bf2364 ekf2: fix errors in publishing of local position origin validity flags 2017-05-01 17:23:11 +02:00
Paul Riseborough 7c068e83d8 msg: correct definitions for local position origin validity flags 2017-05-01 17:23:11 +02:00
Lorenz Meier b039f61762 Check code style: Be more permissive on Astyle 2017-05-01 16:56:13 +02:00
Lorenz Meier 875a35fcd5 GPS: FIncrease stack by 100 bytes
The app reached the check limit and needed a bit more headroom.
2017-04-30 12:03:14 +02:00
Mohammed Kabir 6a99ca70e9 camera_trigger : clarify power control comment 2017-04-30 12:00:06 +02:00
Mohammed Kabir 3ba0275952 camera_trigger : switch to queued publisher 2017-04-30 12:00:06 +02:00
Mohammed Kabir b5ce55bab6 camera_trigger : don't advertise garbage 2017-04-30 12:00:06 +02:00
Mohammed Kabir 3ebfb0cd27 camera_trigger : optimize GCS test command handling 2017-04-30 12:00:06 +02:00
Daniel Agar 0a80ee6c20 OSX builds travis-ci -> circleci (#7157) 2017-04-28 21:08:29 -04:00
Daniel Agar 6ec2ff91af README update links and cleanup 2017-04-28 23:16:27 +02:00
Daniel Agar b3402214f9 README add state estimation label (#7154) 2017-04-28 13:21:31 -04:00
Daniel Agar 5228f70f44 README add MindPX contact (#7153) 2017-04-28 13:21:10 -04:00
ChristophTobler 6c15666368 ekf2: accept min/max range 2017-04-27 21:15:47 +02:00
Khoi Tran 1b7838c2fe Implement Mavlink PLAY_TUNE 2017-04-27 14:48:25 +02:00
Matthias Grob 0c4719de3e mc_pos_control: smooth takeoff, fixed gradient of the velocity ramp by takeoff speed parameter
because we need a workaround for the broken auto takeoff logic which can start the vehicle with a loiter setpoint
in this case the very first moment is still a jump but then it gets taken over by the fix gradient ramp
this can basically be reverted after the auto takeoff logic is fixed
2017-04-27 14:05:20 +02:00
Matthias Grob b5820afa14 mc_pos_control: smooth takeoff, fixed ramp reset bug and takeoff speed limiting condition
currently when the vehicle is landed again (not after bootup) the core position controller does not run anymore
therefore the velocity limit ramp in some cases did not get reset correctly

speed limiting in auto takeoff mode only needs to be limited when the user did not take over
2017-04-27 14:05:20 +02:00
Matthias Grob 9a162a24bb mc_pos_control: improved smooth takeoff and used it for manual takeoff as well
adresses:
there were setpoint twitches at the beginning and end of my smooth takeoff routine
it was to slow and not configurable
it was only available for automatic takeoff
2017-04-27 14:05:20 +02:00
Matthias Grob 75872b0713 mc_pos_control: switched auto takeoff to clean position control to takeoff point with gradual velocity limit
auto takeoff  was pretty chaotic and bypassed the velocity controller until some magic condition
the goal of this approach is to make the behaviour and smoothness more predictable and reuse the exact same logic for manual takeoff
2017-04-27 14:05:20 +02:00
Matthias Grob 5fd6bfc18c mc_pos_control: reorder velocity setpoint limiting, adding comments 2017-04-27 14:05:20 +02:00
Matthias Grob f5964ec237 mc_pos_control: pure refactor, reduce one level of indentation in calculate_thrust_setpoint 2017-04-27 14:05:20 +02:00
Matthias Grob 40d058558b mc_pos_control: pure refactor, split up core position control into velocity and thrust setpoint generation 2017-04-27 14:05:20 +02:00
Matthias Grob fac34de11e mixer_multirotor: switched to math::constrain (#7073)
- a local implementation was used before which is not necessary
2017-04-26 15:25:05 -04:00
Beat Küng fc30f880c8 px4fmu_spi.c for v4: fix usage of wrong GPIO macros
This got introduced with the refactoring in c5e841256a
2017-04-26 13:56:59 +02:00
Daniel Agar f04f1d6b03 sensors HIL increase gyro and accel timeout
- fixes #7050
2017-04-25 23:52:11 +02:00
Beat Küng 0d22e97c09 sensor_params: document PWM_RATE=0 for Oneshot125 2017-04-25 12:59:12 +02:00
Beat Küng bd0c1cffc2 mount.aux.mix: remove the mode channel
It does not exist, neither in the actuator group docs, nor in vmount.
2017-04-25 12:59:12 +02:00
David Sidrane 0a1fbef8c8 pwm:ensure that a rate of 0 will invoke the ioctl
Prior to onshot being added to the system. The -r of the
   "rate" command would not invoke the ioctl PWM_SERVO_SET_UPDATE_RATE
   when -r was not provided on the command line. This may have been a
   feature or a bug.

   When onshot was added to the pwm command a bug was intorduced
   that precluded the ioctl PWM_SERVO_SET_UPDATE_RATE from being
   called on -r 0.

   This commit fixes that issue, and preserves the "prio to oneshot"
   behavior of the "rate" command when -r is not specified.
2017-04-25 09:02:28 +02:00
Beat Küng 44a507fcfe camera_interface: initialize _p_pin & handle error 2017-04-24 16:49:26 +02:00
Beat Küng f42a626527 vmount: fix null-pointer access if invalid output mode was selected
In case of an invalid output mode, thread_data.output_obj was null.
2017-04-24 16:49:26 +02:00
Beat Küng 2ef5ebb6db 4002_quad_x_mount: remove vmount start
vmount is automatically started now when the param is set from rcS
2017-04-24 16:46:28 +02:00
Beat Küng 69e8213b37 rcS: set MIXER_AUX to mount if vmount enabled and output is AUX
This automatically selects the mount aux mixer if mount is enabled via
parameters. A user can customize this by adding a file
 etc/mixers/mount.aux.mix
to the SD card.
2017-04-24 16:46:28 +02:00
Beat Küng 3f3ac414e3 fix rc.interface: do not append .mix when setting MIXER_AUX
Because further down the mixer file is set as:
	set MIXER_AUX_FILE /etc/mixers/${MIXER_AUX}.aux.mix
2017-04-24 16:46:28 +02:00
Mohammed Kabir 60fe87aac2 commander : preflight checks increase max_mags to 4 2017-04-24 12:24:11 +02:00
Mohammed Kabir 57aa41df2c sensors : decouple maximum sensor count and allow flexible maximums 2017-04-24 12:24:11 +02:00
Mohammed Kabir f0accd39f0 sensors : add support for 4th magnetometer 2017-04-24 12:24:11 +02:00
Mohammed Kabir 74f4f72a4c commander : add support for calibrating 4 magnetometers 2017-04-24 12:24:11 +02:00
Mohammed Kabir c8dad56300 mathlib : switch min/max to constexpr to match std::min/max 2017-04-24 12:24:11 +02:00
Mohammed Kabir 9909a373b0 commander : warn if more than 4 mags are connected 2017-04-24 12:24:11 +02:00
Lorenz Meier 6d21aac4a9 BMM150 driver: Be less strict on C++ options 2017-04-24 10:38:39 +02:00
Lorenz Meier e054d1fff7 FMUv5: Start BMI055 in correct rotation 2017-04-24 10:38:39 +02:00
Lorenz Meier 145513ff28 BMI055: Correct boot instructions, better default to 16g 2017-04-24 10:38:39 +02:00
Lorenz Meier 3affe67c96 Enable BMI055 for FMUv5 and improve console handling 2017-04-24 10:38:39 +02:00
Lorenz Meier 53bb6c6822 ROMFS: Start ICM on all boards 2017-04-24 10:38:39 +02:00
Sergej Scheiermann 641a03510c changes on drivers according to comments from DavidS 2017-04-24 10:38:39 +02:00
Sergej Scheiermann da31e6e0b5 bmm150 max datarate changed 2017-04-24 10:38:39 +02:00
Sergej Scheiermann 5923e66cf3 bmp285 support added 2017-04-24 10:38:39 +02:00
Sergej Scheiermann c3711efd27 initial commit of bmm150 2017-04-24 10:38:39 +02:00
Sergej Scheiermann c5e841256a changes added for SPI CS defines as requested for BMI055 driver integration (e.g. GPIO_SPI1_CS_PORTE_PIN15 for bmi055 gyro) to avoid double declaration of same chip select pin 2017-04-24 10:38:39 +02:00
Sergej Scheiermann dad5224206 bmi055 added to start-up script 2017-04-24 10:38:39 +02:00
Sergej Scheiermann 7dcdc57412 Update px4fmu_spi.c 2017-04-24 10:38:39 +02:00
Sergej Scheiermann e55516c4b7 Update bmi055_main.cpp
format check
2017-04-24 10:38:39 +02:00
Sergej Scheiermann cfed8ee2dd bmi055 initial integration 2017-04-24 10:38:39 +02:00
Beat Küng 061bff14c8 rpi startup configs: set logger buffer size to 200
Avoid dropouts, we have enough RAM there.
2017-04-24 10:12:23 +02:00
Daniel Agar ea2a611f0b posix-configs replace sdlog2 with logger 2017-04-24 10:12:23 +02:00
Lorenz Meier de7fef8dd6 Crazyflie: Switch to logger 2017-04-24 10:12:23 +02:00
Lorenz Meier 17c022b73e Aerocore 2: Switch to logger 2017-04-24 10:12:23 +02:00
Lorenz Meier 4d8b5e60c3 System: Set new logger system as the default
This will upgrade systems to the new .ulog format used by http://logs.px4.io and supported by Flight Plot
2017-04-24 10:12:23 +02:00
Mohamed Abdelkader Zahana da8724accb removing pwm_start block; not needed in i2c 2017-04-23 23:29:10 +02:00
Mohamed Abdelkader Zahana 60e0ca9321 add both options (pwm/i2c) for lidar lite 2017-04-23 23:29:10 +02:00
Mohamed Abdelkader Zahana 9911a55393 use i2c for lidar lite 2017-04-23 23:29:10 +02:00
Lorenz Meier c60ad883a4 Update SITL 2017-04-23 19:24:40 +02:00
Lorenz Meier 21f409366a MAVLink app: Warn sender if a command has been rejected 2017-04-23 19:23:09 +02:00
Lorenz Meier 1766f65f02 Update Gazebo SITL 2017-04-23 15:24:41 +02:00
Lorenz Meier f7469581b9 VMount: Fix interface spec with respect to MAVLink / vehicle command interface 2017-04-23 15:19:41 +02:00
Lorenz Meier 3d65fcc875 Mount mixer: Fix channel output order 2017-04-23 15:19:08 +02:00
Andreas Antener 00efbffea9 UAVCAN: disable ESCs when in VTOL fixed-wing 2017-04-23 14:59:24 +02:00
Daniel Agar 1fd343b5cc navigator remove FW and MC cruise parameters 2017-04-23 14:50:21 +02:00
Sander Smeets 0106840b87 Allow inflight updates of cruise throttle during missions 2017-04-23 14:50:21 +02:00
Michael Schaeuble 21de5bbc39 Acknowledge vehicle commands in UAVCAN server 2017-04-23 14:49:24 +02:00
Daniel Agar 293eca7d16 Makefile add px4_metadata for airframes and parameters 2017-04-22 21:31:05 -04:00
Daniel Agar 93d4f487ef travis-ci update to latest docker 2017-04-22 21:31:05 -04:00
Daniel Agar f8e291dab1 mavlink VFR_HUD throttle use first 2 groups (#7106)
- fixes #6974
2017-04-22 16:08:27 -04:00
Julian Oes e9aef2eb95 px_uploader.py: properly loop through all baudrates
In case when the baudrate change failed, we should still try that
baudrate again in the next iteration.
2017-04-22 08:00:51 +02:00
Julian Oes 2467297acf px_uploader.py: fix exception on baudrate change
This prevents an exception happening inside the serial stack.
2017-04-22 08:00:51 +02:00
David Sidrane 0754e8f8bc Bugfix:hrt is used before it is initalized.
sched_note_{suspend|resume} were calling hrt_absolute_time before
   it hrt_init is called. This can lead to register access before
   clocking is enabled. The result is a hardfault.
2017-04-22 07:57:37 +02:00
Sander Smeets 6c6cfd4f65 DeltaQuad updated params 2017-04-21 18:13:35 +02:00
Phillip Khandeliants 5012dffeae Potentially infinite and deleted loops found by PVS-Studio (#7100)
- Fixed V712
 - The compiler can optimize this code by creating an infinite loop, or simply deleting it.
 - There is need to add a volatile qualifier to the '_ExitFlag' and 'sim_delay' variables.
2017-04-21 11:13:06 -04:00
Sander Smeets 545458a687 Consider FW PSP in pitch limits (#7098)
The FW_PSP_OFF parameter no longer breaches the pitch min/max limits
2017-04-21 13:34:43 +02:00
Paul Riseborough 1843061376 Tools/ecl_ekf: Improvements to ecl log analysis scripts
Fix error in scaling of population high frequency vibration metrics
Add histograms for delta angle and velocity bias data
Fix variable descriptions
2017-04-21 08:34:19 +02:00
Paul Riseborough 2a34bde0e9 Tools/ecl_ekf: Update EKF log analysis
Add assessment of IMU bias and mag field estimation
Reduce warning false positives by adjusting thresholds and eliminating use of peak value plots for output observer monitoring
Clear each figure after saving to reduce memory usage
2017-04-21 08:34:19 +02:00
Paul Riseborough ed9a9b772e ekf2: minimum change required to use updated ecl library 2017-04-21 08:34:19 +02:00
Paul Riseborough dad2419b21 ecl: Update EKF version
Miscellaneous bug fixes and improvements including:

More conservative reporting of velocity and position accuracy when aiding is lost
Separate reporting of accuracy for local and global position
Detection and recovery from badly conditioned accel bias states and covariance values
Logic to prevent high manoeuvre levels causing bad acceleration bias learning
Reduce sensitivity of covariance prediction to timing jitter
Continue reporting of GPS quality until the later of airborne or checks pass
Add ability to perform wind estimation for multi-rotors using a specific force drag model
2017-04-21 08:34:19 +02:00
David Sidrane 2a8eaa66ca Revist:Back out fix for secondary issue
Ultimate we want this changes that is being backed out herein.
 But it is breaking things because it returns the EINVAL
 when there is a rate overlap. So the rest of the pwm ioctl
 calls then fail and do not set the pulse widths on arming.

 As a secondary issue. We sould call up_pwm_servo_init() to
 establish the PWM channel allocation early. This then allows
 FMU::set_pwm_rate to properly check for improper rate request
 not isolate to one group (timer).
2017-04-21 08:32:33 +02:00
David Sidrane 7322da3c19 fmu:Fixes cause of 0 values reported in pwm info
The root cause was the replacment of a local variable num_outputs
   with the class member _num_outputs.
   The effect of a "bad mix" is to return 0 - this clampped the
   _num_outputs to 0.

   Prior to commit  3b3e2b2 px4fmu: "consolidate usage of output mode"
   this would not have  been an issue because the local num_outputs
   was reset every cycle"

  As a secondary issue. We sould call up_pwm_servo_init() to
  establish the PWM channel allocation early. This then allows
  FMU::set_pwm_rate to properly check for improper rate request
  not isolate to one group (timer).
2017-04-21 08:32:33 +02:00
David Sidrane b885fd97f6 oneshot:trigger exit early in no chan in oneshot 2017-04-21 08:32:33 +02:00
Andrew C. Smith d21b6655d2 Add the Gumstix AeroCore2 to the build system. 2017-04-20 12:24:27 -10:00
Daniel Agar 05cf34a510 ekf_att_pos_estimator remove unused _mission_sub 2017-04-20 14:41:01 -04:00
Daniel Agar ed1b442065 mission require valid landing after DO_LAND_START 2017-04-20 14:41:01 -04:00
Daniel Agar 56b028148b Navigator move get_time_inside and cleanup (#7062) 2017-04-20 11:24:55 -04:00
Daniel Agar 1913b970d7 main state auto mission don't require valid mission 2017-04-20 11:18:32 -04:00
Daniel Agar 6f89e9d551 integrationtests mavros fix type 2017-04-20 11:18:32 -04:00
Daniel Agar c1d9972244 commander add parameter COM_ARM_MIS_REQ
- arm without mission on by default
2017-04-20 11:18:32 -04:00
Matthias Grob 709bd8cb28 mc_pos_control: combine separate pitch and roll maximum tilt angles into one
because there is no sense to have different angle scalings into different directions
it would lead to unintuitive piloting experience
acceleration is directly coupled to the tilt angle regardless of possible assymetric multicopter vehicles
2017-04-20 13:20:01 +02:00
Matthias Grob d1b270d5b2 land_detector: fix sanity condition that we have ground contact when we are landed to include the hysteresis flag
because the condition was looking for the instantaneous flag and during the hysteresis time the state did not change anymore
2017-04-20 13:20:01 +02:00
Matthias Grob caecdbd60b land_detector: treat altitude mode like position mode with vertical checks but without horizontal checks
because in altitude mode we have a baro available and can therefore check vertical movement
we can not check horizontal movement but I consider the checks for landing still pretty safe
unlike in manual mode we are not allowed to disarm before land detection in altitude mode
2017-04-20 13:20:01 +02:00
Beat Küng 0866025149 shutdown: disable work queues for QuRT 2017-04-20 10:01:51 +02:00
Beat Küng 643a3ba2a7 board_config: clean up board_config.h on POSIX targets 2017-04-20 10:01:51 +02:00
Beat Küng aa6814217e shutdown.cpp: use nullptr instead of NULL 2017-04-20 10:01:51 +02:00
Beat Küng dcccb3a718 system_config.h: remove typedef's, there're defined in board_common.h 2017-04-20 10:01:51 +02:00
Beat Küng a2c80e3d55 px4_config.h: remove system_config.h include, board_config.h already includes it 2017-04-20 10:01:51 +02:00
Beat Küng c98212ecd6 shutdown: ifdef for NuttX builds without work queue support
For example on px4cannode-v1_default.
2017-04-20 10:01:51 +02:00
Beat Küng ec5f5bb808 board_config.h: add #pragma once 2017-04-20 10:01:51 +02:00
Beat Küng e129969ea2 tap_pwr: fix definition of board_shutdown() 2017-04-20 10:01:51 +02:00
Beat Küng 73cb423db6 commander: add power button notification callback 2017-04-20 10:01:51 +02:00
Beat Küng 7cb71af949 reboot.c: switch to px4_shutdown_request() 2017-04-20 10:01:51 +02:00
Beat Küng 1d1eedb086 logger: register shutdown hook for graceful shutdown
This will avoid file system corruptions in cases where px4_shutdown_request
is used. However it will not help obviously when the battery is pulled
directly.
2017-04-20 10:01:51 +02:00
Beat Küng 0165633bf3 board_config: remove px4_board_pwr, use px4_shutdown_request instead
px4_board_pwr has become obsolete with the addition of board_shutdown
2017-04-20 10:01:51 +02:00
Beat Küng 25dfa9cda6 posix board_config.h: add include board_common.h
To get the new API definitions
2017-04-20 10:01:51 +02:00
Beat Küng 694bf48422 system: add generic shutdown API 2017-04-20 10:01:51 +02:00
David Sidrane 211837c73b tap:Use board power button notification API
This adds the board power button notification registration
  and shutdown API points.
2017-04-20 10:01:51 +02:00
David Sidrane 109db75881 Added board power button notification API
Defined types and interface to support a notification call back
   on power button events.
2017-04-20 10:01:51 +02:00
jwilson 57fa031e2b Fixes problem preventing params on snapdragon platforms from being saved to flash memory. 2017-04-20 09:06:13 +02:00
jwilson 0aaf595317 Modified sanity test to identify success from the output of the PX4 flight stack, instead of QuRT. 2017-04-20 08:39:16 +02:00
Beat Küng 7442affaf6 px4fmu-v2_default.cmake: enable vmount 2017-04-20 08:29:00 +02:00
Beat Küng 36b2643402 rcS: make sure if 'vmount start' fails, boot is not aborted 2017-04-20 08:29:00 +02:00
Lucas De Marchi 88e19a0916 nuttx build: fix dangling continuation line (#7079) 2017-04-20 01:31:32 -04:00
Nate Weibley 6a99281501 Incorporate @bkueng's feedback, inhibit bogus output on first pass 2017-04-19 17:24:55 +02:00
Nate Weibley 56f4f2b41f Fix top output, indentation for #7020
Previously load stats were stored outside of the printloop, but
with the refactoring to save memory state was reset and used in
the first loop before the actual load calculations were valid.

Fixed by moving the summary info to the bottom of the top printout
after everything is computed. Also restructured the callback to
not depend on a line counter and fixed astyle glitches.
2017-04-19 17:24:55 +02:00
Julian Oes 349a468f81 vmount: add to startup script, disable by default
vmount is now added to the startup script, however, it will only start
if the param MNT_MODE_IN is set to anything but -1.
2017-04-19 16:59:48 +02:00
Beat Küng ed577f705d vmount: set output to Neutral for VEHICLE_ROI_NONE 2017-04-19 16:59:48 +02:00
Beat Küng c20ff1737c vmount: poll only on active input
To reduce latency of the output update when mode is set to auto.
2017-04-19 16:59:48 +02:00
Beat Küng 9ed21afd59 vmount: simplify initialization 2017-04-19 16:59:48 +02:00
Beat Küng 021b808f6c vmount: fix null-pointer access by iterating only over the used objects 2017-04-19 16:59:48 +02:00
Julian Oes 7c0c97ce03 vmount: added commented output printf 2017-04-19 16:59:48 +02:00
Julian Oes f4b1623550 vmount: wrong pointer was passed to update 2017-04-19 16:59:48 +02:00
Julian Oes 87d5b41b84 vmount: fixed wrong index 2017-04-19 16:59:48 +02:00
Julian Oes ec36bdcd10 vmount: always initialize
MNT_MODE_IN 0 now means to automatically check all inputs.
2017-04-19 16:59:48 +02:00
Julian Oes e3d1b7fab4 vmount: _first_time flag wasn't ever reset 2017-04-19 16:59:48 +02:00
Julian Oes 07de797e8d vmount: correctly set control_data output arg
The control_data pointer wasn't correctly set for the cases where there
actually was a change/command.
2017-04-19 16:59:48 +02:00
Julian Oes e1246063e9 vmount: another try to get abs and types right 2017-04-19 16:59:48 +02:00
Julian Oes 702922e677 vmount: _get_aux_value needs to be re-used 2017-04-19 16:59:48 +02:00
Julian Oes c33e46167c vmount: type-promotion fix clang-tidy 2017-04-19 16:59:48 +02:00
Julian Oes a9523155cf vmount: small formatting change 2017-04-19 16:59:48 +02:00
Julian Oes caf69b290a vmount: refactor to auto-select between all inputs
It is not convenient having to change a parameter to change a gimbal
from RC input to mavlink input mode or back. This refactor changes the
behaviour to use whatever is available, RC or mavlink commands.

Once a mavlink command is followed, control can be taken back using RC,
however, this requires a clear stick change.
2017-04-19 16:59:48 +02:00
Daniel Agar 809fec8c05 navigator treat TAKEOFF like POSITION if already flying 2017-04-19 10:45:59 +02:00
crashmatt 304aeddf03 TinyBson - Compatibility with cpp compiler
Changed "private" keyword used for argument to "priv"
2017-04-19 08:29:23 +02:00
Daniel Agar 7b8f3b03a8 cmake patch depend on previous patch target (#7075) 2017-04-18 23:50:20 -04:00
David Sidrane 4a36a806de px4fmu-v4 enable CONFIG_DEBUG_ALERT 2017-04-18 07:15:00 -10:00
David Sidrane 566d73ec22 Nuttx Build option had repeated ARCHWARNINGS
The Make.defs compisition is

    ARCHWARNINGS		 = $(PX4_ARCHWARNINGS)
    ARCHCWARNINGS		 = $(PX4_ARCHWARNINGS) $(PX4_ARCHCWARNINGS)
    ARCHWARNINGSXX		 = $(ARCHWARNINGS) $(PX4_ARCHWARNINGSXX)

so the pieces from nuttx-configs/PX4_Warnings.mk should not be combined.
2017-04-18 07:15:00 -10:00
David Sidrane 0ba99df55e Use as strict or stricter warnings than NuttX has
Reinstate unused checks.
2017-04-18 07:15:00 -10:00
David Sidrane 1e2cef1d72 Fix Unused warning 2017-04-18 07:15:00 -10:00
David Sidrane 2b994b8778 Fix Unused warning 2017-04-18 07:15:00 -10:00
Beat Küng 06997915c2 px4airframes: update image path for markdown after dev-guide update 2017-04-18 11:58:18 +02:00
Beat Küng 42d2f8a798 px4airframes markdown output: merge output columns with maintainer 2017-04-18 11:58:18 +02:00
Beat Küng 89c24cd697 13001_caipirinha_vtol config: fix motor assignment documentation 2017-04-18 11:58:18 +02:00
Beat Küng 2d9a82198a airframes markdown output: merge Outputs where possible for each group 2017-04-18 11:58:18 +02:00
Beat Küng 1df9742219 airframes: add @output meta-data 2017-04-18 11:58:18 +02:00
Beat Küng ce2502a74c rc.interface: fix indentation 2017-04-18 11:58:18 +02:00
Beat Küng a73c0d469b airframe configs Quadrotor x: fix @output tags
extend where needed, only keep the full list for 4001 (and 4002 which differs)
2017-04-18 11:58:18 +02:00
Beat Küng e30d3a53f5 airframe configs: move 4002_qavr5 to 4003_qavr5
There was already an airframe with id 4002.
2017-04-18 11:58:18 +02:00
Beat Küng a943bf37f0 Tools/px_process_airframes: add markdown output 2017-04-18 11:58:18 +02:00
Beat Küng 62c1a23ea3 Tools/px4airframes: refactor & remove some unneeded code 2017-04-18 11:58:18 +02:00
Beat Küng 59ea964ea2 remove Tools/aiframes.xml: not needed anymore 2017-04-18 11:58:18 +02:00
Daniel Agar c86185d4be sensors init CAL_ACC0_ID and CAL_GYRO0_ID for QGC 2017-04-18 10:54:19 +02:00
Lorenz Meier 00158f6e0e Navigator: Use correct command to start RTL 2017-04-18 08:56:15 +02:00
Don Gagne 96458d3184 Support for RTL and Delay mission commands 2017-04-18 08:56:01 +02:00
Daniel Agar 3721fb9d52 cmake cleanup nuttx dependency handling (#7007)
- closes #6501
 - closes #6820
 - closes #6881
2017-04-17 20:57:35 -04:00
Daniel Agar f460f5b34c mc_pos_control minor cleanup 2017-04-17 20:31:46 +02:00
Daniel Agar 34058cbc21 mavlink EXTENDED_SYS_STATUS add takeoff and landing (#7064) 2017-04-17 09:31:49 -04:00
Chris Lovett 91d2ad17b7 Fix takeoff overshoot (issue #319). 2017-04-17 14:35:16 +02:00
Andreas Daniel Antener 18293875b7 Old style switches: changed the loiter switch to have priorit over main switch (#6764) 2017-04-16 10:10:31 -04:00
Julian Oes 0d2e847c57 tag_to_version.py: fix Python3 error (#7056)
subprocess.communicate returns bytes instead of a str which is not the
same for Python3. Therefore, we need to decode the bytes.
2017-04-16 10:03:06 -04:00
Daniel Agar 4487f06629 fw_pos_ctrl_l1 stop using sensors_combined 2017-04-16 08:19:43 -04:00
Daniel Agar 1b8ed8ab08 add FW to Launch detection param group 2017-04-16 08:19:43 -04:00
Daniel Agar 71004ab897 FW launchdetector only run if armed 2017-04-16 08:19:43 -04:00
Nate Weibley 9038be2d83 Fix EKF velocity innovation limit preflight check 2017-04-15 01:21:10 +02:00
Lorenz Meier f70b4ef883 Navigator: Fix RTL state handling by enabling auto-continue after descend 2017-04-14 10:02:31 +02:00
davidaroyer 2322a4d232 DF_MS5611_Wrapper: convert baro pressure to mbar
Temperature compensation in sensors.cpp calculates Baro Altitude
assuming baro pressure is stored as mbar.
2017-04-14 10:01:58 +02:00
Sander Smeets 128f726cd9 Add paramter to enable rc stick override 2017-04-14 10:01:36 +02:00
David Sidrane ff3994da1b mpu6500 Fixed 'test' function causes register checking to find a false faults
Added hold off of testing for register faults from the duration
      of the test.
2017-04-14 09:58:14 +02:00
David Sidrane c3c5be3881 mpu9250 Fixed 'test' function causes register checking to find a false faults
Diisabled interrupts in reset to make command to reset atomic.

      Added hold off of testing for register faults from the duration
      of the test.
2017-04-14 09:58:14 +02:00
David Sidrane 15460ade77 Fixed 'test' function causes register checking to find a false faults
Added hold off of testing for register faults from the duration
  of the test.
2017-04-14 09:58:14 +02:00
Julian Oes bb168287da gps: just use termios on QURT
QURT has added support for termios calls a while back that we can now
use.
2017-04-14 09:56:42 +02:00
Daniel Agar a41001354a FW landingslope delete unused (#7046) 2017-04-13 18:18:57 -04:00
ChristophTobler 12505177b6 add killswitch to snapdragon pwm driver 2017-04-14 00:16:50 +02:00
Nate Weibley 9eb0e62787 Support calibration of fast+slow gyros #6998 2017-04-13 20:22:35 +02:00
Mohammed Kabir 5fc20bea5d camera_trigger : add support for resetting trigger sequence 2017-04-13 20:21:40 +02:00
Mohammed Kabir 7fcb3b4f93 camera_trigger : add support for sending ACKs for trigger commands 2017-04-13 20:21:40 +02:00
Mohammed Kabir 056c99b6fb px4fmu-v4 : add probe instrumentation for timing analysis 2017-04-13 20:21:40 +02:00
Mohammed Kabir 4850aef4f5 px4fmu-v4pro : add probe instrumentation for timing analysis 2017-04-13 20:21:40 +02:00
Mohammed Kabir 2c0d1c013a camera_trigger : digicam control command should only shoot once 2017-04-13 20:21:40 +02:00
Mohammed Kabir e4896a5972 camera_trigger : remove unnecessary constrains for constant values 2017-04-13 20:21:40 +02:00
Mohammed Kabir ae35bf524d camera_trigger : enforce a minimum activation time in PWM modes 2017-04-13 20:21:40 +02:00
Mohammed Kabir 24f57b00a6 camera_trigger : consolidate camera power control and fix camelCase 2017-04-13 20:21:40 +02:00
Mohammed Kabir 164e200d8e camera_trigger : consolidate handling of pins 2017-04-13 20:21:40 +02:00
Mohammed Kabir 0a5ada9e02 stm32 : formatting 2017-04-13 20:21:40 +02:00
Mohammed Kabir f9862ec5a8 camera_trigger : add default mode for generic PWM triggering 2017-04-13 20:21:40 +02:00
Mohammed Kabir 9be7ad5805 camera_trigger : clean up iterators 2017-04-13 20:21:40 +02:00
Mohammed Kabir c97226b9da camera_trigger : add generic pwm interface for servo-like trigger systems (e.g IR trigger) 2017-04-13 20:21:40 +02:00
Mohammed Kabir c06d1a9dbe camera_trigger : rename Seagull MAP2 interface 2017-04-13 20:21:40 +02:00
Mohammed Kabir 3dee42b5ca stm32 : deconflict pwm_get_rate_group from all other timer modes 2017-04-13 20:21:40 +02:00
Mohammed Kabir 3b3e2b275e px4fmu : consolidate usage of output mode 2017-04-13 20:21:40 +02:00
Mohammed Kabir 6d3c16a35b camera_trigger : cleanup pwm interface 2017-04-13 20:21:40 +02:00
Mohammed Kabir ea890ecdd3 camera_trigger : clean up console output 2017-04-13 20:21:40 +02:00
Mohammed Kabir 704de4f88f stm32 : deinit trigger pins properly 2017-04-13 20:21:40 +02:00
Mohammed Kabir 82a1bd83bc stm32 : add new interface for PWM-based camera_trigger 2017-04-13 20:21:40 +02:00
Mohammed Kabir 2b838f5704 camera_trigger : rename relay to gpio 2017-04-13 20:21:40 +02:00
Mohammed Kabir 95778c74e2 rcS : properly handle trigger/actuator pin mixing 2017-04-13 20:21:40 +02:00
Daniel Agar 827725fbe0 cmake remove -Weffc++ (#7044)
- closes #7040
2017-04-13 13:30:22 -04:00
Jon Watson 3fda79ef8b set battery warning for MAVLink battery status (#6890) 2017-04-13 12:37:19 -04:00
Dennis Mannhart 340773096d landdetector: exit landing state if manual.z is larger than threshold 2017-04-13 16:59:23 +02:00
Mohamed Abdelkader Zahana 239370d72c use 1E7 instead 10000000.0f 2017-04-13 11:18:10 +02:00
Mohamed Abdelkader Zahana a9ec1a35bc divide lat/lon received from HIL_STATE_QUATERNION msg by 1E7 2017-04-13 11:18:10 +02:00
Daniel Agar 2f6249af2f cmake add better logs_symlink dependencies 2017-04-12 19:26:06 +02:00
Matthias Grob 2955a2c317 simulator: typo in initial output message 2017-04-12 18:58:37 +02:00
Daniel Agar f608abc6b0 README add uavcan and aero labels (#7026) 2017-04-11 21:21:07 -04:00
Daniel Agar 06c4a0d195 README link to github labels 2017-04-11 20:31:04 +02:00
Lorenz Meier 39dc983c6f DriverFramework: Update to new version and new dspal submodule / location 2017-04-11 06:49:29 +02:00
davidaroyer 1302b6a796 inav: check for updated baro in baro_offset calculation 2017-04-11 06:24:41 +02:00
Beat Küng 24380ae88c logger: add SDLOG_DIRS_MAX param to limit the max number of log directories
Disabled by default, so that logs are not deleted unexpectedly.
2017-04-10 23:37:09 +02:00
Beat Küng 685f114d29 sitl_target.cmake: create a symlink to the log directory in the build dir
Allowing for easier access to SITL logs.
2017-04-10 23:37:09 +02:00
Beat Küng 7f0db95f87 logger: reduce CPU load by ~1.5%
Reduces CPU load from ~6.9% to 5.3% (tested on Pixracer & Pixhawk). The
method is only used once, so it does not increase flash usage.
2017-04-10 23:37:09 +02:00
Beat Küng 75bd4f1121 logger: implement a logrotate
Remove old log directories on startup if free space falls below a threshold.
The threshold is 300MB or 10% of the disk capacity if that's smaller.
2017-04-10 23:37:09 +02:00
Lorenz Meier 85b074f8d8 Navigator: Fix RTL state sequence 2017-04-10 23:34:35 +02:00
Daniel Agar 83cf4fb16e cmake multi_tables.py dependency 2017-04-10 23:31:56 +02:00
Lorenz Meier 5fd7f2fa6f Navigator: Clean up of mission block init 2017-04-10 23:18:40 +02:00
Dennis Mannhart 8687d414bf mc_pos_control: new variable that defines speed in manual controlled mode 2017-04-10 21:34:00 +02:00
ChristophTobler 232f428f6e add ll40ls for Aerofc 2017-04-10 20:20:36 +02:00
Daniel Agar 0b8e88f476 fw_pos_control_l1 remove unnecessary ground_speed 2017-04-10 09:41:01 +02:00
Daniel Agar dc30498c80 fw_pos_control_l1 control_position split position_setpoint_triplet 2017-04-10 09:41:01 +02:00
Daniel Agar 0b0c552dee fw_pos_control_l1 remove unused ground_speed arg 2017-04-10 09:41:01 +02:00
Daniel Agar af7b2cd22f fw_pos_control_l1 cleanup init and uorb helpers 2017-04-10 09:41:01 +02:00
Daniel Agar 474ce2851e fw_pos_control_l1 using math constrain, max, min, radians 2017-04-10 09:41:01 +02:00
Daniel Agar 8b4877a6eb fw_pos_control_l1 delete unused terrain helper 2017-04-10 09:41:01 +02:00
Mark Whitehorn 7e3d07207c Update README.md 2017-04-10 09:37:49 +02:00
James Goppert 955749ed6f Add iris_rplidar model (#6558)
* Whitespace cleanup and add config for rplidar.

* Add rplidar target.

* Disable gps for rplidar.
2017-04-10 03:06:21 -04:00
Mark Charlebois 36f3befec8 Updated to latest dspal and cmake_hexagon
DriverFramework has to be updated to update dspal to the
ATLFlight version of dspal.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-04-10 08:49:29 +02:00
Daniel Agar c5e0bf1c2f uORB combine VTOL FW and MC virtual topics (#7008) 2017-04-09 13:17:20 -04:00
Lorenz Meier 19f0b0be3a Navigator: Altitude acceptance to switch to new waypoints should be more accurace than horizontal distance by default 2017-04-09 17:25:38 +02:00
Lorenz Meier 3b743fbbe9 MC position control: Smoother takeoff
This patch ramps up the throttle to hover throttle instead of a fixed value and limits the vertical takeoff speed to the value set in the parameter. This should ensure smoother, slower takeoffs, in particular in autonomous flight modes.
2017-04-09 17:22:58 +02:00
Lorenz Meier 61cd89efc1 Land detector: Since multicopters take off and land slower than 0.7 m/s, setting the default detection threshold to 0.5 m/s is a much safer default 2017-04-09 17:22:58 +02:00
Dennis Mannhart 4ff3fb4dee mc_pos_control: if takeoff setpoint in auto mode, then do not enter ground contact 2017-04-09 17:19:28 +02:00
Lorenz Meier 08cf97c687 Commander: indicate failsafe reasons more clearly 2017-04-09 12:40:34 +02:00
James Goppert 10ebac2026 Fix build when px4 is a submodule (#7006)
* Fix build when px4 is a submodule

* Check if submodule directory exists.

* Fix submodule directory reading
2017-04-08 23:47:38 -04:00
David Sidrane 3435936189 Force the patches to be applied in order again!
While the list was sorted, this change serialize the application
   of the patches.

   Moved the disply to the actual application of the patch not
   the configuration step.
2017-04-08 07:59:21 +02:00
Lorenz Meier f74d6e443e Navigator: Initialize RTL state properly 2017-04-08 07:58:37 +02:00
Daniel Agar 8c9affddc8 travis-ci generate and upload parameters.md 2017-04-07 22:06:23 +02:00
Kevin Lopez Alvarez cff20ee51e FMUv4pro : updates (#6983)
* FMUv4pro : allow power monitoring for hipower rail

* FMUv4pro : init temperare calibration EEPROM CS

* FMUv4pro : workaround for safety switch

* FMUv4pro : remove useless and conflicting defines

* FMUv4pro : disable internal pull-up for OC sensing

/FAULT won't achieve VinputLow with internal pull-up resistor so it must
be turned off for both /VDD_5V_PERIPH_OC and /VDD_5V_HIPOWER_OC.
Replaced by external pull-up.

* FMUv4pro : correct safety switch handling

RC02 has a hardware pull-down on this signal

* Revert "FMUv4pro : workaround for safety switch"

This reverts commit 9528ae29b68700fa7c6604c1ac2756c7dac2819c.
2017-04-07 06:14:04 -10:00
Matthias Grob 854511b14b cmake: NuttX make shell script call explicit (#6996) 2017-04-07 11:33:19 -04:00
sirPerna 94ef3db407 autostart external airspeed sensor on i2c port 2 2017-04-07 07:34:39 +02:00
David Sidrane 6ef2ae2999 Reduce USART1 tx buffer by 8 bytes to fix aligment issue
The recent changes to the timers increased memory by 8 bytes.
   and should have ONLY added 8 bytes
   was  20000dc0	40	20000E00
   is:  20000dc8	40	20000E08
   s/b  20000E08       1f3      next symbol

   But for some unknown reason the linker skipped to the next alignment
   of 256 and wasted 246 bytes.

   20000F00     1f3     next symbol

   Even with .align 8 in the .S file and . = ALIGN(4); in the linker
   script I could not move the allocation back only up to the next
   512 alighment.

   So this is a hack to shift things back 8 bytes.
2017-04-07 07:30:30 +02:00
David Sidrane f8d955d5a7 Fixed typo in comment 2017-04-06 17:07:28 +02:00
David Sidrane 6541af9297 add-set-ex-to-nsh Reorder patch 2017-04-06 17:07:28 +02:00
David Sidrane cc04dfd27b Added set [{+|-}{e|x|xe|ex}] [<name> <value>] to nsh (#6985)
* NSH Added support for set [{+|-}{e|x|xe|ex}] [<name> <value>]

   Set the 'exit on error control' and/or 'print a trace' of
   commands when parsing scripts in NSH.
   The settinngs are in effect from the point of exection,
   until they are changed again, or in the case of the init
   script, the settings are returned to the default settings
   when it exits.

   Included child scripts will run with the parents settings
   and changes made in the child script will effect the parent
   on return.

   Use 'set -e' to enable and 'set +e' to disable (ignore) the exit
   condition on commands. The default is -e. Errors cause script to
   exit.

   Use 'set -x' to enable and 'set +x' to disable (silence) printing
   a trace of the script commands as they are ececuted. The default
   is +x. No printing of a trace of script commands as they are
   executed.

  Print expanded variables if -x

* Added comments only on how to use the set +e and and set -x

* Spelling NSH_PFALG_* -> NSH_PFLAG_*
2017-04-06 03:42:16 -10:00
Daniel Agar 392a9fbb19 geotagging.py remove unused imports 2017-04-06 14:43:22 +02:00
Daniel Agar 6677022622 geotagging.py pep8 formatting 2017-04-06 14:43:22 +02:00
Daniel Agar 7be2eb06a2 geotagging.py handle mismatch of triggers and images
- print simple progress with time mismatch warning
2017-04-06 14:43:22 +02:00
Daniel Agar c2be4df9b7 geo_tag_images.py remove unused imports 2017-04-06 14:43:22 +02:00
Daniel Agar 833a7e3677 geo_tag_images pep8 formatting 2017-04-06 14:43:22 +02:00
Daniel Agar 83d7764e9e geo_tag_images.py fix to work with PX4 logs 2017-04-06 14:43:22 +02:00
Hamish Willee 33b4ec450d Update parameter script to include increment, enum value, bitmask, module information 2017-04-06 14:04:26 +02:00
David Sidrane 8e217b0287 bugfix:drv_io_timer properly initialize non-contiguous timer channels
This fixes the issue with initializing channels 5,6 without
  channels 1-4.

  The code assumed all timers actions were in order to be
  initialized. This is not the case. This commit fixes that
  bad assumption by not stopping the configuration on the
  first action entry with a base == 0, but processing all
  entries with non-zero base.
2017-04-06 12:20:45 +02:00
Beat Küng b76e7347b5 px4fmu-v4pro nuttx config: reduce CONFIG_CDCACM_TXBUFSIZE to 2000
Log file download via Mavlink is the one that needs the most bandwidth.
It needs typically around 200B TX buffer, and spikes at around 1500B every
10sec, with an average download speed of 230KB/s.
2017-04-06 12:20:06 +02:00
Beat Küng 9f9477e156 px4fmu-v4 nuttx config: reduce CONFIG_CDCACM_TXBUFSIZE to 2000
Log file download via Mavlink is the one that needs the most bandwidth.
It needs typically around 200B TX buffer, and spikes at around 1500B every
10sec, with an average download speed of 230KB/s.
2017-04-06 12:20:06 +02:00
Beat Küng a18fdd2e26 px4fmu-v3 nuttx config: reduce CONFIG_CDCACM_TXBUFSIZE to 2000
Log file download via Mavlink is the one that needs the most bandwidth.
It needs typically around 200B TX buffer, and spikes at around 1500B every
10sec, with an average download speed of 230KB/s.
2017-04-06 12:20:06 +02:00
Beat Küng 40240e83b7 px4fmu-v2 nuttx config: reduce CONFIG_CDCACM_TXBUFSIZE to 2000
Log file download via Mavlink is the one that needs the most bandwidth.
It needs typically around 200B TX buffer, and spikes at around 1500B every
10sec, with an average download speed of 230KB/s.
2017-04-06 12:20:06 +02:00
Beat Küng 0392efff94 px4-stm32f4discovery nuttx config: reduce CONFIG_CDCACM_TXBUFSIZE to 2000
Log file download via Mavlink is the one that needs the most bandwidth.
It needs typically around 200B TX buffer, and spikes at around 1500B every
10sec, with an average download speed of 230KB/s.
2017-04-06 12:20:06 +02:00
Beat Küng ff7d062987 mindpx-v2 nuttx config: reduce CONFIG_CDCACM_TXBUFSIZE to 2000
Log file download via Mavlink is the one that needs the most bandwidth.
It needs typically around 200B TX buffer, and spikes at around 1500B every
10sec, with an average download speed of 230KB/s.
2017-04-06 12:20:06 +02:00
Beat Küng 6f74994c2a auav-x21 nuttx config: reduce CONFIG_CDCACM_TXBUFSIZE to 2000
Log file download via Mavlink is the one that needs the most bandwidth.
It needs typically around 200B TX buffer, and spikes at around 1500B every
10sec, with an average download speed of 230KB/s.
2017-04-06 12:20:06 +02:00
ChristophTobler 9dab1e36db add two-pole-filter to mpu9250 wrapper 2017-04-06 12:19:15 +02:00
Beat Küng 882c5bbdc9 4070_aerofc: update MPC and LND parameters 2017-04-06 12:18:30 +02:00
Lucas De Marchi 260b8ea940 aerofc: remove USB
There's no USB, don't bring it in.
2017-04-06 12:18:30 +02:00
Lucas De Marchi 5744a0bcec aerofc: update NuttX config 2017-04-06 12:18:30 +02:00
Lucas De Marchi 06408b8a4e ROMFS: allow to run without sercon 2017-04-06 12:18:30 +02:00
Lucas De Marchi c39e9a9695 ROMFS: aerofc: set default EKF2 params 2017-04-06 12:18:30 +02:00
Lucas De Marchi 366ff1f3e9 ist8310: remove undef
Use PX4_ERROR instead.
2017-04-06 12:18:30 +02:00
Lucas De Marchi 04dac46eaf ist8310: be resilient to bad data coming from sensor
It doesn't hurt to test if the sensor is outputing data in the expected
range and it should help with elimination of spikes in case of errors.
2017-04-06 12:18:30 +02:00
Lucas De Marchi e40209ead9 ist8310: remove commented out and dead code
This code just makes it harder to grok the driver. When support for this
feature is available we can bring it back.
2017-04-06 12:18:30 +02:00
Lucas De Marchi ade6336fd0 ist8310: lower sample rate 2017-04-06 12:18:30 +02:00
Lucas De Marchi 3c48aa4cf1 aerofc: use MPU9250 driver 2017-04-06 12:18:30 +02:00
Lucas De Marchi 3200b032c0 mpu9250: add support to MPU6500
MPU9250 is mostly an MPU6500 with a mag (AK8963) in the same package.
Support driving MPU6500 with the MPU9250 driver. The id of the driver
isn't set differently since this way it allows to force a recalibration.

Ideally MPU9250 driver could even not exist and the support for these
sensors be merged back in the MPU6000 that's more complete. This is an
intermediate step in that direction.
2017-04-06 12:18:30 +02:00
Lucas De Marchi 2805bffe52 ms5611: reduce macro scope
Move the addresses to .cpp where they are used. This should help
noticing discrepancies like the OSR we are using and the sampling
interval.
2017-04-06 12:18:30 +02:00
Lucas De Marchi 47d4c75214 ms5611: poll sensor at 100Hz 2017-04-06 12:18:30 +02:00
Lucas De Marchi c5108cafff aerofc: fix documentation about pins
- There's no I2C2, so remove it
  - Fix alignments everywhere in board_config.h
  - Clarify STM32 ADC (not available) and the ADC on the FGPA
  - Fix format on some comments
2017-04-06 12:18:30 +02:00
Lucas De Marchi 11d419161b mpu6500: switch driver to 16G range
All the other drivers use 16G, do the same for MPU6500.
2017-04-06 12:18:30 +02:00
Lucas De Marchi 16cd710251 aerofc: set tap esc mode 2017-04-06 12:18:30 +02:00
Lucas De Marchi 6b8c0f7db2 tap_esc: enable closed loop control if supported by board 2017-04-06 12:18:30 +02:00
Lucas De Marchi 173001e73a aerofc: add BOARD_ prefix to define and update description 2017-04-06 12:18:30 +02:00
Lucas De Marchi 41e51a7c85 tap_esc: change define to use BOARD_ prefix 2017-04-06 12:18:30 +02:00
Lucas De Marchi e535156599 ROMFS: set baudrate to 460800 for aerofc
We are getting way to much transfer errors with high baudrate
2017-04-06 12:18:30 +02:00
bresch 12182ec1fc Increase max yawrate default parameters for standard delta VTOL
MC_YAWRATE_MAX 20  => 50

Signed-off-by: bresch <brescianimathieu@gmail.com>
2017-04-06 12:13:14 +02:00
Pavel Kirienko 5788701cc7 Replaced warn() with PX4_WARN() 2017-04-06 12:05:57 +02:00
Pavel Kirienko 02a9ccc4f2 Removed dependency on <algorithm> 2017-04-06 12:05:57 +02:00
Pavel Kirienko 098b57534d UAVCAN GNSS bridge: proper handling of various time bases 2017-04-06 12:05:57 +02:00
Pavel Kirienko 8e61ed9b77 Republishing GNSS Fix2 if no GNSS publishers are available on the bus 2017-04-06 12:05:57 +02:00
Pavel Kirienko 14249d3318 UAVCAN GNSS bridge status output shows whether support for the old Fix message is active 2017-04-06 12:05:57 +02:00
Pavel Kirienko 75c45b62d7 UAVCAN GNSS Fix2 handling 2017-04-06 12:05:57 +02:00
Pavel Kirienko 32ac1288ba Libuavcan update 2017-04-06 12:05:57 +02:00
Beat Küng 58f42c19ad mpu6000: use MPU6000_ACCEL_DEFAULT_RANGE_G define for accel range 2017-04-06 11:50:35 +02:00
Beat Küng 2506b4099f lsm303d: set accel range to 16g 2017-04-06 11:50:35 +02:00
Beat Küng 51add81f6b bmi160: set accel range to 16g 2017-04-06 11:50:35 +02:00
Beat Küng 4d7ed14606 unittests: add PARAM_NO_AUTOSAVE definition
Seems that the work queue is not available for the tests.
2017-04-06 11:49:03 +02:00
Beat Küng 2946aafc2b cmake configs: add -DPARAM_NO_AUTOSAVE for esc32, px4esc, px4cannode, s2740vc
These configs do not have the work queue enabled.
2017-04-06 11:49:03 +02:00
Beat Küng 044a767235 param: add PARAM_NO_AUTOSAVE: if defined, do not depend on LP work queue
Some NuttX configs do not have the work queues enabled.
2017-04-06 11:49:03 +02:00
Beat Küng b5bb5cffc8 gps: check for allocation failure & avoid busy loop 2017-04-06 11:49:03 +02:00
Beat Küng 1be639ec46 temperature_calibration: turn off param autosave 2017-04-06 11:49:03 +02:00
Beat Küng 43afb8d41e sensor calibration: remove param_save_default() calls 2017-04-06 11:49:03 +02:00
Beat Küng 4b18f8ea46 LandDetector: remove param_notify_changes()
not needed anymore because of autosave
2017-04-06 11:49:03 +02:00
Beat Küng f256d03364 param command: remove param_save_default() calls
Not needed anymore due to autosave
2017-04-06 11:49:03 +02:00
Beat Küng dffba3e03b param: move variable definitions to the top of the file 2017-04-06 11:49:03 +02:00
Beat Küng a0e2b0c5a2 param: add param_control_autosave to enable/disable autosave 2017-04-06 11:49:03 +02:00
Beat Küng f3e9739ab0 param export: use writer lock
to protect against concurrent writes to the same file
2017-04-06 11:49:03 +02:00
Beat Küng a5cdff06d5 param: implement rate-limited autosave
- add a saving delay of 300ms
- save at most once every 2 seconds
2017-04-06 11:49:03 +02:00
Beat Küng 7c43689ddc commander: remove param autosave 2017-04-06 11:49:03 +02:00
Beat Küng f179049e95 replay: ignore the ULogMessageType::INFO message
This got introduced the the addition of the perf counter to the log.

Fixes the error:
unknown log message type 73
2017-04-06 11:48:35 +02:00
Beat Küng c7d9a7a6d1 mavlink_log_handler: fix potential buffer overflow 2017-04-06 11:48:35 +02:00
Beat Küng b0ee1579a9 local_position_estimator: fix typo in params 2017-04-06 11:48:35 +02:00
Beat Küng 04303dcf72 PreflightCheck: use orb_unsubscribe instead of px4_close 2017-04-06 11:48:35 +02:00
Beat Küng ecb0dc2bc4 IridiumSBD: use strncpy instead of strcpy 2017-04-06 11:48:35 +02:00
Beat Küng 9be11c048a batt_smbus: fix string length, use correct delete[] for array 2017-04-06 11:48:35 +02:00
Beat Küng d9dac8a6a8 Tools/px_process_params.py: set executable bit 2017-04-06 11:48:35 +02:00
Beat Küng 4d62dd893b tap_esc: handle lockdown & manual_lockdown -> kill switch 2017-04-06 11:46:09 +02:00
Beat Küng 96c40d3ce9 tap_esc: improve cleanup & initialization code 2017-04-06 11:46:09 +02:00
ChristophTobler 7aea4a33c0 use new logger for all eagle configs 2017-04-06 08:45:45 +02:00
ChristophTobler 3d1a10d4f2 Use new logger for Snapdragon Flight 2017-04-05 13:49:02 +02:00
Hamish Willee 0ea331d5c4 Add markdown (HTML) output format for parameters 2017-04-05 13:39:33 +02:00
Daniel Agar a6eb0053c5 TECS default FW_T_HRATE_FF 0.8 2017-04-05 09:31:20 +02:00
Daniel Agar 027e8ee8c0 TECS remove unused and fix style 2017-04-05 09:31:20 +02:00
Daniel Agar 22d0e507c6 TECS fix height demand change 2017-04-05 09:31:20 +02:00
Beat Küng bc8b36a986 gps: update driver submodule 2017-04-04 11:32:18 +02:00
Dennis Shtatnov 6b2f5970eb FMU get initial values of parameters 2017-04-03 01:41:58 +02:00
Sander Smeets 0158f1d506 VTOL Standard transition improvements (#6904)
* FW actuators fully on the entirety of front and back transition
 * back transition ramp up to full MC weight half way through back transition
 * increase maximum front and back transition times
 *  navigator don't reset transition altitude
2017-04-02 19:39:39 -04:00
Jonathan Lee 1d681b0356 Update URL in airspeed calibration error message
When a FW/VTOL system detects a missing airspeed sensor, it produces an error message.
This patch uses the new relevant URLs in the PX4 documentation.

Fixes #4549
2017-04-03 00:25:24 +02:00
Mohammed Kabir d50a0c4323 pwm : fix code style 2017-04-02 21:52:18 +02:00
Mohammed Kabir f915896413 pwm : run update only on NuttX 2017-04-02 21:52:18 +02:00
Mohammed Kabir e8e4e5be49 land detector : add stbs for altitude 2017-04-02 21:52:18 +02:00
Lorenz Meier 1adbf37cbe PWM command: Do not use return value of read 2017-04-02 21:52:18 +02:00
Lorenz Meier dbd065a307 Add PWM out sim trim settings 2017-04-02 21:52:18 +02:00
Lorenz Meier 306d4b8817 Makefile: Add Gazebo clean step 2017-04-02 21:52:18 +02:00
Lorenz Meier 5f135acf33 Land detector: Add mode for rovers 2017-04-02 21:52:18 +02:00
Lorenz Meier bbd1906dfb Add Rover SITL config 2017-04-02 21:52:18 +02:00
Lorenz Meier 63a84900e6 Add rover model 2017-04-02 21:52:18 +02:00
bharath374 6e64bff494 Updated PID gains in 200qx config file 2017-04-02 12:15:37 +02:00
FantasyJXF d1c3b771ee Update navigator_main.cpp
fix a spell error
2017-04-02 12:15:10 +02:00
Beat Küng 2a175aa2f9 logger: use nullptr instead of NULL 2017-04-01 20:19:52 +02:00
Beat Küng bfcbe4b6c3 log_writer_file: rename perf counters
To be more consistent with the rest of the system
2017-04-01 20:19:52 +02:00
Beat Küng 190c14c186 logger: add preflight & postflight process usage & perf counters to the log
For the process usage: we need to measure over a certain period of time,
then we can use the results. To avoid blocking, this does:
- after log is started, initialze the load counters, then one second later
  add the results to the log
- after disarming: continue logging for one more second, then add the process
  load to the log and stop logging.
- to avoid a delay, 'logger stop' will stop immediately and not log
  postflight process usage.
2017-04-01 20:19:52 +02:00
Beat Küng e75f5a4642 perf_counter: add perf_print_counter_buffer & perf_iterate_all
These can be used to print the perf counters to a buffer.
2017-04-01 20:19:52 +02:00
Beat Küng 446c734edc perf_counter: use a mutex to protect concurrent access to the perf_counters linked list
perf_counters is read from and written to by different threads and thus
requires synchronization. Without it we risk accessing invalid memory.

There are still remaining issues (see comment in code), they will not lead
to a crash however.
2017-04-01 20:19:52 +02:00
Beat Küng 4b01e5b6b6 printload: add print_load_buffer() method
Instead of printing to an fd, this prints to a buffer and calls a callback
for each line. To avoid code duplication, the print_load has been refactored
to print to a buffer first, then print to an fd. The overhead is not
noticable, and the behavior of print_load is unchanged.
2017-04-01 20:19:52 +02:00
Beat Küng 9f3043f9ca printload: store total_runtime in a separate loop
Because during the printf, the total_runtime could be changed by another
task. This is still not entirely race-free though.
2017-04-01 20:19:52 +02:00
Beat Küng 23d0355979 printload: reduce memory usage of print_load_s
assuming CONFIG_MAX_TASKS = 32, this saves 256B of RAM
2017-04-01 20:19:52 +02:00
Beat Küng c46274043f printload: use sched_lock to protect access to tcb
what could have gone wrong before? A scheduling switch during the printload
could have led to a task exit, rendering the tcb invalid. After switching
back, printload would access invalid memory.

This keeps the sched_lock() section as small as possible, just grabbing the
tcb variables we need.
2017-04-01 20:19:52 +02:00
Daniel Agar 4b8bedef48 avoid double promotions 2017-04-01 20:19:28 +02:00
Daniel Agar 412f956636 clang-tidy enable performance-type-promotion-in-math-fn 2017-04-01 20:19:28 +02:00
Julian Oes 3c1d785d86 mavlink_mission: set INT frame correctly
Also when formatting malvink mission items from internal mission items,
the INT flag should be obeyed.
2017-04-01 20:07:55 +02:00
Julian Oes 80ce1b6dd8 mavlink_mission: support INT altitude frames
The relative altitude flag was not set correclty when waypoints are sent
using the INT protocol.
2017-04-01 20:07:55 +02:00
Henry Zhang 982fe91fa8 Commander: fix LED status bug when system is armed 2017-04-01 11:39:05 +02:00
David Sidrane 0b91fd0e20 Backport stm32f7:Serial fix for dropped data
1) Revert the inherited dma bug from the stm32
       see https://bitbucket.org/nuttx/nuttx/commits/df9ae3c13fc2fff2c21ebdb098c520b11f43280d
       for details.

       2) Most all CR1-CR3 settings can not be configured while UE
          is true. Threfore we make all operation atomic and disable
          UE and restore it's originalstate on exit.

       N.B. This backport omits all upstream breaking changes.
2017-04-01 11:37:47 +02:00
David Sidrane ba1de2cc0b Renamed to indicate stm32 2017-04-01 11:37:47 +02:00
David Sidrane cd7a57ca1b fmuv5:cr2 was written to cr1 2017-04-01 11:37:47 +02:00
David Sidrane 3eada2c3df fmuv5:Using wrong Sbus Serial port 2017-04-01 11:37:47 +02:00
David Sidrane 36731e13c6 Allow levels of Sbus debugging 2017-04-01 11:37:47 +02:00
Nate Weibley 3ba3aff505 Correct MPU6/9k external detection 2017-03-31 11:04:14 +02:00
David Sidrane eb86730dca Removed all SPEKTUM Power and Bind Control
FMUv4 PRO HW does not have a controlable V3.3 on the connector
   it therefore can not support the SPEKTUM binding.
   This PR removes the Power switch controls or binding control
   interfaces from the board config
2017-03-30 16:19:26 -10:00
David Sidrane 9f0ea7ff4f aerofc-v1 Remove GPIO_RC_OUT and vetted RC_IN wiring
Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
2017-03-30 16:19:26 -10:00
David Sidrane a8f76a3319 px4nucleoF767ZI-v1 Remove GPIO_RC_OUT and vetted RC_IN wiring
Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate bindin

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
2017-03-30 16:19:26 -10:00
David Sidrane 3ed5cedea3 px4io-v2 Remove GPIO_RC_OUT and vetted RC_IN wiring
Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
2017-03-30 16:19:26 -10:00
David Sidrane 784abf2c19 px4io-v1 Remove GPIO_RC_OUT and vetted RC_IN wiring
Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
2017-03-30 16:19:26 -10:00
David Sidrane 4574feaee6 px4fmu-v5 Remove GPIO_RC_OUT and vetted RC_IN wiring
Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_R
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
2017-03-30 16:19:26 -10:00
David Sidrane 29dd41db1d px4fmu-v4pro Remove GPIO_RC_OUT and vetted RC_IN wiring
Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
2017-03-30 16:19:26 -10:00
David Sidrane a161c05dc6 px4fmu-v4 Remove GPIO_RC_OUT and vetted RC_IN wiring
Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
2017-03-30 16:19:26 -10:00
David Sidrane dace50c2aa mindpx-v2 Remove GPIO_RC_OUT and vetted RC_IN wiring
Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
2017-03-30 16:19:26 -10:00
David Sidrane 78d7508800 dsm Use the abstaction SPEKTRUM_POWER to enable the interface
Use the abstaction SPEKTRUM_POWER to enable the interface not
   the define for the GPIO pin.

   Use the clearer macro definitions
2017-03-30 16:19:26 -10:00
David Sidrane d80a322961 fmu: Remove Legacy FMUv4 and use the abstaction SPEKTRUM_POWER
Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Use the abstaction SPEKTRUM_POWER to enable the interface not
   the define for the GPIO pin.
2017-03-30 16:19:26 -10:00
David Sidrane 26d50d2c98 tap-v1 Remove GPIO_RC_OUT and vetted RC_IN wiring
Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
2017-03-30 16:19:26 -10:00
Matthias Grob 5a00cb4770 MPU6000 driver: change default accelerometer range to +-16g
This range amkes much more sense for MAV applications.
It reduces vibration vulnerability caused by measurement range clipping.
2017-03-30 19:07:59 +02:00
Dennis Mannhart 419c474d53 mc_pos_control: manual input temporary yaw fix 2017-03-30 16:43:43 +02:00
Beat Küng cb87f1ea85 unittests: handle visibility.h correctly 2017-03-29 23:02:09 +02:00
Beat Küng 74f4aecbf8 random.c: remove unused & conflicting RAND_MAX 2017-03-29 23:02:09 +02:00
Beat Küng 358bcb6ae0 visibility.h: add #pragma GCC poison getenv setenv putenv
Just to make sure that it will never be used on NuttX. This is not an
architectural limitation, just a memory optimization, since we call
clearenv() on NuttX.
2017-03-29 23:02:09 +02:00
Beat Küng 4a7e02c640 systemlib/visibility.h: remove this file
This is duplicated in src/include/visibility and is directly included via
compiler flag '-include'
2017-03-29 23:02:09 +02:00
Beat Küng e87aa6f6c1 cmake: remove ${PX4_INCLUDE_DIR}visibility.h
This is already added in px4_base.cmake and PX4_INCLUDE_DIR is not set
either.
2017-03-29 23:02:09 +02:00
Beat Küng d72133a380 rcS: increase log buffer by 4kB
To reduce dropouts, and because we have enough RAM :)
2017-03-29 23:02:09 +02:00
Beat Küng be2d10ff45 px4_nuttx_tasks: call clearenv() before task_create
Frees up around 6kB of RAM on Pixracer & Pixhawk.
2017-03-29 23:02:09 +02:00
ChristophTobler 80e7475267 use snapdragon_pwm_out and change connector for RC 2017-03-29 20:11:34 +02:00
David Sidrane 90fe63bb53 Fixes dead aux channels introduce in oneshot
Returned the fmu mixer code to where it updated the HW once
   it has a mixer. But  only signals a up_pwm_update() for
   onshots on actual control update.

   Before this change the hw outpuse were not updated.
2017-03-28 22:57:00 +02:00
Beat Küng d7703173b2 Critical: Fixes Snapdragon Flight parameter synchronization problem (#6910)
* cmake: Fixes problem caused when the generated parameters.xml differs for the ARM and DSP builds.

* fix px4_getopt.h: add accidentally removed file
2017-03-28 16:10:17 +02:00
David Sidrane 7ef3b92109 Fixes lost RC on px4fmu-v4
A recent change in in the fmu stops the instance when a
   xxxx_reset command is used issued if the fmu was not
   already running.

   That change left publications published and then on the
   next creation created a new publications was created.

   This change calls orb_unadvertise to mark the publication
   as un published so that on the next instantiations of the
   fmu it resumes publishing on the same publication.
2017-03-28 08:18:43 +02:00
Daniel Agar 79d15ad2f0 mavlink stream camera trigger broadcast DO_DIGICAM 2017-03-26 14:05:38 +02:00
Mohammed Kabir 679b59b8d4 lpe : default fusion flags for GPS-only use 2017-03-26 14:05:23 +02:00
Lorenz Meier de6302c418 Update DriverFramework to include Mac OS SITL fixes 2017-03-26 12:44:49 +02:00
Sander Smeets 16515e1d1e VTOL standard transition use FW_PSP_OFF (#6728)
* VTOL back transition maintain FW_PSP_OFF

* VTOL Front transition FW_PSP_OFF rampup
2017-03-25 00:24:59 -04:00
David Sidrane 2d92ad2538 stm32 Updated flash patch to upstream revised (#6893)
* stm32 Updated flash patch to upstream (fixes missing commit)

* Removed zubaxgnss-v1_bootloader check build will not fit

Removing zubaxgnss-v1_bootloader from the check build. It is overflowing flash by 6 Bytes.
2017-03-25 00:06:00 -04:00
Sander Smeets fc71ef98bb DeltaQuad params (#6894)
DeltaQuad params
2017-03-25 02:06:19 +01:00
Nate Weibley 9618b9417b Inline block param getter 2017-03-24 22:51:38 +01:00
Nate Weibley f5ffdba4cc Move uORB Subscription getter to header file (#6891) 2017-03-24 15:47:22 -04:00
Jon Watson 8a6b6f9be5 Send MAVLink DO_DIGICAM_CONTROL on camera trigger (#6815) 2017-03-24 13:24:09 -04:00
David Sidrane 577b4cf2f9 zubaxgnss-v1 Use common/nuttx_stubs to not link scheduler 2017-03-24 16:22:47 +01:00
David Sidrane f550631ecf s2740vc-v1 Use common/nuttx_stubs to not link scheduler 2017-03-24 16:22:47 +01:00
David Sidrane 92ca9fa035 px4flow-v2 Use common/nuttx_stubs to not link scheduler 2017-03-24 16:22:47 +01:00
David Sidrane cbdc6dde7d px4esc-v1 Use common/nuttx_stubs to not link scheduler 2017-03-24 16:22:47 +01:00
David Sidrane c7ace100bf px4cannode-v1 Use common/nuttx_stubs to not link scheduler 2017-03-24 16:22:47 +01:00
David Sidrane c8432ae273 esc35-v1 Use common/nuttx_stubs to not link scheduler 2017-03-24 16:22:47 +01:00
David Sidrane 78e2a293d2 Fix UAVCAN bootloader builds broken by os calls from stm32_flash
Recent upsteam NuttX changes needed by PX4 added sem_[wait|post]
   in the stm32_flash driver.

   UAVCAN Bootloaders do not use the OS's scheduler etal.
   This commit nops the sem_[wait|post] with linker magic.
   Which precludes the linking the nuttx scheduler in the
   bootloader build.
2017-03-24 16:22:47 +01:00
David Sidrane 5c6264ae35 Backport:stm32_flash changes from upsteam
PX4 contrib from <jose.souza@intel.com>

  1) stm32: Fix erase sector number for microcontrolers with
     more than 11 sectors

     Erase a sector from the second bank cause the bit 4 of SNB being set
     but never unsed, so trying to erase a sector from the first bank
     was acually eraseing a sector from the second bank.
  2) stm32: Make up_progmem thread safe

   Writing to a flash sector while starting the erase of other sector
   have a undefined behavior so lets add a [staticaly initalized]
   semaphore and syncronize access to Flash registers.

  3) Add workaround for flash data cache corruption on
     read-while-write

    This is a know hardware issue on some STM32 see the errata
    of your model and if you make use of both memory banks you
    should enable it.

  4) Greg's cleanup

  5) PX4 clean up

    stm32_flash:Need conditional on non F4 targets
2017-03-24 16:22:47 +01:00
David Sidrane 8810f70fdc Renamed for ordering and classification
Last patch to rename.
2017-03-24 07:27:55 +01:00
David Sidrane a5fa4e9c02 Restructure patch ordering and dissolve 90000-wip-inflight-to-upstream.patch (#6878)
* Order patch application

   Per discussion with @demarchi this PR adds ordering to the
   patch application.

   This alos add some encoding
   00000      series - is for px4 non up streamable changes
   60000 (bp) series - is for back ports
   90000      series - is for wip that shold make it upstream

* Restore 00010-workarround-for-flash-data-cache-corruption

  Extract this from the 90000-wip-inflight-to-upstream.patch
  and orders it.

* Moved upstreamed 0dbf44e flash fix to bp patch

* Moved upstreamed 5481087 cdcacm fix to bp patch

* Moved upstreamed ec85425 STM32F7 copy paste errors to bp patch

* Moved upstreamed 20e7237 HSI should not be turned off to bp patch

* Moved upstreamed ca895b9 Adding missing CONFIG_ prefix to bp patch

* Moved upstreamed 169b398 STM32: Fixes the bkp reference counter issue to bp patch

* Moved upstreamed 550d259 STM32F7: Fixes the bkp reference counter issue to bp patch

* Moved upstreamed 02825f3 STM32F3X: Add missing STM32_BKP_BASE to bp patch

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Renamed for ordering and classification

* Order Patches by Name
2017-03-23 10:23:16 -10:00
Beat Küng 941d17d74c cmake: make sure params defined in external modules are found 2017-03-23 08:37:48 +01:00
Beat Küng a4fc7ae95e simplify px_process_params: remove --modules, use a list for --src-path instead 2017-03-23 08:37:48 +01:00
David Sidrane 8cdde42e32 px4io-v2:Fixed GPIO_PPM_IN definition 2017-03-23 08:33:03 +01:00
David Sidrane 0d59e84953 px4io-v1:Fixed GPIO_PPM_IN definition 2017-03-23 08:33:03 +01:00
Lorenz Meier fd0efac2b5 IO driver: Run attitude control group limited until the device speed gets set 2017-03-23 08:28:15 +01:00
David Sidrane 5abdb8fbe9 Fixed spelling - onshot->oneshot 2017-03-23 08:28:15 +01:00
David Sidrane e04d43218a Revert "fmu add command line onshot mode"
This reverts commit 22738b1213fff704d288ec84976fa84ff9535aba.

   The command was added due to a lack of my understanding of how the pwm command can be used.

   The command is not needed as the all flag can be used or a proper
   mask WHIHOUT -g

   fmu task mode_pwm
   pwm rate -a -r 50 -d /dev/pwm_output0
   pwm arm
   pwm test -a -p 500

   fmu task mode_pwm
   pwm oneshot -a -d /dev/pwm_output0 is the same as pwm oneshot -m 0xff  -d /dev/pwm_output0
   pwm arm
   pwm test -a -p 500
2017-03-23 08:28:15 +01:00
David Sidrane 2368d94f53 Fixed low on stack waning 2017-03-23 08:28:15 +01:00
David Sidrane f32f194ad8 fmu add command line onshot mode 2017-03-23 08:28:15 +01:00
David Sidrane 75376b7793 Bugfix:Allow mode switch on a free timer 2017-03-23 08:28:15 +01:00
David Sidrane 11191e54e0 use io_timer_set_PWM_mode not direct reg 2017-03-23 08:28:15 +01:00
David Sidrane d21c44704d Propgate any errors in setting the rate up.
Since the Onshot<->PWM mode is changed based on rate. The
 this signale the higher layers that the operation is invalid

 test case:
   fmu task mode_pwm2cap2
   pwm oneshot -m 0xf -g 0 -d /dev/pwm_output0

   should fail, because all the channels in the group are
   not in the same mode.
2017-03-23 08:28:15 +01:00
David Sidrane f5bc3dbc4e drv_io_timer Support OneShot
1) Updated copyright
  2) Defined BOARD overrideable BOARD_PWM_FREQ and BOARD_ONSHOT_FREQ
     Not recogmended but allow experimentation
  3) Solved the support for BOARD_PWM_DRIVE_ACTIVE_LOW using
     the Polarity control bits as apposed to the negation of
     the ARR.
  4) Added a cache for getting a timers channels. This is static
     and benifits from the qucik response.
  5) Added a function to realocate all channes in a given timer
     from one mode to another.
  6) Removed the frequecy table in favor of the intended use of the
     channel mode set. At it is the way to determine the mode of a
     channel. Or in onshot's case a timers's complete set channels.
  7) Added 2 lowlevel mode changing functions:
     io_timer_set_oneshot_mode and io_timer_set_PWM_mode
     that encapsalate the changes in mode to one place
     in the code.
  8) Added io_timer_trigger (the up_pwm_update) with low
     latancy timer to time in updating.
  9) io_timer_set_rate - use sets to enforce all or none
     rules for switching  PWM<->OneShot.
     Onshot is entered using the very approriate rate of 0.
     Only deltas will change the HW state.
2017-03-23 08:28:15 +01:00
David Sidrane 96db91c468 drv_io_timer Add simplified Oneshot API
1) Define IOTimerChanMode_OneShot
   2) Added detailed commnent on .clock_freq and how it is used
   3) Added single additional API point in support of Onshot mode
      io_timer_trigger - That trigger all timer's channels in Oneshot
      mode to fire the oneshots with updated values.
2017-03-23 08:28:15 +01:00
David Sidrane b01768addc px4iofirmware mixer uses new Oneshot API
As discusssed in https://github.com/PX4/Firmware/pull/6678#discussion_r104177663
   this take the safe approach to only call up_pwm_update on a valid mix
   it does keep intatct the riginal author (OA) had an intent.
2017-03-23 08:28:15 +01:00
David Sidrane 6309642c37 px4iofirmware registers uses new Oneshot API
1) Use up_pwm_retrigger to triger onshot
   2) Updated comment to explain why a rate of zero makes sense
      to set oneshot mode.
   3) Updated copyright
2017-03-23 08:28:15 +01:00
David Sidrane 30c8e6efac drv_pwm_servo provide the simplified interface for OneShot
1) Validate timer paramater before using it.
  2) Allow rate of 0 to enter Oneshot mode
     At first blush this seamed like a hack, but at Mark
     pointed out to me, Onshot PWM does not have a rate
     So this is a realy a clever and beautiful simplification
     on his part!
  3) Exposes up_pwm_update that runs io_timer_trigger
     Which trigger all timer's channels in Oneshot mode to
     fire the oneshots with updated values.
2017-03-23 08:28:15 +01:00
David Sidrane 938824500c Only expose up_pwm_update for onshot
This api will REWORD
2017-03-23 08:28:15 +01:00
David Sidrane 8984b441a0 pwm test uses Onshot API
At at a period greater than the the max Oneshot pulse width
  Trigger all timer's channels in Oneshot mode to fire the
  oneshots with updated values.
2017-03-23 08:28:15 +01:00
David Sidrane 6dc3b1cac6 Revert "add macro PX4FMU_TASK to board_config"
The fmu now support the commandline option to be run as a task
   or off a work queue.
   This reverts the board_config.h changes from commit
   e33af23122f5ee3030bb9745bbbf616b24c2a14a.

Conflicts:
	src/drivers/px4fmu/fmu.cpp
2017-03-23 08:28:15 +01:00
David Sidrane 71c25611b5 fmu warnx->PX4_WARN 2017-03-23 08:28:15 +01:00
David Sidrane fc099879be fmu can be run as a task or as worker thread
The new optional option is
  fmu [task] ....

  fmu task mode_pwm - start fmu as a task
  fmu  mode_pwm     - start fmu as a worker
2017-03-23 08:28:15 +01:00
David Sidrane 07834e51b7 fmu:Ensure work_stop still called work_cancel 2017-03-23 08:28:15 +01:00
David Sidrane 9227547886 fmu added comments & updated copyright 2017-03-23 08:28:15 +01:00
David Sidrane 0ce854ad55 Support onshot command 2017-03-23 08:28:15 +01:00
David Sidrane 6bc0420137 pwm warnx->PX4_WARN 2017-03-23 08:28:15 +01:00
David Sidrane cdd961d2b9 pwm remove arch dependancy 2017-03-23 08:28:15 +01:00
David Sidrane d92cb75b26 pwm use px4_getops 2017-03-23 08:28:15 +01:00
Mark Whitehorn 8b6b4ccee9 add macro PX4FMU_TASK to board_config 2017-03-23 08:28:15 +01:00
Mark Whitehorn f7f12759cd Revert "add timer validation call"
This reverts commit 30fe2aa4fb8c099028fd5ca4f50940e88eddbb08.
2017-03-23 08:28:15 +01:00
Mark Whitehorn bbebf980d8 add timer validation call 2017-03-23 08:28:15 +01:00
Mark Whitehorn b5169b0c7b uncomment FMU servo readback test 2017-03-23 08:28:15 +01:00
Mark Whitehorn 9e3488af46 don't update servos if mixer_mix_threadsafe() failed to run 2017-03-23 08:28:15 +01:00
Mark Whitehorn dd25366b86 clean up timer_set_rate and add advice on hacking counter frequency 2017-03-23 08:28:15 +01:00
Mark Whitehorn 2d5588ae02 simplify oneshot mode selection; use zero PWM rate as indicator
cleanup and remove unused (new) params
2017-03-23 08:28:15 +01:00
Mark Whitehorn aa9fbbedd5 add oneshot mode capability
change fmu to task

increase fmu_servo task priority to max and enable true oneshot

use lowest FMU priority which minimizes jitter

constrain oneshot updates to control group 0 events
2017-03-23 08:28:15 +01:00
David Sidrane eac72051b8 Backport of stm32f7 add DTCM to heap and use it on F7 (#6865)
* Backport:stm32f7: stm32_allocateheap: allow use DTCM memory for heap

   Back port of upstrem contrib by Jussi Kivilinna <jussi.kivilinna@haltian.com>

   stm32f7: stm32_allocateheap: allow use DTCM memory for heap

   STM32F7 has up to 128KiB of DTCM memory that is currently left unused.

   This patch adds DTCM to main heap if CONFIG_STM32F7_DTCMEXCLUDE is not enabled.

* px4fmu-v5_default:Enable inclusion of the DTCM in the heap

  CONFIG_MM_REGIONS=3 adds the DTCM region to the heap.
2017-03-22 13:52:01 -10:00
Dennis Mannhart be500723cd mc_pos_control: gradual vel fix for slope 2017-03-22 15:21:34 +01:00
Dennis Mannhart 20a47a1a72 mc_pos_control: limit if just xy distance close to target 2017-03-22 15:21:34 +01:00
Dennis Mannhart f9551c12de mc_pos_control: param fix and gradual vel fix 2017-03-22 15:21:34 +01:00
Matthias Grob 72fb7a5062 mc_pos_control: added gradual landing speed logic
depending on two altitudes that can get set as parameter
the logic linearly slows down from higher land altitude 1 to slower land altitude 2
2017-03-22 15:21:34 +01:00
Matthias Grob 7434bcc693 mc_pos_control: fixed rebase and refactor errors 2017-03-22 15:21:34 +01:00
Dennis Mannhart cd8cc1beaa mc_pos_control: use blockparam, change variable name, delete unused variables 2017-03-22 15:21:34 +01:00
Dennis Mannhart 4c4f214ec7 mc_pos_control: target_threshold value change
mc_pos_control: reorder if statement

mc_pos_control:  add get function for cruising speed
2017-03-22 15:21:34 +01:00
Dennis Mannhart 0d6f994145 mc_pos_control: slow down in auto when close to target
mc_pos_control: move limit vel xy after velocity controller
2017-03-22 15:21:34 +01:00
Dennis Mannhart 8e5a573cb3 mc_pos_control: add default only if there is no previous setpoint 2017-03-22 15:21:34 +01:00
Dennis Mannhart fd3889b5a6 mc pos control: auto handling such that it does not use slewrate when goint to pos 2017-03-22 15:21:34 +01:00
Matthias Grob 5e2f18ebaa mc_pos_control: added separate velocity control setpoint slewrate for deceleration
to improve the smooth user experience while accelerating
but not have any delay when braking
2017-03-22 15:21:34 +01:00
Matthias Grob b32e5e7ec0 mc_pos_control: fixed all pull request complaints
mainly changing parameters to BlockParams, reorder them and comment
2017-03-22 15:21:34 +01:00
Matthias Grob bfb4de0e66 startup scripts/mc_pos_control: renamed parameters after refactor 2017-03-22 15:21:34 +01:00
Matthias Grob 470c3fdc06 mc_pos_control: refactoring only in manual velocity setpoint generation 2017-03-22 15:21:34 +01:00
Matthias Grob 713ba45876 mcpos_control: remove duplicate deadzone parameters 2017-03-22 15:21:34 +01:00
Matthias Grob eec757915c mc_pos_control: switch manual vertical/z velocity curve to expo with deadzone 2017-03-22 15:21:34 +01:00
David Sidrane eb054a0ea1 priority_restoration_fix:Review feedback
Additional backport of c2c226be1db53dd0c1315e13bbd76ace6538eedf
  sem_holder:Clean up from Review
2017-03-22 09:02:15 +01:00
David Sidrane a6dcbc3a22 HOTFIX:Fixes improper restoration of base_priority
Backport of upstream:

   7601a27cee348f70bebcac95e8e8372fe0651bbf David Sidrane Thu Mar 16 14:16:18 2017 -1000  sem_holder:The logic for the list version is unchanged
   3cc2a4f7c9bb495da6c59f373f8d0e7672e4ee13 David Sidrane Wed Mar 15 14:02:55 2017 -1000  sem_holder: Fixes improper restoration of base_priority
   caf8bac7fb9452f25a3297147e7b414d46e74c6f David Sidrane Mon Mar 13 22:54:13 2017 +0000  missing semi
   d66fd9f965f27eb0446d6aed24b8758674f98b53 David Sidrane Mon Mar 13 12:34:39 2017 -1000  semaphore:sem_boostholderprio prevent overrun of pend_reprios
   3c00651cfef3a0d90bb9e6522463965ad8989e6c David Sidrane Mon Mar 13 11:56:31 2017 -1000  semaphore:sem_holder sem_findholder missing inintalization of pholder
   4d760c5ea44c5f8d30a1a595800e9fbf4874e705 David Sidrane Mon Mar 13 10:46:26 2017 -1000  semaphore:sem_holder add DEBUGASSERTs
   modified 399f3067441941072664bdbfa1bfec8ff35aa449 Gregory Nutt  Sat Mar 11 08:57:34 2017 -0600  A few cosmetic changes (removed file that had nothing to do with semaphore commit by OA)
   60d8606b19a7e7c1285a0ef5e8addaaedf26b95f David Sidrane Fri Mar 10 06:38:17 2017 -1000  Priority Inversion fixes:Initalization
   6cc8f9100b3c8026e73ca738aaa5120bd78dae74 David Sidrane Fri Mar 10 06:37:46 2017 -1000  Priority Inversion fixes:typo
   360539afacc83132acdb83da8f20c468dbe4c63d Gregory Nutt  Fri Mar 10 09:30:15 2017 -0600  Priority inheritance:  When CONFIG_SEM_PREALLOCHOLDERS==0, there is only a single, hard-allocated holder structure.
                                                                                          This is problem because in sem_wait() the holder is released, but needs to remain in the holder container
   a93e46d00c1bc3447fb290b866ed21d8f9c8e146 Gregory Nutt  Fri Mar 10 08:54:50 2017 -0600  Cosmetic (missleading OA commit message) Using !pholder is now  pholder == NULL

   sem_holder: Fixes improper restoration of base_priority
   in the case of CONFIG_SEM_PREALLOCHOLDERS=0

   Original code did not take into accout that 2 holder are needed
   and failed silently when a slot could not be allocated

   The call to sem_restorebaseprio_task context switches in the
   sem_foreachholder(sem, sem_restoreholderprioB, stcb); call
   prior to releasing the holder. So the running task is left
   as a holder as is the started task. Leaving both slots filled
   Thus failing to perforem the boost/or restoration on the
   correct tcb.

   This PR fixes this by releasing the running task slot prior
   to reprioritization that can lead to the context switch.
   To faclitate this, the interface to sem_restorebaseprio
   needed to take the tcb from the holder prior to the
   holder being freed. In the failure case where sched_verifytcb
   fails it added the overhead of looking up the holder.

   There is also the additional thunking on the foreach to
   get from holer to holder->tcb.
2017-03-22 09:02:15 +01:00
flying-production aed280fbd4 Make sure that external sitl project will be rebuild in case of sourcve has changed 2017-03-22 08:53:34 +01:00
Henry Zhang 1880ed9758 MindPX: Start send_events handler in MindPX (#6875) 2017-03-22 02:03:14 -04:00
Henry Zhang 6791090fe3 add new config for NanoMind (#6874) 2017-03-22 01:46:13 -04:00
Dennis Mannhart 8f1e851911 Stick to velocity fix (#6825)
* mc_pos_control: use just float for vel and cruise in xy

* mc_pos_control: stick map saturate magnitude to 1

* mc_pos_control: take minimum cruising speed for auto

* mc_pos_control: cruise speed triplet higher than from mc_pos_control

mc_pos_control: fix if for cruise in auto

* mc_pos_control: use PX4_ISFINITE criteria
2017-03-21 07:58:47 +01:00
David Sidrane 7d62aa6a6d HOTFIX:Backport Memory corruption due to stack coloring overreach complete (#6848)
Backport of upstream NuttX

       86400a252dcbe6e4aef3ecca000b469a0fe96b67
       08e92abb0ba744927ed0b32294859b0f47726f82
       4b65817e99cbdf04fefad883eca0e7c8a9add63c

       Improper rounding in redundant stack coloring
       routines could overwriting the TOS+1 and BOS-1
       depending on the value of CONFIG_ARCH_INTERRUPTSTACK

       This applies the compelet upstream set of fixes from
       David Cabecinhas <david.cab+bitbucket@gmail.com>

       Improper rouding in redundant stack coloring
       routines was overwriting the TOS+1 and BOS-1

       The legacy OABI 4 byte stack alingment was removed
       Only the EABI 8 byte alinement is supported
       The redundant interrupt stack coloring. up_initalize
       had the correct implemantation (last verson of patch)
       and the redundant version in the
       arch/arm/src/stmxxx/stmxx_irq.c was calculating the size
       wrong.

       This is fixed by rounding up CONFIG_ARCH_INTERRUPTSTACK
       by 4 bytes when allocated and alining on a 8 byte boundry
2017-03-20 07:32:45 -10:00
David Sidrane f2164b135d Consolidate the flash patches to fix build (#6850)
nuttx-patches/workarround_for_flash_data_cache_corruption.patch was
   patching a file patched in nuttx-patches/wip_inflight_to_upstream.patch

   The changes in workarround_for_flash_data_cache_corruption.patch
   will be submitted upstream once refactored (upstream coding style
   compliant and moved to correct location)
2017-03-20 06:18:23 -10:00
Dennis Mannhart c9643cb075 mc_pos_control: delete leftover from transitional changes for vel_max_z (#6822) 2017-03-20 10:06:29 +01:00
Dennis Mannhart 31aff0b6c0 mc_pos_control: change yaw setpoint to yaw (#6854) 2017-03-20 10:05:33 +01:00
Beat Küng 546bd2b4d0 drivers: remove the overflow perf counter
This was used together with the read() interface, but we don't use that
so the counters are wrong.
2017-03-20 09:11:34 +01:00
Beat Küng f60dfbbb40 perf: remove unused event_overruns, reduce type of delta times to 32bits
32 bits are still enough to measure elapsed times up to 1 hour.

Testing on Pixracer: I counted 73 allocations and 39 frees during bootup,
resulting in 2kB RAM usage after boot. This patch reduce this by ~0.5kB.
2017-03-20 09:11:34 +01:00
David L Sprague 0a02a4c503 Fixed Issue #6596
Fixed the block comments at the top of the source file and the help message for the script (starting at line 279) so that an underscore ("_") character is correctly described as the separator for the first message field name rather than a period character "."
2017-03-20 08:35:39 +01:00
Pavel Kirienko 2b2c307eac Performance audit (intentionally duplicates #6829) (#6847)
* UAVCAN ESC output: removing ESC output channels from published message that are always zero. This allows the UAVCAN stack to always transfer only the minimum number of output values, avoiding redundant zeroes and the associated increase in bus load and CPU time

* Added a separate mixer file for CAN quadrotor

* Sampling profiler improvements

* PMSP: Output more endpoints

* Matrix update

* libc usage workaround

* Removed UAVCAN perfcounters

* Matrix submodule update
2017-03-18 04:16:20 -10:00
David Sidrane c20b85e6ad Revert "UAVCAN performance audit (#6829)" (#6846)
This reverts commit 21e04c9f7a.
2017-03-18 04:04:43 -10:00
Pavel Kirienko 21e04c9f7a UAVCAN performance audit (#6829)
* UAVCAN ESC output: removing ESC output channels from published message that are always zero. This allows the UAVCAN stack to always transfer only the minimum number of output values, avoiding redundant zeroes and the associated increase in bus load and CPU time

* Added a separate mixer file for CAN quadrotor

* Sampling profiler improvements

* PMSP: Output more endpoints

* Matrix update

* libc usage workaround

* Removed UAVCAN perfcounters
2017-03-18 03:47:09 -10:00
David Sidrane 4fe29e5246 Fiexs frsky telemetry stack warning
WARN  [load_mon] frsky_telemetry low on stack! (164 bytes left)

Added 168 bytes = 160 needed + 8 bytes for head room
2017-03-18 10:54:49 +01:00
Lorenz Meier 7695b65b7f MAVLink app: Default to MISSION, not MISSION_INT
In order to ensure correct transmission the mission system needs to default to the legacy protocol and switch to the new implementation when these conditions are met:
  * If the GCS sends a MISSION_REQUEST_INT - it will do this based on the AUTOPILOT_VERSION flag indicating int mission support
  * If the autopilot sends a MISSION_REQUEST and has the AUTOPILOT_VERSION flag for 2.0 set, the GCS should NACK it, which will make the autopilot retry a MISSION_REQUEST_INT
  * If the autopilot sends a MISSION_REQUEST_INT and the GCS does not support it, the GCS will ignore and time out. The autopilot could retry now opportunistically with the old protocol, but this is not great for lossy links.
  * If the GCS sends a MISSION_ITEM_INT - this is a fallback
2017-03-16 23:16:39 +01:00
Matthias Grob bb3b26e00f logger: adjusted log_writer_file stack size
because of messages in the logs
2017-03-16 14:05:15 +01:00
Matthias Grob ca9393eb97 mc_pos_control: fix parameter description of expo for QGC parsing 2017-03-16 11:42:27 +01:00
ChristophTobler d5137ed794 set EKF2_AID_MASK and EKF2_HGT_MODE because of iris_opt_flow 2017-03-16 09:18:54 +01:00
Beat Küng 948635c989 LandDetector: call param_notify_changes() instead of param_save_default()
param_save_default() could take something like 0.5s, and because the
LandDetector is running on the HP work queue, this would block other
tasks, like RC handling or drivers.
2017-03-14 21:43:44 +01:00
Beat Küng f6d9d77f60 param_notify_changes: set unsaved to true
This will make sure that commmander will save the params.
2017-03-14 21:43:30 +01:00
Beat Küng 0e650638e4 param: implement RW locking
This allows concurrent read access, which are much more common; reducing
potential lock contention and increasing concurrency.

Taking a lock is expensive, and the reader lock is now even more expensive.
An RCU synchronization scheme would reduce the overhead of the readers to
increasing/decreasing an atomic counter.
Thus this should only be an intermediate step until we move towards RCU.

Tested on SITL & Pixracer.
2017-03-14 21:30:53 +01:00
Beat Küng b4290b6b52 params: make param_t uint16_t on NuttX
param_t is only used as an offset and we have <1000 params, so an uint16_t
is enough.
This saves roughly 1KB of RAM. We only do that on NuttX because normal
integers have better performance in general.
Previously on amd64, this was even 64bits because it was an uintptr_t.
2017-03-14 21:30:53 +01:00
Beat Küng 45af77a543 mavlink parameters: try to send 5 params at once on USB & UDP connections
This further speeds up param loading.

On Pixracer via USB, it's possible to send up to 11 at once before the TX
buffer gets full, so there is still enough free bandwidth left.
2017-03-14 21:30:04 +01:00
Beat Küng 2873d973de mavlink: increase parameter rate from 120 to 300Hz
This speeds up parameter loading. Slow links like telemetry are unaffected,
since the mavlink loop runs only with ~100Hz.

Tested on various links, like:
- telemetry link
- pixracer WiFi
- pixracer USB
- SITL
2017-03-14 21:30:04 +01:00
Simone Guscetti cc153638d2 commander calibration_routines: fix the white led
The white led state would continue during calibration, now it return to the previus state
2017-03-14 14:25:49 +01:00
Simone Guscetti 1e4b79034f commander_helper: Add rgbled function
with priority and blink period
2017-03-14 14:25:49 +01:00
Lorenz Meier 2af5d1b929 Mission transfer: Fix retry logic
Previously the retry would not actually have been sent if nothing had been received in time.
2017-03-13 21:51:21 +01:00
Lorenz Meier 10dcb90d52 Commander: Store last manual stick setpoints only when actually in manual control mode 2017-03-13 21:08:17 +01:00
David Sidrane bef24b906e Removed v4pro cloned v4 inappropriate definitions (#6808)
* Remove remove safty swtich LED from FMU control

* Differentiate GPIO_BTN_SAFETY_FMU  from GPIO_BTN_SAFETY
2017-03-13 07:26:36 -10:00
Lorenz Meier 1a3317ebab Commander: Do not abort low battery handling due to stick motion. 2017-03-13 08:42:51 +01:00
Lorenz Meier e9e79cdc9b Updated optical flow repo 2017-03-13 08:37:50 +01:00
Lorenz Meier 706464d2eb Land detector: Fix param meta data 2017-03-12 14:42:19 +01:00
Lorenz Meier e4c012289f Logger: Sync setpoints and states to same rates 2017-03-12 11:10:19 +01:00
Lorenz Meier f7e4d8453d Logger: Drop position_setpoint_triplet to 5 Hz since its not required at such a high rate in analysis 2017-03-12 11:06:40 +01:00
Beat Küng 32cf540159 rgbled: make sure to load the params on startup 2017-03-12 00:08:35 +01:00
Beat Küng 2cf849a520 led_control: fix errors by clang-tidy 2017-03-12 00:08:35 +01:00
Beat Küng f22fc1c543 led: add breathe mode 2017-03-12 00:08:35 +01:00
Beat Küng 30841ee6bf send_event: separate initialization and wait until started for 'send_event start_listening' 2017-03-12 00:08:35 +01:00
Beat Küng 1177ec91e5 temperatoru_calibration: reformat comments to use doxygen style 2017-03-12 00:08:35 +01:00
Beat Küng 7cb291aa62 temperature_calibration: use a define for error code -110 2017-03-12 00:08:35 +01:00
Beat Küng ce8707532e led/led: change update logic to keep blinking led's in sync 2017-03-12 00:08:35 +01:00
Beat Küng 9e09f70f37 lib/led: make sure to do an orb_copy on startup 2017-03-12 00:08:35 +01:00
Beat Küng b7f5d92b21 lib/led: add some clarifying comments 2017-03-12 00:08:35 +01:00
Beat Küng df791cef94 RPi: make sure navio_rgbled works and add it to autostart 2017-03-12 00:08:35 +01:00
Beat Küng 38156d862f temperature_calibration: add led indication
- starts with yellow blinking
- turns led to solid according to progress
- blink red on error, green on success
2017-03-12 00:08:35 +01:00
Beat Küng 1e4fcb6616 cmake configs: add systemcmds/led_control and lib/led where needed 2017-03-12 00:08:35 +01:00
Beat Küng b1be963083 px4fmu_test rcS: switch to led_control command 2017-03-12 00:08:35 +01:00
Beat Küng 46fef30526 systemcmds: add new command led_control
This can be used to test & control the new uorb-based led backend.
2017-03-12 00:08:35 +01:00
Beat Küng 83afc207d4 drv_rgbled.h: remove this, it's not used anymore 2017-03-12 00:08:35 +01:00
Beat Küng 95e8e26ae0 commander: use led_control uorb topic 2017-03-12 00:08:35 +01:00
Beat Küng 8dae94d90a lib/led: add BREATHE mode (but not implemented yet) 2017-03-12 00:08:35 +01:00
Beat Küng 729486f992 rgbled: switch to new led uorb interface 2017-03-12 00:08:35 +01:00
Beat Küng 7fd6748f34 rgbled_pwm: switch to new led uorb interface 2017-03-12 00:08:35 +01:00
Beat Küng 6debbcb20d navio: switch to new led uorb interface 2017-03-12 00:08:35 +01:00
Beat Küng 43b98d9a2f lib/led: add led class with led_control uorb topic
This is the new interface to control external LED's (user-facing).
Features:
- Supports maximum N Leds (where the board can define N)
- on/off/blink M times
- Different priorities
- Allows setting a single led or multiple at once
2017-03-12 00:08:35 +01:00
Beat Küng 5ebbbfc6bf rgbled_pwm: warnx -> PX4_WARN, NULL -> nullptr 2017-03-12 00:08:35 +01:00
Beat Küng b0439836f6 refactor drv_led.h: rename to drv_board_led.h
This makes it clear that it's used to control the board LED's, not external
LED's.
2017-03-12 00:08:35 +01:00
Beat Küng 61c1f6a8ef rgbled: warnx -> PX4_WARN and NULL -> nullptr 2017-03-12 00:08:35 +01:00
Beat Küng 4b1bbaa114 posix: remove rgbledsim driver which does nothing
In addition this is almost a copy of the rgbled driver
2017-03-12 00:08:35 +01:00
Julian Oes 404719953c commander: fix abs bug / trigger POSCTL both ways
The check if stick were touched was only working in one direction (per
axis) because fabsf was used incorrectly.

However, this check is still only a differential check triggered by
fast movement and does not trigger if someone slowly moves a stick to
the side. Also, the sensitivity depends on the rate of the commander
loop and/or the RC update loop. The correct solution would be a proper
filtering and trigger for movement.
2017-03-11 22:41:23 +01:00
Lorenz Meier fb64403607 Updated jMAVSim 2017-03-11 22:03:17 +01:00
Lorenz Meier 86a8e95017 Update jMAVSim to fix compatibility with recent java versions 2017-03-11 21:37:06 +01:00
David Sidrane 5a66539b36 HOTFIX:Backport Memory corruption due to stack coloring overreach
Backport of upstream NuttX PR 264

   As discovered by dcabecinhas. This fix assume the 8 byte
   alignment options for size stack size or this will overwrite
   the first word after TOS
   See https://github.com/PX4/Firmware/issues/6613#issuecomment-285869778
2017-03-11 20:26:51 +01:00
Daniel Agar 742d0e53f9 examples NULL to nullptr 2017-03-11 11:40:14 +01:00
Daniel Agar 0611677ee2 segway move to examples 2017-03-11 11:40:14 +01:00
Daniel Agar 89ff9f1fe3 cmake fmu-v3 fix and enable more examples
- sync posix_sitl_default and px4fmu-v4pro/v5 with fmu-v3
 - fixes #6667
2017-03-11 11:40:14 +01:00
Beat Küng 4811ab6b13 logger: reduce rate of some topics
In SITL, logging rate reduces from 70kB/s to 45kB/s.
2017-03-11 10:30:38 +01:00
José Roberto de Souza f61b830ae9 nuttx-configs: aerofc: Enable CONFIG_STM32_FLASH_WORKAROUND_DATA_CACHE_CORRUPTION_ON_RWW
Now AeroFC is making use of both flash memory banks so it need this
workaround.
2017-03-11 10:30:04 +01:00
José Roberto de Souza 03e3877535 nuttx-patches: Add workaround for flash data cache corruption on read-while-write 2017-03-11 10:30:04 +01:00
David Sidrane c967cade47 HOTFIX:Backport of second round upstream NuttX i2c fix (#6771)
backport 3cd66af889b42b036d6c9d88e067fc3b8abbdb2a and pr 258

   Applies to STM32F4 and STM32F7

   STM32, STM32 F7, and STM32 L4: Clone Freddie Chopin's I2C change to similar STM32 I2C drivers.

   Save elapsed time before handling I2C in stm32_i2c_sem_waitstop()
   This patch follows the same logic as in previous fix to
   stm32_i2c_sem_waitdone().
   It is possible that a context switch occurs after I2C registers are read
   but before elapsed time is saved in stm32_i2c_sem_waitstop(). It is then
   possible that the registers were read only once with "elapsed time"
   equal 0. When scheduler resumes this thread it is quite possible that
   now "elapsed time" will be well above timeout threshold. In that case
   the function returns and reports a timeout, even though the registers
   were not read "recently".
   Fix this by inverting the order of operations in the loop - save elapsed
   time before reading registers. This way a context switch anywhere in the
   loop will not cause an erroneous "timeout" error.
2017-03-10 07:26:51 -10:00
David Sidrane 60c8c84e18 HOTFIX:Backport of upstream NuttX i2c fix
5a6d95dd9f051be548a8d2378aaef75f0a1ba5e1 and ee5ae3a57dbbe835584f164c956e0374da1ed2eb

   Applies to STM32F4 and STM32F7

   Save elapsed time before handling I2C in stm32_i2c_sem_waitdone()
   It is possible that a context switch occurs after stm32_i2c_isr() call
   but before elapsed time is saved in stm32_i2c_sem_waitdone(). It is then
   possible that the handling code was executed only once with "elapsed
   time" equal 0. When scheduler resumes this thread it is quite possible
   that now "elapsed time" will be well above timeout threshold. In that
   case the function returns and reports a timeout, even though the
   handling code was not executed "recently".
   Fix this by inverting the order of operations in the loop - save elapsed
  time before handling I2C. This way a context switch anywhere in the loop
  will not cause an erroneous "timeout" error.
2017-03-10 12:15:10 +01:00
José Roberto de Souza 07921c9f3a aerofc: Use ram_flash dataman backend 2017-03-10 11:31:07 +01:00
José Roberto de Souza e2aae04c95 modules: dataman: Add a ram_flash backend
This backend will keep all updated data in RAM and
persist the data between reboots using flash memory.

Using only flash memory would result in a slow backend that
would decrease the lifetime of the flash memory, using both
we can reduce the several cycles of erase & write into flash
and keep the performance of the backend almost as fast
as the RAM only backend.

Note: Do not use this backend on a sector from the same flash memory
bank as the memory bank that STM32 read instructions or it can block
the CPU from fetching instructions from flash during the erase and
write operations and cause your drone crash.
2017-03-10 11:31:07 +01:00
José Roberto de Souza 75e7cfcbe8 modules: flashparams: Change size to uint32_t
So flash sector of 64Kbyes and 128Kbytes can also be used.
2017-03-10 11:31:07 +01:00
José Roberto de Souza a2670bdbc8 modules: dataman: Move backend specific out of main routines 2017-03-10 11:31:07 +01:00
José Roberto de Souza 66d9d56525 modules: dataman: Share memory between backends
Also having just a boolean to track if backend is running.
2017-03-10 11:31:07 +01:00
Beat Küng 8d5ba63686 tap-v1 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng 374dc1be4c px4nucleoF767ZI-v1 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng d25218eba2 px4fmu-v5 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng 3848432302 px4fmu-v4pro NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng 1f520f15a3 px4fmu-v4 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng b73cd50863 px4fmu-v3 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng b89451f160 px4fmu-v2 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng 0ffcf70a84 px4fmu-v1 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng 58aff84911 stm32f4discovery NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng 6170544738 mindpx-v2 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng 3ac953db0e esc35-v1 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng 9862f1c5f9 crazyflie NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng 34a2326c12 auav-x21 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng ab541b1321 px4esc-v1 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng 3cdec49a09 aerofc-v1 NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng d10848c129 aerocore NuttX defconfig: lower CONFIG_DEV_PIPE_SIZE to 70
This saves almost 2kb of RAM when using the mavlink shell. 70 matches the
size of the mavlink message. Since the pipe is blocking, a process writing
a lot of data will just wait, data will not be dropped.

The mavlink shell is the only process creating a pipe.
2017-03-10 11:29:09 +01:00
Beat Küng cfcc75d444 mavlink shell: check if there's enough free buffer to send the mavlink message
if there is not, the process on the other end of the pipe will just block.
This improves reliability over slow links.
2017-03-10 11:29:09 +01:00
Beat Küng 644d237ce6 posix-configs scripts: remove unneeded 'sleep 1'
There is no need to wait, and it would be the wrong way of doing
startup synchronization.
2017-03-10 11:28:41 +01:00
Beat Küng b1e27f4395 simulator: handle ctrl-c during startup correctly
This makes sure the px4 process does not hang when Ctrl-C is pressed
during startup.
2017-03-10 11:28:41 +01:00
Beat Küng 9597e708df sensors: remove sensors_init
The initialization code is redundant and incomplete (only the first sensor
is done). I verified that all drivers already set this on startup.
For the mags, they all set their maximum supported update rate.
For the baro, the call can silently fail, as for example the MS5611 which
does not support 150Hz update. But it also sets the maximum in
initialization.

Tested on Pixhawk & pixracer.
2017-03-10 11:28:41 +01:00
Beat Küng 019386a5a0 bmi160: remove debug output 2017-03-10 11:28:41 +01:00
Beat Küng 828bb983e8 rpi startup scripts: start dataman so that missions can be flown 2017-03-10 09:00:24 +01:00
Beat Küng 2a6eac578d rpi: add HIL config 2017-03-10 09:00:24 +01:00
Beat Küng 32995a5bc1 state_machine_helper: remove unneeded code to disable sensor publication
In HIL mode we do not start the sensors anymore, so this is not needed.

Also it did not work (I did not try to find the reason, just noticed the
sensors kept publishing in HIL mode)
2017-03-10 09:00:24 +01:00
Beat Küng af1984ac07 sensors: do not warn about baro in HIL mode 2017-03-10 09:00:24 +01:00
Beat Küng bc91005e7a voted_sensors_update: increase accel & gyro timeout in HIL mode 2017-03-10 09:00:24 +01:00
Beat Küng 3a737097ee rpi px4.config: switch to ekf2 2017-03-10 09:00:24 +01:00
Beat Küng 541e53fdcf jmavsim_run.sh: add -i to specify the IP 2017-03-10 09:00:24 +01:00
jwilson 62200e2a81 WIP: Temporary fix for a problem which prevents arming on the Snapdragon Flight board. 2017-03-10 08:54:08 +01:00
Julian Oes 0c926106f1 param_shmem.c: comment out locking on Snappy
The param locking doesn't seem to be working on Snapdragon, so let's
just comment it out again.
2017-03-08 15:44:31 +01:00
Julian Oes 9235c0fd67 Update jMAVSim submodule
This fixes the compass, see:
https://github.com/PX4/jMAVSim/pull/55
2017-03-08 19:37:57 +08:00
jwilson 4f9245cc9c Resolves a conflict in the type of the index parameter in the dm_read and dm_write function signature, caused by a recent change in the dataman code. This problem was causing the loading of the flight stack to fail on the aDSP. 2017-03-08 15:04:20 +08:00
Julian Oes 24819ce7b1 commander: no datalink failsafe on ground
On SITL startup we got a datalink lost failsafe message whenever home
was initialized. The reason that in standalone SITL, there is usually no
datalink connected. However, on ground, we shouldn't really failsafe,
therefore it makes sense not to enter the state in the first place.
2017-03-08 05:33:32 +08:00
Beat Küng c715228b8f LandDetector: save & initialize total flight time 2017-03-08 04:19:22 +08:00
Beat Küng bac10bcfb8 rcS: do not wipe flight time param on autoconf 2017-03-08 04:19:22 +08:00
Michael Schaeuble 06c5cb506a Enable ICM 20608 on Pixhawk Pro 2017-03-08 04:18:48 +08:00
Beat Küng 561a5c5422 Tools/px_mkfw.py: use the same args to get the git version as px_update_git_header.py 2017-03-07 23:55:37 +08:00
Mathieu Bresciani d67b6efda3 PixHawk Pro: Update mag IDs to have external higher priority 2017-03-07 23:43:28 +08:00
Lorenz Meier daf668e687 Fixed wing land detector: Fix RTL logic with a temporary altitude limit workaround 2017-03-07 15:48:23 +08:00
zthorson b8e72789cd px4fmu-v4: Formatting fixes
Signed-off-by: zthorson <zachthorson@gmail.com>
2017-03-05 11:42:27 +08:00
zthorson a716b105f5 px4fmu-v4: Only close down fmu drivers on reset if they weren't running
Signed-off-by: zthorson <zachthorson@gmail.com>
2017-03-05 11:42:27 +08:00
zthorson 63857c6afc px4fmu-v4: Fix for HIL Unable to Set Control Surfaces. Fixes #5651
The sensor_rest command added to the startup script for px4fmu_v4 hardware
was leaving the /dev/pwm_output0 driver open.  This would prevent the
pwm_out_sim module from registering as a simulated driver.  The result
would cause the system to properly boot in HIL mode, but you would not
be able to set any control surfaces.

Since sensor_rest and peripheral_reset are only used on initialization, the
drivers can be shut down after they have performed their reset functions.

Signed-off-by: zthorson <zachthorson@gmail.com>
2017-03-05 11:42:27 +08:00
Daniel Agar e63ee9d8bd fw_att wheel controller enable param (default off) 2017-03-05 11:41:14 +08:00
Beat Küng ca05e64a9f replay: update & add some comments 2017-03-04 22:47:54 +08:00
Beat Küng eaa9e6a019 ekf2: set att.timestamp to now in replay mode before ekf is initialized
logger will always log this topic, and a 0 timestamp will look worse in
FlightPlot. This will show a period of 0 attitude instead before ekf
is initialized.
2017-03-04 22:47:54 +08:00
Beat Küng 01541bb10d logger: switch from ekf2_replay to ekf2_timestamps topic, enable by default 2017-03-04 22:47:54 +08:00
Beat Küng 1d48d7e053 ekf2 replay: add statistics output when replay finished
The error counter is an indicator that the logger missed samples or dropped
due to a too small write buffer.
2017-03-04 22:47:54 +08:00
Beat Küng 2a11a2bc0b ekf2 replay: switch from ekf2_replay to ekf2_timestamps topic 2017-03-04 22:47:54 +08:00
Beat Küng aabdc4125b ekf2: publish ekf2_timestamps topic 2017-03-04 22:47:54 +08:00
Beat Küng df3ef3660b ekf2_timestamps.msg: add new message with ekf2 timestamps 2017-03-04 22:47:54 +08:00
Beat Küng 473192aa81 replay: some API refactoring & extensions
in preparation to the updated ekf2 replay
2017-03-04 22:47:54 +08:00
Beat Küng ba89839f65 replay: make sure ReplayEkf2::handleTopicUpdate is protected, not private 2017-03-04 22:47:54 +08:00
Beat Küng 1d93b1bce3 nuttx configs: increase CONFIG_NFILE_DESCRIPTORS from 51 to 53
this is needed due to the additional topics logged with the logger
2017-03-04 22:47:54 +08:00
Beat Küng 037280c17d sitl: add iris_replay startup script, handle $replay_mode in sitl_run.sh
usage:
export replay_mode=ekf2
export replay=<abs_path_to_log.ulg>
make posix none
2017-03-04 22:47:54 +08:00
Beat Küng 63203625bc replay: add ekf2 replay method (can be selected with 'export replay_mode=ekf2') 2017-03-04 22:47:54 +08:00
Beat Küng e251c64c5f refactor replay: add some overrideable methods 2017-03-04 22:47:54 +08:00
Beat Küng df8c1a1489 logger: log ekf2_replay topic if EKF2_REC_RPL is set 2017-03-04 22:47:54 +08:00
Beat Küng 9d54f62d37 replay: check if topic timestamp is smaller than logging start
This could happen and then the sleep duration would wrap and be huge.
2017-03-04 22:47:54 +08:00
Beat Küng 1d5f51e6a4 replay: don't add subscription if formats don't match 2017-03-04 22:47:54 +08:00
Beat Küng 4eea89bb42 refactor replay: move topic publication into separate method 2017-03-04 22:47:54 +08:00
Beat Küng 45ffb190e3 logger: add -p <topic> option to poll on a topic instead of running at fixed rate
this will be needed for fast replay. In addition, this option disables
the orb interval.
It can be removed again once we have time simulation.
2017-03-04 22:47:54 +08:00
Beat Küng 2220c3a60d ekf2: use sensors timestamp for published topics when in replay mode
when doing fast replay, hrt_absolute_time() will not match the replayed time
thus we just use the same timestamp as the input sensors.
2017-03-04 22:47:54 +08:00
Beat Küng 018846fadf ekf2_replay.msg: use timestamp instead of time_ref, remove unused time_usec_vel 2017-03-04 22:47:54 +08:00
Beat Küng dcdfcbe64f posix_sitl_default cmake: add ekf2_replay
so that CI will build it
2017-03-04 22:47:54 +08:00
Beat Küng aa56822f9d ekf2_replay: fix double/float conversion compile warning 2017-03-04 22:47:54 +08:00
Beat Küng 99beb03f83 ekf2_replay: switch to new vision topics 2017-03-04 22:47:54 +08:00
Beat Küng eb8bce4825 sdlog2: fix PARAM name truncation
if a parameter name was 16 characters long (which is valid), the last
character got truncated due to 0-terminated string.
This raises the param name to 64 chars, which is quite wasteful, but there
is no other length in between.
2017-03-04 18:27:25 +08:00
Beat Küng 54c8e3b26b commander: fix excessive orb_advertise calls for vehicle_status_flags
vehicle_status_flags_pub passed to publish_status_flags() was always null,
thus orb_advertise() was called each time.

Note that it did not produce a memory leak.
2017-03-04 17:44:47 +08:00
Beat Küng b2d47adf56 jmavsim_run.sh: add -r option to set the update rate
currently jmavsim uses a default rate of 500 Hz which is too much.
2017-03-04 05:59:10 +08:00
Beat Küng 2bbe04c3d6 mavlink_receiver: don't publish sensor_combined for MAVLINK_MSG_ID_HIL_SENSOR
In hil mode, sensors is responsible for publishing this topic.
2017-03-04 05:59:10 +08:00
Beat Küng 8957b473a8 px4fmu rcS: start sensors in hil mode if HIL is set, don't load rc.sensors
This makes sure no sensor publishes sensor topics, instead they will be
published from mavlink.
2017-03-04 05:59:10 +08:00
Beat Küng 881f2d2d36 sensors: add 'sensors start -hil' parameter
This does the following if given:
- don't initialize the sensors (the sensor drivers are not started)
- publish sensor_combined even in hil mode
- do not apply or publish thermal corrections
2017-03-04 05:59:10 +08:00
Beat Küng 3f6783fce7 mc_att_control: make sure to update the polling fd when the selected gyro changes 2017-03-04 05:59:10 +08:00
Beat Küng ec33607912 mc_att_control_main: make sure to initialize at least one gyro sensor
in HIL mode, gyros are published after mc_att_control started.
2017-03-04 05:59:10 +08:00
Beat Küng 570aca98a3 pwm_out_sim: make sure g_pwm_sim is initialized with nullptr 2017-03-04 05:59:10 +08:00
ustbguan 68701b197a use mBar 2017-03-03 13:43:27 +00:00
Dennis Mannhart f5ae90a7cb mavlink_main: add POSITION_TARGET_LOCAL_NED to mavlink stream 2017-03-03 07:23:02 +01:00
Sander Smeets 9ef87f1311 VTOL QuadChute Maximum roll and pitch angles (#6665) 2017-03-02 10:34:04 -05:00
Dennis Mannhart e892a51afb mc_pos_control: delta_t needs to be positive 2017-03-01 11:46:23 +01:00
Matthias Grob 2b90224075 land_detector: added parameter for manual position stick takeoff threshold 2017-02-28 13:05:33 +01:00
Dennis Mannhart 9c2dd48814 landdetector: m/s to m 2017-02-27 22:54:19 +01:00
Dennis Mannhart 7f54f891c1 land_detector: set max height to 100 2017-02-27 22:54:19 +01:00
Dennis Mannhart 6939583650 mc_pos_control: _run_altitude if close to max altitude 2017-02-27 22:54:19 +01:00
Dennis Mannhart 3d4e7819a0 landdetector: delete function update_alt_max 2017-02-27 22:54:19 +01:00
Dennis Mannhart 1774e01c00 rtl: keep rtl altitude below max altitude
land_detector: delete unused class enum
2017-02-27 22:54:19 +01:00
Dennis Mannhart b887654d69 mc_pos_control: fix limit_altitude function 2017-02-27 22:54:19 +01:00
Dennis Mannhart ca84cc7439 mc_pos_control: delete max altitude, which is not set by landdetector 2017-02-27 22:54:19 +01:00
Dennis Mannhart a1982e0392 land_detector: battery level status to adjust maximum altitude possible 2017-02-27 22:54:19 +01:00
Dennis Mannhart c8690fd072 mc_pos_control: limit altitude
mc_pos_control: delete spaces

mc_pos_control: cleanup and threshold for velocity control to altitude control when close to max altitude
2017-02-27 22:54:19 +01:00
Michael Schaeuble 497a210742 lis3mdl: Fix check_calibration() output
The previous implementation returned OK when the sensor was not calibrated and vice
versa. This fixes a preflight fail due to selftest failed.
2017-02-27 22:52:28 +01:00
Daniel Agar cff430e137 px4fmu-v2 enable ll40ls and frsky_telemetry
- closes #6686
 - closes #6294
2017-02-27 22:52:06 +01:00
Lorenz Meier 5c524e15f8 Battery params: Enforce system reboot 2017-02-27 16:37:08 +01:00
Michael Schaeuble 3961c46d68 UAVCAN: Incorporate manual loackdown
This flag is triggered when the manual kill switch is activated. The motors
did not stop when the kill switch was engaged before adding this check.
2017-02-27 12:48:30 +01:00
Julian Oes 12c7421be9 px_uploader.py: remove unused exception vars 2017-02-27 11:23:09 +01:00
Julian Oes 974a9a0673 px_uploader.py: enable file to be used as module
In order to use px_uploader as a module from another Python script, all
the action needs to be moved into a main() function which is only called
if the file is run directly.
2017-02-27 11:23:09 +01:00
Julian Oes 090d7ebd6b px_uploader: fix SerialException error
Sometimes right after reboot, we got a `raise SerialException(
msg.errno, "could not open port {}: {}".format(self._port, msg))`.
If this happens now, we will just try again later.
2017-02-27 11:23:09 +01:00
Julian Oes b0a8073e15 px_uploader.py: small whitespace fix
Found by PEP8 checker.
2017-02-27 11:23:09 +01:00
Julian Oes ff87d43be0 px_uploader.py: vim modeline for indent settings 2017-02-27 11:23:09 +01:00
Julian Oes 172f35042f px_uploader.py: use consistent indenting
This file had the indentending mixed up between 4 and 8 spaces.
This changes it to the Pythonic way of 4 spaces.
2017-02-27 11:23:09 +01:00
Lorenz Meier 16530e15db Commander: Differentiate between emergency battery level and critical battery level 2017-02-27 09:03:20 +01:00
Lorenz Meier 029c6de4a9 Battery estimator: Warn on dangerously low levels.
We need to differentiate between a level where the user should act and where we are about to fall out of the sky (emergency). This helps performing more suitable failsafe actions.
2017-02-27 09:03:20 +01:00
Lorenz Meier 7372014aee Battery: Implement an emergency warn level 2017-02-27 09:03:20 +01:00
Beat Küng 85708063d6 fix tap_esc: use correct ORB_ID for esc_status advertisement 2017-02-27 08:52:43 +01:00
Lorenz Meier 7710b64d27 Navigator: Re-initialize RTL every time it gets re-enabled 2017-02-26 13:26:52 +01:00
José Roberto de Souza 6ce5807240 mavlink: Send message to control onboard camera as broadcast
The target was it self.
2017-02-25 19:03:45 +01:00
Daniel Agar c1bd0d5733 sync attitude setpoint messages 2017-02-25 17:57:05 +01:00
Daniel Agar fe4ea6dd63 VTOL mc_pos reset internal state during FW mode 2017-02-25 17:57:05 +01:00
Daniel Agar 1b2973f602 VTOL fw_att don't reset integrators during transition 2017-02-25 17:57:05 +01:00
Lorenz Meier e18fe0a8a8 Port PWM command to POSIX 2017-02-25 11:07:25 +01:00
Matthias Grob 8fd27fddcd mc_pos_control: moved responsibility of the x,y stick deadzone to a mathematical function
to prevent a setpoint step when moving the stick over the border of the deadzone
and to enable very small inputs even from a control stick that needs a big deadzone
2017-02-25 11:05:53 +01:00
Lorenz Meier ad3d0391ab Navigator: Only update params as they change 2017-02-25 11:04:52 +01:00
Daniel Agar ecb2511a7b add matrix copyTo 2017-02-25 11:04:02 +01:00
Beat Küng f43f3baa02 ATT_VIBE_THRESH param: move the definition of this param to sensors
since it's only used in sensors module (otherwise it could get pruned)
2017-02-25 11:02:15 +01:00
Beat Küng 3cc1c9d0a9 param command: warnx -> PX4_{WARN,ERR} 2017-02-25 11:02:15 +01:00
Beat Küng cfa84954ea param_get: add null-pointer check
If param_find() returned PARAM_INVALID, and this was directly passed to
param_get(), param_get_value_ptr() returned null and we read garbage data
(or segfaulted on systems with virtual memory).
On px4fmu-v2, this happened for the param ATT_VIBE_THRESH in sensors.
Because of the recently added parameter scoping, this param got pruned, as
it's defined in attitude_estimator_q.

credits for finding this go to Jeyong Shin (jeyong).
2017-02-25 11:02:15 +01:00
Lorenz Meier 3e88b2f2b1 Rate-limit navigator update rate 2017-02-24 08:52:10 +01:00
Kabir Mohammed 80e1064523 mavlink : fix legacy vision interface attitude timestamps 2017-02-24 08:51:05 +01:00
Beat Küng 058bc97c83 commander preflight calibration: accept param6 == 2 for airspeed calibration as well
This is according to the updated mavlink spec to deconflict the definition
with APM.
2017-02-24 08:24:53 +01:00
Matthias Grob 3a358422c4 mc_pos_control: change sign for close to ground + style fix 2017-02-23 23:26:17 +01:00
Dennis Mannhart de9d05c292 mc_pos_control: uorb home_postition subscription 2017-02-23 23:26:17 +01:00
Kabir Mohammed 3bc8617224 Update maintainers list 2017-02-23 22:37:18 +01:00
José Roberto de Souza 8d50249e8f ROMFS: common: Start aerofc_adc in AeroFC
Probably this was a merge error.
2017-02-23 22:37:01 +01:00
Matthias Grob e6031a97fa land_detector: added a parameter for the manual land detection stick throshold
because it is definitely something that needs to be allowed to tune or disable for different application scenarios
2017-02-23 13:18:49 +01:00
José Roberto de Souza ef228b82aa boards: AeroFC: Make it a memory constrained system
The maximum number of missions was increased in almost 8 times in
recent commit: 9369262e63 navigator: allow more mission items.

As this board loads missions in RAM, now it don't have enough memory
to allocate causing dataman start to fail, so mark it as a memory
constrained system and reduce the number of maximum missions
supported.
2017-02-23 08:26:42 +01:00
José Roberto de Souza b1c11b14a8 ROMFS: common: AeroFC: Do not start MAVLink over USB
STM32 pins are not exposed in AeroFC, so lets save some memory here.
2017-02-23 08:26:42 +01:00
José Roberto de Souza b372d15443 drivers: tap_esc: Fix low on stack warning
WARN  [load_mon] tap_esc_main low on stack! (284 bytes left)
2017-02-23 08:26:42 +01:00
Roman 4bffb1478f ekf2: added parameter for range sensor pitch offset
Signed-off-by: Roman <bapstroman@gmail.com>
2017-02-22 22:21:41 +01:00
Roman 3fdbe13857 updated ecl 2017-02-22 22:21:41 +01:00
Matthias Grob 3183cbda90 land_detector: manual land detection stick throshold less strict
Even for well calibrated RC sticks 5% stick movement is a too small margin for the end user that might not land because of this.
15% is still clearly restricting the stick far down.
2017-02-22 21:56:41 +01:00
Dennis Mannhart cbc54c9917 mc_pos_control: only swithc to velocity control from hold_engaged when user moves stick 2017-02-22 20:48:40 +01:00
Lorenz Meier d7683e97a3 MC pos control: More landing handling 2017-02-22 09:33:12 +01:00
Lorenz Meier c55fa9dd3f MC pos control: add option to use takeoff yaw 2017-02-22 09:21:20 +01:00
Lorenz Meier d11e4915f6 Vehicle control state: Add support for global yaw 2017-02-22 09:21:20 +01:00
Lorenz Meier 4ddc7e22fb MC pos ctrl: Force slow landing speed below min loiter altitude 2017-02-21 22:01:20 +01:00
Lorenz Meier 1d370f3470 MC pos control: Improve landing handling 2017-02-21 21:57:18 +01:00
Dennis Mannhart 20604989bb mc_pos_control: have same acceleration max for xy and z 2017-02-21 21:50:00 +01:00
Dennis Mannhart 2788cf8ffc mc_pos_control: manual stick input fix; deletion of unusued function 2017-02-21 16:47:46 +01:00
Lorenz Meier 7fc8ee85fa Commander: Do not break out of RTL on stick input change 2017-02-21 13:56:31 +01:00
Paul Riseborough bf06066010 Tools: Add scripts for ecl EKF log file analysis 2017-02-20 07:53:07 +01:00
Paul Riseborough ed5c8913ad events: update documentation for polyfit algorithm 2017-02-20 07:53:07 +01:00
Andreas Antener 11484b0d51 Rattitude: set default threshold for multicopter rattitude mode to 0.8 which enables it right away when selecting it 2017-02-18 08:03:19 +01:00
Andreas Antener 44d05bac55 Rattitude: enable for FW in old style switch mapping 2017-02-18 08:03:19 +01:00
Daniel Agar e81e6a8296 fw_att_control add rattitude mode 2017-02-18 08:03:19 +01:00
Daniel Agar 9120082b0c fw_att_control stabilized mode publish att_sp quat 2017-02-18 08:03:19 +01:00
Daniel Agar 12e5aca028 fw_att_control remove unused accel sub 2017-02-18 08:03:19 +01:00
Andreas Antener bd0cd35ff8 Convergence: fix motor output meta data 2017-02-18 08:03:19 +01:00
Daniel Agar f6eecf4d5c commander tests group TRANSITION_CHANGED tests 2017-02-18 08:03:19 +01:00
Daniel Agar c14c9c20eb commander tests allow FW ACRO 2017-02-18 08:03:19 +01:00
Andreas Antener 998427f821 ECL: updated to proper commit 2017-02-18 08:03:19 +01:00
Andreas Antener 8683739fec Convergence: updated tuning 2017-02-18 08:03:19 +01:00
Andreas Antener 459b8b7c7e FW att: removed unused fields again 2017-02-18 08:03:19 +01:00
Andreas Antener e04fe593e0 Tiltrotor: option to enable differential thrust in forwards flight 2017-02-18 08:03:19 +01:00
Andreas Antener b19cd19411 FW Acro: udpate ECL and implemented fixed-wing Acro 2017-02-18 08:03:19 +01:00
Andreas Antener 2f3b1edbd4 Convergence: increase yaw output in mixer 2017-02-18 08:03:19 +01:00
Andreas Antener 986fa1d52f Sublime: exclude build folders 2017-02-18 08:03:19 +01:00
Andreas Antener a5f3f65c2b Switch assignment: added manual and stabilized switch for a default stabilized switch scheme, let FW go into Acro 2017-02-18 08:03:19 +01:00
Beat Küng 21f5219bbc vehicle_command.msg: add PREFLIGHT_CALIBRATION_TEMPERATURE_CALIBRATION 2017-02-17 23:01:25 +01:00
Beat Küng e4ca10363b mavlink MAV_CMD_IMAGE_START_CAPTURE message: send request for highest resolution 2017-02-17 23:01:25 +01:00
Beat Küng 1a81b64d49 VEHICLE_CMD_PREFLIGHT_CALIBRATION: update temperature_calibration param definition 2017-02-17 23:01:25 +01:00
Lorenz Meier 51c8e90508 FW att control: Increase stack size to ensure limits 2017-02-17 22:31:55 +01:00
Lorenz Meier bbc5186e2a GPS driver: Improve GPS "fake" mode init and code style 2017-02-17 22:28:55 +01:00
Lorenz Meier 495e16d510 Uploader script: Fix Python 2 issue and timing corner case on Mac OS, both in a robust fashion 2017-02-17 22:28:14 +01:00
James Goppert 7659402fdb WIP: valgrind runtime analysis and fixes (#6521)
* Fix several valgrind identified mem leaks

* Added callgrind target.

* px4_posix_tasks use nullptr
2017-02-17 12:36:52 -05:00
Beat Küng a0f00f84f3 param show command: add -c to show only changed, do case insensitive comparison 2017-02-17 11:27:08 +01:00
Beat Küng a4050db766 param: comment what the lock is needed for 2017-02-17 11:27:08 +01:00
Beat Küng b4b5c987a6 unittests: add setup code to call param_init() 2017-02-17 11:27:08 +01:00
Beat Küng df8f0da70c param & param_shmem: enable locking
We need to protect access to the param_values array. This is dynamically
allocated and resized (utarray_reserve() calls realloc). If some thread
was iterating the array while another was resizing the array, the first one
would iterate on a freed array, thus accessing invalid memory.

On NuttX this could lead to hardfaults in rare conditions.

Unfortunately we need to initialize the semaphore on startup, by calling
sem_init(). This adds a param_init() method called by every board/config
that uses the params (at least I think I've found all of them)
2017-02-17 11:27:08 +01:00
Beat Küng fa3a6b890c param & flashparam param_export: use value directly instead of calling param_get
This call is not needed, and will avoid deadlocks when locking is enabled.
2017-02-17 11:27:08 +01:00
Beat Küng 42967df63f param command: use param_* calls even if flash-based params are enabled
This will ensure proper locking.
2017-02-17 11:27:08 +01:00
Beat Küng 68bee1b847 flashparams: remove the locking stubs
locking will be done in the params module
2017-02-17 11:27:08 +01:00
James Goppert 85f62f5da0 Fix param scoping to use cmake for parsing. 2017-02-17 11:26:46 +01:00
Lorenz Meier 44c8857354 MAVLink app: Update incorrect comment 2017-02-17 10:00:11 +01:00
Phillip Kocmoud e4afce8b1b Add the 20602 start command for the AUAV x2.1 to the ROMFS rc.sensors file 2017-02-17 09:18:22 +01:00
Phillip Kocmoud 36e2bc8ae7 Fix AUAV X2.1 Board Config for 20608
These changes were required to fix support for the ICM-20608 after this commit:

https://github.com/PX4/Firmware/commit/f746141afe3499ae56e75b3db06409381ead2f4b

This has been tested!
2017-02-17 09:17:41 +01:00
klopezal 6baf6fc666 Board config : correct GPIO init for px4fmu-v4pro 2017-02-17 09:16:23 +01:00
Michael Schaeuble 0d61e22d9b mavlink: Buffer UAVCAN parameter re-requests
We buffer the mavlink messages and don't forward them directly
via uORB. This solves an issue where many requests are dropped and
QGC does not start properly in combination with UAVCAN devices.
2017-02-17 09:15:56 +01:00
José Roberto de Souza 172e218dbd Commander: Use leds to show PX4 status on AeroFC 2017-02-17 09:13:33 +01:00
José Roberto de Souza aa8fa2ae05 drivers: AeroFC: Add more leds
Also change the initial state of the leds to off.
2017-02-17 09:13:33 +01:00
José Roberto de Souza 83a387a553 drivers: Led: Do not initialize twice 2017-02-17 09:13:33 +01:00
Lorenz Meier d66d7a4932 Navigator: Fix code style 2017-02-17 09:13:13 +01:00
Lorenz Meier 798a7ed8cd Commander: Fall back to GPS enabled modes once GPS becomes available 2017-02-17 09:13:13 +01:00
Lorenz Meier 070a73ad63 Commander: Switch into right mode in various corner conditions
* If you move in LAND, AUTO or HOLD the sticks the system will give control back to the pilot
  * If you do not connect any RC the system will default to HOLD and will allow you tablet control
  * If you gain position lock for the first time the system will re-evaluate the mode switch (so if you dropped down to alt hold it will now go into position)
  * If the system breaches the Geofence it will now always drop back to POSCTRL if the sticks are moved
2017-02-17 09:13:13 +01:00
Lorenz Meier c8fb21e73e Navigator: Enforce a minimum altitude for RTL 2017-02-17 09:13:13 +01:00
Paul Riseborough 72633ad4c8 events: update documentation for polyfit algorithm 2017-02-16 22:17:47 +01:00
Lorenz Meier 7bd8514697 PWM out sim: Do not obey hardware lockdown flag 2017-02-16 12:34:51 +01:00
Kabir Mohammed ea5caf258f mavlink : fix vision debug stream attitude update 2017-02-16 09:53:15 +01:00
Lucas De Marchi 47411b052c aerofc: test 115200 and 460800 baud rates
We still want to be able to program the flight stack if the user changes
the baudrate of that UART.
2017-02-16 09:35:23 +01:00
Lucas De Marchi f9795ccbab px_uploader: support multiple baud rates
We may need to change the baud rate from one version to the other.
Allowing the script to try multiple baud rates makes the transition a
little bit less painful.

This also fixes a bug in which it would go the next port before trying
to identify the board after asking it to reboot.
2017-02-16 09:35:23 +01:00
Lucas De Marchi 6121119631 ROMFS: allow to use 460800 baudrate for onboard mode 2017-02-16 09:35:23 +01:00
Siddharth Bharat Purohit ab465744f1 temp_cal: add math explanation for polynomil fit algo 2017-02-16 09:34:19 +01:00
yaoling 0e34de08fb Update send_event.cpp
do same as command module
2017-02-16 09:33:16 +01:00
Daniel Agar 9bc5da6d2d update matrix and fix test_matrix (#6524) 2017-02-16 00:31:06 -05:00
aivian 7a77e27a79 fixed wing offboard attitude setpoint fix (#6112) 2017-02-15 23:51:50 -05:00
Daniel Agar a84dc2e3d2 clang-tidy disable cert-msc50-cpp rand() check 2017-02-15 22:29:24 -05:00
Daniel Agar fd11c3f7b1 clang-tidy disable cert-msc30-c rand() check 2017-02-15 22:29:24 -05:00
Daniel Agar 1bbca3bf1d test_dataman add to SITL with minor updates 2017-02-15 22:29:24 -05:00
Julian Oes 9369262e63 navigator: allow more mission items
Since using more than 256 mission items has been tested and fixed, the
limit can now be raised to more than 256 (but smaller than UINT16_MAX).

Since the whole file is allocated in advance on NuttX, the limit there
is (arbitrarily) set to 2000. For POSIX archs such as SITL, we don't
really need to constrain ourselves any longer.
2017-02-15 22:29:24 -05:00
Julian Oes 8c1e85a65f dataman: don't wrap around at 256
The dataman started overwriting contents after 256 items because the
item index were only uint8_t. This fix allows for more than 256
waypoints.
2017-02-15 22:29:24 -05:00
Lorenz Meier 081c40c6fa Commander: Fix level cal command 2017-02-15 22:16:20 +01:00
Kabir Mohammed e63747ec2f lpe : changes to allow hybrid GPS-denied navigation 2017-02-15 21:48:33 +01:00
Kabir Mohammed 0f91378eeb lpe : use vision timestamps to compute measurement delay 2017-02-15 21:48:33 +01:00
Kabir Mohammed 85df00d2da lpe : use per-measurement variance for vision 2017-02-15 21:48:33 +01:00
Kabir Mohammed 48e7b94162 mavlink : track time offset faster 2017-02-15 21:48:33 +01:00
Kabir Mohammed d831c262d0 mavlink : fix code style 2017-02-15 21:48:33 +01:00
Kabir Mohammed 444005f290 logger : Log new vision topics 2017-02-15 21:48:33 +01:00
Kabir Mohammed 3653d64b31 att_ekf : move to new vision topics 2017-02-15 21:48:33 +01:00
Kabir Mohammed c65b8fffd3 sdlog2 : log new vision topic 2017-02-15 21:48:33 +01:00
Kabir Mohammed a158d7f124 att_q : move to new vision attitude topic 2017-02-15 21:48:33 +01:00
Kabir Mohammed bdcc626f29 mavlink : correct stream name for vision message 2017-02-15 21:48:33 +01:00
Kabir Mohammed f43ee3a0f5 mavlink : use new vision estimate topic and fix stream name 2017-02-15 21:48:33 +01:00
Kabir Mohammed 294663854d inav : move to new vision topic 2017-02-15 21:48:33 +01:00
Kabir Mohammed 7236bafee1 ekf2 : move to new vision topic 2017-02-15 21:48:33 +01:00
Kabir Mohammed 8eaddeee0a lpe : move to new vision topic 2017-02-15 21:48:33 +01:00
Kabir Mohammed f8775306d3 Remove deprecated vision_position_estimate topic 2017-02-15 21:48:33 +01:00
Kabir Mohammed b643c94f0a mavlink_receiver : Switch VISION_POSITION_ESTIMATE to new topics 2017-02-15 21:47:51 +01:00
Kabir Mohammed 569251dc2e mavlink_receiver : Add external estimator interface 2017-02-15 21:47:51 +01:00
Sander Smeets 75f6b4eb0c Readme changes 2017-02-15 21:15:27 +01:00
José Roberto de Souza b7c53342dc ROMFS: AeroFC: Start dataman with RAM backend
AeroFC don't have a SD Card or any other storage device, so changing
dataman backend to work over RAM to be able to load missions.
2017-02-15 21:13:13 +01:00
Roman 8c9f27bb8a land detector (mc): takeoff throttle should be the same for all manual,
altitude controlled modes

Signed-off-by: Roman <bapstroman@gmail.com>
2017-02-15 15:41:44 +01:00
Phillip Kocmoud ccfecd4ad2 Add support for the ICM-20602 to the Pixracer FMUv4 (#6577)
The current ICM-20608 is nearing EOL.

I have tested on both ICM-20608 and ICM-20602 based Pixracers.
2017-02-14 06:37:04 -10:00
Daniel Agar 8c837e72be fixedwing_control example fix fds init (#6575) 2017-02-13 22:23:16 -05:00
Julian Oes 4ee8c43ea2 mavlink: send attitude quaternion in onboard mode 2017-02-13 21:38:10 +01:00
David Sidrane 7e425c8ff2 Disable bl_upload command on non F4 tartgets
Upstream nuttx needs to have the flash programing support added.
2017-02-13 21:37:38 +01:00
David Sidrane 94450eb43a Use PX4_FLASH_BASE from micro HAL 2017-02-13 21:37:38 +01:00
David Sidrane a2fa199a26 Define PX4_FLASH_BASE in micro HAL 2017-02-13 21:37:38 +01:00
Lorenz Meier dfd02d8372 Plane interface: Fix motor scaling in simulator 2017-02-13 21:33:01 +01:00
Lorenz Meier 7f4601a50f Plane: Fix motor scaling 2017-02-13 21:32:46 +01:00
ChristophTobler 0263ab8cd2 enable takeoff in gps denied areas and minor requested changes 2017-02-13 21:11:25 +01:00
ChristophTobler 64092f087f fix landing angle if no gps 2017-02-13 21:11:25 +01:00
ChristophTobler 6a60ff9dc3 fix code style 2017-02-13 21:11:25 +01:00
ChristophTobler 52f5f1be07 update submodule ecl 2017-02-13 21:11:25 +01:00
ChristophTobler 1f7fdb2386 allow local position for takeoff (e.g. flow) 2017-02-13 21:11:25 +01:00
Matthias Grob 194f0c1de8 land_detector: ground detection corrected comment and clarified condition 2017-02-13 11:34:10 +01:00
Matthias Grob 9963cf532d land_detector: refactored helper method names 2017-02-13 11:34:10 +01:00
Matthias Grob c559f195ec land_detector: Hotfix to prevent ground contact detection when descending velocity is very slow with manual stick all the way down
Now the stick down check is only done in manual control and the thrust low is again mandatory to detect ground in any case.
2017-02-13 11:34:10 +01:00
klopezal b5858e729c lis3mdl : correct offset and scale checks 2017-02-12 13:52:41 +01:00
Kevin 1167fba9ad px4fmu-v4pro : adding correct logic for overcurrent sensing 2017-02-12 13:52:41 +01:00
Kevin 1ce0bafebd lis3mdl : fix logic in check functions and code style 2017-02-12 13:52:41 +01:00
Kevin 62b4d2de0d Fixing code style 2017-02-12 13:52:41 +01:00
klopezal f09b60ad9e lis3mdl : several fixes and enhancements 2017-02-12 13:52:41 +01:00
klopezal 089e50c574 px4fmu-v4pro : board configuration 2017-02-12 13:52:41 +01:00
Daniel Agar b14cb952ae sitl plane update tuning 2017-02-12 11:03:51 +01:00
Daniel Agar ff68d63143 fw_pos_control_l1 force heading hold at flare 2017-02-12 11:03:51 +01:00
Daniel Agar 94d6a92f41 fw_pos_control_l1 publish quat in att_sp 2017-02-12 11:03:51 +01:00
Daniel Agar feda5caac2 commander state machine helper fix style and remove unused 2017-02-12 10:29:59 +01:00
Daniel Agar d0b188f585 commander FW don't allow FOLLOW or OFFBOARD 2017-02-12 10:29:59 +01:00
Paul Riseborough 1f4155c208 events: fix code style issues 2017-02-12 09:21:37 +01:00
Paul Riseborough 9858b0b491 sensors: Add calibration control parameters to QGC list 2017-02-12 09:21:37 +01:00
Paul Riseborough 36f83e46ee events: abort calibration if starting temperature is too high 2017-02-12 09:21:37 +01:00
Paul Riseborough 22c8c59829 Thermal Calibration - add parameter required to control max starting temperature 2017-02-12 09:21:37 +01:00
Paul Riseborough 93a70c2d0b systemlib: Fix parameter name error 2017-02-12 09:21:37 +01:00
Paul Riseborough f3d30564ed events: don't start baro calibration until specified temperature achieved 2017-02-12 09:21:37 +01:00
Paul Riseborough e75f2b9cf7 events: don't start accel calibration until specified temperature achieved 2017-02-12 09:21:37 +01:00
Paul Riseborough cdf80a868a events: don't start gyro calibration until minimum temperature achieved 2017-02-12 09:21:37 +01:00
Paul Riseborough c901c4b39e Thermal Calibration - add parameter required to control minimum starting temperature 2017-02-12 09:21:37 +01:00
Paul Riseborough 693cc4a533 Update SYS_CAL_TEMP parameter name and description
We will be adding another parameter to set min starting temp, so this name needs to be made less generic.
Fixes typographical errors in the description
2017-02-12 09:21:37 +01:00
David Sidrane c685cdbfce Use the NuttXs progmem api to progrem flash 2017-02-12 08:57:29 +01:00
bharath374 6013c273bf Added 8x96 mode to Snapdragon Flight sanity test script 2017-02-12 08:46:50 +01:00
Lucas De Marchi 72e628f6e0 aerofc: use autodetection for MS5611 driver 2017-02-09 21:30:19 +01:00
Lucas De Marchi 62ea471ae7 ms5611: support MS5611/MS5607 autodetection
From their registers it's not possible to differentiate MS5611 from
MS5607. Here we use a little heuristic that people won't likely be
flying (or starting to fly) on very high altitude, greater than 5300m.
Even on these altitudes the error would be much lower using the MS5611
calculations for MS5607 than it is on MSL.
2017-02-09 21:30:19 +01:00
Daniel Agar 80c8130f07 sensors true airspeed fix
- _voted_sensors_update.baro_pressure() is already in pascals
2017-02-09 21:29:03 +01:00
David Sidrane d0d7955414 Hotfix:STM32 and STM32F7 Fixes the bkp reference counter issue
See https://groups.yahoo.com/neo/groups/nuttx/conversations/topics/14362
2017-02-09 21:12:23 +01:00
Julian Oes aaa24b0cc8 Reduce attitude rate but add Quaternion 2017-02-08 12:47:34 +01:00
Daniel Agar 317595cff3 SYS_COMPANION add 115200 normal telem 2017-02-08 08:35:29 +01:00
Beat Küng 08f0524b58 camera_trigger: remove unused fields _gpio_fd and _p_pin 2017-02-07 13:36:16 +01:00
Beat Küng 507e3b0263 camera_trigger: add TRIG_INTERFACE=3 for Mavlink forwarding 2017-02-07 13:36:16 +01:00
Beat Küng 212502b2b1 camera_trigger: make sure it builds for SITL & add to SITL cmake 2017-02-07 13:36:16 +01:00
Beat Küng 882146785c camera_trigger: rename info command to status
to be consistent with the rest of the system
2017-02-07 13:36:16 +01:00
Beat Küng d6c54e4240 camera_trigger: remove params from build 2017-02-07 13:36:16 +01:00
Paul Riseborough 5567170a26 Tools: update offline sensor calibration script
Fix typographical error
2017-02-07 11:01:22 +01:00
Lorenz Meier f68e34ce40 Update DF to fix Snapdragon scheduling issues 2017-02-06 21:55:29 +01:00
Dennis Mannhart 57b7c4fc3d mc_pos_control: code style fix 2017-02-06 19:10:42 +01:00
Dennis Mannhart f0978fc9e9 mc_pos_control: set position setpoint during transition based on veloicyt and acceleration 2017-02-06 19:10:42 +01:00
Dennis Mannhart c141d4ca3f mc_pos_control: turn off thrust xy when in position hold and altitude hold and thrust z is low 2017-02-06 19:10:42 +01:00
David Sidrane 602279ad56 zubaxgnss-v1 bootloader uses mfguid for hw_version unique_id 2017-02-04 22:27:04 +01:00
David Sidrane 29888659f2 s2740vc-v1 bootloader uses mfguid for hw_version unique_id 2017-02-04 22:27:04 +01:00
David Sidrane c52a8544c1 px4flow-v2 bootloader uses mfguid for hw_version unique_id 2017-02-04 22:27:04 +01:00
David Sidrane 050b909b20 px4esc-v1 bootloader uses mfguid for hw_version unique_id 2017-02-04 22:27:04 +01:00
David Sidrane 23ecb78552 px4cannode-v1 bootloader uses mfguid for hw_version unique_id 2017-02-04 22:27:04 +01:00
David Sidrane 278d6bb717 esc35-v1 bootloader uses mfguid for hw_version unique_id 2017-02-04 22:27:04 +01:00
David Sidrane a8706ad001 uavcannode uses mfgid for hwver.unique_id 2017-02-04 22:27:04 +01:00
David Sidrane d22a41bb70 uavcanesc uses mfgid for hwver.unique_id 2017-02-04 22:27:04 +01:00
David Sidrane 9672898a33 uavcan uses mfgid for hwver.unique_id 2017-02-04 22:27:04 +01:00
David Sidrane 8ba1ffafec mavlink uses simpler common bord indentity api 2017-02-04 22:27:04 +01:00
David Sidrane 138f0378a7 logger uses simpler common bord indentity api 2017-02-04 22:27:04 +01:00
David Sidrane 473c211eb0 gyro_calibration uses simpler common bord indentity api 2017-02-04 22:27:04 +01:00
David Sidrane 7600aa51f7 Remove fmu id command as it is redundant to ver uid
This command was redudnat to "fmu uid|all" However it
 printed the leading zeros.
2017-02-04 22:27:04 +01:00
David Sidrane 53df80881a ver uses simpler common board indentity api and displays mfguid 2017-02-04 22:27:04 +01:00
David Sidrane 3668047e6c board_serial uses simpler common bord indentity api 2017-02-04 22:27:04 +01:00
David Sidrane bc8b117e85 common board idenity cleanup and add mfguid to api
Remove the notion of legacy from the api. The board level code
   will perform the traslation to lecacy format on the STM32.
   new targets will not need to do this as there is no case
   where the serial number were used by mfg for tracking.

   Extend board common api to get mfguid and mfguid formatted

   This adds an api that return the MFGUID as an array of bytes
   or a string.

   The data is returned with the MSD at index 0 and the LSD at
   index PX4_CPU_MFGUID_BYTE_LENGTH-1.

   Removed all reodering defines from the api and hal
2017-02-04 22:27:04 +01:00
Simone Guscetti b182a5eeca Added the vehicle_status_flags publisher with the conversion in a bit field in commander 2017-02-04 21:13:59 +01:00
Simone Guscetti 2c2addad53 Add new message vehicle_status_flags for the commander status_flags 2017-02-04 21:13:59 +01:00
Lorenz Meier 6bd29b24f6 POSIX: Avoid missing prototype warning on some POSIX platforms 2017-02-04 21:06:21 +01:00
Lorenz Meier 82fa9a8d43 Update return type for power management call 2017-02-04 21:06:21 +01:00
Lorenz Meier bf448fce71 Commander: Update call for new power management interface 2017-02-04 21:06:21 +01:00
Lorenz Meier ce921345cf POSIX: Stub power management support 2017-02-04 21:06:21 +01:00
Lorenz Meier 4f1842c9c4 TAP v1 config: Add support for external power management calls 2017-02-04 21:06:21 +01:00
Lorenz Meier 1ad03ed8ef Common: Add support for power management (on / off) from the flight controller side 2017-02-04 21:06:21 +01:00
Lorenz Meier 565a43dee0 Aero FC v1: Remove unused power management file 2017-02-04 21:06:21 +01:00
Lorenz Meier f7fa374656 Implement default board power control to allow software switch-off 2017-02-04 21:06:21 +01:00
Lorenz Meier a92931fe84 Commander: Switch system off if in undervoltage condition and disarmed.
This is necessary to not have systems deep-discharge the battery while sitting idle. While at it we also deny arming in low battery conditions to ensure people who just landed with a low battery do not take off again and fail to get a successful RTL.
2017-02-04 21:06:21 +01:00
Lorenz Meier 6f84e79d70 Navigator: Fix takeoff handling if already in air
If the vehicle was already in air on takeoff and the waypoint gets converted to a regular waypoint the wait / delay time does not get reset to zero. This change ensures the next mission item is approached immediately.
2017-02-04 14:47:34 +01:00
Lorenz Meier 7fbc71f054 send event: Do use nullptr, not NULL 2017-02-04 14:46:51 +01:00
Beat Küng ffacc6f64a param SYS_STCK_EN: enable stack checking by default 2017-02-04 12:15:59 +01:00
Beat Küng 03dc991188 log_writer_file: adjust stack size
Stack size was below threshold of 300 by 8 bytes.
2017-02-04 12:15:59 +01:00
Beat Küng 5c2fa034da load_mon: rename low_stack -> task_stack_info & always publish it
- use uorb queue to not drop any info, only do 2 tasks per cycle
- also print a warning on low stack (which will be added to ulog)

this allows to gather statistics of each task's stack usage over time.
2017-02-04 12:15:59 +01:00
Beat Küng c02f1946eb load_mon: fix stack check: use up_check_tcbstack_remain()
The previous method did not work anymore since the NuttX upgrade.
2017-02-04 12:15:59 +01:00
Lorenz Meier 0e64f8c288 Matrix update with CLANG compile fix 2017-02-04 11:21:38 +01:00
Lorenz Meier 1b01546d4b Revert "Update matrix lib"
This reverts commit d75024b987.
2017-02-04 11:14:42 +01:00
Lorenz Meier d75024b987 Update matrix lib 2017-02-04 10:42:47 +01:00
Lorenz Meier bf26bec46c Fix gyro init 2017-02-04 10:38:11 +01:00
Lorenz Meier 72156fe9c1 Temp cal: Fix matrix initialization 2017-02-04 08:54:15 +01:00
Lorenz Meier 51e156e1f4 Code style fix 2017-02-04 08:54:00 +01:00
Stephan Brown 54cc212d46 test_autodeclination: Add world endpoints to test. 2017-02-04 08:52:04 +01:00
Stephan Brown 0d219caae3 geo_mag_declination: Fix interpolation when inputs are outside of sampling min and max. 2017-02-04 08:52:04 +01:00
Stephan Brown 20e7bd082a unittests: Remove geomag tests which are now covered in systemcmds tests. 2017-02-04 08:52:04 +01:00
Stephan Brown 614853b023 test_autodeclination: Update mag declination test value. 2017-02-04 08:52:04 +01:00
Stephan Brown bb0d01d812 geo_mag_declination: Update declination values according to 2015 NOAA data. 2017-02-04 08:52:04 +01:00
Stephan Brown fc34eef53a unittests: Add unittests for geo_mag_declination. 2017-02-04 08:52:04 +01:00
Stephan Brown ab9fa59dd2 geo_mag_declination: Fix table bounds checking. 2017-02-04 08:52:04 +01:00
Daniel Agar 384e3bb693 meas_airspeed status aspd_com_err 2017-02-04 08:47:37 +01:00
Beat Küng d3f71454cc posix_sitl_default.cmake: add modules/events
It's not used yet, just to make sure it compiles fine.
2017-02-03 13:57:48 +01:00
Beat Küng 0d000173b5 l3gd20 selftest: don't check for 0 offset
If temperature compensation is enabled, the offset will be 0
2017-02-03 13:57:48 +01:00
Beat Küng 32ed939ea4 param_shmem: readd dropped static to function definition 2017-02-03 13:57:48 +01:00
Beat Küng ea4d3d970b temperature_calibration: make sure to save the params after the process 2017-02-03 13:57:48 +01:00
Beat Küng 6583f73cfa temperature_calibration: reduce code duplication by adding a TemperatureCalibrationCommon class 2017-02-03 13:57:48 +01:00
Beat Küng 38b4984c36 temperature_calibration: make sure to call orb_unsubscribe() when objects are destroyed 2017-02-03 13:57:48 +01:00
Beat Küng 980c3bc6a7 temperature_calibration: notify system about param changes 2017-02-03 13:57:48 +01:00
Beat Küng b89b76fbe6 gyro_calibration: use param_notify_changes 2017-02-03 13:57:48 +01:00
Beat Küng 3eecd16309 accelerometer_calibration: use param_notify_changes 2017-02-03 13:57:48 +01:00
Beat Küng a802caca87 param: add param_notify_changes() method
Can be used for example after several calls to
param_set_no_notification() to avoid unnecessary system notifications,
as it is an expensive change.
2017-02-03 13:57:48 +01:00
Beat Küng 4b8e6cf9cd temperature_calibration: make sure to always do an orb_copy() even when already finished
... since we do poll() on the gyro fd.
2017-02-03 13:57:48 +01:00
Beat Küng d2dd61dfbd temperature_calibration: make sure to report an error only once 2017-02-03 13:57:48 +01:00
Simone Guscetti fe53e3a0d5 commander: add status_changed when battery is low 2017-02-03 13:53:51 +01:00
Beat Küng c4a8aa9c68 temperature_calibration: refactor to separate code & reduce code duplication 2017-02-02 23:54:06 +01:00
Beat Küng b6f3cf9425 events: refactor temperature_calibration command to take options and use a single vehicle_command
This makes it easier to start calibration for all sensors at once.
2017-02-02 23:54:06 +01:00
Beat Küng 603cd1e6dc refator events: move temperature calibration implementation into subdirectory 2017-02-02 23:54:06 +01:00
Paul Riseborough b36e65fd6d events: Improve consistency of console messages 2017-02-02 23:54:06 +01:00
Paul Riseborough 9e219fba0c events: make required temp rise for calibration adjustable 2017-02-02 23:54:06 +01:00
Paul Riseborough 4ff5e7c5ab systemlib 2017-02-02 23:54:06 +01:00
Paul Riseborough 8001db257c ROMFS: enable auto start of thermal calibration 2017-02-02 23:54:06 +01:00
Paul Riseborough 8aa91512e9 systemlib: Add parameters to control thermal calibration startup behaviour 2017-02-02 23:54:06 +01:00
Paul Riseborough f86347f1e2 Tools: Enable offline calibrator to handle less than 3 inertial sensors 2017-02-02 23:54:06 +01:00
Paul Riseborough 4d163eebb9 events: Add accelerometer and baro thermal calibration 2017-02-02 23:54:06 +01:00
Paul Riseborough f0c456dd54 events: give gyro cal unique names in preparation for other sensor types 2017-02-02 23:54:06 +01:00
Matthias Grob 9e80a6c9d6 sensors: rc filter no unstable cutoff, better initialisation, reset filter on change, constrain output
Filter gets unstable if cutoff is above sample rate/2.
Filter initial frequencies do not matter a lot because they get replaced by parameters anyways.
Filter delay values get reset to 0 when the filter is reconfigured otherwise there can be some weird spikes in the output.
Filter output gets constrained to the range again because of possible overshoot.
2017-02-02 21:24:05 +01:00
Matthias Grob 81dcba3a2a sensors: rc added low pass filter parameters 2017-02-02 21:24:05 +01:00
Matthias Grob c2be4b2b29 mc_pos_control: added exponential curve to manual x,y velocity setpoint
controlled by parameter MPC_XY_MAN_EXPO that is disabled (0) by default
2017-02-02 21:24:05 +01:00
Matthias Grob 661832ca1d mathlib: added exponential curve function 2017-02-02 21:24:05 +01:00
Matthias Grob d991285406 sensors: rc filter: added sample rate of 33.3Hz and lowpass cutoff 5Hz hardcoded for testing 2017-02-02 21:24:05 +01:00
Matthias Grob 27a4ce2691 sensors: rc added lowpass filters to the 4 main channels without useful samplerate and cutoff frequency yet 2017-02-02 21:24:05 +01:00
Matthias Grob a14dbdcfdb sensors: rc refactored min max ifs to constrain 2017-02-02 21:24:05 +01:00
David Sidrane 9527dd7714 Add auav-x21_default to the qgc firmware for distribution 2017-02-02 14:39:43 +01:00
Beat Küng 3dc6e7b574 LandDetector: use a 64bit counter for total system flight time
The previous 32bit counter wrapped in ~1.19h, this switches to 2 32bit
counters, wrapping in 584942 years.
2017-02-02 09:22:25 +01:00
Beat Küng 05b649cc86 LandDetector: fix total system flight time (landed & takeoff logic) 2017-02-02 09:22:25 +01:00
Dennis Mannhart f718b3a97a mc_pos_control: limit slewrate different in up and down direction 2017-02-02 09:04:59 +01:00
David Sidrane c976a26156 Use wild card *_PX4_* for upload
Compliments the Bootloader change To simplify the ripple effect on the tools, we will be using  /dev/serial/by-id/*_PX4_* to locate PX4 devices. Therefore  moving forward all Bootloaders must contain the prefix "PX4 BL "  in the USBDEVICESTRING
2017-02-02 08:50:09 +01:00
Daniel Agar 0eac637870 clang-tidy relax function-size.LineThreshold 2017-02-01 22:15:50 -05:00
Daniel Agar 9a2ce9a098 clang-tidy relax function-size.StatementThreshold 2017-02-01 22:15:50 -05:00
Daniel Agar b068c61784 clang-tidy clang-analyzer-core.NonNullParamChecker 2017-02-01 22:15:50 -05:00
Daniel Agar 345123bb04 clang-tidy readability-static-definition-in-anonymous-namespace 2017-02-01 22:15:50 -05:00
Daniel Agar b59ab8b663 clang-tidy remove TODOs
- readability-avoid-const-params-in-decls
 - readability-named-parameter
2017-02-01 22:15:50 -05:00
Daniel Agar 6f05fec335 clang-tidy performance-unnecessary-copy-initialization 2017-02-01 22:15:50 -05:00
Daniel Agar 7e5f09f408 clang-tidy performance-unnecessary-value-param 2017-02-01 22:15:50 -05:00
Daniel Agar be5764db48 clang-tidy misc-suspicious-missing-comma 2017-02-01 22:15:50 -05:00
Daniel Agar edd564b5a9 clang-tidy list all available checks 2017-02-01 22:15:50 -05:00
Daniel Agar 37a2e331c4 clang-tidy test_bson memcmp check return 2017-02-01 22:15:50 -05:00
Daniel Agar 070cd55636 clang-tidy readability 2017-02-01 22:15:50 -05:00
Daniel Agar b33d49c77d state_machine_helper use static_assert 2017-02-01 22:15:50 -05:00
Daniel Agar 4e3b4091e8 run-clang-tidy only display output on error 2017-02-01 22:15:50 -05:00
Daniel Agar 226148ea8b import llvm 4.0 run-clang-tidy.py 2017-02-01 22:15:50 -05:00
Daniel Agar ca09f8a107 uORBDevices use global read with stdin int 2017-02-01 22:15:50 -05:00
Daniel Agar 73da6d30d9 clang-tidy errors cause target failure 2017-02-01 22:15:50 -05:00
Daniel Agar 96e51f7c59 clang-tidy remove redundant 2017-02-01 22:15:50 -05:00
Daniel Agar 6631e72d6f clang-tidy modernize-redundant-void-arg 2017-02-01 22:15:50 -05:00
Daniel Agar e927f3e040 clang-tidy modernize-use-nullptr 2017-02-01 22:15:50 -05:00
Lorenz Meier ec2467d4a5 MPC controller: Do not initialize to zero dt but a likely default dt 2017-02-01 20:06:31 +01:00
Dennis Mannhart 299c40f627 mc_pos_control: timestamp fix for vel_sp 2017-02-01 18:30:31 +01:00
Bart Slinger a66a25b884 sdlog2_dump.py skip unknown message type 2017-02-01 11:31:08 +01:00
Beat Küng 80c348d3b0 temperature_compensation: fix return value for set_sensor_id
got dropped during rebase cleanup
2017-02-01 08:40:23 +01:00
Beat Küng c07fd1a360 mc_att_control_main: fix style 2017-02-01 08:40:23 +01:00
Beat Küng 4f6e379e50 temperature_compensation: use const for reference 2017-02-01 08:40:23 +01:00
Paul Riseborough 7d8ce9ab9c sensors: Fix bug in temperature offset calculation 2017-02-01 08:40:23 +01:00
Beat Küng c0fd3afc8c accelerometer_calibration: only notify system once (after last scale change) 2017-02-01 08:40:23 +01:00
Beat Küng 998a407148 SITL: better formatting of help output 2017-02-01 08:40:23 +01:00
Paul Riseborough 0a447e9a93 Tools: update instructions for off-board calibrator 2017-02-01 08:40:23 +01:00
Paul Riseborough e78c5155a2 Tools: update calibration instructions 2017-02-01 08:40:23 +01:00
Paul Riseborough 253683af5f drivers: Don't require driver level gyro offsets to be non-zero 2017-02-01 08:40:23 +01:00
Paul Riseborough bdbc4f4d65 commander: fix bug in gyro calibration
If the same gyro data was contained in two uORB instances, the thermal offset coefficient was being corrected twice.

TODO should fix what was causing data from the same sensor to appear on two uORB topics.
2017-02-01 08:40:23 +01:00
Paul Riseborough 6e841f6cbd commander: fix bugs in handling of thermal compensation during access cal 2017-02-01 08:40:23 +01:00
Paul Riseborough 06f280e021 Tools: reinstate original offline calibrator to unblock testing
Refactored calibrator is not working.
2017-02-01 08:40:23 +01:00
Beat Küng 0220875961 fix temperature_calibration: reverse order of polynom coefficients 2017-02-01 08:40:23 +01:00
Beat Küng d84e55878a temperature_calibration: remove unused include <vector> 2017-02-01 08:40:23 +01:00
Beat Küng e31958cad1 voted_sensors_update: don't report failover if previous index is invalid 2017-02-01 08:40:23 +01:00
Paul Riseborough f9b75e68c9 Tools: Change sign convention used by thermal calibrator
The flight code assumes corrections have the same sign as the sensor bias error and are subtracted from the raw reading
2017-02-01 08:40:23 +01:00
Beat Küng c829e27a02 temperature_calibration: refactor variable names: remove preceding _ 2017-02-01 08:40:23 +01:00
Beat Küng b5b6fb24e3 temperature_calibration: exit task when complete, set TC_G_ENABLE & use param_set_no_notification 2017-02-01 08:40:23 +01:00
Beat Küng 4a8d29800c voted_sensors_update: cleanup & remove some attributes
since the correction topic now contains data from all sensors, we don't
need additional fields in voted_sensors_update
2017-02-01 08:40:23 +01:00
Beat Küng 4763a119bc calibration: make sure to notify the system when temp calibration changes
This is needed so that temperature compensation reads in the updated values
and publishes the updated sensor_correction topic.
2017-02-01 08:40:23 +01:00
Beat Küng 7ebe2ac017 gyro_calibration: take into account temperature compensation when storing the scale 2017-02-01 08:40:23 +01:00
Beat Küng fbef2b7a6a accelerometer_calibration: avoid using accel_mapping
This is not needed, as s is an uORB instance and accel_offset_0
contains data from uORB instance 0.
2017-02-01 08:40:23 +01:00
Beat Küng 97d7164b64 logger: remove actuator_controls from list of default topics
this was actually never published, only _0, _1, ... get published
2017-02-01 08:40:23 +01:00
Beat Küng 6ee3c1a117 temperature_compensation: fix copy-paste error (max_temp was not initialized) 2017-02-01 08:40:23 +01:00
Beat Küng 21070b069b mc_att_control_main: fix {x,y,z} variables (copy-paste mistake) 2017-02-01 08:40:23 +01:00
Beat Küng 75be1abc4c temperature_compensation: make sure to reset temperature when params change
Makes sure that the offsets & scales are updated and published later on.
2017-02-01 08:40:23 +01:00
Beat Küng fdb75dbba2 accelerometer_calibration: simplify & fix if temp compensation is enabled
if compensation enabled, scale & offsets for the drivers should be reset,
but actually only the params were reset and accel_scale was still applied
to the driver via ioctl.
2017-02-01 08:40:23 +01:00
Beat Küng d0ea4e8876 accelerometer_calibration: cleanup 2017-02-01 08:40:23 +01:00
Beat Küng 69fd8447ae accelerometer_calibration: make sure to initialize sensor_correction properly 2017-02-01 08:40:23 +01:00
Beat Küng 51def4fc60 gyro_calibration: make sure to initialize sensor_correction properly
if it's not published yet or published with low frequency, this makes sure
we have valid data.

also:
- _sensor_correction -> sensor_correction
- remove unnecessary init of sensor_correction_sub
2017-02-01 08:40:23 +01:00
Beat Küng f890c82c97 mc_att_control_main: remove unnecessary memset for _sensor_correction 2017-02-01 08:40:23 +01:00
Paul Riseborough c00c638b77 Remove IMU calibration parameter checks 2017-02-01 08:40:23 +01:00
Paul Riseborough fb774bef67 commander: enable accel cal to adjust thermal compensation parameters 2017-02-01 08:40:23 +01:00
Paul Riseborough bdd3b094a7 sensors: report mapping from uORB to compensation parameter index 2017-02-01 08:40:23 +01:00
Paul Riseborough 8b1a5461c4 sensors: Update documentation 2017-02-01 08:40:23 +01:00
Paul Riseborough ba9e8741c0 msg: Add mapping from uORB index to compensation parameter index
This mapping is required so other applications can use the correct compensation data, even if the uORB ordering changes.
2017-02-01 08:40:23 +01:00
Paul Riseborough f2f5034832 sensors: prevent high frequency updating of sensor corrections
The use of a float to integer cast was causing high frequency reporting when the float value was close to the rounding boundary.
2017-02-01 08:40:23 +01:00
Paul Riseborough 62694d92d2 commander: rework IMU cal for compatibility with temperature compensation 2017-02-01 08:40:23 +01:00
Paul Riseborough add298c0b5 mc_att_control: use legacy offset and scale definition (+2 squashed commits)
Squashed commits:
[f81a8b0] mc_att_control: remove unnecessary initialisers
[f3d3f48] mc_att_control: accommodate changes to sensor_correction topic
2017-02-01 08:40:23 +01:00
Paul Riseborough 170bc91587 sensors: fix bug in thermal compensation temperature limit (+2 squashed commits)
Squashed commits:
[2df1d9e] sensors: change definition of sensor offset and scale factor to match legacy code
[089e103] sensors: publish thermal corrections for all sensors
2017-02-01 08:40:23 +01:00
Paul Riseborough 1dd9a10260 msg: publish thermal corrections for all sensors 2017-02-01 08:40:23 +01:00
pixhawk ef2a5599a1 mag_calibration: Make sure calibration fails if any mag fails; More checks on calibration results 2017-02-01 08:38:26 +01:00
pixhawk fded02220b calibration_routines: use PX4_ISFINITE() instead of isnan() 2017-02-01 08:38:26 +01:00
Beat Küng 1da934049c matrix_alg: use PX4_ISFINITE() instead if isnan() & isinf() 2017-02-01 08:38:26 +01:00
pixhawk 5c96c8c1b3 Removed std::fill_n since it is not supported 2017-02-01 08:38:26 +01:00
pixhawk 9fe65d0957 Fix array initialization bug 2017-02-01 08:38:26 +01:00
Siddharth Bharat Purohit 2c831c314e commander: correct mag cal offset direction 2017-02-01 08:38:26 +01:00
Siddharth Bharat Purohit c6f8bcf8b3 commander: use mathlib matrix_alg functions 2017-02-01 08:38:26 +01:00
Siddharth Bharat Purohit b46b7a3ca3 mathlib: add matrix eval funcs for raw arrays 2017-02-01 08:38:26 +01:00
Siddharth Bharat Purohit 78b8deda15 commander: add ellipsoid 9 param fit for magnetometer corrections 2017-02-01 08:38:26 +01:00
Siddharth Bharat Purohit c9ac15f0dd commander: fix code style 2017-02-01 08:38:26 +01:00
Siddharth Bharat Purohit f811777789 commander: add new math for sphere fit for compass calibration 2017-02-01 08:38:26 +01:00
Beat Küng f746141afe mpu6000: add & check for the device_type on driver startup
Fixes the following case: a board that has several bus_options enabled,
and wants to start a specific device (eg mpu6000 -T 20608 start). In that
case the given device_type is never actually checked, and since the start
routine iterates over all bus_options, several can match, and thus start
multiple instances of the driver (note that the whoami check is performed
against the value provided with -T and thus the check will pass).

This happens on Pixracer (PX4_SPIDEV_MPU and PX4_SPIDEV_ICM_20608 are both
set).
2017-01-31 23:38:50 +01:00
Beat Küng 7c47991504 px4fmu-v4 board config: use PX4_SPIDEV_ICM_20608 instead of PX4_SPIDEV_ICM_20602
This is what's used according to https://pixhawk.org/modules/pixracer.
2017-01-31 23:38:50 +01:00
Lucas De Marchi d6ef703fa4 aerofc: disable internal compass (#6485)
It uses a shared I2C bus with MS65611 which causes noise on the baro
reads. This will rely on the external compass instead of the internal
one.
2017-01-31 07:07:52 -10:00
Daniel Agar 899e406005 cmake optionally find and use ccache 2017-01-30 08:57:53 +01:00
Daniel Agar dcddcdd28e cmake git ver depend on index and HEAD 2017-01-30 08:57:53 +01:00
Daniel Agar 159b35919a cmake nuttx build use full path to copy stamp
- fixes #6469
2017-01-30 08:57:53 +01:00
Lorenz Meier 40aa785720 DSM: Report zero channel count / decode fail through correct data path 2017-01-30 08:45:54 +01:00
Daniel Agar de128aaa6e dsm rctest fix num_values return 2017-01-30 08:41:26 +01:00
Daniel Agar 93b0f07b43 travis-ci run tests 2017-01-30 08:41:26 +01:00
Lorenz Meier d1372ddb67 Snapdragon RC driver: Move RC struct out of main loop to preserve channel values. Initialize raw rc count. 2017-01-30 08:28:59 +01:00
Lorenz Meier 2c24900b9d FMU: Initialize raw RC count 2017-01-30 08:27:49 +01:00
Lorenz Meier e7a0089340 9250: Fill device ID for mag correctly 2017-01-29 16:24:47 +01:00
Lorenz Meier a9a31bc745 MPU6K: Device ID should come from the main instance, not interface 2017-01-29 16:24:47 +01:00
Lorenz Meier be2c73e9c3 HMC driver: Device ID should come from the main instance, not the interface 2017-01-29 16:24:47 +01:00
Lorenz Meier a520c62d1a Allow setting the device ID in device driver 2017-01-29 16:24:47 +01:00
Lorenz Meier 1b06c04b5c Sensors: Style fix 2017-01-29 16:24:47 +01:00
Lorenz Meier 9cacdaafc7 Sensors: Reset gyro and accel calibration if one sensor goes missing.
This is to ensure that if sensor IDs are fixed we do not end up in a state where the system is partially calibrated and the need for re-calibration is not properly communicated to the user.
2017-01-29 16:24:47 +01:00
Lorenz Meier d0d1a8e04f MS5611: Add missing bus identifier 2017-01-29 16:24:47 +01:00
Lorenz Meier 0ee68071fc 9250: Add missing bus identifier 2017-01-29 16:24:47 +01:00
Lorenz Meier af4e9b668b MPU6K: Add missing bus identifier 2017-01-29 16:24:47 +01:00
Lorenz Meier 40e5d25196 LPS25H: Add missing bus identifier 2017-01-29 16:24:47 +01:00
Lorenz Meier 19d4c65a70 LIS: Add missing bus identifier 2017-01-29 16:24:47 +01:00
Lorenz Meier 6c7a8b594e HMC: Add missing bus identifier 2017-01-29 16:24:47 +01:00
Lorenz Meier f80a1df133 Sensor header: Add previously unknown device identifiers 2017-01-29 16:24:47 +01:00
Lorenz Meier 33f6316d3c Device: Also allow to read bus type 2017-01-29 16:24:47 +01:00
Lorenz Meier ec78830657 BMP280: Fix device ID setup 2017-01-29 16:24:47 +01:00
Lorenz Meier 8f77d55b8c BMA180: Fix device ID setup 2017-01-29 16:24:47 +01:00
Lorenz Meier e88bb4cc09 MPU6K: Correctly register sub-type, remove magic numbers.
Before this change the MPU6K driver would register only the MPU6K family, but not the sub-type, which prevented telling individual sensors apart. This is a breaking change because users will have to perform their accel and gyro calibration again. However, it is unavoidable since right now the different sensors can end up with the same ID and the wrong offsets can be applied to the wrong sensor.
2017-01-29 16:24:47 +01:00
Lorenz Meier a33bce0d26 Device IDs: List all sub-types of the MPU6K 2017-01-29 16:24:47 +01:00
Lorenz Meier 1c131f2523 Land detector: Accumulate total flight time between flights 2017-01-29 15:48:34 +01:00
Lorenz Meier 35efe651ac Land detector main: Fix style 2017-01-29 15:48:34 +01:00
Lorenz Meier 75132a50e6 Land detector: Measure total system flight time
This implementation is a baseline implementation and makes no attempt to be tamper-proof. A monotonic counter like the W25R64FV or a similar HW facility would be required to achieve this.
2017-01-29 15:48:34 +01:00
Lorenz Meier 2cf8cdc63f Event system: Initialize work item 2017-01-29 15:10:09 +01:00
Lorenz Meier ff305fa440 SITL: Default to same estimator as onboard 2017-01-29 11:43:10 +01:00
Khoi Tran 21f8e07836 Fixed format 2017-01-29 09:37:48 +01:00
Khoi Tran 2428ff9f3a mc_position_control: Fix divide by zero in scale_control 2017-01-29 09:37:48 +01:00
Lorenz Meier 3f9d79c768 Update GPS 2017-01-29 01:19:48 +01:00
Daniel Agar 278b76e5a9 astyle src/platforms/qurt 2017-01-29 01:18:32 +01:00
Daniel Agar 501f866bf5 astyle src/platforms/posix 2017-01-29 01:18:32 +01:00
Daniel Agar ca60d2d15f astyle src/platforms/ros 2017-01-29 01:18:32 +01:00
Daniel Agar 624403f147 astyle src/examples/hwtest 2017-01-29 01:18:32 +01:00
Daniel Agar fa3b3df061 astyle src/lib/geo 2017-01-29 01:18:32 +01:00
Daniel Agar 8fbf5cbdaf astyle src/drivers/device 2017-01-29 01:18:32 +01:00
Daniel Agar adbe38e86b astyle src/drivers/stm32 2017-01-29 01:18:32 +01:00
Daniel Agar 1261f985d8 astyle src/drivers/bmi160 2017-01-29 01:18:32 +01:00
Daniel Agar fc4831d625 astyle src/drivers/mkblctrl 2017-01-29 01:18:32 +01:00
Daniel Agar f0cde91220 astyle src/drivers/vmount 2017-01-29 01:18:32 +01:00
Daniel Agar e43a8013dd astyle src/drivers/mpu9250 2017-01-29 01:18:32 +01:00
Daniel Agar 52c4479e0f astyle src/drivers/camera_trigger 2017-01-29 01:18:32 +01:00
Daniel Agar 30587e5669 astyle src/drivers/gps 2017-01-29 01:18:32 +01:00
Daniel Agar 32da3381f7 astyle src/drivers/bootloaders 2017-01-29 01:18:32 +01:00
Daniel Agar 8ab79a2c90 astyle src/drivers/test_ppm 2017-01-29 01:18:32 +01:00
Daniel Agar ac06d665a3 astyle src/drivers/boards 2017-01-29 01:18:32 +01:00
Daniel Agar e63c8ab2a2 astyle src/drivers/ardrone_interface 2017-01-29 01:18:32 +01:00
Daniel Agar ee8fa78d93 astyle src/modules/uORB 2017-01-29 01:18:32 +01:00
Daniel Agar 88ad0fc3bd astyle src/modules/navigator 2017-01-29 01:18:32 +01:00
Daniel Agar 750e5d1690 astyle src/modules/uavcanesc 2017-01-29 01:18:32 +01:00
Daniel Agar 0bc3c8dfc4 astyle src/modules/systemlib 2017-01-29 01:18:32 +01:00
Daniel Agar b1b951aace astyle src/modules/muorb 2017-01-29 01:18:32 +01:00
Daniel Agar a0271fe020 astyle src/modules/vtol_att_control 2017-01-29 01:18:32 +01:00
Daniel Agar 380819dfc5 astyle src/modules/uavcannode 2017-01-29 01:18:32 +01:00
Daniel Agar 019c6647f2 astyle src/modules/sensors 2017-01-29 01:18:32 +01:00
Daniel Agar 28e50d5911 astyle src/modules/logger 2017-01-29 01:18:32 +01:00
Daniel Agar da90e1ce62 astyle src/modules/replay 2017-01-29 01:18:32 +01:00
Daniel Agar 830cb44b9c astyle src/modules/fw_pos_control_l1 2017-01-29 01:18:32 +01:00
Daniel Agar a14c5b29ea astyle src/systemcmds/hardfault_log 2017-01-29 01:18:32 +01:00
Daniel Agar 7c094053cb astyle update to v2.06 2017-01-29 01:18:32 +01:00
Roman e916159f5c updated DriverFramework
Signed-off-by: Roman <bapstroman@gmail.com>
2017-01-28 20:18:01 +01:00
Roman c065dc1930 bebop bus wrapper: fix logging of rpm and rpm setpoint
Signed-off-by: Roman <bapstroman@gmail.com>
2017-01-28 20:18:01 +01:00
Roman 1d4d57c4db bebop bus wrapper: log actual and setpoint motor speed
Signed-off-by: Roman <bapstroman@gmail.com>
2017-01-28 20:18:01 +01:00
Roman 0c7c5977ae bebop motor driver: better naming, removed unused header file
Signed-off-by: Roman <bapstroman@gmail.com>
2017-01-28 20:18:01 +01:00
Matthias Grob 480dd0922b Land detector: revision of the 2 stage landing mechanism
Ground detect: pilot want down or we are on minimum thrust by auto land but no vertical movement
-> Controller should relax x,y corrections and even ramp down desired thrust
Landed: All other conditions are eventually met
2017-01-28 16:23:04 +01:00
Matthias Grob b130913090 land_detector: made sure the 2 stage landing can not happen in one hysteresis time 2017-01-28 16:23:04 +01:00
Lorenz Meier 9ef97b78c8 Land detector: Turn throttle range parameter into proper user-configurable parameter 2017-01-28 16:23:04 +01:00
Lorenz Meier 9448b8cb52 Land detector: Fix hover throttle detection 2017-01-28 16:23:04 +01:00
Dennis Mannhart f297c45f78 mc_pos_control_main:
for landing, set velocity to zero and consider thrust_sp in body frame
instead of NED frame. Also limit thrust_sp_body_z to be larger than 0.0f
2017-01-28 16:23:04 +01:00
Lorenz Meier 58983e4c52 Land detector: Fix code style 2017-01-28 16:23:04 +01:00
Dennis Mannhart 3fe45697bb Fix3dwinglandDetector.cpp: adjusted to astyle 2017-01-28 16:23:04 +01:00
Dennis Mannhart 2f164602b4 LandDetector:
- constructor initalization fix
- set trigger time for ground contact hysteresis
- updated ground_contact_state logic
MulticopterLandDetector:
- added hysteresis for ground_contact
VtolLandDetector:
- get_ground_contact_state function that return the one form MultcopterLandDetector
FixedWingLandDetector:
- get_ground_contact_state with a return false: requires implementation
2017-01-28 16:23:04 +01:00
Lorenz Meier f961a12d9a MC position controller: Stop XY control once ground contact is established 2017-01-28 16:23:04 +01:00
Lorenz Meier aab04141f0 Initialize raw GPS data 2017-01-28 16:23:04 +01:00
Lorenz Meier 9e9e0e23ad Land detector: Detect ground contact separately
This allows to detect ground contact before concluding the system is landed. This allows to disable some parts of the horizontal control system and only control the vertical position to avoid tipping over.
;
2017-01-28 16:23:04 +01:00
Lorenz Meier 36026fb631 Land detection topic: Add ground contact state 2017-01-28 16:23:04 +01:00
Lorenz Meier 264589b2cc Fix motor range 2017-01-28 15:25:00 +01:00
Matthias Grob 41ff46b557 tap_esc: fixed offset to really keep the range 1200-1900
even if the input to the driver is too low or too high.
This prevents motor stalling.
NaN or Inf still stop the motor.
2017-01-28 15:24:45 +01:00
Beat Küng 91416fc49a ver.c: fix hwcmp to match exact string
Previously for example 'ver hwcmp PX4FMU_V4PRO' matched on PX4FMU_V4
hardware too.
2017-01-28 15:18:35 +01:00
José Roberto de Souza 37f73bb0ed ROMFS: aerofc: Only start logger with MAVLink support
AeroFC don't have SDCard to store logs.
2017-01-28 11:03:07 +01:00
José Roberto de Souza 340be986a6 ROMFS: aerofc: Switch from sdlog2 to logger
Logger have adds support of ULog over MAVLink and it will be used in AeroFC.
2017-01-28 11:03:07 +01:00
David Sidrane b3f5a0d51a Tools to ease nuttx config maintenance (#6452)
* Added tool to restore defconfig sections after make [old|menu]config

* Use tool to restore defconfig sections after make [old|menu]config

   invocation:
      make px4fmu-v2_default oldconfig_px4fmu-v2
      make px4fmu-v2_default menuconfig_px4fmu-v2
2017-01-27 14:14:48 -10:00
Larry Wang 72ea5c53db qurt px4_layer initialize shared memory (#6453) 2017-01-27 17:59:12 -05:00
David Sidrane 0f33ca1ecc tap-v1 Increased IRQ Stack Size 2017-01-27 15:01:52 +01:00
David Sidrane 8bb72d45dc px4-stm32f4discovery Increased IRQ Stack Size 2017-01-27 15:01:52 +01:00
David Sidrane 3d05fa7229 mindpx-v2 Increased IRQ Stack Size 2017-01-27 15:01:52 +01:00
David Sidrane 214fd04b3c crazyflie Increased IRQ Stack Size 2017-01-27 15:01:52 +01:00
David Sidrane 5a7b8e052e auav-x21 Increased IRQ Stack Size 2017-01-27 15:01:52 +01:00
David Sidrane 2fe0f76e27 aerofc-v1 Increased IRQ Stack Size 2017-01-27 15:01:52 +01:00
David Sidrane 57581ddaac aerocore Increased IRQ Stack Size 2017-01-27 15:01:52 +01:00
Daniel Agar cdd472f722 Makefile update Firmware.zip px4 naming 2017-01-26 19:41:48 -05:00
Daniel Agar 3d804dd7ca cmake nuttx simple binary naming 2017-01-26 18:39:09 -05:00
Daniel Agar bc72b8161f px4fmu-v2_default add logger 2017-01-26 18:39:09 -05:00
David Sidrane f604b71838 tap-v1 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane 0088d17f4c px4nucleoF767ZI-v1 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane 59d95cd77b px4fmu-v5 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane 3dc205f28a px4fmu-v4pro using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane cd1148f146 px4fmu-v4 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane d5059efdde px4fmu-v2 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane af4b8ee8ca px4fmu-v1 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane f71d0eaf5a px4esc-v1 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane d7fc536f06 px4cannode-v1 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane bff54584fe px4-stm32f4discovery using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane 5b2ceb7fda mindpx-v2 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane 579f698e4c crazyflie using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane e484c3bab5 auav-x21 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane b955ef2876 aerofc-v1 using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane 2cf8a1b432 aerocore using board common mcu version api 2017-01-26 08:39:12 +01:00
David Sidrane af12816296 posix derived targets use BOARD_OVERRIDE_CPU_VERSION for mcu_version 2017-01-26 08:39:12 +01:00
David Sidrane 6ab32f1632 logger uses common board api for mcu_version 2017-01-26 08:39:12 +01:00
David Sidrane 4be19b26b0 ver uses common board api for mcu_version 2017-01-26 08:39:12 +01:00
David Sidrane 242f563d44 Adds a board common API for retriving the SoC' Silicon revision data/errata
This abstraction will support mcu's other than the stm32 family.
    It moves the systemlib/mcu_version.c functionality to
    common/stm32/board_mcu_version.c
2017-01-26 08:39:12 +01:00
Siddharth Bharat Purohit 975893a406 events: tempcal: get rid of commented code 2017-01-25 22:43:29 +01:00
Beat Küng be512fdc4c temperature_calibration: use device id from published topic
uorb topic instance does not necessarily match the gyro device path instance,
so we need to use the id from the topic.
2017-01-25 22:43:29 +01:00
Beat Küng 00d2fc936a polyfit.hpp: fix code style (class member variables start with _) 2017-01-25 22:43:29 +01:00
Beat Küng 2fbb1aee84 temperature_calibration: fix poll (number of fds), remove usleep
useep() is not needed because we use the poll()
2017-01-25 22:43:29 +01:00
Beat Küng 54e9bda412 temperature_calibration: properly initialize gyro subscriptions & bounds checking 2017-01-25 22:43:29 +01:00
Beat Küng e74e883c56 temperature_calibration: change some log levels to be more appropriate 2017-01-25 22:43:29 +01:00
Siddharth Bharat Purohit 5c7dbe0f24 events: tempcal: run cal for all available gyros 2017-01-25 22:43:29 +01:00
Siddharth Bharat Purohit 7e6daaf3d1 tempcal: remove separate temperature calibration module 2017-01-25 22:43:29 +01:00
Siddharth Bharat Purohit 416a0aece2 events:polyfit: change to using int/unsigned instead of (u)intx_t types 2017-01-25 22:43:29 +01:00
Siddharth Bharat Purohit e390f672c9 events: tempcal: save temperature calibration result 2017-01-25 22:43:29 +01:00
Siddharth Bharat Purohit 917a8f63f6 events: add temperature calibration scheme 2017-01-25 22:43:29 +01:00
Siddharth Bharat Purohit 86d9ba9cde tempcal: move to using Matrix library functions 2017-01-25 22:43:29 +01:00
Siddharth Bharat Purohit 0cc034ee15 px4fmu-v2 cmake: disable uavcan build to make space for tempcal module 2017-01-25 22:43:29 +01:00
Siddharth Bharat Purohit acff114260 tempcal: add ref temperature and proper debug print methods 2017-01-25 22:43:29 +01:00
Siddharth Bharat Purohit 137ade308f tempcal: change to double as float was insufficient for calculation 2017-01-25 22:43:29 +01:00
Siddharth Bharat Purohit 269d05ff22 tempcal: sandbox app for temperature calibration 2017-01-25 22:43:29 +01:00
Lorenz Meier 0909c32262 PX4 FMU: Start send_events handler in all FMU generations 2017-01-25 22:43:29 +01:00
Lorenz Meier fd6b051895 Start send_events in work queue 2017-01-25 22:43:29 +01:00
Beat Küng c1e2aeff0b commander: ignore PREFLIGHT_CALIBRATION for temperature calibration param 2017-01-25 22:43:29 +01:00
Beat Küng ab8ac8f63a events: add new module events
It uses the LP worker queue to periodically check for vehicle commands (30hz),
useful for several housekeeping tasks.
Currently the only task is temperature calibration.

Commands can be started via command line or via vehicle_command (from
Mavlink)

TODO: need to spec & extend the mavlink command.
2017-01-25 22:43:29 +01:00
Matthias Grob 34080be68b mc_pos_control: removed special mode switch calculation
because it is not needed anymore with feed forward thrust
it even produced aggressive twitches when used together with the feed forward thrust
2017-01-25 22:42:45 +01:00
Lorenz Meier 63057d7b60 Ensure that manual control is only sent by sensors app if signal is valid and initialized 2017-01-25 07:43:45 +01:00
Lorenz Meier b1c6494ed7 MAVLink receiver: Do use correct multi-topic architecture
This prevents two inputs publishing to the same topic. Now if both RC and joystick are connected the first to be active gets control. This is not optimal but consistent and safe.
2017-01-25 07:43:45 +01:00
Lorenz Meier cc4fa627c2 Messages: Add input source field to manual control setpoint message 2017-01-25 07:43:45 +01:00
David Sidrane 6368768d31 px4esc-v1 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane ead65eb581 px4cannode-v1 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane 8972308559 tap-v1 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane 6b9d87821b px4nucleoF767ZI-v1 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane 75bb427830 px4fmu-v5 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane 5ede3772ee px4fmu-v4pro using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane ca6105d042 px4fmu-v4 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane 5ede0ace17 px4fmu-v2 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane a4ad8821cb px4fmu-v1 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane 89bbe708f8 px4-stm32f4discovery using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane 9e5d7d6e09 mindpx-v2 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane e6623554cb crazyflie using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane 1d7dff05e9 auav-x21 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane ff2e8b10a2 aerofc-v1 using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane 5ea2d1d53f aerocore using board common identity api 2017-01-25 07:43:11 +01:00
David Sidrane 5c239ffb0b logger uses board_get_uuid_formated32 instead of mcu_unique_id
Replace the creation of uuid string with the board common api
  board_get_uuid_formated32 as opposed to using mcu_unique_id
  and printf.
2017-01-25 07:43:11 +01:00
David Sidrane e6ba897b9a mavlink is using board_get_uuid_raw32 instead of mcu_unique_id 2017-01-25 07:43:11 +01:00
David Sidrane 63e3bbde07 gyro_calibration is using board_get_uuid_raw32 instead of mcu_unique_id 2017-01-25 07:43:11 +01:00
David Sidrane 5a5cfdbbe3 mcu_version remove mcu_unique_id
Using board cvommon UUID api thefore Removed mcu_unique_id
2017-01-25 07:43:11 +01:00
David Sidrane 93f2cf077f posix derrived targes use BOARD_OVERRIDE_UUID 2017-01-25 07:43:11 +01:00
David Sidrane d0ebc183c9 ver uses common board api for uuid 2017-01-25 07:43:11 +01:00
David Sidrane 4dc8e61612 uavcan uses common board api to interface with systemlib/board_serial 2017-01-25 07:43:11 +01:00
David Sidrane 5bdd5c7989 fmu uses common board api to interface with systemlib/board_serial 2017-01-25 07:43:11 +01:00
David Sidrane 24f5461402 systemlib/board_serial uses common board api for UUID 2017-01-25 07:43:11 +01:00
David Sidrane 459f71f579 zubaxgnss-v1 bootloader uses common board api for UUID 2017-01-25 07:43:11 +01:00
David Sidrane 9efeb0d848 s2740vc-v1 bootloader uses common board api for UUID 2017-01-25 07:43:11 +01:00
David Sidrane 69a500c6e7 px4flow-v2 bootloader uses common board api for UUID 2017-01-25 07:43:11 +01:00
David Sidrane 147ed3067d px4esc-v1 bootloader uses common board api for UUID 2017-01-25 07:43:11 +01:00
David Sidrane 796a7a1a69 px4cannode-v1 bootloader uses common board api for UUID 2017-01-25 07:43:11 +01:00
David Sidrane ae872448fd esc35-v1 bootloader uses common board api for UUID 2017-01-25 07:43:11 +01:00
David Sidrane bf0de997cb Adds a board common way of retriving the SoC' Unique identifier
This abstraction will support mcu's with longer ID's then the
   stm32 family.

   It provids a common interface for byte and 32 bit word access
   to the UUID data and a facility to reorder it.
2017-01-25 07:43:11 +01:00
James Goppert b86380086e Streamline python script for temp cal. (#6416)
* Streamline python script for temp cal.

* Simplify file generation for temp calibration.
2017-01-24 18:42:15 -05:00
David Sidrane 1abd629461 Move common macros to systemlib/px4_macros.h 2017-01-24 21:18:28 +01:00
David Sidrane f3f235376b PX4 System changes you use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane ec90bfb8a5 zubaxgnss-v1 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane a29d7091c4 px4flow-v2 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane c6c2eca139 s2740vc-v1 use board common reset interface requiers upstream nuttx fix 2017-01-24 21:17:06 +01:00
David Sidrane dde2a0164e s2740vc-v1 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane 571ffb7652 px4nucleoF767ZI-v1 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane 6653bfc3c9 px4esc-v1 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane 1aad48c869 px4cannode-v1 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane 999ecb84d0 tap-v1 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane 327d45165d crazyflie use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane cde6b0ac07 posix builds define BOARD_HAS_NO_RESET and BOARD_HAS_NO_BOOTLOADER 2017-01-24 21:17:06 +01:00
David Sidrane 4b99426736 px4-stm32f4discovery use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane 4bbcb9a768 px4-stm32f4discovery use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane e68532a86e mindpx-v2 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane 844f753881 px4fmu-v5 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane ab3a0ba025 px4fmu-v4pro use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane eb72b49507 px4fmu-v4 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane fc00e3e168 px4fmu-v3 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane b01e03bf4f px4fmu-v2 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane a5d1290398 px4fmu-v1 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane bcba37b71c auav-x21 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane a89a51cb9b aerofc-v1 use board common reset interface 2017-01-24 21:17:06 +01:00
David Sidrane c2c8962765 board_crashdump uses board_system_reset API 2017-01-24 21:17:06 +01:00
David Sidrane 3692a62c35 Move board reset and entering bootloader to to board_common api
Define modes of reset and way to tell the system to enter
  the bootloader via an api defined in board_common.h

  If hardware or simulation deo not support the reset or
  bootloader API and can define BOARD_HAS_NO_RESET and
  BOARD_HAS_NO_BOOTLOADER respectivly.
2017-01-24 21:17:06 +01:00
José Roberto de Souza 523688e43c aerofc: Reboot after crash 2017-01-24 00:06:12 +01:00
David Sidrane c866e745cd Removed mis-named file px4iov2.prototype (#6420) 2017-01-23 12:52:37 -10:00
David Sidrane e31dfba4d0 Include up_internal.h to pickup extern _sdata definition
Fixes CI error
2017-01-23 22:10:38 +01:00
David Sidrane 4320492377 Add the ability to use probes 2017-01-23 22:10:38 +01:00
David Sidrane 59ec0e8aef Make board_crashdump.c arch agnostic and move to common 2017-01-23 22:10:38 +01:00
David Sidrane 127a639cd6 Updated to upstream NuttX config 2017-01-23 22:10:38 +01:00
José Roberto de Souza 4142f1c9d5 aerofc: Disable BBSRAM and SAVE_CRASHDUMP support
This board don't have a SDCard to save crash dumps and it was causing
the board to get stuck into '[boot] There were %d reboots with Hard
fault that were not committed to disk - System halted', until user
connect to the serial console and clear the fault.
2017-01-23 22:10:38 +01:00
José Roberto de Souza 24f9a53f60 drivers: common: stm32: Do not call stm32_bbsram_savepanic() if not implemented 2017-01-23 22:10:38 +01:00
José Roberto de Souza 163bcc4bbc drivers: boards: Share board_crashdump() implementation 2017-01-23 22:10:38 +01:00
José Roberto de Souza 0b3fa7bfbb aerofc: Remove call to board_dma_alloc_init()
This commit will only remove the error message from serial console as
this board don't define BOARD_DMA_ALLOC_POOL_SIZE.
2017-01-23 22:10:38 +01:00
Lorenz Meier 969c9ca7e8 Better status reporting for RC 2017-01-22 15:17:35 +01:00
Julian Oes 4ceba407f2 commander: raise stack size
A stack usage of 3000 bytes was observed, therefore it's safer to raise
the commander's stack size by 400 bytes.
2017-01-21 16:04:43 +01:00
Lorenz Meier eed78fdcc9 DSM: Fix code style 2017-01-21 14:08:10 +01:00
Lorenz Meier 99450c05f5 FMU driver: Fix code style 2017-01-21 12:47:39 +01:00
Andrew C. Smith 12a34c9fcf Minor changes made to FMU module and the DSM code to properly catch Spekrum DSM data. 2017-01-21 12:13:40 +01:00
Lorenz Meier 42c5684a06 Fix temperature clipping for temperature calibration. Fixes #6412 2017-01-21 12:08:18 +01:00
Paul Riseborough 7e21aaf0c9 Tools: Add script file to generate sensor thermal compensation parameters 2017-01-21 11:48:03 +01:00
Paul Riseborough d8c046e47c ROMFS: add thermal calibration logging mode 2017-01-21 11:48:03 +01:00
Paul Riseborough 3a029e58c7 logger: Add mode for thermal calibration logging
Logs the IMU and baro data at 10Hz
2017-01-21 11:48:02 +01:00
David Sidrane 27abc4fe6b Moved BOARD_EEPROM_WP_CTRL further down in file (from rebase) 2017-01-21 11:45:36 +01:00
David Sidrane e3698e6853 Use the PX4IO_FW_SEARCH_PATHS to set path for PX4IO FW update 2017-01-21 11:45:36 +01:00
David Sidrane daba952ba9 Use the BOARD_USES_PX4IO_VERSION to set an overridable FW search path
1) Key the exsitance of the PX4IO HW based on BOARD_USES_PX4IO_VERSION
   2) Set default PX4IO_FW_SEARCH_PATHS based on verions of the PXPIO HW
   3) allow PX4IO_FW_SEARCH_PATHS to be overwritten if a board provides
      BOARD_PX4IO_FW_SEARCH_PATHS
2017-01-21 11:45:36 +01:00
David Sidrane 7b4f048ca3 px4fmu-v4pro Add PX4IO HW version 2017-01-21 11:45:36 +01:00
David Sidrane edd0b46887 px4fmu-v2 Add PX4IO HW version 2017-01-21 11:45:36 +01:00
David Sidrane d4097a0e29 px4fmu-v1 Add PX4IO HW version 2017-01-21 11:45:36 +01:00
David Sidrane eb25358aac auav-x21 Add PX4IO HW version 2017-01-21 11:45:36 +01:00
David Sidrane feb76b4649 Unit test does not have a board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 9665db3efc Use px4_config.h not board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 78eb02e480 Remove the posix based #ifdef from version.h
Use the BOARD_NAME distributed to the board_config.h files
 for posix derived targets
2017-01-21 11:45:36 +01:00
David Sidrane df1ed22cf9 Distribute sitl and board based assets for posix targets
This adds a src/board/<bebop|eagle|excelsior|rpi|sitl>/board_config.h
   to configure the build as is done with the Nuttx targets

   src/platforms/posix/include/board_config.h has been renamed to
   src/platforms/posix/include/system_config.h to allow the common
   posix defines to be included with the board specific defines.
2017-01-21 11:45:36 +01:00
David Sidrane df6b46d0ba FMUV1 Moved magic numbers for battery V div and A per V to board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 894b41e313 AEROCORE Moved magic numbers for battery V div and A per V to board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane f86a8c0e5e MINDPX_V2 Moved magic numbers for battery V div and A per V to board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane e0fa53f444 FMUV2 Moved magic numbers for battery V div and A per V to board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 0baefec09f FMUV4 Moved magic numbers for battery V div and A per V to board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane e9ca626e19 TAP_V1 Moved magic numbers for battery V div and A per V to board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane fd25f0a594 AEROFC_V1 Moved magic numbers for battery V div and A per V to board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 99902807c9 SITL Moved magic numbers for battery V div and A per V to px4_config.h 2017-01-21 11:45:36 +01:00
David Sidrane a8b9c906f6 Board_config.h will provide the BOARD_BATTERYx_V_DIV
Prep to distrubte the magic numbers assgined in parameters.cpp
  to the board_config.h

  common/board_common.h will define:
  1) BOARD_BATTERY[1|2]_V_DIV as 0.0f if not defined to ensure
      the missing default trips a low voltage lockdown

  2) BOARD_BATTERY[1|2]_A_PER_V as 0.0f if not defined to ensure
     the default leads to an unrealistic current value.
2017-01-21 11:45:36 +01:00
David Sidrane 1c3ebadb85 Removed unused defines AVIONICS_ERROR_VOLTAGE and AVIONICS_WARN_VOLTAGE 2017-01-21 11:45:36 +01:00
David Sidrane 93bc8f6467 Combined ifdess and made positive logic
We still allow CONFIG_ARCH_BOARD_SITL in the code base, but
  use positive logic and less #ifdefs
2017-01-21 11:45:36 +01:00
David Sidrane 0bb0e92378 gpio_led removed dependancy on CONFIG_ARCH_BOARD_xxxx
The gpio leg can use either the FMU GPIO_SERVO (Aux Pins)
  or the FMUv1 style IO pins.

  We define either LED_ON_SERVO_GPIO or LED_ON_EXT_GPIO_AND_PIO
  based on if the board_config provides GPIO_SERVO_1 or
  GPIO_EXT_1.

  For LED_ON_SERVO_GPIO we further define GPIO_MIN_SERVO_PIN and
  the GPIO_MAX_SERVO_PIN based on the highest GPIO_SERVO_x provided
  by the board_config

  When base the ability to use the PX4PIO not in the existance of
  the path but on the define BOARD_USES_PX4PIO
2017-01-21 11:45:36 +01:00
David Sidrane 07d7ff5f38 Removed all CONFIG_ARCH_BOARD_xxx usage in drv_gpio.h
Removed remaining entries that had no fmu or pio GPIO
  defined
2017-01-21 11:45:36 +01:00
David Sidrane 0fe915bdfd aerofc-v1 Removed empty GPIO table
aerofc-v1 does not used any user GPIO via the FMU Driver
2017-01-21 11:45:36 +01:00
David Sidrane cf893b6e89 TAP_V1 removed unused GPIO defines
Removed GPIO pins defines that were never user GPIO.
  Removed the camera_trigger driver as it depends on
  GPIO that are not on the TAP V1 HW
2017-01-21 11:45:36 +01:00
David Sidrane d0f2d5e07f crazyflie removed unused GPIO defines 2017-01-21 11:45:36 +01:00
David Sidrane aaf1b9c617 mindpx-v2: moved GPIO defines to mindpx-v2/board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane acb0684a4e aerocore **corrected** and moved GPIO defines to aerocore/board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 1d4d0656c6 PX4FMUV1: moved GPIO defines to px4fmu-v1/board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane fe0f3bc557 PX4FMUV4PRO: moved GPIO defines to px4fmu-v4pro/board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 356911ab0d PX4FMUV4: moved GPIO defines to px4fmu-v4/board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 58a5ac78d9 PX4NUCLEOF767ZI_V1 **corrected** and moved GPIO defines to px4nucleoF767ZI-v1/board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 0b89088065 PX4FMUV5 **corrected** and moved GPIO defines to px4fmu-v5/board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 62dee7d096 PX4FMUV2: moved GPIO defines to px4fmu-v2/board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane b74d049e89 AUAVX21 **corrected** and moved GPIO defines to auav-x21/board_config.h 2017-01-21 11:45:36 +01:00
David Sidrane 9416ae670b Bring the board config into drv_gpio under nuttx 2017-01-21 11:45:36 +01:00
David Sidrane 955f2d7701 make device paths not board specific 2017-01-21 11:45:36 +01:00
David Sidrane 5d263776f2 Placed dependancy on BOARD_USES_PX4IO not path (PX4IO_DEVICE_PATH)
Code was conditionaly included based on #define PX4IO_DEVICE_PATH
    in drivers/drv_gpio.h depanedent on board #ifdef CONFIG_ARCH_BOARDxxxx
    Now that dependancy comes from board_common.h as BOARD_USES_PX4IO defined
    when a board config provides PX4IO_SERIAL_DEVICE.
2017-01-21 11:45:36 +01:00
David Sidrane 33486d5047 FMU gpio operations now conditional on BOARD_FMU_GPIO_TAB in board_config
return -EINVAL on any GPIO ioctl operation when there are
       no GPIO pins defined in the board config. I.E.
       BOARD_FMU_GPIO_TAB is not defined.

       BOARD_FMU_GPIO_TAB is now optional and if it is defined
       then the logical BOARD_HAS_FMU_GPIO is defined and
       will enable the px4fmu driver to perform the physical GPIO
       operations.
2017-01-21 11:45:36 +01:00
David Sidrane 216ec6513a Removed CONFIG_ARCH_BOARD_AEROFC_V1 from tap_esc
Changed the CONFIG_ARCH_BOARD_AEROFC_V1 in tap_esc.cpp to
   TAP_ESC_NO_VERIFY_CONFIG to maintian the commitment to not
   have CONFIG_ARCH_BOARD_xxxx ifdef litter in the PX4 code base.
   TAP_ESC_NO_VERIFY_CONFIG will be removed (see todo) in
   aerofc-v1/board_config.h
2017-01-21 11:45:36 +01:00
David Sidrane fa6ad99aba Enable MEAS Airspeed voltage_correction based on ADC_SCALED_V5_SENSE not CONFIG_ARCH_BOARD_xxx
ADC_SCALED_V5_SENSE is defined and derived based on HW that provides
    and adc input that samples the V5 Rail or in the case of FMUv5 the
    V5 supply.
2017-01-21 11:45:36 +01:00
David Sidrane 26b1e1fe0c Use HW independant overrideable defines to condition ADC V5 sensing & publishing
Use ADC_SCALED_V5_SENSE as apposed to legasy ADC_5V_RAIL_SENSE to populate
    voltage5V_v
    Then Scale the DN based on an overridable ADC_V5_V_FULL_SCALE value
2017-01-21 11:45:36 +01:00
David Sidrane a5ec920756 Provide overridable default ADC Full scale Voltage and Scaling factors
This add the ability to override the defaults ADC values by
   defining values in board_config.h
2017-01-21 11:45:36 +01:00
David Sidrane 43c1237d00 On lis3mdl use the bus setting to return internal/external
Removed asssumtion that all HW other then PX4v1 has lis3mdl on
  an external i2c bus. Use the actual value of the bus the device
  was found and instanced on to return the result of
  MAGIOCGEXTERNAL ioctl
2017-01-21 11:45:36 +01:00
Lorenz Meier 084e714f62 Mixer: Fix yaw throttle adjustment
When a motor hits a limit we only want to lower the collective throttle as much as the total limit, not per motor hitting the limit.
2017-01-21 08:33:51 +01:00
Paul Riseborough 1d66d4b051 sensors: Allow for difference in temperature readings across sensors
We need to track the temperature change in each sensor instance individually when using it as basis for publication.
2017-01-21 08:31:56 +01:00
Larry Wang 1beb2911e2 init shmem early to avoid random crash in fastrpc (#6407)
* init shmem early to avoid possible crash

* fix_code_style

* Keep the initialziation to NULL, remove the duplicate memory allocation
2017-01-21 08:30:46 +01:00
Michael Schaeuble 7aea2ca030 BebopFlow: Add V4L2 interface and image functionality 2017-01-20 23:09:13 +01:00
Michael Schaeuble f572752412 BebopFlow: Add initial PX4 app and structure 2017-01-20 23:09:13 +01:00
Lorenz Meier 27fca51b05 Update DF 2017-01-20 23:09:13 +01:00
Michael Schaeuble 85aa710414 BebopRangeFinder: Integration into build and starup 2017-01-20 23:09:13 +01:00
Michael Schaeuble 6cb659c8ef BebopRangeFinder: Add DF wrapper for Bebop's height sensor 2017-01-20 23:09:13 +01:00
David Sidrane 1d4ae4c683 Allows a board config to override the number of partitions and names
A board_config may define BOARD_HAS_MTD_PARTITION_OVERRIDE to
   uses it's own number of partitions and names.

   If a BOARD_HAS_MTD_PARTITION_OVERRIDE is not defined
   the hardcoded original values of fs/mtd_params &
   /fs/mtd_waypoints are used.

on an mtd device.
2017-01-20 22:55:04 +01:00
David Sidrane 487fbdf009 Use BOARD_EEPROM_WP_CTRL signal to control EEPROM WP signal if defined
Erases and write operations will use the BOARD_EEPROM_WP_CTRL
  macro to remove the Write protection and restore it.
2017-01-20 22:55:04 +01:00
David Sidrane 44cb1afa4d Provide an overidable nop default for BOARD_EEPROM_WP_CTRL
To simplify integration of an EEPROM device with a Write Protect
  control pin, we add an overidable BOARD_EEPROM_WP_CTRL macro
  the does nothing.

  A board that provids the GPIO for WP should define
  BOARD_EEPROM_WP_CTRL(_protected_true) that will set the WP GPIO
  to the Protected state when passed true.
2017-01-20 22:55:04 +01:00
David Sidrane 9002581ad4 Fixes the missing CONFIG_ prefix on RAMTRON_WRITEWAIT
This is an intrim nuttx patch that fixes the missing CONFIG_
  prefix on RAMTRON_WRITEWAIT. PR submitted upstream. This will
  be in affect until the next uptake of upstream NuttX
2017-01-20 22:53:56 +01:00
Janis Dzerve 3c270ae2a8 simulator: Do not kill every process with string 'px4' in the name 2017-01-20 09:41:16 +01:00
José Roberto de Souza 6bcf9266dc aerofc: Correctly enable UART driver for UART5(Telemetry port)
UART4 and UART5 are not USART instances.
2017-01-20 08:49:17 +01:00
David Sidrane d42f8f4745 BugFix:Prevent drv_led_pwm passing a value of 0 to px4_arch_configgpio
This prevents the meta value of 0 => not used from being passed to
  px4_arch_configgpio. As this would map to PORTA|PIN0 and is not
  the intended configuration.
2017-01-19 22:18:04 +01:00
David Sidrane 3ea5a24924 crazyflie BugFix:Prevent a value of 0 being passed to px4_arch_configgpio
This prevents the meta value of 0 => not used from being passed to
  px4_arch_configgpio. As this would map to PORTA|PIN0 and is not
  the intended use.
2017-01-19 22:18:04 +01:00
Beat Küng c1b1d03515 mc_att_control: use a maximum of 3 gyros 2017-01-19 19:24:52 +01:00
Beat Küng 21a3e4d36a mc_att_control: fix out-of-bounds access if system has multiple gyros 2017-01-19 19:24:52 +01:00
Beat Küng ab9e0aa524 sensors temp compensation: do an orb_copy to get the driver ID
This removes the necessity, that the driver class ID matches the uorb topic
instance.

Also improve error handling & reporting
2017-01-19 19:24:52 +01:00
Beat Küng 41d220ac2d sensors: reorder initialization calls
needed for the next commit
2017-01-19 19:24:52 +01:00
Beat Küng f6f145cbe8 sensors & mc_att_control: increase stack sizes due to recent changes 2017-01-19 19:24:52 +01:00
Beat Küng fd48d9c190 sensors: print status of temp compensation with 'sensors status' 2017-01-19 19:24:52 +01:00
Beat Küng 916a04bc56 sensors temp compensation: use SENSOR_COUNT_MAX instead of just 3 2017-01-19 19:24:52 +01:00
Lorenz Meier a3515893f3 ROMFS: Disable AR Drone and micro PCB quad for frames not supporting them 2017-01-19 19:24:52 +01:00
Beat Küng 117826a31f sensors temp compensation: refactor into a separate class
- reduces some code duplication
- provides clear API & separation for temp compensation

additional changes:
- added timestamp to sensor_correction topic
- reduced its publication rate, to only when voting index or scales or
  offsets change (if there is more than 1deg change in temperature)
2017-01-19 19:24:52 +01:00
Beat Küng 23d278cc43 sensors temp compensation: minor cleanup 2017-01-19 19:24:52 +01:00
Beat Küng f38843278d voted_sensors_update: make msl_pressure static const 2017-01-19 19:24:52 +01:00
Beat Küng e1ff6af792 mc_att_control_main: initialize _sensor_corrections properly 2017-01-19 19:24:52 +01:00
Beat Küng 535b1ea0dd voted_sensors_update: simplify accel & gyro poll methods 2017-01-19 19:24:52 +01:00
Lorenz Meier 6209cd0e57 Fix MPU6050 2017-01-19 19:24:52 +01:00
Lorenz Meier 62f95931ed MPU9250: Fix device ID 2017-01-19 19:24:52 +01:00
Lorenz Meier 1134f1a868 Fix sensor IDs 2017-01-19 19:24:52 +01:00
Beat Küng 7d5cd02c70 mc_att_control_main: fix bound check for gyro instance 2017-01-19 19:24:52 +01:00
Beat Küng bbd47389e0 voted_sensors_update: fix copy paste naming mistake 2017-01-19 19:24:52 +01:00
Beat Küng 0765ed552c sensor_correction.msg rename {gyro,accel,baro}_select to match uORB convention 2017-01-19 19:24:52 +01:00
Lorenz Meier 7326fea142 Driver compile fixes 2017-01-19 19:24:52 +01:00
Lorenz Meier 71fa064bc7 MPU6K: Fix device ID 2017-01-19 19:24:52 +01:00
Lorenz Meier 171c321acc MS5611: Fix device ID 2017-01-19 19:24:52 +01:00
Lorenz Meier 9860a17e25 MPU6K: Fix device ID 2017-01-19 19:24:52 +01:00
Lorenz Meier 479e6937d6 LSM303D: Fix devid 2017-01-19 19:24:52 +01:00
Lorenz Meier 36e4b8e5e8 LPS25H: Fix devid 2017-01-19 19:24:52 +01:00
Lorenz Meier 79caa30bd5 L3GD20: Fix devid 2017-01-19 19:24:52 +01:00
Lorenz Meier 6e2c43b3d9 BMP280: Fix devid 2017-01-19 19:24:52 +01:00
Lorenz Meier a42932033e BMI160: Fix devid 2017-01-19 19:24:52 +01:00
Lorenz Meier 00d26b75e9 MC att control: Harden against incorrect indices 2017-01-19 19:24:52 +01:00
Lorenz Meier 905c091f8c MAVLink receiver: Use fake device ID 2017-01-19 19:24:52 +01:00
Lorenz Meier 9f0d588989 Simulated drivers: Use fake device IDs 2017-01-19 19:24:52 +01:00
Lorenz Meier b1e4291590 Sensor messages device IDs: These remain unsigned 2017-01-19 19:24:52 +01:00
Lorenz Meier 49a29ee775 Fix up DriverFramework wrappers, bring them back to the real device ID they have already in-built 2017-01-19 19:24:52 +01:00
Paul Riseborough eac6dfed3c mc_att_control: Sync attitude loops to gyro data
Sync the attitude controller to the raw gyro data to remove the latency in the rate loops caused by the sensor and estimator modules.
Attitude data latency will increase as it will be from the previous EKF update, however attitude loops are less latency sensitive.
Thermal compensation and bias data will be from the previous frame.
2017-01-19 19:24:52 +01:00
Paul Riseborough b2113b9abe cmake: Reduce flash size for px4fmu-v2 build
Removes Iridium SBD support
2017-01-19 19:24:52 +01:00
Paul Riseborough edbe68f833 posix drivers: use orb instance as surrogate sensor ID for simulated IMU 2017-01-19 19:24:52 +01:00
Paul Riseborough e84a189380 drivers: use driver class instance as surrogate sensor ID for gyro and accelerometer 2017-01-19 19:24:52 +01:00
Paul Riseborough 60c12aaa36 msg: change sensor device ID's to signed integers
Required to use driver class instance as surrogate sensor ID
2017-01-19 19:24:52 +01:00
Paul Riseborough 0485c2b94a sensors: add baro pressure temperature compensation and reporting 2017-01-19 19:24:52 +01:00
Paul Riseborough c21b4aaf2e posix drivers: Populate baro device ID
TODO - use unique HW ID
2017-01-19 19:24:52 +01:00
Paul Riseborough 0ba31b521c uavcan: Populate baro device ID
TODO - use unique HW ID
2017-01-19 19:24:52 +01:00
Paul Riseborough 677616ed83 mavlink: Populate baro device ID
TODO - use unique HW ID
2017-01-19 19:24:52 +01:00
Paul Riseborough 5e53a5425a drivers: Populate baro device ID
TODO - use unique HW ID
2017-01-19 19:24:52 +01:00
Paul Riseborough 137bd73ea1 msg: add reporting of baro sensor corrections
Also improve documentation
2017-01-19 19:24:52 +01:00
Paul Riseborough c2fc283fdb sensors: Update single axis temp comp method to 5th order
This allows future use with baro sensors that require a higher fit order
2017-01-19 19:24:52 +01:00
Paul Riseborough 6a78df7fa0 ekf_att_pos_estimator: Publish control state gyro bias 2017-01-19 19:24:52 +01:00
Paul Riseborough f8cef1e9ab attitude_estimator_q: populate control state gyro bias data
Populate with zeros.
TODO provide estimate.
2017-01-19 19:24:52 +01:00
Paul Riseborough 27e6f07485 ekf2: publish control state gyro bias data 2017-01-19 19:24:52 +01:00
Paul Riseborough 28488cfcd0 msg: add gyro biases to control state message 2017-01-19 19:24:52 +01:00
Paul Riseborough da87e3eb0a posix drivers: Populate device ID in sensor topics for simulated IMU 2017-01-19 19:24:52 +01:00
Paul Riseborough 961474f430 posix drivers: Populate device ID in sensor topics for mpu9250 2017-01-19 19:24:52 +01:00
Paul Riseborough 1009550262 posix drivers: Populate device ID in sensor topics for mpu6050 2017-01-19 19:24:52 +01:00
Paul Riseborough 48f81f24e1 posix drivers: Populate device ID in sensor topics for lsm9ds1 sensor 2017-01-19 19:24:52 +01:00
Paul Riseborough 7c9e9f31e1 drivers/mpu9250: Populate device ID in sensor topics 2017-01-19 19:24:52 +01:00
Paul Riseborough 5177866b54 drivers/mpu6500: Populate device ID in sensor topics 2017-01-19 19:24:52 +01:00
Paul Riseborough ddda5eccd6 drivers/mpu6000: Populate device ID in sensor topics 2017-01-19 19:24:52 +01:00
Paul Riseborough cfaef7f433 drivers/lsm303d: Populate device ID in sensor topics 2017-01-19 19:24:52 +01:00
Paul Riseborough 14e2ea78b3 drivers/l3gd20: Populate device ID in sensor topic 2017-01-19 19:24:52 +01:00
Paul Riseborough 9014443d77 drivers/bmi160: Populate device ID in sensor topics 2017-01-19 19:24:52 +01:00
Paul Riseborough f12820755f msg: Add device ID to sensor_baro topic 2017-01-19 19:24:52 +01:00
Paul Riseborough 6a160ecad3 msg: Update documentation for gyro and accel sensor topics 2017-01-19 19:24:52 +01:00
Paul Riseborough 63f032832f Add prototype IMU temperature compensation
Enabled using TC_A_ENABLE and TC_G_ENABLE parameters
Disabled by default.
IMU offsets and scale factors for selected sensor published to sensor_correction topic
TODO Parameter storage method is cumbersome
2017-01-19 19:24:52 +01:00
Paul Riseborough 9599f58c5d msg: add uORB topic for IMU sensor corrections 2017-01-19 19:24:52 +01:00
Paul Riseborough 4f1b748786 msg: Fix documentation errors in sensor_combined 2017-01-19 19:24:52 +01:00
Matthias Grob db581fa5e8 mc_pos_control: hotfix for possible thrust below minimum thrust setting
Hotfix after a crash because of a heavily negative desired thrust that got clipped to 0 by the mixer.
0 thrust meant no more attitude tracking.
2017-01-19 18:05:57 +01:00
David Sidrane 23eb07ff3e Only perform GIOP operations on defined IO (#6381)
Check if the table entry fo the IO requested is defined
   so that 0 is never passed to px4_arch_gpioXXXX functions.
2017-01-18 09:53:16 -10:00
Beat Küng e7db0ed098 test_mixer & mixer: use memmove instead of memcpy
Both, src & dst use the same array, thus potentially overlapping.
Behavior of memcpy in that case is undefined.
2017-01-18 18:23:42 +01:00
Chris Lovett 33a307873a Enable rc mode change switch to override offboard mode. This is a safety feature, in case offboard control goes crazy, user can always regain control by switching modes to stabilize, or alt hold or position hold, however they have configured the mode change RC switch. 2017-01-18 18:15:58 +01:00
Vlad Radulescu ec104bb7ac Corrected a tiny spelling mistake and modifed the PPM_MIN_CHANNELS check so it accepts a minimum of 5 channels. It seems that was the initial intention. 2017-01-17 23:40:31 -08:00
David Sidrane 569b20d184 FMUv5 Fixed hardfault log
F7 was missing in the CONFIG_xxx that controlled enableing the
  hardfault_log boot code that can save the fault log
2017-01-17 23:11:20 -08:00
Henry Zhang 0fdf3b13e8 MindPX: disable USART3 flow control 2017-01-17 23:10:43 -08:00
Sander Smeets ba10db06c2 Code formatting 2017-01-17 03:14:26 -08:00
Sander Smeets d0dad4ad7d Indenting 2017-01-17 03:14:26 -08:00
Sander Smeets de039ca870 VTOL back transition acceptance radius calculation 2017-01-17 03:14:26 -08:00
BharathR 496dee5d2d Fixed PX4 sanity test script (removed a check msg) (#6354)
* Fixed build error in Snapdragon Flight legacy driver mode (partially)

* Fixed build error in eagle_legacy_default mode (px4muorb.h generation issue)

* Fixed the snapdragon flight sanity test script (default and legacy driver modes)

* Fixed PX4 sanity test script (removed a check msg)
2017-01-16 13:10:31 -08:00
Lorenz Meier 7fd06ee913 MAVLLink simulator interface: Simulate minimum airspeed noise 2017-01-16 08:26:37 -08:00
Lorenz Meier b8598c4407 Sensors: Adjust airspeed fail checks 2017-01-16 08:26:37 -08:00
Lorenz Meier a13082bfed commander: Widen pre-flight check for airspeed 2017-01-16 08:26:37 -08:00
Lorenz Meier b29e0040f1 ETS airspeed: Work around weird choice of manufacturer zero level cutoff 2017-01-16 08:26:37 -08:00
wangxdflight 67c3102db4 updated to remove a compilation flag check as orb_exists() is already supported 2017-01-16 08:25:58 -08:00
wangxdflight b693e29d64 enable px4 flight for excelsior(legacy) 2017-01-16 08:25:58 -08:00
Lorenz Meier 12767c8538 MC position controller: Stop holding position once ground contact is established.
This ensures the system does not tip over on landings. Tested in SITL with a GPS drift model.
2017-01-16 08:25:26 -08:00
Matthias Grob 5b54d78128 land detector: changed minimum throttle threshold to have useful landing detection in real world scenarios 2017-01-16 08:25:26 -08:00
Matthias Grob 39f9647291 mc_pos_control: fixed float literals and commented calculations 2017-01-16 08:25:26 -08:00
Matthias Grob f95fb0f20f land detector: commented takeoff throttle values for each mode 2017-01-16 08:25:26 -08:00
Matthias Grob 5f3cbbbbc2 mc_pos_control: changed thrust calculation to 3D projection onto body z axis
until now the desired thrust was simply the absolute value of the thrust setpoint vector
but a multicopter is only capable of producing thrust in its (negative) body z axis
this leads to excess thrust during attitude tracking errors

one important use case is:
trying to land with minimal thrust in NED z axis against gravity
but the position controller still correcting some small horizontal estimation errors
then this prevents unwanted thrust in a completely wrong direction
2017-01-16 08:25:26 -08:00
Julian Oes d63db203ba mc_pos_control: don't publish attitude sp 2x 2017-01-16 08:25:26 -08:00
Matthias Grob 7ab2958757 land_detector: added takeoff throttle threshold
if we control manually and are still landed, we want to stay idle until the pilot rises the throttle
2017-01-16 08:25:26 -08:00
Matthias Grob 5529023ec1 mc_pos_control: added feed forward hover thrust
the velocity controller was misusing the integral part to account for the constant gravitational force offset
the hover throttle from the parameter is now is now directly used as feed forward for the thrust in world z direction
the integrator compensates for inaccurate paarameter but should now be idealy zero
2017-01-16 08:25:26 -08:00
FantasyJXF 3f94818dcf spelling error;
as it is
2017-01-16 03:11:03 -08:00
Daniel Agar 73b31c031f cmake nuttx rsync copy only use relative paths
- this is to work around confusion between cygwin and windows native
   paths
 - closes #6332
2017-01-16 02:16:23 -08:00
BharathR dafa838e2f Fixed Snapdragon Flight sanity test script (default and legacy driver modes) (#6323)
* Fixed build error in Snapdragon Flight legacy driver mode (partially)

* Fixed build error in eagle_legacy_default mode (px4muorb.h generation issue)

* Fixed the snapdragon flight sanity test script (default and legacy driver modes)
2017-01-16 00:20:59 -08:00
Henry Zhang e81548bdb9 MindPX: Fix for hmc5883 rotation 2017-01-16 00:19:03 -08:00
Lorenz Meier 50002a0ff6 Update EEKF2 to match ecl updates 2017-01-15 01:57:38 -08:00
Lorenz Meier 7652a3737c Update ECL 2017-01-15 01:57:38 -08:00
Lorenz Meier 1c42cea28e MAVLink: Ignore bogus mission item requests silently 2017-01-15 01:47:10 +01:00
James Goppert 8e297022e6 Update px4tools api for mission test. 2017-01-14 18:55:39 -05:00
Daniel Agar d8f423aa2b travis-ci run check_format 2017-01-14 18:31:09 -05:00
Daniel Agar 207f08aa15 apps.cpp and ekf_att_pos_estimator readability braces fix 2017-01-14 18:31:09 -05:00
Daniel Agar 6961a513c7 clang-tidy readability-braces-around-statements 2017-01-14 18:31:09 -05:00
Daniel Agar fedc1279e4 travis-ci fix coverity build (#6338) 2017-01-14 17:36:51 -05:00
Lorenz Meier adcf563460 Update README 2017-01-14 21:04:10 +01:00
Lorenz Meier b6e18a1479 Mixer test: More instrumentation to catch repro cases in CI 2017-01-14 20:42:54 +01:00
mazahner 06d28b2635 Rework Includes during the uorb message generation
each CMakeFile that generates parameters should add its path to the msg_include_path
which will then be handled in the px_generate_uorb_topic_files.py
2017-01-14 10:07:12 -08:00
Nicolae Rosia 6ffffe3367 Remove invalid eigen reference
This is a left over from cleanup 0acf6db64f

Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
2017-01-14 10:02:44 -08:00
Lorenz Meier d1fcd8dd8e Fix code style for mavlink main 2017-01-14 07:47:03 -08:00
Lorenz Meier 557a57d51a Coverity: Fix RC tests 2017-01-14 07:47:03 -08:00
Lorenz Meier 521b89b1ce MAVLink: Protect against illegal length indication of RTCM data 2017-01-14 07:47:03 -08:00
Lorenz Meier 26625b3a5d Servo test: Fix resource leak 2017-01-14 07:47:03 -08:00
Lorenz Meier a905babe95 PPM LoopbackTest: Fix resource leak 2017-01-14 07:47:03 -08:00
Lorenz Meier 3d31914eb5 Tone alarm sim: Fix resource leak 2017-01-14 07:47:03 -08:00
Lorenz Meier 1549f5a5d1 sdlog2: Fix string termination 2017-01-14 07:47:03 -08:00
Lorenz Meier 3eb7caba4f MAVLink param handling: Exclude Coverity false positives 2017-01-14 07:47:03 -08:00
Lorenz Meier fc2970b309 Helicopter mixer: Fix out of bounds checks 2017-01-14 07:47:03 -08:00
Lorenz Meier 4939e42c0f MAVLink main: Fix resource leak for non-NuttX cases 2017-01-14 07:47:03 -08:00
Lorenz Meier b9e32d7a34 mixer test: Fix string handling
Some strings were not enforcing NUL termination.
2017-01-14 07:47:03 -08:00
Lorenz Meier 1155a4725b PX4IO: Fix mixer load corner case in string termination 2017-01-14 07:47:03 -08:00
Lorenz Meier 6927fcb5c0 Mixer test: Fix string termination corner case 2017-01-14 07:47:03 -08:00
Daniel Agar 9605507c87 travis-ci install jinja2 (#6333) 2017-01-14 10:10:15 -05:00
Daniel Agar 8caf6c54fa Makefile cleanup and travis-ci s3 deploy (#6329)
- pulls more of the travis-ci s3 deploy into the repo so we can potentially migrate to another CI system
 - fixed the sizes output and added verbose compiler version to cmake (#6322)
 - fixed filenames for firmware uploaded to s3 (was broken by the changes yesterday)
 - fixed some broken git version display in cmake
 - Makefile organization
 - simplified .travis.yml
 - added a print to know which config the nuttx patch was being applied to
 - docker_run.sh now respects PX4_DOCKER_REPO for setting the docker image, but defaults to the good production nuttx image
2017-01-14 09:38:28 -05:00
David Sidrane c235b44a90 FMUv5 define ADC usage 2017-01-14 02:26:48 -08:00
Daniel Agar df5d0ba8b9 airspeed cal more descriptive error message (#6324) 2017-01-13 17:26:27 -05:00
ChristophTobler 967197adee update sitl_gazebo to used flow with limited ouput rate 2017-01-13 04:34:57 -08:00
James Goppert b1173f1f62 Fix cmake version detection from git tag. 2017-01-13 01:11:14 -08:00
James Goppert 249d7f00ce Fix s3 deployment bug. 2017-01-13 01:11:14 -08:00
James Goppert 1877df7917 Fix Bootloader install files issue. 2017-01-13 01:11:14 -08:00
James Goppert a0fff97fd2 Moved deployment logic to python scripts. 2017-01-13 01:11:14 -08:00
James Goppert 50159cabbe Automatically set cmake version. 2017-01-13 01:11:14 -08:00
James Goppert 73462dc5e5 Add xml to cpack packaging. 2017-01-13 01:11:14 -08:00
James Goppert 434dddedea Changes to add px4fmu-v2_lpe config. 2017-01-13 01:11:14 -08:00
Andreas Antener 338804606a Fixed-wing: allow mission takeoff 2017-01-13 00:18:08 -08:00
Beat Küng 78c0186ff8 fix posix_rpi_native.cmake: add __DF_RPI define
Needed for the DriverFramework. Fixes the error:
15050 SPIDevObj start failed
15142 DevObj start failed
15185 Unable to open the device path:
ERROR [df_lsm9ds1_wrapper] LSM9DS1 start fail: -1
ERROR [df_lsm9ds1_wrapper] DfLsm9ds1Wrapper start failed
Command 'df_lsm9ds1_wrapper' failed, returned -1
2017-01-13 00:17:10 -08:00
David Sidrane 79d682e740 Master uavcan mainline (#6313)
* Update libuavcan to upstream master with PX4 contrib for NuttX 7.16+

* Release any 64B blocks not needed by usavcan after FW server is stopped.

  We simply call the srrink methode after the server stop.
  See https://github.com/PX4/Firmware/pull/3005#issue-111885687
  for backgound
2017-01-12 13:28:38 -10:00
CarlOlsson 0d3fd77ba9 mixer: Removed the pitch offset in the mixer file for the TBS Caipirinha since it should be handled by either hardware installation or trim parameter
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2017-01-12 13:35:30 -08:00
Lorenz Meier cf5f5bfad9 Fix code style for param 2017-01-12 10:57:11 -08:00
Mark Charlebois b14959e165 Fixed param output for QuRT
QuRT doesn't support printf, so the messages don't appeat in mini-dm.

This problem is also present in many other parts of the PX4 code.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-01-12 10:57:11 -08:00
David Sidrane ba2efff70f Updated libuavcan submodule with upstream ci fix.
This commit does not effect PX4 it just points to a commit
   that fixes a CI failure introduced in the changes upstrem to
   support the nuttx upgrade to 7.16+
2017-01-12 10:53:48 -08:00
Daniel Agar 056cd30629 Servo test: fix style 2017-01-12 03:02:05 -05:00
Julian Oes c91b36bf1f px_uploader.py: try to follow PEP8 (#6278)
This fixes some non-Pythonic things and unneccessary semicolons.

Still to fix are line-length and multiple spaces before operators.
2017-01-12 02:51:06 -05:00
Lorenz Meier a8902472e4 Params: Fix the description text
The MAIN and AUX outputs had the same description which could confuse users.
2017-01-12 02:40:56 +01:00
Lorenz Meier 61d7f22aba Servo test: Ensure we only close an open FD 2017-01-12 02:31:15 +01:00
BharathR 8c7f810cc2 Fixed build error in eagle_legacy_default mode (px4muorb.h generation issue) 2017-01-11 17:12:27 -08:00
bharathr ee0b0f2a3e Fixed build error in Snapdragon Flight legacy driver mode (partially) 2017-01-11 17:12:27 -08:00
David Sidrane ae946be046 Changes to RCC HSI and FLASH driver
STM32F4 does not require the HSI to erase or program FLASH
   The HSI needs to be left on until a new clock source is chosen.
   (we leave it on all the time)
2017-01-11 17:11:22 -08:00
Daniel Agar 751909cd4e clang readability-braces-around-statements (#6298) 2017-01-11 17:01:51 -05:00
Beat Küng 48c5ec54bb commander: make sure all code paths return an (n)ack to MAV_CMD_PREFLIGHT_CALIBRATION 2017-01-11 16:25:04 +01:00
Dennis Mannhart 8cd913c148 gps.cpp: add gps baudrate 230400 to qurt 2017-01-10 11:49:05 +01:00
ChristophTobler 21587bf8d3 update submodule sitl_gazebo 2017-01-10 10:09:38 +01:00
Lucas De Marchi 26d107923b motor_test: fix use of negative channel 2017-01-10 08:34:53 +01:00
Lucas De Marchi c3b462b3d6 motor_test: fix getopt call
This was trying to use optarg when it should instead use myoptarg.
2017-01-10 08:34:53 +01:00
Mark Whitehorn 71baa4b54a Update README.md 2017-01-09 15:42:58 -08:00
Mark Charlebois f529069368 Fixed code format issues
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-01-09 15:41:54 -08:00
Mark Charlebois 00a6fab5a2 Converted cout to printf
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-01-09 15:41:54 -08:00
Mark Charlebois d0c379e371 Removed inconsistent static definition
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-01-09 15:41:54 -08:00
Mark Charlebois b9ba673009 Added wait_for_topic builtin command
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-01-09 15:41:54 -08:00
Mark Charlebois 830eb8528e fixed merge conflict
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-01-09 15:41:54 -08:00
Mark Charlebois b08e70b65a Enabled topic_unadvertised
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-01-09 15:41:54 -08:00
Mark Charlebois 9834155d09 Removed extra debug
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-01-09 15:41:54 -08:00
Mark Charlebois b556528984 Fixed wait_for_topic and orb_exists
orb_exists was not updating the DSP topics on apps proc side

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-01-09 15:41:54 -08:00
Mark Charlebois 62a3e07423 orb_exists support for muorb
Also added builtin command wait_for_topic

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2017-01-09 15:41:54 -08:00
Daniel Agar dc787830b5 circleci run tests under code coverage (#6273)
* use regular optimization levels for the code coverage build.
 * the mixer test fails intermittently when built without optimization
2017-01-09 16:08:40 -05:00
Beat Küng 768485c083 jmavsim: update submodule
- enable baro noise
- add lat/lon to ground truth
2017-01-09 11:19:45 +01:00
Beat Küng 30f80515ec fix logger: sscanf was used wrong for custom topics file
using scanf with %s reads until the first whitespace, which included the
comma (as per C standard and tested on linux). Behavior on NuttX differs.

This makes it work on both Linux and Nuttx.
2017-01-09 11:09:37 +01:00
Daniel Agar b8afc97959 clang-tidy config file .clang-tidy (#6277) 2017-01-08 21:55:24 -05:00
Daniel Agar defaf7f5e5 docker run helper script (#6270) 2017-01-08 13:45:28 -05:00
matanhavi 7df3b4ae71 check_submodules recursevely go over all submodules (#6272)
* Recursevely go over all submodules
Using git submodules command going over all the submodules and not only the ones on the whitelist
and fixed white spaces
2017-01-07 18:55:45 -05:00
Daniel Agar c9956e25b4 mavlink fix code style 2017-01-07 01:03:18 -05:00
Daniel Agar c280358e32 navigator fix code style 2017-01-07 01:03:18 -05:00
James Goppert be14c11589 Fix hook install script to create hook dir if it doesn't exist. (#6269) 2017-01-06 19:28:03 -05:00
Daniel Agar 48e7c784e7 remove px4_model targets from all 2017-01-06 11:56:27 +01:00
Beat Küng 9b3803f71c px_process_params.py: fix for empty cmake scope
Hotfix for cmake configs which use include() for the module list (eg.
posix_sitl_ekf2.cmake or snapdragon). In that case the cmake parser did
not find any modules and thus the param list was empty.

The proper fix will be to parse the include() statements correctly.
2017-01-06 11:52:26 +01:00
Bart Slinger ff560e8c16 Blade130X heli meta-data 2017-01-06 10:01:46 +01:00
Stephan Brown 5a6084de07 param: Add a missing include. 2017-01-06 09:58:58 +01:00
Stephan Brown e57f6221b2 Rearrange parameter unit tests so they are in alphabetical order. 2017-01-06 09:58:58 +01:00
Stephan Brown 67a484ac34 Make parameter generation also depend on the scripts that run. Address some review comments. 2017-01-06 09:58:58 +01:00
Stephan Brown 92b2395ff6 param: Fix another off by 1 error and a formatting issue. 2017-01-06 09:58:58 +01:00
Stephan Brown bf57e86dc2 param: Fix an off by 1 issue and some style fixes. 2017-01-06 09:58:58 +01:00
Stephan Brown fe8deeeed9 param: Add a system command for finding parameters by name. 2017-01-06 09:58:58 +01:00
Stephan Brown 99228bdeb1 param: Use utarray_find when looking for changed parameters and use a binary search for finding param handles by name. 2017-01-06 09:58:58 +01:00
Stephan Brown e90bf8f8e5 px_generate_params: Sort parameters by name after parsing the xml file. 2017-01-06 09:58:58 +01:00
Andreas Antener 272f1dd4b9 Firefly6: config meta data update and some small param changes 2017-01-05 06:47:40 +01:00
Daniel Agar b721f5fc7c fw_att_control init all fields and delete unused 2017-01-04 16:08:20 -05:00
Daniel Agar 67975d68bb tailsitter_recovery initialize yaw_ff 2017-01-04 16:08:20 -05:00
Daniel Agar ab52bf0391 attq remove unused perf counters 2017-01-04 16:08:20 -05:00
Daniel Agar 525448de93 navigator follow target add harmless float cast 2017-01-04 16:08:20 -05:00
Daniel Agar 61e48e2286 navigator comment fall through in case 2017-01-04 16:08:20 -05:00
Daniel Agar b1d537c603 launchdetection initiailize motorDelayCounter 2017-01-04 16:08:20 -05:00
Daniel Agar a7e38e1119 Makefile rename checks_alt to alt_firmware 2017-01-04 11:16:28 -05:00
Lorenz Meier 45c1ad830f Autostart: Do not abort boot if sensor driver fails to start 2017-01-04 10:44:08 +01:00
Lorenz Meier 36ba5eb741 Control lib: Fix string handling corner cases
strncpy() does not enforce NUL-termination, but snprintf() does. So we need to ensure all strings are terminated. Another issue was the use of the wrong length parameter for these functions, resulting in the limiting arguments not being applied to the right length.
2017-01-04 10:14:25 +01:00
Daniel Agar d5082251d9 controllib decrease blockNameLengthMax to 40 2017-01-04 10:04:30 +01:00
Daniel Agar b3c741715a controllib block use consistent name length
- coverity CID 12524, 12542, 12548, 12550
2017-01-04 10:04:30 +01:00
Lorenz Meier 256222d44d HMC5883: Remove output on driver level. Reporting should be done by the caller, not inside the driver. 2017-01-04 09:40:50 +01:00
mazahner 6b0a6fb38f again remove unrequired output 2017-01-04 09:29:52 +01:00
mazahner f0c393baf6 remove unnecessary printfs 2017-01-04 09:29:52 +01:00
mazahner 4e9c986806 remove optional_files dependency
This is a remainder of a rebase onto master
2017-01-04 09:29:52 +01:00
mazahner 6fe9b8e543 use CmakeLists scope to generate te XML file
- the only difference really is, that scope (the configuration.cmake) is already passed
  to px_process_params via the argument --scope. The Paths in --scope are evaluated w.r.t
  the path to src provided via the -s /--src-path argument.
- if no --scope is proveided. the Old scheme by simply walking the full --src-path directory
  is applied
2017-01-04 09:29:52 +01:00
Lorenz Meier c72de874d6 Chance airframe and parameter meta generation to FMUv4 2017-01-04 09:29:19 +01:00
Andreas Antener cc1989b180 Convergence: updated param from todays flights 2017-01-03 20:32:33 -05:00
Andreas Antener 2416e523e4 Convergence: normalize the mixer 2017-01-03 20:32:33 -05:00
Andreas Antener 1de7636fad Tiltrotor: gradually reduce roll control with time or airspeed instead of simply switching it off 2017-01-03 20:32:33 -05:00
Andreas Antener f2db8d0106 VTOL: added missing open loop time parameter 2017-01-03 20:32:33 -05:00
Andreas Antener 364a57016f VTOL: added config for the E-flite Convergence 2017-01-03 20:32:33 -05:00
Andreas Antener c416fc3fa0 Tiltrotor:
- added open-loop transition time for airspeed-less flying
- added ramping down the back motors during forwards transition
2017-01-03 20:32:33 -05:00
Andreas Antener 35740b0b59 Mixer test: fix paths for nuttx 2017-01-03 20:32:33 -05:00
Lorenz Meier 3229c4183a Mixer test: Condition strncpy properly 2017-01-03 20:32:33 -05:00
Lorenz Meier 9e95d88574 Use system define for path length buffer 2017-01-03 20:32:33 -05:00
Lorenz Meier 2cabc4866a PX4IO: Use mixer header for buffer length 2017-01-03 20:32:33 -05:00
Lorenz Meier c6b6d04a19 UART tests: Move shell and fix config restore command 2017-01-03 20:32:33 -05:00
Lorenz Meier 0d5089e3bf Mixer test: Improve portability 2017-01-03 20:32:33 -05:00
Lorenz Meier 5247f17576 Mixer test: use real defines from IO firmware
We use the real defines now and test them against every mixer on the system. This means we should catch transfer errors now before even hitting master.
2017-01-03 20:32:33 -05:00
Lorenz Meier d401252c9e IO firmware: Convert magic numbers to defines
This is necessary to allow more and better unit testing.
2017-01-03 20:32:33 -05:00
Lorenz Meier e395c1f3d7 ROMFS: Limit test mixer to max 4 inputs 2017-01-03 20:32:33 -05:00
Andreas Antener a5a5694a5e Mixer tests: updated vtol2 test mixer to the one that actually failed before 2017-01-03 20:32:33 -05:00
Lorenz Meier d0dbddea1b Extend mixer test case with complex mixer 2017-01-03 20:32:33 -05:00
Lorenz Meier 51a89b74fb VTOL mixer: Use formatting without workarounds for system test 2017-01-03 20:32:33 -05:00
Lorenz Meier b3ce3cbaff Simple mixer: Remove incorrect pre-parser and replace with fixed central implementation 2017-01-03 20:32:33 -05:00
Lorenz Meier dd05ff5156 Multirotor mixer: Remove incorrect pre-parser and replace with fixed central implementation 2017-01-03 20:32:33 -05:00
Lorenz Meier ff18140cf4 Mixer: add string wconditioning check.
This introduces a correctly designed pre-check for the input parsers. This fixes the mixer unit test and should fix all issues occuring on real hardware.
;
2017-01-03 20:32:33 -05:00
Lorenz Meier 0810bcfe8e Polish mixer test, remove any too verbose output 2017-01-03 20:32:33 -05:00
Lorenz Meier c27728a7aa Test VTOL test mixers 2017-01-03 20:32:33 -05:00
Lorenz Meier 2eda90906d Add VTOL2 test mixer 2017-01-03 20:32:33 -05:00
Lorenz Meier 01bbd3976b Add VTOL1 test mixer 2017-01-03 20:32:33 -05:00
Lorenz Meier fb8243d5e1 Mixer test: Fix test, failing right now but showing the real issues 2017-01-03 20:32:33 -05:00
Lorenz Meier 8cc261a148 Slight improvements in unit tests 2017-01-03 20:32:33 -05:00
Daniel Agar bae3f36900 circleci temporarily disable code coverage (#6248) 2017-01-03 18:16:10 -05:00
Bart Slinger a7eed46062 Update vtol_att_control_main.cpp
Fixes https://github.com/PX4/Firmware/issues/6246
2017-01-04 00:02:53 +01:00
Dennis Mannhart d124de5045 px4.config: add spektrum_rc to startup
added line at the end
2017-01-03 20:54:06 +01:00
Beat Küng ab3b68cf18 ORB_PRIO: set ORB_PRIO_MIN to 1 instead of 0
This is needed as the sensors app assumes a value of 0 means uninitialized.

Follow-up to 'Sensors app: Fix consistency checks', a6696d339d
2017-01-03 20:53:26 +01:00
Beat Küng 000d965a5e fix test_uart_loopback: 0 is a valid file descriptor 2017-01-03 14:44:45 +01:00
Daniel Agar a9d3f0dc73 update gps driver submodule 2017-01-03 14:44:45 +01:00
Lorenz Meier 750ab87303 GPS Sim: Fix destructor 2017-01-03 14:44:45 +01:00
Lorenz Meier 9cfd46b87c Airspeed sim: Fix reset function 2017-01-03 14:44:45 +01:00
Lorenz Meier 4fcb4cf0fd MAVLink: Fix FTP file path handling
This was a real issue for long paths and not a flight safety issue for regular users, but could have been an issue for developers trying to use FTP on very deep nested file systems
2017-01-03 14:44:45 +01:00
Lorenz Meier 66226fb754 Land detector: Harden string handling
Due to known input this was not a real issue, but bad style.
2017-01-03 14:44:45 +01:00
Lorenz Meier 1a1522d3ff Fix RC unit test 2017-01-03 14:44:45 +01:00
Lorenz Meier 9f3fe2a802 Fix unit tests leaking resources
This was harmless but none the less is not good style and needs fixing.
2017-01-03 14:44:45 +01:00
Beat Küng 2880bb185f uavcan_main: replace std::array with a C array
Sadly, we cannot use std::array on NuttX
2017-01-03 13:25:33 +01:00
Beat Küng 59ca22ee6d px4.h: remove this include, causes compile problems on GCC 6.1.0
It causes problems because it includes px4_nodehandle.h which in turn
includes <functional>, and this is not available on NuttX
2017-01-03 10:39:55 +01:00
Beat Küng f0c905ae43 Makefile: remove executable bit 2017-01-03 10:39:55 +01:00
Daniel Agar c5c676cbd5 tests template remove list_builtins 2017-01-03 04:20:19 -05:00
Daniel Agar 9689163125 tests skip junit output and cmake exclude from all 2017-01-03 04:16:11 -05:00
Daniel Agar 573aed0ee8 tests coverage reorder to avoid lcov issues 2017-01-03 04:00:41 -05:00
Daniel Agar 6d4579751a tests add airspeedsim 2017-01-03 04:00:41 -05:00
Daniel Agar d4d63b982d unittests disable optimization for coverage 2017-01-03 04:00:41 -05:00
Daniel Agar c37d2c13e3 circleci limit coveralls submit to main repo 2017-01-03 04:00:41 -05:00
Daniel Agar b4da337cd4 test coverage cleanup
- dataman clean exit code
 - unit test proper cleanup
 - add some level of simulated sensors for tests
 - delete unused test/standard_vtol
2017-01-03 04:00:41 -05:00
Julian Oes a985c27ab0 navigator: reset reached flag, not reached seq
It doesn't make sense to reset the reached sequence, especially not to
false since it's an int.
2017-01-03 08:22:34 +01:00
Julian Oes a394d148a1 navigator: don't reset current waypoint
We don't want to reset the current waypoint because this means that the
ground stations see a current waypoint of 0 if the current waypoint is
not updated e.g. when we're not in mission mode.

However, it is wrong to send 0 as the current waypoint because if we
switch back to mission mode, it will actually go to the last current
waypoint and not 0.
2017-01-03 08:22:34 +01:00
Daniel Agar e0eada4400 travis-ci run coverity scan (#6230) 2017-01-02 23:34:45 -05:00
Daniel Agar a0837b88a5 cmake add clang santiziers
- PX4_ASAN=1 enable address sanitizer (was MEMORY_DEBUG)
 - PX4_TSAN=1 enable thread santiizer
 - PX4_UBSAN=1 enable undefined behaviour santizier (some options off)
2017-01-02 10:14:41 +01:00
Daniel Agar 1ceb0bebb5 sitl tests don't manually stop mavlink and dataman 2017-01-02 10:14:41 +01:00
Daniel Agar 34b2fb55e6 Makefile add clang-check and clang-tidy helpers 2017-01-02 10:14:41 +01:00
Daniel Agar 28971caaf3 partially restore mavlink_tests 2017-01-02 10:14:41 +01:00
Daniel Agar 5ec546f735 Makefile add scan-build target 2017-01-02 10:14:41 +01:00
Daniel Agar dc9a71b674 WIP startup_shutdown test with ASAN on 2017-01-02 10:14:41 +01:00
Daniel Agar f8d7c53537 lcov exclude gtest and mavlink 2017-01-02 10:14:41 +01:00
Daniel Agar 9fad6f9dd2 travis-ci use PX4_DOCKER for builds and specify tag 2017-01-02 10:14:41 +01:00
Daniel Agar 3607e72d4d OSX don't run uorb test 2017-01-02 10:14:41 +01:00
Daniel Agar 554f6da1c2 circleci fix test reports and artifacts storage 2017-01-02 10:14:41 +01:00
Daniel Agar b6ff406b7f circleci upload coverage to coveralls 2017-01-02 10:14:41 +01:00
Daniel Agar cc6fc48be2 circleci fix .ccache permissions 2017-01-02 10:14:41 +01:00
Daniel Agar d6fd633500 sitl tests manually list all 2017-01-02 10:14:41 +01:00
Daniel Agar 4f97ef417f sitl tests all config 2017-01-02 10:14:41 +01:00
Daniel Agar 9ae5e55f43 Makefile escape cmake generator string 2017-01-02 10:14:41 +01:00
Daniel Agar 351b3d20cb sitl testing exclude tests 2017-01-02 10:14:41 +01:00
Daniel Agar 97bc0f4486 gather test results 2017-01-02 10:14:41 +01:00
Daniel Agar cddef87998 Makefile split large target list for semaphore 2017-01-02 10:14:41 +01:00
Daniel Agar 74231e6656 split tests for SITL ctest 2017-01-02 10:14:41 +01:00
Daniel Agar cbc9680800 relax uorb test required avg 2017-01-02 10:14:41 +01:00
Daniel Agar c9192e23e1 quiet git header output 2017-01-02 10:14:41 +01:00
Daniel Agar ac7c309925 move cmake version check into cmake 2017-01-02 10:14:41 +01:00
Daniel Agar 9ea80e9ff0 Makefile add PX4_RUN docker wrapper 2017-01-02 10:14:41 +01:00
Lorenz Meier 9178bb7371 Add new posix_sitl_shell build target which allows to run -make posix_sitl_shell none- in order to get an empty shell 2017-01-01 13:59:41 +01:00
Lorenz Meier 78f00368c5 Dataman: Be less verbose on start to clutter shell output less 2017-01-01 13:59:41 +01:00
ChristophTobler 037d91c51c update posix-config for inav optical flow 2017-01-01 13:33:27 +01:00
Lorenz Meier 0205492a24 Update Mixer for LPE solo 2016-12-30 12:21:16 +01:00
jg 14ddc3018a fixed solo gazebo target 2016-12-30 12:20:15 +01:00
ChristophTobler 90eada1e43 update sitl_gazebo submodule 2016-12-30 10:39:57 +01:00
ChristophTobler 11de4d70a6 add config file for ekf2-optical flow 2016-12-30 10:39:57 +01:00
ChristophTobler 04bc745d66 update sitl_gazebo submodule to master 2016-12-30 10:39:57 +01:00
Paul Riseborough 94ce6e12c1 sensor: update default flow sensor rotation
The SENS_FLOW_ROT parameter is used in the px4flow and mavlink receiver to perform the rotation from sensor frame to body frame.
2016-12-30 10:39:10 +01:00
Paul Riseborough 3787fafdff px4flow: update default rotation and documentation
The driver performs the rotation from sensor frame to body frame.
The recommended installation default is with the Y sensor axis pointing forward.
2016-12-30 10:39:10 +01:00
Paul Riseborough eca2aeccf9 position_estimator_inav: Make optical flow data conversions consistent with uORB interface 2016-12-30 10:39:10 +01:00
Paul Riseborough 92f5211f55 local_position_estimator: Make optical flow data conversions consistent with uORB interface 2016-12-30 10:39:10 +01:00
Paul Riseborough ae55c8d87c msg: Clarify sign conventions for optical flow message 2016-12-30 10:39:10 +01:00
Lorenz Meier a6696d339d Sensors app: Fix consistency checks.
The sensors app assumed that all topics are published on boot which is not necessarily true and it assumed that all publications had valid data. This change ensures that topics are initialized as they update the first time and that the consistency check only runs on topics which carry valid data.
2016-12-30 00:06:04 +01:00
ChristophTobler 06436e753e acount for SENS_FLOW_ROT in simulation 2016-12-29 15:10:29 +01:00
Lucas De Marchi fd91f998c4 build: sort targets for GCS download
While at it, fix the trailing continuation line in the last item.
2016-12-29 08:54:02 -05:00
Lucas De Marchi e3f7bbfd8c build: add aerofc firmware for GCS download 2016-12-29 08:54:02 -05:00
Lorenz Meier ece8d85860 Add ICM20602 to Pixracer config 2016-12-29 11:55:57 +01:00
Dennis Mannhart d0d6b39602 This fix is needed because of the pitch_min and time_inside union from mission_item.
Without this fix, the function "get_time_inside" from navigation.h looses its purpose
to distinguish between takeoff and other waypoints.
2016-12-29 03:08:37 +01:00
Lorenz Meier c597a8e1df Disable a set of warnings for NuttX that are new in GCC 6 2016-12-28 15:14:48 +01:00
Lorenz Meier 381611bb66 LL40LS: Make commandline arguments easier to use 2016-12-28 15:07:56 +01:00
Lorenz Meier 9c2f4503a1 Additional test command feedback 2016-12-28 15:04:28 +01:00
Lorenz Meier 4c8e353df7 Fix navigator build error after re-integration 2016-12-28 12:02:25 +01:00
Andreas Antener 7dcba260a7 Fix meta data for added boolean parameters 2016-12-28 11:53:19 +01:00
Simon Wilks 647fafe9bc Allow for immediate cruise speed changes at any time during a mission. 2016-12-28 11:53:19 +01:00
Andreas Antener e0fc0a847c Mission:
- weathervane on takeoff
- separate cruising speeds for VTOL in MC and FW
- cruising speed resets
- mission work item logic is more clear
- fixed double execution of certain work item states
- enable cruise speed change on the fly by command
- moved VTOL transition target position generation to mission code and set always
2016-12-28 11:53:19 +01:00
Sander Smeets 2c78e9de5d DroneKit IT: use new QGC json format 2016-12-28 11:47:52 +01:00
Sander Smeets 53be474191 Simplify dronekit mode change 2016-12-28 11:47:52 +01:00
Sander Smeets 05fda0c0fe Fix test mission index 2016-12-28 01:19:28 +01:00
Lorenz Meier f153e9b024 Nucleo board config: Add px4_tasks header 2016-12-27 21:00:51 +01:00
Lorenz Meier 57fd8ffbed Update Crazyflie board driver to include task header 2016-12-27 21:00:51 +01:00
Lorenz Meier 4ceeb8b0e1 HoTT driver: Add task header dependency 2016-12-27 21:00:51 +01:00
Lorenz Meier faf83aad6a Aero FC: Add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier 8a53866553 AUAV 2.1: Add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier 1f8fabd619 MindPX: Add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier 4ba12f71a0 FMUv2: Add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier 6bc70af7a0 FMUv2: Add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier c5a167935e FMUv4PRO: Add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier b3c3f92988 FMUv5: Add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier 520b1dfe07 TAP: Add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier c2af93d1a5 sensors: Add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier 27cc274991 FW control: add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier 9275436043 FMU: Add missing headers 2016-12-27 21:00:51 +01:00
Lorenz Meier f1aeeef35e Posix: Add tasks header 2016-12-27 21:00:51 +01:00
Lorenz Meier 89b37fd727 IO: Add missing float header 2016-12-27 21:00:51 +01:00
Lorenz Meier 4653a7f883 Bottle drop: fix headers 2016-12-27 21:00:51 +01:00
Lorenz Meier 884876babf Rover: fix headers 2016-12-27 21:00:51 +01:00
Lorenz Meier 13dc938de2 MK driver: Fix header 2016-12-27 21:00:51 +01:00
Lorenz Meier 2ccf0c7bea FrSky: Header fix 2016-12-27 21:00:51 +01:00
Lorenz Meier ca5ee13238 Fixed Ardrone driver 2016-12-27 21:00:51 +01:00
Lorenz Meier 26b6e64ddc Unit tests: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 556938aebd Sim: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 0e09f072e1 L1: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier a516a2ccf1 LPE: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 1ce43f8d46 Inav: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 2ec9f4a74e uORB: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 38d27e284f Logger: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 8fd22c7f54 Q: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier f72b439fd5 Dataman: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 8416505a67 Commander: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 16dfd4c6ff Navigator: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 1511838919 Pos control: header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 7f4519d763 VTOL: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 90c4b41234 Examples: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 2cfcf3402e Systemlib: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 8d4edd74b8 Platforms: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 50d07b196c EKF: Header cleanup 2016-12-27 21:00:51 +01:00
Lorenz Meier 1857a16e90 vmount: Header cleanup, do not build param file 2016-12-27 21:00:51 +01:00
devbharat 5a8c542d46 Added checks for setting mpc saturation flags 2016-12-27 17:38:00 +01:00
Roman b596874b91 ulanding radar: small improvements
- set measurement of first sample to -1 to indicated that the data
is not valid

- give an estimate of the sensor variance based on the sensor resolution
and experiments

Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-27 15:35:55 +01:00
Roman 97d106b5f1 ulanding radar: added correct sensor type
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-27 15:35:55 +01:00
Roman bb3b2ba52c distance sensor message: added type for radar sensors
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-27 15:35:55 +01:00
Roman 0b9da80ec1 ulanding radar: added parsing of buffer
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-27 15:35:55 +01:00
Roman 06498ce01a build ulanding radar for Pixhawk version 2
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-27 15:35:55 +01:00
Roman 4e71d2e2db ulanding radar from Aerotenna: added driver for NuttX
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-27 15:35:55 +01:00
Sander Smeets 3649def02e Fix heading hold for ekf2 mission takeoff 2016-12-27 13:05:26 +01:00
Daniel Agar e491817610 cmake nuttx create target for nuttx copy 2016-12-27 11:45:48 +01:00
Daniel Agar b1496f72cd Makefile cleanup target lists 2016-12-26 23:50:51 -05:00
Daniel Agar 13c7cd29b3 docker update to 2016-12-26 images 2016-12-26 23:50:51 -05:00
Anton Matosov 3a17c07b1e Implement RC and DL failsafe action handling for multirotors
Move RC and DL failsafe actions handling from navigator to commander (credits to @AndreasAntener)
Separate manual kill switch handling via manual_lockdown to prevent override and release of software lockdown by RC switch

Other changes:
Add failsafe tune
Fix LED blinking for Pixracer
Return back support for rc inputs in simulator but now it is configurable via cmake
2016-12-27 00:38:13 +01:00
James Goppert 964dabe179 Add better option handling to integration testing script. 2016-12-27 00:34:13 +01:00
Lorenz Meier ce106a8324 Disable the safety switch by default on Pixracer
This disables the safety switch when Pixracer is configured. It does not change existing setups and it can be re-enabled after. This might be the more sensible default for a racing board.
2016-12-26 19:53:17 +01:00
Sander Smeets 8defe7e7d9 Revert scaling change 2016-12-26 16:56:22 +01:00
Sander Smeets ba3796ebaf Work with double scaling 2016-12-26 16:56:22 +01:00
Sander Smeets 17a089af31 Fix orb poll 2016-12-26 16:56:22 +01:00
Sander Smeets 7fd5aae834 Apply battery voltage throttle scaling to FW (ported from #5778) 2016-12-26 16:56:22 +01:00
James Goppert 8fdd392700 Added ground truth tests to sitl gazebo CI. 2016-12-26 16:33:37 +01:00
Andrew Tridgell d150b4b084 px4iofirmware: fixed a bug with override handling
this fixes a race condition between the DMA completion handler
updating registers in px4io and the mixer used for handling the
override state. The register set code could set r_page_servos[]
between the time when pwm_limit_calc() is called and the servos are
actually output.
2016-12-26 16:32:33 +01:00
Lucas De Marchi 72d8a4f932 aerofc: improve upload script
- Run in a single ssh command
  - Allow to update firmware when mavlink-routerd had already been
    stopped
  - Be resilient to another daemon interfering the communication by
    reading/writting to the UART
  - Print OS, BIOS nad FPGA version
2016-12-26 16:11:33 +01:00
Lucas De Marchi d26b406a04 aerofc: update script to upload firmware
mavlink_bridge.py script was removed in favor of new mavlink-router
project (https://github.com/01org/mavlink-router).
2016-12-26 16:11:33 +01:00
Lucas De Marchi 1fafa2069c sensors: aerofc: set default voltage divider 2016-12-26 16:11:33 +01:00
Lucas De Marchi 0341af4858 aerofc: add some fixes to adc driver
- Other channels are irrelevant since they aren't physically
    connected. Avoid the I2C transaction to get invalid data
  - Port the driver to use only one address, as it should be
  - Minor changes here and there
  - Add test() method to read the latest value - helpful during
    debugging.
2016-12-26 16:11:33 +01:00
José Roberto de Souza 53f2c1eb19 aerofc: Implement ADC
Measure the battery voltage of Aero RTF kit will be done by FPGA
and read by AeroFC using I2C bus.

The protocol is a little bit odd, it have different I2C slave
address for each "register", in future the FPGA RTL will
have a protocol more similar to other I2C sensors.

Also Aero RTF don't have a ADC line to measure current consumption.
2016-12-26 16:11:33 +01:00
Michael Schaeuble 71e48c937e Restructure posix cmake configuration
We check if the target is SITL and do not build it with all other
posix targets.
2016-12-26 15:38:25 +01:00
Anton Matosov 6d3116e30b Implement the way to run posix simulator directly from IDE without the need to reconfigure command lines, but use runner created via CMake
Steps to debug:
 * Run gazebo (or any other sim) server and client viewers via the terminal: `make posix_sitl_default gazebo_none_ide`
 * In your IDE select `px4_<mode>` target you want to debug (e.g. `px4_iris`)
 * Start debug session directly from IDE

This approach significantly reduces the debug cycle time because simulator (e.g. gazebo) is always running in background and you only re-run px4 process which is very light.
2016-12-26 15:38:25 +01:00
Matthias Grob b79e4ab506 land detector: reverted scientific notation unwanted doubles 2016-12-26 15:36:43 +01:00
Matthias Grob 03d7b65299 land detector: refactoring ff to freefall 2016-12-26 15:36:43 +01:00
Matthias Grob 808dedf441 land detector: small refactor while studying 2016-12-26 15:36:43 +01:00
Lorenz Meier 494d2c9ecf ROMFS: Enable robust PWM command mode during startup 2016-12-26 15:34:53 +01:00
Lorenz Meier ca096c1257 PWM command: Allow robust error code returns 2016-12-26 15:34:53 +01:00
Lorenz Meier fff35fe34b Commander: Improve preflight check experience
* Loosen thresholds for gyro consistency check until temperature compensated units are the norm
  * Cut down string lengths so they make it through the MAVLink transport as a whole
2016-12-26 14:04:30 +01:00
Lorenz Meier 4dc96e3ea1 MAVLink app: Remove flow control warning to clean up the boot log 2016-12-26 13:55:04 +01:00
Lorenz Meier 074e666b95 PX4IO: Robustify firmware for mixer load operation
This change makes the mixer load and reset operation closer to thread-safe. It was guarded one-way before and in only one location. This change ensures that its being locked out from both directions. The accesses to the locking variables still need work because they are non-atomic.
2016-12-26 13:41:36 +01:00
Lorenz Meier 5b70522541 Mixer: Make reset operation more robust
This change makes the operation more robust as it flags the whole group invalid in the first step. This should not be confused with being thread-safe - to be thread-safe, all accesses to _first and the following linked list need to be guarded by a mutex. This should be done outside of the mixer in the driver though, as the method depends on the board architecture.
2016-12-26 13:41:36 +01:00
Lorenz Meier 66b9ee2d24 UAVCAN: Make GPS module use the multi-topic facility so that a normal GPS and an UAVCAN GPS can co-exist and do not write on top of each other. 2016-12-26 12:12:44 +01:00
Lorenz Meier da198a40c5 Code style check: Remove stale folder location 2016-12-26 12:12:44 +01:00
Lorenz Meier 8a58cf0daa Fix usage of CRTSCTS define from termios.h
NuttX had the CRTSCTS define incorrectly set for only output flow control, which broke our flow control logic. This commit patches NuttX and puts in addition a guard in place to prevent any future issue with the non-POSIX define being incorrect.

This has been debugged and identified by @ecmnet, which was the main contribution for this patch.
2016-12-26 12:08:05 +01:00
Lorenz Meier 72eafe7e72 Fix DSM debug statement. From @firwar 2016-12-25 21:55:23 +01:00
Lorenz Meier 0b6e0c020e MAVLink stream: Guard against an interval value of zero 2016-12-25 21:34:19 +01:00
Lorenz Meier 48f1ae31dd Iris: use correct mixer for frame 2016-12-25 21:31:32 +01:00
Lorenz Meier cbd237a58a Integration test: Robustify against 0 home altitude 2016-12-25 21:30:31 +01:00
Lorenz Meier 9b97e0358b MAVLink: Send correct home heading 2016-12-25 21:30:31 +01:00
Lorenz Meier 6444988392 MAVLink app: Send messages on average at a more correct rate and send on first call
This patch fixes two issues:
  * It sends the message on the first call, making sure that the first update gets sent out.
  * It improves the rate scheduling. In an experiment with 0.5, 50 and 250 Hz all rates were correct within 0.3% of the intended rate.
2016-12-25 21:30:31 +01:00
Lorenz Meier d6ef137e59 VTOL att control: Fix status reporting
The transition state reporting was inverted because of a typo. Code analysis suggests this will only have an effect in manual transition.
2016-12-25 18:15:51 +01:00
Lorenz Meier 1141079a3b Fix Simulator: Set correct rotor count for standard VTOL
The rotor count was incorrect which meant that control surfaces like elevons were scaled incorrectly. This was the main reason for really bad SITL performance
2016-12-25 18:15:51 +01:00
Lorenz Meier b7f5a33c90 EKF2: Code style and efficiency
Its sufficient to use sqrtf() with floating point resolution and its better to use the Matrix library call for local and global position yaw
2016-12-25 18:15:51 +01:00
Lorenz Meier 737e18dccb MAVLink app: Fix VTOL reporting and prevent mission reached spam
The VTOL status reporting and the mission status reporting were both suboptimal. VTOL was too slow, mission reporting too fast
2016-12-25 18:15:51 +01:00
Lorenz Meier 171ccd1203 POSIX SITL configs: Update default parameters to improve simulation behaviour
The main changes include:
 * Better attitude tuning for airframes (more realistic models, the models had previously not as much thrust as the real vehicles)
 * Better waypoint and navigation default parameters which match the on-hardware parameters
 * More suitable minimum and trim airspeeds for VTOL and fixed wing which prevents stalls that happened in SITL previously (the new airspeeds match the real vehicles nicely)
2016-12-25 18:15:51 +01:00
Lorenz Meier 0ae85e8a17 VTOL vehicle status: Adjust defines to match VTOL controller enum 2016-12-25 18:15:51 +01:00
Lorenz Meier 8165ef7d95 SITL: Move back to LPE as its more robust to host timing 2016-12-25 18:15:51 +01:00
Lorenz Meier 79fbcf8a1c Tuning to integration testing for better reporting 2016-12-25 18:15:51 +01:00
Lorenz Meier fa84d104b2 Update SITL Gazebo to include model fixes 2016-12-25 18:15:51 +01:00
Lorenz Meier 42101671f4 Drop rate gains for H480 2016-12-24 16:14:52 +01:00
Lorenz Meier 07fecaa9d5 Re-tune the H480 config as we increased its simulated motor power recently. 2016-12-24 16:14:52 +01:00
Lorenz Meier f56bb95bdd Default SITL to the same estimator as the physical vehicle 2016-12-24 16:14:52 +01:00
Lorenz Meier 349e3f6309 Update SITL Gazebo to include baro noise 2016-12-24 16:14:52 +01:00
Lorenz Meier 8418be5fa5 Slowdown message: More descriptive and less often 2016-12-24 16:14:52 +01:00
David Sidrane 5607df8a44 Added missing IFLOWCONTROL_WATERMARK settings.
This was the cause of the CI failure on the hot fix
2016-12-24 09:42:48 +01:00
David Sidrane e15b67ff70 HOTFIX:For Data loss on Nuttx serial w/ DMA & GPIO Flow Control
This hot fix essentialy revert commit 265af481209d60033f7cd4c4216048b1ce3eb435
   in NuttX/nuttx. The commit STM32 serial: Make input hardware flow-control work with RX DMA.
   From Jussi Kivilinna has broken the DMA on an STM32F4 in a yet TBD way.
   The symptoms are lost data on RX, the DMA count decrements but
   the data ia not written to memory. This looks to be introduced but the
   non circular DMA settings.
2016-12-24 09:42:48 +01:00
Lorenz Meier 2bf7a53d55 FMUv5: Ensure enough IRQ stack 2016-12-23 23:24:52 +01:00
Lorenz Meier 88a4b5ba07 FMUv4: Ensure enough IRQ stack 2016-12-23 23:24:52 +01:00
Lorenz Meier 0924d8ddcf FMUv3: Ensure enough IRQ stack 2016-12-23 23:24:52 +01:00
Lorenz Meier b6e4b63b0d FMUv2: Ensure enough IRQ stack 2016-12-23 23:24:52 +01:00
Lorenz Meier bdeabbd02c FMUv1: Ensure enough IRQ stack 2016-12-23 23:24:52 +01:00
Lorenz Meier cbe04d5f9b FMUv5: Not supporting AUX yet 2016-12-23 23:24:52 +01:00
James Goppert c28cd76e5f LPE fault relaxation and sitl fix (#6146)
* Set LPE FUSE for standard iris sitl config.

* Relax fault detection handling.

* Always correct lidar.
2016-12-23 15:08:37 -05:00
Lorenz Meier 661fda2b2a MAVLink app: Acknowledge all commands that are not sent off to other components 2016-12-23 17:40:11 +01:00
Lorenz Meier 5d7d26531c Commander: Acknowledge pair commands 2016-12-23 17:40:11 +01:00
David Sidrane df5b29abce Bugfix:MPU6000 Driver accept unknown ICM20xxx product IDs
This allows a ICM20xxxx with an unkown product ID to be used
   with the mpu6000 driver.

   This change will issues a warning for any part with an unknown product ID.
   For mpu6000 parts (-T 6000 or not specified) it will then exit.
   For any ICM20xxxx part with an unknown product ID it will accept the ID
   and run with it.

   N.B. This fix expecte the value in the product ID register to be
   a per chip constant. (Not changing during operations)
2016-12-23 17:08:30 +01:00
Dennis Mannhart d00750c22e updated ECL submodule to include snapdragon compile fix 2016-12-23 11:34:31 +01:00
Dennis Mannhart ccc909f346 uORBFastRpcChannel: fixed include for snapdragon 2016-12-23 10:43:06 +01:00
Lorenz Meier 9e2eac41ff ROMFS startup: Fix variable expansion for new NuttX scheme 2016-12-23 09:30:37 +01:00
Beat Küng 1e05520350 Tools/upload_log.py: add missing source parameter 2016-12-23 00:20:17 +01:00
David Sidrane 83fdb9761c px4fmu-v4:Fixed SDIO Clocking 2016-12-23 00:05:59 +01:00
David Sidrane abc2ed3c52 px4fmu-v3:Fixed SDIO Clocking 2016-12-23 00:05:59 +01:00
David Sidrane a84eebbee4 px4fmu-v2:Fixed SDIO Clocking 2016-12-23 00:05:59 +01:00
David Sidrane 31355c8584 Mindpx-v2:Fixed SDIO Clocking 2016-12-23 00:05:59 +01:00
David Sidrane feb139eb6a AUAVX21:Fixed SDIO Clocking 2016-12-23 00:05:59 +01:00
Michael Schaeuble b9bd30d4e2 Build hardfault_log in px4fmu-v3 target 2016-12-22 21:58:16 +01:00
Beat Küng fca3a11907 RPI config: set SYS_MC_EST_GROUP 2016-12-22 16:54:15 +01:00
Beat Küng eadb55569b eagle configs: set SYS_MC_EST_GROUP 2016-12-22 16:54:15 +01:00
Beat Küng af99ecfe42 bebop config: set SYS_MC_EST_GROUP to 2 2016-12-22 16:54:15 +01:00
Beat Küng d828023e47 SITL startup config: set SYS_MC_EST_GROUP
so that we know which estimator was used in the log file
2016-12-22 16:54:15 +01:00
Lorenz Meier e6cea82b21 Better default values for UAVCAN params 2016-12-22 15:33:21 +01:00
Beat Küng a3de7f7acc RPI: fix startup scripts: start navigator & load parameters 2016-12-22 15:17:58 +01:00
Simone Guscetti 304afa5629 Changed getopt with px4_getopt which was causing motor_test to always go to the usage function 2016-12-22 11:08:21 +01:00
Lucas De Marchi 03c3ea0040 build: also look for ninja-build in addition to ninja
The ninja binary may have other names on Linux distributions. On Fedora
it's ninja-build.
2016-12-22 08:33:33 +01:00
Lorenz Meier 54ab5cde2f Fix unused variable in LPE 2016-12-21 22:28:42 +01:00
Roman c38e378f59 bebop config: updated some gains for decent performance
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-21 21:36:53 +01:00
Beat Küng 0c7e9b0e6d version CMakeLists.txt: add ver_gen dependency
Necessary so that build_git_version.h is generated before version.c is
compiled.

Error before:
../src/lib/version/version.c:152:31: error: 'PX4_GIT_TAG_STR' undeclared (first use in this function)
  return version_tag_to_number(PX4_GIT_TAG_STR);
2016-12-21 16:59:32 +01:00
Beat Küng cf21d8f554 cmake: remove unneeded file build_git_version.h.in
Obsolete since 9ee478e1f7
2016-12-21 16:59:32 +01:00
Lorenz Meier 479374a047 Update SITL gazebo 2016-12-21 14:18:21 +01:00
James Goppert 1a6c1da855 Update sitl gazebo. 2016-12-21 14:15:29 +01:00
Beat Küng db2efa79da fix commander: remove unused variable rtl_on 2016-12-21 14:09:41 +01:00
Beat Küng ffe4688d0b px4_base.cmake: make sure px_update_git_header.py is executed in the source directory
otherwise the 'git describe' command can fail.
2016-12-21 14:09:41 +01:00
Lucas De Marchi 9ee478e1f7 cmake: fix update of git hashes
Since the git hashes were being generate by cmake it would only be
generated if the header file was not present. Simple test:

    $ make aerofc-v1_default
    $ touch a
    $ git add a
    $ git commit -m tmp
    $ make aerofc-v1_default

The file build_aerofc-v1_default/build_git_version.h should have the new
hashes and the correspondent .c/c.pp files should be rebuilt, but they
aren't.  The end result is that checking the version with "ver git" in
the nsh console will point to the wrong commit.

This moves the generation of the header to a separate tool and enforces
the command to be executed every time.
2016-12-21 14:09:41 +01:00
Julian Oes 8aede5d32b mavlink: add 500000 baudrate 2016-12-21 11:44:47 +01:00
Lorenz Meier 9ae2376d1c Commander: Indicate overload on the ground only if not transient. Adjust max CPU load to 80%. Indicate overload in air immediatley 2016-12-21 11:44:47 +01:00
Lorenz Meier 11ef348a34 PWM: Use same stack size as mixer to limit fragmentation 2016-12-21 11:44:47 +01:00
Lorenz Meier 535d5b9233 Ensure TAP ESC is fully booted 2016-12-21 11:44:47 +01:00
Lorenz Meier 6b9d95648f MAVLink app: Fix flow control handling flags 2016-12-21 11:44:47 +01:00
Lorenz Meier 19a474e376 Enable flow control in OS config for TAP so that ports without support are correctly detected 2016-12-21 11:44:47 +01:00
Beat Küng 7d8553ecd8 uavcan: remove assert() for git name check 2016-12-21 11:35:10 +01:00
Beat Küng 115301d43a cmake configs: add lib/version to remaining configurations 2016-12-21 11:35:10 +01:00
Beat Küng 8d1f35bff6 board cmake: remove board_name.c from all boards
leftover after rebase
2016-12-21 11:35:10 +01:00
Beat Küng 5e9bdff205 version: remove FW_GIT & FW_BUILD_URI, use the correct methods instead
This is cleanup after rebasing
2016-12-21 11:35:10 +01:00
Beat Küng 3d0f1e4a4f logger: use better variable names for chip name description 2016-12-21 11:35:10 +01:00
Beat Küng 66a6ce880c cmake stm32f4discovery: add lib/version 2016-12-21 11:35:10 +01:00
Beat Küng 5ad2595f43 logger: add more version info & uuid
in particular:
- SW release version (in addition to the git hash)
- OS version (tag + git hash if exists)
- mcu version & revision & UUID
- toolchain version

The uuid can be disabled via parameter, it's enabled by default.
2016-12-21 11:35:10 +01:00
Beat Küng 41dc34204c version cleanup: move all version information into version.c and use a common API
The provided versioning information is the same, except for some additions,
like OS version (which still need to be implemented on NuttX).
2016-12-21 11:35:10 +01:00
Beat Küng 08dc3decb1 mavlink: avoid sending uninitialized data
_global_pos_sub->update(&_global_pos_time, &global_pos); could return
false and in that case global_pos was not set but still accessed.

This is prevented by checking if timestamp == 0.
2016-12-21 11:35:10 +01:00
Beat Küng c662113527 board_name.c: remove the file and HW_ARCH macro, use px4_board_name() instead
boards define BOARD_NAME, so board_name() is not necessary. HW_ARCH was
just a wrapper around board_name().

This patch simplifies to having only one common method px4_board_name().
2016-12-21 11:35:10 +01:00
Mark Whitehorn 3d1f240351 exclude config from fmu-v1/v2 builds 2016-12-21 11:00:29 +01:00
Mark Whitehorn c722e2733f update s250aq config for new TPA params 2016-12-21 11:00:29 +01:00
Mark Whitehorn 8962eaa944 add new asymmetric airframe for Spedix S250AQ 2016-12-21 11:00:29 +01:00
James Goppert 6ff85fb927 LPE land bug fix and switch to fusion bit mask. 2016-12-21 08:43:18 +01:00
Beat Küng f263ea7f7e rc.sensors aerofc: change external mag orientation to 'Yaw 180 deg' 2016-12-21 08:42:04 +01:00
Matthias Grob eda7848e16 mc_pos_control small refactoring while studying 2016-12-21 08:40:16 +01:00
Lorenz Meier 3f545c270d Removed unused code 2016-12-21 08:37:45 +01:00
Lorenz Meier 8a32e5a20d Mixers: Disable on unreachable boards 2016-12-21 08:37:45 +01:00
Lorenz Meier bf7bdd4062 Crazyflie: Disable on Pixhawk boards 2016-12-21 08:37:45 +01:00
Lorenz Meier 9fd742d131 ZMR250: Disable on Pixhawk 2016-12-21 08:37:45 +01:00
Lorenz Meier f795fb0535 Disable Aero on non-Aero boards 2016-12-21 08:37:45 +01:00
Lorenz Meier 3faa836a24 Disable Solo on Pixhawk 2016-12-21 08:37:45 +01:00
Lorenz Meier f9a4d3b731 Disable Bebop on Pixhawk 2016-12-21 08:37:45 +01:00
Lorenz Meier 5d530da9c2 Disable QAVR5 on Pixhawk 2016-12-21 08:37:45 +01:00
Lorenz Meier f601dc672e Disable Snapdragon PWM on Pixhawk 2016-12-21 08:37:45 +01:00
Lorenz Meier 417eda82ef ROMFS pruner: Kick out excluded files 2016-12-21 08:37:45 +01:00
Lorenz Meier becd9457ca Call airframes script with board arg 2016-12-21 08:37:45 +01:00
Lorenz Meier 671e380fd2 Params script: Whitespace cleaning 2016-12-21 08:37:45 +01:00
Lorenz Meier f23881d8ab Airframes tool: Support basic pruning 2016-12-21 08:37:45 +01:00
David Sidrane f67e44215f Fixes TAP-V1 CI Failure:
Reverted MPU6000_BUS_I2C_INTERNAL1 back to MPU6000_BUS_I2C_INTERNAL
  Ony SPI has multiple device
2016-12-21 08:34:22 +01:00
David Sidrane e5b10e808b Pickup 2 Upstream NuttX PX4 contributions
1) Ensure if CONFIG_SERIAL_DMA is set that cdcacm uart_ops is initalized
     with correct functions in correct slots.
     This was detected only with PX4 build flags
  2) C&P error from F7 would prevent CONFIG_STM32_SERIALBRK_BSDCOMPAT ifdefed
     code from being included.
2016-12-21 08:34:22 +01:00
Lorenz Meier 5ce9a35e95 Update rotation for FMUv5 ICM sensors 2016-12-21 08:34:22 +01:00
David Sidrane b250ec2730 Adding more Prudut IDs for ICM20689 2016-12-21 08:34:22 +01:00
Lorenz Meier f9ed66fe8b Board config for FMUv5: I2C bus naming consistency 2016-12-21 08:34:22 +01:00
Lorenz Meier c220956961 MPU6K driver: More device names 2016-12-21 08:34:22 +01:00
Lorenz Meier 83e833c997 FMUv5 defconfig: Better defaults 2016-12-21 08:34:22 +01:00
Lorenz Meier a7d31133ac Sensors startup: Whitespace fix 2016-12-21 08:34:22 +01:00
Lorenz Meier 27201ba2a1 MPU6K: Support different device names 2016-12-21 08:34:22 +01:00
Lorenz Meier 3caff7cdca HMC5883: Support additional I2C buses 2016-12-21 08:34:22 +01:00
Lorenz Meier ace1f91355 I2C4: Fix GPIO setup 2016-12-21 08:34:22 +01:00
Lorenz Meier 3bbf5da85a FMUv5: Set default GPS port 2016-12-21 08:34:22 +01:00
Lorenz Meier fcc85f79d5 MPU6K: Make stop routine safe to call from any location in the startup code 2016-12-21 08:34:22 +01:00
David Sidrane 489ee58773 px4fmu-v5 starts ICM 20602 and ICM 20689 2016-12-21 08:34:22 +01:00
David Sidrane 749fd2f155 Added ICM 20689 2016-12-21 08:34:22 +01:00
David Sidrane 6ebd24a678 Added ICM20602 2016-12-21 08:34:22 +01:00
David Sidrane 05701a2830 Reorged px4fmu-v5 code up 32K now that bootloader is completed. 2016-12-21 08:34:22 +01:00
David Sidrane 120064b55d WIP:Startup for FMUV5
Incomplete changes to startup script for FMUv5.
   See "Place holder Need" in ROMFS/px4fmu_common/init.d/rc.sensors
2016-12-21 08:34:22 +01:00
David Sidrane 93996a6d6e TAP uses BOARD_HAS_SHARED_PWM_TIMERS
Fixes https://github.com/PX4/Firmware/issues/5710
2016-12-21 08:34:22 +01:00
David Sidrane 0baab8263b Fix the LED PWM support for non shared timers
This is the fixes https://github.com/PX4/Firmware/issues/5710
  by adding 2 concepts.

  1) Allowing a board to define BOARD_HAS_SHARED_PWM_TIMERS
     in this case the io_timeris will be initalized as the
     led_pwm_timers  - there is an assumptionm that the
     number of io_timers == the number of led_pwm timers

  2) Allowing a board to define BOARD_LED_PWM_RATE
     To set an alternate frequency

  Future expansion will require:
  1) The ability to have a config with both the I2C RGB LED and
     PWM RGB LED drivers loaded.
  2) The higher level driver to create  multiple instances of the
     /dev/rgbld, to support internal and  external User facing
     RGB LED as supported in FMUv5
2016-12-21 08:34:22 +01:00
David Sidrane 4712ed1889 Complete px4fmu-v5 Led configuration 2016-12-21 08:34:22 +01:00
David Sidrane 3f64bf81f3 RGB LED cleanup
Removed dead code and magic numbers
  Defined the RGB LED to support 2 timers
2016-12-21 08:34:22 +01:00
David Sidrane a81aceea58 Add SD_CARD_POWER_CTRL as logical interface for SD Power Control
Set inital State to ON
   Add interface macro.
2016-12-21 08:34:22 +01:00
Lorenz Meier a777cad102 ROMFS: output cosmetics on startup script 2016-12-21 08:34:22 +01:00
David Sidrane 5f82fc70be CI Fixes 2016-12-21 08:34:22 +01:00
David Sidrane 116704ef50 Makefile add all Targets 2016-12-21 08:34:22 +01:00
David Sidrane 2957b8d7d4 Adding Carlo Woods's config cloning tool 2016-12-21 08:34:22 +01:00
David Sidrane b7521e1b38 Adding Test for sending break on u[s]arts 2016-12-21 08:34:22 +01:00
David Sidrane cc0a4248f8 PX4 System changes for new Boards 2016-12-21 08:34:22 +01:00
David Sidrane f5a0c04ae8 Upstream NuttX irq{save|restor} -> {enter/leave}_critical_section 2016-12-21 08:34:22 +01:00
David Sidrane 3eee469fbc Display the irq stack usage on the for the init thread (pid = 0) 2016-12-21 08:34:22 +01:00
David Sidrane 1781801151 Scope irq_state to function using it 2016-12-21 08:34:22 +01:00
David Sidrane 056bd5527d New NuttX debug API 2016-12-21 08:34:21 +01:00
David Sidrane 5661370944 Changed to Upstream NuttX Instrumentation changes 2016-12-21 08:34:21 +01:00
David Sidrane b7d7b567c0 Changes to px4iofirmware for Upstrem Nuttx c++ init and logging changes 2016-12-21 08:34:21 +01:00
David Sidrane ff0e810b55 Nuttx changed CONFIG_DRAM_SIZE to CONFIG_RAM_SIZE 2016-12-21 08:34:21 +01:00
David Sidrane b6362ed87c Needed math.h 2016-12-21 08:34:21 +01:00
David Sidrane 3ed0bfe0d8 Nuttx added FIONSPACE and fixed FIONWRITE: had retuned the space and should have returned enqueued count 2016-12-21 08:34:21 +01:00
David Sidrane 81d00e730a Portable fsync call 2016-12-21 08:34:21 +01:00
David Sidrane dc8c6ea5e5 White space fixes 2016-12-21 08:34:21 +01:00
David Sidrane dd2fe5d42f Document and fix '${varname}' usage 2016-12-21 08:34:21 +01:00
David Sidrane dec46927f7 RAND_MAX properly defined in upstream NuttX 2016-12-21 08:34:21 +01:00
David Sidrane c9f10107c0 Nuttx Upgrade:Adds sem_setprotocol 2016-12-21 08:34:21 +01:00
David Sidrane 8610eced57 Changes to sim for upstream Nuttx 2016-12-21 08:34:21 +01:00
David Sidrane b7cc04e0d2 Changes to tap_v1 for upstream Nuttx and hardfault logging 2016-12-21 08:34:21 +01:00
David Sidrane 402251819d Changes to mindpx-v2 for upstream Nuttx and hardfault logging 2016-12-21 08:34:21 +01:00
David Sidrane f149adac54 Changes to px4-stm32f4discovery for upstream Nuttx 2016-12-21 08:34:21 +01:00
David Sidrane feda3e8c5c Changes to px4io-v2 for upstream Nuttx 2016-12-21 08:34:21 +01:00
David Sidrane 63f04c1236 Changes to px4io-v1 for upstream Nuttx 2016-12-21 08:34:21 +01:00
David Sidrane 17633c0714 Changes to px4fmu-v4 for upstream Nuttx and hardfault logging 2016-12-21 08:34:21 +01:00
David Sidrane c89c47e57e Changes to px4fmu-v3 for upstream Nuttx 2016-12-21 08:34:21 +01:00
David Sidrane d9575964a4 Changes to px4fmu-v2 for upstream Nuttx and hardfault logging 2016-12-21 08:34:21 +01:00
David Sidrane 82cb9353d1 Changes to px4fmu-v1 for upstream Nuttx 2016-12-21 08:34:21 +01:00
David Sidrane 64c00e6c95 Changes to crazyflie for upstream Nuttx and hardfault logging 2016-12-21 08:34:21 +01:00
David Sidrane 3ddeb07b25 Changes to auav-x21 for upstream Nuttx and hardfault logging 2016-12-21 08:34:21 +01:00
David Sidrane a2adf94d13 Changes to aerofc-v1 for upstream Nuttx and hardfault logging 2016-12-21 08:34:21 +01:00
David Sidrane 2e235b9013 Changes to aerocore for upstream Nuttx 2016-12-21 08:34:21 +01:00
David Sidrane 1b17bc74b2 Adding zubaxgnss-v1 bootloader 2016-12-21 08:34:21 +01:00
David Sidrane 276bf47865 Adding s2740vc-v1 board and bootloader 2016-12-21 08:34:21 +01:00
David Sidrane 6ce7ade2c6 Adding px4nucleoF767ZI-v1 2016-12-21 08:34:21 +01:00
David Sidrane bca8767981 Adding px4fmu-v5 2016-12-21 08:34:21 +01:00
David Sidrane 925102464b Adding px4fmu-v4pro 2016-12-21 08:34:21 +01:00
David Sidrane f14a0ba107 Adding px4flow-v2 bootloader 2016-12-21 08:34:21 +01:00
David Sidrane 24e8c213ee Adding px4esc-v1 board and bootloader 2016-12-21 08:34:21 +01:00
David Sidrane bba8371b0f Adding px4cannode-v1 board and bootloader 2016-12-21 08:34:21 +01:00
David Sidrane cd8b759fed Adding esc35-v1 board and bootloader 2016-12-21 08:34:21 +01:00
David Sidrane d09cd77777 Adding hardfault logging application 2016-12-21 08:34:20 +01:00
David Sidrane 57ac4dd401 Adding example of developer custom make file 2016-12-21 08:34:20 +01:00
David Sidrane c417a1be7b Adding USVCAN bootloader support 2016-12-21 08:34:20 +01:00
David Sidrane ced8c6a2ef Changes to boards/common for upstream NuttX directory changes 2016-12-21 08:34:20 +01:00
David Sidrane 2f0a0e1c30 Added nuttx/arch API 2016-12-21 08:34:20 +01:00
David Sidrane ddb033aa12 Temp fix - Needs to move to micro hal 2016-12-21 08:34:20 +01:00
David Sidrane dcc2d1c3d1 I2C changes for upstream NuttX per trasaction freq control 2016-12-21 08:34:20 +01:00
David Sidrane 0177e250f4 STM32 Serial Number location is defined in NuttX 2016-12-21 08:34:20 +01:00
David Sidrane fd7d399958 Upstream Nuttx restructured directories use micro_hal 2016-12-21 08:34:20 +01:00
David Sidrane d8580d39b9 Honor Micro hal and new Nuttx Loging API 2016-12-21 08:34:20 +01:00
David Sidrane ddb9bc3242 Honor micro hal 2016-12-21 08:34:20 +01:00
David Sidrane 9db89ea4cf Added Micro Hal and configue for Upstream NuttX 2016-12-21 08:34:20 +01:00
David Sidrane 318c69c74b Honor GIT_SUBMODULES_ARE_EVIL 2016-12-21 08:34:20 +01:00
David Sidrane 16229b3985 Build time patching of Uptream NuttX 2016-12-21 08:34:20 +01:00
David Sidrane d6098c8226 Adding Nuttx Build infrastructure 2016-12-21 08:34:20 +01:00
David Sidrane cb9517486d Upgrade to uavcan to support Nuttx 7.18+ {enter/leave}_critical_section 2016-12-21 08:34:20 +01:00
David Sidrane 07923a86c7 Upgrade to Nuttx 7.18+ ==upstream 2016-12-21 08:34:20 +01:00
Lorenz Meier 1e625d024c Updated ECL to include a minor compile fix 2016-12-21 08:11:05 +01:00
Dennis Mannhart 42093a5ee1 remove PX4_WARN if zero bytes are received 2016-12-20 14:38:28 +01:00
Dennis Mannhart bf6328001d move sleep to then end of the loop 2016-12-20 14:38:28 +01:00
Dennis Mannhart 833ee4ba7f deleted poll function since not supported in qurt 2016-12-20 14:38:28 +01:00
Julian Oes d62520e26b Update DriverFramework and build lib/rc 2016-12-20 14:38:28 +01:00
Julian Oes d8b6a1df9f Revert "spektrum_rc: fix ugly pointers in function args"
This reverts commit ef3bc1431215dca15383b293101fe75fc27492f2.
2016-12-20 14:38:28 +01:00
Julian Oes 402e2ec611 spektrum_rc: fix ugly pointers in function args 2016-12-20 14:38:28 +01:00
Julian Oes 45ff2d026d dsm: only close valid fds 2016-12-20 14:38:28 +01:00
Julian Oes 3b937ffab4 Remove save file created by mistake 2016-12-20 14:38:28 +01:00
Julian Oes f184e642c9 dsm: fix definition 2016-12-20 14:38:28 +01:00
Julian Oes fb42db41d2 spektrum_rc: raise poll timeout to 50ms/20Hz 2016-12-20 14:38:28 +01:00
Julian Oes a57c8d2a7c spektrum_rc: make usage clear 2016-12-20 14:38:28 +01:00
Julian Oes de9cb46a56 spektrum_rc: move and clean up (untested) 2016-12-20 14:38:28 +01:00
Julian Oes 97fe56a4e7 dsm: add deinit function
This implements closing of the serial port which previously was not
taken care of.
2016-12-20 14:38:28 +01:00
Julian Oes c0fcffae76 spektrum_rc: make it compile 2016-12-20 14:38:28 +01:00
Lorenz Meier c14f1fbaec Add initial structure for Snapdragon Spektrum input 2016-12-20 14:38:28 +01:00
David Sidrane 4d17467590 Interim fix avoid using params before initialized
This is a Interim fix to avoid using params before initialized.

The Long term fix will be:
1) Not play the startup tone on start but allow tones to be generated from other invocations (i.e error conditions)
2) Add a command to tone alam to have it read a parameter, after parameter initialization, in the init script. If that parameter is on then sound the startup tone and further tones will be enabled. If it is off all further tones will be disabled.

The new parameter will not be of the class circuit breaker (not named ) as is is not an absolute control of the tone alarm.
2016-12-20 14:16:04 +01:00
Matthias Grob f9da41fcf2 fixed rebase errors in arm switch implementation 2016-12-20 09:46:36 +01:00
Matthias Grob 0dbdde3404 Arming: made flags more understandable, added error message for rejected disarm 2016-12-20 09:46:36 +01:00
Matthias Grob f6282f5b3d Arm button fix: include the arm switch into the structure of all the checks for RC arming 2016-12-20 09:46:36 +01:00
Matthias Grob 94c8371ffe Arm button fix: toggle arming state only once per arm button press 2016-12-20 09:46:36 +01:00
Matthias Grob 8a75827d6a fixed all comments of arm button review 2016-12-20 09:46:36 +01:00
Matthias Grob aa984edd90 added an rc switch for arming and disarming with the option to use it as a button 2016-12-20 09:46:36 +01:00
Matthias Grob 537f72073d minor: uppercase typo and unused header 2016-12-20 09:46:36 +01:00
Lucas De Marchi 292599d3c9 Revert "px4fmu rcS: increase mavlink rate to 100000 for SYS_COMPANION 1500000"
This reverts commit e3537ca6c2.

It needs changes on the Linux side, so reverting for now.
2016-12-20 08:56:38 +01:00
Lucas De Marchi f48605b975 Revert "aerofc: use logger when autoconfig"
This reverts commit e4e5a77f71.
2016-12-20 08:56:38 +01:00
Lucas De Marchi 03be988ebe aerofc: fix defining PX4FMU_V4 macro
We were defining both macros. Fix it by using changing to AEROFC_V1.
Also remove a leftover from board rename.
2016-12-20 08:51:14 +01:00
Lucas De Marchi 9468e7779a aerofc: use same macro name as px4fmu boards 2016-12-20 08:51:14 +01:00
Lucas De Marchi eaa2cf7d99 aerofc: fix LED names
There are no blue/red LEDs and these names just causes confusion with
the "always-on LEDs".
2016-12-20 08:51:14 +01:00
Lorenz Meier 3e8061c3cd Iris mixer: Update naming of mixer 2016-12-19 20:39:48 +01:00
Lorenz Meier 83b177c5ad DC mixer: Fix geometry for Iris 2016-12-19 20:39:48 +01:00
Lorenz Meier 6b0ac296b6 Fix usage of Iris mixer, make space by deleting unused files 2016-12-19 20:39:48 +01:00
Lorenz Meier 92c35f26be Tests: Correct use of unsubscribe 2016-12-19 20:39:03 +01:00
Lorenz Meier 313ff2a6f2 UAVCAN: Correct use of unsubscribe 2016-12-19 20:39:03 +01:00
Lorenz Meier 1d98c8f202 MAVLink app: Correct use of unsubscribe 2016-12-19 20:39:03 +01:00
Lorenz Meier 3532b48411 TAP ESC: Correct use of unsubscribe 2016-12-19 20:39:03 +01:00
Lorenz Meier 97ce9edcac FMU: Tighter compile checks and correct use of unsubscribe 2016-12-19 20:39:03 +01:00
Lorenz Meier 4b99a8f28c Fix sf1xx start 2016-12-19 20:37:40 +01:00
Lorenz Meier dfed9a3f13 Fix nullptr access in mixer group. This was only ever an issue on booboot and not in flight. 2016-12-19 20:36:05 +01:00
Lorenz Meier 6e32d0b52b Update ECL to include data validator fixes 2016-12-19 20:34:52 +01:00
Lorenz Meier c91f827072 sensors app: Always run validator so it gets updated and can detect timeouts 2016-12-19 20:34:52 +01:00
Lorenz Meier 143086ba2c HMC5883: Harden shutdown logic 2016-12-19 20:34:52 +01:00
Lorenz Meier 5759fd5726 GPS app: Increase stack to ensure 300 bytes headroom 2016-12-19 20:34:52 +01:00
Lorenz Meier fe5cc5622b Failover logging in sensors app: Trim down strings 2016-12-19 20:34:52 +01:00
Lorenz Meier b91b0463d2 Update ECL lib to include failover fix for one sensor case 2016-12-19 20:34:52 +01:00
Lorenz Meier cc7db94edc Sensors app mag voter: Increase stale value detection threshold to accomodate low-noise mag setups 2016-12-19 20:34:52 +01:00
Lorenz Meier 077f22ece7 HMC5883: Make driver stoppable to simplify system validation 2016-12-19 20:34:52 +01:00
Lorenz Meier 0e93b75ced Update ECL library to include configurable stale sample counts 2016-12-19 20:34:52 +01:00
Lorenz Meier 8297e979ff ECL: Update to include whitespace fixes 2016-12-19 20:34:52 +01:00
Lorenz Meier c62c3c98bf uORB devices: Guard more against invalid handles fed to publish routine 2016-12-19 20:34:52 +01:00
Lorenz Meier ca59d4cddb Simulator: Initialize ground truth topic handle 2016-12-19 20:34:52 +01:00
Lorenz Meier df613361b9 LPE: Increase stack to allow enough safe margin 2016-12-19 20:34:52 +01:00
Lorenz Meier 9667c98b61 Start UAVCAN in the two phases required 2016-12-19 15:13:05 +01:00
Dennis Mannhart e2ded396c8 Snapdragon pwm (#5940)
* px4 pwm driver for snapdragon

* added driver to cmake file

* applied review changes and adjusted format

* adjustement to review 2

* run formatting

* added timeout initialization
2016-12-16 18:41:45 +01:00
Mark Whitehorn 48778ed3f2 bump parameter minor version 2016-12-16 18:12:17 +01:00
Mark Whitehorn bad2dc80a4 change default THR_MDL_FAC to zero (disabled) 2016-12-16 18:12:17 +01:00
Mark Whitehorn e5f4f50a52 add param_find for THR_MDL_FAC 2016-12-16 18:12:17 +01:00
Roman d0d9ee373b bebop config: increase logger buffer from 20kB to 200kB
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-16 00:15:25 +01:00
Roman 5b0a1d4b2a updated DriverFramework: activated dlpf in mpu6050
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-16 00:15:25 +01:00
Roman daa88f69db bebop2 config: updated some positon control params for decent performance
- this is not the final tune!!!

Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-16 00:15:25 +01:00
Roman b0bca24526 bebop2 config: use logger instead of sdlog2
- sdlog2 drops lots of data and logs very, very irregularly

Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-16 00:15:25 +01:00
Mark Whitehorn 381a565ce3 add THR_MDL_FAC parameter handling to FMU 2016-12-15 23:39:53 +01:00
Roman d221313dfb implemented mapping between desired thrust and applied pwm in
multirotor mixer.

Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-15 23:39:53 +01:00
Dennis Mannhart 22733b1501 mc_pos_control: dont run alt-control when landing 2016-12-15 10:17:03 +01:00
Julian Oes ef7ade52b1 mc_pos_control: stay landing even after freefall
This fixes the following case:
1. VTOL in auto mission descends to land
2. _in_landing is set to true correctly
3. _lnd_reached_ground is set to true because it's detected, motors idle.
4. The vehicle might drop for a few centimeters and _acc_z_lp goes back
   up above 4m/s^2, so freefall is detected.
5. The motors spin up again, and _in_landing and _lnd_reached_ground are
   both reset to false.
6. Since we're floating at a few centimeters, we can't actyally get to
   _vel_z_lp > 0.5, and therefore _in_landing is never triggered after.
7. Thus we never finish the landing.

This is fixed by only resetting _lnd_reached_ground to false but
leaving _in_landing true.
2016-12-15 10:17:03 +01:00
Julian Oes 70fec788d9 mc_pos_control: allow takeoff in offboard mode 2016-12-15 10:17:03 +01:00
Julian Oes 072ba51064 mc_pos_control_main: changes got lost in rebase 2016-12-15 10:17:03 +01:00
Julian Oes b285827f52 mc_pos_control: remove leftover printf 2016-12-15 10:17:03 +01:00
Julian Oes 65b8bcae12 mc_pos_control: always require takeoff setpoint
Problem: The drone started taking off in LOITER (HOLD) mode even if on
ground and did not do a proper takeoff jump. The effect was mostly a
hovering close above ground or tilting/flipping because of integrator
wind-up.

Solution: Stay at minimum throttle until a takeoff setpoint is issued.
2016-12-15 10:17:03 +01:00
Julian Oes c64b8c7095 mc_pos_control: always use fabsf and not fabs 2016-12-15 10:17:03 +01:00
Julian Oes e01eaf172a Add body/NED frame for offboard velocity control
This adds the possibility to use offboard velocity control in the body
frame and not just the NED (world) frame.

The frame is set in the set_position_target_local_ned message and passed
on to mc_pos_control in the position_setpoint topic.
2016-12-15 10:17:03 +01:00
Julian Oes e3aecc0762 state_machine_helper: remove unused const var 2016-12-15 10:17:03 +01:00
Julian Oes 5b132aef70 mc_pos_control: hold position at offboard vel 0
If velocity offboard control is used, it makes sense to lock/hold
position if the velocity input is 0. If this is not done, we will slowly
drift because nothing is integrating to keep the UAV at its position.
2016-12-15 10:17:03 +01:00
Julian Oes 0b02a6e0f7 state_machine_helper: warn about offboard lost, not RC
When offboard input stops and we're in OFFBOARD mode, we should complain
about offboard being lost and not RC because we probably never even had RC.
2016-12-15 10:17:03 +01:00
Julian Oes 454cd33a5e mc_pos_control: move stuff where it belongs 2016-12-15 10:17:03 +01:00
Julian Oes 0b37272d75 mc_pos_control: further reshuffling
Should not have any functional change
2016-12-15 10:17:03 +01:00
Julian Oes 61fff54cbe mc_pos_control: copy triplet in one place only 2016-12-15 10:17:03 +01:00
Julian Oes 432824d603 mc_pos_control: move attitude setpoint to function
Again, no functional change, just refactor.
2016-12-15 10:17:03 +01:00
Julian Oes c200e581c3 mc_pos_control: move control into functions
This is only a refactor with no functional change
2016-12-15 10:17:03 +01:00
Julian Oes 3ac056924c navigator: increase stack
The stack size was generally ok but seemed to get exhausted in the case
of a waypoint which is too far away and therefore exercises some more
code in the mission feasability checker.

Generally, we should have more margin in the navigator stack size
because there are a bunch of different code paths that can happen.
2016-12-15 09:05:02 +01:00
Julian Oes a096b97455 Revert "navigator: increase stack"
This reverts commit 6a6e9d02a3.
2016-12-15 09:05:02 +01:00
Mark Whitehorn 08d36fe2af move initial pwm trim update to pwm_ioctl load case 2016-12-15 00:13:59 +01:00
Julian Oes 6a6e9d02a3 navigator: increase stack
The stack size was generally ok but seemed to get exhausted in the case
of a waypoint which is too far away and therefore exercises some more
code in the mission feasability checker.

Generally, we should have more margin in the navigator stack size
because there are a bunch of different code paths that can happen.
2016-12-15 00:12:54 +01:00
Julian Oes 8a6af658f3 navigator: don't omit printf value
There was a mismatch between the printf arguments and what was defined
in the fmt.
2016-12-15 00:12:54 +01:00
Roman 3392e3f9f7 bebop2 upload script: create microsd filesystem so that logger does not
complain

Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-15 00:11:13 +01:00
Roman 34d253e4d0 bebop2: let PX4_ROOTFSDIR point to the internal mmc card
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-15 00:11:13 +01:00
Roman 5ce24e82f5 bebop2 apps: start other important apps, use ekf2 as estimator
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-15 00:11:13 +01:00
Julian Oes 18dd6923e6 integrationtests: use Python2 for dependencies
This changes the shebang of the integration test files to python2
because the scripts fail on systems with Python 3 as the default.

Even though ROS has been ported to Python 3, there are still some
dependencies not playing along.

The error that comes up when starting with Python 3 is:
> No module named 'mavexpression'
2016-12-15 00:10:57 +01:00
Julian Oes 1c2194c600 gps: fix cli parsing
The gps driver did not give feedback if a non-existing verb was used
such as `gps foo`. Also, the goto out was ugly and the usage always
marked as an error when it's really an info. This cleans it up a bit.
2016-12-15 00:10:27 +01:00
Julian Oes 12c5ed39ae gps: fix faking so that ekf2 initializes
This changes the faked GPS values in order to get ekf2 to initialize.
2016-12-15 00:10:27 +01:00
Michael Schaeuble ed2d28d5dc Use time-stamped integrator in Posix MPU6050 driver 2016-12-15 00:09:07 +01:00
Julian Oes f6c573e882 mavlink: don't send uninitialized bytes
Valgrind did not approve uninitialized bytes from either home or
vehicle global position to be sent.
2016-12-14 22:08:26 +01:00
Beat Küng 66925bc065 voted_senors_update: fix style after rebase 2016-12-14 19:57:54 +01:00
Beat Küng d4da626e78 sensors: move sensors with voting into a separate class 2016-12-14 19:57:54 +01:00
Beat Küng f9b3b5a799 sensors: break off parameters initialization into separate source file 2016-12-14 19:57:54 +01:00
Beat Küng c5e485bdd7 sensors: break off RC handling into its own class 2016-12-14 19:57:54 +01:00
Beat Küng 4e2d0500a1 sensors: use orb_publish_auto where possible 2016-12-14 19:57:54 +01:00
Lorenz Meier 4b0647d9c0 Condition the GPS check always on the commander GPS prearm check param (#6055) 2016-12-14 15:30:24 +01:00
Daniel Agar 17990cf5dc geofence fix combined simple and polygon logic
- require being inside both fences, not either
2016-12-14 08:49:13 +01:00
Daniel Agar bce7ecb0f6 Iridium driver and support
Mavlink module implement HIGH_LATENCY (Iridium)
2016-12-14 08:20:01 +01:00
Lorenz Meier 77e482a30e Rover: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier e74094db5a ZMR: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier 1bf45610fe 250: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier 91b39d14c3 Reaper: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier 45549890ad Micro PCB: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier 679803ab1a Caipi: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier 83f5ed5d42 Albatross: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier 3d771d6c8a Maja: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier 85e388839f AERT: Refresh airframe config 2016-12-13 16:14:15 +01:00
Lorenz Meier fbce24bb65 Heli: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier f9d1cd6f1f Coax: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier 38a431b267 TBS endurance: Refresh config 2016-12-13 16:14:15 +01:00
Lorenz Meier b2d48f65bf MC att ctrl: Properly initialize members 2016-12-13 16:14:15 +01:00
Lorenz Meier c9b7b6bbb5 TAP ESC: Secure being the first publisher of all outputs / reports 2016-12-13 16:14:15 +01:00
Lorenz Meier ac3aa3e85c FMU driver: Avoid trashing existing publicacations for RC, motor outputs, etc. 2016-12-13 16:14:15 +01:00
Lorenz Meier c23378e70d Update heli mixer, not reporting saturation yet 2016-12-13 16:14:15 +01:00
Paul Riseborough da6d4398e9 px4fmu: publish mixer saturation data to uORB 2016-12-13 16:14:15 +01:00
Paul Riseborough ca6f67fd3b tap_esc: publish mixer saturation status to uORB 2016-12-13 16:14:15 +01:00
Lorenz Meier 27d5ecaaa9 Fix multirotor code style 2016-12-13 16:14:15 +01:00
Paul Riseborough 8b55c8ec55 systemlib mixer: Add public method for multi_rotor saturation status 2016-12-13 16:14:15 +01:00
Paul Riseborough eb67686b11 mc_att_control: Improve integrator wind-up protection
Use reporting from the motor mixer to only restrict integrator growth when it will result in increased saturation of the control axis concerned.
Enable absolute integrator limits to be set by parameter
2016-12-13 16:14:15 +01:00
Paul Riseborough efb7131186 px4io: improve multi-rotor motor saturation status reporting 2016-12-13 16:14:15 +01:00
Paul Riseborough 57a6faf8a2 px4iofirmware: remove unused defines 2016-12-13 16:14:15 +01:00
Paul Riseborough c4ccfeae0d mixer: improve multirotor motor limits reporting 2016-12-13 16:14:15 +01:00
Paul Riseborough 3835e8cd79 msg: improve multirotor_motor_limits reporting 2016-12-13 16:14:15 +01:00
Andreas Antener 1f72068de3 Integrationtests: updated script to properly handle log uploads 2016-12-13 10:20:14 +01:00
Andreas Antener 14f75bc8a3 SITL CI: Remove log upload from test script and move into separate one 2016-12-13 10:20:14 +01:00
Andreas Antener be2451cfc7 SITL: use logger for standard_vtol and upload *.ulg files after integrationtests 2016-12-13 10:20:14 +01:00
Andreas Antener 3ff0609f26 Integrationtests: upload test logs to flight review 2016-12-13 10:20:14 +01:00
Andreas Antener 30445ebd68 log upload: ignore error if we cannot get git email, really be quiet with -q except for printing the URL in the end 2016-12-13 10:20:14 +01:00
Lorenz Meier cc92339602 pwm command: Fix off-by-one in param parsing 2016-12-13 09:18:59 +01:00
Lorenz Meier f60bde9edd Protect variables correctly during expansion 2016-12-13 09:18:59 +01:00
Lorenz Meier 73689e65ee Update VTOL setup for PWM outputs 2016-12-13 09:18:59 +01:00
Lorenz Meier 7d0db35e90 Update PWM params to match standard usage in system 2016-12-13 09:18:59 +01:00
Lorenz Meier c1d7a3d2ff rcS: Default PWM settings to params 2016-12-13 09:18:59 +01:00
Lorenz Meier 3bb9dbba98 Better param PWM defaults for multicopter 2016-12-13 09:18:59 +01:00
Lorenz Meier fce8e3eb23 Better param PWM defaults for fixed wing 2016-12-13 09:18:59 +01:00
Lorenz Meier e0d770983c FW: Handle PWM params in startup 2016-12-13 09:18:59 +01:00
Lorenz Meier 421b4fb6fb MC: Handle PWM params in startup 2016-12-13 09:18:59 +01:00
Roman 8e8336a83f gps drivers submodule: updated after removing unnecessary baud rate 2016-12-12 23:48:15 +01:00
Roman 0acdf32ed5 gps driver: removed unnecessary baud rate
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-12 23:48:15 +01:00
Roman e6cbbac120 gps devices: update submodule 2016-12-12 23:48:15 +01:00
Roman 88f771fc1e bebop2 startup config: start gps driver
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-12 23:48:15 +01:00
Roman d10c4dd824 gps driver: added more baud rates in order to support bebop2
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-12 23:48:15 +01:00
Roman 4fab448000 build gps driver for bebop2
Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-12 23:48:15 +01:00
Lorenz Meier 1926c7bca7 Revert "Implement the way to run posix simulator directly from IDE without the need to reconfigure command lines, but use runner created via CMake"
This reverts commit fff4934743.
2016-12-12 22:32:34 +01:00
Lorenz Meier 4cb9903561 UAVCAN: Be less verbose on boot 2016-12-12 16:11:21 +01:00
Lorenz Meier 4c714f0e46 Load mon: Be less verbose on boot 2016-12-12 16:11:21 +01:00
Lorenz Meier 0d174be0a0 IO: Remove unnecessary boot output 2016-12-12 16:11:21 +01:00
Lorenz Meier 6820eb7a0c MS5611: Less chatty boot 2016-12-12 16:11:21 +01:00
Lorenz Meier dd6d1136b3 LIS3MLD: Remove unnecessary boot output left over from driver bringup 2016-12-12 16:11:21 +01:00
Lorenz Meier 2b518278df HMC5883: Silence chatty boot 2016-12-12 16:11:21 +01:00
Matthias Grob d1a2f52246 fix segmentation fault when running local_position_estimator module without arguments
argv[1] was read even if argc < 2 -> segmentation fault when running without arguments
the return saves this
2016-12-12 15:25:05 +01:00
Daniel Agar c98927121d crazyflie_default upload for QGC (#6030) 2016-12-11 13:59:35 -05:00
Andreas Antener 17f49ec8cb Integration tests: use separate commands to set mode and arm 2016-12-11 17:00:09 +01:00
Julian Oes adc9ed61b8 commander: ignore arm/disarm in DO_SET_MODE cmd
According to https://github.com/mavlink/mavlink/pull/629 the mavlink
command DO_SET_MODE should only determine the mode but not the
armed/disarmed state, so the MAV_MODE_FLAG_SAFETY_ARMED bit should be
ignored.
Instead the mavlink command COMPONENT_ARM_DISARM should be used instead.

Therefore, the commander now ignores the arm/disarm bit.
2016-12-11 17:00:09 +01:00
Dennis Shtatnov f23b5e4699 Syslink bootloader faker 2016-12-11 09:52:24 +01:00
Dennis Shtatnov 1ab6635ffe ACKs for syslink radio parameters. Fixes #6005 2016-12-11 09:52:24 +01:00
Lorenz Meier d817d331fd Add set trim API for helicopter mixer 2016-12-10 14:45:49 +01:00
Bart Slinger a7c8d77453 Generic helicopter mixer
fix code style
2016-12-10 14:45:49 +01:00
Mark Whitehorn d8d9ab1bfb switch fmu-v2 config back to old logger: config now identical to master 2016-12-10 12:56:39 +01:00
Mark Whitehorn 88126e560f remove trim command: replaced by trim parameters 2016-12-10 12:56:39 +01:00
Mark Whitehorn fc906a79b0 delete commented code 2016-12-10 12:56:39 +01:00
Mark Whitehorn 086043a237 remove unused variable 2016-12-10 12:56:39 +01:00
Mark Whitehorn 6257d9bde1 remove pwm "trim" command; replaced by parameter values 2016-12-10 12:56:39 +01:00
Mark Whitehorn 86252e19e6 clean up other build targets 2016-12-10 12:56:39 +01:00
Mark Whitehorn f0b41a0e52 change main trims to normalized values 2016-12-10 12:56:39 +01:00
Mark Whitehorn dbc149c224 change trim units from absolute usec to normalized values 2016-12-10 12:56:39 +01:00
Mark Whitehorn d8528f46ce remove DEBUG_BUILD from fmu.cpp compile flags 2016-12-10 12:56:39 +01:00
Mark Whitehorn 764101e41e bump parameter minor version 2016-12-10 12:56:39 +01:00
Mark Whitehorn 876ab45bf3 fix errors in crazyflie and navio builds 2016-12-10 12:56:39 +01:00
Mark Whitehorn d4c707e698 remove INAV and switch to new logger for fmu-v2 builds
roughly 10K bytes below the 1MiB limit
2016-12-10 12:56:39 +01:00
Mark Whitehorn e80ef34b0d retest FMU control latency 2016-12-10 12:56:39 +01:00
Mark Whitehorn 009a413438 fix argument order in pwm_limit_calc call, clean up
note that FMU does not update AUX pwm outputs if no RC signal
2016-12-10 12:56:39 +01:00
Mark Whitehorn f3c3d1f7f9 fix rebase merge error 2016-12-10 12:56:39 +01:00
Mark Whitehorn 257e236c92 add errno to error message 2016-12-10 12:56:39 +01:00
Mark Whitehorn 5601ca19de astyle 2016-12-10 12:56:39 +01:00
Mark Whitehorn 0ccfcab010 fmu trims still not working 2016-12-10 12:56:39 +01:00
Bartosz Wawrzacz bb52a77194 [PX4IO/PWM driver] Fixed a bug in px4io driver 2016-12-10 12:56:39 +01:00
Mark Whitehorn 82bfaf3967 debugging fmu mode_pwm4 not recognized 2016-12-10 12:56:39 +01:00
Mark Whitehorn ea83b67bd8 add trim parameter handling 2016-12-10 12:56:39 +01:00
Mark Whitehorn 9ced4afca3 add AUX trim parameters 2016-12-10 12:56:39 +01:00
Mark Whitehorn a0c8a78a14 use trim values to set mixer:scaler.offset
clamp mixer output offset to [-.2,.2] ([-2000, 2000] in mixer file)

add 8 main PWM trim parameters

add long desc to parameters and bump minor parameter version
2016-12-10 12:56:39 +01:00
Bartosz Wawrzacz 619efa7b45 [PX4IO/PWM driver] Added trim values to the PWM output drivers 2016-12-10 12:56:39 +01:00
David Sidrane 4494182bfc Update rc.interface 2016-12-10 12:49:25 +01:00
Anton Matosov fff4934743 Implement the way to run posix simulator directly from IDE without the need to reconfigure command lines, but use runner created via CMake
Steps to debug:
 * Run gazebo (or any other sim) server and client viewers via the terminal: `make posix_sitl_default gazebo_none_ide`
 * In your IDE select `px4_<mode>` target you want to debug (e.g. `px4_iris`)
 * Start debug session directly from IDE

This approach significantly reduces the debug cycle time because simulator (e.g. gazebo) is always running in background and you only re-run px4 process which is very light.
2016-12-10 12:48:53 +01:00
Anton Matosov a2c0391bcc Rework TPA to have per-component setup and use more stable and intuitive function
This also adds a ZMR250 config.
2016-12-10 12:42:47 +01:00
Lorenz Meier 1bef1ae34a Make space in test config 2016-12-10 01:00:11 +01:00
Andreas Antener 64778b9540 Load monitor: added parameter to disable stack check 2016-12-09 21:12:12 +01:00
Andreas Antener 72f52c920c Load monitor: reduce scope of scheduler locking 2016-12-09 21:12:12 +01:00
Andreas Antener 806b8d3a67 Load monitor: free counter 2016-12-09 21:12:12 +01:00
Andreas Antener a0cf938ced Load monitor: lock scheduler for stack check and added performance counter for stack checking 2016-12-09 21:12:12 +01:00
Andreas Antener dda0de09dd Load monitor: optimize performance of stack checking 2016-12-09 21:12:12 +01:00
Andreas Antener a74269ec60 Load monitor: adding stack logging to logger 2016-12-09 21:12:12 +01:00
Andreas Antener c0c75d07c9 Removed 'degree' character that caused python3 to act up while pruning the mixer file 2016-12-09 21:12:12 +01:00
Andreas Antener 62103be7ba Load monitor: report and log processes low on stack 2016-12-09 21:12:12 +01:00
Michael Schaeuble b0ee5256d5 Disable LPE in px4fmu-v2_default
With GCC 4.9 the binary is to large for the flash memory.
This is why we disabled LPE on that platform.
2016-12-09 18:59:42 +01:00
Michael Schaeuble bdb76d013e Fix incorrect MPU9250 device ID
We propagate the bus parameters from the bus interface to the sensor
devices. Thus, the device ID of the sensor driver is set to the correct
bus id and address. Otherwise it would be zero, which is an issue if several MPU9250s
are running at the same time.
2016-12-09 18:59:42 +01:00
Paul Riseborough 1fbc688757 Commander: Fix pre-flight EKF check errors 2016-12-09 17:58:23 +01:00
Beat Küng 9442c89691 Tools/upload_log.py: add script to upload ulog file to logs.px4.io 2016-12-09 17:57:29 +01:00
Julian Oes 1424994bc0 navigator: don't takeoff in loiter on ground
This fixes the following corner case:
1. Upload a mission.
2. Set mission mode.
3. Set loiter mode.
4. Arm.
At this point it will shoot up and go to the takeoff waypoint even
though we're not in mission but in loiter mode.

The fix makes sure that the triplet is reset to invalid (and idle) in
loiter mode if we're landed and disarmed.
It will lead to the vehcle sit in idle on the ground until you issue a
start mission (or takeoff) command.
2016-12-08 15:07:14 +01:00
Dennis Mannhart dd1ca0daa2 correctin from user input to roll and pitch 2016-12-08 15:06:00 +01:00
Dennis Mannhart 6906d966ce manual input mapping to roll and pitch 2016-12-08 15:06:00 +01:00
Roman 0c49abbef8 standard vtol: correctly modify attitude for pusher assist
- fix a bug where the wrong rotation order was used to compute the attitude
setpoint when using the pusher assist feature

Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-08 15:05:43 +01:00
Samay Siga 6b08ba6272 Update 13010_claire
updated VT_FW_MOT_OFFID
2016-12-07 20:54:49 +01:00
Samay Siga e3ef206846 Update claire.aux.mix
Replaced individual elevator and aileron into "elevons"
2016-12-07 20:17:43 +01:00
Daniel Agar 1941dfca87 add tests code coverage
-closes #5862
2016-12-07 20:17:00 +01:00
Dennis Mannhart c2b6381759 adjust to astyle format 2016-12-07 17:32:09 +01:00
Dennis Mannhart 5ed35e9731 added comment why reseting at this point; created variable for horizontal velocity magnitude 2016-12-07 17:32:09 +01:00
Dennis Mannhart 6865a70dea reset position setpoints once altitude condition is reached 2016-12-07 17:32:09 +01:00
Julian Oes fc9f2143d2 sitl_gazebo: update submodule 2016-12-07 16:23:21 +01:00
Beat Küng 78f1d9d017 hmc5883: fix MAGIOCGEXTERNAL ioctl for non fmuv1 boards
This makes the onboard check consistent with hmc5883_bus_option
initialization. If the current bus is the onboard bus, return !external.

It fixes the onboard mag (HMC5883) for AeroFC. Its priority is now 100,
previously it was 255, so that if an external mag is attached, it will be
preferred.
2016-12-07 11:06:28 +01:00
James Goppert 13df03c78a Fix bug with imu rotation for tyhpoon in sitl gazebo. (#5988) 2016-12-06 12:55:05 -05:00
James Goppert fa834497bf Setup sf0x driver to handle all lightware lidars. (#5957) 2016-12-06 12:19:13 -05:00
Lucas De Marchi 7b81374fda aerofc: add comment to make intention clear 2016-12-06 08:34:18 +01:00
Lucas De Marchi 162c0a7418 Revert "Aerofc: px4fmu_common: Only set AUTOSTART to 4070 if nothing was set"
This reverts commit 126172d70c.

This commit is going in the wrong direction: it's actually the same as
it was before, but allows changing the autostart configuration to
something other than 4070, which means people could wrongly assume it
would work in other configurations.
2016-12-06 08:34:18 +01:00
Beat Küng 176c6e0df2 aerofc config: update default parameters for attitude & position controllers 2016-12-05 18:08:44 +01:00
Beat Küng e4e5a77f71 aerofc: use logger when autoconfig 2016-12-05 18:08:44 +01:00
Beat Küng e3537ca6c2 px4fmu rcS: increase mavlink rate to 100000 for SYS_COMPANION 1500000
Needed for log streaming
2016-12-05 18:08:44 +01:00
Roman aabf753ecb mc_pos_control: do not do tilt compensation when hor velocity is controlled
- fixed a bug where tilt compensation was done also when the horizontal
velocity was controlled. This is not needed because in this case
the controller outputs a 3D thrust vector.

Signed-off-by: Roman <bapstroman@gmail.com>
2016-12-05 16:07:19 +01:00
Lorenz Meier f15d1ce5e7 Sort and sync FMUv3 config 2016-12-05 15:27:11 +01:00
Daniel Agar 77298e42db fix pixhawk 2 (solo) sensor start 2016-12-05 15:27:11 +01:00
Daniel Agar 69cc4d7e7f rc.sensors fix indentation 2016-12-05 15:27:11 +01:00
Daniel Agar 9d494e625f travis-ci upload px4fmu-v3 for qgc 2016-12-05 15:27:11 +01:00
Daniel Agar a8747a01fe pixhawk 2.1 add 2nd ms5611 2016-12-05 15:27:11 +01:00
Daniel Agar 2c23c16b4f airframe metadata for vtol standard delta and AAERT 2016-12-05 10:26:17 +01:00
Mark Whitehorn 3294d839d6 add airframe metadata 2016-12-05 10:25:54 +01:00
Daniel Agar 2f962a986b PX4IO add IMU heater to status 2016-12-05 10:23:46 +01:00
Daniel Agar 1a1b8f69ac PX4IO add page setup case for thermal 2016-12-05 10:23:46 +01:00
Lorenz Meier 1b19b78c2b ROMFS: Enable thermal control (set to off) for Pixhawk 2 2016-12-05 10:23:46 +01:00
Lorenz Meier b229dd891f Senssors app: Introduce thermal setting 2016-12-05 10:23:46 +01:00
Lorenz Meier 3166aeb8a4 PX4IO driver: Enable thermal control 2016-12-05 10:23:46 +01:00
Lorenz Meier 9f14ace0fa IO: Allow control of the blue led state as function of a Pixhawk 2.1 heater 2016-12-05 10:23:46 +01:00
James Goppert 4b6a11161e Fixes for sitl gazebo ground truth. (#5932)
* Fixes for sitl gazebo ground truth.

* Switch ekf2 to new logging module for sitl.
2016-12-03 11:40:53 -05:00
Dennis Shtatnov d71645b321 CF2 Update to EKF2 2016-12-03 17:02:16 +01:00
Andreas Antener 64657900de SITL CI: use tagged docker image instead of latest 2016-12-03 09:42:54 +01:00
Lorenz Meier 899fb8d3c5 Aero: Add integrator gains for attitude control 2016-12-02 23:39:30 +01:00
Andreas Antener ef495d26b8 Airspeed calibration: wait on filter before preflight check 2016-12-02 22:56:48 +01:00
Andreas Antener e9737d6f7a Preflight checks: made sure pre-flight check results are always reported first thing on the console and always on new or re-established telemetry links AFTER waiting for the hotplug timeout
(leads to double publishing on the console when a new link is established, but this is the best compromise between fixing and completely restructuring)
2016-12-02 22:56:48 +01:00
Andreas Antener c069264752 Preflight check: initialize VTOL flag before it is used 2016-12-02 22:56:48 +01:00
Andreas Antener b531e65f6a Airspeed check: updated message and explained test parameters 2016-12-02 22:56:48 +01:00
Andreas Antener f772fc2d02 Airspeed: preflight check for bad offset, fixed calls to preflight checks (vtol & airspeed) 2016-12-02 22:56:48 +01:00
Julian Oes f092b31f54 Update cmake_hexagon and DriverFramework
This update is needed after changes in
https://github.com/ATLFlight/cross_toolchain/pull/10.
2016-12-02 21:18:18 +01:00
Lorenz Meier c53d828e09 Set EKF2 as default estimator 2016-12-02 21:13:34 +01:00
Lorenz Meier 654c7d2d16 Remove unused system command for FMUv2 config and re-enable MPU9250 driver 2016-12-02 20:58:38 +01:00
bharathr fee75c61a1 Added PX4 sanity test script for Snapdragon Flight 2016-12-02 18:49:30 +01:00
Julian Oes e416a8cb83 mc_pos_control: fix takeoff bug
This resolves a bug where a takeoff would go sideways instead of
straight up. What happened was that the position setpoint got shifted
around even though there was actually no real setpoint set but only a
setpoint of type IDLE. This then lead to a position setpoint far away
from the takeoff point and therefore scary takeoffs.

This fix prevents the part of the position controller which
moves/integrates the position setpoint from running in the case of an
idle setpoint.

This bug could be reproduced by switching the vehicle to mission mode
without a valid mission, then switch to hold mode, and then send the arm
and takeoff command.
2016-12-02 17:34:00 +01:00
Michael Schaeuble b982dca45a Add comments to clarify the BMI160 related changes 2016-12-02 12:40:12 +01:00
Michael Schaeuble 10867131fa Bring up BMI160 for px4fmu-v4 targets 2016-12-02 12:40:12 +01:00
José Roberto de Souza 126172d70c Aerofc: px4fmu_common: Only set AUTOSTART to 4070 if nothing was set
This way user can set aftwards any other AUTOSTART value and it will
not be overwritten.
Also move the block up and set SYS_AUTOCONFIG, this way if air frame
configuration was reset in ground station it will wipe the parameters
before load new ones.
2016-12-01 07:52:23 +01:00
José Roberto de Souza 9bb77adbec Aerofc: Fix and add more information about flash sectors 2016-12-01 07:52:23 +01:00
Beat Küng b020be13f6 flashparams: fix memory leak when saving parameters
A large buffer on the heap was not deallocated when parameters were saved,
but there were no changes to the parameters. In that case
parameter_flashfs_write() was not called, which was previously responsible
for freeing the buffer.

This patch moves the responsibility of freeing the buffer to the calling
side, which already explicitly allocates the buffer.
2016-11-29 10:38:11 +01:00
Mark Whitehorn a0796c6847 add tests to auavx21 config 2016-11-29 08:03:23 +01:00
Daniel Agar e0a9793347 mavlink doesn't have already published message
- if the land detector started before the mavlink module it won't have
   a valid message vehicle_land_detected message until published again
2016-11-29 00:49:57 -05:00
David Sidrane abc79faf3b Chip Slect fixes for the ICM_20608_G
The mapping of PX4_SPIDEV_ACCEL_MAG to PX4_SPIDEV_ICM is not
   a clean approach and the PX4_SPIDEV_MPU is already used by the
   mpu9250 leaving the only (and the correct) option to the use
   PX4_SPIDEV_ICM and make it map to the reused ACCEL_MAG_CS PC15
   as 206080D_CS
2016-11-28 21:02:23 +01:00
Julian Oes 0109f6f549 update mavlink to master, rename MOUNT_STATUS
The mavlink message MOUNT_STATUS has been renamed to MOUNT_ORIENTATION.

This changes the Firmware code accordingly.
2016-11-28 21:01:22 +01:00
Lucas De Marchi 780e903d5b aerofc: load autostart on first boot 2016-11-28 09:21:12 +01:00
Lucas De Marchi 2fb09b7978 Add AUTOCNF to Intel Aero RTF
Thanks to Beat Küng for improved tuning.
2016-11-28 09:21:12 +01:00
Lucas De Marchi f51595ab16 Fix setting output mode in the wrong place
Make it common with other boards
2016-11-28 09:21:12 +01:00
Lucas De Marchi 8fe765c3aa Change drone name
This is the file to set things related to the Intel Aero RTF.
2016-11-28 09:21:12 +01:00
José Roberto de Souza 9befff1e79 aerofc: Add information about the flash usage 2016-11-28 09:21:12 +01:00
José Roberto de Souza 621a0fe492 aerofc: Enable IST8310 2016-11-28 09:21:12 +01:00
José Roberto de Souza 8fb15f1de8 aerofc: Enable I2C1 for external compass
For now it is only checking if there is a external HMC5883, if
necessary more compass should be added and probe.
2016-11-28 09:21:12 +01:00
José Roberto de Souza c49c3f469e aerofc: add upload command
AeroFC is updated by Aero board using the UART between AeroFC
and Aero board.

This script will copy firmware and px_uploader.py to Aero board and run
px_uploader.py with the correct paremeters. User only needs to have a
network connection (Ethernet over USB or WiFi) with Aero board to update
AeroFC firmware. The IP/hostname can be given by AERO_HOSTNAME
environment variable.
2016-11-28 09:21:12 +01:00
Lucas De Marchi 6af31a109f aerofc: start mavlink on ttyS4 2016-11-28 09:21:12 +01:00
Lucas De Marchi 4989f8d40a aerofc: start mavlink to communicate with Aero Compute Board 2016-11-28 09:21:12 +01:00
José Roberto de Souza 508c782bab mavlink: Add support for high speed baudrates 2016-11-28 09:21:12 +01:00
Lucas De Marchi 1360c26c62 romfs: allow to use another uart for companion
Right now it's only possible to use ttyS2 as the UART for connecting a
companion computer. Add a variable that can be set so other boards may
be better supported.
2016-11-28 09:21:12 +01:00
José Roberto de Souza 4943437327 aerofc: Set sensors rotation 2016-11-28 09:21:12 +01:00
José Roberto de Souza 873901c7cd aerofc: Sleep for some time to wait tap_esc startup
Or mixer load will fail
2016-11-28 09:21:12 +01:00
José Roberto de Souza 8f0322b8aa aerofc: Dirty hack to start mixer with the correctly output device 2016-11-28 09:21:12 +01:00
Lucas De Marchi 66628a4cf1 aerofc: forbid gpio changes
We export an "empty" table, but there's no protection when doing
ioctl().
2016-11-28 09:21:12 +01:00
Lucas De Marchi fdb5a92873 aerofc: make sure we don't have IO enabled 2016-11-28 09:21:12 +01:00
Lucas De Marchi f5c65cf206 aerofc: disable mixer aux 2016-11-28 09:21:12 +01:00
Lucas De Marchi 99bb7be10f aerofc: leave OUTPUT_MODE as rcin
So it just does rcin and does not try to do the other initializations.
2016-11-28 09:21:12 +01:00
Lucas De Marchi 3b3d4f385c aerofc: fix UART port assignments 2016-11-28 09:21:12 +01:00
Lucas De Marchi 1eadee19c3 aerofc: Fix for ms5611 init 2016-11-28 09:21:12 +01:00
James Goppert 893714dc6a aerofc: Fixes for init 2016-11-28 09:21:12 +01:00
José Roberto de Souza 15c75ebb40 aerofc: Add autostart script
As ASC use a non-standard UART for mavlink it is necessary check for
the board name and set SYS_AUTOSTART to initialize mavlink on the
right interface otherwise there is no way to change the SYS_AUTOSTART.
2016-11-28 09:21:12 +01:00
José Roberto de Souza effdb37a2b aerofc: Fix UARTs configuration
Correct set pin mux and removed unused interfaces.
2016-11-28 09:21:12 +01:00
Lucas De Marchi ce8a7f6bdc aerofc: fix comment regarding hrt 2016-11-28 09:21:12 +01:00
Lucas De Marchi 1aea9457a9 aerofc: remove usb sensing 2016-11-28 09:21:12 +01:00
José Roberto de Souza 51f85858f2 aerofc: Power on sensors
MPU6500, MS5611 and HMC5883 only power on when GPIO_SENSORS_POWER is
set.
2016-11-28 09:21:12 +01:00
José Roberto de Souza 7ced5a1b6f aerofc: Remove unused GPIO configuration 2016-11-28 09:21:12 +01:00
José Roberto de Souza 0f9ad1c393 aerofc: Remove remaining code and macros of RGBLed 2016-11-28 09:21:12 +01:00
José Roberto de Souza 8788e2e81e aerofc: Remove ADC configuration
Battery voltage and current will be read in another way in future.
2016-11-28 09:21:12 +01:00
Lucas De Marchi 007731df46 aerofc: use center LED for activity
Like in bootloader, use the centered LED to show activity.
2016-11-28 09:21:12 +01:00
José Roberto de Souza e690af14d8 aerofc: fix I2C bus of MS5611 and HMC5883 2016-11-28 09:21:12 +01:00
José Roberto de Souza ef7c3b2174 aerofc: Fix SPI configuration
SPI bus 1 is the bus connected to MPU6500, so remove SPI bus 3 and 4.
Also remove everything else related to SPI that this board doesn't have.
2016-11-28 09:21:12 +01:00
José Roberto de Souza a1eec553dc aerofc: Remove unused modules 2016-11-28 09:21:12 +01:00
Lucas De Marchi cf07fa3a1c aerofc: streamline nuttx configuration
Remove what's not used like SPI and UART ports, ADC, etc. Add UART5 and
I2C1 that are going to be used.

This also received contribution from
José Roberto de Souza <jose.souza@intel.com>.
2016-11-28 09:21:12 +01:00
Lucas De Marchi 0cd7984b7f Rename asc board to aerofc 2016-11-28 09:21:12 +01:00
David Sidrane 4b90daf605 WIP:Using _PX4_ wildcard match - needs testing 2016-11-28 09:18:45 +01:00
David Sidrane 100f977b0c Added listener removed unconfigured drivers 2016-11-28 09:18:45 +01:00
David Sidrane c042f49fde System Changes for AUAV X2.1 2016-11-28 09:18:45 +01:00
David Sidrane 5b5076ae01 Added AUAV X2.1 sensor startup script 2016-11-28 09:18:45 +01:00
David Sidrane fb3e2665f3 Inital Commit AUAV X2.1 2016-11-28 09:18:45 +01:00
Lorenz Meier 70e597bd9a Update ECL to include fw controller limit improvements and side slip filter improvements 2016-11-27 16:08:53 +01:00
Julian Oes cf9945ecdc sitl_run.sh: env variable NO_PXH for deamon mode
This allows to set the environment variable NO_PXH to start SITL without
the interactive pxh> shell. For this, px4 is called with the -d arg
which sets it to deamon mode.

This feature is handy to script sitl_run.sh.
2016-11-25 17:51:50 +01:00
Beat Küng 707666488e RPi px4_fw.config: use AERT mixer file & fix fw_pos_control_l1 start 2016-11-24 14:57:52 +01:00
Beat Küng fdc489358a RPi startup scripts: start logger 2016-11-24 14:43:45 +01:00
Beat Küng 0a0f268407 RPi: improve upload script, upload mixer files & all startup scripts 2016-11-24 14:43:45 +01:00
Beat Küng 6680af0d96 navio_sysfs_pwm_out: use quad_x.main.mix as default mixer file
Most people will use a quad, not FW.
2016-11-24 14:43:45 +01:00
Beat Küng 9230f419e5 DriverFramework: update submodule 2016-11-24 14:43:22 +01:00
lhc610github f559b6ca88 df_lsm9ds1_wrapper: apply calibration after rotation 2016-11-24 14:39:23 +01:00
Julian Oes afd6fd3896 px4fmu-v2_default: save more flash
This disables the following modules to save flash:
- mpu9250 driver because the MPU9250 is rarely used on Pixhawks
- Snapdragon RC PWM passthrough which is rarely used and definitely a
  special/custom configuration. Also, it will soon be obsolete with the
  upcoming PWM support on Snapdragon.
2016-11-23 12:49:15 +01:00
Julian Oes 109558cf1f cmake: fix git binary hash
The generated binary hash was off by one.
2016-11-23 12:42:06 +01:00
Julian Oes 43caf2b683 Revert "mavlink: copy chars of git hash instead of binary"
Pushed by accident.
This reverts commit 87f0ec19e4.
2016-11-23 10:57:05 +01:00
Julian Oes 87f0ec19e4 mavlink: copy chars of git hash instead of binary
I could not figure out how to make sense out of the binary git data.
Therefore, I replaced the px4_git_version_binary with the first 8 bytes
of px4_git_version (char[]) and this is easily readable when it arrives
on the other side.
2016-11-23 10:48:17 +01:00
Roman f8f12ee265 vtol_att_control: removed unnecessary pointers to derived classes
- we interface over the base class pointer so we don't need any pointers
to the derived classes of VtolType

Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-22 10:05:53 +01:00
Roman d77547e7e1 vtol_attitude_control: hotfix, do not update parameters on every iteration
Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-22 10:05:53 +01:00
Roman 92a5db92a2 vtol_att_control: initialise pointers and free memory
Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-22 10:05:53 +01:00
Julian Oes 7a698952fb cmake: use default Python version
If the Python versions are specified, this breaks the build on Ubuntu systems
where Python3 is also installed but the extensions such as python-empy
are not installed. One could, of course, install python3-empy to fix
this but that's not in the instructions or error messages and therefore
not straightforward.

It is therefore probably better to just use the system default which
ends up being 2.7 on Ubuntu.
2016-11-21 15:02:17 +01:00
devbharat 4ea72f35ed Disable resetting alt/pos setpoint flags if switching to position control from auto when very close to takeoff setpoint 2016-11-21 09:05:22 +01:00
devbharat dd1821b02e Reset alt/position when entring position control from auto 2016-11-21 09:05:22 +01:00
devbharat 59c1dd7183 Always check reset flags in auto. Only set reset flags to true when required. Do not limit hor/vert setpoint acceleration when setpoints are reset. 2016-11-21 09:05:22 +01:00
Julian Oes d720cbe189 cmake: Use Python3 if available
This brings support for Distros that use Python3 by default such as
Arch Linux.
2016-11-21 08:34:12 +01:00
Felix Hu fe9ffb824c Update README.md 2016-11-21 08:33:42 +01:00
Roman 912ed98a28 updated ecl 2016-11-21 07:29:21 +01:00
Roman a61b1e089c make sure to update the reset counters every time the topic updates
Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-21 07:29:21 +01:00
Roman 9f57ee8564 updated ecl for updated gps reset logic
Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-21 07:29:21 +01:00
Roman 76f862de33 fw_pos_control_l1: when doing a position reset just reset position controller
- do not try to shift the target waypoints when a reset occurs in position
control mode. Just make it lock into the current heading.

Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-21 07:29:21 +01:00
Roman 7ba49aeb80 fw_pos_control_l1: make TECS handle height ekf height resets properly
Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-21 07:29:21 +01:00
Roman ae7f61b0bf tecs: added method to handle ekf height resets
Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-21 07:29:21 +01:00
Roman 1e1bf7e4bb ekf2 reset: fix sign of delta altitude for global position topic
Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-21 07:29:21 +01:00
Roman 8155044b40 fw_pos_control_l1: put comments for lat/lon wrapping
Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-21 07:29:21 +01:00
Roman f80b4f8732 fw_pos_ctrl_l1: added wrapping of lat lon coordinate after addition of
delta reset

Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-21 07:29:21 +01:00
Roman b3f9114b1c fw_pos_control_l1: added missing alitude reset counter update
Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-21 07:29:21 +01:00
Roman d4c87d62f1 fixed code style
Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-21 07:29:21 +01:00
tumbili 0e481a5d00 ekf2: publish state reset information 2016-11-21 07:29:21 +01:00
tumbili b2410460a5 made position controllers handle estimator state resets 2016-11-21 07:29:21 +01:00
tumbili 937c5adfc0 added estimator reset data to global position topic 2016-11-21 07:29:21 +01:00
tumbili 0d7189c894 added position and velocity reset data to local position topic
Conflicts:
	msg/vehicle_local_position.msg
2016-11-21 07:29:21 +01:00
tumbili 89f81cb626 added attitude reset data to control state topic 2016-11-21 07:29:21 +01:00
Daniel Agar c17c8884d1 implement MAV_CMD_DO_LAND_START 2016-11-19 15:48:10 +01:00
Daniel Agar 6cdd188158 geofence max horz/vertical better messages 2016-11-19 15:16:00 +01:00
Daniel Agar c701085ed4 geofence fix code style 2016-11-19 15:16:00 +01:00
Daniel Agar 6f10f8de9a navigator begin fixing code style 2016-11-19 15:16:00 +01:00
Daniel Agar 9e589cef48 airspeed calibration fail with any errors 2016-11-19 15:15:36 +01:00
Daniel Agar 46a697787f log all raw diff pres and airspeed 2016-11-19 15:15:36 +01:00
Daniel Agar 0fa79eab5c add differential_pressure to airspeed logging 2016-11-19 15:15:36 +01:00
Anton Matosov 90c049d8ec Fix formatting 2016-11-19 15:14:46 +01:00
Anton Matosov cd40512505 Add mag2, acc2 and gyro2 sensors params to make sure backup/restore is reliable 2016-11-19 15:14:46 +01:00
Anton Matosov 96fc66ff7d Add force param_find for missing sensor parameters to fix load/save loss of calibration data 2016-11-19 15:14:46 +01:00
Anton Matosov e284a28e25 Fixed formatting 2016-11-19 15:14:18 +01:00
Anton Matosov 4edd12c44a Make PWM_RATE configurable via QGroundControl 2016-11-19 15:14:18 +01:00
Paul Riseborough 81dc20ea86 logger: add preflight sensor check messages 2016-11-19 15:12:08 +01:00
Beat Küng 9301e9cc50 logger params: add SDLOG_MODE to select when to start & stop logging 2016-11-19 15:12:08 +01:00
Paul Riseborough 983cfb8fdd commander: Add preflight checking for EKF health and IMU sensor consistency 2016-11-19 15:12:08 +01:00
Paul Riseborough 55bf6b4974 sensors: Calculate and publish pre-flight IMU sensor consistency metric
If a single sensor is fitted, the calculation is not performed and zero values are published.
If dual IMU's are fitted, the vector length difference between the primary IMU and the second sensor is output for the angular rates and accelerations. The vector difference is low pass filtered before the length is taken.
If three IMU's are fitted, the vector length is calculated for both alternative sensors and and the maximum values output.
Fourth and subsequent IMU's are ignored.
2016-11-19 15:12:08 +01:00
Paul Riseborough c07f7b5659 msg: Add topic for pre-flight sensor checks 2016-11-19 15:12:08 +01:00
Paul Riseborough 06aca33085 ekf2_replay: Add missing log messages 2016-11-19 15:11:45 +01:00
Dennis Shtatnov 2799c0fae2 Change MC_BAT_SCALE_EN to boolean 2016-11-19 14:55:52 +01:00
Dennis Shtatnov 37641042cc Explicit internal battery resistance params 2016-11-19 14:55:52 +01:00
Dennis Shtatnov a634c14582 Scale throttle outputs by battery level. Fixes #4751 2016-11-19 14:55:52 +01:00
Andreas Antener a94c8d7812 Log download: try to use file modification date for log list if it makes sense 2016-11-19 14:51:30 +01:00
Andreas Antener dd8d178168 MAVLink Streams: added collision stream 2016-11-19 14:46:20 +01:00
lovettchris 8a2399eee1 Fix multithreading bug in mavlink over serial port. 2016-11-19 00:24:15 +01:00
Andreas Antener 0eadf26d34 Log download: fix memory leak in generating the list 2016-11-18 16:27:47 +01:00
Lorenz Meier 1f0e630958 Update use of time stamp field 2016-11-17 09:38:56 +01:00
Lorenz Meier 616c5012da Update MAVLink submodules to latest 2016-11-17 09:38:56 +01:00
Lorenz Meier 8ebc846ae7 Simulator: Do not open hardware UART in SITL 2016-11-17 09:11:58 +01:00
Lorenz Meier b83363a518 UAVCAN: Always enable dynamic node ID allocation 2016-11-16 10:56:08 +01:00
Paul Riseborough 9ff1feb92f ekf2: fix formatting 2016-11-15 23:58:05 +01:00
Paul Riseborough 056ac3c9c6 EKF: Update default value for sideslip fusion noise
Use value obtained from tuning on replay logs
2016-11-15 23:58:05 +01:00
Paul Riseborough 680a8f0b44 ekf2: fix rebase compile errors 2016-11-15 23:58:05 +01:00
CarlOlsson 72ad6627e1 updated beta noise
Conflicts:
	src/modules/ekf2/ekf2_params.c
2016-11-15 23:58:05 +01:00
CarlOlsson 5435b99f86 added beta innovations to ekf_innovations 2016-11-15 23:58:05 +01:00
CarlOlsson e4f5710ec3 added logic for beta fusion 2016-11-15 23:58:05 +01:00
CarlOlsson f00f6e6eff added parameter for when to fuse sideslip 2016-11-15 23:58:05 +01:00
CarlOlsson 1223e4ba6b added beta to replay 2016-11-15 23:58:05 +01:00
CarlOlsson 106c882cea modified logging 2016-11-15 23:58:05 +01:00
CarlOlsson d550290e63 modified ekf2_main.cpp 2016-11-15 23:58:05 +01:00
Anton Matosov 0734db1740 Ignore all CLion related files as they are all generated from cmake 2016-11-15 11:10:22 +01:00
Anton Matosov 3414fc1c7c Setup default CLion ignores 2016-11-15 11:10:22 +01:00
Julian Oes 25d1daa7a5 px4fmu-v1: Raise INTERRUPTSTACK again
This fixes #5855.
2016-11-15 08:10:40 +01:00
Julian Oes 53c23e7bff Revert "Revert "FMUv1: Save resources in config""
This reverts commit 0ca397ab20.
2016-11-15 08:10:40 +01:00
Lorenz Meier 0ca397ab20 Revert "FMUv1: Save resources in config"
This reverts commit c24046ca5b.
2016-11-14 22:37:01 +01:00
Beat Küng 2f19aebac0 mavlink_ulog_streaming: always send an ack (#5853)
Fixes the case where an ack got lost and the FMU resends the data, but
the client does not resend the ack.
2016-11-14 17:06:21 +01:00
Roman 896118281c TECS: remove logic which shifts or limits integrator during large transients
- during large transients in pitch demand the pitch integrator value
was shifted such that the final demanded pitch did not violate given
limits. Since this strategy can cause large knock-backs of the pitch
integrator we remove this logic completely. We already have logic in place
which reduces the integrator at the pitch time constant in case the
pitch limits are exceeded so we don't need to limit it further. This
has the advantage that spikes in the specific energy balance error
signal does not lead to integrator knock-back.

Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-14 22:43:33 +11:00
Paul Riseborough 9221c74e46 tecs: improvements to pitch integration limiting
Constrain the specific energy balance integrator input to prevent increasing saturation of pitch demand.
Decay the specific energy balance integrator state if the pitch demand is saturated to reduce saturation to zero and do so at the same tome constant as the control loop
Relax the clipping threshold on the specific energy balance integrator to allow the input constraint and decay functions to do more of the work
Improve variable naming and commenting
2016-11-14 22:43:33 +11:00
Roman 7106881cbc tecs: fix limiting of pitch integrator input, better comments and structure
- when limiting the pitch integrator input the value was related to
a quantity with different units (specific energy error rate vs delta pitch)
- once the unconstrained pitch demand is larger / smaller than the max/min
allowed pitch angle the integrator input should only be allowed to drag
the integrator into the direction leading to less pitch demand violation

Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-14 22:43:33 +11:00
Roman 12ddf9d25e TECS: better handling of the constraint for the pitch integrator
- if the specific energy balance correction term produced a demanded
pitch value which exceeded the aircraft pitch limits then the pitch
integrator was shifted such that the pitch demand violation was prevented.
However, this meant that the exceeding pitch was just unloaded into the
integrator and caused unexpected behavior of the pitch loop.
In an underspeed condition e.g. this has lead to the plane pulling up it's
nose very quickly shorty after the underspeed condition kicked in.

Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-14 22:43:33 +11:00
Roman eec55a0918 TECS: run underspeed detection method before calculating speed demand
- the method in TECS for detecting an underspeed condition was run after
the method which calculated the airspeed demand. As a result the specific
engergy balance error signal showed a spike when TECS detected an underspeed
condition.

Signed-off-by: Roman <bapstroman@gmail.com>
2016-11-14 22:43:33 +11:00
Beat Küng dc6ca7c372 VDev & CDev: dynamically allocate & resize _pollset array
In most cases, really only 1 element is needed. The dynamic allocation
handles cases where more are necessary. This is all done within a locked
state, so no races can occur.

Frees roughly 2.3KB RAM.
2016-11-14 10:27:57 +01:00
Beat Küng 14fd1b8693 ulog_stream_ack.msg: lower timeout & increase max retries
We expect a short round-trip time, so lowering the retry timeout will
increase throughput on links with high drop rate.
2016-11-14 10:27:57 +01:00
Beat Küng d54e22614f fix mavlink ulog: return if initial ack not yet received
Avoid sending data before we have an ack from the logger.
2016-11-14 10:27:57 +01:00
Carlo Wood a96ee50442 Stop people from using broken awk. 2016-11-13 19:36:27 +01:00
Carlo Wood 0fbf26e955 Add Tools/fix_headers.sh
Running this script will parse the top of all source files
that are not submodules, examples or test cases, to find
all #include's and then do basically two things:

1) Reorder and group the headers so that px4_* headers are
   included first, then local headers (headers of the project
   that aren't submodules) then C++ headers if any, then C
   headers if any, then system headers (which includes submodules)
   and finally any #includes that are inside #if*...#endif
   constructs.
2) Fix the use of "" or <> in a consistent manner.

Afterwards few fixes might be necessary for compile errors that
pop up. Most of those are already fixed in my previous commits.
However, I was not able to test a compilation for ros
(with __PX4_ROS defined) -- so some more fixes might be necessary
because of the header reordering.

The script comes with a progress counter and an error summary
(if any) at the end (so no scrolling back is necessary).
It is highly recommended to only run this script in a clean
project with no outstanding changes that need to be committed.
In fact, the script enforces this (unless you pass --force).
Reverting a run of the script is then easy with 'git checkout .'.

It is also possible to run the script on a single file
by passing that on the command line. In that case it
might make sense to pass --debug too, though that was really
meant for just me, while developing the script. This will write
debug output into the file that is passed, so you don't
want to commit that! ;)
2016-11-13 19:36:27 +01:00
Carlo Wood de85fbe1dc Remaining fixes needed before running Tools/fix_headers.sh
<systemlib/err.h> --> "systemlib/err.h" that fix_headers.sh
would miss because it comes after code it doesn't understand.

Effectively remove the '__EXPORT extern perf_counter_t perf_alloc('
line, because currently perf_alloc is defined to be NULL, and
after running fix_headers.sh that happens *before* this header
is included (the order of headers will be changed).

Do not define NULL to be (void*)0: that only works for C.
In fact, the conversions needed for NULL are so full of exceptions
that standard C++ introduced a new *keyword*: nullptr.
That's what we really should be using for C++ code.
In this case I just include the correct header to define NULL
the correct way.

Not really related to the header line:
Removed an #include <time.h> because I noted that px4_time.h
was already included... and moved a #include <sys/time.h>
to the top of the file (not really a fan of including headers
in the middle unless absolutely necessary).
Removed a include of queue.h because I noted it wasn't used.
2016-11-13 19:36:27 +01:00
Carlo Wood ebeb187522 Move #pragma once outside #ifdef's.
In this particular case it does no harm,
but since in other cases it can lead to
problems I didn't want to add an exception
for this case to fix_headers.sh, that currently
chokes on this because it doesn't know better
than that it's a bad thing.

Note on how #pragma once works: when encountered
(aka the #ifdef that it is inside has to
be true), the compiler marks the whole
file as "seen" (this is implementation
defined, but most implementations store
the inode of the file). Subsequent #include's
of that file/inode are then completely skipped.
Hence it doesn't matter if the #pragma is at
the beginning, at the end or in the middle,
but it should be encountered every #include,
usually, and thus not be inside an #if... #endif
construct.
2016-11-13 19:36:27 +01:00
Carlo Wood 04aa2bb3a4 Add missing header files.
These headers files were missing from the header files that
I added them to; the fact that they were missing didn't
lead to compile errors because by coincidence the missing
headers are included in the source files before including
these headers. But, after the reordering of header inclusions
by Tools/fix_headers.sh, these cases will give rise to compiler
errors.
2016-11-13 19:36:27 +01:00
Lorenz Meier 86c581b2ef Enable usage of UAVCAN node ID for params 2016-11-13 18:43:15 +01:00
Lorenz Meier 9866ff8959 Allow sending a param with a different component ID 2016-11-13 18:43:15 +01:00
Benoit3 83e9e1c382 The goal of this patch is to allow compatibility with GR12/GR16/GR24 graupner receiver by :
- allowing decoding of SUMD frame with failsafe bit set
- updating stack failsafe state with the sumd failsafe info

Refer to #5817 issue
2016-11-12 14:28:57 +01:00
Michael Schäuble 697d401b73 Fix boot process on Pixhawk 2 (#5844)
* Pixhawk2: Check for mpu9250 during boot

* Fix indentation style
2016-11-12 12:57:33 +01:00
Mark Whitehorn 77a23a043f use include statement instead of symbolic link 2016-11-11 09:50:42 +01:00
Mark Whitehorn 92ae763535 change board_config to symbolic link 2016-11-11 09:50:42 +01:00
Mark Whitehorn 40f2c4a8e4 add new board config for fmu-v3 2016-11-11 09:50:42 +01:00
Paul Riseborough bdec646736 ekf2_replay: Display RMS innovation values to assist with tuning
Displaying the RMS innovation values at the end of each replay assets with rapid iteration for time delay parameter tuning without having to plot or post process using another tool.
2016-11-11 08:51:12 +01:00
Julian Oes ab76a37910 DriverFramework: update of cmake_hexagon 2016-11-10 07:56:28 +01:00
Mark Charlebois 47c14395d3 Updated cmake_hexagon for Semaphore CI fix
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2016-11-10 07:56:28 +01:00
Julian Oes 6bdca1053c Next cmake_hexagon in Firmware and DriverFramework 2016-11-10 07:56:28 +01:00
Julian Oes 88e81aa58e cmake_hexagon: rpcmem and linking fix
This updates cmake_hexagon and cmake_hexagon inside DriverFramework
which fixes somethine about rpcmem.a and the double linking issue.
2016-11-10 07:56:28 +01:00
James Goppert 068ef591ab Added fake landing xy velocity measurement to lpe. (#5820)
Flight tested and is working.
2016-11-09 19:40:25 -05:00
James Goppert 4d6d0b2850 Fix px4io bind failed message to say safet is off instead of armed. (#5834)
Minor message clarity fix.
2016-11-09 19:39:39 -05:00
James Goppert 3511f8abfb Add position ground truth. (#5819)
Have confirmed this works with gazebo sitl.
2016-11-09 19:38:38 -05:00
Julian Oes d1d47c4c27 mavlink: send MOUNT_STATUS msg if subscribed
This adds the message MOUNT_STATUS to report about the attitude of a
gimbal.
2016-11-09 10:23:34 +01:00
Julian Oes 18d69698a0 vmount: publish mount_status
We need feedback in mavlink about the attitude of the gimbal. Therefore
the gimbal output angles are published in vmount.
2016-11-09 10:23:34 +01:00
Julian Oes 7e312f3961 msg: Added message for mount status 2016-11-09 10:23:34 +01:00
Julian Oes 8ddda0a8fa mavlink: move the msg id from uint8_t to uint16_t
With mavlink2 new messages are added with msg IDs greated than 255.
Therefore the msg ID types needed to be raised everywhere.
2016-11-09 10:23:34 +01:00
Julian Oes 278d63eef6 mavlink: update both submodule to lastest master 2016-11-09 10:23:34 +01:00
Julian Oes 7df11b900d mavlink: use queueing for acks 2016-11-09 08:50:13 +01:00
Julian Oes d0b1983784 mavlink: send NACK if msg ID does not exist 2016-11-09 08:50:13 +01:00
Julian Oes 1e617f362d mavlink: send ACK for CMD_SET_MESSAGE_INTERVAL
There was no feedback if a CMD_SET_MESSAGE_INTERVAL went through or not.
2016-11-09 08:50:13 +01:00
Beat Küng 643ccd66b6 MavlinkParametersManager: output deprecation warning if INAV is selected 2016-11-08 11:17:07 +01:00
Beat Küng d32d250a50 px4fmu-v2_test.cmake: remove inav 2016-11-08 11:17:07 +01:00
Beat Küng 66ffc834d3 startup scripts: remove INAV, start LPE if INAV selected 2016-11-08 11:17:07 +01:00
Paul Riseborough 246dc5421b ekf2: remove unnecessary variables found during review 2016-11-08 11:17:07 +01:00
Paul Riseborough d19a62a8f6 px4fmu-v1: Remove INAV to free required flash space 2016-11-08 11:17:07 +01:00
Paul Riseborough d75600b8a4 px4fmu-v2: Remove INAV to free required flash space 2016-11-08 11:17:07 +01:00
Paul Riseborough 0ee75dbc6b ekf2: Allow adjustment of min arrival time delta parameter 2016-11-08 11:17:07 +01:00
Paul Riseborough 08a380ae2d ecl: update library reference
Enables optimum setting of sensor data buffer lengths using specified data delays and min arrival interval.
2016-11-08 11:17:07 +01:00
Paul Riseborough 5ac73f3440 ekf2: code style fixes 2016-11-08 11:17:07 +01:00
Paul Riseborough 699edd2535 ekf2: Prevent loss of baro data due to buffer time arrival checks
Baro data arriving too soon after the last measurement due to a high sampling rate or timing jitter is rejected inside the ecl EKF to prevent the data buffer overflowing.
This patch checks the timestamp difference from the last measurement, and if to small, the data is accumulated and the average sent to the EKF when the time delta
is acceptable.
2016-11-08 11:17:07 +01:00
Paul Riseborough ef7ed97cbd ekf2: Don't send un-usable mag and baro data to the EKF
Fixes:

1) Invalid data with a zero time stamp could be the EKF ends up in the data buffers and result in loss of 'good' data from the buffers

2) Magnetometer data was arriving at a rate faster than the data buffers could handle resulting in loss of data.
2016-11-08 11:17:07 +01:00
Paul Riseborough 7d0d29f62d ekf2_replay: fix time stamping bug
If the replay data for the baro or mag data has a zero time stamp, then the corresponding relative timestamp published over the combined sensor topic must be se to RELATIVE_TIMESTAMP_INVALID so that the ekf2 module does not try to use this data.
2016-11-08 11:17:07 +01:00
Lorenz Meier 7be71459f5 Offboard control (#5816)
* Fix jmavsim HITL simulation of MAV_CMD_DO_REPOSITION in the case where you have no radio attached to the PX4 and so you have disabled RC link loss for that reason (set NAV_RCL_ACT = 0) but you still want the jmavsimulation to work.  The line of code changed here causes failsafe RTL to kick in without this fix.

* Add altitude hold option using Z position control, while doing velocity control on vx and vy.

* Fix style and rebase issues
2016-11-07 12:09:41 +01:00
Michal Stasiak 9180268a17 Geofence: Param update fix (#5812) 2016-11-06 14:31:59 -05:00
Daniel Agar 8ac4dd04ae implement MAV_CMD_MISSION_START 2016-11-06 15:24:34 +01:00
Beat Küng 223595e978 ecl: update submodule to master 2016-11-06 14:48:20 +01:00
Beat Küng d1a3261e81 ekf2_main: reduce stack (according to the reductions in the commit before) 2016-11-06 14:48:20 +01:00
Beat Küng 5bcfa3c7e6 ekf2_main: add {} to limit variable scope and save stack
Reformatting makes it look worse than it is, but it really only adds {}
2016-11-06 14:48:20 +01:00
Beat Küng f7e3e46a92 config command: fix device commands like 'config /dev/accel0 block' 2016-11-06 14:48:20 +01:00
Beat Küng cc27d2a1e0 ekf2_main: move subscriptions into main thread & call orb_unsubscribe at the end 2016-11-06 14:48:20 +01:00
Beat Küng 53cf27eb84 ekf2_main: some cleanup of redundant fields 2016-11-06 14:48:20 +01:00
Beat Küng 85cee9460f sensors: use only as many voters as there are sensors
This saves ~1.1KB of RAM for systems with only 1 sensor of each type.

If there are more sensors, they will be dynamically added, such that
failover still works.
2016-11-06 14:48:20 +01:00
Beat Küng 0f2b31b41e uorb: inline orb_advertise (directly calls orb_advertise_multi)
reduces the stack depth
2016-11-06 14:48:20 +01:00
Henry Zhang 309c256e9e fix param interface (#5797)
* param: fix bug when param value is changed to 'zero' for the first time, it won't be saved.

* param: revert incorrectly removed code.
2016-11-06 14:45:17 +01:00
Julian Oes 53e0bc5f12 POSIX: use up to 20 command line arguments
This fixes the case where more than 10 args were needed for instance
when starting mavlink with all its options.
2016-11-05 14:20:17 +01:00
Lorenz Meier bae8adc1a8 Update README.md
Add GitHub links to maintenance team list.
2016-11-05 11:43:09 +01:00
Lorenz Meier f44ab6f05d Update README.md
Listing existing maintainers explicitly.
2016-11-05 11:34:38 +01:00
Michal Stasiak 2bfac7ff4f Mission feasibility: Geofence check fix
Current implementation checks against geofence only if it is in polygon form.
When it's created via params, it accepts all the waypoints as the number of vertices = 0.
Thus, changed the function to the one that is used to check whether geofence is breached in flight.
2016-11-05 11:07:23 +01:00
Dennis Shtatnov bf9a1c5a18 Removing alternative io timer rate for CF2 2016-11-05 11:06:43 +01:00
David Sidrane 2d451991af PX4 System change to Remove #ifdefs from the IO timers
Update the comment, to explain how to achive a different perescale
   value.

   Added PX4_IO_TIMER_ALTERNATE_RATE one board agnostic ifdef
   PX4_IO_TIMER_ALTERNATE_RATE that is non board specific.

   N.B.  I would like to eliminate PX4_IO_TIMER_ALTERNATE_RATE
   as well, but I need crazyflie HW to validate that the startup
   script can just set the rate on the PWM to 3921 fast enough to
   not effect the motors.
2016-11-05 11:06:43 +01:00
David Sidrane b2b9a0be9f PX4 System change to allow way to override the PWM_.*_{MIN|MAX} values
Add PX4_PWM_ALTERNATE_RANGES in suport of a board agnostic way
 to override the PWM_.*_{MIN|MAX} values
2016-11-05 11:06:43 +01:00
David Sidrane d77e107e31 Crazyflie uses the board common interface to provide board name
Removed #ifdef in version.h
2016-11-05 11:06:43 +01:00
David Sidrane ab43baa02d Clean up Crazyflie
1) Remove uneeded spi and reset code
   2) Use the Board commin for providing the BOARD_NAME
   3) Add PX4_PWM_ALTERNATE_RANGES in suport of a board agnostic
      way to override the PWM_.*_{MIN|MAX} values
   4) Remove #ifdefs from the IO timers*. Drive the config deltas
      from the crazyflie_timer_config.c and one board agnostic
      ifdef PX4_IO_TIMER_ALTERNATE_RATE that is non board specific

      *I would like to eliminate PX4_IO_TIMER_ALTERNATE_RATE
      as well, but I need HW to validate that the startup
      script can just set the rate on the PWM to 3921 fast
      enough to not effect the motors.
2016-11-05 11:06:43 +01:00
David Sidrane c4d91ef644 Removed CONFIG_STM32_I2CTIMEOTICKS defined in the PX4 I2C driver
CONFIG_STM32_I2CTIMEOTICKS is hard defined on PX4 master
 and defconfig defined on upstream Nuttx (nuttx_v3) it will be fixed
 there.
2016-11-05 11:06:43 +01:00
David Sidrane fd797ae3b4 Using build system warnings.
Aligned Make.Defs to use the build system's defined warnigns.
2016-11-05 11:06:43 +01:00
Mark Whitehorn 9603794b9d set verbose flag for Dcm.renormalize test 2016-11-05 11:05:25 +01:00
Mark Whitehorn 03beeb2e55 update matrix submodule 2016-11-05 11:05:25 +01:00
Mark Whitehorn fc73ab5e40 add unit test for Dcm.renormalize() 2016-11-05 11:05:25 +01:00
Daniel Agar a8369c6ac8 FW use loiter to achieve waypoint altitude
- fixes #5061
2016-11-05 10:30:36 +01:00
Sander Smeets 39cc75b4a0 Rebase of vtol_land_weathervane patch 2016-11-04 20:29:45 +01:00
Beat Küng 4bcf2cdb52 uavcan: fix initialization of std::array
in C++11, double braces are needed for std::array aggregate initialization,
or assignment with =.
see: http://en.cppreference.com/w/cpp/container/array
2016-11-04 16:41:13 +01:00
Carlo Wood 09d36a63ef Revert to using __builtin_isfinite for QuRT.
See discussion in https://github.com/PX4/Firmware/issues/5756
2016-11-04 16:40:45 +01:00
Beat Küng ab4d7dfc59 mavlink: stop ulog streaming when mavlink thread exits
'mavlink stop-all' during a log streaming session previously led to a
resource leak, and log streaming could only be re-started by rebooting the
system.
2016-11-04 11:08:06 +01:00
Beat Küng 587c5161a3 mavlink_{shell,ulog_streaming}.py: show full error output when pymavlink import fails 2016-11-04 11:08:06 +01:00
Beat Küng fa461d018d mavlink_{shell,ulog_streaming}.py: send heartbeat
This is helpful, so that a connected partner can switch from broadcasting
to a 'connected' state.
2016-11-04 11:08:06 +01:00
Mark Whitehorn 25be7aa7cf incorporate Bill Premerlani's fast rotation handling from MatrixPilot 2016-11-03 23:03:03 +01:00
Lorenz Meier 76082da674 Add IST8310 driver 2016-11-03 15:38:28 +01:00
Lucas De Marchi c5100b6273 tap_esc: fix output order for quadrotor 2016-11-03 15:38:09 +01:00
mantelt 8b237d7cf3 navio_sysfs_pwm_out: Adressing comments of @bkueng
(https://github.com/PX4/Firmware/pull/5704#pullrequestreview-6977559)
2016-11-03 12:37:41 +01:00
mantelt 10491884ca navio_sysfs_pwm_out: command line argument for mixerfile 2016-11-03 09:38:38 +01:00
mantelt 32403ddb90 navio_sysfs_pwm_out: removing default mixer 2016-11-03 08:59:58 +01:00
mantelt 6cbd398974 RPi/Navio: add rpi baseline config for fw 2016-11-02 17:45:31 +01:00
mantelt 4b8fc2365e navio_sysfs_pwm_out: Use mixer file
use all actuator groups for mixing.
2016-11-02 17:45:30 +01:00
mantelt 4c0c526898 Loading mixer from (hardcoded) file
use actuator_controls_3 for the time being
2016-11-02 17:45:30 +01:00
Daniel Agar cdd317ba38 commander arm check throttle include rattitude 2016-11-01 22:51:51 +01:00
CarlOlsson 93fb02bfa3 fw_att_ctrl: Code cleanup
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2016-10-31 15:17:14 +01:00
Beat Küng 00cd2902c7 fix logger: avoid leaking file descriptor in get_log_time()
orb_subscribe can succeed, but if there is no publisher, orb_copy will fail.
We still need to unsubscribe in that case.
2016-10-31 12:41:04 +01:00
Daniel Agar 2908f1c16d commander allow disarm command with throttle 2016-10-31 09:15:06 +01:00
Daniel Agar 27a50275b6 commander NAV_RETURN_TO_LAUNCH change mode to RTL 2016-10-30 21:41:43 +01:00
Carlo Wood 0bff3593d3 Do not use std::cout for qurt's sake.
Using cout drags in std::localeconv which isn't defined
on QURT. While this file is also used for POSIX, it doesn't
seem to harm much to use printf there as well.
2016-10-29 10:57:34 +02:00
Carlo Wood 52b8e75aea Export symbols init_app_map and list_builtins
See discussion at https://github.com/PX4/Firmware/issues/5756
2016-10-29 10:57:34 +02:00
Henry Zhang 278124bfb8 MindPX: Code clean up. 2016-10-29 10:56:32 +02:00
Henry Zhang b280e28623 MindPX: Remove hardcode for sensors rotation. 2016-10-29 10:56:32 +02:00
Henry Zhang f17dc2f2a6 MindPX: Code style and clean up. 2016-10-29 10:56:32 +02:00
Henry Zhang d6ed416d29 MindPX: Update spi bus and sensors io config. 2016-10-29 10:56:32 +02:00
Henry Zhang cabcc39816 MindPX: Expand to maximum 8 PWM outputs. 2016-10-29 10:56:32 +02:00
Henry Zhang 53b4996379 MindPX: Use TIM14 CH1 for tone alarm output. 2016-10-29 10:56:32 +02:00
Henry Zhang b76c8cd80c MindPX: Use i2c rgbled. 2016-10-29 10:56:32 +02:00
Henry Zhang 016aa47dfc MindPX: Enable FrkSky telemetry on usart8/ttys6. 2016-10-29 10:56:32 +02:00
Henry Zhang 2b23835d56 MindPX: Support RSSI. 2016-10-29 10:56:32 +02:00
Henry Zhang d8ac044414 MindPX: Support serial RC input. 2016-10-29 10:56:32 +02:00
Henry Zhang 5076ba0049 MindPX: Disable second CAN bus. 2016-10-29 10:56:32 +02:00
Henry Zhang 99ad8f464e MindPX: Update modules config. 2016-10-29 10:56:32 +02:00
Henry Zhang 93343487e7 MindPX: Harmonize with FMUv4. 2016-10-29 10:56:32 +02:00
Julian Oes c9f0d1e645 rcS: move check for PWM input up
pwm_input was not working correctly (only after a pwm_input reset) on
Pixracer because fmu was started on all PWM output channels.

This moves the check if PWM input is needed up before the fmu start.
2016-10-29 10:52:44 +02:00
Lorenz Meier b9cf679118 Update sitl_gazebo 2016-10-29 00:01:39 +02:00
Lorenz Meier b3e948d28c Update simulators 2016-10-29 00:00:33 +02:00
Julian Oes 62603bee45 simulation: SITL outputs from 0..1
Instead of sending actuator controls from -1..1 for SITL, we should send
0..1 like we already do for HIL. This will enable negative thrust in the
future, e.g. for pusher props that spin backwards, or for vehicles with
variable pitch propellers.
2016-10-28 23:56:46 +02:00
Julian Oes 0a043365ec rename gazebo_tailsitter to tailsitter
This is currently broken anyway but the new name makes more sense.
2016-10-28 23:56:46 +02:00
Carlo Wood 90f3e3b5d3 Do not include headers inside __BEGIN_DECLS ... __END_DECLS blocks.
We don't have C++ unsafe headers (anymore).

I added a test to fix_headers.sh that checks if certain "unsafe"
headers are ONLY included inside a __BEGIN_DECLS ... __END_DECLS
(because after all, they are unsafe), as well as checking that
no other header files are included inside such a block. The rationale
of the latter is that if a file is a C header and it declares
function prototypes (otherwise it doesn't matter) and is sometimes
included outside a __BEGIN_DECLS ... __END_DECLS block (from a C++
source file) then it has to be C++ safe and doesn't ever to be
included from inside such a block; while if a file is a C++ header
then obviously it should never be included from such a block.

fix_headers.sh subsequently found several safe headers to be
included from inside such a block, and those that were (apparently
in the past) unsafe were included only sometimes inside such a
block and often outside it. I had a look at those files and saw
that at least an attempt has been made to make them C++ safe,
but especially because they already are included OFTEN outside
a __BEGIN_DECLS ... __END_DECLS (from C++ source files) the
best decision seems to treat them as safe.

This is not risky: .c files that define such functions still
generate C-linkage for their functions. If a C++ unsafe C header
is included outside a __BEGIN_DECLS ... __END_DECLS block then
the only possible result would be an undefined reference to
a function with C++-linkage that will not exist. Aka, when
something links after this commit, then the commit was correct.
I did build all targets and they all linked.
2016-10-28 11:57:08 +02:00
Carlo Wood baf89f4398 Clean up of px4_defines.h (remove math.h)
This patch reorders px4_defines.h to make it more readable (I think)
but more importantly, cleans up the #include <math.h>/<cmath>
and [std::]isfinite stuff.

My main goal was to completely get rid of including math.h/cmath,
because that doesn't really belong in a header that is supposed to
define macro's and is included in almost every source file (if not
all).

I'm not sure what it did before ;) (pun intended), but now it does
the following:

PX4_ISFINITE is only used in C++ code (that was already the case,
but hereby is official; for C code just use 'isfinite()') and is
defined to be std::isfinite, except on __PX4_QURT because that uses
the HEXAGON toolset which (erroneously) defines isfinite as macro.

I would have liked to remove PX4_ISFINITE completely from the code
and just use std::isfinite whereever that is needed, but that would
have required changing the libecl submodule, and at the moment I'm
getting tired of changing submodules... so maybe something for the
future.

Also, all includes of <math.h> or <cmath> have been removed except
for __PX4_NUTTX. Like the HEXAGON toolset NuttX currently defines
isfinite as macro for C++. So, we could have solved this in the
same was as __P4_QURT; but since we can fix NuttX ourselves I chose
to add a kludge to px4_defines.h instead that fixes this problem,
until the time that NuttX can be fixed (again postponing changing
a submodule). The kludge still demands including <cmath>, thus.

After removal of the math header file, it needed to be included
in source files that actually need it, of course.

Finally, I had a look at the math macro's (like M_PI, M_PI_F,
M_DEG_TO_RAD etc). These are sometimes (erroneously) defined in
certain math.h header files (like both, hexagon and nuttx).
This is incorrect: neither the C nor the C++ standard defines
math constants (neither as macro nor otherwise). The "problem"
here was that px4_defines.h defined some of the M_*_F float
constants in terms of the M_* double constant, which are
sometimes not defined either thus. So, I cleaned this up by
defining the M_*_F math constants as float literals in px4_defines.h,
except when they are defined in math.h for that platform.
This means that math.h has to be always included when using those
constants, but well; not much difference there as those files
usually also need/use the macro NAN (which *is* a standard macro
defined by math.h).

Finally finally, DEFAULT_PARAM_FILE was removed as it isn't
used anymore.

All in all I think the resulting px4_defines.h is nice, giving me
much less the feeling of a nearly unmaintainable and over time
slowly growing collection of kludges and hacks.
2016-10-28 08:41:30 +02:00
Carlo Wood e29b9b5d39 Remove fake config targets.
The "targets" posix_rpi_common, qurt_sdflight_default and
posix_sdflight_default are not real targets; they are
just files in cmake/configs that are included by other
targets.
2016-10-28 08:40:23 +02:00
Erik Jähne ae2aeab5e4 HIL_STATE: publish control_state_msg when receive mavlink_hil_state_quaternion message 2016-10-28 08:38:18 +02:00
Carlo Wood 5b52cd0fe6 Compile fixes for old/unused targets.
These are some changes that I needed to compile
most of the unsupported targets.

After this all (make list_config_targets) compile
for me except: posix_eagle_muorb, posix_sdflight_default
and qurt_eagle_legacy_driver_default.
2016-10-26 14:00:52 +02:00
Andreas Antener 1999ed2601 Testing: use return value to check if controllib tests failed 2016-10-26 08:41:21 +02:00
Beat Küng a2c493efc7 fix vmount: initialize manual control for mavlink inputs 2016-10-26 08:40:23 +02:00
Paul Riseborough d37a927cdb ROMFS: enable use of px4flow sensor with pixracer 2016-10-25 20:31:46 +11:00
David Sidrane 7ae749090b Update NuttX submodule to use backport of ctype.h & cctype
This is the equivalent to Greg's upstream solution for ctype.h &
 cctype with the necessary shadow waning fix.
 It also deletes the Hack in pa4_defines.h
2016-10-25 08:39:09 +02:00
Mark Whitehorn 4cc97aa705 fix another bug in fmu mode 2016-10-24 18:22:18 +02:00
Beat Küng 95f5ba9635 fix mavlink_shell.py: python3 compat for octal numbers 2016-10-24 12:51:50 +02:00
Beat Küng cbbee30e48 log_writer_file: add include px4_posix.h (needed for stack size macro)
Failed with GCC 6.0.1, don't know why it worked before...
2016-10-24 10:22:48 +02:00
Beat Küng c8a79d2443 mc_pos_control_main: remove <functional> include
Avoid including <functional> which can cause problems on NuttX
2016-10-24 10:22:48 +02:00
Beat Küng 3029555016 uORBUtils: remove #include <string>
Avoid including <string> which can cause problems on NuttX
2016-10-24 10:22:48 +02:00
Beat Küng d0dace7c23 uavcan: use math::min instead of std::min
Avoid including <memory> which can cause problems on NuttX
2016-10-24 10:22:48 +02:00
Lorenz Meier f466913a32 Update MAVLink headers and adapter header to current master 2016-10-23 22:14:19 +02:00
Lorenz Meier f9abe39c3a DSM parser: Keep local copy of channel data 2016-10-23 19:58:52 +02:00
Lorenz Meier 3bed398a1e FMU: scan longer 2016-10-23 19:58:52 +02:00
Lorenz Meier 8d51e4ade1 MAVLink shell: Fix OS X default path 2016-10-23 17:46:22 +02:00
Lorenz Meier 05bc9acfb7 navigator: Wrap get time inside into function call and set time inside to zero
This ensures that the dual-use of the pitch_min / time_inside field is handled
properly between takeoff and non-takeoff items. Flight tested in SITL.
2016-10-23 16:26:03 +02:00
Lorenz Meier 5ddd69c872 Dataman: Make versioning define more explicit 2016-10-23 16:26:03 +02:00
Lorenz Meier c7cdef2a4b Clarify version flag for dataman 2016-10-23 16:26:03 +02:00
Lorenz Meier 0a4fedd778 Dataman: Use single method to infer file compatibility 2016-10-23 16:26:03 +02:00
Lorenz Meier 9e7d5f088e dataman: Ensure compat field is set and read correctly 2016-10-23 16:26:03 +02:00
Lorenz Meier ff0d7613b1 Add manual seed to dataman hash to allow later incrementing the seed number for incompatible changes 2016-10-23 16:26:03 +02:00
Lorenz Meier db774798fa Dataman: Store sizes of all containers and reset file if any of them changes. 2016-10-23 16:26:03 +02:00
Lorenz Meier c340974991 Ensure pitch min param is correctly handled 2016-10-23 16:26:03 +02:00
Lorenz Meier eaae1abdaf Simplify use of pitch_min 2016-10-23 16:26:03 +02:00
Lorenz Meier 9821499113 navigator / mission item: Compress fields into bitfield 2016-10-23 16:26:03 +02:00
Lorenz Meier 5899ce715d Navigator: Leverage overlapping fields in logic to save RAM by makeing them overlap in memory as well 2016-10-23 16:26:03 +02:00
Julian Oes 4160b65edb navigator: change default min takeoff alt to 2.5m
Fixedwing aircraft will override this with fw.defaults anyway.
2016-10-23 16:25:15 +02:00
Julian Oes 82f27884df navigator: fix wrong altitude after takeoff
This change fixes a wrong behaviour when a takeoff command is sent.

An example:
- MIS_TAKEOFF_ALT set to 10 meters
- Takeoff command with alt setpoint of 2 meters

Old behaviour:
1. Climb to 10 meters -> takeoff WP reached
2. Go to setpoint at 2 meters

New behaviour:
1. Climb to 10 meters and stay there but notify that altitude was
   overridden.
2016-10-23 16:25:15 +02:00
Julian Oes 032f4df3de mc_pos_control: revert gain change 2016-10-23 16:25:15 +02:00
Julian Oes dcd0df7d02 navigator: fix typo 2016-10-23 16:25:15 +02:00
Julian Oes 4f5fa50efb navigator: fix takeoff jump edge case
In the normal sitl `commander takeoff` case, the takeoff jump was never
actually carried out because the default altitude radius is set to 3m
and the takeoff altitude to ~2m which means that the takeoff waypoint is
"reached" immediately.

This works around this edge case by using the altitude between the home
altitude and takeoff altitude divided by 2 as a acceptance radius.
2016-10-23 16:25:15 +02:00
Julian Oes 72e46e7ed0 mc_pos_control: jump quicker
In SITL, it still takes a while until a vehicle lifts off, so it seems
sensible to raise this jump gain a bit.
2016-10-23 16:25:15 +02:00
Julian Oes ff415a4f1d mc_pos_control: correctly initialize landed state
Since orb_copy is guarded with a orb_check, we ended up not having the
corrent landed state in the beginning which could lead to some
unexpected behaviour on takeoff.
2016-10-23 16:25:15 +02:00
Pavel Kirienko 3a332bb11a Printing all online nodes within UAVCAN status output. This feature increased memory footprint by about 150 bytes. 2016-10-23 15:26:10 +02:00
Pavel Kirienko 9b0ab83f9b Fixed misuse of the preprocessor 2016-10-23 15:26:10 +02:00
Pavel Kirienko eff6a7b5d0 get_next_active_node_id() - starting from 0 2016-10-23 15:26:10 +02:00
Beat Küng 9448e0d673 vdev: remove wrong comment 2016-10-23 15:25:20 +02:00
Beat Küng f7d8612bc9 logger: enable all backends by default
This requires ~270B more RAM
2016-10-23 15:25:20 +02:00
Beat Küng 7c6d99d30f BlockParam: remove _extern_address and create a new class BlockParamExt for this
In most cases, _extern_address was unused, thus wasting cycles & RAM. This
adds a separate class BlockParamExt with the field and uses it in ekf2_main

Frees roughly 0.5KB of RAM on Pixracer
2016-10-23 15:25:20 +02:00
Beat Küng 09d8e4fd8c logger: reduce stack size, which got freed in 05a771152520
commit msg: 'logger: avoid uORB::Subscription, directly use orb_subscribe() instead'
2016-10-23 15:25:20 +02:00
Beat Küng 1bdad65849 uorb: reduce RAM usage by avoiding string copies
The lifetime of the string is guaranteed because we never delete
DeviceNode objects and the strings in question are already on the heap.

This frees roughly 2.2KB of RAM on Pixracer
2016-10-23 15:25:20 +02:00
Beat Küng 4da2ae2302 MavlinkOrbSubscription: optimize fields for size
reorder & reduce instance to uint8_t (which is more than enough).
Reduces sizeof(MavlinkOrbSubscription) from 40 to 24.

On Pixracer this frees almost 2KB of RAM
2016-10-23 15:25:20 +02:00
Beat Küng c50e4a6e21 uORB::DeviceNode: reduce the size of some members
The limits the maximum queue size to 255, which I think is ok for the
forseable future.

sizeof(uORB::DeviceNode) is reduces from 128 to 112 on NuttX, and with
~80 instances, this saves over 1KB of RAM.
2016-10-23 15:25:20 +02:00
Beat Küng 03c12c4c78 Device: use uint16_t for _open_count instead of int (save space) 2016-10-23 15:25:20 +02:00
Beat Küng a5e6f3213f Device: remove _irq_attached flag, test with _irq == 0 instead 2016-10-23 15:25:20 +02:00
Beat Küng 64df463a85 logger: avoid setting the interval for topics where not needed
Saves some RAM, although not much in that case. But all subscriptions
combined need ~1.5KB only for the interval data within uORB.
2016-10-23 15:25:20 +02:00
Beat Küng 7140914d38 logger: remove LoggerSubscription::time_tried_subscribe
Instead use a single timestamp for subscription checks. This frees up
~800B of RAM.

Also make sure the subscription checks are distributed over time. On each
update, at most 1 topic subscription is checked. Reduces the load of the
logger from 7.3% to 5.8% (Pixracer)
2016-10-23 15:25:20 +02:00
Beat Küng f244a78368 logger: avoid uORB::Subscription, directly use orb_subscribe() instead
This frees up ~160B stack size
2016-10-23 15:25:20 +02:00
Beat Küng 4120cd93df logger: make sure structs are properly aligned
ulog_message_info_header_s *msg = reinterpret_cast<ulog_message_info_header_s *>(buffer);
members of msg could end up unaligned, because of the uint8_t buffer.
2016-10-23 15:25:20 +02:00
Lorenz Meier 296b07f9d8 Update Gazebo plugin to fix plane model 2016-10-23 14:21:50 +02:00
Julian Oes 3aa9a72562 mavlink_shell.py: default to 57600 baudrate 2016-10-23 14:00:29 +02:00
Paul Riseborough 06ad477847 ekf2: publish vibration metrics 2016-10-22 12:03:05 +02:00
Paul Riseborough 79ec263b1e msg: Change definition for un-used vibration monitoring variable
Makes the message more useful in comparing the types of vibration likely to cause numerical errors and matches the update ecl library interface.
2016-10-22 12:03:05 +02:00
Paul Riseborough 6a3b147477 ecl: update library reference
Adds reporting of IMU coning and high frequency vibration levels
2016-10-22 12:03:05 +02:00
David Sidrane a2ad92b2d7 Bugfix: Hard Fault hmc5883 with not params
Fault results from if (!strcmp(verb, "start")) {``` with null verb
2016-10-22 11:54:38 +02:00
David Sidrane bdfb2bbb8d Fixed hardfault on fast proc
_baro_topic can be null in init sequence
   init call collect before the topic is inited.

I think this pattern is repeated in other drivers. I would suggest
allowing null in orb_publish to just return.
2016-10-22 11:43:22 +02:00
Siddharth Bharat Purohit b75ff417ea fmu: fix typo introduced in 78b0d1a which adds PWM1 mode 2016-10-22 08:37:13 +02:00
Carlo Wood 6fc30c76a6 Clean up of app.h
app.h, generated from app.h_in, has unnecessary code duplication
and isn't a header file (it defines globals, static functions
and doesn't have a header guard, moreover, it has a 'using namespace
std;'). Because of this, a real headerfile that declares the stuff
defined in apps.h was missing leading to even more code duplication:
scattered forward declarations in .cpp files and an often repeated
type of std::map<std::string, px4_main_t>.

This patch moves cmake/qurt/apps.h_in to src/platforms/apps.cpp.in
(with some changes) and removes cmake/posix/apps.h_in.
Then src/platforms/apps.cpp.in is split into src/platforms/apps.cpp.in
and src/platforms/apps.h.in, splitting declarations from definitions.

A typedef is defined for the map (apps_map_type).

The main difference between cmake/posix/apps.h_in and
cmake/qurt/apps.h_in was that the first defined a global 'apps',
while qurt stores the apps in QShell. I opted to get rid of
the global variable (which are in general evil for various reasons)
and used the API of cmake/qurt/apps.h_in where a provided 'apps'
map is initialized with a call to init_app_map. Thus removing
the existing code duplication.
2016-10-22 08:31:14 +02:00
Daniel Agar c200ef88ed travis-ci, circleci update to GCC 4.9 and 5.4 2016-10-20 22:01:53 -04:00
Julian Oes d57e9f13d7 px_uploader.py: catch exception in except block
This could lead to an exception if serial is not available.
2016-10-20 23:18:56 +02:00
Julian Oes d1822699a9 px_uploader.py: remove unused variable 2016-10-20 23:18:56 +02:00
Julian Oes a14c565ab1 px_uploader.py: trailing whitespace 2016-10-20 23:18:56 +02:00
Julian Oes 78b0d1a01f tap: add landing gear capability
This configures the PWM output for the landing gear.
2016-10-20 23:17:05 +02:00
Julian Oes 2fff2ab9ac Add switch for landing gear, pass it to actuators 2016-10-20 23:17:05 +02:00
Beat Küng 10c4ec2e1a update gps submodule 2016-10-20 21:12:11 +02:00
Beat Küng 0002e86b6f jmavsim_run.sh: add additional arguments for HITL 2016-10-20 18:54:47 +02:00
Beat Küng 7ed81e5edb simulator_mavlink: send MAV_CMD_SET_MESSAGE_INTERVAL to enable ground truth 2016-10-20 18:54:47 +02:00
Beat Küng 7415d94e12 mavlink: don't publish HIL_CONTROLS in HIL mode
it generates unnecessary load. If really needed, it can still be enabled
manually.
2016-10-20 18:54:47 +02:00
Daniel Agar 3fda48517d travis-ci git clone depth 1000 2016-10-19 20:31:56 -04:00
Lorenz Meier 7b2898eaee Fix merge collision 2016-10-19 18:29:34 +02:00
Lorenz Meier 3f5f74399e Increased SBUS buffer size for more reliable SBUS and DSM parsing 2016-10-19 15:32:30 +02:00
Lorenz Meier f7f406c45d Expand RC test to 2nd receiver with 12 channels 2016-10-19 15:31:54 +02:00
Lorenz Meier 6f7a5cdf9b Add additional DSM test data 2016-10-19 15:31:54 +02:00
Beat Küng 210b5704a9 px4fmu_common rcS: fix MAVLINK_F test
fixes a 'test: syntax error' message on startup. There were two problems:
- the expansion of $MAVLINK_F lead to multiple arguments in the test
  when the variable contained spaces. Fixed with ""
- the x prevents interpretation as a unary expression, if $MAVLINK_F starts
  with a - character (in that case the expansion would be:
  if [ -r 1200 ... and nsh interprets - as unary expression)
2016-10-19 15:27:09 +02:00
Beat Küng 3bb479f72e ulog mavlink: use the px4_sem calls (needed for OSX) 2016-10-19 13:13:47 +02:00
Beat Küng 7c40c8dfd9 update mavlink submodules 2016-10-19 13:13:47 +02:00
Beat Küng 9272aa592a logwriter: fix shadowing compiler warnings 2016-10-19 13:13:47 +02:00
Beat Küng b2d45732c2 system_params: add missing crazyflie to the param description 2016-10-19 13:13:47 +02:00
Beat Küng 318c970477 mavlink ulog streaming: add rate limiting
This limits the maximum bandwidth of ulog streaming to 70% of the specified
mavlink datarate. If less is used, the leftover is assigned to the mavlink
streams, if more is used, it starts to drop.

mavlink status outputs the currently used rate, to check if a link is
saturated.
2016-10-19 13:13:47 +02:00
Beat Küng 8f5656f033 mavlink ulog: add target sys & component ids (update to changed mavlink message) 2016-10-19 13:13:47 +02:00
Beat Küng 326800e5a8 logger: increase stack size
evaluated with: logger start -e -t -m all
and then make sure to get an error printf in the mavlink writer backend,
eg. for an ack timeout.
2016-10-19 13:13:47 +02:00
Beat Küng 8e0d548f51 logger: increase default queue size for mavlink logging to 14
tested on Pixracer: 14 still produces some dropouts once in a while, but I
think it's a fair tradefoff between RAM usage & dropouts. The queue needs
about 3.5KB of RAM.

When topic sizes/logging rates change, this will have to be reevaluated.
2016-10-19 13:13:47 +02:00
Beat Küng 6999bb3e9a Tools: add mavlink_ulog_streaming.py script to stream ULog via MAVLink to a file 2016-10-19 13:13:47 +02:00
Beat Küng 7d72f31a29 mavlink: integrate MavlinkULog into the main Mavlink task & receiver 2016-10-19 13:13:47 +02:00
Beat Küng 57d85de4d1 mavlink: add MavlinkULog class to receive ulog data from the logger 2016-10-19 13:13:47 +02:00
Beat Küng f29a50df31 logger: add support for mavlink backend in Logger class, handle start/stop 2016-10-19 13:13:47 +02:00
Beat Küng 2dc59efbb6 logger: add mavlink write backend 2016-10-19 13:13:47 +02:00
Beat Küng b7d07d77d6 msg files: add ulog_stream & ulog_stream_ack 2016-10-19 13:13:47 +02:00
Beat Küng b233753e23 logger: don't exit if directory creation failed & mavlink mode enabled 2016-10-19 13:13:47 +02:00
Beat Küng 8ea38bc278 logger: better status output with configured backend mode 2016-10-19 13:13:47 +02:00
Beat Küng 7a60c1296e logger: re-use subscribed topic id's, only set them once on first use
Will be necessary when using multiple backends in parallel.
2016-10-19 13:13:47 +02:00
Beat Küng 12ded377d1 refactor logger: add need_reliable_transfer flag, remove write_wait 2016-10-19 13:13:47 +02:00
Beat Küng de20f1778e logger: add -m <mode> and -q <queue_size> parameters, prepare for mavlink backend 2016-10-19 13:13:47 +02:00
Beat Küng 1ddddccb81 logger: move thread start/stop logic into LogWriterFile 2016-10-19 13:13:47 +02:00
Beat Küng 78f19fccce replay: remove unneeded include <logger/logger.h> 2016-10-19 13:13:47 +02:00
Beat Küng ccdaabc7fb refactor logger: prepare for multiple write backends 2016-10-19 13:13:47 +02:00
Beat Küng 4e1a4440ca logger: remove _enabled attribute and add LogWriter::is_started() instead 2016-10-19 13:13:47 +02:00
Beat Küng c26e29d11c logger: move writer_thread variable into function (never accessed outside) 2016-10-19 13:13:47 +02:00
Lorenz Meier 14b0511c6c MC pos control multiplatform style fix. 2016-10-19 10:17:41 +02:00
Lorenz Meier 21bc78dedc Update ROS att estimator and remove unused rotation matrix 2016-10-19 10:17:41 +02:00
Lorenz Meier 3696e7722a Code style adjustments 2016-10-19 10:17:41 +02:00
Lorenz Meier a12780c88f Remove attitude setpoint matrix from attitude setpoint topic 2016-10-19 10:17:41 +02:00
Lorenz Meier 5317d29ffd Disable blinkm for FMUv2 2016-10-19 09:25:55 +02:00
Julian Oes af5d2c488c st24: fix RC lost detection based on error count
The packet_count was actually an error_count, therefore we should
process RC input only when the error_count since the last packet is 0.

Also, this commit fixes the RSSI scaling for st24.
2016-10-19 09:22:57 +02:00
Michael Schaeuble ffaed18e67 Reduce the binary size Bebop
The firmware binary is to large to fit into the onboard memory of the Parrot
Bebop. It could be uploaded to the emmc, but for ease of use it would be nice
to have it in /usr/bin. To strip the binary seems to be the best option right now.
2016-10-18 23:56:56 +02:00
Lorenz Meier ffe4c77dc9 vmount: Params do not need to be built 2016-10-18 20:50:09 +02:00
Michael Schaeuble 062df05865 Add __PX4_POSIX_BEBOP define to PreflightCheck.cpp 2016-10-18 20:48:17 +02:00
Carlo Wood 2c23aa4348 Avoid compile error for posix_rpi_common/native.
Fixes,
error: ignoring return value of ‘ssize_t write(int, const void*,
size_t)’, declared with attribute warn_unused_result
[-Werror=unused-result]
2016-10-18 20:47:59 +02:00
Michael Schaeuble 9bb230fa3d Remove obsolete linker flag for Bebop build
The pthread linker flags were changed in c6a2641 and it was questioned in #5504 if the
exception for the Bebop is necessary. It is not, so remove those lines from the cmake
file.
2016-10-18 20:47:19 +02:00
Lorenz Meier 43d8e5710c Remove unused q_e flag 2016-10-18 20:46:08 +02:00
Roman 7a7bf2205d ekf2_replay: compute euler angles for logging
Signed-off-by: Roman <bapstroman@gmail.com>
2016-10-18 20:46:08 +02:00
Roman 17a4b64434 old ekf: fix computation of rotation matrix
Signed-off-by: Roman <bapstroman@gmail.com>
2016-10-18 20:46:08 +02:00
Roman 7c2ebd96a0 lpe: remove usage of euler angles from attitude topic
Signed-off-by: Roman <bapstroman@gmail.com>
2016-10-18 20:46:08 +02:00
Roman 06931e12cf mc_pos_control_mulitplatform: cleanup of matrix usage
Signed-off-by: Roman <bapstroman@gmail.com>
2016-10-18 20:46:08 +02:00
Roman d086a348aa rover steering example: fixed compile error
Signed-off-by: Roman <bapstroman@gmail.com>
2016-10-18 20:46:08 +02:00
Roman 7cb06c01eb attitude_estimator_ekf: fixed quaternion computation from dcm
Signed-off-by: Roman <bapstroman@gmail.com>
2016-10-18 20:46:08 +02:00
Roman 51941b0af8 rover_steering_control: fixed comment
Signed-off-by: Roman <bapstroman@gmail.com>
2016-10-18 20:46:08 +02:00
Roman a978d61d9a attitude message cleanup: more cleanup
Signed-off-by: Roman <bapstroman@gmail.com>
2016-10-18 20:46:08 +02:00
Roman 3faaeb06d1 attitude setpoint topic: cleanup of matrix class usage
Signed-off-by: Roman <bapstroman@gmail.com>
2016-10-18 20:46:08 +02:00
Lorenz Meier ee314d2f50 Remove unused gx, gy, gz fields from attitude 2016-10-18 20:46:08 +02:00
Lorenz Meier f1e5fe9b39 Fix isfinite compilation for fixed wing example 2016-10-18 20:46:08 +02:00
Lorenz Meier 57f193174c Fix mc att control multiplatform 2016-10-18 20:46:08 +02:00
Lorenz Meier b035b6a112 Remove non-quaternion handling for ROS attitude 2016-10-18 20:46:08 +02:00
Lorenz Meier 5d9c91dece Convert fixed wing example to quaternions 2016-10-18 20:46:08 +02:00
Lorenz Meier 526fb8f515 Remove q_valid flag from attitude topic 2016-10-18 20:46:08 +02:00
Beat Küng d349bd570f ekf examples: remove unused variable 2016-10-18 20:46:08 +02:00
Lorenz Meier 0bd42402fb Sim: Remove euler angles 2016-10-18 20:46:08 +02:00
Lorenz Meier 13833e5fd6 LPE: Use euler angles derived from quaternion 2016-10-18 20:46:08 +02:00
Lorenz Meier ac936a28dd Update examples 2016-10-18 20:46:08 +02:00
Lorenz Meier 873ed17b14 VMount: Do not rely on euler angles 2016-10-18 20:46:08 +02:00
Lorenz Meier affefcc75e Attitude: Remove redundant timestamp 2016-10-18 20:46:08 +02:00
tumbili 56b2fd0257 fixed rover example 2016-10-18 20:46:08 +02:00
tumbili 38b949a5aa calculate euler angles for logging 2016-10-18 20:46:08 +02:00
tumbili 0d0fa133e6 remove comments 2016-10-18 20:46:08 +02:00
Roman eb18622d85 added old ekf attitude estimator back to config and made changes so it compiles 2016-10-18 20:46:08 +02:00
Roman b8a219d351 removed comments and fixed some euler bugs 2016-10-18 20:46:08 +02:00
tumbili 5e0e522903 adapted to new vehicle attitude message 2016-10-18 20:46:08 +02:00
tumbili 215bfaa377 clean up vehicle attitude message 2016-10-18 20:46:08 +02:00
Lorenz Meier 78c52be08c Minoor nitpick in README 2016-10-18 08:07:14 +02:00
Julian Oes e2c308c4e6 cmake: fixes for cmake_hexagon changes 2016-10-18 08:07:14 +02:00
Julian Oes 340b9002e2 sdflight_default: define QC_SOC_TARGET if not set 2016-10-18 08:07:14 +02:00
Julian Oes b5b077ae04 DriverFramework: update submodule once again 2016-10-18 08:07:14 +02:00
Julian Oes 75657dc2eb cmake: add __DF_ defines with comments 2016-10-18 08:07:14 +02:00
Julian Oes 0a4ca7c77f cmake/DriverFramework: update submodules again 2016-10-18 08:07:14 +02:00
Julian Oes f8a1631077 DriverFramework/cmake_hexagon: use defines with DF
This changes the following defines:

__QURT -> __DF_QURT
__RPI -> __DF_RPI
__EDISON -> __DF_EDISON
__BEBOP -> __DF_BEBOP
__LINUX -> __DF_LINUX
2016-10-18 08:07:14 +02:00
Lorenz Meier e4398c7088 Update ECL to include a fix for height reset 2016-10-18 08:00:13 +02:00
Lorenz Meier c2285c84a9 Dataman: Do nnot pack structs to avoid reading back wrong values on existing systems 2016-10-18 00:26:40 +02:00
David Sidrane ecbe8c2179 Packed union to save more space 2016-10-18 00:23:58 +02:00
David Sidrane 86ec703620 Left test_dataman out by default - as it was prior 2016-10-18 00:23:58 +02:00
David Sidrane bb71aa5b64 Revive test_dataman.c 2016-10-18 00:23:58 +02:00
David Sidrane b2bf9e15eb Use union of datatypes supported by dataman to reduce wasted space 2016-10-18 00:23:58 +02:00
David Sidrane b1e94b98b3 Define tap as a Memory Constrained system 2016-10-18 00:23:58 +02:00
David Sidrane 44b5b52bcb Add suport for Memory Constrained systems 2016-10-18 00:23:58 +02:00
David Sidrane 979381fcfa Support passing defines from top level config makefile 2016-10-18 00:23:58 +02:00
David Sidrane 24e20b2cec Changed public interface comments to Doxyagen style 2016-10-18 00:23:58 +02:00
David Sidrane 1152b68a28 Use RAM storage in dataman 2016-10-18 00:23:58 +02:00
David Sidrane dce2262243 Add in RAM storage to dataman 2016-10-18 00:23:58 +02:00
Lorenz Meier 0544a6ee32 Upgrade NuttX submodule 2016-10-17 22:55:31 +02:00
James Goppert e73218c112 Increase min agl for flow from 5 to 30 cm to prevent drift on ground. 2016-10-16 12:12:19 -04:00
Julian Oes cd937321c8 px_mkfw.py: fix indent (fix for Python 3) 2016-10-15 22:01:22 +02:00
Julian Oes 7eabf1ccb3 px_mkfw.py: remove unused import 2016-10-15 22:01:22 +02:00
Julian Oes 8450178849 mavlink: move MAV_CMDs according to value 2016-10-15 12:37:06 +02:00
Julian Oes 9842e49dc6 navigator/mavlink: photos and videos at waypoints
This adds the capability to forward the commands
- MAV_CMD_VIDEO_START_CAPTURE
- MAV_CMD_VIDEO_STOP_CAPTURE
- MAV_CMD_IMAGE_START_CAPTURE
- MAV_CMD_IMAGE_STOP_CAPTURE
at waypoints which will then be sent over mavlink to component id
100 aka MAV_COMP_ID_CAMERA.
2016-10-15 12:37:06 +02:00
Paul Riseborough eb51184bbd msg: Update estimator_status documentation 2016-10-15 12:00:49 +02:00
Julian Oes 2d039af7a4 sitl_gazebo: update submodule yet again
This fixes the build for Gazebo >= 7.4.
2016-10-14 20:38:29 +02:00
mantelt 8bbc1b8472 navio_sysfs_rc_in: Fixing logical expression
navio_sysfs_rc_in stop works now.
2016-10-14 15:38:36 +02:00
Julian Oes 36b2e4be09 sitl_gazebo: update submodule 2016-10-14 14:47:53 +02:00
James Goppert 9c82293bc4 Fix comment. 2016-10-14 07:00:13 -05:00
James Goppert 3ffff212e1 Added landed agl correction for lpe. 2016-10-14 07:00:13 -05:00
Paul Riseborough 35bf165190 ekf2_replay: fix code style 2016-10-13 09:06:41 +02:00
Paul Riseborough 02c3ea0a5b ekf2_replay: log output predictor tracking errors 2016-10-13 09:06:41 +02:00
Paul Riseborough 865b6404ec ekf2: reduce default output predictor time constant 2016-10-13 09:06:41 +02:00
Paul Riseborough ed0cc2af43 sdlog2: log ekf output predictor tracking errors 2016-10-13 09:06:41 +02:00
Paul Riseborough 7a9e3002ff ekf2: publish output predictor tracking errors 2016-10-13 09:06:41 +02:00
Paul Riseborough 23a379a6bf msg: add output predictor tracking errors to innovation message 2016-10-13 09:06:41 +02:00
James Goppert dbd94907c4 Only send failsafe info messages on state change. 2016-10-13 01:57:00 -04:00
James Goppert 43b665ae01 Fix gps circuit breaker logic in state machine. 2016-10-12 23:07:26 -05:00
James Goppert cf658638f4 LPE flow improvements. 2016-10-12 23:05:53 -05:00
David Sidrane db44129ec0 Prevents the posibility of buffer overflow in mixer parsing.
The fix limits scanf from overwritting the geomname buffer local
variable. Thus preventing stack corruption as noted by chungkim.
2016-10-12 22:58:55 +02:00
James Goppert f30dd2b819 Removed lidarlite driver, not widely available. 2016-10-12 11:59:46 -05:00
James Goppert 027badc340 Remove bottle/rover apps from v1 to reduce flash space. 2016-10-12 11:59:46 -05:00
Lorenz Meier 1cb180728e Disable vectorcontrol ESC firmware as they still are not really available on the market 2016-10-12 09:27:02 +02:00
Lorenz Meier c6015e65d0 Update ECL to include a reset fix 2016-10-12 08:55:36 +02:00
Lorenz Meier b4e85d1273 Update ECL to include a status reporting fix 2016-10-12 08:53:00 +02:00
Lorenz Meier 569cceb059 Fix task load measurement in NuttX. Reported by @chungkim. Fixes #5645. 2016-10-12 08:43:45 +02:00
Daniel Agar e9bce5dd71 eclipse project file updates
-properly index ECL and generated uORB
2016-10-11 21:25:58 -04:00
Lorenz Meier 69551141b7 Updated SITL 2016-10-12 00:32:59 +02:00
Beat Küng c87933d556 navigator: cleanup output messages (don't use warnx) 2016-10-11 13:10:43 +02:00
Julian Oes 7cdf9c31bf navigator: usual usleep after poll fail
We don't want to busy loop after the poll fail if that ever happened.
2016-10-11 13:05:37 +02:00
Julian Oes f6ad9b8283 navigator: only poll for position
We don't need to poll for vehicle commands, we will get them anyway by
doing orb_check. Also, the polling for them wasn't implemented correctly
anyway.
2016-10-11 13:05:37 +02:00
Paul Riseborough d80a233bcb ekf2: fix code style 2016-10-11 08:52:35 +02:00
Paul Riseborough bef4850ae3 mavlink: Publish estimator solution status flags 2016-10-11 08:52:35 +02:00
Paul Riseborough 6eabf80f2a ekf2: Publish estimator solution status flags 2016-10-11 08:52:35 +02:00
Paul Riseborough fa47569aa5 msg: Add EKF solution status flags to estimator status message 2016-10-11 08:52:35 +02:00
Paul Riseborough b6d69ca3aa mavlink: Add ESTIMATOR_STATUS accuracy data 2016-10-11 08:52:35 +02:00
Paul Riseborough c0fe08a203 ekf2: publish estimator status position accuracy 2016-10-11 08:52:35 +02:00
Paul Riseborough bc530ea992 mavlink: add missing data to ESTIMATOR_STATUS message 2016-10-11 08:52:35 +02:00
Paul Riseborough 66e887e581 sdlog2: log estimator innovation test pass/fail data 2016-10-11 08:52:35 +02:00
Paul Riseborough 5a69f4560a ekf2: Publish innovation test status data 2016-10-11 08:52:35 +02:00
Paul Riseborough 2bda15d72b msg: Add innovation test data to estimator status 2016-10-11 08:52:35 +02:00
Paul Riseborough ad65e56f47 ecl: update submodule reference 2016-10-11 08:52:35 +02:00
Daniel Agar e9e15ba3d1 Makefile error preventing px4fmu-v4_default build
-fixes #5625
2016-10-10 22:47:28 -04:00
Andreas Antener f3b5c243e5 UT: added method to test float values
MC pos control tests: added tests to all configs that include them
2016-10-10 23:05:44 +02:00
Andreas Antener 9a219da9c2 Refactored cross sphere line tracking and added a unittest to verify correct operation 2016-10-10 23:05:44 +02:00
Andreas Antener c2e0246650 MC pos control: realize when we are on the trajectory but passed the target waypoint 2016-10-10 23:05:44 +02:00
Lorenz Meier 710a8e8f56 Commander: ensure hysteresis init 2016-10-10 22:47:07 +02:00
Julian Oes 0f763768b1 commander: don't auto-disarm as fast if not flown
It was found inconvenient that auto-disarm triggers too quickly right
after arming when the vehicle has not actually taken off yet.

Therefore, the auto-disarm takes now by a factor of 5 longer if the
vehicle has not taken off yet.
2016-10-10 22:47:07 +02:00
Gregory ddea179e95 Adding support for 19200 and 38400 baud TELEM2 2016-10-10 22:24:17 +02:00
Daniel Agar 2771b92dc0 px4fmu trivial style fix 2016-10-09 23:47:09 -04:00
Daniel Agar cdc1c5c7a4 travis-ci and circleci update docker tag 2016-10-09 23:47:09 -04:00
Lorenz Meier ed62957474 Increase RC buffer size 2016-10-08 17:18:06 +02:00
Lorenz Meier 4cfd84b56a FMU driver: Ensure correct binding pulses for Spektrum, time out any receiver which has more than one second no signal. 2016-10-08 16:56:04 +02:00
Lorenz Meier 9d2b5b1c28 Always start MAVLink, never default UART to serial 2016-10-08 16:53:31 +02:00
Mark Whitehorn a56d50599d subscribe to vehicle_command topic and implement RX_PAIR command
add spektrum satellite bind command to fmu

open fmu file descriptor to issue ioctl
2016-10-08 16:19:45 +02:00
Lorenz Meier 605cffc230 Fix sensor rail reset on Pixracer. Increase the reset duration to 50 ms to ensure the sensor power has bled off. 2016-10-08 16:18:48 +02:00
Beat Küng e73cd08a30 syslink_bridge: return state instead of 0 2016-10-07 13:26:58 +02:00
Beat Küng 55bff206be mission: add NAV_CMD_DO_SET_ROI & NAV_CMD_ROI 2016-10-07 10:57:26 +02:00
David Sidrane 248cd45503 Added missig can_devinit prototype
The Nuttx CAN driver is not used with UAVCAN. However to
facilitate compilation to allow the Nuttx CAN Example to be
compiled and linked, the missing proto type was needed.

Futhermore to include the NuttX CAN eaxample the following changes
are needed:

1 ) In cmake/configs/<target>.cmake
Add can to config_extra_builtin_cmds as:

set(config_extra_builtin_cmds
        serdis
        sercon
        can
        )

Add:
add_custom_target(can)
set_target_properties(can PROPERTIES
       PRIORITY "SCHED_PRIORITY_DEFAULT"
       MAIN "can" STACK_MAIN "2048"
       COMPILE_FLAGS "-Os")

2) Update the nuttx-configs/<target>/nsh/defconfig

Run make oldconfig and make menuconfig and set the follwoing:
CONFIG_CAN=y
CONFIG_STM32_CAN1=y or CONFIG_STM32_CAN2=y
CONFIG_CAN_EXTID=y
CONFIG_CAN1_BAUD=250000
CONFIG_CAN_FIFOSIZE=8
CONFIG_CAN_NPENDINGRTR=4
CONFIG_EXAMPLES_CAN=y
2016-10-06 19:02:51 +02:00
David Sidrane 1c766aef12 Removed comments to allow appconfigs to bring in can
Removed the commented body of the 'if CONFIG_CAN' in the appconfigs
2016-10-06 19:02:51 +02:00
Gene 5cd85b98c2 Fixed app args buffer overrun in qurt px4_layer main.cpp and qshell.cpp 2016-10-06 11:06:57 +02:00
Lorenz Meier f543463349 Disable FrSky for FMUv2 2016-10-06 09:11:26 +02:00
Beat Küng 9ceb5a7e2e mavlink: extend status output 2016-10-06 09:01:57 +02:00
Beat Küng bad107a374 navio_sysfs_pwm_out: avoid dynamic memory allocation & fix a memory leak
memory leak was in send_outputs_pwm()
2016-10-06 09:01:25 +02:00
Beat Küng b864983c5e navio_sysfs_rc_in: avoid dynamic memory allocation for path 2016-10-06 09:01:25 +02:00
Beat Küng a42f0f5a62 gps: fix code style 2016-10-06 09:00:09 +02:00
Beat Küng 6d0288d494 gps: update submodule 2016-10-06 09:00:09 +02:00
Beat Küng 80771ce8b3 gps: remove gps_driver_interface_t and use GPSHelper::Interface instead 2016-10-06 09:00:09 +02:00
Miguel Arroyo c6f43689e7 Adds Auto Mode Scanning 2016-10-06 09:00:09 +02:00
Miguel Arroyo 2799525462 Commandline Interface and Mode options 2016-10-06 09:00:09 +02:00
Hidenori 9bd3f6c9bf Navio: Delete (wrong) unnecessary ifdef and modify for new GPSDriverUBX constructor 2016-10-06 09:00:09 +02:00
Hidenori e7b582502a Navio: change the GPS device 2016-10-06 09:00:09 +02:00
Hidenori 96a5baa12b Navio: fix style 2016-10-06 09:00:09 +02:00
Hidenori 56ef984529 Navio2: modify for SPI-connected GPS and fix bug in GPIO driver 2016-10-06 09:00:09 +02:00
José Roberto de Souza b9728ecf39 Uploader tool: Add option to set different baudrates for bootloader and flight stack
By default the baudrate in flight stack (Mavlink or NSH) 57600 and the default
baudrate of bootloader is 115200. So we may need to set different
baudrates.
2016-10-05 11:25:14 +02:00
José Roberto de Souza 7e0946466e Uploader tool: Reboot board and keep it in bootloader
The Mavlink reboot messages was only requesting the board to reboot.
If the flashed bootloader has a small or no timeout user will
never be able to update firmware.
2016-10-05 11:25:14 +02:00
Michael Schaeuble 6bb03f3665 Add pitch angle to AK8963 for Bebop 2016-10-05 09:56:54 +02:00
Nate Weibley bc44ba2907 Fix QtCreator auto whitespace formatting 2016-10-05 08:58:57 +02:00
Nate Weibley 71e87cf287 Set maximum publishing rate to match MPU6000
The integrators were set to publish at 800Hz which was overwhelming
the CPU with the EKF running. This brings them in line with what we
get from the MPU6k device.
2016-10-05 08:58:57 +02:00
Nate Weibley fde165b4f1 Fix 2000dps gyro rate setbits 2016-10-05 08:58:57 +02:00
Nate Weibley 57d7a00261 Set BMI160 bus speed to 10MHz
Unliked the MPU6000 from which this driver was based, the bosch
sensor does not have a requirement to handle registers at different
speeds.
2016-10-05 08:58:57 +02:00
Glenn Bitar 6d41ab9e16 Fixed order of arguments in px4_task_spawn_cmd.
Fixes #5601
2016-10-05 08:34:58 +02:00
Beat Küng c81a1631ec simulator_mavlink: init hil_attitude with 0 & set angular speed 2016-10-04 12:56:25 +02:00
Mark Whitehorn 9500b7f01f update submodule 2016-10-04 12:54:58 +02:00
Mark Whitehorn ec1609350f fix jMAVSim body-fixed XYZ Euler Angles 2016-10-04 12:54:58 +02:00
Lorenz Meier 29a4113ce3 MAVLink app: Handle reboot command properly on COMMAND_INT 2016-10-03 22:35:07 +02:00
James Goppert cb5728297e LPE fix to enable visual odom. only navigation. (#5588) 2016-10-03 14:58:02 -04:00
Daniel Agar 03bfcae351 circleci better manual submodules clean (#5590) 2016-10-03 12:59:40 -04:00
James Goppert 7c2798269c Added vision delay compensation to LPE. (#5585) 2016-10-03 02:28:46 -04:00
bharathr 2f6abf26a3 Updated mainapp.config for 200qx and 210qc airframes (based off the generic flight version) 2016-10-02 16:06:08 +02:00
Lorenz Meier c24046ca5b FMUv1: Save resources in config 2016-10-02 11:50:34 +02:00
Lorenz Meier 93ad4fa440 rcS: The param save command is unnecessary as param set already stores to disk. 2016-10-02 11:29:53 +02:00
Artem Sabadyr 74b2780874 GPS driver: use FIONREAD on NuttX only 2016-10-02 11:19:55 +02:00
Artem Sabadyr 4c04b7bb53 gps read optimization 2016-10-02 11:19:47 +02:00
James Goppert fe40e9cfae LPE vision estimation fixes. (#5505) 2016-10-01 09:02:12 -04:00
James Goppert f6bed6f2d2 Update sitl gazebo. 2016-10-01 08:25:49 -04:00
James Goppert 91f92aa7d3 Update sitl gazebo. (#5580) 2016-10-01 07:58:56 -04:00
nephen 0027333e6d add pci-Bitcraze to px4_base.cmake 2016-09-30 23:06:57 +02:00
Roman cf8f484868 mixer class: updated comments on slew rate limit method
Signed-off-by: Roman <bapstroman@gmail.com>
2016-09-30 13:55:53 +02:00
Roman c2a511d81d multirotor mixer slew rate limiting: naming and fixes
- avoid dividing by zero when calculating max delta output
- better comments when calculating max delta output
- better naming of functions and variables

Signed-off-by: Roman <bapstroman@gmail.com>
2016-09-30 13:55:53 +02:00
Roman cced6fc8b2 multirotor mixer: use correct version of delete operator for array pointer
Signed-off-by: Roman <bapstroman@gmail.com>
2016-09-30 13:55:53 +02:00
Roman 8b889caa33 slew rate limiting: implemented for fmu
Signed-off-by: Roman <bapstroman@gmail.com>
2016-09-30 13:55:53 +02:00
Roman 2607769470 slew rate limiting: moved logic to multirotor mixer
Signed-off-by: Roman <bapstroman@gmail.com>
2016-09-30 13:55:53 +02:00
Roman 66ddea01d1 implemented slew-rate 2016-09-30 13:55:53 +02:00
Beat Küng b6b8892606 hrt_queue: add px4_posix.h include for px4_getpid() 2016-09-30 13:50:51 +02:00
Beat Küng 489f63a3d3 rc_check: replace mavlink_and_console_log_critical with mavlink_log_critical
these functions got merged.
2016-09-30 13:50:51 +02:00
Beat Küng 76733ce54b uorb tests: move orb metadata struct definition into cpp file
If they're in the header and the header is used in multiple .cpp, there
are multiple definitions. Oddly it did not lead to an error, but there
were multiple structs of the same topic but with different adresses.
This lead to a metadata mismatch, when running eg:
uorb_tests
uorb_tests latency_test
2016-09-30 13:50:51 +02:00
Beat Küng 549d456ec7 uorb devices: set errno on write error 2016-09-30 13:50:51 +02:00
Beat Küng e061842219 posix main: only try to generate symlinks if data path argument given
if not given, the dirs are either not needed (eg RPI) or assumed to
exist already
2016-09-30 13:50:51 +02:00
Beat Küng 98ac60e3fd Tools: remove unused scripts {posix,qurt}_apps.py
These were replaced by cmake, with the template cmake/posix/apps.h_in
2016-09-30 13:50:51 +02:00
Beat Küng 50b8ed0a89 commander: initialize gps & baro as failure state
This avoids error messages on startup.
2016-09-30 13:50:51 +02:00
Beat Küng ce0d31b7d9 mavlink log: ensure all critical & emergency msgs are also logged to console & ulog
Critical messages that the user sees should also go to the log file, so
that the exact error (with time) can later be analyzed from the log file.
2016-09-30 13:50:51 +02:00
Beat Küng 241fd629ce ERROR macro: get rid of the many 'oddly, ERROR is not defined for c++', use PX4_ERROR 2016-09-30 13:50:51 +02:00
Beat Küng c606554da3 PreflightCheck.cpp: use __PX4_POSIX_RPI instead of __LINUX for RPI 2016-09-30 13:50:51 +02:00
Beat Küng cf5338df02 accelsim: lower publisher rate to 250Hz 2016-09-30 13:50:51 +02:00
Beat Küng 27aaf244af fix accelsim: ACC_READ cannot be 0 (it's used to check if a bit is set)
before that, accel data was all 0, but since the gyrosim also publishes
accel data, it was not a problem.
2016-09-30 13:50:51 +02:00
Beat Küng d7ed47e2e5 px4_posix_tasks.cpp: make sure to copy the thread name into the thread data struct
The thread name is used from within the entry of the new thread, but the
provided name could live on the stack of the caller thread. Thus we need to
copy the name.
2016-09-30 13:50:51 +02:00
Beat Küng ac189704ed simulator: flush output after waiting message output
Just to make sure the user sees the message.
2016-09-30 13:50:51 +02:00
Beat Küng f25947b964 hrt_work_queue posix: only send a wake-up signal if not called from own thread
The simulated timer interrupt always adds a new scheduled work task, which
is called from the work queue thread. Sending the signal creates measurable
overhead (~5% of the px4 CPU runtime) and is unnecessary, since the thread
is not sleeping anyway.
2016-09-30 13:50:51 +02:00
Beat Küng 1d111cb254 px4_getpid: return the taskmap index instead of pthread_self()
this makes it consistent with other functions, like px4_task_spawn_cmd()
and px4_task_kill()
2016-09-30 13:50:51 +02:00
Beat Küng a51d1bc5dc jmavsim_run.sh: add optional -p <port> argument 2016-09-30 13:50:51 +02:00
Beat Küng 35e93c24e8 fix sitl_multiple_run.sh: adapt to path updates 2016-09-30 13:50:51 +02:00
Julian Oes 763d2d0447 ecl: point to interim branch for now 2016-09-30 09:25:26 +02:00
Lorenz Meier 17a1d31b79 Update L1 controller stack 2016-09-30 09:16:36 +02:00
Lorenz Meier 69f6708f37 Increase sensors stack 2016-09-30 09:16:36 +02:00
Julian Oes 7f8f6c3879 ecl: updated submodule again 2016-09-30 08:11:51 +02:00
Julian Oes b1708f3871 cmake: only optimize for size on NuttX
With this change only builds for NuttX which are very much flash size
constraint are optimized for size. All other builds (e.g. SITL,
Snapdragon, etc.) are left at the default for debugging or -O2 for the
usual use.
2016-09-30 08:11:51 +02:00
Julian Oes 8ff237c69f Remove size optimization for individual modules
It makes more sense to set the optimization flags on a platform basis
instead of individually for each module. This allows for different
optimization options for SITL, NuttX, Snapdragon, etc.
2016-09-30 08:11:51 +02:00
Julian Oes aa6d9e363f mavlink: fix a shadowing warning 2016-09-30 08:02:55 +02:00
Julian Oes ab4441c00b mavlink: add comment for Snapdragon 2016-09-30 08:02:55 +02:00
Julian Oes 1b69f9cb23 mavlink: don't miss first vehicle_command_ack
This fixes a corner case where the first advertise/publish of a
vehicle_command_ack was missed. What happened was that the
orb_subscribe_multi was not called until the topic had been published
and therefore orb_exists was happy. This means that by the time
orb_subscribe_multi was finally called, the first vehicle_command_ack
was already history and not detected by orb_check.

This changed adds a flag to the MavlinkOrbSubscription which tells it to
subscribe to a topic from the beginning.
2016-09-30 08:02:55 +02:00
Julian Oes 158a0be6c4 commander: whitespace fix 2016-09-30 08:02:55 +02:00
Beat Küng 1eca97757c sitl_run.sh: fix $rootfs not set (needed for efk2 replay) 2016-09-29 10:53:33 +02:00
Beat Küng bb61144efc cmake: add posix_sitl_inav target 2016-09-29 07:28:03 +02:00
Daniel Agar acc1cc3158 travis-ci fix s3 deploy (#5564)
- deploy all branches to s3
2016-09-29 00:10:29 -04:00
Beat Küng 92d160c431 uorb devices: fix for QuRT which has no poll() 2016-09-28 15:31:52 +02:00
Beat Küng 219ab519e3 uorb devices: rename queue_size() & meta() to avoid member shadowing 2016-09-28 15:31:52 +02:00
Beat Küng d1850f5112 uorb top: measure the elapsed time to give more accurate results 2016-09-28 15:31:52 +02:00
Beat Küng 52dde93a31 uorb: merge nuttx & posix files 2016-09-28 15:31:52 +02:00
Beat Küng f601428e82 uorb: add ifdef's where necessary to mitigate diffs between nuttx & posix
now the files are equal
2016-09-28 15:31:52 +02:00
Beat Küng f5654511b8 uorb: more syntax changes to remove diff between nuttx & posix files 2016-09-28 15:31:52 +02:00
Beat Küng 83c5323c3a uorb: remove syntax differences between posix & nuttx src file 2016-09-28 15:31:52 +02:00
Beat Küng fbd7aac4b5 uorb: add 'top' command for a live view of topic updates 2016-09-28 15:31:52 +02:00
Beat Küng 670c93e726 cmake: add support for out-of-tree modules via EXTERNAL_MODULES_LOCATION variable 2016-09-27 15:10:23 +02:00
Lorenz Meier 65e3ae70dd DF update 2016-09-27 11:56:49 +02:00
Lorenz Meier 676e90cd98 Define realtime clock for systems not having one 2016-09-27 11:56:49 +02:00
Lorenz Meier adf56050b9 Use monotonic clock for simulator 2016-09-27 11:56:49 +02:00
Lorenz Meier 5b674ffe48 Update DF to include Travis CI fix for DF
DF Update: Use common CMake version so Darwin handling is correct in PX4

Update DF to use proper constants

Update DF
2016-09-27 11:56:49 +02:00
Lorenz Meier af8cbee6d5 Support 10.11 and 10.12 in parallel in PX4 2016-09-27 11:56:49 +02:00
Lorenz Meier f49eabdb9d Update DF to have 10.11 and 10.12 support in parallel 2016-09-27 11:56:49 +02:00
Lorenz Meier c433e7bf3e Set correct XCode 8 version 2016-09-27 11:56:49 +02:00
Lorenz Meier 88cffaddec Enable CMake
Output CMake version
2016-09-27 11:56:49 +02:00
Lorenz Meier cf671b5134 Fix tests and re-introduce tests into build
Code style fix
2016-09-27 11:56:49 +02:00
Lorenz Meier 1909f2b02f Switch Travis to XCode 8 2016-09-27 11:56:49 +02:00
Lorenz Meier 2b9596cac0 Run clean beffore distclean so that a partial build is wiped as well. 2016-09-27 11:56:49 +02:00
Lorenz Meier 69c28177ac Fix platform headers / files for XCode 8 2016-09-27 11:56:49 +02:00
Lorenz Meier edf0057cee Modify build for XCode 8 2016-09-27 11:56:49 +02:00
Lorenz Meier 398d9642cb Update DF for XCode 8 2016-09-27 11:56:49 +02:00
Daniel Agar fb75240ee9 FW init TECS with PSP_OFF and constrain TAS error 2016-09-27 08:49:45 +02:00
Daniel Agar ebdfa2860b land_detector status cleanup 2016-09-27 08:49:45 +02:00
Daniel Agar 9fd0513be3 vtol remove unused vehicle_status 2016-09-27 08:49:45 +02:00
Dennis Shtatnov e27f396f55 Syslink properly working address params 2016-09-27 08:46:00 +02:00
David Sidrane f750140b6f Make line 280 check happy (#5550) 2016-09-27 08:34:48 +02:00
Daniel Agar 7c0a567eaa navigator explicitly invalidate position setpoint 2016-09-26 23:11:08 +02:00
Daniel Agar 7b03bce416 Navigator mission FOH use previous loiter altitude
-the previous item altitude wasn't valid if switching from LOITER ->
MISSION
-fixes #5395
2016-09-26 23:11:08 +02:00
Julian Oes 660a9e13e7 mavlink_mission: improve comments about casting 2016-09-26 22:55:21 +02:00
Julian Oes 238f597b78 mavlink_mission: remove wrong comment 2016-09-26 22:55:21 +02:00
Julian Oes 047c0e44bd mavlink_mission: support missions with int params
This brings support for the messages MISSION_REQUEST_INT and
MISSION_ITEM_INT which raises the lat/lon accuracy for waypoints.
2016-09-26 22:55:21 +02:00
Julian Oes 997ae98444 navigator: reset cruise speed when out of mission (#5494)
This reset the cruise speed which can be set by mission items/waypoints
to set a custom speed. Once, switched out of mission, it makes sense to
use the speed set by the param again.
2016-09-26 22:54:15 +02:00
Carlo Wood c6a2641507 Fix some pthread related linker stuff. (#5504)
The px4_os_add_flags defined in cmake/posix/px4_impl_posix.cmake did
add (threading) libraries to added_exe_linker_flags, which subsequently
end up in CMAKE_EXE_LINKER_FLAGS and then have no effect because those
flags are passed to the linker before any of the object files and static
libraries.

Those libraries are already added correctly in the corresponding
src/firmware/*/CMakeLists.txt files (for qurt, nuttx AND posix).

I left in the non-library linker flag '-pthread' for the bebop board,
although it seems very weird to me that this is needed (is it?).
If that is needed then it seems weird to link manually (that is,
src/firmware/*/CMakeLists.txt) with -lpthread.

For linux/g++ -pthread is added to the CXXFLAGS as it should be:
this causes the compiler to define _REENTRANT which is needed
for (the interface of) certain libraries to become thread-safe.
Offically one also can just pass -pthread to the linker, which then
causes the right libraries to be linked, but just linking with
-lpthread -lm -lrt works too.

I ran into this while adding support for libcwd, which explicitly
complains that _REENTRANT isn't defined when trying to link with
the thread-safe version of libcwd (-lcwd_r) and then tells you
to use -pthread.
2016-09-26 22:53:41 +02:00
Daniel Agar 6d655d2d6e startup remove old EKF PE_ params (#5533) 2016-09-26 22:51:43 +02:00
Daniel Agar 1d0a667826 Geofence defaults (#5534)
* geofence messages too frequent

* geofence horz/vert disable with 0 instead of -1

-closes #5430
2016-09-26 22:50:36 +02:00
David Sidrane 0eca86443d Master additional targets (#5548)
* Allow Niga to be disabled from command line

* Add a build all nuttx targets
2016-09-26 22:48:37 +02:00
Sander Smeets c4eabbd083 VTOL transition switch parameter checking (#5545)
* VTOL transition switch parameter checking

* Code style
2016-09-26 10:18:23 +02:00
Lorenz Meier bd922e4eed Standard VTOL: report correctly in SIM 2016-09-25 18:37:33 +02:00
Lorenz Meier 9915a416ff Better yaw limits for default VTOLs 2016-09-25 18:37:03 +02:00
Lorenz Meier e42ff72d6a Standard VTOL configs: Limit yaw rate 2016-09-25 18:37:03 +02:00
lovettchris 11f8da5fc6 AUTO_LOITER respect disabled RC link loss param (#5499) 2016-09-23 18:14:32 -04:00
tommises 35b45e02b1 controllib_test fix filename in comments (#5538) 2016-09-23 17:13:54 -04:00
Dennis Shtatnov b9c5d117dd CF2: Linux USB uploading fix 2016-09-21 17:20:08 -04:00
Andreas Antener e7d90b1cd3 reduced the wait time at the end of the motor ramp to not unnecessary stress the system 2016-09-21 08:53:15 +02:00
Andreas Antener 3b58caa32a Updated motor RAMP timing to match slew rate limiter 2016-09-21 08:53:15 +02:00
Daniel Agar 69ae0091b8 VTOL QuadChute only if not landed 2016-09-21 08:36:00 +02:00
Dennis Shtatnov cfe59e74b2 CF2: Unique Board ID 2016-09-20 19:21:24 -04:00
Daniel Agar 9fb167b642 add crazyflie to builds (#5516)
* Makefile simplify check and quick_check

* make check add crazyflie_default
2016-09-20 21:05:44 +02:00
Beat Küng 21ce157763 lps25h: use STACK_MAIN instead of STACK 2016-09-20 18:55:25 +02:00
Beat Küng 281c450b6e fix syslink: rc.timestamp_publication -> rc.timestamp
changed in d297d31c23
2016-09-20 18:55:05 +02:00
Daniel Agar c4b9b05af9 make check_format also check git whitespace (#5503)
-fixes #5484
2016-09-20 12:45:42 -04:00
Nacho Carnicero 392391e8df Fix VTOL status in forward transition for tiltrotor models 2016-09-19 20:27:14 +02:00
Mark Whitehorn 95f899fee7 always publish simulator groundtruth attitude 2016-09-19 13:07:02 +02:00
Mark Whitehorn 8f64825297 switch to new logger for posix_sitl_default 2016-09-19 13:05:14 +02:00
Mark Whitehorn ca9ac1c807 add default simulator groundtruth topic only for SITL builds 2016-09-19 13:05:14 +02:00
Mark Whitehorn f24b199775 add HIL_STATE message handler and publish to uORB
add missing break

uorb topics generator: add multi-topics to the list of all topics

topic names with '# TOPICS <name>' were previously not in orb_get_topics().
This means the logger could not find them.

Affects for example actuator_controls_0.

px_generate_uorb_topic_files.py: add multitopics to generate_topics_list_file_from_files method

switch simulated attitude to new topic: vehicle_attitude_groundtruth

logger: add input_rc topic. needed for web plotting

input_rc.msg: remove timestamp_publication, use timestamp instead

mixer.cpp: warnx -> PX4_ERR

logger: initialize timer_call to 0 (hrt_call_every reads some fields)

position_setpoint_triplet topic: set the timestamp when publishing

px_generate_uorb_topic_files.py: add multitopics to generate_topics_list_file_from_files method

add vehicle_attitude_groundtruth to default topics

change to hil_state_quaternion
2016-09-19 13:05:14 +02:00
Beat Küng 79f2cd79d9 px_generate_uorb_topic_files.py: add multitopics to generate_topics_list_file_from_files method 2016-09-19 13:03:40 +02:00
Beat Küng 3a084fbdb8 position_setpoint_triplet topic: set the timestamp when publishing 2016-09-19 13:03:40 +02:00
Beat Küng 89a7e0cf87 uorb topics generator: add multi-topics to the list of all topics
topic names with '# TOPICS <name>' were previously not in orb_get_topics().
This means the logger could not find them.

Affects for example actuator_controls_0.
2016-09-19 13:03:40 +02:00
Beat Küng 4e1652fa6b logger: initialize timer_call to 0 (hrt_call_every reads some fields) 2016-09-19 13:03:40 +02:00
Beat Küng 44ac7d11e7 mixer.cpp: warnx -> PX4_ERR 2016-09-19 13:03:40 +02:00
Beat Küng d297d31c23 input_rc.msg: remove timestamp_publication, use timestamp instead 2016-09-19 13:02:31 +02:00
Beat Küng 3a94afb03c logger: add input_rc topic. needed for web plotting 2016-09-19 13:02:31 +02:00
Dennis Shtatnov f334a6225a Syslink cli deck detection 2016-09-19 11:54:53 +02:00
Dennis Shtatnov 937f3477d3 Syslink memory/deck interface 2016-09-19 11:54:53 +02:00
Dennis Shtatnov 83105fca95 CF2: Buzzer 2016-09-19 11:54:53 +02:00
Dennis Shtatnov c9a17fdd68 CF2: Free up serials
There are only two exposed serial connections, which are used as other things for the decks, so don't utilize any by default
2016-09-19 11:54:53 +02:00
Dennis Shtatnov eafc0dad4a CF2: Disable UART console to free up expansion pins
nshterm should still work. Using low console instead which should just discard all characters for the plain system console
2016-09-19 11:54:53 +02:00
Dennis Shtatnov 984e7521d4 CF2: Charging and RX/TX LEDs working 2016-09-19 11:54:53 +02:00
Beat Küng c191a82882 gazebo: update submodule 2016-09-19 09:18:37 +02:00
Beat Küng 69865e4e04 vmount: fix mavlink input: angles are given in deg 2016-09-19 08:03:02 +02:00
Beat Küng ead9b2111c vmount: fix calculation of GPS location to angles 2016-09-19 08:02:27 +02:00
Beat Küng 3ae2ca74c5 posix-configs: start vmount for typhoon 2016-09-19 07:55:38 +02:00
Beat Küng 057d71e101 posix-configs: use 'mixer append' command for typhoon mount mixer 2016-09-19 07:54:51 +02:00
Andreas Antener 5825b8c3e7 Geofence: renamed action on flag, reset only if none of the possible warning actions is set 2016-09-18 21:14:18 +02:00
Carlo Wood a03441b818 Fix the multi- target targets (#5489) (#5491)
On second thought, using % just isn't correct. When a make
target looks like:

foo% bar%:
	...

Then that implies that it will build BOTH foo% and bar% whenever
that rule is triggered (by either) for any value of the pattern %.

Clearly that is not what we want / intend.

So, this commit goes back to using config targets without a % in it
by generating a full list of them.

It also turns sitl_deprecation into a Hidden Target.

Finally, now that we have those target lists anyway, I added
a 'help' and 'list_config_targets' targets that print the
available targets.

Note that the '%' catch-all target only works when all other targets
either have a recipe or are marked as .PHONY, otherwise such targets
are only interpretted as dependencies and still executre the '%'
target afterwards, which is not what we want.
2016-09-18 01:44:45 +02:00
Lorenz Meier 71fd4b9e98 Uploader tool: Try MAVLink reboot command first 2016-09-17 23:49:41 +02:00
Lorenz Meier d98bbd9b82 Fix issue #5501. Link termination now requires param 2 = 10 2016-09-16 11:34:40 +02:00
Julian Oes 4453e4201b navigator/mavlink: fixes for mission item reached message (#5486)
* navigator/mavlink: always send last reached item

Since we can't rely on mavlink that every message arrives, it makes
sense to continuously send the last reached waypoint.

* navigator: don't report reached for takeoff

If a takeoff waypoint has been inserted, we should not report that we
reached a mavlink mission item because we actually have not.
2016-09-13 21:52:28 +02:00
Carlo Wood d2626d725d Makefile cleanup - fix merge conflict change 2016-09-13 16:31:08 +02:00
Carlo Wood e93324785b list_vmd_make_targets and list_cmake_targets
* This allows one to run 'make posix list_vmd_make_targets' and get output like

>make posix list_vmd_make_targets
[...]
-- Build files have been written to:
/usr/src/debian/px4/Firmware/Firmware.git/build_posix_sitl_default
PX4 CONFIG: /usr/src/debian/px4/Firmware/Firmware.git/build_posix_sitl_default
Scanning dependencies of target list_vmd_make_targets
[100%] List of acceptable 'posix_sitl_default' <viewer_model_debugger> targets:
none
none_iris
none_iris_opt_flow
none_tailsitter
[...]
replay_solo_valgrind
replay_typhoon_h480_valgrind
[100%] Built target list_vmd_make_targets

Or, run 'make list_vmd_make_targets' from the build_posix_* directory.

* This adds the list_cmake_targets make target to print all
cmake targets that one can match with PX4_NO_OPTIMIZATION.
PX4_NO_OPTIMIZATION is ignored (do optimization as normal)
when the CONFIG isn't posix_sitl_*.

* Add comment in Makefile on how/where to find all targets.
2016-09-13 16:31:08 +02:00
Carlo Wood 6f94f7031b More Makefile cleanup.
Use $(MAKE) -C build_dir ..., not (cd build_dir; make ...)
(ie, see https://blog.flameeyes.eu/2010/10/tell-tale-signs-that-your-makefile-is-broken)

Also talk about 'make targets' where appropriate, instead of 'cmake targets' %-).
2016-09-13 16:31:08 +02:00
Carlo Wood 77d356d275 Target specific optimization control.
This allows one to set a semi-colon separated list of regular
expressions in the environment variable PX4_NO_OPTIMIZATION
to control which (cmake generated) targets should be compiled
without optimization.

Suppressing optimization can be necessary for debugging in
a debugger, especially when trying to step through the code
or needing to print variables that otherwise are optimized out.

EXAMPLE

export PX4_NO_OPTIMIZATION="px4;^modules__uORB;^modules__systemlib$"

will result in the following messages during cmake configuration:

[...]
-- Disabling optimization for target 'platforms__posix__px4_layer'
because it matches the regexp 'px4' in env var PX4_NO_OPTIMIZATION
-- Disabling optimization for target 'modules__systemlib' because it
matches the regexp '^modules__systemlib$' in env var PX4_NO_OPTIMIZATION
-- Disabling optimization for target 'modules__uORB' because it matches
the regexp '^modules__uORB' in env var PX4_NO_OPTIMIZATION
-- Disabling optimization for target 'examples__px4_simple_app' because
it matches the regexp 'px4' in env var PX4_NO_OPTIMIZATION
-- Disabling optimization for target 'modules__uORB__uORB_tests' because
it matches the regexp '^modules__uORB' in env var PX4_NO_OPTIMIZATION
-- Disabling optimization for target 'px4' because it matches the regexp
'px4' in env var PX4_NO_OPTIMIZATION

Note that a list of all (currently used) target names can be printed
with the following command line from within the required build directory:

find . -wholename '*/CMakeFiles/*.dir/flags.make' | xargs dirname | xargs basename -a | sort -u | sed -e 's/.dir$//'
2016-09-13 16:31:08 +02:00
Carlo Wood 541c8a06ca Partly cleanup and simplify cmake/configs/posix_sitl_* config files.
While the config_sitl_rcS_dir is used more extensively (and actually
only depending on the base cmake target), the variables
config_sitl_viewer and config_sitl_debugger are just used to be
passed on for the run_config target; config_sitl_debugger is even
*always* 'disable'. Hence, they don't really need to be cached
(INTERNAL or not). Before this patch FILEPATH was used instead
of INTERNAL, but I doubt very much that that was intended. That
only makes sense when cmake-gui would be used and then would pop-up
a file browser to let the user pick a file (while really they
need to pick a directory, so it's wrong either way).

The ONLY reason caching would be used is when a developer edits
the build_posix_sitl_*/CMakeCache.txt files, changes these values
and then runs cmake in the build directory again, now overriding
the values intended here. Nevertheless, I left in the caching.

The main change in this commit (that theoretically has no real effect)
is that I removed the duplicated maintenance of
posix_sitl_broadcast.cmake. When that file was added, it was an
exact copy of posix_sitl_default.cmake and is since not always
maintained to remain the same. I don't think that difference is
in anyway relevant for the broadcasting part though.

Note that I think that something like that also holds for the
posix_sitl_replay.cmake; it would be a lot better - maintenance-wise
- when it was just derived from (or the same as) posix_sitl_default,
I think.
2016-09-13 16:31:08 +02:00
Carlo Wood 900026818b Makefile cleanup.
Doesn't really do anything, but while working on understanding
things I did this cleanup, making the Makefile a lot shorter
and more flexible for future changes ;).
2016-09-13 16:31:08 +02:00
Carlo Wood 03d176d097 Bug fixes, typos, indentation.
Over time I made a few changes unrelated to what I'm really working on.
These changes are hereby committed first. The bug fixes are related to
what I'm doing in that I need them to be fixed for future commits.

Tools/sitl_run.sh: rename label to rcS_dir and fix usage help.
cmake/common/px4_base.cmake: Remove the check on OUT_UNPARSED_ARGUMENTS,
  and a few typos and indentation issues.
cmake/configs/posix_sitl_replay.cmake: Set the correct variable
  (config_sitl_rcS_dir) to the correct directory.
cmake/nuttx/px4_impl_nuttx.cmake: typos and indentation issues,
  and removal of a redundant FORCE (INTERNAL implies FORCE).
cmake/posix/px4_impl_posix.cmake: typos and indentation issues.
cmake/qurt/px4_impl_qurt.cmake: typos and indentation issues.
src/modules/mavlink/mavlink_ftp.cpp : possible strict-aliasing breakage.

NOTES

The second argument passed to sitl_run.sh is the value of
config_sitl_rcS_dir. This fact is missing from the usage help.
I renamed 'label' to 'rcS_dir' to better reflect this.
Also, for the 'replay' config the wrong variable was set causing
the call to sitl_run.sh to skip an argument and fail (ie the
debugger was passed as rcS_dir and so on).

The check on OUT_UNPARSED_ARGUMENTS in px4_parse_function_args
basically causes every passed IN variable to be REQUIRED and is
therefore a bug. The test for the presence of the REQUIRED arguments
follows directly after and is sufficient for this job. This bug went
unnoticed because currently every argument to OPTIONS, ONE_VALUE,
and MULTI_VALUE is actually passed to the function(s) calling
px4_parse_function_args (them being REQUIRED or not).

The changes in mavlink_ftp.cpp are to avoid a possible aliasing bug
and (mostly) to avoid the compiler warning/error: dereferencing type-
punned pointer will break strict-aliasing rules [-Werror=strict-aliasing].
2016-09-13 16:31:08 +02:00
Andreas Antener 6c7e5651ce Geofence: moved rtl_on reset up so it always happens when falling out of RTL 2016-09-13 14:32:01 +02:00
Andreas Antener 5a7046027c added rattitude to geofence exit condition 2016-09-13 14:32:00 +02:00
Andreas Antener a59038e3cb Geofence: fix reset after violation and also if RTL/Loiter switches are not assigned 2016-09-13 14:32:00 +02:00
Roman ab4731a99f fw_pos_control_l1: for tailsitters we need to rotate the body acceleration
vector as it has it's reference in the mc frame

Signed-off-by: Roman <bapstroman@gmail.com>
2016-09-13 14:32:00 +02:00
Andreas Antener e1e410783a tailsitter: correctly use roll/pitch inputs when optimal recovery is enabled 2016-09-13 14:32:00 +02:00
Andreas Antener 8c9f4e8ab8 added which transition the vtol is in to vehicle status 2016-09-13 14:32:00 +02:00
Andreas Antener 46105f735e finish back transition when a mode change from manual to auto happens during the back transition 2016-09-13 14:32:00 +02:00
Andreas Antener c6e4926d4e prevent instant transition to fixed-wing while already in back transition, prevents unsafe flying state 2016-09-13 14:32:00 +02:00
Beat Küng 670697b0ac fw_att_control_main: fix implicit float to double conversion issue
GCC 6.1.1 output:
../src/modules/fw_att_control/fw_att_control_main.cpp:884:41: error:
implicit conversion from ‘float’ to ‘double’ to match other operand of
binary expression [-Werror=double-promotion]
2016-09-13 11:43:22 +02:00
Daniel Agar 31ddf6bdd9 sitl_run.sh use full path to jmavsim_run.sh 2016-09-13 11:30:38 +02:00
Beat Küng e7afecb544 Tools: add separate jmavsim_run.sh script
It is useful to run jmavsim separately, for example when debugging mainapp
separately, or running some other external tool on mainapp (like heap
analysis)
2016-09-13 11:30:38 +02:00
Lorenz Meier 7d7e40f594 UAVCAN: Adjust stack size to platform 2016-09-11 20:07:30 +02:00
Lorenz Meier 29d33a12dc Simulator: Adjust way too small task stack 2016-09-11 20:07:30 +02:00
Lorenz Meier f815d9fa74 sdlog2: Adjust writer stack size 2016-09-11 20:07:30 +02:00
Lorenz Meier 1c2b932cf8 MAVLink receiver: Adjust stack size 2016-09-11 20:07:30 +02:00
Lorenz Meier bb48787811 Logger: Adjust pthread stack size 2016-09-11 20:07:30 +02:00
Lorenz Meier 9a8e6de7fe EKF2: Remove QuRT hackery 2016-09-11 20:07:30 +02:00
Lorenz Meier c52c692c4f Commander: Adjust pthread stack size for platform 2016-09-11 20:07:30 +02:00
Lorenz Meier 5b69e58925 Provide macros and extensions to the task spawn command to set the stack sizes right 2016-09-11 20:07:30 +02:00
Simon Wilks efd64e2cd2 Update the title metadata and gains after some tuning flights. (#5480) 2016-09-11 18:46:00 +02:00
Dennis Shtatnov 52fdbf4acc Syslink Bridge to Mavlink (#5479) 2016-09-11 11:23:15 +02:00
Daniel Agar 446f8e3a36 make quick_check even quicker 2016-09-09 18:50:51 -04:00
James Goppert d5c96ec66a LPE rate and stddev changes for mocap/vision. (#5467) 2016-09-07 23:56:10 +00:00
James Goppert 76c2d92b7e Fix for lpe accel bias saturation. (#5466)
* Fix for lpe accel bias saturation.

* Formatting.
2016-09-07 23:53:50 +00:00
Andreas Antener 3163cf90c9 FW: simplified flap/flaperon logic and always move them at the same rate (don't jump) 2016-09-07 19:29:32 +02:00
Beat Küng be4db3c5df vehicle_command topic: use uorb queuing with length 3
Just to make sure we don't lose any messages.
2016-09-07 18:47:12 +02:00
James Goppert c1b73a068e qavr tuning 2016-09-07 10:26:12 -04:00
Lorenz Meier f34a56999f Remove SRF02 driver to make flash space 2016-09-07 13:29:41 +02:00
Bart Slinger 79d8d580b1 Append AUX mixer for HITL simulation (#5457) 2016-09-07 12:09:22 +02:00
Andreas Antener cbbf5e2e7c filtering files for code check seperately to enable fast use of git pre-commit hook to check code style
ask user to install pre-commit hook when code style is checked
2016-09-07 11:25:51 +02:00
Michael Schaeuble 93201835d3 Fix code style 2016-09-07 08:24:08 +02:00
Michael Schaeuble 57fee8b9de Update DF submodule 2016-09-07 08:24:08 +02:00
Michael Schaeuble 1fac4c4874 Improve code documentation and code cleanup 2016-09-07 08:24:08 +02:00
Michael Schaeuble 40bf8f75d6 Add Bebop mixer and controller gains 2016-09-07 08:24:08 +02:00
Michael Schaeuble ad8f51f662 Update PX4 config to new functionality 2016-09-07 08:24:08 +02:00
Michael Schaeuble d84a325010 Integrate DF BebopBus into the wrapper 2016-09-07 08:24:08 +02:00
Michael Schaeuble 5d3e9df731 Add DF wrapper for BebopBus driver 2016-09-07 08:24:08 +02:00
Miguel Arroyo 8dfbb43e00 Adds Navio Kill Switch Logic (#5461) 2016-09-07 08:17:41 +02:00
Andreas Antener 06bfecd829 Geofence: use correct types for float params 2016-09-07 08:05:28 +02:00
Andreas Daniel Antener 9ea4c33ede Battery: directly evaluate critical battery state if set, wait longer for USB detection to happen (#5460) 2016-09-07 07:26:06 +02:00
Lorenz Meier e011a528eb Enable a workaround for #5438 (#5450)
* Enable a workaround for #5438

* Disable Travis Slack integration

* Fix formatting
2016-09-06 23:34:02 +02:00
Beat Küng 78df9de4c4 update jmavsim submodule 2016-09-06 16:25:13 +02:00
Beat Küng 9c0380c31d update jmavsim submodule 2016-09-06 15:58:48 +02:00
Beat Küng 44520522ac vmount: make sure the test command works, even if MNT_MODE_IN is 0 2016-09-06 11:39:22 +02:00
Lorenz Meier 3f07b03911 SITL: Tune standard VTOL to have better position control performance & update gazebo 2016-09-06 11:35:52 +02:00
Beat Küng 90c7b06152 mavlink hil: add HIL_CONTROLS publication for compatibility (eg. with mavros) 2016-09-06 11:33:18 +02:00
Beat Küng 3de4ec7093 Update SITL gazebo 2016-09-06 11:33:18 +02:00
Beat Küng 7e05c12f5d px4fmu hexa mixer: add support for mount/gimbal output 2016-09-06 11:33:18 +02:00
John Hsu 340cb05f70 Add configurations for Zephyr SITL. Add init script for Zephyr SITL. Update hexa_x.main.mix with leg control. 2016-09-06 11:33:18 +02:00
Beat Küng 010c9e937b SITL: switch to HIL_ACTUATOR_CONTROLS mavlink message & add pwm_out_sim support for 16 outputs 2016-09-06 11:33:18 +02:00
Beat Küng 41913c4a80 vmount: fix print status output, adjust stack size, improve error handling 2016-09-06 11:33:18 +02:00
Beat Küng 0a95c447b0 vmount: add 'vmount test' command to set a specific angle 2016-09-06 11:33:18 +02:00
Beat Küng ccde51304a cmake px4fmu-v2: disable vmount for now, due to flash overflow 2016-09-06 11:33:18 +02:00
Beat Küng 94dbf358bd vmount: refactor architecture & use C++
This splits vmount into inputs and outputs modules with a small API in
between. It allows for greater flexibility, as any input method can be
combined with any output method. At the same time it is easy to add a new
input or output module.
2016-09-06 11:33:18 +02:00
Beat Küng 8757b9a9a5 cmake posix sitl: add vmount driver 2016-09-06 11:33:18 +02:00
Leon faebdeedcf vmount: add mount and ROI implementation
MavLink spec implementation

implemented vehicle_roi topic

rename old gimbal to rc_gimbal

little changes

corrected RC Gimbal group

Starting ROI implementation in commander

implementation done, needs to be tested

uhm..

add todo

Change to float32 for x,y and z

remove mission topic again, not needed

change roi coordinates to lat, lon and alt

adjust to float64

starting mount implementation

correcting small mistakes, compiles now

add todos

further progress

implementing parameters

adjust default parameters

started implementation of mavlink

fix typo

change to lat, lon and alt

fix typo :D

change to double (to represent float64)

add global_position_

add mount topic

commander mount implementation done

cleanup

almost finished

little fix

codestyle fixes

leave pitch at 0 degrees

added pitch calculation

codestyle changes

Undo vehicle_mount, react to updated parameters, parsing of CMD_DO_MOUNT_* in mount.cpp

start implementing mode override

forgot a semikolon.

add debug

Finish implementation of mount override and manual control.

fix codestyle

correct cleanup

rename to vmount

works now

fix rebase error

fix polling

refactoring and custom airframe for gimbal

couple changes

remove warnx

almost done

finally

What is going on?

change back to actuator_controls_2

working

bump parameter version number and some clarification

fix submodules
2016-09-06 11:33:18 +02:00
Beat Küng e6391189bc px4_simple_app: update printf to latest format version 2016-09-06 10:41:46 +02:00
Beat Küng 0da44b7166 posix main: make <data_directory> argument optional, default to CWD 2016-09-06 10:41:36 +02:00
Daniel Agar f07cd13fe8 circleci update to tolerate submodule changes (#5451)
- remove broken ccache setup
2016-09-05 00:47:48 -04:00
Carlo Wood 4a5eae23a2 Increase stack space on posix 64bit architectures. (#5447)
When running a simulation with, for example,
make posix jmavsim
px4 crashed almost 100% reproducable near start up.

This turned out to be a stack overflow. On gitter
it was suggested that the main reason for this could
be stack sizes, as currently used, assume a 32bit pointer
size and that doubling the stack size for everything
but NuttX would be the Right Thing.

This is the solution that I came up with (it makes
my core dumps disappear).
2016-09-04 23:04:04 +02:00
Lorenz Meier f607069a57 Purge old configs 2016-09-04 21:57:19 +02:00
Lorenz Meier 3aa66da20f Build serdis / sercon with size optimization 2016-09-04 21:44:30 +02:00
Lorenz Meier 07966de432 Build serdis / sercon with size optimization 2016-09-04 21:43:44 +02:00
Lorenz Meier 8709078c38 Save some flash for much too verbose output 2016-09-04 20:55:03 +02:00
Dennis Shtatnov 585147d5b7 Working LPS25H driver 2016-09-04 19:12:08 +02:00
Dennis Shtatnov 1fd3636ab3 Flyable gains for CF2 2016-09-04 19:12:08 +02:00
Dennis Shtatnov c842b0457f Syslink for battery, RSSI, and initial radio control 2016-09-04 19:12:08 +02:00
Dennis Shtatnov b99b886576 CF2 correct motor map and LEDs 2016-09-04 19:12:08 +02:00
Dennis Shtatnov e91821d2a2 Merge Crazyflie motor driver with FMU
Comment corrections
2016-09-04 19:12:08 +02:00
Dennis Shtatnov e6b98b2ab8 Tweak configs for CF2
Fix build error

Capitalization mistake for headers

Non-Mac compiler issue

Baudrate for crazyflie nrf and fix code style

Save space

Cleanup mpu9250 driver
2016-09-04 19:12:08 +02:00
Dennis Shtatnov 5100785f51 MPU9250 I2C mode
Fixes for other boards

Functioning sensors
2016-09-04 19:12:08 +02:00
Dennis Shtatnov 9c8e56401b Working motors and mtd for CF2 2016-09-04 19:12:08 +02:00
Tim Dyer b65ff53b00 Initial build for Crazyflie 2.0
Working crazyflie firmware build

* Console on USART3
* Could not disable building PX4IO firmware, currently commented out

Don't build PX4IO firmware if the board doesn't ask for it

Added crazyflie motor driver

Fixed wrong register

CLK_SEL is in PWR_MGMT_1

Initial I2C/SPI MPU9250 device

* Tested with I2C
* Need to add error checking
* Intermittent crash on stop call

Working ak8963 mag driver

Functional lps25h driver. Work in progress.

Works well enough to probe and allow sensors task to start.

Added serial port test module

HACK! Get sensors module working

Set crazyflie PWM range

Extend baudrate for Crazyflie's NRF radio

Added dummy tone alarm to allow for init

Added autostart script for Crazyflie
2016-09-04 19:12:08 +02:00
Lorenz Meier c1e681df60 HMC: Fill extended mag report completely 2016-09-04 19:11:46 +02:00
Lorenz Meier 45f740e210 Device: Allow access to device id 2016-09-04 19:11:28 +02:00
Lorenz Meier 31bba3a847 Report mag data 2016-09-04 19:10:57 +02:00
Lorenz Meier 8c49372e7a Better error reporting for sdlog2 2016-09-04 18:47:41 +02:00
Carlo Wood cc69dd5665 printf format fixes. (#5444)
After I got a compiler warning for a printf format in this file
(which I cannot reproduce anymore; for some reason g++ is usually
quite happy with all the errors in this file), I fixed all 'printf'
formats to match the type of their arguments as follows:

uint8_t         : %hhu
uint16_t        : %hu (or %hx)
uint32_t        : %u (or %x)
int16_t         : %hd
int and int32_t : %d
long int        : %ld

Since this file is C++, what we REALLY should be using is
ostream operator<<'s of course (type safe by design and faster
(compile time type matching, no need for format decoding)).
2016-09-04 14:28:23 +02:00
Miguel Arroyo f999fbe440 Publishes LPE GPS epv and eph as estimator status. (#5413)
* Publishes LPE GPS epv and eph as estimator status.

* Adds timestamp
2016-09-03 22:00:51 +02:00
Nicolas de Palezieux a071ef94db always update armed flag (#5434)
otherwise the battery estimator does not compute bat_v_empty_dynamic correctly
2016-09-03 21:59:27 +02:00
Otávio d03611763a Use readdir instead of readdir_r (#5421)
readdir_r is deprecated since glibc version 2.24 and glibc manual
recomends usage of readdir instead of readdir_r.
Replacing readdir_r by readdir will also not be a problem for Nuttx,
because readdir_r is using readdir and filling parameters with the
return information.

Signed-off-by: Otavio Pontes <otavio.pontes@intel.com>
2016-09-03 13:45:40 +02:00
Michael Schäuble b9b9f17eee Fix build errors (#5436)
* Use sorted to fix python3 build error

* Add drv_hrt.h include to Bebop df wrappers
2016-09-03 12:34:27 +02:00
Lorenz Meier 723d3c121a Find and use Python 2 (#5442)
This will make the build works in distros that have Python 3 as default
and will not break anything in distros that have Python 2 as default.
2016-09-03 12:33:48 +02:00
Mark Whitehorn a054fb1e04 fix altitude setpoint bug (#5409) 2016-09-03 12:33:36 +02:00
Lorenz Meier ea212a8ef5 LPE: Avoid false positives for GPS 2016-09-03 12:30:42 +02:00
Nate Weibley 686fd5b125 Convert geofence distance params to float (#5435) 2016-09-02 11:49:53 -04:00
Beat Küng ced33e982b update mavlink submodules 2016-09-01 13:37:42 +02:00
Beat Küng 33fdb072df uORBMain: disable message logging to the ulog on Snapdragon 2016-09-01 09:59:17 +02:00
Lorenz Meier 48a94e3570 Fixed i2c not running (#5408) 2016-09-01 09:19:30 +02:00
stmoon d219b8cf46 fix the bug for double space 2016-09-01 08:44:16 +02:00
Nate Weibley 22d286b9ce Fix version generation for release builds, #5308 (#5422) 2016-08-31 22:03:00 +02:00
Lorenz Meier 1d99f83b34 Add config for LPE and plane 2016-08-31 09:17:01 +02:00
James Goppert 9d861f021c Use git tag in cpack package. 2016-08-29 22:17:40 -04:00
James Goppert f6d7fef7c2 Added more gains for dji matrice. 2016-08-29 22:05:59 -04:00
James Goppert 8707cbc315 Fix version. 2016-08-29 22:05:48 -04:00
Lorenz Meier 5a734de319 Commander: Increase stack space 2016-08-29 23:36:34 +02:00
Lorenz Meier ece70dc18d Revert "commander: Running a bit low on space"
This reverts commit 2a90f7e9c0.
2016-08-29 23:35:56 +02:00
Lorenz Meier 2a90f7e9c0 commander: Running a bit low on space 2016-08-29 22:47:07 +02:00
James Goppert 36acb90680 Fix gps noise matrix for LPE. 2016-08-29 16:08:28 -04:00
Andreas Daniel Antener 02029882db SITL CI: gracefully fail tests early (#5405) 2016-08-28 21:56:31 +02:00
Lorenz Meier 15e50b26dc Fix MAVLink subscription 2016-08-28 15:53:42 +02:00
Lorenz Meier 8dc8ae7de8 MAVLink app: Only hold buffers for published topics 2016-08-28 10:49:41 +02:00
Lorenz Meier d4b588f84a Fix proto version selection 2016-08-28 10:40:00 +02:00
Lorenz Meier 19c2ae615f MAVLink: Do no not init fds struct 2016-08-28 10:26:59 +02:00
Lorenz Meier 1a716e1a0d Update MAVLink 2.0 headers 2016-08-28 10:08:15 +02:00
Lorenz Meier 6f19531ce4 MAVLink: Cleanup of port handling, switch to MAVLink 2 if receiving MAVLink 2. Announce MAVLink 2 capability in autopilot_version message
commit
2016-08-28 10:08:15 +02:00
James Goppert 6b08e8ce1f Improvements to lpe for flow and gps. (#5401) 2016-08-27 23:50:24 -04:00
James Goppert be1417f613 LPE alt init now allows baro only init without GPS w/o changing flag. (#5398)
Flight test went well, merging.
2016-08-27 21:57:32 -04:00
James Goppert 4499006744 Condition LPE covariance to avoid blowing up in edge cases. (#5377)
Merging this as it is definitely more robust than what we have now.
2016-08-27 21:18:27 -04:00
James Goppert dbc5e90993 Change to sitl to allow no board rotation for gazebo. (#5400)
* Change to sitl to allow no board rotation for gazebo.

* Fix typo in typhoon launch file and create config for lpe.

* Exit early on test failures
2016-08-27 20:03:54 -04:00
Mark Whitehorn bad6f0032c change board rotation to zero (#5392) 2016-08-27 22:56:08 +02:00
Lorenz Meier 25182108f9 Ensure NuttX build depends on defconfig 2016-08-27 12:56:31 +02:00
Lorenz Meier 5ef6d7952f MAVLink app: Enforce code style 2016-08-26 23:43:49 +02:00
Lorenz Meier 720c445f21 MAVLink: Code style 2016-08-26 23:43:33 +02:00
Lorenz Meier e67a6bdfc2 MAVLink: No need to restore previous port config on exit 2016-08-26 23:38:46 +02:00
Nicolas de Palezieux ebce93f338 only advertise range topic of px4flow board if it is the primary range device (#5390)
this allows selecting another range device such as a lidar by starting that app first
2016-08-26 14:28:46 +02:00
Lorenz Meier a1627fad9a Slack: Only report Travis CI failures 2016-08-26 12:11:48 +02:00
Luís Rodrigues cda4338095 Configuration parameter for TeraRanger One (#5359) 2016-08-26 12:03:18 +02:00
Lorenz Meier 3d7906647e Test Travis fix for OS X 2016-08-26 11:16:00 +02:00
mazahner 73014acf97 Only Compile and create dependencies for the Messages specified in msg/CMakeLists.txt
this lets a user select what msgs should be compiled for his project
Care must be taken though, to compile all orb_topcis that are required by the Rest of the Code.
Otherwise many compile errors will occur.

This commits adds by default the ./msg include path to reference to other msgs.
if an exisiting msg is used in another msg.
2016-08-25 22:30:13 +02:00
David Sidrane add2aa0680 Update Nuttx Submodule to included Proper MAC El Capitan USB fix ==master (#5385) 2016-08-25 21:59:59 +02:00
Lorenz Meier 1dfe51b11b Travis CI: OS X needs to build at least onene Firmware target 2016-08-25 21:48:30 +02:00
Lorenz Meier f511d49cc2 Improvements to SITL to make paths more flexible. (#5181) (#5255)
* Path cleanup for SITL.

* Restructured sitl scripts dir.

* Set integration tests to use ekf2 for vtol.

* Fix sitl paths for mac.
2016-08-25 21:47:45 +02:00
Beat Küng 61f7470e7e df wrappers: fix invalid NaN to int16 conversion (set to 0 instead)
The result of this conversion is undefined!
2016-08-25 13:14:15 +02:00
Beat Küng a7ef9b4954 fix navio_gpio: use uintptr_t for pointer type instead of uint32_t 2016-08-25 13:14:15 +02:00
Beat Küng 4b6e6572b9 fix navio_sysfs_pwm_out: use correct type for buflen (required by MultirotorMixer::from_text) 2016-08-25 13:14:15 +02:00
David Sidrane d4530d3a39 Update Nuttx Submodule to included MAC El Capitan USB fix ==master (#5380) 2016-08-25 09:24:52 +02:00
Tiktiki 111b41bc86 Removed configuration files from master (depreciated). (#5379)
* Update multi_tables.py

* Update mixer_multirotor.cpp

* Create gk

* Rename gk to 13011_greenkoptr

* Update 13011_greenkoptr

* Create greenkoptr.main

* Update and rename greenkoptr.main to greenkoptr.main.mix

* Create greenkoptr.aux.mix

* Update greenkoptr.main.mix

* Update 13011_greenkoptr

* Update multi_tables.py

Corrected HEX_T position and rotation for motors 1-2-5-6

* Delete 13011_greenkoptr

* Delete greenkoptr.aux.mix

* Delete greenkoptr.main.mix

* Update mixer_multirotor.cpp
2016-08-25 00:32:35 +02:00
Mark Whitehorn 545152f676 remove "transitional support" (#5378) 2016-08-24 23:05:39 +02:00
Beat Küng 96384bdc29 df wrappers: add drv_hrt.h include 2016-08-24 21:30:50 +02:00
Beat Küng eede43a786 px4_log.h: move px4_log_initialize() out of #ifdef 2016-08-24 21:24:35 +02:00
Beat Küng b8e247a018 muorb: add drv_hrt.h include for hrt_absolute_time 2016-08-24 21:24:35 +02:00
Beat Küng 441a05d976 uorb unittests stubs: add orb_advertise_queue 2016-08-24 21:24:35 +02:00
Beat Küng 528ca931af logger: only add data message to the log if orb_copy succeeds, when adding a new instance 2016-08-24 21:24:35 +02:00
Beat Küng df53fb0fde logging: publish a message for PX4_{WARN,ERR} & store them to the ulog file
- ulog file message rate limited to 50Hz
- queuing with size 2
- this replaces the mavlink log message in the ulog
  (but the mavlink warnings & errors still go to the ulog)
2016-08-24 21:24:35 +02:00
Beat Küng eae1585e38 logger: store full file name in logger, remove it from log writer
- also add log file to the status output
2016-08-24 21:24:35 +02:00
Beat Küng aefd217fc0 uorb subscription: remove _interval & use orb_get_interval() instead 2016-08-24 21:24:35 +02:00
Beat Küng 6b4c24fb12 px4_log: remove __px4_log_level_current
- there is no way to change it at runtime
- it was implemented wrong (<= comparison disabled the PANIC log level)
2016-08-24 21:24:35 +02:00
Beat Küng e2afb0be6b px4_log.h: remove hrt_absolute_time() declaration (it does not belong here) 2016-08-24 21:24:35 +02:00
Beat Küng d404359888 local_position_estimator_main: warnx -> PX4_{WARN,INFO,DEBUG} 2016-08-24 21:24:35 +02:00
Julian Oes 14ed65f0e4 sitl_run.sh: use ps instead of jps (#5376)
The tool jps does not seem to be available on macos Java.
2016-08-24 17:07:14 +02:00
Beat Küng 0127f4017a NuttX: update submodule 2016-08-23 20:17:16 +02:00
Lorenz Meier fadac79617 Add 9250 startup for FMUv2 2016-08-23 19:51:57 +02:00
Beat Küng 1fffd731b1 print_load_posix under DARWIN: remove unused variable basic_info (#5364) 2016-08-23 09:09:55 +02:00
Lorenz Meier 79678c5f25 MPU6K fix code style 2016-08-19 22:24:41 +02:00
Bart Slinger 7f04e3c759 Helicopter aiframe and basic PID control (#5339)
* Helicopter aiframe and basic PID control

* codestyle

* Blade 130x gains working but not optimal

* Changed behaviour of feedforward for all multicopter
2016-08-19 22:20:59 +02:00
Mark Whitehorn 75c95955fc Update 4050_generic_250 (#5343) 2016-08-19 22:20:27 +02:00
Mark Whitehorn 1b5964dc42 Update 4009_qav250 (#5344) 2016-08-19 22:19:47 +02:00
Lorenz Meier 7579ebf4e8 Fix failing mac test 2016-08-19 22:19:05 +02:00
Julian Oes 62297c3d86 DriverFramework: updated submodule (#5351)
- Fix if _retries variable is not set to prevent "UINT_MAX-1"
  retries.
- Update for the cmake_hexagon submodule.
2016-08-19 22:17:13 +02:00
Gus Grubba 821d7062df Support for new log file extension. (#5355) 2016-08-19 22:16:46 +02:00
Lorenz Meier 306a911dc9 Fix MPU6K driver ICM extensions 2016-08-19 22:09:05 +02:00
Beat Küng c3c8fa55b3 RC st24: change channel input range from [0,4096] to [500,3500] (#5350)
QGC failed to calibrate RC with the old range.
2016-08-19 20:45:56 +02:00
Lorenz Meier fe62c259e8 Fix MPU6K initialization 2016-08-19 11:10:11 +02:00
James Goppert 90b509a73f Update driver framework. (#5347) 2016-08-18 19:32:57 -04:00
James Goppert 372d16ee5e Update matrix. (#5346) 2016-08-18 18:01:55 -04:00
James Goppert 569e87d46b Update sitl gazebo. (#5345) 2016-08-18 17:22:13 -04:00
Lorenz Meier 192cde408a Remove unnecessary C++11 usage in UAVCAN 2016-08-18 21:44:15 +02:00
James Goppert 818840b576 Path cleanup, low impact changes (#5340)
* Low impact changes from path_cleanup branch.

This is a step towards minimizing the diff with path_cleanup branch.

* Update ecl.

* Revert matrix update.

* Revert ecl and matrix.

* Update sitl gazebo.

* Revert sitl_gazebo and matrix changes.
2016-08-18 15:37:23 -04:00
Lorenz Meier d32a7ffb8d Probe for ICM20608 2016-08-18 21:02:48 +02:00
Pavel Kirienko 24e90e3c90 UAVCAN servers: fixed member initialization; removed dead stuff 2016-08-18 17:14:53 +02:00
Pavel Kirienko d12be196a2 Fixed #5153 2016-08-18 17:14:53 +02:00
Pavel Kirienko 2784c3c5f0 Improved uavcan activity indication 2016-08-18 17:14:53 +02:00
Pavel Kirienko 64d7946cdc Fixed beep duration 2016-08-18 17:14:53 +02:00
Pavel Kirienko 36efc8c83e Fixed beeping 2016-08-18 17:14:53 +02:00
Pavel Kirienko 61ffc6c432 Fixed implementation of the ESC auto-enumeration feature 2016-08-18 17:14:53 +02:00
Pavel Kirienko 2fad9a6397 ESC status: printing temperature in Celsius 2016-08-18 17:14:53 +02:00
Pavel Kirienko 42031ab572 Better beeping during ESC enumeration 2016-08-18 17:14:53 +02:00
Pavel Kirienko e27d3f4e13 Added new configuration parameter UAVCAN_ESC_IDLT.
This parameter, when enabled, enforces that the UAVCAN ESC driver never outputs zero throttle
while the system is armed. This feature is disabled by default, so the change will not break
the experience of current users.
2016-08-18 17:14:53 +02:00
Hidenori 2ba70c5d89 rename Tools/rpi/clang-check.sh to Tools/clang-tool.sh
extended in two ways: target specification and tool selection.
2016-08-18 16:11:05 +02:00
Hidenori 211c2b9ca6 Rename clang toolchain file 2016-08-18 16:11:05 +02:00
Hidenori 9181f97f71 RPi: move clang-check.sh to Tools/rpi 2016-08-18 16:11:05 +02:00
Hidenori a1f89e4fd9 RPi: add a comment to clang-check.sh 2016-08-18 16:11:05 +02:00
Hidenori a8d3b15d73 RPi: add clang & clang-check support 2016-08-18 16:11:05 +02:00
Lorenz Meier ae00abe468 Fix typo 2016-08-18 15:44:51 +02:00
Tiktiki dfed00d870 Update multi_tables.py
Corrected HEX_T position and rotation for motors 1-2-5-6
2016-08-18 15:27:32 +02:00
Tiktiki 03e5d7490f Update 13011_greenkoptr 2016-08-18 15:26:26 +02:00
Tiktiki 7d4e7aff20 Create greenkoptr.main
Update and rename greenkoptr.main to greenkoptr.main.mix

Create greenkoptr.aux.mix

Update greenkoptr.main.mix
2016-08-18 15:26:25 +02:00
Tiktiki a962098645 Create gk
Rename gk to 13011_greenkoptr

Update 13011_greenkoptr
2016-08-18 15:26:21 +02:00
Tiktiki 021da9b2e1 Update mixer_multirotor.cpp 2016-08-18 15:25:24 +02:00
Tiktiki 3daf4a3a67 Update multi_tables.py 2016-08-18 15:25:24 +02:00
Andreas Bircher 9fe95275bb removing unnecessary parts 2016-08-18 15:12:39 +02:00
Andreas Bircher 70cd06bc84 initial version camera turn on / off 2016-08-18 15:12:39 +02:00
Lorenz Meier a97c5ec4e1 MPU6K compile and code style fixes 2016-08-18 13:50:29 +02:00
Lorenz Meier 3d1f1522d9 MPU6K driver improvements 2016-08-18 12:55:54 +02:00
sander 1efe011522 code style 2016-08-17 23:58:04 +02:00
sander 5bb36162be Start time based transition blending half-way 2016-08-17 23:58:04 +02:00
sander e6834579e5 Use altitude acc rad 2016-08-17 23:58:04 +02:00
sander 7afa21ebb7 Revert altitude acceptance radius to combat overshoot 2016-08-17 23:58:04 +02:00
Mark Whitehorn f1a1c9d7da add breakpoint and slope params for TPA 2016-08-17 23:15:36 +02:00
Mark Whitehorn 5c78af0f36 simple linear throttle PID attenuation test 2016-08-17 23:15:29 +02:00
JochiPochi 31e634b082 mpu6000 driver: set icm registers only on icm devices 2016-08-17 20:50:44 +02:00
JochiPochi e3557e0d3e mpu6000 driver: Add DLPF set function for IMC20608 2016-08-17 20:50:44 +02:00
JochiPochi ce27cc8326 mpu6000: Separate DLPF params for MPU and ICM family of sensors 2016-08-17 20:50:44 +02:00
Lorenz Meier 9f9c51eab3 Fix MPU6500 devtype define 2016-08-16 23:32:44 +02:00
James Goppert 7472c9033b Formatting fix. 2016-08-16 01:39:47 -04:00
Lorenz Meier 73362f325b Update mapping 2016-08-15 23:31:58 +02:00
Lorenz Meier 39ce001c41 MAVLink: use only the memory it needs 2016-08-15 19:53:21 +02:00
Lorenz Meier d810726c6e EKF2: Only use the memory it needs 2016-08-15 19:53:21 +02:00
Lorenz Meier a7ad722b98 Use less memory for ESC driver 2016-08-15 19:53:21 +02:00
Lorenz Meier 7cc0b32e74 Make altitude more efficient and estimator status safe in terms of memory overflow 2016-08-15 19:53:21 +02:00
Lorenz Meier 5786b73772 Tweak startup order for memory 2016-08-15 19:53:21 +02:00
Lorenz Meier a130b6a65c style cleanup 2016-08-15 19:53:21 +02:00
Lorenz Meier 1a9688c42f Commander: signal high memory usage 2016-08-15 14:58:33 +02:00
Lorenz Meier 8934aaa912 Load mon: populate memory usage i field for NuttX 2016-08-15 14:53:48 +02:00
Lorenz Meier eceb7e21b2 Include memory in CPU load message 2016-08-15 14:53:26 +02:00
Lorenz Meier 8b66a76432 Fix FMU init 2016-08-15 10:49:43 +02:00
Lorenz Meier 4b9e1d58f7 Fix ESC driver to also include direction information 2016-08-15 10:49:43 +02:00
Lorenz Meier 0c9ead44f1 Update ASCv1 template 2016-08-15 10:49:43 +02:00
Lorenz Meier e6dcc0a2ed Complete ASC config 2016-08-15 10:49:43 +02:00
Lorenz Meier 90b5fcc1ec Strip tone alarm 2016-08-15 10:49:43 +02:00
Lorenz Meier 7ef8d197c6 Patch up ASC config 2016-08-15 10:49:43 +02:00
James Goppert b36d705688 Update matrix. (#5310) 2016-08-12 14:24:35 -04:00
James Goppert bedf081d92 Sitl gazebo update. (#5309) 2016-08-12 13:49:48 -04:00
Lorenz Meier 5d0f57d61e Update Makefile to build for QGC 2016-08-12 13:55:16 +02:00
Lorenz Meier 0551275b9c Update prototype and board ID 2016-08-12 13:55:16 +02:00
Lorenz Meier ed6c63e48f TAPv1: Harmonize with FMUv1 (since they are pretty much the same) 2016-08-12 13:55:16 +02:00
Lorenz Meier f231feb0f6 FMUv1: Harmonize with FMUv2 2016-08-12 13:55:16 +02:00
Lorenz Meier 39303aa87a Set default battery config 2016-08-12 13:55:16 +02:00
David Sidrane ac1003875a USB Fix:iForce Soft Disconnect
The STM32F404 OTG FS has an internal soft pull-up.

The HW also has one too. So we need to overcome it to force a soft disconnect.
2016-08-12 13:55:16 +02:00
David Sidrane 6f973f1d6c Better Portability with clear naming 2016-08-12 13:55:16 +02:00
David Sidrane b9d93f2cad OTG_FS_ID that is on PA10 is managed by stm32 otg fs device Driver
N.B The driver set FDMOD, Force device mode and Writing a 1 to this bit
forces the core to device mode irrespective of the OTG_FS_ID input
pin.
2016-08-12 13:55:16 +02:00
David Sidrane 6173649c43 Minor corrections 2016-08-12 13:55:16 +02:00
Lorenz Meier 8bd4a624a7 Added voltage scaling. Need to move this to board_config.h instead 2016-08-12 13:55:16 +02:00
Lorenz Meier d21023c966 FMU: Power on radio if prsent 2016-08-12 13:55:16 +02:00
Lorenz Meier 2fad39aaae tap: Init both USB pins 2016-08-12 13:55:16 +02:00
Lorenz Meier 3fff9e5826 Harmonize TAP config with FMUv4 config 2016-08-12 13:55:16 +02:00
Lorenz Meier 3203d3f770 More USB buffer 2016-08-12 13:55:16 +02:00
Lorenz Meier 7e878e221c FMUv4: Code style 2016-08-12 13:55:16 +02:00
Lorenz Meier 5678b4cc83 Enable RC lib 2016-08-12 13:55:16 +02:00
Lorenz Meier 957b01a8eb Enable serial for RC input 2016-08-12 13:55:16 +02:00
Lorenz Meier 63275ef92f Sensors: Perform init on best effort basis 2016-08-12 13:55:16 +02:00
Lorenz Meier c3022bf713 FMU: Accomodate serial only RC input 2016-08-12 13:55:16 +02:00
Lorenz Meier 1c0a494b4d Code style 2016-08-12 13:55:16 +02:00
Lorenz Meier 64e47f2fae Boot improvements for TAP 2016-08-12 13:55:16 +02:00
Lorenz Meier a52d0ca00a Remove hysteresis tests on Mac OS 2016-08-12 13:53:02 +02:00
Andreas Antener 2e44fe9edd update previous waypoint before transition command 2016-08-12 11:50:38 +02:00
Lorenz Meier 5175d45e74 Update Gazebo 2016-08-11 22:07:19 +02:00
Andreas Antener 5eaf104318 fixed optimal recovery condition 2016-08-10 22:47:26 +02:00
Andreas Antener 853a5b77fd disabled attitude setpoint change in MC controller when optimal recovery is active 2016-08-10 22:47:26 +02:00
Andreas Antener 9087ef5990 only recalculate rotation matrix and quaternion when not in velocity control 2016-08-10 22:47:26 +02:00
Andreas Antener ae533b01b6 removed unused code 2016-08-10 22:47:26 +02:00
David Sidrane deeefe5dd1 Describe the issues that requires the +=2 on arg[c|v] for NuttX (#5293)
This may be moot and should be revisited if only px4_getops is used, but this pr politely documents the reson for the logic.
2016-08-10 06:19:59 -10:00
Lorenz Meier 17561daefb TAP power: Shut down faster 2016-08-10 12:33:04 +02:00
Andreas Daniel Antener 9f4a91ab19 initialize waypoint transfer sequence with -1 (#5274) 2016-08-10 08:39:54 +02:00
huanglilong 6f7b78821a fix fake gps bugs (#5285) 2016-08-09 21:24:11 +02:00
Lorenz Meier c62b886da5 Ua venture hottupdate (#5289)
* Change default port to Serial4 and improve status outputs.

* Reduce stack size.
2016-08-09 21:19:41 +02:00
Lorenz Meier b8c377b91a Temporarily disable new logger 2016-08-09 16:00:42 +02:00
Lorenz Meier a664747d0a Remove unused sensors 2016-08-09 16:00:28 +02:00
Lorenz Meier 43f772154c TAP: adjust ESC buffer size 2016-08-09 16:00:00 +02:00
Lorenz Meier aae3a37983 GPS: Do not use nonblocking access 2016-08-09 15:59:34 +02:00
Daniel Agar 12a5ce7a0a temporarily disable uorb test on OSX (#5280) 2016-08-08 20:59:24 -04:00
Lorenz Meier 630cebeabc Relax uORB test for Darwin CI system 2016-08-07 14:05:03 +02:00
Lorenz Meier e24d18f810 Hysteresis test: Relax time for all tests for OS X CI system 2016-08-07 14:05:03 +02:00
Lorenz Meier 207a04bba0 Fix uORB tests for Mac OS 2016-08-07 14:05:03 +02:00
Lorenz Meier ead8e31de4 Hysteresis test: Fix for Mac OS CI 2016-08-07 14:05:03 +02:00
Lorenz Meier 7b5917567a Fix Mixer test for OS X 2016-08-07 14:05:03 +02:00
Daniel Agar 8b9bef3872 osx fix and enable tests 2016-08-07 14:05:03 +02:00
Roman Bapst ba047f234d ekf2 replay: added magic values for range min/max distance (#5268)
- replay was not working without these values as only range measurements
were given to the filter which were between the min/max value

Signed-off-by: Roman <bapstroman@gmail.com>
2016-08-07 11:30:54 +02:00
Lorenz Meier 393acf2231 Start ESC drivers 2016-08-07 11:15:48 +02:00
Lorenz Meier 0e9c352927 Simplify TAP config 2016-08-07 11:15:48 +02:00
David Sidrane c5e11cd16f TAP:Added i2c speed setting to init 2016-08-07 11:15:48 +02:00
David Sidrane e8ae0fe13c Made the MPU6000 driver a highbread using both hrt for SPI or workqueue for I2C 2016-08-07 11:15:48 +02:00
David Sidrane 5f342c3b5f Added I2C to MPU6000 driver 2016-08-07 11:15:48 +02:00
Lorenz Meier a0cad961b3 Remove non-used app from config 2016-08-07 11:12:20 +02:00
Lorenz Meier 58135d892b Sync estimator CMake configs for all boards 2016-08-07 10:40:17 +02:00
Lorenz Meier 990304ee22 Fix check code style to work on Mac OS 2016-08-07 10:40:17 +02:00
Lorenz Meier a73d5037f2 Fix FMUv4 build 2016-08-07 10:40:17 +02:00
Lorenz Meier cf776aeb0a Fix compilation of examples 2016-08-07 10:40:17 +02:00
Lorenz Meier 148b6e6135 Update CMake config paths 2016-08-07 10:40:17 +02:00
Lorenz Meier cba4bcd2fb Multiplatform controllers: Move to examples and fix code style 2016-08-07 10:40:17 +02:00
Lorenz Meier ee5cdab963 Move old estimators to examples 2016-08-07 10:40:17 +02:00
Daniel Agar cff9e90bec position_estimator_inav fix and enforce code style 2016-08-07 10:40:17 +02:00
Daniel Agar 4049ec2e96 mc_pos_control fix and enforce code style 2016-08-07 10:40:17 +02:00
Daniel Agar d4196f7f0c mc_att_control fix and enforce code style 2016-08-07 10:40:17 +02:00
Daniel Agar 8f01324890 ekf2 fix and enforce code style 2016-08-07 10:40:17 +02:00
Daniel Agar 968a3d499b add make format (check_code_style_all.sh --fix) 2016-08-07 10:40:17 +02:00
Daniel Agar a260a6eead check code style list unformatted modules 2016-08-07 10:40:17 +02:00
Lorenz Meier 61d5d8ce2a Makefile: Remove remaining EKF2 config bits 2016-08-07 10:39:51 +02:00
Lorenz Meier 3cc64b3b7b LPE: Remove unused var 2016-08-07 10:39:31 +02:00
Lorenz Meier fb4c620f94 Replace EKF1 with EKF2 in rover config 2016-08-06 23:34:35 +02:00
Julian Oes 68986604e9 df_mpu9250_wrapper: calibration after rotation
Same as for the df_hmc5883_wrapper.
2016-08-06 21:01:37 +02:00
Julian Oes 1dd2c94949 df_hmc5883_wrapper: use calibration after rotation
The calibration values need to be applied after the rotation, otherwise
the offsets and scale can be applied to the wrong axes.
2016-08-06 21:01:37 +02:00
Daniel Agar 2a15578f8d FW implement MAV_CMD_DO_GO_AROUND 2016-08-06 20:56:53 +02:00
Hidenori aa3ffa28c8 add copyright header 2016-08-06 20:47:55 +02:00
Hidenori 5920711c20 fix style 2016-08-06 20:47:55 +02:00
Hidenori eded7bf772 Navio: add rgbled test and tweak implementation 2016-08-06 20:47:55 +02:00
Hidenori 9a5f88d6bf Navio: fix GPIO register definition 2016-08-06 20:47:55 +02:00
Hidenori ff647e7bc8 Navio: GPIO driver command fix and update ifdefs 2016-08-06 20:47:55 +02:00
Hidenori 3049b9af01 Navio2: add support for GPIO and RGBLED 2016-08-06 20:47:55 +02:00
Lorenz Meier 40ba3f5131 Initial config for ASC module 2016-08-06 20:45:11 +02:00
Beat Küng c0e3ab632e orb: proper locking for DeviceNode::{add,remove}_internal_subscriber 2016-08-06 20:44:23 +02:00
Beat Küng b86cf2b017 orb status: print information about lost messages 2016-08-06 20:44:23 +02:00
Beat Küng 7280f71cef orb: rm static from DeviceMaster::_node_map & use the non-static getDeviceNode in uORB::Manager
Reasons:
- DeviceMaster::_node_map does not need to be shared among instances,
  because there is at most 1 instance per Flavor and different Flavors
  have non-intersecting device paths.
- Keeping it static would also require a static lock
- DeviceMaster::_node_map was not locked at all when used from
  uORB::Manager

So this fixes two synchronization issues:
- Different DeviceMaster objects could access the same static data in
  parallel
- getDeviceNode() called from uORB::Manager did not use any locking at all
2016-08-06 20:44:23 +02:00
Beat Küng 45a0a7c5ab refactor orb: uORB::Manager is responsible for the DeviceMaster objects
This has the following benefits:
- Manager can ensure that there is at most one instance of DeviceMaster
  per Flavor
- The Manager needs access to (static) data of DeviceMaster already.
  This will make it easier to access this data in a non-static way, and
  does not introduce new dependencies.
2016-08-06 20:44:23 +02:00
Andreas Antener 2dd29ec4a1 VTOL: publish stabilized FW attitude to correct topic 2016-08-06 20:43:49 +02:00
Lorenz Meier c97a18b6a4 Fix README name 2016-08-06 20:42:44 +02:00
h3ct0r 3deefb1a79 Fixed some edge cases on the geo_tag_images.py script. Added explanation to the --kml function. Added more examples for the execution of the script. 2016-08-06 20:42:24 +02:00
Beat Küng 124e1c26d9 gps injection: use the orb queuing API instead of multiple instances
It uses a queue length of 6. There are 3 RTCM msgs/s, but due to
fragmentation and WiFi lags, there can be more than that. During several
tests, a length of 6 showed no queue overflows.
2016-08-06 20:41:38 +02:00
sander 9398a4819f Only check mission when needed 2016-08-06 20:40:41 +02:00
Julian Oes 3e87ec5153 navigator: mission check refactor
The mission feasability checker was called with the same arguments
twice which made it hard to understand when a mission is marked valid.

The mission check should run in these two cases:
- When initializing (if home comes up) if there is already a mission saved.
- When the mission gets updated.
2016-08-06 20:39:56 +02:00
Lorenz Meier c76c8fda04 MC pos control: Drop default position controller gain 2016-08-06 11:50:08 +02:00
Lorenz Meier bcd5f98cb1 Navigator: Fix mission feedback and wording 2016-08-06 10:34:20 +02:00
Roman 278b607f62 Update ECL library 2016-08-06 10:18:58 +02:00
Lorenz Meier 37230f4c5d Revert "navigator: mission check refactor"
This reverts commit a956429c4c.
2016-08-05 22:10:34 +02:00
Lorenz Meier 102f5b54d7 Revert "Improvements to SITL to make paths more flexible. (#5181)"
This reverts commit 699b6a2cb3.
2016-08-05 21:29:49 +02:00
Mark Whitehorn bbe3525377 fix VTOL vehicle_status timestamp (#5252)
* fix VTOL vehicle_status timestamp

* run astyle
2016-08-05 17:00:12 +02:00
James Goppert 6ac79aa55f Formatting. 2016-08-05 06:52:35 -04:00
Lorenz Meier 08f5ece306 Remove on arming reset, be less verbose in normal conditions output 2016-08-05 06:51:54 -04:00
James Goppert 699b6a2cb3 Improvements to SITL to make paths more flexible. (#5181) 2016-08-05 06:23:59 -04:00
sander bc7178c538 Allow mission with active DL and DLL failsafe off 2016-08-05 10:19:06 +02:00
sander e8a87538b8 Code style 2016-08-05 10:19:06 +02:00
sander 95e80cc29b Only RTL when mission finishes mid air on DL Lost 2016-08-05 10:19:06 +02:00
Julian Oes a956429c4c navigator: mission check refactor
The mission feasability checker was called with the same arguments
twice which made it hard to understand when a mission is marked valid.

The mission check should run in these two cases:
- When initializing (if home comes up) if there is already a mission saved.
- When the mission gets updated.
2016-08-05 10:17:06 +02:00
Michael Schaeuble 8566cabd76 Make some code-style fixes 2016-08-05 10:15:11 +02:00
Michael Schaeuble a3a855203c Update Bebop mainapp.config with new functionality 2016-08-05 10:15:11 +02:00
Michael Schaeuble 8351afdca8 Initialize mag scaling with reasonable defaults 2016-08-05 10:15:11 +02:00
Michael Schaeuble 6aa8fcdf53 Enable commander module for Parrot Bebop 2016-08-05 10:15:11 +02:00
Michael Schaeuble 0b7fa4f5ad Apply sensor calibration after coordinate frame rotation 2016-08-05 10:15:11 +02:00
Michael Schaeuble e600e29ea4 Add DF wrapper for AK8963 2016-08-05 10:15:11 +02:00
Lorenz Meier 0481c002df Navigator: Initialize subscription and disallow copy constructors for classes that have pointer members 2016-08-05 10:13:52 +02:00
Lorenz Meier 074a71173b Systemlib: Address init and copy constructors 2016-08-05 10:13:24 +02:00
Lorenz Meier db174cf8b1 Disable EKF2 3D fusion temporarily in SITL, fix missing fast-init params for some configs 2016-08-05 10:12:44 +02:00
Bart Slinger 815c367294 Add helicopter airframe icon (#5234) 2016-08-04 17:26:17 +02:00
Beat Küng 8aa3b245a5 fix sdlog2: use LOG_DGPS_MSG for second gps (#5235) 2016-08-04 17:18:02 +02:00
Julian Oes aaeeb1684d DriverFramework: update submodule (#5233)
This brings support for the Ak8963 for Bebop.
2016-08-04 16:04:02 +02:00
Vasily Evseenko aa0c89c3ec Fix i2c collision with rgbled 2016-08-04 15:09:33 +02:00
Vasily Evseenko b4d9f44904 Wait conversion_interval before first measurement 2016-08-04 15:09:33 +02:00
Vasily Evseenko 078aca1966 Fix SENS_EN_SF1XX description 2016-08-04 15:09:33 +02:00
Vasily Evseenko 6689a3d1b1 Add SENS_EN_SF1XX param to specify sensor model
Fix missing orb_unadvertise on shutdown
Fix missing closing of file descriptors
2016-08-04 15:09:33 +02:00
Vasily Evseenko 6d3aba1c5f Fix code style 2016-08-04 15:09:33 +02:00
Vasily Evseenko 49844f52d5 Fix SF10a driver. Add support for SF11c and rename to SF1xx 2016-08-04 15:09:33 +02:00
Julian Oes 00d4eae373 attitude_estimator_q: don't filter output rates
Since we're already filtering the incoming gyro and accel sensor
signals, we don't need to filter the output rates again.
2016-08-04 11:33:44 +02:00
Julian Oes ea9c8b968a attitude_estimator_q: don't spam console
We should not spam the console just because the input data is
degenerate, it would only make things worse because everything would
slow down due to the printfs.
2016-08-04 11:33:44 +02:00
Julian Oes d748f6ca71 attitude_estimator_q: filter accel and gyro data
Since accel and gyro are not filtered in the drivers anymore, we need to
filter them in this estimator in order to achieve a similar performance.
2016-08-04 11:33:44 +02:00
Eike cfa203ca22 Remove LPOS.Z reset (#5228) 2016-08-04 11:32:26 +02:00
Mark Whitehorn 422cf7e21c assign timestamp in vtol vehicle_rates_setpoint message (#5227) 2016-08-04 08:22:33 +02:00
James Goppert eeb73888fd update sitl_gazebo (#5224) 2016-08-03 18:46:25 -04:00
Andreas Daniel Antener f3c5c2c5a9 use thrust scale parameter for vtol pusher support (#5207) 2016-08-03 23:41:01 +02:00
James Goppert feccb9bfc1 Make integraiton test script work with kinetic. 2016-08-03 17:17:07 -04:00
Lorenz Meier 5b06b40ed9 Set SITL as default target now that Pixhawk is not necessarily the default HW 2016-08-03 23:04:35 +02:00
Lorenz Meier e287b05d67 NuttX: Add file change which allows really fast log download 2016-08-03 21:10:34 +02:00
Nate Weibley 547592fddf Use a persistent file* and seek less for log download
Opening/seeking/closing the file for each data chunk was extremely
expensive and drastically slowed the download process as the position
in the file increased. Over USB with large files this change + nuttx
update results in ~ 10x speedup for log downloads.
2016-08-03 14:33:01 -04:00
James Goppert 391eb7f8df Sitl update. (#5220) 2016-08-03 13:19:26 -04:00
Andreas Antener 579d420db1 VTOL: enable MC motors after instant back transition 2016-08-03 13:56:07 +02:00
Andreas Antener 86d1488e52 added missing const keyword 2016-08-02 21:09:45 +02:00
Andreas Antener d089c427ec quadchute code style fix 2016-08-02 21:09:45 +02:00
Andreas Antener 6f1eda2b18 added single point to decide if we need quadchute, let the reason be passed from the source where we know what's going on 2016-08-02 21:09:45 +02:00
Andreas Antener 92ddc30b69 moved min alt param 2016-08-02 21:09:45 +02:00
Andreas Antener 92185945bc make quadchute work during transitions 2016-08-02 21:09:45 +02:00
sander 0cc44a82c5 Code style 2016-08-02 21:09:45 +02:00
sander 45a4472a47 Do not apply back transition duration for QuadChute 2016-08-02 21:09:45 +02:00
Andreas Antener bae5416819 removed duplicate memset 2016-08-02 21:05:00 +02:00
Lorenz Meier 033e9e140d Update MAVLink 2.0 version 2016-08-02 14:55:12 +02:00
Lorenz Meier e2d1524a7a Mission feasibility checker: Better feedback for landing waypoints 2016-08-02 14:54:40 +02:00
Lorenz Meier 670b0f7c6d Commander: MAVLink is an off-vehicle API we should not depend internally on 2016-08-02 14:54:16 +02:00
James Goppert 437221bec2 Make LPE default estimator. (#4483) 2016-08-02 02:02:01 -07:00
Beat Küng c22e7ed5c9 Tools/mavlink_shell.py: implement a simple shell with history 2016-08-02 09:10:18 +02:00
Beat Küng aefa319fc4 fw_pos_control_l1: fix compiler problem (implicit float conversion) (#5198)
issue (GCC 6.1.1):
../src/modules/fw_pos_control_l1/fw_pos_control_l1_main.cpp:1284:27: error: implicit conversion from ‘float’ to ‘double’ to match other operand of binary expression [-Werror=double-promotion]
  if ((fabs(air_gnd_angle) > M_PI) || (ground_speed_2d.length() < 3.0f)) {
2016-08-02 00:04:44 -07:00
Vasily Evseenko 457526ebe7 Don't push bad values from lidar to EKF2 (#5196)
Report terrain altitude
2016-08-01 23:30:40 -07:00
James Goppert a58c2f416f Update sitl_gazebo. (#5195) 2016-08-01 15:30:31 -04:00
Julian Oes ccea9c9e6f fmu: flash safety button correctly even disabled (#5189)
If the circuit breaker to disable IO safety is engaged, the safety
button should still blink in the appropriate pattern: double flash for
safety off, solid on for armed.
2016-08-01 02:18:36 -07:00
Julian Oes 623b99327d param: lock the bus as short as possible (#5187)
Since the FRAM and the baro are on the same bus on the Pixracer, we
currently need to lock down everything (instead of just this SPI bus)
for the time when the params are written.
Therefore, we need to keep this locking as short as possible.

This change makes the locking even shorter by moving all param_get and
param_name and param_size calls out of the lock.
2016-08-01 02:15:21 -07:00
sander 5710a0c040 Remove default geofence from gazebo_standard_vtol 2016-07-31 22:09:44 +02:00
Lorenz Meier a38263b8e7 Enforce enough braking power when users set higher horizontal speeds 2016-07-31 17:43:15 +02:00
Julian Oes dd70b3752a mpu9250: set accel DLPF to 41 Hz (#5177)
Previously, the accel DLPF was not set, so it's not clear what the
settings are or should be.
2016-07-31 08:04:01 -07:00
Lorenz Meier d809faec63 Fixes for Gazebo 2016-07-31 16:52:53 +02:00
Julian Oes 21bc5d1716 land_detector: remove leftover printf (#5178) 2016-07-31 07:49:11 -07:00
Lorenz Meier 4e81263d3a Updated Tools/sitl_gazebo 2016-07-31 15:56:35 +02:00
Lorenz Meier 11f1a11934 Lock yaw integral if we hit a yaw limit 2016-07-31 14:14:55 +02:00
Lorenz Meier a1c8585342 EKF2: Report zero as position until local pos is valid 2016-07-31 14:01:32 +02:00
Lorenz Meier c835fb36a6 5611: Bump sampling frequency back up to 40 Hz from 25 Hz to help with altitude estimation 2016-07-31 12:20:48 +02:00
Julian Oes 0d80a77e46 unit_tests: move hysteresis test to new framework 2016-07-30 12:26:56 +02:00
Julian Oes 8f1d350d3c unit_test: add ut_assert_true and ut_assert_false 2016-07-30 12:26:56 +02:00
Julian Oes 6bf4bd5f35 land_detector: remove unused variable 2016-07-30 12:26:56 +02:00
Julian Oes 50cac88e5b land_detector: big refactor, share update function
This is a big refactor and general cleanup of the land detector. The
main functional change is to share the hysteresis lib across all land
detectors.
2016-07-30 12:26:56 +02:00
Julian Oes 9f928308c4 land_detector: astyle 2016-07-30 12:26:56 +02:00
Julian Oes 3d0fa410a8 hysteresis: astyle 2016-07-30 12:26:56 +02:00
Julian Oes fd6ad6565c commander: use hysteresis lib for auto_disarm
Since the auto disarm hysteresis was implemented wrongly, it's now
replaced with the hysteresis library call.
2016-07-30 12:26:56 +02:00
Julian Oes f7ad8c03b4 hysteresis: use 64bit for everything in us 2016-07-30 12:26:56 +02:00
Julian Oes 93acff8641 MulticopterLandDetector: remove always true call
The result from `!get_freefall_state()` was always true because
`get_freefall_state()` is already called before `get_landed_state()` is
called. Only if we're not in a freefall, we check if we are landed.
2016-07-30 12:26:56 +02:00
Julian Oes 740bfc0b32 MulticopterLandDetector: use hysteresis lib
The hysteresis was not properly implemented in the land detector and is
therefore replaced by the library call, both for the freefall detector
and the land detector.
2016-07-30 12:26:56 +02:00
Julian Oes ee1669e174 hysteresis: add to systemlib CMakeLists.txt 2016-07-30 12:26:56 +02:00
Julian Oes f365832c0b hysteresis: we needed different hysteresis
Sometimes, we only need a histeresis in one direction.
2016-07-30 12:26:56 +02:00
Julian Oes 401d807261 systemlib: added library for hysteresis
There have been two cases where a hysteresis function wasn't working
correctly. It is therefore a good idea to abstract the hysteresis
functionality into a library.
2016-07-30 12:26:56 +02:00
Julian Oes 36299c59b4 unittests: whitespace 2016-07-30 12:26:56 +02:00
sander 788f04ea58 Remove debug info 2016-07-30 11:43:52 +02:00
sander 94fc8bda02 Fix indenting 2016-07-30 11:43:52 +02:00
sander 2bca19fc5e Remove acceptance radius from takeoff altitude for MC 2016-07-30 11:43:52 +02:00
sander e4f20f98cd Implement altitude acceptance radius 2016-07-30 11:43:52 +02:00
Lorenz Meier b5ef5cabb5 Updated src/drivers/gps/devices 2016-07-30 11:40:50 +02:00
James Goppert 5f16c97662 Added mb12xx sensor enable. (#5164) 2016-07-29 16:18:27 -04:00
Daniel Agar 390a7165dd make tests (#5163)
* make tests use px4 instead of mainapp

* commander_tests ALTCTL - not rotary requires altitude
2016-07-29 11:46:47 -04:00
Julian Oes 5a262ec6bc uorb: came across a wrong comment 2016-07-29 17:44:50 +02:00
Julian Oes a18eabead4 navigator: whitespace 2016-07-29 17:44:50 +02:00
Daniel Agar 2de66b1a9d FW navigation in high winds (#5097) 2016-07-29 06:05:48 -07:00
Beat Küng ad2a13dcc8 cmake TAP config: add topic_listener 2016-07-29 14:50:03 +02:00
Beat Küng 0fa3bd4691 ms5611: use px4_getopt instead of getopt
- px4_getopt is threadsafe
- getopt does not do argument reordering (ms5611 start -T 5607 did not work)
2016-07-29 14:50:03 +02:00
David Sidrane 1b0f41e36e Added support to MS5611 Driver for MS5607 2016-07-29 14:50:03 +02:00
Lorenz Meier fa421a91e2 Add missing teest targets for MindPX 2016-07-29 14:10:44 +02:00
Lorenz Meier 6ab9dc0acf Testing cleanup from Daniel Agar 2016-07-29 13:49:14 +02:00
Daniel Agar 99aa5f49fc FW ALTCTL requires altitude 2016-07-29 13:48:21 +02:00
Daniel Agar 6aa935fed6 FW don't allow ACRO or RATTITUDE 2016-07-29 13:48:21 +02:00
Lorenz Meier e70223c2be Allow transition commands also in manual if no switch is used 2016-07-29 13:43:24 +02:00
Roman 1f1839d978 sensors: fixed code style
Signed-off-by: Roman <bapstroman@gmail.com>
2016-07-29 13:28:09 +02:00
Roman 9ece090dbe vtol_att_control: use transition switch instead of aux1
Signed-off-by: Roman <bapstroman@gmail.com>
2016-07-29 13:28:09 +02:00
Roman 499d362b8b added transition switch 2016-07-29 13:28:09 +02:00
Beat Küng 302719527a nuttx defconfig: increase nr of file descriptors, due to mavlink shell 2016-07-29 13:07:17 +02:00
Beat Küng e8d44da2c0 Tools: add mavlink_shell.py script to start a shell over mavlink 2016-07-29 13:07:17 +02:00
Beat Küng 2241ab9cac mavlink: add a shell using SERIAL_CONTROL MAVLink message 2016-07-29 13:07:17 +02:00
Julian Oes 78a9472b25 px4iofirmware: astyle 2016-07-29 12:46:17 +02:00
Julian Oes dcb7c0e4c2 px4iofirmware: correct newline 2016-07-29 12:46:17 +02:00
Julian Oes 79a1b84b09 px4iofirmware: clean up override decision
The override checking was scattered across two places and is now unified
in controls_tick(). The part in mixer_tick only decides which mixer (or
none) to use give the override flag.
2016-07-29 12:46:17 +02:00
Julian Oes de76c398ca px4io: whitespace fixes 2016-07-29 12:46:17 +02:00
Julian Oes ec035b7268 px4iofirmware: no override in multirotor mode
This fixes a bug where multirotors got into override mode when the FMU
is dead/not responding.
The main bug was that the check was for FMU_OK || MANUAL_OVERRIDE_OK
in order to get further in the override checks.

Also a mixer_tick was called inside the controls_tick even though these
are called in px4io.c after each other anyway.
2016-07-29 12:46:17 +02:00
Julian Oes 57b3bbf657 px4iofirmware: don't set FMU_OK flags immediately
The FMU_OK flags are later checked anyway based on
system_state.fmu_data_received_time.
2016-07-29 12:46:17 +02:00
Julian Oes 31d5c59ab7 px4iofirmware: remove unused define 2016-07-29 12:46:17 +02:00
Julian Oes a9a5f3a19e px4io: add FMU fail test mode
In order to test what happens in px4iofirmware when the FMU stops
sending PWM or control commands, I added a test mode. When the test mode
is activated, no controls are sent.
2016-07-29 12:46:17 +02:00
Julian Oes 55d21242fe Snapdragon: keep copying mainapp.config for now
mainapp.config can't be renamed to px4.config just yet because it would
clash with the name used for the DSP side.
2016-07-29 11:15:10 +02:00
James Goppert b6a9ff756c Rename mainapp to px4. 2016-07-29 11:05:01 +02:00
Sebastian Quilter 3b7ba915a8 small refactor (#5155) 2016-07-28 14:49:37 -07:00
Eric Ye 9f5b081257 Wrap help line to fit through mini-dm. (#5157)
It currently gets cut off on mini-dm, split it into multiple lines
so all of it comes through.
2016-07-28 14:47:57 -07:00
sander 4b414d96eb Init _mission_throttle 2016-07-28 16:44:27 +02:00
sander 0ce08ed9f8 Code style 2016-07-28 16:44:27 +02:00
sander ce3749d04f Make tecs init airspeed mode dependent 2016-07-28 16:44:26 +02:00
sander 0cf77a30b1 Init tecs with transition airspeed for vtols without airspeed sensor 2016-07-28 16:44:26 +02:00
David Sidrane 415fbae31e Fix build for HW w/o mux 2016-07-28 08:50:59 +02:00
Beat Küng 50a14cfd29 tap_esc: disable the _mode param, use the number of configured channels instead
Not sure why the Mode enum exists in the first place...
2016-07-28 08:50:59 +02:00
Beat Küng 3a0f4c84a5 motor_test: add iterate command 2016-07-28 08:50:59 +02:00
Beat Küng cbcbce3a28 tap_esc: use correct number of outputs 2016-07-28 08:50:59 +02:00
Beat Küng 6245a9b134 motor_test: make -m & -p optional (select all motors/0 output if not given) 2016-07-28 08:50:59 +02:00
Beat Küng d660fb094b tap_esc: add RPMSTOPPED macro, make sure driver starts with stopped motors 2016-07-28 08:50:59 +02:00
Beat Küng d6d3a56116 tap_esc: add buffer size check for _esc_feedback.esc[] 2016-07-28 08:50:59 +02:00
Beat Küng c55c978145 tap_esc: reset outputs only when armed really changed (not on each topic update) 2016-07-28 08:50:59 +02:00
Beat Küng 4045068187 tap_esc: properly initialize _outputs 2016-07-28 08:50:59 +02:00
Beat Küng 8602ff7856 tap_esc: fix code style, IS_armed -> _is_armed 2016-07-28 08:50:59 +02:00
Beat Küng 3f9f320f18 tap_esc: improve error handling & reporting 2016-07-28 08:50:59 +02:00
Beat Küng a8e28c7232 tap_esc: fix argument ordering in memset 2016-07-28 08:50:59 +02:00
David Sidrane 632e4630b1 TAP:ESC motors and LED working - The code is still hardcoded for 4 ESC
But the basics are working. N.B. To Stop the moros a value of 0 need to be
sent. LED color mask are misleeding - LED is On or Off per ESC.
2016-07-28 08:50:59 +02:00
Julian Oes a71cfe92f1 fmu: whitespace fix 2016-07-28 08:49:22 +02:00
Julian Oes 664092b7d4 fmu: support ESC calibration
The FMU was lacking support to do the ESC calibration. This is needed
for Pixracer.
2016-07-28 08:49:22 +02:00
Julian Oes 3289e0cee6 fmu: don't disarm with disarmed set
If disarmed PWM values have been set, we can't accept a disarm command.
If we did, the PWM output stop alltogether after the high pulse of the
ESC calibration.
2016-07-28 08:49:22 +02:00
Julian Oes d63870ad71 fmu: don' de-initialize
Once the PWM outputs are initialized, there is no point in
de-initializing them again.
2016-07-28 08:49:22 +02:00
Julian Oes f4e35873a1 DriverFramework: updated submodule (#5148)
This brings fixes for Edison which should not have any influence on
Snapdragon or Raspberry Pi.
2016-07-27 23:47:53 -07:00
Sander Smeets c4eb65862f Reduce esc calibration pwm timeout (#5011) 2016-07-27 01:52:20 -07:00
Daniel Agar a9cb2d2fbe navigator mission don't report loiter if landed 2016-07-27 10:39:07 +02:00
Julian Oes c4cb916afa Fix sdlog2/logger path/file name overflows. (#5138)
* logger: prevent logpath buffer overflows

The handling of the log path had the potential to cause buffer
overflows, especially on POSIX platforms where the paths are often much
longer than just 64 chars.

* sdlog2: prevent logpath buffer overflows

When the log folder path was created, this was done with the unsafe
sprintf function instead of snprintf. This caused buffer overflows in
SITL but the overflow was usually not detected until recent testing of
some work in progress.
2016-07-27 00:55:29 -07:00
Julian Oes 4656b34244 DriverFramework: update submodule
This fixes a gyro/accel scaling bug on Snapdragon.
2016-07-26 17:11:29 +02:00
Beat Küng 4fa59c3cde sdlog2 README: describe geotagging.py script 2016-07-26 10:20:22 +02:00
h3ct0r b6e57e1347 Added geo tagger script to geo reference any set of arbitraty JPG images that does not have the CAM trigger, but have a valid creation date 2016-07-26 10:14:51 +02:00
Julian Oes 83feb83fe2 cmake: don't build load_mon for POSIX/QURT 2016-07-26 09:58:12 +02:00
Gus Grubba c3b58822a8 Fixes to log download (#5133)
* Fixes to log download

* Fixing indentation
2016-07-25 08:15:23 -04:00
Andreas Antener 50175ca7ea manual condition includes threshold values 2016-07-25 08:56:19 +02:00
Roman aea7bd5b47 fw_attitude_control: calculate attitude setpoint for STAB mode
- attitude setpoint generation for stabilized mode was shifted back
to the fw attitude controller. since the fw position controller is polling
on global position attitude setpoints were not generated when global
position was not published.

Signed-off-by: Roman <bapstroman@gmail.com>
2016-07-25 08:56:19 +02:00
Andreas Antener f069880504 VTOL: don't wait on TECS in FW state if TECS is not running 2016-07-25 08:56:19 +02:00
Andreas Antener 254358ef86 fixed implicit conversion 2016-07-25 08:56:19 +02:00
Andreas Antener 89a2f5057f fixed code style 2016-07-25 08:56:19 +02:00
Andreas Antener 6ff65cd8b2 reset attitude setpoint where necessary 2016-07-25 08:56:19 +02:00
Andreas Antener 0a997577f5 allow manual yaw in all manual modes and also use it as threshold to snap into heading lock 2016-07-25 08:56:19 +02:00
Andreas Antener 9f7f6e4d3d removed roll lock for altitude hold 2016-07-25 08:56:19 +02:00
Roman 6226a0c77d fw_pos_control_l1: fixed code style
Signed-off-by: Roman <bapstroman@gmail.com>
2016-07-25 08:56:19 +02:00
Roman ec334f7c9b fw_pos_control_l1: limit max roll and pitch setpoints for manual modes
Signed-off-by: Roman <bapstroman@gmail.com>
2016-07-25 08:56:18 +02:00
tumbili 8c8120e2fc fw position controller: logic cleanup
cleaned up logic when not to use pitch setpoint from TECS

Signed-off-by: tumbili <roman@px4.io>
2016-07-25 08:56:18 +02:00
tumbili fd51bf44d5 fw position / fw attitude control: move attitude setpoint generation to
position controller

- attitude setpoints for all modes are now computed in the fw position
controller

Signed-off-by: tumbili <roman@px4.io>
2016-07-25 08:56:18 +02:00
Roman e3f3233ee4 fw position controller: fixup attitude setpoint generation
- generate complete attitude setpoint for position and altitude
control mode
- fix generation of roll setpoint for position control which lead to
wing rock
- add roll and pitch setpoint offsets so that they are logged as well

Signed-off-by: Roman <bapstr@ethz.ch>
2016-07-25 08:56:18 +02:00
Lorenz Meier 880fa47ba2 Fix install in Mac OS X Gazebo 2016-07-24 23:09:17 +02:00
James Goppert 7458f1e07d Update sitl_gazebo. (#5136)
* Update sitl_gazebo.

* Update sitl_gazebo.
2016-07-24 17:07:14 -04:00
James Goppert 563122f5d3 sitl_gazebo update. 2016-07-24 16:30:01 -04:00
James Goppert 4f62a35993 Fixed sitl_gazebo. 2016-07-24 16:27:12 -04:00
James Goppert 05315abc89 Optical flow simulator and install cleanup. (#5132)
sitl CI is having some issue cloning, but I have verified it locally for various configs
2016-07-24 13:07:14 -04:00
Eric Ye 5cee3fa0e1 Proper return value on qshell help 2016-07-23 08:25:03 +02:00
Eric Ye 76d74640ae Add "help" to qshell for qurt
Fixes issue #5111
2016-07-23 08:25:03 +02:00
Julian Oes 7399e60e96 ecl: update submodule
This includes just some minor fixes.
2016-07-23 08:05:47 +02:00
James Goppert a4ef364f80 Added innovation logging to LPE. (#5124) 2016-07-22 19:19:30 -04:00
Henry Zhang 0730e681bc Nuttx config: MAVLink app needs more FDs. 2016-07-22 11:16:18 +02:00
Henry Zhang 2b93f16118 mindpx-v2: build topic_listener, sd_bench, tests, motor_ramp. 2016-07-22 11:16:18 +02:00
Julian Oes 317fd270d1 RPi: add mainapp.config again
This file got deleted accidentally because all .config files were in
gitignore.
2016-07-22 09:33:43 +02:00
Julian Oes b99f51a035 gitignore: don't ignore all .config files 2016-07-22 09:33:43 +02:00
Michael Schaeuble ae66085f89 MPU6050: Apply calibration after coordinate frame rotation 2016-07-22 09:21:55 +02:00
Michael Schaeuble 1fc8e38157 Fix incorrect indentation 2016-07-22 09:21:55 +02:00
Michael Schaeuble 7d11b32981 Add correct rotation for MPU6050 on Bebop 2016-07-22 09:21:55 +02:00
Michael Schaeuble 2197bf518d Fix code style 2016-07-22 09:21:55 +02:00
Michael Schaeuble 28de6d2cbd Update mainapp.config and add MPU6050 2016-07-22 09:21:55 +02:00
Michael Schaeuble d94bdb0829 Add missing defines for Bebop sensor drivers 2016-07-22 09:21:55 +02:00
Michael Schaeuble e73d8d73e1 Add DF wrapper for MPU6050 2016-07-22 09:20:27 +02:00
Beat Küng 8ab841e046 sensors: poll on best-voted gyro (#5106)
This is a follow-up to 399d4ef833
2016-07-21 14:52:32 -07:00
Beat Küng 03b3bfa98d tap: add the motor_test command to the build config 2016-07-20 14:04:15 +02:00
Beat Küng 2c0c30eadf drv_tap_esc.h: fix file permissions 2016-07-20 14:04:15 +02:00
Beat Küng 38e4882b5f tap_esc: subscribe to test_motor topic and set outputs accordingly in non-armed state
This makes it possible to use the 'motor_test' command
2016-07-20 14:04:15 +02:00
Beat Küng 0f6a6f7150 mavlink_messages.cpp: only warn once, when MAVLink log opening fails
This happens for example if no SD card is present.
2016-07-20 13:07:32 +02:00
Beat Küng 9a8c092116 mavlink_messages.cpp: fix coding style: prepend _ to class members 2016-07-20 13:07:32 +02:00
David Sidrane 5ded579bf3 TAP:More IO Init (#5096) 2016-07-19 11:58:44 -10:00
Beat Küng 7b52eced66 commander: write timestamp of commander_state topic on init and state change 2016-07-19 09:21:35 +02:00
David Sidrane a420d47797 Minor fix usage (#5094) 2016-07-18 15:01:55 -10:00
Beat Küng 5b85fdb636 fix sdlog2 replay: changed format string from 9c73eae941 (#5090) 2016-07-18 15:25:49 +02:00
James Goppert 9fcf121380 LPE: Don't use home as local origin (#5067) 2016-07-17 10:16:17 -04:00
Mark Whitehorn 981353f439 fix bug in RC scan for SUMD input 2016-07-16 16:35:03 +01:00
Julian Oes fa614a3cc1 RPi: just use RPI instead of RPI2.
The reason for this change is that RPi2 and RPi3 are compatible, and
hopefully all differences coming up can be resolved without ifdefs but
at runtime.
2016-07-16 15:51:00 +01:00
Julian Oes 2bf40efe8b RPi2: fuse mainapp/common and navio2
We currently only support Navio2, so let's fuse the two configurations.
2016-07-16 15:51:00 +01:00
Miguel Arroyo 17be06cf1a Fixes Navio2 Config Typo 2016-07-16 15:51:00 +01:00
Julian Oes 1939b88a33 RPi2: use cross/native instead of release/default 2016-07-16 15:51:00 +01:00
Julian Oes f241518d0e RPi2: bring default and release cmake in sync
The two cmake files for default and release where out of
sync. This change bases them on a common cmake file.
2016-07-16 15:51:00 +01:00
Daniel Agar d733fc9139 travis-ci use tagged docker image (#5068) 2016-07-16 08:41:19 -04:00
Beat Küng a1b710025b Improve new logger update rate (#5073)
* logger: disable some default topics, which are most likely not used

This is also to safe CPU and lower the amount of file descriptors used.

* logger: use the hrt timer for more accurate scheduling

Under NuttX with the default rate of 285Hz, the actual measured rate was
only 200Hz while on Linux it was ~280Hz. The reason is that NuttX only
uses a usleep() granularity of 1ms, so that the typical sleep time is
longer than what we set.

Now the logger waits on a semaphore, which gets activated periodically
with a hrt timer. With this the measured rate is exactly the expected one,
285Hz.
2016-07-15 16:55:32 -07:00
Beat Küng ee58f0d11d encoders.msg: remove this topic, it's never published (#5074) 2016-07-15 14:59:52 -07:00
lovettchris b48c081e5c Reset _transfer_in_progress if mavlink transfer times out. (#5077) 2016-07-15 14:59:30 -07:00
Julian Oes 87e964ec10 commander: POSCTL with localpos for MC
Fixedwings need a global position estimate for POSCTL.
2016-07-15 14:43:36 +01:00
Julian Oes f430c39f5b commander: allow POSCTL with local position
We want to allow flying POSCTL with optical flow only without GPS.
2016-07-15 14:43:36 +01:00
Julian Oes 1cfa429efe DriverFramework: update submodule
Small additions for Intel Edison.
2016-07-15 12:58:10 +02:00
David Sidrane 33e4f38d82 Add GPS and Compass (#5066) 2016-07-14 08:26:40 -10:00
David Sidrane e2a6ae676f More complete IO init (#5065) 2016-07-14 07:32:11 -10:00
Beat Küng 4a199c1360 gyro calibration: avoid double initialization of gyro_scale data
They're initialized in do_gyro_calibration already
2016-07-14 14:17:38 +02:00
Julian Oes f1b8bed5df gyro_calibration: set scale to 1 instead of 0 2016-07-14 13:13:56 +02:00
David Sidrane 8a2df2a458 Avoid unnecessary Write Cycle 2016-07-13 20:42:05 +02:00
David Sidrane 5d1bd6fb2c TAP used FLASH Based parameter storage - needs timing eval 2016-07-13 20:42:05 +02:00
David Sidrane 8d13dba0cc Update NuttX with backport of stm32 FLASH driver to support F4 ==master_flash 2016-07-13 20:42:05 +02:00
David Sidrane 5e8d6375c9 Back Port nuttx_v3 FLASH based parameter hooks 2016-07-13 20:42:05 +02:00
David Sidrane 39ce201efe TAP:Fix build to use correct ROMFS 2016-07-13 20:19:05 +02:00
David Sidrane 78bc7d850b Fix Syntax error - but I suspect the USE_IO logic can be simplified 2016-07-13 07:52:58 -10:00
Julian Oes 3ed8b735c2 mavlink: only warn once if broadcast fails
This fixes the issue where the console was spammed if a broadcast failed
after a connection had previously been established.
2016-07-13 19:40:59 +02:00
Beat Küng 399d4ef833 sensors: only poll on first gyro for now
This fixes a bug with following setup:
- two (or N > 1) connected gyros
- ekf2 enabled
In this case, sensors would publish with the combined rate of the gyros,
but with N following messages having the same gyro data & timestamp.
Apparently ekf2 cannot handle this, the other estimators can.

We may want to rethink what the proper solution is here.
2016-07-13 14:35:03 +02:00
Julian Oes eda2915f0b mavlink: whitespace fix 2016-07-13 10:10:45 +02:00
Julian Oes d9343fa925 mavlink: use new copy_if_updated interface 2016-07-13 10:10:45 +02:00
Julian Oes 8345a0368b mavlink: add function to copy only if updated
The MavlinkOrbSubscription only had an interface to either always copy
or copy based on a timestamp. This commit adds a copy interface if the
topic has been updated.
2016-07-13 10:10:45 +02:00
Julian Oes 8ded6a58ab mavlink_log: enable queueing
We don't want to drop messages if possible for mavlink log messages, so
let's use the orb queueing.
2016-07-13 10:10:45 +02:00
Julian Oes 314ee6b7e0 commander: remove some if confusion
This is a try to simplify the if statements a bit. Also, a check of
new_arming_state which was impossible, is removed.
2016-07-13 10:10:45 +02:00
Julian Oes 631ce1fc55 commander: proper arguments for preflight check 2016-07-13 10:10:45 +02:00
Andreas Antener af8cd3f880 correctly scale and trim outputs in IO 2016-07-13 09:29:13 +02:00
Roman 13905c2480 px4io driver: send roll, pitch and yaw scale parameter values to io
Signed-off-by: Roman <bapstr@ethz.ch>
2016-07-13 09:29:12 +02:00
Roman 08bbd6dbfa px4iofirmware: added scale parameters for roll, pitch and yaw
since pure manual control for fixed wings in handled on the io side
the scale parameters for roll, pitch and yaw had to be introduced there
as well.

Signed-off-by: Roman <bapstr@ethz.ch>
2016-07-13 09:29:12 +02:00
tumbili 71e2a43790 consider scale parameters in rc calibration code 2016-07-13 09:29:12 +02:00
tumbili f0dd5a103c allow scaling controls in full manual mode for fixed wings 2016-07-13 09:29:12 +02:00
tumbili 784883af22 added parameters to allow scaling controls in full manual mode
for fixed wings
2016-07-13 09:29:12 +02:00
xiaoyuli 7718343b27 fix the function of disabling safety switch (#5031) 2016-07-12 23:43:17 +02:00
Daniel Agar de14418e93 fw_pos_ctrl_l1 var naming consistency and effc++ 2016-07-12 23:40:39 +02:00
Daniel Agar ebce725720 px4fmu-v2 disable motor_ramp 2016-07-12 23:36:05 +02:00
Daniel Agar 59b4350aa0 implement MAV_CMD_NAV_LOITER_TO_ALT and general mission cleanup 2016-07-12 23:36:05 +02:00
Lorenz Meier 7419151314 Update EKF2 replay timestamp handling 2016-07-12 22:17:22 +02:00
David Sidrane 0576031a81 TAP PID (#5036) 2016-07-12 05:07:03 -10:00
Beat Küng f8382a2713 upload scripts: add TAP for the uploader script 2016-07-12 16:00:33 +02:00
David Sidrane 5cc58fa067 Reserving 32Kib of FLASH for parameters (#5035) 2016-07-12 03:57:31 -10:00
James Goppert 817f695297 Change to LPE terrain model to account for velocity scaling. (#5027) 2016-07-11 16:02:39 -04:00
Lorenz Meier a740d80a20 Mag voter: Be more forgiving on load changes 2016-07-11 15:16:35 +02:00
Lorenz Meier 021f0840ae Fix Hobbyking Pixracers 2016-07-11 15:03:07 +02:00
tommises 4fa2c54485 Mocap timestamp cleanup (#5021) 2016-07-11 12:46:29 +02:00
Beat Küng c9652fd42a logger: update set of default topics to match functionality of sdlog2
logging rate with these topics: ~50KB/s

The rates may need to be adjusted
2016-07-11 10:04:44 +02:00
Beat Küng 4ec9e53deb param SYS_LOGGER: remove experimental for new logger
It's ready to be used!
2016-07-11 10:03:02 +02:00
Beat Küng 68e14ceb29 tap startup script: add -t param for logger 2016-07-11 10:01:16 +02:00
Beat Küng 49614cfe38 SITL init scripts: add replay tryapplyparams & replay trystart
These will only start replay if there's an environment variable 'replay',
otherwise they do nothing.

We apply the parameters even before loading the modules, so that the
modules 'see' the same state as the recorded system had. We will have to
see how well this works in practice.
2016-07-11 09:26:35 +02:00
Beat Küng db13ac4c53 posix_sitl_default.cmake: add -DORB_USE_PUBLISHER_RULES if it's a replay build 2016-07-11 09:25:16 +02:00
Beat Küng e9726af54c Makefile: check for 'replay' env variable and change build dir accordingly
For replay with the new logger, we want a separate build dir so that the
parameters file and orb rules don't get mixed up.
2016-07-11 09:25:07 +02:00
Randy Mackay 80134d2b7d IR-LOCK: rework driver (from jschall) (#5024)
* irlock: change output format to tangent of angles

* irlock: put all targets in single struct

* irlock: eliminate tanf function in constant
2016-07-11 09:05:29 +02:00
Lorenz Meier 71d150f6ec MAVLink app: Fix rate handling 2016-07-10 17:05:33 +02:00
Lorenz Meier c7130081cc Update ECL 2016-07-10 16:33:07 +02:00
Lorenz Meier 02b3adc4a7 Update DriverFramework 2016-07-10 16:32:59 +02:00
Lucas De Marchi 18330f7ab7 Move __STDC_FORMAT_MACROS to build system
__STDC_FORMAT_MACROS changes the behavior of inttypes.h to allow
defining format macros for printf-like functions. It needs to be defined
before any include is done, otherwise due to include chains and header
guards it may not take effect.

Instead of having to define it everywhere it is used, move the define to the
build system. Also update ecl and DriverFramework submodules to deal with the
changed definitions.
2016-07-10 16:31:36 +02:00
tommises d2194d787f Refactored Mavlink stream configuration (#5015)
Streams ordered same way in all modes.
2016-07-10 16:22:22 +02:00
Lorenz Meier f39d284193 Update vision fields for attitude_estimator_ekf 2016-07-10 14:21:56 +02:00
Lorenz Meier 7601788c43 INAV: clean up vision timestamps 2016-07-10 12:44:00 +02:00
Lorenz Meier 8b3045baa2 MAVLink: clean up vision timestamps 2016-07-10 12:43:47 +02:00
Lorenz Meier c0a406b81f LPE: Clean up vision timestamps 2016-07-10 12:43:34 +02:00
Lorenz Meier 826eaed2ee EKF2: Clean up vision timestamps 2016-07-10 12:43:21 +02:00
Lorenz Meier 4f875560b7 Att Q Estimator: New vision timestamp 2016-07-10 12:43:10 +02:00
Lorenz Meier 07384d6b5a Vision msg: Cleanup timestamp 2016-07-10 12:42:56 +02:00
tommises 19b56c1574 Use timestamp received from companion computer as timestamp_boot 2016-07-10 12:29:19 +02:00
tommises 5bd574dd05 Fixed timestamp synchronization 2016-07-10 12:29:19 +02:00
tommises f69e9a3d37 Fixed VISION_POSITION_ESTIMATE.usec
Fixed units to be microseconds and not milliseconds.
2016-07-10 12:29:19 +02:00
David Sidrane a23785842c tap-v1 Uses New PWM LED driver structure 2016-07-10 11:46:47 +02:00
David Sidrane ea4d9a34fd mindpx-v2 Uses New PWM LED driver structure 2016-07-10 11:46:47 +02:00
David Sidrane a36f392b58 Rework PWM LED Driver 2016-07-10 11:46:47 +02:00
David Sidrane da96144e80 Added Power button and cleanup sdio 2016-07-10 11:46:47 +02:00
David Sidrane 5de19500c2 TAP-v1 set Console Baud Rate to 57600 2016-07-10 11:46:47 +02:00
Mark Whitehorn 09227526b6 enable use of GPS time for new logger folder/file naming (#5010) 2016-07-10 11:15:27 +02:00
Lorenz Meier 7afe2e8dd8 Iris SITL: Default gains 2016-07-08 00:02:48 +02:00
Lorenz Meier eb6af9afb9 VTOL updates 2016-07-07 23:30:57 +02:00
Lorenz Meier 38652ec940 SITL: Re-tune multicopter gains 2016-07-07 23:28:21 +02:00
Miguel Arroyo 3c11c0d8d8 Adds Calibration Support for RPi2 and Navio2 (#4999) 2016-07-07 22:38:17 +02:00
Andreas Bircher 2317589950 fixing the publishing of the triggering stamps (#5005) 2016-07-07 16:50:46 +02:00
Lorenz Meier e86c1851a7 Mag fusion update to ECL 2016-07-07 16:49:28 +02:00
Julian Oes ddba274496 sdlog2: fix poll_counter that I broke earlier 2016-07-07 16:48:27 +02:00
Julian Oes 544ea72d4c Snapdragon: set CPUs scaling to performance mode
Sdlog2 misses least updates when the CPU scaling governor is set at
maximum performance. This is not optimal to save power but the best
effort until there is a RT patched kernel on Snapdragon.
2016-07-07 16:48:27 +02:00
Julian Oes 03dbcf5464 sdlog2: don't forget to copy after poll
The previous changes broke sdlog2 on NuttX because no orb_copy was
called after polling in the case when sdlog2 was not actually logging.
2016-07-07 16:48:27 +02:00
Julian Oes 772dc302b6 sdlog2: raise min write size back
Turns out in practice there was not really a difference, so there was
no reason to change it.
2016-07-07 16:48:27 +02:00
Julian Oes fe91527604 sdlog2: poll for sensor and replay on Snappy
This brings better performance, so less missed updates on Snappy, as
well as a bit of a cleanup of the poll and orb_copy logic.
2016-07-07 16:48:27 +02:00
Julian Oes 5f18f9bbba sdlog2: select MIN < MAX bytes to write
Previously, the MAX and MIN were both 512 meaning that usually it would
start writing at > 512 bytes but only write 512 bytes which results in
a 512 bytes write shortly followed by a e.g. 30 bytes write.

Also, performance (measured in missed poll updates) seems slightly
better on Snapdragon with bigger chunks.
2016-07-07 16:48:27 +02:00
Julian Oes 1631cfdc83 Eagle: SDLOG_PRIO_BOOST to raise sdlog2 priority
This should lead to less drops on Snapdragon although it's hard to
verify this.
2016-07-07 16:48:27 +02:00
Julian Oes f7bb43b20b DriverFramework: update submodule (#5004)
This brings various PRs and fixes.
2016-07-07 16:24:13 +02:00
Beat Küng 168c744232 replay: fix string printf output: add .c_str() 2016-07-07 12:51:42 +02:00
Beat Küng 6e44760819 replay: add 'tryapplyparams' command
This only applies parameters from the log file and user-supplied overrides.
It is intended to be called as one of the first startup commands (after
param load), so that during startup, all applications find the parameters
from the replayed system.

Note that this is an optional command and 'replay start' will again load
and apply the parameters in any case.
2016-07-07 12:51:42 +02:00
Beat Küng 84a1a10006 logger: check if we are in replay mode via ENV variable 'replay' 2016-07-07 12:51:42 +02:00
Beat Küng 28ad6066aa replay: add replay module, build for sitl_default, but do not load on startup
This adds a new module that does:
- read an parse an ULog file, given via ENV variable 'replay'
- apply all parameters from the log file
- read and apply user-defined override parameters from a file
- publish all messages in 'real-time' from the log file and add a constant
  offset to the timestamp to match the system time.
- apply changed parameters in the log (which are not overridden)
2016-07-07 12:51:42 +02:00
Beat Küng ffcefd9047 orb: read & apply publisher rules from file (currently disabled via #ifdef)
If enabled, orb reads a rules file (./rootfs/orb_publisher.rules) on
startup. This can contain rules about which module is allowed to publish
which topic. It is completely transparent, so a publisher does not know
if he's not allowed to publish, and publications will look as if they
succeeded.

To test, add
#define ORB_USE_PUBLISHER_RULES
to uORBManager.hpp
2016-07-07 12:51:42 +02:00
Daniel Agar 4252511b8e add bitmask param metadata 2016-07-07 12:42:59 +02:00
Andreas Bircher 9974b6f747 Camera trigger update (#4998)
* updating the camera driver, correct init and keepAlive function

* removing debug output
2016-07-07 11:40:11 +02:00
Lorenz Meier 15880f8d13 Less verbose 2016-07-07 11:40:11 +02:00
Lorenz Meier aa77e8ee23 Cleanup 2016-07-07 11:40:11 +02:00
Lorenz Meier 50b93b161c Camera trigger: Make interface dependent on parameter, not command line 2016-07-07 11:40:11 +02:00
Lorenz Meier 78f7f00ae2 Camera trigger: Make interface dependent on parameter, not command line 2016-07-07 11:40:11 +02:00
Lorenz Meier 4683e20187 Clean up camera trigger interface code 2016-07-07 11:40:11 +02:00
Beat Küng 9c73eae941 sensor_combined: replace accel & gyro integral with value, use float for dt
Reason: the value is easier to read & handle (for example plotting). In
most places the value is needed, not the integral.

Note that this breaks the replay format for sdlog2 replay
2016-07-07 11:35:50 +02:00
Beat Küng 8e136779ec stack sizes: reduce stack sizes for modules that use sensor_combined
The sensor_combined topic got reduced from ~780 bytes to 72 bytes.
2016-07-07 11:35:50 +02:00
Beat Küng c5ea4b43be sensor_combined.msg: make timestamps relative
This is needed for the new logger & saves some space as well.
2016-07-07 11:35:50 +02:00
Beat Küng c66f26245c sensor_combined.msg: use uint32 for integral_dt
There is no reason to make this 64 bit. The same should be done in
the sensor raw messages, together with further cleanup.
2016-07-07 11:35:50 +02:00
Beat Küng 30301187f0 cleanup sensors_init: remove the static const int ERROR and use PX4_ERROR 2016-07-07 11:35:50 +02:00
Beat Küng d846ad5dac sensors: move voting into sensors module
- voting is now at a central place instead of duplicated within the
  estimators
  -> this also means that estimators that did not do voting so far,
     now have voting, like ekf2
- estimators requiring more than that can still subscribe to the raw
  sensors
- allows sensors_combined to be 3 times smaller
  - reduces logger, memcpy (cache) & RAM overhead
- all modules requiring only 1 or 2 sensor values now automatically get
  the voted result
- this also adds voting to baro
2016-07-07 11:35:50 +02:00
Beat Küng c50d267bfb sensors: cleanup includes and logging (warnx -> PX4_WARN/ERR/INFO) 2016-07-07 11:35:50 +02:00
Beat Küng 0c30ee8d37 fix resource leak in attitude_estimator_q_main: unsubscribe topics 2016-07-07 11:35:50 +02:00
Beat Küng b4ecc5a8d9 sensor_combined cleanup: remove many unneeded fields
Decreases the message size from 780 to 280 bytes.
In particular, all modules using sensor_combined must use the integral now.
The sensor value can easily be reconstructed by dividing with dt.

Voters now need to be moved into sensors module, because error count and
priority is removed from the topic.

Any module that requires additional data from a sensor can subscribe to
the raw sensor topics.

At two places, values are set to zero instead of subscribing to the raw
sensors (with the assumption that no one reads them):
- mavlink mavlink_highres_imu_t::abs_pressure
- sdlog2: sensor temperatures
2016-07-07 11:35:50 +02:00
Beat Küng c407123a72 cleanup sensor_combined: remove adc & differential_pressure fields
These are not really used. differential_pressure is just copied from the
topic with the same name.

for sdlog2 we assume no one needs the diff pressure fields and set it to 0.
We plan to switch to the new logger soon anyway.
2016-07-07 11:35:50 +02:00
Beat Küng 2c2477a07d fix sensors leaks: unsubscribe topics when exiting 2016-07-07 11:35:50 +02:00
Beat Küng ac45c9001b sensors: cleanup syntax: replace &x[0] with x 2016-07-07 11:35:50 +02:00
Beat Küng 78b45c4778 sensors: remove duplicated initialization 2016-07-07 11:35:50 +02:00
Beat Küng ddc4d70d51 airspeed_calibration: remove unused include 2016-07-07 11:35:50 +02:00
David Sidrane 1d5c5497b5 Reduces wasted FLASH by > 4K (#4994)
* Reduces wasted FLASH by > 4K

* Removed PX4_IMPLEMENT_PX4_LOG_MODULENAME

* Moved implamentation of px4_log_modulename to px4_log.c
2016-07-06 23:52:08 +02:00
James Goppert 056f73f5d2 Changed LPE distance sensor timeout logic. (#4996) 2016-07-06 10:31:55 -04:00
Lorenz Meier 703141d650 Estimator cleanup 2016-07-06 13:37:46 +02:00
Lorenz Meier 332f669d9b Add tap-v1 config 2016-07-06 13:34:35 +02:00
Lorenz Meier 7ed0eba50e USB config is now in main boot 2016-07-06 13:31:24 +02:00
Lorenz Meier 8a2155f2af UAVCAN is now in main RCs 2016-07-06 13:31:11 +02:00
Lorenz Meier 96f053273c Always start default mc apps 2016-07-06 13:30:58 +02:00
Beat Küng 09ecc84cc7 gps file dump: re-implement with an uORB topic & write to the log file (#4987)
Drawbacks of the previous method: when writing to the SD card, there are
high delays in the write() call of several 100ms, every now and then. The
frequency and length of these events depend on:
- SD card
- used logger bandwidth
- bandwidth of gps data (RTCM)
Since the whole gps thread was blocked during this period, it lead to
gps timeouts and lost module.

What we do now is: publish an orb topic with queuing. This makes it async
and the logger takes care of buffering. This means it's best to:
- use high logger rate
- use large logger buffer
- reduce logger bandwith by disabling unused topics
2016-07-06 09:32:37 +02:00
James Goppert 7e883809e3 Bump matrix version to 1.0.1. 2016-07-06 01:43:59 -04:00
James Goppert c38f23c0e1 Bump matrix version. (#4993) 2016-07-05 21:20:17 -04:00
James Goppert 9c0ed52bb8 Updated matrix lib to 1.0.0. (#4991)
* Updated matrix lib to 1.0.0.

* Bump matrix version.
2016-07-05 17:38:35 -04:00
James Goppert 09ddc24801 Added agl smoothing to LPE. (#4976) 2016-07-05 16:54:08 -04:00
Julian Oes 3524fd7d24 ekf2: don't ignore function argument (#4990) 2016-07-05 17:40:37 +02:00
Ivan Dimitrov e342299204 Fixed filename in the Doxygen field. See issue "wrong doxygen descriptor (file name) #4979" 2016-07-05 15:17:05 +02:00
Beat Küng c4e77cf411 logger: fix '-r 0' parameter: should be unlimited rate instead of 1Hz 2016-07-05 14:08:25 +02:00
Beat Küng c94fe845ec fix logger: remove space in format for changed parameters 2016-07-05 14:08:25 +02:00
Beat Küng a455962e17 logger: only call write_add_logged_msg when sucessfully subscribed 2016-07-05 14:08:25 +02:00
Eike dc1f343501 Change lower range limit of SF10a to 0.01m (#4977)
* SF10a driver added

* Remove Sf10a driver

* Set lower range boundary to 0.01m for LPE
2016-07-04 21:41:58 +02:00
Daniel Agar 7f89994785 use NAV_ACC_RAD for vertical waypoint acceptance (#4978) 2016-07-04 21:41:16 +02:00
Daniel Agar a9a3050682 EKF2 HIL gps decrease s_variance_m_s 5.0 -> 1.0 (#4973) 2016-07-04 08:18:15 +02:00
Andreas Antener 8d254058fa added square wave mode and PWM max parameter 2016-07-03 22:23:25 +02:00
bharathr d96810f250 Removed px4 config file for 200qx P1 board, updated P2 board version to support Qualcomm ESCs 2016-07-03 12:43:54 +02:00
bharathr 29be7c3003 Updated motor-esc mappings in 200qx config file 2016-07-03 12:43:54 +02:00
bharathr 9131647566 Fixed UART_ESC_MODEL parameter in 200qx config file 2016-07-03 12:43:54 +02:00
bharathr 00243a9842 Updated 200qx config files (removed calib files, cleaned up and renamed all files) 2016-07-03 12:43:54 +02:00
Martin K. Schröder 97d9fd38be Update Matrix.hpp (#4966)
This was horribly wrong. Matrix is first cast into a matrix of size NxM (which is supposed to be the size of the result - NOT the starting point) so the transpose result becomes garbage. Instead make "Me" an MxN matrix as the original. Took me a whole evening to figure out this problem. Now my Kalman filter finally returns good results.
2016-07-03 12:29:58 +02:00
Lorenz Meier bc6e83f5e3 Version reporting: Be more accurate about platforms 2016-07-02 13:00:07 +02:00
Lorenz Meier d85e416680 Fix default handling for battery params 2016-07-02 12:59:49 +02:00
Lorenz Meier 9258bb2ae8 v1.4.0 transitional support for battery count 2016-07-02 12:08:57 +02:00
Lorenz Meier 88cf8f23f6 Fix ver command 2016-07-02 12:08:30 +02:00
Lorenz Meier fd17c87eb4 Fix release parsing 2016-07-02 12:00:56 +02:00
Lorenz Meier 972a6f7be8 Fix MAVLink reporting of Firmware version, implement dev / release version reporting 2016-07-02 11:43:24 +02:00
Lorenz Meier 2a729028bd SITL: Set battery cells 2016-07-02 11:41:23 +02:00
tumbili 7e282f579b sensors app: logic fixed and cleanup
- do not exit sensors app if sensor init failed
- do not spam console if we fail over first/second gyro

Signed-off-by: tumbili <roman@px4.io>
2016-07-01 23:11:38 +02:00
Hidenori ee58188162 Split Navio2 specific parts from general RPI2 files
For Navio2, make posix_navio2_release and use navio2.config.
2016-07-01 23:08:17 +02:00
Hidenori 506d1855ff rename files and add navio target 2016-07-01 23:08:17 +02:00
Miguel Arroyo b871b322d2 Using Actuator Control Group 0 & Checkstyle fixes 2016-07-01 23:08:17 +02:00
Hidenori 76ee17e532 RC input and PWM output for Navio2 2016-07-01 23:08:17 +02:00
Daniel Agar 54e14cd4b6 add latest version to README (#4960) 2016-07-01 23:00:35 +02:00
James Goppert cb3120764a Made LPE var pub threshold a parameter. (#4959) 2016-07-01 13:27:29 -04:00
Lorenz Meier a0fdfb0c21 Strip ESC calib commandline tool 2016-07-01 18:23:08 +02:00
Lorenz Meier ed19d1ff6b EKF2 wrapper: Optimize for size 2016-07-01 18:22:56 +02:00
Lorenz Meier fad07a45b9 Mathlib: Optimize for sixe 2016-07-01 18:21:35 +02:00
Lorenz Meier 8162300522 Switch fixed wing to EKF2. Does not link yet. 2016-07-01 18:09:20 +02:00
Lorenz Meier e43625cfc1 ROMFS: Clear out SITL mixers from deployed image, delete unused mixers, move test mixers to test config 2016-07-01 18:08:32 +02:00
Lorenz Meier 42d8459e87 We are not using the conversion scripts in this ZIP file any more 2016-07-01 18:04:47 +02:00
Lorenz Meier 82b2fa5ecb Commander should not depend on MAVLink 2016-07-01 18:04:09 +02:00
Lorenz Meier 37edb43b60 ROMFS: Strip README files 2016-07-01 18:03:38 +02:00
Lorenz Meier 6268cdc86a Solo is just a normal X quad 2016-07-01 18:03:23 +02:00
James Goppert 00dfc99e08 LPE Variance Dependent Publication (#4914)
* Use variance to control publishing for LPE.

* Don't stop publishing if we have gps/ baro.

* LPE tuning and cleanup.

* Added bias saturation to LPE.

* Added vector enabled low pass filter block.

* Added rk4 integration and pub lowpass to LPE.

* Fix std::abs issue on mac/ reset lowpass on state reset.

* Don't estimate gyro bias when rotating at high speed  att_est_q.

* Lowered low pass on position to 5 Hz for LPE.

* Streamline state space update for LPE.

* Added health flags to est2 log.

* Revert to old tuning, more conservative, less faults.

* Formatting.

* Fix for fault message on LPE.

* Added subscription throttling to LPE.

* Formatting.
2016-07-01 11:43:09 -04:00
sander 2a395c3fec Moved to integrationtests 2016-07-01 11:44:37 +02:00
sander 1548a9a2a1 Change mission to new format and reset defaults 2016-07-01 11:44:37 +02:00
Andreas Antener 25e749de77 use MC auto rates always in AUTO
removed duplicate weathervaning limit
2016-07-01 11:31:57 +02:00
Daniel Agar a2b1269b27 check_code_style don't paginate output (#4952)
- fixes #4943
2016-06-30 21:00:11 -04:00
Lorenz Meier 2214e7c202 Commander: Remove annoying GPS fix regained warning 2016-06-30 16:59:17 +02:00
tumbili 998579befc mc pos control: zero yaw setpoint move rate in attitude setpoint topic
- fixed bug where a non-zero yaw setpoint move rate could make the drone
yaw around in non-manual modes

Signed-off-by: tumbili <roman@px4.io>
2016-06-30 16:42:51 +02:00
Lorenz Meier 0a40034159 Takeoff: Fix coordinate scaling (#4947) 2016-06-30 16:26:05 +02:00
Andreas Antener 5dcc62d8f9 allow yaw setpoint offset to be reduced once maxed out 2016-06-30 14:30:59 +02:00
Daniel Agar 377726a9a7 sitl gazebo plane fix land detector startup order (#4932) 2016-06-30 13:56:06 +02:00
Daniel Agar 07fa814597 FW vtol landing always forced (#4939) 2016-06-30 13:55:47 +02:00
Lorenz Meier 9649050c2e Update ECL to master 2016-06-30 13:29:47 +02:00
tumbili 036f42999a vtol delta quad plane: adjusted default controller gains
Signed-off-by: tumbili <roman@px4.io>
2016-06-29 13:29:57 +02:00
tumbili 57a665ad99 vtol delta quad plane: adjusted mixer scaling
Signed-off-by: tumbili <roman@px4.io>
2016-06-29 13:28:58 +02:00
Samay Siga fcee34a9d1 Quad tilt vtol config (#4473)
* Added new VTOL Config

I added new Vehicle ID for our VTOL aircraft - Quad - Tilt Rotor - FW

Added
13010_claire
claire.main.mix
claire.aux.mix

* Added files via upload

* Delete 13010_claire

* Create 13010_claire

* Update 13010_claire

* Update claire.main.mix

* Update claire.aux.mix
2016-06-29 09:14:18 +02:00
Andreas Antener 5ed4e4e3a5 use proper matching for VTOL fixed-wing state regarding position acceptance 2016-06-28 22:44:49 +02:00
Andreas Antener 53b5758eb4 added mission name to assertion outputs 2016-06-28 22:44:49 +02:00
Andreas Antener 85b5b399b9 updated FW horizontal acceptance radius to work with deltaquad 2016-06-28 22:44:49 +02:00
Andreas Antener 26de353d4f added mission file to test name 2016-06-28 22:44:49 +02:00
Andreas Antener 2f581a296e enable VTOL tests on CI again 2016-06-28 22:44:49 +02:00
Andreas Antener c9f278e46f fix rcS for standard vtol 2016-06-28 22:44:49 +02:00
Andreas Antener 0e5a83f3c1 temporarily disabled running mission test on CI 2016-06-28 22:44:49 +02:00
Andreas Antener 37884dc5dd fixed landing and transition detection test 2016-06-28 22:44:49 +02:00
Andreas Antener d995f758c2 added mission test to CI run 2016-06-28 22:44:49 +02:00
Andreas Antener f252ac3eff added mission checks for landing and VTOL transition 2016-06-28 22:44:49 +02:00
Andreas Antener 57fa9d2070 use separate altitude offset check in FW 2016-06-28 22:44:49 +02:00
Andreas Antener 05dc643f17 increased fixed wing radius for mission tests and added more informative output for position matching 2016-06-28 22:44:49 +02:00
Andreas Antener 361abd7f04 added VTOL test missions 2016-06-28 22:44:49 +02:00
Andreas Antener 00d56b9ef8 added VTOL mission test, updated mission test to check mission depending on vehicle state 2016-06-28 22:44:49 +02:00
Andreas Antener 150eb779ae added draft script to run missions against SITL 2016-06-28 22:44:49 +02:00
Andreas Antener 5c88353d05 removed GCS link from mavros 2016-06-28 22:44:49 +02:00
Beat Küng 8a12dee125 cmake: remove all module.mk files & cmake conversion script (#4918)
It seems these files are leftovers.
2016-06-28 09:26:36 +02:00
Beat Küng b28bfce186 position_estimator_inav: fix compiler issue for GCC 6.1.1 (#4923)
GCC output:
implicit conversion from ‘float’ to ‘double’ to match other operand of
binary expression [-Werror=double-promotion]

It seems gcc 6.1.1 uses the float variant of fabs, whereas older gcc's
use the double version. This makes it compile for both.
2016-06-28 09:25:36 +02:00
Roman Bapst ec35e77175 px4io driver: fix reporting of mixer limits (#4922)
mixer limit topic was not filled correctly

Signed-off-by: tumbili <roman@px4.io>
2016-06-27 17:31:43 +02:00
Daniel Agar 050eedc4f8 mavlink publish WIND_COV (#4913)
* mavlink publish WIND_COV

-closes #4678

* px4fmu-v2_default disable logger and sync configs
2016-06-27 16:16:24 +02:00
James Goppert 5935b18581 Added EPH/EPV min to LPE. (#4915) 2016-06-27 08:46:00 +02:00
Eike 04e8b40a5c Posix LPE target (#4911) 2016-06-27 08:43:39 +02:00
Daniel Agar 422acc0b69 travis-ci add check_format to qgc_firmware 2016-06-26 17:42:00 -04:00
Daniel Agar b8b855f2aa param.c fix style 2016-06-26 17:36:45 -04:00
Lorenz Meier 3c2bd4f6dd Param interface: Only mark as changed if value changed 2016-06-26 22:29:14 +02:00
Lorenz Meier acc8acd059 FMU driver: Fix typo 2016-06-26 22:27:45 +02:00
Lorenz Meier 33e259e827 Update controller gains to match better vehicle models 2016-06-26 22:25:55 +02:00
Lorenz Meier 47a4b95217 Updated simulation models 2016-06-26 22:25:26 +02:00
Lorenz Meier e9fb929f50 Annotate build type classes for ver command 2016-06-26 21:38:14 +02:00
Daniel Agar cb320f6e8a param set default battery parameters (#4912) 2016-06-26 21:27:11 +02:00
Lorenz Meier 27e20acbae Leave pin 5 and 6 of the AUX port available for camera triggering when the trigger is enabled 2016-06-25 12:15:32 +02:00
tommises e6bb21db65 Leave some pins available for camera trigger GPIO. 2016-06-25 12:11:19 +02:00
Julian Oes 6618cac10a RPi2: don't forget to start the baro 2016-06-25 12:00:49 +02:00
Julian Oes fedde86bf4 df_lsm9ds1_wrapper: new DF submodule, fixes 2016-06-25 12:00:49 +02:00
Julian Oes e56be33e50 RPi2: switch from ekf2 to q/inav 2016-06-25 12:00:49 +02:00
Julian Oes 8b8766e840 RPi2: put drivers back in 2016-06-25 12:00:49 +02:00
Julian Oes ea7cebbf10 scp_upload.sh: use ENV variable to set IP of RPi2 2016-06-25 12:00:49 +02:00
Julian Oes 4c0ed8bdd5 df_lsm9ds1_wrapper: astyle 2016-06-25 12:00:49 +02:00
Hidenori ef729ab2d8 MS5611 driver wrapper for RPi 2016-06-25 12:00:49 +02:00
Miguel Arroyo f0dbae2e19 Adds LSM9DS1 DriverFramework 2016-06-25 12:00:49 +02:00
Miguel Arroyo 8b8513fe8c Adds LSM9DS1 Wrapper 2016-06-25 12:00:49 +02:00
Henry Zhang ae6600e48f MAVLink app: fix mavlink forwarding issue. (#4907) 2016-06-25 11:02:01 +02:00
Andreas Daniel Antener 705a08bbbd do not modify attitude setpoint in velocity controlled mode (#4905) 2016-06-25 10:59:50 +02:00
Daniel Agar 8ba5afcd5a circleci ccache (#4906) 2016-06-25 00:25:13 -04:00
Daniel Agar 52c790b184 circleci sync submodules recursive 2016-06-24 20:21:46 -04:00
Lorenz Meier 645204eb42 Update MAVLink library versions 2016-06-24 12:47:59 +02:00
Lorenz Meier e432a406b6 Update MAVLink submodules 2016-06-24 11:45:23 +02:00
James Goppert bf9f3b6061 Added QAV-R (raceblade) 5". (#4897)
* Added QAV-R (raceblade) 5".

* Added I gain for qav-r.
2016-06-24 11:44:39 +02:00
Lorenz Meier 286efb6b34 Remove POOSIX porting noise from ms5611 driver (#4896) 2016-06-24 10:39:55 +02:00
Lorenz Meier d49598b8b3 Build SF10A on FMUv4 2016-06-24 10:31:28 +02:00
Lorenz Meier 7b2367cdff Remove unused topic from SF10A 2016-06-24 10:31:17 +02:00
ecmnet 993831aba8 SF10A driver fix 2016-06-24 10:28:25 +02:00
Roman eabc4647c2 mavlink receiver: fixed unit conversions for current
Signed-off-by: Roman <bapstr@ethz.ch>
2016-06-24 08:35:27 +02:00
Roman f754d23a0f mavlink receiver: fixed computation of cell count
Signed-off-by: Roman <bapstr@ethz.ch>
2016-06-24 08:10:35 +02:00
Lorenz Meier 925c340915 Remove unused code from simulated driver 2016-06-24 00:24:09 +02:00
Beat Küng e0c11f5545 fix ekf2_replay_main.cpp: remove timestamp_velocity from gps topic 2016-06-24 00:22:01 +02:00
Beat Küng cf5d959f1b gnss.cpp: switch to relative gps timestamp 2016-06-24 00:22:01 +02:00
Beat Küng 940ac5471d ekf2: remove unused gps_msg.time_usec_vel 2016-06-24 00:22:01 +02:00
Beat Küng f8e9a19889 gps_position: convert uint64 timestamp_time -> int32 timestamp_time_relative
We need to make this timestamp relative to the main timestamp. Necessary
for replay, and saves some space.
2016-06-24 00:22:01 +02:00
Beat Küng e2a7145379 vehicle_gps_position: remove timestamp_variance & timestamp_velocity (they're not used) 2016-06-24 00:22:01 +02:00
Beat Küng 89f5bd27e8 vehicle_gps_position: use timestamp field instead of timestamp_position
timestamp was unused. This allows to remove timestamp_position.
2016-06-24 00:22:01 +02:00
Lorenz Meier bf0b3c1585 More complete ESC feedback, ensure to include a timestamp 2016-06-24 00:08:24 +02:00
Lorenz Meier 34c0d3e99a Add TAP to vendor list 2016-06-24 00:08:24 +02:00
Lorenz Meier b04e2526a1 Fix compile errors for tap ESC 2016-06-24 00:08:24 +02:00
Lorenz Meier de1c865881 Move TAP ESC to FMUv4 to save flash on FMUv2 2016-06-24 00:08:24 +02:00
Lorenz Meier 1f8b75c9f3 Enable it in build 2016-06-24 00:08:24 +02:00
Lorenz Meier fab201a2d6 Initial import of TAP controllers 2016-06-24 00:08:24 +02:00
Mark Whitehorn 40a7bd009f implement Spektrum bind function for Pixracer R14 (#4887) 2016-06-23 23:27:51 +02:00
Lorenz Meier 024a86c309 Simulator: fix battery sim 2016-06-23 22:32:14 +02:00
Roman Bapst 571798c318 Pr external battery monitoring (#4881)
* mavlink receiver: added handling of battery status

handle incoming battery status messages in order to support external
battery monitoring

Signed-off-by: Roman <bapstr@ethz.ch>

* sensor params: added parameter for battery monitoring source

Signed-off-by: Roman <bapstr@ethz.ch>

* sensors: only publish battery status if we don't have external battery
monitoring activated

Signed-off-by: Roman <bapstr@ethz.ch>
2016-06-23 18:41:38 +02:00
sirPerna 9f95f457a9 Update default Caipirinha parameters (#4883)
* Update default parameters for TBS Caipirinha

* reverse channel 0 doesn't exist
2016-06-23 18:09:07 +02:00
Daniel Agar b09872e795 travis-ci fix git shallow clone for git ver (#4885) 2016-06-23 11:04:36 -04:00
tumbili c2825f701a ekf_att_pos_estimator: fixed saving params when landed
fixed logic such that parameters are saved when vehicle just landed.
only save parameters once when state changed from in_air to landed.

Signed-off-by: tumbili <roman@px4.io> and bkueng <beat-kueng@gmx.net>
2016-06-23 15:56:51 +02:00
tumbili 8026273cb0 land_detector: do not publish if landing or freefall state has not changed
Signed-off-by: tumbili <roman@px4.io> and bkueng <beat-kueng@gmx.net>
2016-06-23 15:56:51 +02:00
Beat Küng 7dea8d4a24 fix 10020_3dr_quad script: load proper mixer file (#4880)
fixes regression from 85245471c0
2016-06-23 14:54:20 +02:00
Nate Weibley 0551e001e2 Properly reflect flow control state if IOCTL fails (#4873)
The flow control state is improperly reflected as enabled if the arch/HAL rejects an IOCTL to turn it on. Mavlink::enable_flow_control updates _flow_control_enabled only if the IOCTL call does not fail.
2016-06-23 10:17:17 +02:00
Roman 27e61127a8 ekf2: fix if else logic
Signed-off-by: Roman <bapstr@ethz.ch>
2016-06-23 09:08:35 +02:00
Roman 6f6ae78cf2 ekf_att_pos_estimator: added logic for airspeed modes
Signed-off-by: Roman <bapstr@ethz.ch>
2016-06-23 09:08:35 +02:00
tumbili c1ba7ab62b vtol attitude control: fixed code style
Signed-off-by: tumbili <roman@px4.io>
2016-06-23 09:08:35 +02:00
sander bbf852787e Rename param to throttle 2016-06-23 09:08:35 +02:00
sander 3002852bfa Allow throttle updates below 10% 2016-06-23 09:08:35 +02:00
sander f2e425b75b commenting 2016-06-23 09:08:35 +02:00
sander 9d59ba125d remove debug info 2016-06-23 09:08:35 +02:00
sander 37531c018a Implement MAV_CMD_DO_CHANGE_SPEED throttle 2016-06-23 09:08:35 +02:00
Roman 7f8c183d99 added airspeed mode enum to control state topic
Signed-off-by: Roman <bapstr@ethz.ch>
2016-06-23 09:08:35 +02:00
Roman 22db94e352 removed debug printf
Signed-off-by: Roman <bapstr@ethz.ch>
2016-06-23 09:08:35 +02:00
sander cea2350d2e Time based front transition blending 2016-06-23 09:08:35 +02:00
sander b54982965b Allow VTOL transition based on time 2016-06-23 09:08:35 +02:00
tumbili 1bce38bd9b code style formatting 2016-06-23 09:08:35 +02:00
tumbili c2da51ccf5 use airspeed mode parameter to decide which method used to publish
control state airspeed
2016-06-23 09:08:34 +02:00
tumbili 099becb353 added parameter for airspeed mode selection
this will enable small planes flying without an
airspeed sensor
2016-06-23 09:08:34 +02:00
Daniel Agar e0a214da20 travis-ci OSX don't use homebrew (#4875)
* the OSX builds were spending the majority of the time just updating homebrew and installing a couple packages
2016-06-23 01:22:47 -04:00
Daniel Agar 3194153b21 travis-ci homebrew cleanup (#4874) 2016-06-22 21:55:12 -04:00
Daniel Agar b247dac120 travis-ci optimizations (#4870)
* move gcc 4.9 build to circleci

* travis-ci update to xcode 7.3

* travis-ci limit git fetching for OSX

* Makefile split firmware targets for CI

* OSX ccache
2016-06-22 17:42:49 -04:00
Lorenz Meier 56ddd29f1a Commander: Update params on last step of mag cal 2016-06-22 16:03:01 +02:00
Beat Küng e7f31393bc orb: reduce size of SubscriberData struct (#4771)
- priority field uses only the lower 8 bits, so we can merge with the
  update_reported flag
- orb_set_interval is not used often, so make the necessary data an
  optional pointer and alloc only when needed.

Memory savings:
- pixracer (w. ekf2): 7.3kB
- pixhawk: 5.3kB
2016-06-22 15:28:23 +02:00
Julian Oes dfa2ec8c6c DriverFramework: updated submodule (#4867)
This brings some makefile and script fixes, as well as an updated dspal.
2016-06-22 15:19:29 +02:00
Roman Bapst 37108870e1 fw_pos_control_l1: added roll setpoint for logging (#4869)
in altitude control mode for fixed wings the roll setpoint was not
logged because the position controller publishes the attitude setpoint
but the desired roll setpoint is calculated in the attitude control
module. Now the position controller calculates the roll setpoint as well
for the sake of logging.

Signed-off-by: tumbili <roman@px4.io>
2016-06-22 15:19:11 +02:00
Daniel Agar 36103d33d2 travis-ci only build qgc firmware 2016-06-22 13:51:39 +02:00
Daniel Agar 3f3a44fec5 cmake status message if MEMORY_DEBUG enabled 2016-06-22 13:51:39 +02:00
Daniel Agar 924fb49bf5 fw_pos_control_l1 shorten task name
-limited to 16 chars
2016-06-22 13:51:39 +02:00
Daniel Agar b65291579f show bad formatting diff 2016-06-22 13:51:39 +02:00
Daniel Agar 4d0bb9f1e2 update eclipse project file templates 2016-06-22 13:51:39 +02:00
jwilson 9794bb2f2f Running fix_code_style.sh on the requested source files. 2016-06-22 08:57:06 +02:00
jwilson acc1f04b67 Unfortunately, lot's of whitespace changes, required to satisfy unspecified code style format errors. 2016-06-22 08:57:06 +02:00
jwilson 1091319274 Removing shmem_posix.c from the unit testing since param_shmem_test is disabled. 2016-06-22 08:57:06 +02:00
jwilson a2c16a3b5e Another attempt to fix the build problem in the shmem code. 2016-06-22 08:57:06 +02:00
jwilson 701d6314d2 Fixes build problem in the shmem code. 2016-06-22 08:57:06 +02:00
jwilson a73ac821ab Fixes shared memory locking bug and eliminates the need for an AppsProm driver to reserve a shared memory region. 2016-06-22 08:57:06 +02:00
tumbili 6739ae9dfc ekf2: substract gyro bias from control state rates
Signed-off-by: tumbili <roman@px4.io>
2016-06-22 07:10:20 +02:00
tumbili c84870046e updated ecl: added method to return ekf bias state
Signed-off-by: tumbili <roman@px4.io>
2016-06-22 07:10:20 +02:00
Lorenz Meier b563fae118 Fix request data stream handling 2016-06-22 00:09:13 +02:00
Lorenz Meier de675845af Fix navigator timeout logic 2016-06-22 00:04:31 +02:00
Lorenz Meier 2f113a4ce3 MAVLink: Allow data rate updates 2016-06-21 16:38:53 +02:00
Lorenz Meier 1869ffd15f Fix unknown command message for Spektrum bind 2016-06-21 13:36:35 +02:00
Julian Oes 91127d51c0 commander: stay in failsafe even when landed
If the failsafe state is ended when landed, we would switch back to
POSCTL and therefore take off again, however, all we want is stay on
ground and wait for the auto disarm.
2016-06-21 10:21:34 +02:00
dong.chen 5ad671ed4c Solve the problem When lost rc signal, it will rtl repeated. 2016-06-21 10:21:34 +02:00
Julian Oes c7ec07be70 commander: properly use new param
The param COM_ARM_WO_GPS is set to 1 by default to allow arming without
GPS. This then sets a bool arm_without_gps which translates to
!GNSS_check in preflightCheck.
2016-06-21 10:21:34 +02:00
Julian Oes f67e74935e commander: remove leftover printf 2016-06-21 10:21:34 +02:00
Julian Oes 66dd72555a navigator: change default of RC loss param to RTL 2016-06-21 10:21:34 +02:00
Julian Oes ef04085ac5 commander: go to ALTCTL if GPS is lost in POSCTL
Previously, we renained in POSCTL and would drift away if GPS was lost.
2016-06-21 10:21:34 +02:00
Julian Oes 67a4a57491 commander: only warn if termination happens
The termination warnings were printed even if termination was not
actually enabled. This was confusing and is therefore fixed.
2016-06-21 10:21:34 +02:00
Julian Oes 872b08f677 commander: remove unneeded include 2016-06-21 10:21:34 +02:00
Julian Oes fdff6ea325 Revert "commander: remove unused/wrong failsafe handling"
This reverts commit 9e704a5e121c7516e2133d02b328500d9d66fb67.
2016-06-21 10:21:34 +02:00
Julian Oes d0355cef1f Revert "commander/navigator: remove param NAV_RCL_ACT"
This reverts commit 77ea4cebf41cd106fe771b9eb469aa2326339467.
2016-06-21 10:21:34 +02:00
Julian Oes 049146ef9c commander: param to allow arming without GPS 2016-06-21 10:21:34 +02:00
Julian Oes 3e9d1388af commander: remove unused/wrong failsafe handling
The deleted code conflicts with the failsafe handling in set_nav_state.
Also, flight termination was usually disabled by circuit breaker which
means this code had no effect anyway.
2016-06-21 10:21:34 +02:00
Julian Oes 016d514d80 commander/navigator: remove param NAV_RCL_ACT
The param NAV_RCL_ACT was not implemented as described. Also, it has the
completely the wrong name. It should be a COM param and not NAV.
Therefore, remove the param and delete the partly implemented
and probably never used functionality.
2016-06-21 10:21:34 +02:00
Julian Oes ea10c8c8a3 circuit_breaker: change default for GPS failure
We should definitely take action when GPS fails, this circuit breaker
shouldn't be engaged anymore.
2016-06-21 10:21:34 +02:00
Julian Oes 739d1cfd3f navigator: always run the loop, even without GPS
If the navigator stops when no more position updates arrive, it won't
switch to land mode when DESCEND is requested by the commander.
2016-06-21 10:21:34 +02:00
Julian Oes fe29d99d62 commander: use the gps_failure flag
The gps_failure flag had been ignored in some navigation states.
2016-06-21 10:21:34 +02:00
Julian Oes 4d10759699 commander: use DESCEND mode and not LANDGPSFAIL
Always use the DESCEND mode and not LANDGPSFAIL because LANDGPSFAIL will
try to loiter for some time and then request termination instead of
descending gently and trying to land.
2016-06-21 10:21:34 +02:00
Henry Zhang 178f32ab41 Commander:fill missing command ack. (#4814) 2016-06-21 10:20:33 +02:00
Chris Lovett 847d9ec4f4 Fix code style using Tools/fix_code_style.sh 2016-06-21 10:10:50 +02:00
Chris Lovett 534e10c96a Implement code review feedback. Add get_id_static to MavlinkStream items. Add implementation of MAV_CMD_SET_MESSAGE_INTERVAL, MAV_CMD_GET_MESSAGE_INTERVAL. Add deprecation message to REQUEST_DATA_STREAM. 2016-06-21 10:10:50 +02:00
Chris Lovett 4ef4be2d70 MavlinkReceiver::handle_message_request_data_stream walks into deleted memory when you send the "stop" bit on a stream. It also fails to restart the stream because it deletes the stream when you send the stop command, so restart needs to use stream_list to find the stream again. 2016-06-21 10:10:50 +02:00
Lorenz Meier 3f45d008eb Fix stack main usage in motor ramp app 2016-06-21 09:43:00 +02:00
Julian Oes 8aee4432a9 px4io: set safety on before going into bootloader (#4860)
Sometimes when flashing new firmware, the IO update fails because safety
is off. In this case, we should set safety on first before putting the
IO board into bootloader mode.
2016-06-21 09:15:38 +02:00
Lorenz Meier 85245471c0 Update 3DR quad config, remove rendundant entries 2016-06-20 22:37:05 +02:00
Andreas Antener 2c29652136 fixed code style in motor_ramp 2016-06-20 20:59:43 +02:00
Andreas Antener 0581f1af52 added motor_ramp to fmu v4 2016-06-20 20:24:46 +02:00
Andreas Antener 2dc97fc680 added check for running attitude controllers, cleaned-up output 2016-06-20 20:24:46 +02:00
Andreas Antener 4e0980aeb9 fixed sine output 2016-06-20 20:24:46 +02:00
Andreas Antener 7f56961e26 removed unnecessary output texts 2016-06-20 20:24:46 +02:00
Roman 87dc996a41 added option to output sine wave 2016-06-20 20:24:46 +02:00
Andreas Antener b3c3d6f88f fixed format error 2016-06-20 20:24:46 +02:00
Andreas Antener 7c76c7c25a added warning, set hold time to 1 sec 2016-06-20 20:24:46 +02:00
Andreas Antener a7834693e8 updated usage, increased prio and lowered max hold time 2016-06-20 20:24:46 +02:00
Andreas Antener d8cdb2032c constantly set outputs for ramp, otherwise the ESC doesn't keep it's setting (why?) 2016-06-20 20:24:46 +02:00
Andreas Antener ede032c557 ouput pwm values directly 2016-06-20 20:24:45 +02:00
Andreas Antener fabb37975d added motor_ramp to v2 config 2016-06-20 20:24:45 +02:00
Andreas Antener 0b930a36b9 added parameters to motor_ramp 2016-06-20 20:24:45 +02:00
Andreas Antener 1aeb139157 added motor ramp app, draft impl 2016-06-20 20:24:45 +02:00
Andreas Antener d1b27ab056 moved params NAV_OBL to COM_OBL 2016-06-20 19:23:11 +02:00
Andreas Antener 8727295f8e fix OBL parameters in commander 2016-06-20 19:03:10 +02:00
Andreas Antener d3d9f013f4 set OBL parameters for iris 2016-06-20 19:03:10 +02:00
Andreas Antener 095997ca59 changed order of arguments for readability 2016-06-20 19:03:10 +02:00
Andreas Antener fedb9de6ef fixed offboard loss timing handling 2016-06-20 19:03:09 +02:00
Andreas Antener ced8376268 added offboard lost actions with additional timeout 2016-06-20 19:03:09 +02:00
Daniel Agar e42b5804a0 travis-ci only run make check within docker (#4854)
* otherwise the build environment doesn't get the proper return code
2016-06-20 10:03:37 -04:00
Julian Oes d92496a7f7 df_ms5607_wrapper: astyle (#4853) 2016-06-20 15:29:30 +02:00
Michael Schaeuble f95f37cb7b Update to DF commit with the MS5607 driver 2016-06-20 12:55:01 +02:00
Michael Schaeuble 83ec092b46 Update bebop configuration and use parameters 2016-06-20 12:55:01 +02:00
Michael Schaeuble cc0d28e59b Update DF to include the MS5607 driver 2016-06-20 12:55:01 +02:00
Michael Schaeuble 0d9c031a2c Check for bebop ip as environment variable 2016-06-20 12:55:01 +02:00
Michael Schaeuble 847562f5d7 Don't build px4_simple_app anymore 2016-06-20 12:55:01 +02:00
Michael Schaeuble 47613fefa0 Don't advertise garbage, apply same fix from #4735 2016-06-20 12:55:01 +02:00
Michael Schaeuble 52d8723d55 Add df_ms5607_wrapper (a renamed copy from BMP280) 2016-06-20 12:55:01 +02:00
Michael Schaeuble 696a378120 Add modules and commands to bebop build 2016-06-20 12:55:01 +02:00
Michael Schaeuble 9933494d53 Add parrot bebop build structure 2016-06-20 12:55:01 +02:00
Lorenz Meier b2cfe05881 Adjust Typhoon H480 gains 2016-06-20 12:54:22 +02:00
Julian Oes 146c8ddbc3 px4_getopt: astyle 2016-06-20 09:37:43 +02:00
Lorenz Meier 97f6ad4e53 Even better Gazebo models 2016-06-18 19:28:48 +02:00
Lorenz Meier a812224103 Update standard VTOL 2016-06-18 18:18:00 +02:00
Lorenz Meier 95430180f0 Update gazebo 2016-06-18 17:37:24 +02:00
Lorenz Meier c647b6db4d Update gains 2016-06-18 17:36:48 +02:00
Lorenz Meier d860bdcdc0 Update VTOL gains 2016-06-18 17:03:49 +02:00
Lorenz Meier 229208610e Fix simulator code style 2016-06-18 17:03:11 +02:00
Lorenz Meier e7d02f6272 Update VTOL gains 2016-06-18 16:59:46 +02:00
Lorenz Meier 3ef6ee056f Sync rate control gains 2016-06-18 16:58:04 +02:00
Lorenz Meier 3c9f5694e7 Fix Gazebo models for VTOL and planes 2016-06-18 16:38:49 +02:00
Lorenz Meier 03813cc46b Update fixed VTOL model 2016-06-18 16:29:39 +02:00
Lorenz Meier afdc8cdf55 VTOL: Use standard attitude gains 2016-06-18 16:29:28 +02:00
Lorenz Meier 2242331f08 Update SITL Gazebo 2016-06-18 15:34:37 +02:00
Lorenz Meier eabb504445 Compress Iris Gazebo model 2016-06-18 13:16:05 +02:00
Lorenz Meier 7b109bacf2 Update Gazebo models 2016-06-18 12:08:45 +02:00
Lorenz Meier fd768fe5ac Update models 2016-06-18 10:41:35 +02:00
Lorenz Meier 5d18ea7502 Update models 2016-06-18 10:40:34 +02:00
Lorenz Meier 51df9771b3 Add support for more than 8 outputs, but do not enable it yet 2016-06-18 01:54:31 +02:00
Lorenz Meier 85e3073f14 Simulator: Send all actuator output groups 2016-06-18 01:50:42 +02:00
Lorenz Meier c285e231b7 Update jMAVSim 2016-06-17 22:44:42 +02:00
Lorenz Meier 9230688f54 Commander: Add transition command 2016-06-17 22:44:42 +02:00
Lorenz Meier e8274d3ddb SITL: Add gimbal meshes 2016-06-17 22:44:42 +02:00
Lorenz Meier e6b82898fb Add airframe model 2016-06-17 22:44:42 +02:00
Lorenz Meier 0126e49841 Solo: Use the right mixer 2016-06-17 22:44:42 +02:00
Lorenz Meier dff50072e9 Add new airframe meta files 2016-06-17 22:44:42 +02:00
Lorenz Meier 55267b9ad3 Add new airframe 2016-06-17 22:44:42 +02:00
Lorenz Meier 825ba912c3 Update plane mixer 2016-06-17 22:44:42 +02:00
Lorenz Meier 3770bfd641 Update Gazebo model for plane 2016-06-17 22:44:42 +02:00
Lorenz Meier d50e307243 Update Tailsitter model 2016-06-17 22:44:42 +02:00
Lorenz Meier c248adb18d Fix tuning gains for Solo and tailsitter 2016-06-17 22:44:42 +02:00
Lorenz Meier 96387ed824 Update SITL gazebo 2016-06-17 22:44:42 +02:00
Lorenz Meier acd7c37057 Get closer to correct tailsitter mixer, still incomplete 2016-06-17 22:44:42 +02:00
Lorenz Meier 413233341e Update SITL Gazebo model 2016-06-17 22:44:42 +02:00
Lorenz Meier afa9467dad Final plane mixer 2016-06-17 22:44:42 +02:00
Lorenz Meier 982c25b7da Update SITL Gazebo with new consistent interface 2016-06-17 22:44:42 +02:00
Lorenz Meier 184da9e743 Remove null mixers from plane now that we are doing it correctly 2016-06-17 22:44:42 +02:00
Lorenz Meier f11d42aab3 Simulator MAVLink: Forward port cleanly 2016-06-17 22:44:42 +02:00
Andreas Bircher 46ec1e6b95 fixing cherry-picking divergences 2016-06-17 22:39:02 +02:00
Andreas Bircher 6bd17c7ba4 adding user info 2016-06-17 22:39:02 +02:00
Andreas Bircher e951a356fe fixing the driver interface
Conflicts:
	PX4/src/drivers/camera_trigger/interfaces/src/pwm.cpp
	PX4/src/drivers/camera_trigger/interfaces/src/pwm.h
2016-06-17 22:39:02 +02:00
Andreas Bircher f038b16734 adding arming check before setting PWM 2016-06-17 22:39:02 +02:00
Kelly Steich eed968979f added parameter for choosing the camera interface mode
Conflicts:
	PX4/src/drivers/camera_trigger/camera_trigger.cpp
2016-06-17 22:39:02 +02:00
Andreas Bircher c49a2da261 adding arming check before setting PWM 2016-06-17 22:39:02 +02:00
Kelly Steich 2ec1e508d2 added setup method to constructor of camera interfaces
Conflicts:
	PX4/src/drivers/camera_trigger/interfaces/src/pwm.cpp
2016-06-17 22:39:02 +02:00
Andreas Bircher adffb85962 adding arming check before setting PWM 2016-06-17 22:39:02 +02:00
Kelly Steich 4c5f32ab16 delete the camera interface object in camera trigger destructor 2016-06-17 22:39:02 +02:00
Andreas Bircher f83c53c274 adding the initial pwm trigger logic 2016-06-17 22:39:02 +02:00
Kelly Steich 3671bfb743 added the camera interface info method to the camera trigger info method 2016-06-17 22:39:02 +02:00
Kelly Steich 29f31ae6ac fixed the triggering function logic
Conflicts:
	PX4/src/drivers/camera_trigger/camera_trigger.cpp
	PX4/src/drivers/camera_trigger/interfaces/src/camera_interface.h
	PX4/src/drivers/camera_trigger/interfaces/src/pwm.cpp
	PX4/src/drivers/camera_trigger/interfaces/src/pwm.h
	PX4/src/drivers/camera_trigger/interfaces/src/relay.cpp
	PX4/src/drivers/camera_trigger/interfaces/src/relay.h
2016-06-17 22:39:02 +02:00
Kelly Steich b31c346ea7 new file structure for the camera_trigger driver
Conflicts:
	PX4/cmake/configs/nuttx_px4fmu-v2_default.cmake
2016-06-17 22:39:02 +02:00
Julian Oes 1dec6e83c6 ecl: update submodule (#4839) 2016-06-17 21:16:54 +02:00
Eric Ye c446304751 Update makefile to ask for cmake 3.4.3 (#4831) 2016-06-17 10:47:06 -04:00
Daniel Agar bada390dde fw_pos_control_l1 fix FW_LND_FLALT usage (#4835)
-fixes #4745
2016-06-16 21:02:28 +02:00
David Sidrane 538d9ada25 Needed to avoid name collsion in upcomming Nuttx logger changes (#4830) 2016-06-15 21:51:53 +02:00
Daniel Agar e2801d35e4 fix comment spelling 2016-06-15 20:35:16 +02:00
Daniel Agar 64d9b8eefd fix COM_FLTMODE5 metadata typo 2016-06-15 20:35:16 +02:00
Daniel Agar 4ab8ddec53 rename cb_usb -> circuit_breaker_engaged_usb_check 2016-06-15 20:35:16 +02:00
Daniel Agar c22a9137dd commander cleanup headers 2016-06-15 20:35:16 +02:00
Daniel Agar 7bbfa5d94b cleanup px4_custom_mode 2016-06-15 20:35:16 +02:00
Daniel Agar d16daf5ba4 pwm_out_sim sleep if no fds (#4829)
-fixes #4828
2016-06-15 20:29:19 +02:00
James Goppert 2a26611cf5 Make LPE sonar reading more robust. (#4806) 2016-06-15 12:37:52 -04:00
Julian Oes a76eab367c DriverFramework: update submodule
This brings various PRs in:
- RPi build fixes
- unit tests on CI and on Mac
- some cmake cleanup
- CI style check for DF
2016-06-15 13:36:30 +01:00
Julian Oes d9d5d9d9e4 mc_pos_control: run the loop without position data
By running the loop in mc_pos_control without successfully polling on
position data, we still copy the manual input over so that
mc_att_control can consume it. This allows to fly in manual mode without
GPS and no position estimate.
2016-06-15 13:34:27 +01:00
Beat Küng 26b7ac3884 mavlink: remove an UDP remote port warning, print remote port in mode info 2016-06-15 09:56:34 +02:00
Beat Küng 574a67b93d fix px4_getopt: ensure progress in case of unknown options
Previously sdlog2 got stuck in an endless loop if an unknown argument was
given
2016-06-15 09:55:25 +02:00
Beat Küng 2b85c594b3 fix px4_getopt: correctly handle options that take an argument, but no argument is given
This lead to a segfault, for example 'logger start -r'
2016-06-15 09:53:37 +02:00
CarlOlsson d66af65a92 ekf2: fixed airspeed thr bug 2016-06-14 10:28:40 +02:00
Lorenz Meier b731a9e96c Fix AR Drone scaling param 2016-06-14 08:42:12 +02:00
Daniel Agar 2eac57731c travis-ci fix missing semicolon (#4812) 2016-06-14 02:18:22 -04:00
Daniel Agar f13b75a6d2 travis-ci fix s3 deploy conditions (#4810) 2016-06-14 01:56:42 -04:00
Daniel Agar 2f5357be7a travis-ci use px4io docker images (#4696) 2016-06-14 01:06:43 -04:00
Daniel Agar 6f7e978f33 initial circle-ci configuration (#4807) 2016-06-13 17:39:30 -04:00
Lorenz Meier 4cca4ea954 Add DOI 2016-06-12 11:53:55 +02:00
2232 changed files with 241594 additions and 118459 deletions
+87
View File
@@ -0,0 +1,87 @@
Checks: '*
,-cert-dcl50-cpp
,-cert-err34-c
,-cert-err58-cpp
,-cert-msc30-c
,-cert-msc50-cpp
,-clang-analyzer-core.CallAndMessage
,-clang-analyzer-core.NullDereference
,-clang-analyzer-core.UndefinedBinaryOperatorResult
,-clang-analyzer-core.uninitialized.Assign
,-clang-analyzer-core.VLASize
,-clang-analyzer-cplusplus.NewDelete
,-clang-analyzer-cplusplus.NewDeleteLeaks
,-clang-analyzer-deadcode.DeadStores
,-clang-analyzer-optin.cplusplus.VirtualCall
,-clang-analyzer-optin.performance.Padding
,-clang-analyzer-security.insecureAPI.strcpy
,-clang-analyzer-unix.API
,-clang-analyzer-unix.cstring.BadSizeArg
,-clang-analyzer-unix.Malloc
,-clang-analyzer-unix.MallocSizeof
,-cppcoreguidelines-c-copy-assignment-signature
,-cppcoreguidelines-interfaces-global-init
,-cppcoreguidelines-no-malloc
,-cppcoreguidelines-pro-bounds-array-to-pointer-decay
,-cppcoreguidelines-pro-bounds-constant-array-index
,-cppcoreguidelines-pro-bounds-pointer-arithmetic
,-cppcoreguidelines-pro-type-const-cast
,-cppcoreguidelines-pro-type-cstyle-cast
,-cppcoreguidelines-pro-type-member-init
,-cppcoreguidelines-pro-type-reinterpret-cast
,-cppcoreguidelines-pro-type-union-access
,-cppcoreguidelines-pro-type-vararg
,-cppcoreguidelines-special-member-functions
,-google-build-using-namespace
,-google-explicit-constructor
,-google-global-names-in-headers
,-google-readability-casting
,-google-readability-namespace-comments
,-google-readability-todo
,-google-runtime-int
,-google-runtime-references
,-llvm-header-guard
,-llvm-include-order
,-llvm-namespace-comment
,-misc-incorrect-roundings
,-misc-macro-parentheses
,-misc-misplaced-widening-cast
,-misc-redundant-expression
,-misc-unconventional-assign-operator
,-misc-unused-parameters
,-modernize-deprecated-headers
,-modernize-loop-convert
,-modernize-use-auto
,-modernize-use-bool-literals
,-modernize-use-default-member-init
,-modernize-use-emplace
,-modernize-use-equals-default
,-modernize-use-equals-delete
,-modernize-use-override
,-modernize-use-using
,-performance-inefficient-string-concatenation
,-readability-avoid-const-params-in-decls
,-readability-else-after-return
,-readability-implicit-bool-cast
,-readability-inconsistent-declaration-parameter-name
,-readability-non-const-parameter
,-readability-redundant-declaration
,-readability-redundant-member-init
,-readability-simplify-boolean-expr
'
WarningsAsErrors: '*'
CheckOptions:
- key: google-readability-braces-around-statements.ShortStatementLines
value: '1'
- key: google-readability-function-size.BranchThreshold
value: '600'
- key: google-readability-function-size.LineThreshold
value: '4000'
- key: google-readability-function-size.StatementThreshold
value: '4000'
- key: readability-braces-around-statements.ShortStatementLines
value: '1'
- key: readability-function-size.LineThreshold
value: '4000'
- key: readability-function-size.StatementThreshold
value: '4000'
+9
View File
@@ -0,0 +1,9 @@
**Bug Report** or **Feature Request**
For general questions please use [PX4 Discuss](http://discuss.px4.io/) or [Slack](slack.px4.io). Issue reports need to contain the items below:
- Download the flight log file from the vehicle ([tutorial](https://docs.px4.io/en/flight-reporting.html))
- Share the link to a log showing the problem on [PX4 Flight Review](http://logs.px4.io/)
- Expected behavior and actual behavior.
- Steps to reproduce the problem.
- Specifications like the version of the project, operating system, or hardware.
+33
View File
@@ -0,0 +1,33 @@
# How to install:
# gem install github_changelog_generator
# How to run:
# github_changelog_generator -u PX4 -p Firmware
# Description:
# The following params are sensible defaults for the PX4 project,
# if you want to do a changelog before a release you need to update since-tag and future-releases,
# Params:
# github_changelog_generator --help for all options
# max-issues
# max threshold for github api queries
# make sure you set your CHANGELOG_GITHUB_TOKEN before
# running
max-issues=1500
# exclude-tags-regex
# excludes release candidates
exclude-tags-regex=rc[0-9]{1,}|beta[0-9]{1,}
# since-tag
# version of last stable release
# you need to change this depending on what you need
# if you want a changelog between versions this is the lowest version
since-tag=1.6.5
# future-release
# version you are about to release
# if you want a changelog between a version and all unreleased changes grouped as a release
# eg: v1.6.5 to v1.7.0
future-release=v1.7.0
+19 -21
View File
@@ -1,10 +1,6 @@
*.d
!ROMFS/*/*.d
!ROMFS/*/*/*.d
!ROMFS/*/*/*/*.d
*.px4log
*.dSYM
*.o
*.gch
*.pyc
*~
.*.swp
@@ -16,9 +12,10 @@
.settings
.swp
.~lock.*
Archives/*
Build/*
Testing/
Packages/*
s3deploy-branch/
s3deploy-archive/
build/*
build_*/
core
@@ -27,15 +24,6 @@ cscope.in.out
cscope.po.out
Firmware.sublime-workspace
user.sublime*
Images/*.bin
Images/*.px4
mavlink/include/mavlink/v0.9/
/nuttx-configs/px4io-v2/src/.depend
/nuttx-configs/px4io-v2/src/Make.dep
/nuttx-configs/px4io-v2/src/libboard.a
/nuttx-configs/px4io-v1/src/.depend
/nuttx-configs/px4io-v1/src/Make.dep
/nuttx-configs/px4io-v1/src/libboard.a
/Documentation/doxy.log
/Documentation/html/
/Documentation/doxygen*objdb*tmp
@@ -49,7 +37,6 @@ src/modules/uORB/topics/*
src/platforms/nuttx/px4_messages/*
src/platforms/ros/px4_messages/*
Firmware.zip
unittests/build
*.generated.h
.vagrant
*.pretty
@@ -64,12 +51,23 @@ CMakeLists.txt.user
GPATH
GRTAGS
GTAGS
*.config
*.creator
*.creator.user
*.files
*.includes
# uavcan firmware
ROMFS/px4fmu_common/uavcan/
vectorcontrol/
# CLion ignores
.idea
cmake-build-*/
.vscode
posix-configs/SITL/init/test/*_generated
/airframes.md
/airframes.xml
/parameters.md
/parameters.xml
/modules
*.gcov
+32 -14
View File
@@ -1,43 +1,61 @@
[submodule "mavlink/include/mavlink/v1.0"]
path = mavlink/include/mavlink/v1.0
url = git://github.com/mavlink/c_library.git
[submodule "NuttX"]
path = NuttX
url = git://github.com/PX4/NuttX.git
url = https://github.com/mavlink/c_library_v1.git
branch = master
[submodule "mavlink/include/mavlink/v2.0"]
path = mavlink/include/mavlink/v2.0
url = https://github.com/mavlink/c_library_v2.git
branch = master
[submodule "src/modules/uavcan/libuavcan"]
path = src/modules/uavcan/libuavcan
url = git://github.com/UAVCAN/libuavcan.git
url = https://github.com/UAVCAN/libuavcan.git
[submodule "Tools/genmsg"]
path = Tools/genmsg
path = msg/tools/genmsg
url = https://github.com/ros/genmsg.git
[submodule "Tools/gencpp"]
path = Tools/gencpp
path = msg/tools/gencpp
url = https://github.com/ros/gencpp.git
[submodule "Tools/jMAVSim"]
path = Tools/jMAVSim
url = https://github.com/PX4/jMAVSim.git
branch = master
[submodule "Tools/sitl_gazebo"]
path = Tools/sitl_gazebo
url = https://github.com/PX4/sitl_gazebo.git
[submodule "unittests/googletest"]
path = unittests/googletest
url = https://github.com/google/googletest.git
ignore = untracked
branch = master
[submodule "src/lib/matrix"]
path = src/lib/matrix
url = https://github.com/PX4/Matrix.git
branch = master
[submodule "src/lib/DriverFramework"]
path = src/lib/DriverFramework
url = https://github.com/PX4/DriverFramework.git
branch = master
[submodule "src/lib/ecl"]
path = src/lib/ecl
url = https://github.com/PX4/ecl.git
branch = master
[submodule "cmake/cmake_hexagon"]
path = cmake/cmake_hexagon
url = https://github.com/ATLFlight/cmake_hexagon
branch = master
[submodule "src/drivers/gps/devices"]
path = src/drivers/gps/devices
url = https://github.com/PX4/GpsDrivers.git
[submodule "mavlink/include/mavlink/v2.0"]
path = mavlink/include/mavlink/v2.0
url = git://github.com/mavlink/c_library.git
branch = master
[submodule "src/lib/micro-CDR"]
path = src/modules/micrortps_bridge/micro-CDR
url = https://github.com/eProsima/micro-CDR.git
branch = master
[submodule "platforms/nuttx/NuttX/nuttx"]
path = platforms/nuttx/NuttX/nuttx
url = https://github.com/PX4-NuttX/nuttx.git
branch = px4_firmware_nuttx-7.22+
[submodule "platforms/nuttx/NuttX/apps"]
path = platforms/nuttx/NuttX/apps
url = https://github.com/PX4-NuttX/apps.git
branch = px4_firmware_nuttx-7.22+
[submodule "cmake/configs/uavcan_board_ident"]
path = cmake/configs/uavcan_board_ident
url = https://github.com/PX4/uavcan_board_ident.git
branch = master
+43 -125
View File
@@ -1,144 +1,62 @@
# Build and autotest script for PX4 Firmware
# http://travis-ci.org
sudo: required
services:
- docker
language: cpp
git:
depth: 2000
submodules: false
env:
global:
# COVERITY_SCAN_TOKEN
- secure: "Q4IAcmo1r5cr/UvhcixQa6QN5e5eTcP7FeidzEbX2+BA38yo2BH5O9YQCvZe2AI1Na8ZCjVx3H2luGgDwOKgzAIAjXjZ2KbmXYc6Ns/j/BXScY05dCCzYEhXKD98NZxIKH9lLN9pYDGRA8pChGRJnVlFOr1JHHHnB801+osHy7M="
# AWS KEY: $PX4_AWS_KEY
- secure: "XknnZHWBbpHbN4f3fuAVwUztdLIu8ej4keC3aQSDofo3uw8AFEzojfsQsN9u77ShWSIV4iYJWh9C9ALkCx7TocJ+xYjiboo10YhM9lH/8u+EXjYWG6GHS8ua0wkir+cViSxoLNaMtmcb/rPTicJecAGANxLsIHyBAgTL3fkbLSA="
# AWS SECRET: $PX4_AWS_SECRET
- secure: "h6oajlW68dWIr+wZhO58Dv6e68dZHrBLVA6lPXZmheFQBW6Xam1HuLGA0LOW6cL9TnrAsOZ8g4goB58eMQnMEijFZKi3mhRwZhd/Xjq/ZGJOWBUrLoQHZUw2dQk5ja5vmUlKEoQnFZjDuMjx8KfX5ZMNy8A3yssWZtJYHD8c+bk="
matrix:
fast_finish: true
include:
- os: linux
sudo: false
env: GCC_VER=4.8
- os: linux
sudo: false
env: GCC_VER=4.9
- os: osx
osx_image: xcode7
sudo: true
- env: BUILD_TARGET=coverity_scan
dist: trusty
if: branch = coverity_scan
allow_failures:
- env: BUILD_TARGET=tests_coverage
cache:
directories:
- $HOME/.ccache
addons:
apt:
sources:
- kubuntu-backports
- ubuntu-toolchain-r-test
- george-edison55-precise-backports
packages:
- build-essential
- ccache
- clang-3.5
- cmake
- g++-4.9
- gcc-4.9
- genromfs
- libc6-i386
- libncurses5-dev
- ninja-build
- python-argparse
- python-empy
- s3cmd
- texinfo
- zlib1g-dev
ccache: true
before_install:
- cd ${TRAVIS_BUILD_DIR} && git fetch --unshallow && git fetch --all --tags
- if [ "${TRAVIS_OS_NAME}" = "linux" ]; then
pushd .
&& cd ~ && mkdir gcc && cd gcc
&& if [ "$GCC_VER" = "4.8" ]; then GCC_URL="https://launchpadlibrarian.net/186124160/gcc-arm-none-eabi-4_8-2014q3-20140805-linux.tar.bz2" ; fi
&& if [ "$GCC_VER" = "4.9" ]; then GCC_URL="https://launchpad.net/gcc-arm-embedded/4.9/4.9-2014-q4-major/+download/gcc-arm-none-eabi-4_9-2014q4-20141203-linux.tar.bz2" ; fi
&& wget -O gcc.tar.bz2 ${GCC_URL}
&& tar -jxf gcc.tar.bz2 --strip 1
&& exportline="export PATH=$HOME/gcc/bin:\$PATH"
&& if grep -Fxq "$exportline" ~/.profile; then echo nothing to do ; else echo $exportline >> ~/.profile; fi
&& . ~/.profile
&& popd
&& git clone git://github.com/PX4/CI-Tools.git
&& ./CI-Tools/s3cmd-configure
&& mkdir -p ~/bin
&& wget -O ~/bin/astyle https://github.com/PX4/astyle/releases/download/2.05.1/astyle-linux && chmod +x ~/bin/astyle
&& astyle --version
&& if [ "$CXX" = "g++" ]; then export CXX="g++-4.9" CC="gcc-4.9"; fi
;
elif [ "${TRAVIS_OS_NAME}" = "osx" ]; then
brew tap PX4/homebrew-px4
&& brew update; brew update
&& brew install cmake ninja
&& brew install genromfs
&& sudo easy_install pip
&& sudo pip install empy
;
# install dependencies for the coverity build (target and branch), otherwise exit early
- if [[ "${TRAVIS_BRANCH}" = "coverity_scan" ]]; then
sudo pip install empy jinja2 numpy toml;
echo -n | openssl s_client -connect scan.coverity.com:443 | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' | sudo tee -a /etc/ssl/certs/ca-;
fi
before_script:
# setup ccache
- mkdir -p ~/bin
- ln -s /usr/bin/ccache ~/bin/arm-none-eabi-g++
- ln -s /usr/bin/ccache ~/bin/arm-none-eabi-gcc
- ln -s /usr/bin/ccache ~/bin/arm-none-eabi-size
- ln -s /usr/bin/ccache ~/bin/arm-none-eabi-objcopy
- ln -s /usr/bin/ccache ~/bin/clang++
- ln -s /usr/bin/ccache ~/bin/clang++-3.4
- ln -s /usr/bin/ccache ~/bin/clang++-3.5
- ln -s /usr/bin/ccache ~/bin/clang
- ln -s /usr/bin/ccache ~/bin/clang-3.4
- ln -s /usr/bin/ccache ~/bin/clang-3.5
- export PATH=~/bin:$PATH
env:
global:
- NINJA_BUILD=1
# AWS KEY: $PX4_AWS_KEY
- secure: "XknnZHWBbpHbN4f3fuAVwUztdLIu8ej4keC3aQSDofo3uw8AFEzojfsQsN9u77ShWSIV4iYJWh9C9ALkCx7TocJ+xYjiboo10YhM9lH/8u+EXjYWG6GHS8ua0wkir+cViSxoLNaMtmcb/rPTicJecAGANxLsIHyBAgTL3fkbLSA="
# AWS SECRET: $PX4_AWS_SECRET
- secure: "h6oajlW68dWIr+wZhO58Dv6e68dZHrBLVA6lPXZmheFQBW6Xam1HuLGA0LOW6cL9TnrAsOZ8g4goB58eMQnMEijFZKi3mhRwZhd/Xjq/ZGJOWBUrLoQHZUw2dQk5ja5vmUlKEoQnFZjDuMjx8KfX5ZMNy8A3yssWZtJYHD8c+bk="
- PX4_AWS_BUCKET=px4-travis
# use git:// to fetch instead of https://
- git config --global url."git://".insteadOf https://
script:
- git submodule update --quiet --init --recursive
- if [ "${TRAVIS_OS_NAME}" = "linux" ]; then
arm-none-eabi-gcc --version && make check VECTORCONTROL=1;
elif [ "${TRAVIS_OS_NAME}" = "osx" ]; then
make check_posix_sitl_default;
fi
- ./Tools/docker_run.sh make ${BUILD_TARGET}
after_success:
- if [[ "${TRAVIS_OS_NAME}" = "linux" && "${GCC_VER}" = "4.8" ]]; then
make package_firmware
&& find . -name \*.px4 -exec cp "{}" . \;
&& find . -maxdepth 1 -mindepth 1 -type f -name 'nuttx-*-default.px4' | sed 's/.\/nuttx-//' | sed 's/-default.px4//' | xargs -I{} mv nuttx-{}-default.px4 {}_default.px4
&& ./CI-Tools/s3cmd-put `find . -maxdepth 1 -mindepth 1 -type f -name '*_default.px4'` build_px4fmu-v2_default/parameters.xml build_px4fmu-v2_default/airframes.xml CI-Tools/directory/index.html Firmware/$TRAVIS_BRANCH/
&& ./CI-Tools/s3cmd-put Firmware.zip archives/Firmware/$TRAVIS_BRANCH/$TRAVIS_BUILD_ID/
&& ./CI-Tools/s3cmd-put CI-Tools/directory/index.html archives/Firmware/$TRAVIS_BRANCH/
&& ./CI-Tools/s3cmd-put CI-Tools/index.html index.html
&& ./CI-Tools/s3cmd-put CI-Tools/timestamp.html timestamp.html
&& echo ""
&& echo "Binaries have been posted to:" https://px4-travis.s3.amazonaws.com/archives/Firmware/$TRAVIS_BRANCH/$TRAVIS_BUILD_ID/Firmware.zip
;
# upload code coverage
- if [ "${TRAVIS_PULL_REQUEST}" = "false" ]; then
[ "${BUILD_TARGET}" = "tests_coverage" ] && bash <(curl -s https://codecov.io/bash) -F unittests;
fi
deploy:
provider: releases
api_key:
secure: cdHWLRBxA5UlYpOS0Sp891QK7PFmMgQ5ZWs1aPt+sw0rIrowyWMHCwXNBEdUqaExHYNYgXCUDI0EzNgfB7ZcR63Qv1MQeoyamV4jsxlyAqDqmxNtWO82S6RhHGeMLk26VgFKzynVcEk1IYlQP2nqzMQLdu+jTrngERuAIrCdRuc=
file: "Firmware.zip"
skip_cleanup: true
on:
tags: true
all_branches: true
repo: PX4/Firmware
condition: $GCC_VER = 4.8
notifications:
webhooks:
urls:
- https://webhooks.gitter.im/e/2b9c4a4cb2211f8befba
on_success: always # options: [always|never|change] default: always
on_failure: always # options: [always|never|change] default: always
slack:
secure: "QKw73Zel/s3JAbe/7XyO9tPnJwiiGFpYzSjdR8lG3tYFjRdXZnhxG4c+G7bkgkaPTS4Hult33VXE3kcEqOI7+C+eRwRlZhDfL0knQbXVCxjcLjzmUFdoPOwurlgZDw66PFWCi5tZcLKSRo3u4U8ibT4WKi3jm9sDSyOcfBAucMU="
on_success: change # options: [always|never|change] default: always
on_failure: always # options: [always|never|change] default: always
addons:
coverity_scan:
project:
name: "PX4/Firmware"
description: "Build submitted via Travis CI"
notification_email: ci@px4.io
build_command_prepend: "make distclean"
build_command: "make posix_sitl_default"
branch_pattern: coverity_scan
-1
View File
@@ -61,7 +61,6 @@ flags = [
'c++',
'-undef', # get rid of standard definitions to allow us to include arm math header
'-I', os.path.join(os.path.expanduser("~"),'gcc-arm-none-eabi-4_7-2013q3/arm-none-eabi/include'),
'-I', 'Build/px4io-v1_default.build/nuttx-export/include/',
'-I', 'Build/px4io-v2_default.build/nuttx-export/include/',
'-I', './NuttX/nuttx/arch/arm/include',
'-include', './src/include/visibility.h',
+246 -161
View File
@@ -1,6 +1,6 @@
############################################################################
#
# Copyright (c) 2015 PX4 Development Team. All rights reserved.
# Copyright (c) 2017 PX4 Development Team. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
@@ -55,24 +55,6 @@
#
# * For else, endif, endfunction, etc, never put the name of the statement
#
# Instead of the very confusing:
# if (${var} STREQUAL "1") <-- condition now becomes if name
# # do somthing
# elseif (${var} STREQUAL "2") <-- another condition
# # do somthing
# else (${var} STREQUAL "1") <-- tag is referring to name of if
# # do somthing
# endif (${var} STREQUAL "1") <-- tag is referring to name of if
#
# Do this:
# if (${var} STREQUAL "1") <-- condition now becomes if name
# # do somthing
# elseif (${var} STREQUAL "2") <-- another condition
# # do somthing
# else () <-- leave blank
# # do somthing
# endif () <-- leave blank
#
# Functions/Macros
# ---------------------------------------------------------------------------
#
@@ -101,7 +83,7 @@
#
# * Setting a global variable in a CMakeLists.txt file is ok, because
# each CMakeLists.txt file has scope in the current directory and all
# subdirecties, so it is not truly global.
# subdirectories, so it is not truly global.
#
# * All toolchain files should be included in the cmake
# directory and named Toolchain-"name".cmake.
@@ -119,150 +101,215 @@
# Warning: Changing this modifies CMake's internal workings
# and leads to wrong toolchain detection
cmake_minimum_required(VERSION 2.8 FATAL_ERROR)
cmake_minimum_required(VERSION 3.2 FATAL_ERROR)
# Use clang
#SET (CMAKE_C_COMPILER /usr/bin/clang-3.6)
#SET (CMAKE_CXX_COMPILER /usr/bin/clang++-3.6)
set(PX4_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}")
set(PX4_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}")
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PX4_BINARY_DIR})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG ${PX4_BINARY_DIR})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE ${PX4_BINARY_DIR})
list(APPEND CMAKE_MODULE_PATH ${PX4_SOURCE_DIR}/cmake)
#=============================================================================
# parameters
# git
#
include(common/px4_git)
set(CMAKE_BUILD_TYPE "" CACHE STRING "build type")
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY
STRINGS ";Debug;Release;RelWithDebInfo;MinSizeRel")
set(CONFIG "nuttx_px4fmu-v2_default" CACHE STRING "desired configuration")
file(GLOB_RECURSE configs RELATIVE cmake/configs "cmake/configs/*.cmake")
set_property(CACHE CONFIG PROPERTY STRINGS ${configs})
set(THREADS "4" CACHE STRING
"number of threads to use for external build processes")
set(DEBUG_PORT "/dev/ttyACM0" CACHE STRING "debugging port")
execute_process(
COMMAND git describe --always --tags
OUTPUT_VARIABLE git_tag
OUTPUT_STRIP_TRAILING_WHITESPACE
WORKING_DIRECTORY ${PX4_SOURCE_DIR}
)
px4_add_git_submodule(TARGET git_ecl PATH "src/lib/ecl")
px4_add_git_submodule(TARGET git_matrix PATH "src/lib/matrix")
define_property(GLOBAL PROPERTY PX4_LIBRARIES
BRIEF_DOCS "PX4 libs"
FULL_DOCS "List of all PX4 module libraries"
)
#=============================================================================
# configuration
#
# must come before project to set toolchain
set(CONFIG "posix_sitl_default" CACHE STRING "desired configuration")
string(REPLACE "_" ";" config_args ${CONFIG})
list(GET config_args 0 OS)
list(GET config_args 1 BOARD)
list(GET config_args 2 LABEL)
set(target_name "${OS}-${BOARD}-${LABEL}")
set(target_name "${OS}_${BOARD}_${LABEL}")
message(STATUS "${target_name}")
file(GLOB_RECURSE configs RELATIVE cmake/configs "cmake/configs/*.cmake")
set_property(CACHE CONFIG PROPERTY STRINGS ${configs})
# switch to ros CMake file if building ros
if (${OS} STREQUAL "ros")
include("cmake/ros-CMakeLists.txt")
else() # otherwise use the rest of this file
set(THREADS "4" CACHE STRING "number of threads to use for external build processes")
set(DEBUG_PORT "/dev/ttyACM0" CACHE STRING "debugging port")
set(EXTERNAL_MODULES_LOCATION "" CACHE STRING "External modules source location")
list(APPEND CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake)
if (NOT EXTERNAL_MODULES_LOCATION STREQUAL "")
get_filename_component(EXTERNAL_MODULES_LOCATION "${EXTERNAL_MODULES_LOCATION}" ABSOLUTE)
endif()
list(APPEND CMAKE_MODULE_PATH ${PX4_SOURCE_DIR}/platforms/${OS}/cmake)
include(platforms/${OS}/cmake/px4_impl_os.cmake)
set(config_module "configs/${CONFIG}")
include(${config_module})
# cmake modules
include(ExternalProject)
include(common/coverage)
include(common/sanitizers)
# CMake build type
# Debug Release RelWithDebInfo MinSizeRel Coverage
if (NOT CMAKE_BUILD_TYPE)
if (${OS} STREQUAL "nuttx")
set(PX4_BUILD_TYPE "MinSizeRel")
elseif (${OS} STREQUAL "bebop")
set(PX4_BUILD_TYPE "MinSizeRel")
else()
set(PX4_BUILD_TYPE "RelWithDebInfo")
endif()
set(CMAKE_BUILD_TYPE ${PX4_BUILD_TYPE} CACHE STRING "Build type" FORCE)
endif()
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug;Release;RelWithDebInfo;MinSizeRel;Coverage")
message(STATUS "Build Type: ${CMAKE_BUILD_TYPE}")
#=============================================================================
message(STATUS "PX4 VERSION: ${git_tag}")
message(STATUS "CONFIG: ${target_name}")
message(STATUS "Build Type: ${CMAKE_BUILD_TYPE}")
#=============================================================================
# project definition
#
project(px4 CXX C ASM)
set(package-contact "px4users@googlegroups.com")
#=============================================================================
# The URL for the elf file for crash logging
if (DEFINED ENV{BUILD_URI})
set(BUILD_URI $ENV{BUILD_URI})
else()
set(BUILD_URI "localhost")
endif()
add_definitions(-DBUILD_URI=${BUILD_URI})
# Setup install paths
if (${OS} STREQUAL "posix")
# Define GNU standard installation directories
include(GNUInstallDirs)
if (NOT CMAKE_INSTALL_PREFIX)
set(CMAKE_INSTALL_PREFIX "/usr" CACHE PATH "Install path prefix" FORCE)
endif()
# cmake testing only on posix
enable_testing()
include(CTest)
endif()
#=============================================================================
# require px4 module interface
set(px4_required_interface
px4_os_prebuild_targets
px4_os_add_flags
)
foreach(cmd ${px4_required_interface})
if(NOT COMMAND ${cmd})
if (NOT COMMAND ${cmd})
message(FATAL_ERROR "${config_module} must implement ${cmd}")
endif()
endforeach()
set(px4_required_config
config_module_list
)
set(px4_required_config config_module_list)
foreach(conf ${px4_required_config})
if(NOT DEFINED ${conf})
if (NOT DEFINED ${conf})
message(FATAL_ERROR "cmake/${config_module} must define ${conf}")
endif()
endforeach()
# List the DriverFramework drivers
if(DEFINED config_df_driver_list)
message("DF Drivers: ${config_df_driver_list}")
# force static lib build
set(BUILD_SHARED_LIBS OFF)
#=============================================================================
# ccache
#
option(CCACHE "Use ccache if available" ON)
find_program(CCACHE_PROGRAM ccache)
if (CCACHE AND CCACHE_PROGRAM AND NOT DEFINED ENV{CCACHE_DISABLE})
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE "${CCACHE_PROGRAM}")
else()
endif()
#=============================================================================
# project definition
# find programs and packages
#
project(px4 CXX C ASM)
if (NOT ${CMAKE_VERSION} VERSION_LESS 3.0.0)
cmake_policy(SET CMP0045 NEW) # error on non-existent target in get prop
cmake_policy(SET CMP0046 NEW) # no non-existent targets as dependencies
cmake_policy(SET CMP0025 OLD) # still report AppleClang as Clang
endif()
if (NOT ${CMAKE_VERSION} VERSION_LESS 3.1.0)
cmake_policy(SET CMP0054 NEW) # don't dereference quoted variables
# see if catkin was invoked to build this
if (CATKIN_DEVEL_PREFIX)
message(STATUS "catkin ENABLED")
find_package(catkin REQUIRED)
if (catkin_FOUND)
catkin_package()
else()
message(FATAL_ERROR "catkin not found")
endif()
endif()
set(version_major 1)
set(version_minor 0)
set(version_patch 1)
set(version "${version_major}.${version_minor}.${version_patch}")
set(package-contact "px4users@googlegroups.com")
#=============================================================================
# programs
#
find_package(PythonInterp REQUIRED)
px4_find_python_module(jinja2 REQUIRED)
#=============================================================================
# cmake modules
# generate compile command database
#
enable_testing()
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
#=============================================================================
# check required toolchain variables
#
set(required_variables
CMAKE_C_COMPILER_ID
)
# PX4 requires c++11
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
# PX4 requires c99
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_STANDARD_REQUIRED ON)
set(required_variables CMAKE_C_COMPILER_ID CMAKE_CXX_COMPILER_ID)
foreach(var ${required_variables})
if (NOT ${var})
message(FATAL_ERROR "Toolchain/config must define ${var}")
endif()
endforeach()
#=============================================================================
# git
#
px4_add_git_submodule(TARGET git_genmsg PATH "Tools/genmsg")
px4_add_git_submodule(TARGET git_gencpp PATH "Tools/gencpp")
px4_add_git_submodule(TARGET git_mavlink PATH "mavlink/include/mavlink/v1.0")
px4_add_git_submodule(TARGET git_gtest PATH "unittets/gtest")
px4_add_git_submodule(TARGET git_uavcan PATH "src/modules/uavcan/libuavcan")
px4_add_git_submodule(TARGET git_nuttx PATH "NuttX")
px4_add_git_submodule(TARGET git_driverframework PATH "src/lib/DriverFramework")
px4_add_git_submodule(TARGET git_ecl PATH "src/lib/ecl")
px4_add_git_submodule(TARGET git_jmavsim PATH "Tools/jMAVSim")
px4_add_git_submodule(TARGET git_gazebo PATH "Tools/sitl_gazebo")
px4_add_git_submodule(TARGET git_matrix PATH "src/lib/matrix")
px4_add_git_submodule(TARGET git_cmake_hexagon PATH "cmake/cmake_hexagon")
# print full c compiler version
execute_process(COMMAND ${CMAKE_C_COMPILER} --version
OUTPUT_VARIABLE c_compiler_version
OUTPUT_STRIP_TRAILING_WHITESPACE
)
STRING(REGEX MATCH "[^\n]*" c_compiler_version_short ${c_compiler_version})
message(STATUS "C compiler: ${c_compiler_version_short}")
add_custom_target(submodule_clean
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
COMMAND git submodule deinit -f .
COMMAND rm -rf .git/modules/*
)
#=============================================================================
# misc targets
#
add_custom_target(check_format
COMMAND Tools/check_code_style.sh
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
)
add_custom_target(config
COMMAND cmake-gui .
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
)
# print full c++ compiler version
execute_process(COMMAND ${CMAKE_CXX_COMPILER} --version
OUTPUT_VARIABLE cxx_compiler_version
OUTPUT_STRIP_TRAILING_WHITESPACE
)
STRING(REGEX MATCH "[^\n]*" cxx_compiler_version_short ${cxx_compiler_version})
message(STATUS "C++ compiler: ${cxx_compiler_version_short}")
#=============================================================================
# external libraries
@@ -278,39 +325,52 @@ px4_os_add_flags(
BOARD ${BOARD}
C_FLAGS c_flags
CXX_FLAGS cxx_flags
OPTIMIZATION_FLAGS optimization_flags
EXE_LINKER_FLAGS exe_linker_flags
INCLUDE_DIRS include_dirs
LINK_DIRS link_dirs
DEFINITIONS definitions)
px4_join(OUT CMAKE_EXE_LINKER_FLAGS LIST "${exe_linker_flags}" GLUE " ")
px4_join(OUT CMAKE_C_FLAGS LIST "${c_flags}" GLUE " ")
px4_join(OUT CMAKE_CXX_FLAGS LIST "${cxx_flags}" GLUE " ")
px4_join(OUT CMAKE_EXE_LINKER_FLAGS LIST "${CMAKE_EXE_LINKER_FLAGS};${exe_linker_flags}" GLUE " ")
px4_join(OUT CMAKE_C_FLAGS LIST "${CMAKE_C_FLAGS};${c_flags};${optimization_flags}" GLUE " ")
px4_join(OUT CMAKE_CXX_FLAGS LIST "${CMAKE_CXX_FLAGS};${cxx_flags};${optimization_flags}" GLUE " ")
include_directories(${include_dirs})
#message("INCLUDE_DIRS=${include_dirs}")
link_directories(${link_dirs})
add_definitions(${definitions})
#=============================================================================
# source code generation
# message, and airframe generation
#
include(common/px4_metadata)
add_subdirectory(msg)
px4_generate_messages(TARGET msg_gen
MSG_FILES ${msg_files}
OS ${OS}
DEPENDS git_genmsg git_gencpp prebuild_targets
)
px4_generate_parameters_xml(OUT parameters.xml BOARD ${BOARD})
px4_generate_airframes_xml(OUT airframes.xml BOARD ${BOARD})
add_custom_target(xml_gen
DEPENDS parameters.xml airframes.xml)
px4_generate_airframes_xml(BOARD ${BOARD})
#=============================================================================
# DriverFramework
#
px4_add_git_submodule(TARGET git_driverframework PATH "src/lib/DriverFramework")
# List the DriverFramework drivers
if (DEFINED config_df_driver_list)
message("DF Drivers: ${config_df_driver_list}")
endif()
set(df_driver_libs)
foreach(driver ${config_df_driver_list})
add_subdirectory(src/lib/DriverFramework/drivers/${driver})
list(APPEND df_driver_libs df_${driver})
message("Adding DF driver: ${driver}")
endforeach()
#=============================================================================
# external projects
#
set(ep_base ${CMAKE_BINARY_DIR}/external)
set(ep_base ${PX4_BINARY_DIR}/external)
set_property(DIRECTORY PROPERTY EP_BASE ${ep_base})
# add external project install folders to build
@@ -321,62 +381,87 @@ execute_process(COMMAND cmake -E make_directory ${ep_base}/Install/lib)
execute_process(COMMAND cmake -E make_directory ${ep_base}/Install/include)
#=============================================================================
# DriverFramework Drivers
# external modules
#
set(df_driver_libs)
foreach(driver ${config_df_driver_list})
add_subdirectory(src/lib/DriverFramework/drivers/${driver})
list(APPEND df_driver_libs df_${driver})
message("Adding DF driver: ${driver}")
endforeach()
set(external_module_paths)
if (NOT EXTERNAL_MODULES_LOCATION STREQUAL "")
message(STATUS "External modules: ${EXTERNAL_MODULES_LOCATION}")
add_subdirectory("${EXTERNAL_MODULES_LOCATION}/src" external_modules)
foreach(external_module ${config_module_list_external})
add_subdirectory(${EXTERNAL_MODULES_LOCATION}/src/${external_module} external_modules/${external_module})
list(APPEND external_module_paths ${EXTERNAL_MODULES_LOCATION}/src/${external_module})
endforeach()
endif()
#=============================================================================
# subdirectories
#
set(module_libraries)
foreach(module ${config_module_list})
string(REGEX MATCH "^[./]" external_module ${module})
if(external_module)
STRING(REGEX REPLACE "//" "/" EXT_MODULE ${module})
STRING(REGEX REPLACE "/" "__" EXT_MODULE_PREFIX ${EXT_MODULE})
add_subdirectory(${module} ${CMAKE_BINARY_DIR}/${EXT_MODULE_PREFIX})
else()
add_subdirectory(src/${module})
endif()
px4_mangle_name(${module} mangled_name)
list(APPEND module_libraries ${mangled_name})
#message(STATUS "adding module: ${module}")
add_subdirectory(src/${module})
endforeach()
# Keep track of external shared libs required for modules
set(module_external_libraries "${module_external_libraries}" CACHE INTERNAL "module_external_libraries")
add_subdirectory(src/firmware/${OS})
#add_dependencies(df_driver_framework nuttx_export_${CONFIG}.stamp)
if (NOT "${OS}" STREQUAL "nuttx")
endif()
if (config_io_board)
add_subdirectory(src/modules/px4iofirmware)
endif()
add_subdirectory(platforms/${OS})
#=============================================================================
# generate git version
# generate custom target to print for all executable and module cmake targets
#
px4_create_git_hash_header(HEADER ${CMAKE_BINARY_DIR}/build_git_version.h)
if (all_posix_cmake_targets)
list(SORT all_posix_cmake_targets)
px4_join(OUT posix_cmake_target_list LIST ${all_posix_cmake_targets} GLUE "\\n")
add_custom_target(list_cmake_targets
COMMAND sh -c "printf \"${posix_cmake_target_list}\\n\""
COMMENT "List of cmake targets that can be matched by PX4_NO_OPTIMIZATION:"
VERBATIM
)
endif()
#=============================================================================
# uORB graph generation: add a custom target 'uorb_graph'
#
set(uorb_graph_config ${BOARD})
set(graph_module_list "")
foreach(module ${config_module_list})
set(graph_module_list "${graph_module_list}" "--src-path" "src/${module}")
endforeach()
add_custom_command(OUTPUT ${uorb_graph_config}
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/uorb_graph/create.py
${module_list}
--exclude-path src/examples
--file ${PX4_SOURCE_DIR}/Tools/uorb_graph/graph_${uorb_graph_config}
WORKING_DIRECTORY ${PX4_SOURCE_DIR}
COMMENT "Generating uORB graph"
)
add_custom_target(uorb_graph DEPENDS ${uorb_graph_config})
#=============================================================================
# packaging
#
# Important to having packaging at end of cmake file.
#
set(CPACK_PACKAGE_VERSION ${version})
set(CPACK_PACKAGE_CONTACT ${package_contact})
set(CPACK_PACKAGE_NAME ${PROJECT_NAME}-${CONFIG})
set(CPACK_PACKAGE_VERSION ${git_version})
set(CPACK_PACKAGE_CONTACT ${package-contact})
set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS ON)
set(CPACK_DEBIAN_PACKAGE_SECTION "devel")
set(CPACK_DEBIAN_PACKAGE_PRIORITY "optional")
set(short-description "The px4 autopilot.")
set(CPACK_DEBIAN_PACKAGE_DESCRIPTION ${short-description})
set(CPACK_GENERATOR "ZIP")
set(CPACK_SOURCE_GENERATOR "ZIP")
set(CPACK_PACKAGE_FILE_NAME "${PROJECT_NAME}-${CONFIG}-${git_tag}")
set(CPACK_SOURCE_PACKAGE_FILE_NAME "${PROJECT_NAME}-${git_version}")
set(CPACK_SOURCE_GENERATOR "ZIP;TBZ2")
set(CPACK_PACKAGING_INSTALL_PREFIX "")
set(CPACK_SET_DESTDIR "OFF")
if ("${CMAKE_SYSTEM}" MATCHES "Linux")
find_program(DPKG_PROGRAM dpkg)
if (EXISTS ${DPKG_PROGRAM})
list (APPEND CPACK_GENERATOR "DEB")
endif()
endif()
include(CPack)
endif() # ros alternative endif
# vim: set noet fenc=utf-8 ff=unix ft=cmake :
+46
View File
@@ -0,0 +1,46 @@
# Contributor Covenant Code of Conduct
## Our Pledge
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.
## Our Standards
Examples of behavior that contributes to creating a positive environment include:
* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members
Examples of unacceptable behavior by participants include:
* The use of sexualized language or imagery and unwelcome sexual attention or advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a professional setting
## Our Responsibilities
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
## Scope
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
## Enforcement
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at lorenz@px4.io. The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
## Attribution
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]
[homepage]: http://contributor-covenant.org
[version]: http://contributor-covenant.org/version/1/4/
+15
View File
@@ -0,0 +1,15 @@
## This file should be placed in the root directory of your project.
## Then modify the CMakeLists.txt file in the root directory of your
## project to incorporate the testing dashboard.
##
## # The following are required to submit to the CDash dashboard:
## ENABLE_TESTING()
## INCLUDE(CTest)
set(CTEST_PROJECT_NAME "PX4 Firmware")
set(CTEST_NIGHTLY_START_TIME "00:00:00 EST")
set(CTEST_DROP_METHOD "http")
set(CTEST_DROP_SITE "my.cdash.org")
set(CTEST_DROP_LOCATION "/submit.php?project=PX4+Firmware")
set(CTEST_DROP_SITE_CDASH TRUE)
-5
View File
@@ -1,5 +0,0 @@
#!/bin/bash
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
openocd -f interface/olimex-arm-usb-ocd-h.cfg -f $DIR/px4fmu-v1-board.cfg
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

File diff suppressed because it is too large Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.

Before

Width:  |  Height:  |  Size: 92 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 79 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 74 KiB

-98
View File
@@ -1,98 +0,0 @@
[TOC]
# Introduction
The HIL architecture allows you to test the flight stack replacing the real physical vehicle and sensors with a simulator of vehicle dynamics and sensor outputs. The flight stack "is not aware" that it is not on a real vehicle. This is a powerful tool for develping and testing code rapidly in a benchtop environment.
The flight stack can be run anywhere that supports a network connection to the simulator (with sufficient bandwidth and latency to transport the sensor and actuator messages). This can be on a standard linux workstation, an on-target linux image, or the on-target DSP image. These modes can be selected based on the goals of the testing. Workstation is useful for rapid testing in a tool-rich environment. DSP image testing is the closest to the final implementation, so is useful for testing actual HW operation, other than the physical sensing and actuation.
## Px4 High-level HIL Architecture
A diagram of the setup described is shown here. Note that UDP port numbers are only displayed on the socket server and are left blank on the socket client.
(???NOTES: This diagram needs to be updated to use control inputs over UDP, either from QGC or from other)
![SITL Diagram](./SITL_Diagram_QGC.png "SITL Diagram")
## Requirements
The simulator that is currently supported is jMAVSim. The setup described here requires PX4 and jMAVSim installed and running. qGroundControl (QGC) is also required because it is the supported method of providing manual control commands.
## Assumptions
# Compiling Code
## JMAVSim
### Platform Requirements
Linux with java-1.7.x or greater
### Build Instructions
In a clean directory
```
> git clone https://github.com/PX4/jMAVSim.git
> cd jMAVSim
> git submodule init
> git submodule update
> ant
```
## qGroundControl
### Platform Requirements
Windows 7
Logitech Gamepad F310 joystick controller
### Download/Install Instructions
Download QGC from http://qgroundcontrol.org/downloads and install using the windows executable.
## PX4
### Platform Requirements
Linux or Eagle with a working IP interface (?? does this need further instructions?)
### Build Host Requirements
(???Notes: Windows?)
### Download & Build Instructions
### Installing binaries on the Qualcomm Target
# Running PX4 in HIL Mode
## Starting PX4 on Qualcomm Eagle
```
> adb shell
# bash
root@linaro-developer:/# cd ???
root@linaro-developer:/# ./mainapp
App name: mainapp
Enter a command and its args:
uorb start
muorb start
mavlink start -u 14556
simulator start -p
```
## Starting jMAVSim
In the directory where jMAVSim is installed
```
java -cp lib/*:out/production/jmavsim.jar me.drton.jmavsim.Simulator -udp <IPADDR>:14560 -n 100
```
replacing <IPADDR> with the IP address of the machine running PX4 (Eagle). This can be found by running "ifconfig" on that machine.
## Starting qGroundControl
Launch the qGroundControl application
1. Set up the communication to the flight stack. In the menu File:Settings:CommLinks, select Add. Enter a Link Name of your choice. Select Link Type: UDP. Set the listening port to an unused port (example: 14561). Select Add. Enter the IP address and port of the PX4 Mavlink app, which is <IPADDR>:14556 with <IPADDR> being the IP address of the Eagle board. Select OK.
1. Set up the joystick. Plug in the joystick to your Windows machine. In the menu File:Settings:CommLinks, check Enable Controllers. Select "Gamepad F310". Select "Manual". Set the axes/channel mapping to 0:Yaw, 1:Throttle, 2:unset, 3:Pitch, 4:Roll. Seletct "Inverted" for the throttle axis. Click "Calibrate range". Move the right joystick through its full range of motion. Move the left joystick full left then full right. Move the left joystick full forward (but not full backward). Click "end calibration."
1. Connect to the flight stack. Click Analyze. Click the "Connect" button in the upper right, and select the connection that you created in the first step.
You should now be connected to the flight stack. You can see incoming Mavlink packets using the MAVLink Instpector (from Advanced:Tool Widgets)
## Controlling PX4 flight in HIL Mode
The joystick can now be used to fly the simulated vehicle. The jMAVSim world visualization gives a FPV view, and QGC can be used to display instruments such as artificial horizon and maps (if GPS simulation is enabled).
# Debugging/FAQ
File diff suppressed because it is too large Load Diff
Binary file not shown.
Binary file not shown.
-2
View File
@@ -1,2 +0,0 @@
#!/bin/sh
git log --pretty=format:"Last change: commit %h - %aN, %ar : %s" -1 $1 || echo no git
+4 -3
View File
@@ -25,7 +25,8 @@
[
".settings",
"nuttx/arch/arm/src/board",
"nuttx/arch/arm/src/chip"
"nuttx/arch/arm/src/chip",
"build_*"
]
}
],
@@ -39,12 +40,12 @@
"options_c":
{
"use_only_additional_options": true,
"additional_options_file": "${project_path}/Tools/astylerc"
"additional_options_file": "${project_path}/Tools/astyle/astylerc"
},
"options_c++":
{
"use_only_additional_options": true,
"additional_options_file": "${project_path}/Tools/astylerc"
"additional_options_file": "${project_path}/Tools/astyle/astylerc"
}
}
},
-12
View File
@@ -1,12 +0,0 @@
{
"board_id": 19,
"magic": "AeroCore",
"description": "Firmware for the Gumstix AeroCore board",
"image": "",
"build_time": 0,
"summary": "AEROCORE",
"version": "0.1",
"image_size": 0,
"git_identity": "",
"board_revision": 0
}
-12
View File
@@ -1,12 +0,0 @@
{
"board_id": 5,
"magic": "PX4FWv1",
"description": "Firmware for the PX4FMU board",
"image": "",
"build_time": 0,
"summary": "PX4FMU",
"version": "0.1",
"image_size": 0,
"git_identity": "",
"board_revision": 0
}
-12
View File
@@ -1,12 +0,0 @@
{
"board_id": 7,
"magic": "PX4FWv1",
"description": "Firmware for the PX4IO board",
"image": "",
"build_time": 0,
"summary": "PX4IO",
"version": "0.1",
"image_size": 0,
"git_identity": "",
"board_revision": 0
}
-12
View File
@@ -1,12 +0,0 @@
{
"board_id": 10,
"magic": "PX4FWv2",
"description": "Firmware for the PX4IOv2 board",
"image": "",
"build_time": 0,
"summary": "PX4IOv2",
"version": "2.0",
"image_size": 0,
"git_identity": "",
"board_revision": 0
}
Vendored
+663
View File
@@ -0,0 +1,663 @@
pipeline {
agent none
stages {
stage('Build') {
steps {
script {
def builds = [:]
// nuttx default targets that are archived and uploaded to s3
for (def option in ["px4fmu-v4", "px4fmu-v4pro", "px4fmu-v5", "aerofc-v1"]) {
def node_name = "${option}"
builds["${node_name}"] = {
node {
stage("Build Test ${node_name}") {
docker.image('px4io/px4-dev-nuttx:2017-10-23').inside('-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw') {
stage("${node_name}") {
checkout scm
sh "make clean"
sh "ccache -z"
sh "git fetch --tags"
sh "make nuttx_${node_name}_default"
sh "make nuttx_${node_name}_rtps"
sh "make sizes"
sh "ccache -s"
archiveArtifacts(artifacts: 'build/*/*.px4', fingerprint: true)
}
}
}
}
}
}
// special case for fmu-v2/fmu-v3
builds["px4fmu-v2"] = {
node {
stage("Build Test ${node_name}") {
docker.image('px4io/px4-dev-nuttx:2017-10-23').inside('-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw') {
stage("${node_name}") {
checkout scm
sh "make clean"
sh "ccache -z"
sh "git fetch --tags"
sh "make px4io-v2_default"
sh "make nuttx_px4fmu-v2_default"
sh "make nuttx_px4fmu-v2_lpe"
sh "make nuttx_px4fmu-v3_default"
sh "make nuttx_px4fmu-v3_rtps"
sh "make sizes"
sh "ccache -s"
archiveArtifacts(artifacts: 'build/*/*.px4', fingerprint: true)
}
}
}
}
}
// nuttx default targets that are archived and uploaded to s3
for (def option in ["aerocore2", "auav-x21", "crazyflie", "mindpx-v2", "nxphlite-v3", "tap-v1"]) {
def node_name = "${option}"
builds["${node_name}"] = {
node {
stage("Build Test ${node_name}") {
docker.image('px4io/px4-dev-nuttx:2017-10-23').inside('-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw') {
stage("${node_name}") {
checkout scm
sh "make clean"
sh "ccache -z"
sh "git fetch --tags"
sh "make nuttx_${node_name}_default"
sh "make sizes"
sh "ccache -s"
archiveArtifacts(artifacts: 'build/*/*.px4', fingerprint: true)
}
}
}
}
}
}
// other nuttx default targets
for (def option in ["px4-same70xplained-v1", "px4-stm32f4discovery", "px4cannode-v1", "px4esc-v1", "px4nucleoF767ZI-v1", "s2740vc-v1"]) {
def node_name = "${option}"
builds["${node_name}"] = {
node {
stage("Build Test ${node_name}") {
docker.image('px4io/px4-dev-nuttx:2017-10-23').inside('-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw') {
stage("${node_name}") {
checkout scm
sh "make clean"
sh "ccache -z"
sh "make nuttx_${node_name}_default"
sh "make sizes"
sh "ccache -s"
}
}
}
}
}
}
// posix_sitl
for (def option in ["sitl_default", "sitl_rtps"]) {
def node_name = "${option}"
builds["${node_name}"] = {
node {
stage("Build Test ${node_name}") {
docker.image('px4io/px4-dev-base:2017-12-30').inside('-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw') {
stage("${node_name}") {
checkout scm
sh "make clean"
sh "ccache -z"
sh "make posix_${node_name}"
sh "ccache -s"
}
}
}
}
}
}
// raspberry pi and bebop (armhf)
for (def option in ["rpi_cross", "bebop_default"]) {
def node_name = "${option}"
builds["${node_name}"] = {
node {
stage("Build Test ${node_name}") {
docker.image('px4io/px4-dev-raspi:2017-12-30').inside('-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw') {
stage("${node_name}") {
checkout scm
sh "make clean"
sh "ccache -z"
sh "make posix_${node_name}"
sh "ccache -s"
}
}
}
}
}
}
// other armhf (to be merged with raspi and bebop)
for (def option in ["ocpoc_ubuntu"]) {
def node_name = "${option}"
builds["${node_name}"] = {
node {
stage("Build Test ${node_name}") {
docker.image('px4io/px4-dev-armhf:2017-12-30').inside('-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw') {
stage("${node_name}") {
checkout scm
sh "make clean"
sh "ccache -z"
sh "make posix_${node_name}"
sh "ccache -s"
}
}
}
}
}
}
// snapdragon eagle (posix + qurt)
for (def option in ["eagle_default"]) {
def node_name = "${option}"
builds["${node_name}"] = {
node {
stage("Build Test ${node_name}") {
docker.withRegistry('https://registry.hub.docker.com', 'docker_hub_dagar') {
docker.image("lorenzmeier/px4-dev-snapdragon:2017-12-29").inside('-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw') {
stage("${node_name}") {
checkout scm
sh "make clean"
sh "ccache -z"
sh "make ${node_name}"
sh "ccache -s"
}
}
}
}
}
}
}
// GCC7 posix
for (def option in ["sitl_default"]) {
def node_name = "${option}"
builds["${node_name} (GCC7)"] = {
node {
stage("Build Test ${node_name} (GCC7)") {
docker.image('px4io/px4-dev-base-archlinux:2017-12-30').inside('-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw') {
stage("${node_name}") {
checkout scm
sh "make clean"
sh "ccache -z"
sh "make posix_${node_name}"
sh "ccache -s"
}
}
}
}
}
}
// GCC7 nuttx
for (def option in ["px4fmu-v5_default"]) {
def node_name = "${option}"
builds["${node_name} (GCC7)"] = {
node {
stage("Build Test ${node_name} (GCC7)") {
docker.image('px4io/px4-dev-base-archlinux:2017-12-08').inside('-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw') {
stage("${node_name}") {
checkout scm
sh "make clean"
sh "ccache -z"
sh "make nuttx_${node_name}"
sh "ccache -s"
}
}
}
}
}
}
parallel builds
}
}
}
stage('Test') {
parallel {
stage('check style') {
agent {
docker {
image 'px4io/px4-dev-base:2017-12-30'
args '-e CI=true'
}
}
steps {
sh 'make check_format'
}
}
stage('clang analyzer') {
agent {
docker {
image 'px4io/px4-dev-clang:2017-12-30'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw'
}
}
steps {
sh 'make clean'
sh 'make scan-build'
// publish html
publishHTML target: [
reportTitles: 'clang static analyzer',
allowMissing: false,
alwaysLinkToLastBuild: true,
keepAll: true,
reportDir: 'build/scan-build/report_latest',
reportFiles: '*',
reportName: 'Clang Static Analyzer'
]
}
when {
anyOf {
branch 'master'
branch 'beta'
branch 'stable'
}
}
}
stage('clang tidy') {
agent {
docker {
image 'px4io/px4-dev-clang:2017-12-30'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw'
}
}
steps {
sh 'make clean'
sh 'make clang-tidy-quiet'
}
}
stage('cppcheck') {
agent {
docker {
image 'px4io/px4-dev-base:ubuntu17.10'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw'
}
}
steps {
sh 'make clean'
sh 'make cppcheck'
// publish html
publishHTML target: [
reportTitles: 'Cppcheck',
allowMissing: false,
alwaysLinkToLastBuild: true,
keepAll: true,
reportDir: 'build/cppcheck/',
reportFiles: '*',
reportName: 'Cppcheck'
]
}
when {
anyOf {
branch 'master'
branch 'beta'
branch 'stable'
}
}
}
stage('tests') {
agent {
docker {
image 'px4io/px4-dev-base:2017-12-30'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw'
}
}
steps {
sh 'make clean'
sh 'make posix_sitl_default test_results_junit'
junit 'build/posix_sitl_default/JUnitTestResults.xml'
}
}
stage('ROS vtol mission new 1') {
agent {
docker {
image 'px4io/px4-dev-ros:2017-12-31'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'make clean; rm -rf .ros; rm -rf .gazebo'
sh 'git fetch --tags'
sh 'make posix_sitl_default'
sh 'make posix_sitl_default sitl_gazebo'
sh './test/rostest_px4_run.sh mavros_posix_test_mission.test mission:=vtol_new_1.txt vehicle:=vtol_standard'
}
post {
success {
sh './Tools/upload_log.py -q --description "ROS mission test vtol_new_1.txt: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI .ros/rootfs/fs/microsd/log/*/*.ulg'
}
failure {
sh './Tools/upload_log.py -q --description "ROS mission test vtol_new_1.txt: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI --email "${CHANGE_AUTHOR_EMAIL}" .ros/rootfs/fs/microsd/log/*/*.ulg'
archiveArtifacts '**/*.ulg'
archiveArtifacts '.ros/*/px4/**.xml'
archiveArtifacts '.ros/log/**.log'
}
}
}
stage('ROS vtol mission new 2') {
agent {
docker {
image 'px4io/px4-dev-ros:2017-12-31'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'make clean; rm -rf .ros; rm -rf .gazebo'
sh 'git fetch --tags'
sh 'make posix_sitl_default'
sh 'make posix_sitl_default sitl_gazebo'
sh './test/rostest_px4_run.sh mavros_posix_test_mission.test mission:=vtol_new_2.txt vehicle:=vtol_standard'
}
post {
success {
sh './Tools/upload_log.py -q --description "ROS mission test vtol_new_2.txt: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI .ros/rootfs/fs/microsd/log/*/*.ulg'
}
failure {
sh './Tools/upload_log.py -q --description "ROS mission test vtol_new_2.txt: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI --email "${CHANGE_AUTHOR_EMAIL}" .ros/rootfs/fs/microsd/log/*/*.ulg'
archiveArtifacts '**/*.ulg'
archiveArtifacts '.ros/*/px4/**.xml'
archiveArtifacts '.ros/log/**.log'
}
}
}
stage('ROS vtol mission old 1') {
agent {
docker {
image 'px4io/px4-dev-ros:2017-12-31'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'make clean; rm -rf .ros; rm -rf .gazebo'
sh 'git fetch --tags'
sh 'make posix_sitl_default'
sh 'make posix_sitl_default sitl_gazebo'
sh './test/rostest_px4_run.sh mavros_posix_test_mission.test mission:=vtol_old_1.txt vehicle:=vtol_standard'
}
post {
success {
sh './Tools/upload_log.py -q --description "ROS mission test vtol_old_1.txt: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI .ros/rootfs/fs/microsd/log/*/*.ulg'
}
failure {
sh './Tools/upload_log.py -q --description "ROS mission test vtol_old_1.txt: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI --email "${CHANGE_AUTHOR_EMAIL}" .ros/rootfs/fs/microsd/log/*/*.ulg'
archiveArtifacts '**/*.ulg'
archiveArtifacts '.ros/*/px4/**.xml'
archiveArtifacts '.ros/log/**.log'
}
}
}
stage('ROS vtol mission old 2') {
agent {
docker {
image 'px4io/px4-dev-ros:2017-12-31'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'make clean; rm -rf .ros; rm -rf .gazebo'
sh 'git fetch --tags'
sh 'make posix_sitl_default'
sh 'make posix_sitl_default sitl_gazebo'
sh './test/rostest_px4_run.sh mavros_posix_test_mission.test mission:=vtol_old_2.txt vehicle:=vtol_standard'
}
post {
success {
sh './Tools/upload_log.py -q --description "ROS mission test vtol_old_2.txt: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI .ros/rootfs/fs/microsd/log/*/*.ulg'
}
failure {
sh './Tools/upload_log.py -q --description "ROS mission test vtol_old_2.txt: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI --email "${CHANGE_AUTHOR_EMAIL}" .ros/rootfs/fs/microsd/log/*/*.ulg'
archiveArtifacts '**/*.ulg'
archiveArtifacts '.ros/*/px4/**.xml'
archiveArtifacts '.ros/log/**.log'
}
}
}
stage('ROS vtol mission old 3') {
agent {
docker {
image 'px4io/px4-dev-ros:2017-12-31'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'make clean; rm -rf .ros; rm -rf .gazebo'
sh 'git fetch --tags'
sh 'make posix_sitl_default'
sh 'make posix_sitl_default sitl_gazebo'
sh './test/rostest_px4_run.sh mavros_posix_test_mission.test mission:=vtol_old_3.txt vehicle:=vtol_standard'
}
post {
success {
sh './Tools/upload_log.py -q --description "ROS mission test vtol_old_3.txt: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI .ros/rootfs/fs/microsd/log/*/*.ulg'
}
failure {
sh './Tools/upload_log.py -q --description "ROS mission test vtol_old_3.txt: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI --email "${CHANGE_AUTHOR_EMAIL}" .ros/rootfs/fs/microsd/log/*/*.ulg'
archiveArtifacts '**/*.ulg'
archiveArtifacts '.ros/*/px4/**.xml'
archiveArtifacts '.ros/log/**.log'
}
}
}
stage('ROS MC mission box') {
agent {
docker {
image 'px4io/px4-dev-ros:2017-12-31'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'make clean; rm -rf .ros; rm -rf .gazebo'
sh 'git fetch --tags'
sh 'make posix_sitl_default'
sh 'make posix_sitl_default sitl_gazebo'
sh './test/rostest_px4_run.sh mavros_posix_test_mission.test mission:=multirotor_box.mission vehicle:=iris'
}
post {
success {
sh './Tools/upload_log.py -q --description "ROS mission test multirotor_box.mission: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI .ros/rootfs/fs/microsd/log/*/*.ulg'
}
failure {
sh './Tools/upload_log.py -q --description "ROS mission test multirotor_box.mission: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI --email "${CHANGE_AUTHOR_EMAIL}" .ros/rootfs/fs/microsd/log/*/*.ulg'
archiveArtifacts '**/*.ulg'
archiveArtifacts '.ros/*/px4/**.xml'
archiveArtifacts '.ros/log/**.log'
}
}
}
stage('ROS offboard att') {
agent {
docker {
image 'px4io/px4-dev-ros:2017-12-31'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'make clean; rm -rf .ros; rm -rf .gazebo'
sh 'git fetch --tags'
sh 'make posix_sitl_default'
sh 'make posix_sitl_default sitl_gazebo'
sh './test/rostest_px4_run.sh mavros_posix_tests_offboard_attctl.test'
}
post {
success {
sh './Tools/upload_log.py -q --description "ROS offboard attitude test: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI .ros/rootfs/fs/microsd/log/*/*.ulg'
}
failure {
sh './Tools/upload_log.py -q --description "ROS offboard attitude test: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI --email "${CHANGE_AUTHOR_EMAIL}" .ros/rootfs/fs/microsd/log/*/*.ulg'
archiveArtifacts '**/*.ulg'
archiveArtifacts '.ros/*/px4/**.xml'
archiveArtifacts '.ros/log/**.log'
}
}
}
stage('ROS offboard pos') {
agent {
docker {
image 'px4io/px4-dev-ros:2017-12-31'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'make clean; rm -rf .ros; rm -rf .gazebo'
sh 'git fetch --tags'
sh 'make posix_sitl_default'
sh 'make posix_sitl_default sitl_gazebo'
sh './test/rostest_px4_run.sh mavros_posix_tests_offboard_posctl.test'
}
post {
success {
sh './Tools/upload_log.py -q --description "ROS offboard position test: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI .ros/rootfs/fs/microsd/log/*/*.ulg'
}
failure {
sh './Tools/upload_log.py -q --description "ROS offboard position test: ${CHANGE_ID}" --feedback "${CHANGE_TITLE} - ${CHANGE_URL}" --source CI --email "${CHANGE_AUTHOR_EMAIL}" .ros/rootfs/fs/microsd/log/*/*.ulg'
archiveArtifacts '**/*.ulg'
archiveArtifacts '.ros/*/px4/**.xml'
archiveArtifacts '.ros/log/**.log'
}
}
}
// temporarily disabled until stable
//stage('tests coverage') {
// agent {
// docker {
// image 'px4io/px4-dev-base:2017-12-30'
// args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw'
// }
// }
// steps {
// sh 'make clean'
// sh 'make tests_coverage'
// // publish html
// publishHTML target: [
// allowMissing: false,
// alwaysLinkToLastBuild: false,
// keepAll: true,
// reportDir: 'build/posix_sitl_default/coverage-html',
// reportFiles: '*',
// reportName: 'Coverage Report'
// ]
// }
//}
}
}
stage('Generate Metadata') {
parallel {
stage('airframe') {
agent {
docker { image 'px4io/px4-dev-base:2017-12-30' }
}
steps {
sh 'make airframe_metadata'
archiveArtifacts(artifacts: 'airframes.md, airframes.xml', fingerprint: true)
}
}
stage('parameter') {
agent {
docker { image 'px4io/px4-dev-base:2017-12-30' }
}
steps {
sh 'make parameters_metadata'
archiveArtifacts(artifacts: 'parameters.md, parameters.xml', fingerprint: true)
}
}
stage('module') {
agent {
docker { image 'px4io/px4-dev-base:2017-12-30' }
}
steps {
sh 'make module_documentation'
archiveArtifacts(artifacts: 'modules/*.md', fingerprint: true)
}
}
stage('uorb graphs') {
agent {
docker {
image 'px4io/px4-dev-nuttx:2017-12-30'
args '-e CI=true -e CCACHE_BASEDIR=$WORKSPACE -e CCACHE_DIR=/tmp/ccache -v /tmp/ccache:/tmp/ccache:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'make uorb_graphs'
archiveArtifacts(artifacts: 'Tools/uorb_graph/graph_sitl.json')
}
}
}
}
stage('S3 Upload') {
agent {
docker { image 'px4io/px4-dev-base:2017-12-30' }
}
when {
anyOf {
branch 'master'
branch 'beta'
branch 'stable'
}
}
steps {
sh 'echo "uploading to S3"'
}
}
}
options {
buildDiscarder(logRotator(numToKeepStr: '5'))
timeout(time: 60, unit: 'MINUTES')
}
}
+29
View File
@@ -0,0 +1,29 @@
BSD 3-Clause License
Copyright (c) 2012 - 2017, PX4 Development Team
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
* Neither the name of the copyright holder nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-41
View File
@@ -1,41 +0,0 @@
The PX4 firmware is licensed generally under a permissive 3-clause BSD license. Contributions are required
to be made under the same license. Any exception to this general rule is listed below.
/****************************************************************************
*
* Copyright (c) 2012-2015 PX4 Development Team. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
* 3. Neither the name PX4 nor the names of its contributors may be
* used to endorse or promote products derived from this software
* without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
* COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
* OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
* AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*
****************************************************************************/
- PX4 middleware: BSD 3-clause
- PX4 flight control stack: BSD 3-clause
- NuttX operating system: BSD 3-clause
- Exceptions: Currently only this [400 LOC file](https://github.com/PX4/Firmware/blob/master/src/lib/external_lgpl/tecs/tecs.cpp) remains LGPL, but will be replaced with a BSD implementation.
+278 -198
View File
@@ -1,6 +1,6 @@
############################################################################
#
# Copyright (c) 2015 - 2016 PX4 Development Team. All rights reserved.
# Copyright (c) 2015 - 2017 PX4 Development Team. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
@@ -39,26 +39,6 @@ ifeq ($(wildcard .git),)
$(error YOU HAVE TO USE GIT TO DOWNLOAD THIS REPOSITORY. ABORTING.)
endif
CMAKE_VER := $(shell Tools/check_cmake.sh; echo $$?)
ifneq ($(CMAKE_VER),0)
$(warning Not a valid CMake version or CMake not installed.)
$(warning On Ubuntu, install or upgrade via:)
$(warning )
$(warning 3rd party PPA:)
$(warning sudo add-apt-repository ppa:george-edison55/cmake-3.x -y)
$(warning sudo apt-get update)
$(warning sudo apt-get install cmake)
$(warning )
$(warning Official website:)
$(warning wget https://cmake.org/files/v3.3/cmake-3.3.2-Linux-x86_64.sh)
$(warning chmod +x cmake-3.3.2-Linux-x86_64.sh)
$(warning sudo mkdir /opt/cmake-3.3.2)
$(warning sudo ./cmake-3.3.2-Linux-x86_64.sh --prefix=/opt/cmake-3.3.2 --exclude-subdir)
$(warning export PATH=/opt/cmake-3.3.2/bin:$$PATH)
$(warning )
$(error Fatal)
endif
# Help
# --------------------------------------------------------------------
# Don't be afraid of this makefile, it is just passing
@@ -73,203 +53,181 @@ endif
# make px4fmu-v2_default test (builds and tests)
#
# This tells cmake to build the nuttx px4fmu-v2 default config in the
# directory build_nuttx_px4fmu-v2_default and then call make
# directory build/nuttx_px4fmu-v2_default and then call make
# in that directory with the target upload.
# explicity set default build target
all: px4fmu-v2_default
all: posix_sitl_default
# Parsing
# --------------------------------------------------------------------
# assume 1st argument passed is the main target, the
# rest are arguments to pass to the makefile generated
# by cmake in the subdirectory
FIRST_ARG := $(firstword $(MAKECMDGOALS))
ARGS := $(wordlist 2,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))
j ?= 4
NINJA_BUILD := $(shell ninja --version 2>/dev/null)
ifdef NINJA_BUILD
PX4_CMAKE_GENERATOR ?= "Ninja"
PX4_MAKE = ninja
PX4_MAKE_ARGS =
else
NINJA_BIN := ninja
ifndef NO_NINJA_BUILD
NINJA_BUILD := $(shell $(NINJA_BIN) --version 2>/dev/null)
ifdef SYSTEMROOT
# Windows
PX4_CMAKE_GENERATOR ?= "MSYS Makefiles"
else
PX4_CMAKE_GENERATOR ?= "Unix Makefiles"
ifndef NINJA_BUILD
NINJA_BIN := ninja-build
NINJA_BUILD := $(shell $(NINJA_BIN) --version 2>/dev/null)
endif
endif
PX4_MAKE = make
PX4_MAKE_ARGS = -j$(j) --no-print-directory
ifdef NINJA_BUILD
PX4_CMAKE_GENERATOR := Ninja
PX4_MAKE := $(NINJA_BIN)
ifdef VERBOSE
PX4_MAKE_ARGS := -v
else
PX4_MAKE_ARGS :=
endif
else
ifdef SYSTEMROOT
# Windows
PX4_CMAKE_GENERATOR := "MSYS\ Makefiles"
else
PX4_CMAKE_GENERATOR := "Unix\ Makefiles"
endif
PX4_MAKE = $(MAKE)
PX4_MAKE_ARGS = -j$(j) --no-print-directory
endif
SRC_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
# check if replay env variable is set & set build dir accordingly
ifdef replay
BUILD_DIR_SUFFIX := _replay
else
BUILD_DIR_SUFFIX :=
endif
# additional config parameters passed to cmake
ifdef EXTERNAL_MODULES_LOCATION
CMAKE_ARGS += -DEXTERNAL_MODULES_LOCATION:STRING=$(EXTERNAL_MODULES_LOCATION)
endif
ifdef PX4_CMAKE_BUILD_TYPE
CMAKE_ARGS += -DCMAKE_BUILD_TYPE=${PX4_CMAKE_BUILD_TYPE}
endif
# Functions
# --------------------------------------------------------------------
# describe how to build a cmake config
define cmake-build
+@if [ $(PX4_CMAKE_GENERATOR) = "Ninja" ] && [ -e $(PWD)/build_$@/Makefile ]; then rm -rf $(PWD)/build_$@; fi
+@if [ ! -e $(PWD)/build_$@/CMakeCache.txt ]; then Tools/check_submodules.sh && mkdir -p $(PWD)/build_$@ && cd $(PWD)/build_$@ && cmake .. -G$(PX4_CMAKE_GENERATOR) -DCONFIG=$(1) || (cd .. && rm -rf $(PWD)/build_$@); fi
+@Tools/check_submodules.sh
+@(echo "PX4 CONFIG: $@" && cd $(PWD)/build_$@ && $(PX4_MAKE) $(PX4_MAKE_ARGS) $(ARGS))
+@$(eval BUILD_DIR = $(SRC_DIR)/build/$@$(BUILD_DIR_SUFFIX))
+@if [ $(PX4_CMAKE_GENERATOR) = "Ninja" ] && [ -e $(BUILD_DIR)/Makefile ]; then rm -rf $(BUILD_DIR); fi
+@if [ ! -e $(BUILD_DIR)/CMakeCache.txt ]; then mkdir -p $(BUILD_DIR) && cd $(BUILD_DIR) && cmake $(2) -G"$(PX4_CMAKE_GENERATOR)" $(CMAKE_ARGS) -DCONFIG=$(1) || (rm -rf $(BUILD_DIR)); fi
+@(cd $(BUILD_DIR) && $(PX4_MAKE) $(PX4_MAKE_ARGS) $(ARGS))
endef
define cmake-build-other
+@if [ $(PX4_CMAKE_GENERATOR) = "Ninja" ] && [ -e $(PWD)/build_$@/Makefile ]; then rm -rf $(PWD)/build_$@; fi
+@if [ ! -e $(PWD)/build_$@/CMakeCache.txt ]; then Tools/check_submodules.sh && mkdir -p $(PWD)/build_$@ && cd $(PWD)/build_$@ && cmake $(2) -G$(PX4_CMAKE_GENERATOR) || (cd .. && rm -rf $(PWD)/build_$@); fi
+@(cd $(PWD)/build_$@ && $(PX4_MAKE) $(PX4_MAKE_ARGS) $(ARGS))
endef
# create empty targets to avoid msgs for targets passed to cmake
define cmake-targ
$(1):
@#
.PHONY: $(1)
endef
COLOR_BLUE = \033[0;34m
NO_COLOR = \033[m
define colorecho
@tput setaf 6
@echo $1
@tput sgr0
+@echo "${COLOR_BLUE}${1} ${NO_COLOR}"
endef
# Get a list of all config targets cmake/configs/*.cmake
ALL_CONFIG_TARGETS := $(basename $(shell find "$(SRC_DIR)/cmake/configs" -maxdepth 1 ! -name '*_common*' ! -name '*_sdflight_*' -name '*.cmake' -print | sed -e 's:^.*/::' | sort))
# Strip off leading nuttx_
NUTTX_CONFIG_TARGETS := $(patsubst nuttx_%,%,$(filter nuttx_%,$(ALL_CONFIG_TARGETS)))
# ADD CONFIGS HERE
# --------------------------------------------------------------------
# Do not put any spaces between function arguments.
px4fmu-v1_default:
$(call cmake-build,nuttx_px4fmu-v1_default)
# All targets.
$(ALL_CONFIG_TARGETS):
$(call cmake-build,$@,$(SRC_DIR))
px4fmu-v2_default:
$(call cmake-build,nuttx_px4fmu-v2_default)
px4fmu-v2_test:
$(call cmake-build,nuttx_px4fmu-v2_test)
# Abbreviated config targets.
px4fmu-v4_default:
$(call cmake-build,nuttx_px4fmu-v4_default)
# nuttx_ is left off by default; provide a rule to allow that.
$(NUTTX_CONFIG_TARGETS):
$(call cmake-build,nuttx_$@,$(SRC_DIR))
px4-stm32f4discovery_default:
$(call cmake-build,nuttx_px4-stm32f4discovery_default)
px4fmu-v2_ekf2:
$(call cmake-build,nuttx_px4fmu-v2_ekf2)
mindpx-v2_default:
$(call cmake-build,nuttx_mindpx-v2_default)
posix_sitl_default:
$(call cmake-build,$@)
posix_sitl_test:
$(call cmake-build,$@)
posix_sitl_replay:
$(call cmake-build,$@)
posix_sitl_broadcast:
$(call cmake-build,$@)
ros_sitl_default:
@echo "This target is deprecated. Use make 'posix_sitl_default gazebo' instead."
qurt_eagle_travis:
$(call cmake-build,$@)
qurt_eagle_default:
$(call cmake-build,$@)
posix_eagle_default:
$(call cmake-build,$@)
eagle_default: posix_eagle_default qurt_eagle_default
eagle_legacy_default: posix_eagle_legacy_driver_default qurt_eagle_legacy_driver_default
qurt_eagle_legacy_driver_default:
$(call cmake-build,$@)
posix_eagle_legacy_driver_default:
$(call cmake-build,$@)
qurt_excelsior_default:
$(call cmake-build,$@)
posix_excelsior_default:
$(call cmake-build,$@)
excelsior_default: posix_excelsior_default qurt_excelsior_default
posix_rpi2_default:
$(call cmake-build,$@)
posix_rpi2_release:
$(call cmake-build,$@)
posix_bebop_default:
$(call cmake-build,$@)
all_nuttx_targets: $(NUTTX_CONFIG_TARGETS)
posix: posix_sitl_default
broadcast: posix_sitl_broadcast
sitl_deprecation:
@echo "Deprecated. Use 'make posix_sitl_default jmavsim' or"
@echo "'make posix_sitl_default gazebo' if Gazebo is preferred."
# All targets with just dependencies but no recipe must either be marked as phony (or have the special @: as recipe).
.PHONY: all posix broadcast all_nuttx_targets
run_sitl_quad: sitl_deprecation
run_sitl_plane: sitl_deprecation
run_sitl_ros: sitl_deprecation
# Multi- config targets.
eagle_default: posix_eagle_default qurt_eagle_default
eagle_rtps: posix_eagle_rtps qurt_eagle_default
eagle_legacy_default: posix_eagle_legacy qurt_eagle_legacy
excelsior_default: posix_excelsior_default qurt_excelsior_default
excelsior_rtps: posix_excelsior_rtps qurt_excelsior_default
excelsior_legacy_default: posix_excelsior_legacy qurt_excelsior_legacy
.PHONY: eagle_default eagle_rtps eagle_legacy_default
.PHONY: excelsior_default excelsior_rtps excelsior_legacy_default
# Other targets
# --------------------------------------------------------------------
.PHONY: gazebo_build uavcan_firmware check check_format unittest tests package_firmware clean submodulesclean distclean
.NOTPARALLEL: gazebo_build uavcan_firmware check check_format unittest tests package_firmware clean submodulesclean distclean
.PHONY: qgc_firmware px4fmu_firmware misc_qgc_extra_firmware alt_firmware check_rtps
gazebo_build:
@mkdir -p build_gazebo
@if [ ! -e $(PWD)/build_gazebo/CMakeCache.txt ];then cd build_gazebo && cmake -Wno-dev -G$(PX4_CMAKE_GENERATOR) $(PWD)/Tools/sitl_gazebo; fi
@cd build_gazebo && $(PX4_MAKE) $(PX4_MAKE_ARGS)
@cd build_gazebo && $(PX4_MAKE) $(PX4_MAKE_ARGS) sdf
# QGroundControl flashable NuttX firmware
qgc_firmware: px4fmu_firmware misc_qgc_extra_firmware
uavcan_firmware:
ifeq ($(VECTORCONTROL),1)
$(call colorecho,"Downloading and building Vector control (FOC) firmware for the S2740VC and PX4ESC 1.6")
@(rm -rf vectorcontrol && git clone --quiet --depth 1 https://github.com/thiemar/vectorcontrol.git && cd vectorcontrol && BOARD=s2740vc_1_0 make --silent --no-print-directory && BOARD=px4esc_1_6 make --silent --no-print-directory && ../Tools/uavcan_copy.sh)
endif
checks_defaults: \
check_px4fmu-v1_default \
# px4fmu NuttX firmware
px4fmu_firmware: \
check_px4io-v2_default \
check_px4fmu-v2_default \
check_px4fmu-v3_default \
check_px4fmu-v4_default \
check_px4fmu-v4pro_default \
check_px4fmu-v5_default \
sizes
misc_qgc_extra_firmware: \
check_aerocore2_default \
check_aerofc-v1_default \
check_auav-x21_default \
check_crazyflie_default \
check_mindpx-v2_default \
check_px4fmu-v2_lpe \
check_tap-v1_default \
sizes
# Other NuttX firmware
alt_firmware: \
check_nxphlite-v3_default \
check_px4-same70xplained-v1_default \
check_px4-stm32f4discovery_default \
check_px4cannode-v1_default \
check_px4esc-v1_default \
check_px4nucleoF767ZI-v1_default \
check_s2740vc-v1_default \
sizes
checks_bootloaders: \
# builds with RTPS
check_rtps: \
check_px4fmu-v3_rtps \
check_px4fmu-v4_rtps \
check_px4fmu-v4pro_rtps \
check_posix_sitl_rtps \
sizes
.PHONY: sizes check quick_check check_rtps uorb_graphs
checks_tests: \
check_px4fmu-v2_test
sizes:
@-find build -name *.elf -type f | xargs size 2> /dev/null || :
checks_alts: \
check_px4fmu-v2_ekf2 \
# All default targets that don't require a special build environment
check: check_posix_sitl_default px4fmu_firmware misc_qgc_extra_firmware alt_firmware tests check_format
checks_uavcan: \
check_px4fmu-v4_default_and_uavcan
checks_sitls: \
check_posix_sitl_default \
check_posix_sitl_test \
checks_last: \
check_unittest \
check_format \
check: checks_defaults checks_tests checks_alts checks_uavcan checks_bootloaders checks_sitls checks_last
check_format:
$(call colorecho,"Checking formatting with astyle")
@./Tools/fix_code_style.sh
@./Tools/check_code_style_all.sh
# quick_check builds a single nuttx and posix target, runs testing, and checks the style
quick_check: check_posix_sitl_default check_px4fmu-v4pro_default tests check_format
check_%:
@echo
@@ -277,53 +235,175 @@ check_%:
@$(MAKE) --no-print-directory $(subst check_,,$@)
@echo
check_px4fmu-v4_default: uavcan_firmware
check_px4fmu-v4_default_and_uavcan: check_px4fmu-v4_default
@echo
ifeq ($(VECTORCONTROL),1)
@echo "Cleaning up vectorcontrol firmware"
@rm -rf vectorcontrol
@rm -rf ROMFS/px4fmu_common/uavcan
endif
uorb_graphs:
@./Tools/uorb_graph/create_from_startupscript.sh
@./Tools/uorb_graph/create.py --src-path src --exclude-path src/examples --file Tools/uorb_graph/graph_full
@$(MAKE) --no-print-directory px4fmu-v2_default uorb_graph
@$(MAKE) --no-print-directory px4fmu-v4_default uorb_graph
@$(MAKE) --no-print-directory posix_sitl_default uorb_graph
unittest: posix_sitl_test
@export CC=clang
@export CXX=clang++
@export ASAN_OPTIONS=symbolize=1
$(call cmake-build-other,unittest, ../unittests)
@(cd build_unittest && ctest -j2 --output-on-failure)
test_onboard_sitl:
@HEADLESS=1 make posix_sitl_test gazebo_iris
package_firmware:
@zip --junk-paths Firmware.zip `find . -name \*.px4`
.PHONY: coverity_scan
coverity_scan: posix_sitl_default
# Documentation
# --------------------------------------------------------------------
.PHONY: parameters_metadata airframe_metadata module_documentation px4_metadata
parameters_metadata:
@python $(SRC_DIR)/src/modules/systemlib/param/px_process_params.py -s `find $(SRC_DIR)/src -maxdepth 3 -type d` --inject-xml $(SRC_DIR)/src/modules/systemlib/param/parameters_injected.xml --markdown
@python $(SRC_DIR)/src/modules/systemlib/param/px_process_params.py -s `find $(SRC_DIR)/src -maxdepth 3 -type d` --inject-xml $(SRC_DIR)/src/modules/systemlib/param/parameters_injected.xml --xml
airframe_metadata:
@python $(SRC_DIR)/Tools/px_process_airframes.py -v -a $(SRC_DIR)/ROMFS/px4fmu_common/init.d --markdown
@python $(SRC_DIR)/Tools/px_process_airframes.py -v -a $(SRC_DIR)/ROMFS/px4fmu_common/init.d --xml
module_documentation:
@python $(SRC_DIR)/Tools/px_process_module_doc.py -v --markdown $(SRC_DIR)/modules --src-path $(SRC_DIR)/src
px4_metadata: parameters_metadata airframe_metadata module_documentation
# Astyle
# --------------------------------------------------------------------
.PHONY: check_format format
check_format:
$(call colorecho,"Checking formatting with astyle")
@$(SRC_DIR)/Tools/astyle/check_code_style_all.sh
@cd $(SRC_DIR) && git diff --check
format:
$(call colorecho,"Formatting with astyle")
@$(SRC_DIR)/Tools/astyle/check_code_style_all.sh --fix
# Testing
# --------------------------------------------------------------------
.PHONY: tests tests_coverage tests_mission tests_offboard rostest
tests:
@$(MAKE) --no-print-directory posix_sitl_default test_results \
ASAN_OPTIONS="color=always:check_initialization_order=1:detect_stack_use_after_return=1" \
UBSAN_OPTIONS="color=always"
tests_coverage:
@$(MAKE) clean
@$(MAKE) --no-print-directory posix_sitl_default PX4_CMAKE_BUILD_TYPE=Coverage
@$(MAKE) --no-print-directory posix_sitl_default sitl_gazebo PX4_CMAKE_BUILD_TYPE=Coverage
@$(SRC_DIR)/test/rostest_px4_run.sh mavros_posix_tests_missions.test
@$(SRC_DIR)/test/rostest_px4_run.sh mavros_posix_tests_offboard_attctl.test
@$(SRC_DIR)/test/rostest_px4_run.sh mavros_posix_tests_offboard_posctl.test
@$(MAKE) --no-print-directory posix_sitl_default test_coverage_genhtml PX4_CMAKE_BUILD_TYPE=Coverage
@echo "Open $(SRC_DIR)/build/posix_sitl_default/coverage-html/index.html to see coverage"
rostest: posix_sitl_default
@$(MAKE) --no-print-directory posix_sitl_default sitl_gazebo
tests_mission: rostest
@$(SRC_DIR)/test/rostest_px4_run.sh mavros_posix_tests_missions.test
tests_offboard: rostest
@$(SRC_DIR)/test/rostest_px4_run.sh mavros_posix_tests_offboard_attctl.test
@$(SRC_DIR)/test/rostest_px4_run.sh mavros_posix_tests_offboard_posctl.test
# static analyzers (scan-build, clang-tidy, cppcheck)
# --------------------------------------------------------------------
.PHONY: scan-build posix_sitl_default-clang clang-tidy clang-tidy-fix clang-tidy-quiet cppcheck check_stack
scan-build:
@export CCC_CC=clang
@export CCC_CXX=clang++
@rm -rf $(SRC_DIR)/build/posix_sitl_default-scan-build
@rm -rf $(SRC_DIR)/build/scan-build/report_latest
@mkdir -p $(SRC_DIR)/build/posix_sitl_default-scan-build
@cd $(SRC_DIR)/build/posix_sitl_default-scan-build && scan-build cmake $(SRC_DIR) -GNinja -DCONFIG=posix_sitl_default
@scan-build -o $(SRC_DIR)/build/scan-build cmake --build $(SRC_DIR)/build/posix_sitl_default-scan-build
@find $(SRC_DIR)/build/scan-build -maxdepth 1 -mindepth 1 -type d -exec cp -r "{}" $(SRC_DIR)/build/scan-build/report_latest \;
posix_sitl_default-clang:
@mkdir -p $(SRC_DIR)/build/posix_sitl_default-clang
@cd $(SRC_DIR)/build/posix_sitl_default-clang && cmake $(SRC_DIR) $(CMAKE_ARGS) -G"$(PX4_CMAKE_GENERATOR)" -DCONFIG=posix_sitl_default -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++
@$(PX4_MAKE) -C $(SRC_DIR)/build/posix_sitl_default-clang
clang-tidy: posix_sitl_default-clang
@cd $(SRC_DIR)/build/posix_sitl_default-clang && run-clang-tidy-4.0.py -header-filter=".*\.hpp" -j$(j) -p .
# to automatically fix a single check at a time, eg modernize-redundant-void-arg
# % run-clang-tidy-4.0.py -fix -j4 -checks=-\*,modernize-redundant-void-arg -p .
clang-tidy-fix: posix_sitl_default-clang
@cd $(SRC_DIR)/build/posix_sitl_default-clang && run-clang-tidy-4.0.py -header-filter=".*\.hpp" -j$(j) -fix -p .
# modified version of run-clang-tidy.py to return error codes and only output relevant results
clang-tidy-quiet: posix_sitl_default-clang
@cd $(SRC_DIR)/build/posix_sitl_default-clang && $(SRC_DIR)/Tools/run-clang-tidy.py -header-filter=".*\.hpp" -j$(j) -p .
# TODO: Fix cppcheck errors then try --enable=warning,performance,portability,style,unusedFunction or --enable=all
cppcheck: posix_sitl_default
@mkdir -p $(SRC_DIR)/build/cppcheck
@cppcheck -i$(SRC_DIR)/src/examples --enable=performance --std=c++11 --std=c99 --std=posix --project=$(SRC_DIR)/build/posix_sitl_default/compile_commands.json --xml-version=2 2> $(SRC_DIR)/build/cppcheck/cppcheck-result.xml > /dev/null
@cppcheck-htmlreport --source-encoding=ascii --file=$(SRC_DIR)/build/cppcheck/cppcheck-result.xml --report-dir=$(SRC_DIR)/build/cppcheck --source-dir=$(SRC_DIR)/src/
check_stack: px4fmu-v4pro_default
@echo "Checking worst case stack usage with checkstack.pl ..."
@echo " "
@echo "Top 10:"
@cd $(SRC_DIR)/build/px4fmu-v4pro_default && mkdir -p stack_usage && arm-none-eabi-objdump -d nuttx_px4fmu-v4pro_default.elf | $(SRC_DIR)/Tools/stack_usage/checkstack.pl arm 0 > stack_usage/checkstack_output.txt 2> stack_usage/checkstack_errors.txt
@head -n 10 $(SRC_DIR)/build/px4fmu-v4pro_default/stack_usage/checkstack_output.txt | c++filt
@echo " "
@echo "Symbols with 'main', 'thread' or 'task':"
@cat $(SRC_DIR)/build/px4fmu-v4pro_default/stack_usage/checkstack_output.txt | c++filt | grep -E 'thread|main|task'
# Cleanup
# --------------------------------------------------------------------
.PHONY: clean submodulesclean submodulesupdate gazeboclean distclean
clean:
@rm -rf build_*/
@(cd NuttX/nuttx && make clean)
@rm -rf $(SRC_DIR)/build
submodulesclean:
@git submodule foreach --quiet --recursive git clean -ff -x -d
@git submodule update --quiet --init --recursive --force || true
@git submodule sync --recursive
@git submodule deinit -f .
@git submodule update --init --recursive --force
distclean: submodulesclean
@git clean -ff -x -d -e ".project" -e ".cproject"
submodulesupdate:
@git submodule update --quiet --init --recursive || true
@git submodule sync --recursive
@git submodule update --init --recursive
# targets handled by cmake
cmake_targets = test upload package package_source debug debug_tui debug_ddd debug_io debug_io_tui debug_io_ddd check_weak \
run_cmake_config config gazebo gazebo_gdb gazebo_lldb jmavsim replay \
jmavsim_gdb jmavsim_lldb gazebo_gdb_iris gazebo_lldb_tailsitter gazebo_iris gazebo_iris_opt_flow gazebo_tailsitter \
gazebo_gdb_standard_vtol gazebo_lldb_standard_vtol gazebo_standard_vtol gazebo_plane gazebo_solo
$(foreach targ,$(cmake_targets),$(eval $(call cmake-targ,$(targ))))
gazeboclean:
@rm -rf ~/.gazebo/*
.PHONY: clean
distclean: submodulesclean gazeboclean
@git clean -ff -x -d -e ".project" -e ".cproject" -e ".idea" -e ".settings" -e ".vscode"
CONFIGS:=$(shell ls cmake/configs | sed -e "s~.*/~~" | sed -e "s~\..*~~")
# --------------------------------------------------------------------
# All other targets are handled by PX4_MAKE. Add a rule here to avoid printing an error.
%:
$(if $(filter $(FIRST_ARG),$@), \
$(error "$@ cannot be the first argument. Use '$(MAKE) help|list_config_targets' to get a list of all possible [configuration] targets."),@#)
#help:
# @echo
# @echo "Type 'make ' and hit the tab key twice to see a list of the available"
# @echo "build configurations."
# @echo
empty :=
space := $(empty) $(empty)
# Print a list of non-config targets (based on http://stackoverflow.com/a/26339924/1487069)
help:
@echo "Usage: $(MAKE) <target>"
@echo "Where <target> is one of:"
@$(MAKE) -pRrq -f $(lastword $(MAKEFILE_LIST)) : 2>/dev/null | \
awk -v RS= -F: '/^# File/,/^# Finished Make data base/ {if ($$1 !~ "^[#.]") {print $$1}}' | sort | \
egrep -v -e '^[^[:alnum:]]' -e '^($(subst $(space),|,$(ALL_CONFIG_TARGETS) $(NUTTX_CONFIG_TARGETS)))$$' -e '_default$$' -e '^(posix|eagle|Makefile)'
@echo
@echo "Or, $(MAKE) <config_target> [<make_target(s)>]"
@echo "Use '$(MAKE) list_config_targets' for a list of configuration targets."
# Print a list of all config targets.
list_config_targets:
@for targ in $(patsubst nuttx_%,[nuttx_]%,$(ALL_CONFIG_TARGETS)); do echo $$targ; done
Submodule NuttX deleted from f0f4bdc872
+99 -24
View File
@@ -1,35 +1,110 @@
## PX4 Pro Drone Autopilot ##
# PX4 Pro Drone Autopilot
[![Build Status](https://travis-ci.org/PX4/Firmware.svg?branch=master)](https://travis-ci.org/PX4/Firmware) [![Coverity Scan](https://scan.coverity.com/projects/3966/badge.svg?flat=1)](https://scan.coverity.com/projects/3966?tab=overview)
[![Releases](https://img.shields.io/github/release/PX4/Firmware.svg)](https://github.com/PX4/Firmware/releases) [![DOI](https://zenodo.org/badge/22634/PX4/Firmware.svg)](https://zenodo.org/badge/latestdoi/22634/PX4/Firmware)
[![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/PX4/Firmware?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![Build Status](http://ci.px4.io:8080/buildStatus/icon?job=Firmware/master)](http://ci.px4.io:8080/blue/organizations/jenkins/Firmware/activity) [![Coverity Scan](https://scan.coverity.com/projects/3966/badge.svg?flat=1)](https://scan.coverity.com/projects/3966?tab=overview)
This repository holds the [PX4 Pro](http://px4.io) flight control solution for drones, with the main applications located in the src/modules directory. It also contains the PX4 Drone Middleware Platform, which provides drivers and middleware to run drones.
[![Slack](https://px4-slack.herokuapp.com/badge.svg)](http://slack.px4.io)
* Official Website: http://px4.io
* License: BSD 3-clause (see [LICENSE.md](https://github.com/PX4/Firmware/blob/master/LICENSE.md))
* Supported airframes (more experimental are supported):
* [Multicopters](http://px4.io/portfolio_category/multicopter/)
* [Fixed wing](http://px4.io/portfolio_category/plane/)
* [VTOL](http://px4.io/portfolio_category/vtol/)
* Releases
* [Downloads](https://github.com/PX4/Firmware/releases)
This repository holds the [PX4 Pro](http://px4.io) flight control solution for drones, with the main applications located in the [src/modules](https://github.com/PX4/Firmware/tree/master/src/modules) directory. It also contains the PX4 Drone Middleware Platform, which provides drivers and middleware to run drones.
### Users ###
* Official Website: http://px4.io (License: BSD 3-clause, [LICENSE](https://github.com/PX4/Firmware/blob/master/LICENSE))
* [Supported airframes](https://docs.px4.io/en/airframes/airframe_reference.html) ([portfolio](http://px4.io/#airframes)):
* [Multicopters](https://docs.px4.io/en/airframes/airframe_reference.html#copter)
* [Fixed wing](https://docs.px4.io/en/airframes/airframe_reference.html#plane)
* [VTOL](https://docs.px4.io/en/airframes/airframe_reference.html#vtol)
* many more experimental types (Rovers, Blimps, Boats, Submarines, etc)
* Releases: [Downloads](https://github.com/PX4/Firmware/releases)
Please refer to the [user documentation](http://px4.io) and [user forum](http://discuss.px4.io) for flying drones with the PX4 flight stack.
### Developers ###
## PX4 Users
* [Developer Forum / Mailing list](http://groups.google.com/group/px4users)
* [Guide for Contributions](https://github.com/PX4/Firmware/blob/master/CONTRIBUTING.md)
* [Developer guide](http://dev.px4.io)
The [PX4 User Guide](https://docs.px4.io/en/) explains how to assemble [supported vehicles](https://docs.px4.io/en/airframes/airframe_reference.html) and fly drones with PX4.
See the [forum and chat](https://docs.px4.io/en/#support) if you need help!
## PX4 Developers
This [Developer Guide](https://dev.px4.io/) is for software developers who want to modify the flight stack and middleware (e.g. to add new flight modes), hardware integrators who want to support new flight controller boards and peripherals, and anyone who wants to get PX4 working on a new (unsupported) airframe/vehicle.
Developers should read the [Guide for Contributions](https://dev.px4.io/en/contribute/).
See the [forum and chat](https://dev.px4.io/en/#support) if you need help!
### Weekly Dev Call
The PX4 Dev Team syncs up on a [weekly dev call](https://dev.px4.io/en/contribute/#dev_call).
> **Note** The dev call is open to all interested developers (not just the core dev team). This is a great opportunity to meet the team and contribute to the ongoing development of the platform.
## Maintenance Team
* Project / Founder - [Lorenz Meier](https://github.com/LorenzMeier)
* [Dev Call](https://github.com/PX4/Firmware/labels/devcall) - [Ramon Roche](https://github.com/mrpollo)
* Communication Architecture
* [Beat Kueng](https://github.com/bkueng)
* [Julian Oes](https://github.com/JulianOes)
* UI / UX
* [Donald Gagne](https://github.com/DonLakeFlyer)
* [Gus Grubba](https://github.com/dogmaphobic)
* [Multicopter Flight Control](https://github.com/PX4/Firmware/labels/multicopter)
* [Dennis Mannhart](https://github.com/Stifael)
* [Matthias Grob](https://github.com/MaEtUgR)
* [VTOL Flight Control](https://github.com/PX4/Firmware/labels/vtol)
* [Daniel Agar](https://github.com/dagar)
* [Mathieu Bresciani](https://github.com/bresch)
* [Sander Smeets](https://github.com/sanderux)
* [Roman Bapst](https://github.com/tumbili)
* [Andreas Antener](https://github.com/AndreasAntener)
* [Fixed Wing Flight Control](https://github.com/PX4/Firmware/labels/fixedwing)
* [Daniel Agar](https://github.com/dagar)
* [Paul Riseborough](https://github.com/priseborough)
* Racers - [Matthias Grob](https://github.com/MaEtUgR)
* OS / drivers - [David Sidrane](https://github.com/davids5)
* [UAVCAN](https://github.com/PX4/Firmware/labels/uavcan) / Industrial - [Pavel Kirienko](https://github.com/pavel-kirienko)
* [State Estimation](https://github.com/PX4/Firmware/issues?q=is%3Aopen+is%3Aissue+label%3A%22state+estimation%22) - [James Goppert](https://github.com/jgoppert), [Paul Riseborough](https://github.com/priseborough)
* Vision based navigation
* [Christoph Tobler](https://github.com/ChristophTobler)
* [Mohammed Kabir](https://github.com/mhkabir)
* Obstacle Avoidance - [Vilhjalmur Vilhjalmsson](https://github.com/vilhjalmur89)
* [Snapdragon](https://github.com/PX4/Firmware/labels/snapdragon)
* [Christoph Tobler](https://github.com/ChristophTobler)
* [Mark Charlebois](https://github.com/mcharleb)
* [Intel Aero](https://github.com/PX4/Firmware/labels/intel%20aero)
* [Sugnan Prabhu](https://github.com/sugnanprabhu)
* [José Roberto de Souza](https://github.com/zehortigoza)
* [Raspberry Pi / Navio](https://github.com/PX4/Firmware/labels/raspberry_pi) - [Beat Kueng](https://github.com/bkueng)
* [Parrot Bebop](https://github.com/PX4/Firmware/labels/bebop) - [Michael Schaeuble](https://github.com/eyeam3)
* [Airmind MindPX / MindRacer](https://github.com/PX4/Firmware/labels/mindpx) - [Henry Zhang](https://github.com/iZhangHui)
* RTPS/ROS2 Interface - [Vicente Monge](https://github.com/vicenteeprosima)
See also [About Us](http://px4.io/about-us/#development_team) (px4.io) and the [contributors list](https://github.com/PX4/Firmware/graphs/contributors) (Github).
## Supported Hardware
This repository contains code supporting these boards:
* [Snapdragon Flight](http://dev.px4.io/hardware-snapdragon.html)
* FMUv1.x
* FMUv2.x ([Pixhawk](http://dev.px4.io/hardware-pixhawk.html), Pixhawk 2 and [Pixfalcon](http://dev.px4.io/hardware-pixfalcon.html))
* FMUv4.x (Pixhawk X and [Pixracer](http://dev.px4.io/hardware-pixracer.html))
* AeroCore (v1 and v2)
* STM32F4Discovery (basic support) [Tutorial](https://pixhawk.org/modules/stm32f4discovery)
* [Snapdragon Flight](https://docs.px4.io/en/flight_controller/snapdragon_flight.html)
* [Intel Aero](https://docs.px4.io/en/flight_controller/intel_aero.html)
* [Raspberry PI with Navio 2](https://docs.px4.io/en/flight_controller/raspberry_pi_navio2.html)
* [Parrot Bebop 2](https://dev.px4.io/en/advanced/parrot_bebop.html)
* FMUv2.x
* [Pixhawk](https://docs.px4.io/en/flight_controller/pixhawk.html)
* [Pixhawk Mini](https://docs.px4.io/en/flight_controller/pixhawk_mini.html)
* [Pixfalcon](https://docs.px4.io/en/flight_controller/pixfalcon.html)
* FMUv3.x [Pixhawk 2](https://pixhawk.org/modules/pixhawk2)
* FMUv4.x
* [Pixracer](https://docs.px4.io/en/flight_controller/pixracer.html)
* [Pixhawk 3 Pro](https://docs.px4.io/en/flight_controller/pixhawk3_pro.html)
* FMUv5.x (ARM Cortex M7, future Pixhawk)
* [STM32F4Discovery](http://www.st.com/en/evaluation-tools/stm32f4discovery.html) (basic support) [Tutorial](https://pixhawk.org/modules/stm32f4discovery)
* [Gumstix AeroCore](https://www.gumstix.com/aerocore-2/) (only v2)
* [Airmind MindPX V2.8](http://www.mindpx.net/assets/accessories/UserGuide_MindPX.pdf)
* [Airmind MindRacer V1.2](http://mindpx.net/assets/accessories/mindracer_user_guide_v1.2.pdf)
* [Bitcraze Crazyflie 2.0](https://docs.px4.io/en/flight_controller/crazyflie2.html)
Additional information about supported hardware can be found in [PX4 user Guide > Autopilot Hardware](https://docs.px4.io/en/flight_controller/).
## Project Roadmap
A high level project roadmap is available [here](https://www.dronecode.org/roadmap/).
+46
View File
@@ -0,0 +1,46 @@
message(STATUS "ROMFS: ${config_romfs_root}")
set(romfs_temp_dir ${PX4_BINARY_DIR}/ROMFS/${config_romfs_root})
set(romfs_src_dir ${PX4_SOURCE_DIR}/ROMFS/${config_romfs_root})
# directory setup
# copy all romfs files, process airframes, prune comments
file(GLOB_RECURSE init_airframes ${PX4_SOURCE_DIR}/ROMFS/${config_romfs_root}/*/[1-9]*)
add_custom_command(OUTPUT ${romfs_temp_dir}/init.d/rcS ${romfs_temp_dir}/init.d/rc.autostart
COMMAND cmake -E copy_directory ${romfs_src_dir} ${romfs_temp_dir}
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/px_process_airframes.py
-a ${romfs_temp_dir}/init.d
-s ${romfs_temp_dir}/init.d/rc.autostart
--board ${BOARD}
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/px_romfs_pruner.py
--folder ${romfs_temp_dir} --board ${BOARD}
DEPENDS
${romfs_src_files}
${init_airframes}
${PX4_SOURCE_DIR}/ROMFS/${config_romfs_root}/init.d/rcS
${PX4_SOURCE_DIR}/Tools/px_process_airframes.py
)
set(romfs_dependencies)
list(APPEND romfs_dependencies
${romfs_temp_dir}/init.d/rcS
${romfs_temp_dir}/init.d/rc.autostart
)
# create romfs.bin
add_custom_command(OUTPUT romfs.img
COMMAND ${GENROMFS} -f romfs.img -d ${romfs_temp_dir} -V "NSHInitVol" -v > romfs.txt 2>&1
DEPENDS ${romfs_dependencies}
)
# create romfs.o
add_custom_command(OUTPUT nsh_romfsimg.c
COMMAND xxd -i romfs.img nsh_romfsimg.c
COMMAND sed 's/unsigned/const unsigned/g' nsh_romfsimg.c > nsh_romfsimg.c.tmp && mv nsh_romfsimg.c.tmp nsh_romfsimg.c
DEPENDS romfs.img
)
add_library(romfs STATIC nsh_romfsimg.c)
add_dependencies(romfs platforms__common)
set_target_properties(romfs PROPERTIES LINKER_LANGUAGE C)
@@ -3,11 +3,14 @@
# @name HILStar (XPlane)
#
# @type Simulation
# @class Plane
#
# @output MAIN1 aileron
# @output MAIN2 elevator
# @output MAIN3 rudder
# @output MAIN4 throttle
# @output MAIN5 flaps
# @output MAIN6 gear
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
@@ -41,5 +44,5 @@ then
param set RWTO_TKOFF 1
fi
set HIL yes
param set SYS_HITL 1
set MIXER AERT
+14 -1
View File
@@ -3,8 +3,21 @@
# @name Team Blacksheep Discovery
#
# @type Quadrotor Wide
# @class Copter
#
# @maintainer Anton Babushkin <anton@px4.io>, Simon Wilks <simon@px4.io>
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output MAIN5 feed-through of RC AUX1 channel
# @output MAIN6 feed-through of RC AUX2 channel
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
# @output AUX4 feed-through of RC FLAPS channel
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
sh /etc/init.d/rc.mc_defaults
+13 -2
View File
@@ -3,8 +3,19 @@
# @name 3DR Iris Quadrotor
#
# @type Quadrotor Wide
# @class Copter
#
# @maintainer Anton Babushkin <anton@px4.io>
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
# @output AUX4 feed-through of RC FLAPS channel
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
sh /etc/init.d/rc.mc_defaults
@@ -29,6 +40,6 @@ then
param set BAT_A_PER_V 15.39103
fi
set MIXER quad_w
set MIXER quad_dc
set PWM_OUT 1234
@@ -3,8 +3,21 @@
# @name Steadidrone QU4D
#
# @type Quadrotor Wide
# @class Copter
#
# @maintainer Thomas Gubler <thomas@px4.io>
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output MAIN5 feed-through of RC AUX1 channel
# @output MAIN6 feed-through of RC AUX2 channel
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
# @output AUX4 feed-through of RC FLAPS channel
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
sh /etc/init.d/rc.mc_defaults
+15 -3
View File
@@ -3,8 +3,21 @@
# @name Team Blacksheep Discovery Endurance
#
# @type Quadrotor Wide
# @class Copter
#
# @maintainer Simon Wilks <simon@px4.io>
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output MAIN5 feed-through of RC AUX1 channel
# @output MAIN6 feed-through of RC AUX2 channel
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
# @output AUX4 feed-through of RC FLAPS channel
#
# @maintainer Simon Wilks <simon@uaventure.com>
#
sh /etc/init.d/rc.mc_defaults
@@ -27,11 +40,10 @@ then
param set MC_YAWRATE_I 0.1
param set MC_YAWRATE_D 0.0
param set MPC_XY_FF 0.2
param set MPC_XY_VEL_MAX 2
param set PWM_MIN 1080
fi
set MIXER quad_w
set PWM_OUT 1234
set PWM_MIN 1080
@@ -1,39 +0,0 @@
#!nsh
#
# @name HobbyKing SK450 DeadCat modification
#
# @type Quadrotor Wide
#
# @maintainer Anton Matosov <anton.matosov@gmail.com>
#
sh /etc/init.d/rc.mc_defaults
if [ $AUTOCNF == yes ]
then
param set MC_ROLL_P 6.0
param set MC_ROLLRATE_P 0.08
param set MC_ROLLRATE_I 0.03
param set MC_ROLLRATE_D 0.0015
param set MC_PITCH_P 6.0
param set MC_PITCHRATE_P 0.1
param set MC_PITCHRATE_I 0.03
param set MC_PITCHRATE_D 0.0015
param set MC_YAW_P 2.8
param set MC_YAWRATE_P 0.1
param set MC_YAWRATE_I 0.07
param set MC_YAWRATE_D 0.0
fi
set MIXER sk450_deadcat
set PWM_OUT 1234
set PWM_AUX_OUT 1234
# set PWM_AUX_MIN 900
# set PWM_AUX_MAX 2100
set PWM_AUX_RATE 100
gimbal start
@@ -3,12 +3,11 @@
# @name HIL Quadcopter X
#
# @type Simulation
# @class Copter
#
# @maintainer Anton Babushkin <anton@px4.io>
# @maintainer Lorenz Meier <lorenz@px4.io>
#
sh /etc/init.d/rc.mc_defaults
sh /etc/init.d/4001_quad_x
set MIXER quad_x
set HIL yes
param set SYS_HITL 1
@@ -1,14 +0,0 @@
#!nsh
#
# @name HIL Quadcopter +
#
# @type Simulation
#
# @maintainer Anton Babushkin <anton@px4.io>
#
sh /etc/init.d/rc.mc_defaults
set MIXER quad_+
set HIL yes
@@ -1,14 +0,0 @@
#!nsh
#
# @name HIL Rascal 110 (Flightgear)
#
# @type Simulation
#
# @maintainer Thomas Gubler <thomas@px4.io>
#
sh /etc/init.d/rc.fw_defaults
set HIL yes
set MIXER AERT
@@ -1,41 +0,0 @@
#!nsh
#
# @name HIL Malolo 1 (Flightgear)
#
# @type Simulation
#
# @maintainer Thomas Gubler <thomas@px4.io>
#
sh /etc/init.d/rc.fw_defaults
if [ $AUTOCNF == yes ]
then
param set FW_AIRSPD_MIN 12
param set FW_AIRSPD_TRIM 25
param set FW_AIRSPD_MAX 40
param set FW_R_TC 0.3
param set FW_P_TC 0.3
param set FW_L1_DAMPING 0.74
param set FW_L1_PERIOD 15
param set FW_PR_FF 0.8
param set FW_PR_I 0.05
param set FW_PR_IMAX 0.2
param set FW_PR_P 0.1
param set FW_P_ROLLFF 0
param set FW_RR_FF 0.6
param set FW_RR_I 0.02
param set FW_RR_IMAX 0.2
param set FW_RR_P 0.1
param set FW_R_LIM 45
param set FW_R_RMAX 0
param set FW_YR_FF 0.0
param set FW_YR_I 0
param set FW_YR_IMAX 0.2
param set FW_YR_P 0.0
fi
set HIL yes
# Set the AERT mixer for HIL (even if the malolo is a flying wing)
set MIXER AERT
+3 -2
View File
@@ -1,15 +1,16 @@
#!nsh
#
# @name Generic Hexa coaxial geometry
# @name Generic Hexarotor coaxial geometry
#
# @type Hexarotor Coaxial
# @class Copter
#
# @output MAIN1 front right top, CW; angle:60; direction:CW
# @output MAIN2 front right bottom, CCW; angle:60; direction:CCW
# @output MAIN3 back top, CW; angle:180; direction:CW
# @output MAIN4 back bottom, CCW; angle:180; direction:CCW
# @output MAIN5 front left top, CW; angle:-60; direction:CW
# @output MAIN6 front left bottom, CCW;angle:-60; direction:CCW
# @output MAIN6 front left bottom, CCW;angle:-60; direction:CCW
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
+10
View File
@@ -3,6 +3,16 @@
# @name Generic 10" Octo coaxial geometry
#
# @type Octorotor Coaxial
# @class Copter
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output MAIN5 motor 5
# @output MAIN6 motor 6
# @output MAIN7 motor 7
# @output MAIN8 motor 8
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
@@ -3,6 +3,16 @@
# @name Steadidrone MAVRIK
#
# @type Octo Coax Wide
# @class Copter
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output MAIN5 motor 5
# @output MAIN6 motor 6
# @output MAIN7 motor 7
# @output MAIN8 motor 8
#
# @maintainer Simon Wilks <simon@uaventure.com>
#
@@ -31,7 +41,7 @@ then
param set MPC_HOLD_MAX_XY 0.25
param set MPC_THR_MIN 0.15
param set MPC_Z_VEL_MAX 2.0
param set MPC_Z_VEL_MAX_DN 2.0
param set BAT_N_CELLS 4
fi
@@ -0,0 +1,37 @@
#!nsh
#
# @name Generic Quadplane VTOL
#
# @type Standard VTOL
# @class VTOL
#
# @maintainer
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output AUX1 Aileron 1
# @output AUX2 Aileron 2
# @output AUX3 Elevator
# @output AUX4 Rudder
# @output AUX5 Throttle
#
sh /etc/init.d/rc.vtol_defaults
if [ $AUTOCNF == yes ]
then
param set VT_TYPE 2
param set VT_MOT_COUNT 4
fi
set MIXER quad_x
set PWM_OUT 1234
set PWM_RATE 400
set MIXER_AUX vtol_AAERT
set PWM_ACHDIS 5
set PWM_AUX_DISARMED 950
set MAV_TYPE 22
@@ -3,11 +3,12 @@
# @name Caipiroshka Duo Tailsitter
#
# @type VTOL Duo Tailsitter
# @class VTOL
#
# @output MAIN1 motor left
# @output MAIN2 motor right
# @output MAIN5 elevon left
# @output MAIN6 elevon right
# @output MAIN1 motor right
# @output MAIN2 motor left
# @output MAIN5 elevon right
# @output MAIN6 elevon left
#
# @maintainer Roman Bapst <roman@px4.io>
#
+17 -6
View File
@@ -1,10 +1,21 @@
#!nsh
#
# @name BirdsEyeView Aerobotics FireFly6
#
# @type VTOL Tiltrotor
# @class VTOL
#
# @maintainer Roman Bapst <roman@px4.io>
# @maintainer Roman Bapst <roman@uaventure.com>
#
# @output MAIN1 Front right motor bottom
# @output MAIN2 Front right motor top
# @output MAIN3 Back motor bottom
# @output MAIN4 Back motor top
# @output MAIN5 Front left motor bottom
# @output MAIN6 Front left motor top
# @output AUX1 Tilt servo
# @output AUX2 Elevon 1
# @output AUX3 Elevon 2
# @output AUX4 Gear
#
sh /etc/init.d/rc.vtol_defaults
@@ -12,16 +23,16 @@ sh /etc/init.d/rc.vtol_defaults
if [ $AUTOCNF == yes ]
then
param set MC_ROLL_P 7.0
param set MC_ROLLRATE_P 0.17
param set MC_ROLLRATE_P 0.19
param set MC_ROLLRATE_I 0.002
param set MC_ROLLRATE_D 0.003
param set MC_ROLLRATE_D 0.005
param set MC_ROLLRATE_FF 0.0
param set MC_PITCH_P 7.0
param set MC_PITCHRATE_P 0.14
param set MC_PITCHRATE_I 0.002
param set MC_PITCHRATE_D 0.003
param set MC_PITCHRATE_D 0.004
param set MC_PITCHRATE_FF 0.0
param set MC_YAW_P 3.8
param set MC_YAW_P 4.0
param set MC_YAW_FF 0.5
param set MC_YAWRATE_P 0.22
param set MC_YAWRATE_I 0.02
@@ -3,6 +3,7 @@
# @name Quadrotor X Tailsitter
#
# @type VTOL Quad Tailsitter
# @class VTOL
#
# @maintainer Roman Bapst <roman@px4.io>
#
@@ -3,9 +3,21 @@
# @name Quadrotor + Tailsitter
#
# @type VTOL Quad Tailsitter
# @class VTOL
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 4
# @output MAIN4 motor 5
# @output MAIN5 elevon left
# @output MAIN6 elevon right
# @output MAIN7 canard surface
# @output MAIN8 rudder
#
# @maintainer Roman Bapst <roman@px4.io>
#
# @board px4fmu-v2 exclude
#
sh /etc/init.d/rc.vtol_defaults
@@ -1,11 +1,22 @@
#!nsh
#
# @name Fun Cub Quad VTOL.
# @name Fun Cub Quad VTOL
#
# @type Standard VTOL
# @class VTOL
#
# @maintainer Simon Wilks <simon@uaventure.com>
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output AUX1 Aileron 1
# @output AUX2 Aileron 2
# @output AUX3 Elevator
# @output AUX4 Rudder
# @output AUX5 Throttle
#
sh /etc/init.d/rc.vtol_defaults
@@ -33,6 +44,8 @@ then
param set MC_YAWRATE_I 0.02
param set MC_YAWRATE_D 0.0
param set MC_YAWRATE_FF 0.0
param set MC_YAWRATE_MAX 40
param set MC_YAWRAUTO_MAX 40
param set FW_PR_FF 0.5
param set FW_PR_I 0.02
@@ -49,7 +62,7 @@ then
param set VT_TYPE 2
fi
set MIXER vtol_quad_x
set MIXER quad_x
set PWM_OUT 1234
set PWM_RATE 400
@@ -1,11 +1,20 @@
#!nsh
#
# @name Generic quad delta VTOL.
# @name Generic quad delta VTOL
#
# @type Standard VTOL
# @class VTOL
#
# @maintainer Simon Wilks <simon@uaventure.com>
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output AUX1 Right elevon
# @output AUX2 Left elevon
# @output AUX3 Motor
#
sh /etc/init.d/rc.vtol_defaults
@@ -15,29 +24,35 @@ then
param set VT_MOT_COUNT 4
param set VT_TRANS_THR 0.75
param set MC_ROLL_P 7.0
param set MC_ROLL_P 6.5
param set MC_ROLLRATE_P 0.15
param set MC_ROLLRATE_I 0.002
param set MC_ROLLRATE_I 0.01
param set MC_ROLLRATE_D 0.003
param set MC_ROLLRATE_FF 0.0
param set MC_PITCH_P 7.0
param set MC_PITCHRATE_P 0.12
param set MC_PITCHRATE_I 0.002
param set MC_PITCH_P 6.5
param set MC_PITCHRATE_P 0.15
param set MC_PITCHRATE_I 0.01
param set MC_PITCHRATE_D 0.003
param set MC_PITCHRATE_FF 0.0
param set MC_YAW_P 2.8
param set MC_YAW_P 3.5
param set MC_YAW_FF 0.5
param set MC_YAWRATE_P 0.22
param set MC_YAWRATE_I 0.02
param set MC_YAWRATE_P 0.2
param set MC_YAWRATE_I 0.1
param set MC_YAWRATE_D 0.0
param set MC_YAWRATE_FF 0.0
param set MC_YAWRATE_MAX 50
param set MC_YAWRAUTO_MAX 20
param set MPC_XY_P 0.8
param set MPC_XY_VEL_P 0.1
param set MPC_ACC_HOR_MAX 2.0
param set VT_MOT_COUNT 4
param set VT_IDLE_PWM_MC 1080
param set VT_TYPE 2
fi
set MIXER vtol_quad_x
set MIXER quad_x
set PWM_OUT 1234
set PWM_RATE 400
@@ -3,6 +3,7 @@
# @name Generic AAVVT v-tail plane airframe with Quad VTOL.
#
# @type Standard VTOL
# @class VTOL
#
# @maintainer Sander Smeets <sander@droneslab.com>
#
@@ -31,13 +32,15 @@ then
param set MC_YAWRATE_I 0.02
param set MC_YAWRATE_D 0.0
param set MC_YAWRATE_FF 0.0
param set MC_YAWRATE_MAX 40
param set MC_YAWRAUTO_MAX 40
param set VT_MOT_COUNT 4
param set VT_IDLE_PWM_MC 1080
param set VT_TYPE 2
fi
set MIXER vtol_quad_x
set MIXER quad_x
set PWM_OUT 1234
set PWM_RATE 400
+5 -2
View File
@@ -3,6 +3,7 @@
# @name QuadRanger
#
# @type Standard VTOL
# @class VTOL
#
# @maintainer Sander Smeets <sander@droneslab.com>
#
@@ -34,9 +35,11 @@ then
param set MC_YAWRATE_I 0.04
param set MC_YAWRATE_D 0.0
param set MC_YAWRATE_FF 0.0
param set MC_YAWRATE_MAX 40.0
param set MC_YAWRAUTO_MAX 40.0
param set MPC_ACC_HOR_MAX 2.0
param set MPC_Z_VEL_MAX 1.5
param set MPC_Z_VEL_MAX_DN 1.5
param set MPC_TKO_SPEED 1.5
param set MPC_LAND_SPEED 0.8
@@ -57,7 +60,7 @@ then
param set VT_TYPE 2
fi
set MIXER vtol_quad_x
set MIXER quad_x
set PWM_OUT 1234
set PWM_RATE 400
@@ -3,6 +3,7 @@
# @name Sparkle Tech Ranger VTOL
#
# @type Standard VTOL
# @class VTOL
#
# @maintainer Andreas Antener <andreas@uaventure.com>
#
@@ -45,6 +46,7 @@ then
param set MC_YAWRATE_I 0.02
param set MC_YAWRATE_MAX 40.0
param set MC_YAWRATE_P 0.18
param set MC_YAWRATE_MAX 40.0
param set MC_YAWRAUTO_MAX 40.0
param set MIS_TAKEOFF_ALT 2.5
@@ -60,13 +62,10 @@ then
param set MPC_TILTMAX_AIR 35.0
param set MPC_TILTMAX_LND 20.0
param set MPC_TKO_SPEED 1.0
param set MPC_XY_FF 0.1
param set MPC_XY_P 0.3
param set MPC_XY_VEL_MAX 3.0
param set MPC_XY_VEL_P 0.05
param set MPC_Z_FF 0.3
param set MPC_Z_P 0.5
param set MPC_Z_VEL_MAX 1.0
param set MPC_Z_VEL_P 0.1
param set NAV_ACC_RAD 3.0
@@ -77,7 +76,7 @@ then
param set PWM_AUX_REV4 1
fi
set MIXER vtol_quad_x
set MIXER quad_x
set PWM_OUT 1234
set PWM_RATE 400
+40
View File
@@ -0,0 +1,40 @@
#!nsh
#
# @name CruiseAder Claire
#
# @type VTOL Tiltrotor
# @class VTOL
#
# @maintainer Samay Siga <samay_s@icloud.com>
#
# @board px4fmu-v2 exclude
#
sh /etc/init.d/rc.vtol_defaults
if [ $AUTOCNF == yes ]
then
param set VT_TYPE 1
param set VT_TILT_MC 0.08
param set VT_TILT_TRANS 0.5
param set VT_TILT_FW 0.9
param set VT_MOT_COUNT 4
param set VT_FW_MOT_OFFID 13
param set VT_IDLE_PWM_MC 1080
param set VT_TYPE 1
fi
set MIXER claire
set PWM_OUT 1234
set PWM_RATE 400
set PWM_MAX 2000
set MIXER_AUX claire
set PWM_AUX_RATE 50
set PWM_AUX_RATE 123
set PWM_AUX_MIN 1000
set PWM_AUX_MAX 2000
set PWM_AUX_DISARMED 1000
set MAV_TYPE 21
@@ -0,0 +1,83 @@
#!nsh
#
# @name E-flite Convergence
#
# @type VTOL Tiltrotor
# @class VTOL
#
# @maintainer Andreas Antener <andreas@uaventure.com>
#
# @output MAIN1 Motor right
# @output MAIN2 Motor left
# @output MAIN3 Motor back
# @output MAIN4 empty
# @output MAIN5 Tilt servo right
# @output MAIN6 Tilt servo left
# @output MAIN7 Elevon right
# @output MAIN8 Elevon left
#
sh /etc/init.d/rc.vtol_defaults
if [ $AUTOCNF == yes ]
then
param set VT_MOT_COUNT 3
param set VT_FW_MOT_OFFID 3
param set VT_IDLE_PWM_MC 1080
param set VT_TYPE 1
param set VT_B_TRANS_DUR 1.0
param set VT_FW_DIFTHR_EN 1
param set VT_FW_DIFTHR_SC 0.17
param set VT_FW_PERM_STAB 0
param set VT_F_TRANS_DUR 1.2
param set VT_F_TR_OL_TM 4.0
param set VT_TILT_FW 1.0
param set VT_TILT_MC 0.0
param set VT_TILT_TRANS 0.45
param set VT_TRANS_MIN_TM 1.2
param set VT_TRANS_P2_DUR 1.3
param set FW_L1_PERIOD 17
param set FW_MAN_R_MAX 50.0
param set FW_ACRO_X_MAX 270
param set FW_ACRO_Y_MAX 270
param set FW_ACRO_Z_MAX 180
param set FW_PR_FF 0.5
param set FW_PR_P 0.08
param set FW_PSP_OFF 5.0
param set FW_P_LIM_MAX 30
param set FW_P_LIM_MIN -30
param set FW_P_RMAX_NEG 60
param set FW_P_RMAX_POS 60
param set FW_RR_FF 0.33
param set FW_RR_P 0.11
param set FW_YR_FF 0.3
param set FW_YR_P 0.05
param set MC_PITCHRATE_D 0.003
param set MC_PITCHRATE_P 0.15
param set MC_PITCH_P 6.0
param set MC_ROLLRATE_D 0.003
param set MC_ROLLRATE_P 0.15
param set MC_ROLL_P 6.0
param set MC_YAWRATE_MAX 120
param set MC_YAWRATE_P 0.27
param set MC_YAW_FF 0.35
param set MC_YAW_P 2.5
param set MC_YAWRATE_P 0.3
param set MPC_LAND_SPEED 1.2
param set MPC_TKO_SPEED 2.5
param set MPC_Z_VEL_MAX_UP 3.0
param set CBRK_AIRSPD_CHK 162128
param set FW_ARSP_MODE 2
param set SENS_BOARD_ROT 8
fi
set MIXER vtol_convergence
set PWM_OUT 1234
set PWM_RATE 400
set MAV_TYPE 21
+124
View File
@@ -0,0 +1,124 @@
#!nsh
#
# @name DeltaQuad
#
# @type Standard VTOL
# @class VTOL
#
# @maintainer Sander Smeets <sander@droneslab.com>
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output MAIN5 Right elevon
# @output MAIN6 Left elevon
# @output MAIN7 Pusher motor
# @output MAIN8 Pusher reverse channel
#
sh /etc/init.d/rc.vtol_defaults
if [ $AUTOCNF == yes ]
then
param set VT_TYPE 2
param set VT_MOT_COUNT 4
param set VT_TRANS_THR 1
param set VT_DWN_PITCH_MAX 8
param set VT_FW_QC_P 55
param set VT_FW_QC_R 55
param set VT_TRANS_MIN_TM 8
param set VT_B_TRANS_DUR 5
param set VT_WV_LND_EN 1
param set VT_WV_LTR_EN 1
param set VT_FWD_THRUST_SC 2
param set VT_F_TRANS_DUR 1
param set VT_IDLE_PWM_MC 1025
param set FW_ARSP_MODE 2
param set FW_L1_PERIOD 25
param set FW_PR_FF 0.7
param set FW_PR_I 0.18
param set FW_PR_P 0.15
param set FW_P_TC 0.5
param set FW_PSP_OFF 5
param set FW_R_LIM 35
param set FW_RR_FF 0.9
param set FW_RR_I 0.08
param set FW_RR_P 0.18
param set FW_T_HRATE_FF 0.5
param set FW_T_CLMB_MAX 3
param set FW_T_SINK_MAX 3
param set FW_T_SINK_MIN 1
param set FW_T_VERT_ACC 6
param set FW_THR_CRUISE 0.68
param set FW_THR_SLEW_MAX 1
param set FW_MAN_P_MAX 30
param set FW_P_LIM_MAX 20
param set FW_P_LIM_MIN -25
param set FW_P_RMAX_NEG 45
param set FW_P_RMAX_POS 45
param set FW_R_RMAX 50
param set LNDMC_ALT_MAX 9999
param set LNDMC_XY_VEL_MAX 1
param set LNDMC_Z_VEL_MAX 0.7
param set MC_ROLL_P 6.5
param set MC_ROLLRATE_P 0.16
param set MC_ROLLRATE_I 0.01
param set MC_ROLLRATE_D 0.003
param set MC_ROLLRATE_FF 0.0
param set MC_ROLLRATE_MAX 80
param set MC_PITCH_P 6.5
param set MC_PITCHRATE_P 0.15
param set MC_PITCHRATE_I 0.05
param set MC_PITCHRATE_D 0.003
param set MC_PITCHRATE_FF 0.0
param set MC_PITCHRATE_MAX 80
param set MC_YAW_P 3.5
param set MC_YAW_FF 0.5
param set MC_YAWRATE_P 0.2
param set MC_YAWRATE_I 0.1
param set MC_YAWRATE_D 0.0
param set MC_YAWRATE_FF 0.0
param set MC_YAWRATE_MAX 20
param set MC_YAWRAUTO_MAX 20
param set MPC_XY_P 0.8
param set MPC_XY_VEL_P 0.1
param set MPC_XY_VEL_MAX 4
param set MPC_ACC_HOR_MAX 2.0
param set MPC_LAND_SPEED 1.5
param set MPC_MAN_R_MAX 30
param set MPC_TILTMAX_LND 35
param set MPC_Z_VEL_MAX 1.5
param set MPC_Z_VEL_MAX_UP 1.5
param set MPC_Z_VEL_MAX_DN 1.5
param set MPC_HOLD_MAX_XY 0.5
param set MPC_HOLD_MAX_Z 0.5
param set CBRK_AIRSPD_CHK 162128
param set CBRK_IO_SAFETY 22027
param set EKF2_GPS_POS_X -0.12
param set EKF2_IMU_POS_X -0.12
param set EKF2_TAU_VEL 0.5
param set SYS_COMPANION 57600
fi
set MIXER deltaquad
set PWM_OUT 1234
set PWM_RATE 400
param set PWM_MAIN_DIS5 1500
param set PWM_MAIN_DIS6 1500
param set PWM_MAIN_DIS7 900
param set PWM_MAIN_DIS8 900
set MIXER_AUX pass
set PWM_AUX_OUT 12345
set PWM_AUX_DISARMED 950
set MAV_TYPE 22
@@ -3,6 +3,12 @@
# @name Generic Tricopter Y+ Geometry
#
# @type Tricopter Y+
# @class Copter
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 yaw servo
#
# @maintainer Trent Lukaczyk <aerialhedgehog@gmail.com>
#
+7 -3
View File
@@ -3,6 +3,12 @@
# @name Generic Tricopter Y- Geometry
#
# @type Tricopter Y-
# @class Copter
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 yaw servo
#
# @maintainer Trent Lukaczyk <aerialhedgehog@gmail.com>
#
@@ -11,6 +17,4 @@ sh /etc/init.d/rc.mc_defaults
set MIXER tri_y_yaw-
set PWM_OUT 1234
set PWM_OUT 1234
+2 -12
View File
@@ -3,7 +3,8 @@
# @name Esky (Big) Lama v4
#
# @type Coaxial Helicopter
#
# @class Copter
#
# @output MAIN1 Left swashplate servomotor, pitch axis
# @output MAIN2 Right swashplate servomotor, roll axis
# @output MAIN3 Upper rotor (CCW)
@@ -17,11 +18,6 @@ set MIXER coax
if [ $AUTOCNF == yes ]
then
param set PE_VELNE_NOISE 0.5
param set PE_VELD_NOISE 0.35
param set PE_POSNE_NOISE 0.5
param set PE_POSD_NOISE 1.25
param set NAV_ACC_RAD 2.0
param set RTL_RETURN_ALT 30.0
param set RTL_DESCEND_ALT 10.0
@@ -51,14 +47,8 @@ fi
# use PWM parameters for throttle channel
set PWM_OUT 34
set PWM_RATE 400
set PWM_DISARMED p:PWM_DISARMED
set PWM_MIN p:PWM_MIN
set PWM_MAX p:PWM_MAX
# This is the gimbal pass mixer
set MIXER_AUX pass
set PWM_AUX_RATE 50
set PWM_AUX_OUT 1234
set PWM_AUX_DISARMED 1500
set PWM_AUX_MIN 1000
set PWM_AUX_MAX 2000
@@ -0,0 +1,57 @@
#!nsh
#
# @name Blade 130X
#
# @type Helicopter
# @class Copter
#
# @maintainer Bart Slinger <bartslinger@gmail.com>
#
# @output MAIN1 main motor
# @output MAIN2 front swashplate servo
# @output MAIN3 right swashplate servo
# @output MAIN4 left swashplate servo
# @output MAIN5 tail-rotor servo
#
sh /etc/init.d/rc.mc_defaults
# Configure as helicopter (number 4 defined in commander_helper.cpp)
set MAV_TYPE 4
set MIXER blade130
#set PWM_OUT 1234
if [ $AUTOCNF == yes ]
then
param set MC_ROLL_P 5.0
param set MC_ROLLRATE_P 0.0
param set MC_ROLLRATE_I 0.0
param set MC_ROLLRATE_D 0.0
param set MC_ROLLRATE_FF 0.15
param set MC_PITCH_P 6.5
param set MC_PITCHRATE_P 0.0
param set MC_PITCHRATE_I 0.0
param set MC_PITCHRATE_D 0.0
param set MC_PITCHRATE_FF 0.15
param set MC_YAW_P 3.0
param set MC_YAWRATE_P 0.1
param set MC_YAWRATE_I 0.0
param set MC_YAWRATE_D 0.0
param set MC_YAW_FF 0.0
param set MC_ROLLRATE_MAX 720.0
param set MC_PITCHRATE_MAX 720.0
param set MC_YAWRATE_MAX 400.0
param set MC_ACRO_R_MAX 360.0
param set MC_ACRO_P_MAX 360.0
param set PWM_MIN 1075
param set MPC_THR_MIN 0.06
param set MPC_MANTHR_MIN 0.06
param set ATT_BIAS_MAX 0.0
param set CBRK_IO_SAFETY 22027
fi
@@ -3,6 +3,13 @@
# @name Passthrough mode for Snapdragon
#
# @type custom
# @class Tool
#
# @board px4fmu-v2 exclude
# @board px4fmu-v3 exclude
# @board px4fmu-v4pro exclude
# @board px4fmu-v5 exclude
# @board aerofc-v1 exclude
#
# @maintainer Julian Oes <julian@oes.ch>
#
@@ -1,12 +0,0 @@
#!nsh
#
# @name Multiplex Easystar
#
# @type Standard Plane
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
sh /etc/init.d/rc.fw_defaults
set MIXER easystar
@@ -1,14 +1,16 @@
#!nsh
#
# @name Standard AETR Plane
# @name Standard Plane
#
# @type Standard Plane
# @class Plane
#
# @output MAIN1 aileron
# @output MAIN2 elevator
# @output MAIN3 throttle
# @output MAIN4 rudder
# @output MAIN5 flaps
# @output MAIN6 gear
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
@@ -19,10 +21,10 @@
sh /etc/init.d/rc.fw_defaults
set MIXER AETR
set MIXER AETRFG
# use PWM parameters for throttle channel
set PWM_OUT 3
set PWM_DISARMED p:PWM_DISARMED
set PWM_MIN p:PWM_MIN
set PWM_MAX p:PWM_MAX
set PWM_RATE 50
set PWM_AUX_RATE 50
# rate must be set by group (see pwm info)
# throttle is in the same group as servos
-28
View File
@@ -1,28 +0,0 @@
#!nsh
#
# @name Standard AERT Plane
#
# @type Standard Plane
#
# @output MAIN1 aileron
# @output MAIN2 elevator
# @output MAIN3 rudder
# @output MAIN4 throttle
# @output MAIN5 flaps
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
sh /etc/init.d/rc.fw_defaults
set MIXER AERT
# use PWM parameters for throttle channel
set PWM_OUT 4
set PWM_DISARMED p:PWM_DISARMED
set PWM_MIN p:PWM_MIN
set PWM_MAX p:PWM_MAX
@@ -1,22 +0,0 @@
#!nsh
#
# @name Skywalker (3DR Aero)
#
# @type Standard Plane
#
# @output MAIN1 aileron
# @output MAIN2 elevator
# @output MAIN4 rudder
# @output MAIN3 throttle
# @output MAIN5 flaps
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
sh /etc/init.d/rc.fw_defaults
set MIXER skywalker
@@ -1,20 +0,0 @@
#!nsh
#
# @name Skyhunter 1800
#
# @type Standard Plane
#
# @output MAIN1 aileron
# @output MAIN2 elevator
# @output MAIN4 throttle
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
sh /etc/init.d/rc.fw_defaults
set MIXER AET
+1 -3
View File
@@ -3,6 +3,7 @@
# @name Bormatec Maja
#
# @type Standard Plane
# @class Plane
#
# @output MAIN1 aileron
# @output MAIN2 aileron
@@ -45,6 +46,3 @@ set MIXER AAERTWF
# use PWM parameters for throttle channel
set PWM_OUT 5
set PWM_DISARMED p:PWM_DISARMED
set PWM_MIN p:PWM_MIN
set PWM_MAX p:PWM_MAX
+1 -3
View File
@@ -3,6 +3,7 @@
# @name Applied Aeronautics Albatross
#
# @type Plane A-Tail
# @class Plane
#
# @output MAIN1 aileron right
# @output MAIN2 aileron left
@@ -46,6 +47,3 @@ set MIXER AAVVTWFF
# use PWM parameters for throttle channel
set PWM_OUT 5
set PWM_DISARMED p:PWM_DISARMED
set PWM_MIN p:PWM_MIN
set PWM_MAX p:PWM_MAX
@@ -0,0 +1,51 @@
#!nsh
#
# @name Generic Dodecarotor cox geometry
#
# @type Dodecarotor cox
# @class Copter
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output MAIN5 motor 5
# @output MAIN6 motor 6
#
# @output AUX1 motor 7
# @output AUX2 motor 8
# @output AUX3 motor 9
# @output AUX4 motor 10
# @output AUX5 motor 11
# @output AUX6 motor 12
#
# @maintainer Ian McNanie <ianmcnanie@gmail.com>
# @maintainer William Peale <develop707@gmail.com>
#
set VEHICLE_TYPE mc
if [ $AUTOCNF == yes ]
then
param set NAV_ACC_RAD 2.0
param set RTL_RETURN_ALT 30.0
param set RTL_DESCEND_ALT 10.0
param set PWM_MIN 1075
param set PWM_MAX 1950
param set PWM_RATE 400
param set RTL_LAND_DELAY 0
fi
set PWM_AUX_RATE 400
# Note: May Have to set these parameters manually. They don't appear to save.
set PWM_AUX_DISARMED 900
param set PWM_AUX_MIN 1075
param set PWM_AUX_MAX 1950
set MIXER dodeca_top_cox
set MIXER_AUX dodeca_bottom_cox
# Need to set all 8 channels
set PWM_OUT 12345678
set PWM_AUX_OUT 123456
@@ -0,0 +1,18 @@
#!nsh
#
# @name Generic Flying Wing
#
# @type Flying Wing
# @class Plane
#
# @maintainer
#
sh /etc/init.d/rc.fw_defaults
if [ $AUTOCNF == yes ]
then
fi
set MIXER fw_generic_wing
+4 -2
View File
@@ -5,6 +5,7 @@
# @url https://pixhawk.org/platforms/planes/bormatec_camflyer_q
#
# @type Flying Wing
# @class Plane
#
# @output MAIN1 left aileron
# @output MAIN2 right aileron
@@ -14,7 +15,7 @@
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
#
# @maintainer Simon Wilks <simon@px4.io>
# @maintainer Simon Wilks <simon@uaventure.com>
#
sh /etc/init.d/rc.fw_defaults
@@ -42,7 +43,8 @@ then
param set FW_RR_P 0.04
fi
set MIXER Q
set MIXER fw_generic_wing
# Provide ESC a constant 1000 us pulse while disarmed
set PWM_OUT 4
set PWM_DISARMED 1000
+2 -1
View File
@@ -5,6 +5,7 @@
# @url https://pixhawk.org/platforms/planes/z-84_wing_wing
#
# @type Flying Wing
# @class Plane
#
# @output MAIN1 left aileron
# @output MAIN2 right aileron
@@ -14,7 +15,7 @@
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
#
# @maintainer Simon Wilks <simon@px4.io>
# @maintainer Simon Wilks <simon@uaventure.com>
#
sh /etc/init.d/rc.fw_defaults
+3 -2
View File
@@ -5,6 +5,7 @@
# @url https://pixhawk.org/platforms/planes/skywalker_x5
#
# @type Flying Wing
# @class Plane
#
# @output MAIN1 left aileron
# @output MAIN2 right aileron
@@ -14,7 +15,7 @@
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
#
# @maintainer Thomas Gubler <thomas@px4.io>, Julian Oes <julian@px4.io>
# @maintainer Julian Oes <julian@px4.io>
#
sh /etc/init.d/rc.fw_defaults
@@ -39,4 +40,4 @@ then
param set FW_RR_P 0.04
fi
set MIXER X5
set MIXER fw_generic_wing
+2 -1
View File
@@ -2,9 +2,10 @@
#
# @name Wing Wing (aka Z-84) Flying Wing
#
# @url https://pixhawk.org/platforms/planes/z-84_wing_wing
# @url https://docs.px4.io/en/framebuild_plane/wing_wing_z84.html
#
# @type Flying Wing
# @class Plane
#
# @output MAIN1 left aileron
# @output MAIN2 right aileron
+2 -1
View File
@@ -3,8 +3,9 @@
# @name FX-79 Buffalo Flying Wing
#
# @type Flying Wing
# @class Plane
#
# @maintainer Simon Wilks <simon@px4.io>
# @maintainer Simon Wilks <simon@uaventure.com>
#
sh /etc/init.d/rc.fw_defaults
+2 -1
View File
@@ -4,8 +4,9 @@
# @name Viper
#
# @type Flying Wing
# @class Plane
#
# @maintainer Simon Wilks <simon@px4.io>
# @maintainer Simon Wilks <simon@uaventure.com>
#
sh /etc/init.d/rc.fw_defaults
+2 -1
View File
@@ -5,6 +5,7 @@
# @url http://www.sparkletech.hk/
#
# @type Flying Wing
# @class Plane
#
# @output MAIN1 left aileron
# @output MAIN2 right aileron
@@ -14,7 +15,7 @@
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
#
# @maintainer Simon Wilks <simon@px4.io>
# @maintainer Simon Wilks <simon@uaventure.com>
#
sh /etc/init.d/rc.fw_defaults
@@ -0,0 +1,91 @@
#!nsh
#
# @name Modified Parrot Disco
#
# @url
#
# @type Flying Wing
# @class Plane
#
# @output MAIN1 left aileron
# @output MAIN2 right aileron
# @output MAIN4 throttle
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
#
# @maintainer Jan Liphardt <JTLiphardt@gmail.com>
#
sh /etc/init.d/rc.fw_defaults
if [ $AUTOCNF == yes ]
then
####################################
# Airspeed
####################################
param set FW_AIRSPD_MIN 15 # = 29 knots
param set FW_AIRSPD_TRIM 20 # = 39 knots
param set FW_AIRSPD_MAX 27 # = 52 knots
####################################
# The Main L1 Controller
####################################
param set FW_L1_PERIOD 20 #units of meters
#Damping factor for L1 control (def = 0.75)
param set FW_L1_DAMPING 0.75
####################################
# Pitch
####################################
# Basic limits (def = +/- 45 deg)
param set FW_P_LIM_MAX 45
param set FW_P_LIM_MIN -45
# Time Constant (def = 0.4s)
param set FW_P_TC 0.4
# Pitch rate feed forward (def = 0.5 %/rad/sec)
param set FW_PR_FF 0.35
# Pitch rate integrator limit (def = 0.4)
param set FW_PR_IMAX 0.4
# Pitch rate proportional gain (def = 0.08 %/rad/sec)
param set FW_PR_P 0.08
####################################
# Roll
####################################
# Basic limits (def = 50 deg)
param set FW_R_LIM 40
# Roll rate upper limit (def = 70 deg/s)
param set FW_R_RMAX 50
# Roll Time Constant (def = 0.4 s)
param set FW_R_TC 0.4
# Roll rate feed forward (def = 0.5 %/rad/sec)
param set FW_RR_FF 0.5
# Roll rate proportional Gain (def = 0.05 %/rad/sec)
param set FW_RR_P 0.05
# Roll Integrator Anti-Windup
param set FW_RR_IMAX 0.2
fi
set MIXER fw_generic_wing.main.mix
# Provide ESC a constant 1000 us pulse
set PWM_OUT 4
set PWM_DISARMED 1000
+28 -18
View File
@@ -3,6 +3,7 @@
# @name TBS Caipirinha
#
# @type Flying Wing
# @class Plane
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
@@ -11,36 +12,45 @@ sh /etc/init.d/rc.fw_defaults
if [ $AUTOCNF == yes ]
then
param set FW_AIRSPD_MAX 20
param set FW_AIRSPD_MIN 12
param set FW_AIRSPD_TRIM 16
param set FW_R_TC 0.3
param set FW_P_TC 0.3
param set FW_L1_DAMPING 0.74
param set FW_L1_PERIOD 16
param set FW_AIRSPD_MAX 25
param set FW_AIRSPD_MIN 12.5
param set FW_AIRSPD_TRIM 16.5
param set LNDFW_AIRSPD_MAX 6
param set LNDFW_VELI_MAX 4
param set LNDFW_VEL_XY_MAX 3
param set LNDFW_VEL_Z_MAX 5
param set FW_R_TC 0.4
param set FW_P_TC 0.4
param set FW_THR_CRUISE 0.55
param set FW_L1_DAMPING 0.75
param set FW_L1_PERIOD 15
param set FW_LND_ANG 15
param set FW_LND_FLALT 5
param set FW_LND_FLALT 8
param set FW_LND_HHDIST 15
param set FW_LND_HVIRT 13
param set FW_LND_TLALT 5
param set FW_LND_TLALT 10
param set FW_THR_LND_MAX 0
param set FW_PR_FF 0.35
param set FW_P_LIM_MAX 20
param set FW_P_LIM_MIN -30
param set FW_R_LIM 45
param set FW_PR_FF 0.45
param set FW_PR_IMAX 0.4
param set FW_PR_P 0.08
param set FW_RR_FF 0.6
param set FW_PR_P 0.005
param set FW_RR_FF 0.45
param set FW_RR_IMAX 0.2
param set FW_RR_P 0.04
param set FW_RR_P 0.013
param set FW_P_RMAX_NEG 70
param set FW_P_RMAX_POS 70
param set FW_R_RMAX 70
param set SYS_COMPANION 157600
param set PWM_MAIN_REV0 1
param set PWM_MAIN_REV1 1
param set PWM_MAIN_REV2 1
param set PWM_DISARMED 0
param set PWM_MIN 900
param set PWM_MAX 2100
param set MIS_TAKEOFF_ALT 50
param set NAV_LOITER_RAD 30
fi
set PWM_DISARMED p:PWM_DISARMED
set PWM_MIN p:PWM_MIN
set PWM_MAX p:PWM_MAX
set MIXER caipi
set PWM_OUT 1234
+10 -1
View File
@@ -1,12 +1,21 @@
#!nsh
#
# @name Generic Quadrotor X config
# @name Generic Quadrotor x
#
# @type Quadrotor x
# @class Copter
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output MAIN5 feed-through of RC AUX1 channel
# @output MAIN6 feed-through of RC AUX2 channel
#
# @output AUX1 feed-through of RC AUX1 channel
# @output AUX2 feed-through of RC AUX2 channel
# @output AUX3 feed-through of RC AUX3 channel
# @output AUX4 feed-through of RC FLAPS channel
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
@@ -0,0 +1,31 @@
#!nsh
#
# @name Generic Quadrotor x with mount (e.g. gimbal)
#
# @type Quadrotor x
# @class Copter
#
# @output MAIN1 motor 1
# @output MAIN2 motor 2
# @output MAIN3 motor 3
# @output MAIN4 motor 4
# @output MAIN5 feed-through of RC AUX1 channel
# @output MAIN6 feed-through of RC AUX2 channel
#
# @output AUX1 Mount pitch
# @output AUX2 Mount roll
# @output AUX3 Mount yaw
# @output AUX4 Mount retract
#
# @maintainer Leon Mueller <thedevleon>
#
sh /etc/init.d/rc.mc_defaults
set MIXER quad_x
set PWM_OUT 1234
set MIXER_AUX mount
set PWM_AUX_OUT 123456
set PWM_AUX_RATE 50
+35
View File
@@ -0,0 +1,35 @@
#!nsh
#
# @name Lumenier QAV-R (raceblade) 5" arms
#
# @type Quadrotor x
# @class Copter
#
# @board px4fmu-v2 exclude
#
# @maintainer James Goppert <james.goppert@gmail.com>
#
sh /etc/init.d/4001_quad_x
if [ $AUTOCNF == yes ]
then
param set MC_ROLL_P 8.0
param set MC_ROLLRATE_P 0.08
param set MC_ROLLRATE_I 0.16
param set MC_ROLLRATE_D 0.003
param set MC_PITCH_P 8.0
param set MC_PITCHRATE_P 0.1
param set MC_PITCHRATE_I 0.2
param set MC_PITCHRATE_D 0.003
param set MC_YAW_P 2.8
param set MC_YAWRATE_P 0.15
param set MC_YAWRATE_I 0.1
param set MC_YAWRATE_D 0.0
param set MC_YAW_FF 0.5
param set MC_TPA_BREAK_P 0.7
param set MC_TPA_RATE_P 0.3
param set PWM_MIN 1075
param set MPC_THR_MIN 0.06
param set MPC_MANTHR_MIN 0.06
fi
+27
View File
@@ -0,0 +1,27 @@
#!nsh
#
# @name H4 680mm with Z1 Tiny2 Gimbal
#
# @type Quadrotor x
# @class Copter
#
# @maintainer Leon Mueller <thedevleon>
#
sh /etc/init.d/4002_quad_x_mount
# The Z1 Tiny2 can handle up to 400Hz
# and works with min 1020us, middle 1520us, max 2020us
# see http://www.zhiyun-tech.com/uploadfile/datedown/instruction/Tiny2_English_instructionV1.03.pdf
# under Gimbal Connection Instruction
set PWM_AUX_RATE 400
set PWM_AUX_DISARMED 1520
set PWM_AUX_MIN 1020
set PWM_AUX_MAX 2020
# Start FrSky telemetry on SERIAL4 (ttyS6, designated "SERIAL4/5" on the case)
frsky_telemetry start -d /dev/ttyS6
# GPIO LED
gpio_led start -p 6
-39
View File
@@ -1,39 +0,0 @@
#!nsh
#
# @name AR.Drone Frame
#
# @type Quadrotor x
#
# @maintainer Lorenz Meier <lorenz@px4.io>
#
sh /etc/init.d/rc.mc_defaults
#
# Load default params for this platform
#
if [ $AUTOCNF == yes ]
then
# Set all params here, then disable autoconfig
param set MC_ROLL_P 6.0
param set MC_ROLLRATE_P 0.14
param set MC_ROLLRATE_I 0.1
param set MC_ROLLRATE_D 0.002
param set MC_PITCH_P 6.0
param set MC_PITCHRATE_P 0.14
param set MC_PITCHRATE_I 0.1
param set MC_PITCHRATE_D 0.002
param set MC_YAW_P 2.0
param set MC_YAWRATE_P 0.2
param set MC_YAWRATE_I 0.2
param set MC_YAWRATE_D 0.0
param set MC_YAW_FF 0.8
param set BAT_V_SCALING 0.00838095238
fi
set OUTPUT_MODE ardrone
set USE_IO no
set MIXER skip
# set MAV_TYPE because no specific mixer is set
set MAV_TYPE 2

Some files were not shown because too many files have changed in this diff Show More