Commit Graph
100 Commits
Author SHA1 Message Date
Julian Oes 727783fe94 mavlink: keep trying to find to broadcast
This should help the Snapdragon to connect if the network is not yet up
by the time the mainapp starts. It will retry to find a network and
broadcast once it finds one.
2016-04-08 22:38:22 -07:00
Julian Oes c32310b6b4 muorb: improve comment 2016-04-08 15:51:16 +02:00
Julian Oes 36d580bdc8 DF wrappers: use abs time instead of DF timestamp
The timestamp in the DriverFramework is not the same as the one
provided by hrt_absolute_time() in PX4. Because we are publishing on the
PX4 side, let's also use the timestamp from there.
2016-04-08 15:51:16 +02:00
Julian Oes 8422280f18 muorb: typo and added comment for magic number 2016-04-08 15:51:16 +02:00
Julian Oes 2bce8f2803 muorb: abs time on aDSP in sync with Linux side
This adds a call on startup of the muorb on the aDSP side to use an
offset for hrt_absolute_call(). This means that the hrt_absolute_call()
on the appsproc (Linux) side should now match the one on the aDSP
(QURT) side.
The accuracy still needs to be determined.
2016-04-08 15:51:16 +02:00
Julian Oes ae2c28677d mavlink: adapt network detection for Mac, use heap
It seems that Mac does not support the ioctl to check how big the ifconf
buffer needs to be. Therefore we just have to make a guess.
Alos, instead of allocating the variable size array on the stack, it's
probably safer to use the heap.
2016-04-08 09:41:10 +02:00
Julian Oes 20cd5f3e76 mavlink: make broadcast detection Mac compatible
This adresses that the ifconf interface is a bit different on Mac.
2016-04-07 15:21:24 +02:00
Julian Oes 66567baf89 mavlink: only try broadcast if valid address found 2016-04-07 13:20:48 +02:00
Julian Oes 9c8f67dfb8 platforms: fix build for QURT 2016-04-06 11:18:24 +02:00
Julian Oes 8707cfe9f2 commander: use macro with wait in all calibrations 2016-04-05 15:36:03 -07:00
Julian Oes f583f51027 commander: add macros for log messages and wait
As a current workaround we need to wait some time after publishing a
mavlink log message in order for it to arrive in QGC.
2016-04-05 15:36:02 -07:00
Julian Oes 7352dc6f2e commander: workaround to wait 1s before param save
Without this wait, we end up saving the old parameters on Snapdragon.
2016-04-05 13:02:53 +02:00
Julian Oes 60d66dc23f param_shmem: before saving update the param 2016-04-05 13:02:53 +02:00
Julian Oes 57c134a23d DriverFramework: updated submodule
This fixes the clock used for pthread_cond_timedwait properly.
2016-04-05 09:30:33 +02:00
Julian Oes 1afb7af2bb cmake: don't mess with git submodules everywhere
It's enough to have the check_submodules.sh script. The rest needs to
go.
2016-04-05 09:22:37 +02:00
Julian Oes e5c64c7629 DriverFramework: update submodule
This fixes a bug that the mainapp on Snapdragon uses 100% CPU.
2016-04-04 16:01:44 +02:00
Julian Oes 2b95b3dff1 sdlog2: fixed wrong memset 2016-04-04 13:02:36 +02:00
Julian Oes f4f1f5f027 commander: raise stack of low prio thread
The accel calibration sometimes lead to a crash. Raising the stack size
resolved the issue.
2016-04-01 15:12:08 +02:00
Julian Oes 994947ea84 Makefile/cmake/Tools: add easy Snapdragon upload
This adds a a target `make eagle_default` to build both the POSIX and
the QURT side in one command. Also, it adds an upload target for both to
push the files over adb to the device. This doesn't just push the
executables and lib files, but also the startup config files.
2016-04-01 11:36:27 +02:00
Julian Oes 56585082ec mavlink: look up broadcast address, don't guess it 2016-03-30 17:36:04 +02:00
Julian Oes a7e9bc8ba5 mavlink: copyright and author update 2016-03-30 17:36:04 +02:00
Julian Oes df24852366 mavlink: fix broadcast on Snapdragon
Instead of using 255.255.255.255 as the broadcast address, go through
the network interfaces and and try to use a broadcast in the local
network such as 192.168.1.255.
2016-03-30 17:36:04 +02:00
Julian Oes f776a3dc37 mavlink: better broadcast failed error description 2016-03-30 17:36:04 +02:00
Julian Oes 4a68946b62 DriverFramework: update submodule
This lowers the MPU9250 sampling rate from 1kHz to 500 Hz.
2016-03-30 17:35:02 +02:00
Julian Oes 9a5aa4f112 commander: pass PreflightCheck on Snapdragon
The tests don't work properly on Snapdragon yet, so just report happy
for now. Otherwise users get messages such as "No Gyro found" which is
wrong.
2016-03-30 10:00:22 +02:00
Julian Oes 3464648533 sdlog2: fix segfault when starting without args
`sdlog2 start` lead to a segfault.
2016-03-29 22:43:20 +02:00
Julian Oes 4179ed6c19 sdlog2: don't free the logbuffer after disarm
Only free the logbuffer if you exit sdlog2. After disarming, just reset
the pointers. This way, we don't take any risks doing malloc and free.

The actual "double free" was caused by trying to free the perf counter
inside logbuffer_free.
2016-03-29 22:43:20 +02:00
Julian Oes 7ce297be59 sdlog2: add logbuffer_reset to reset pointers
This allows resetting of the logbuffer without having to free and malloc
again.
2016-03-29 22:43:20 +02:00
Julian Oes 4e64382ba5 sdlog2: fixes for Snapdragon 2016-03-29 09:55:29 +02:00
Julian Oes 3ae0ef6eb6 mainapp.config: add sdlog2 to Snapdragon startup 2016-03-29 09:54:19 +02:00
Julian Oes 438c8827f6 snapdragon_rc_pwm: astyle 2016-03-27 12:40:10 +02:00
Julian Oes f718c25dbe commander: remove QURT workaround
Timestamps didn't exist when commander was run on the Linux side.
However, commander is now always run on the QURT side, so the hack is no
longer needed.
2016-03-27 12:40:10 +02:00
Julian Oes 00bee89c66 uart_esc: fix compile error and remove printf 2016-03-27 12:40:10 +02:00
Julian Oes 4698bf92a5 snapdragon_rc_pwm: no PWM when timed out
PWM output is now stopped if the mavlink actuator_controls stop being
sent. This means props will stop in case the Snapdragon crashes or the
cable from Snapdragon to Pixhawk/Pixracer breaks.
2016-03-27 12:40:10 +02:00
Julian Oes 8bf41fda94 px4.config: go back to J13 which is /dev/tty-2 2016-03-27 12:40:10 +02:00
Julian Oes 5fc5fc1ba2 posix_eagle_default: define fix for POSIX eagle 2016-03-27 12:40:10 +02:00
Julian Oes e7c997c5f1 rcS: remove hack
The mavlink instance USB can now be shutdown, so this hack is not needed
anymore.
2016-03-27 12:40:10 +02:00
Julian Oes 28a295485c rcS: set PWM output to 400 Hz for passthrough 2016-03-27 12:40:10 +02:00
Julian Oes 8b9c943da9 uart_esc: calculate raw PWM on the Snapdragon
This includes taking care of the arming state and the limit ramp.
2016-03-27 12:40:10 +02:00
Julian Oes df9832f806 snapdragon_rc_pwm: use ioctl to set PWM
This is by far the easiest solution for now.
2016-03-27 12:40:10 +02:00
Julian Oes a615f57c80 rcS: Make the passthrough option a vehicle_type 2016-03-27 12:40:10 +02:00
Julian Oes a9a20e0a55 rcS: startup for a passthrough Snapdragon option
This adds a custom passthrough "vehicle" to be used on
Pixhawk/Pixfalcon/Pixracer together with Snapdragon for RC input and PWM
output.
2016-03-27 12:40:10 +02:00
Julian Oes e5dfda6d46 uart_esc: remove timeout printf 2016-03-27 12:40:10 +02:00
Julian Oes e50f3ad4f2 uart_esc: do an additional advertise
If this is not done, the aDSP crashes, not quite sure why but it's gotta
be something about the context of the callback.
2016-03-27 12:40:10 +02:00
Julian Oes 647526407a snapdragon_rc_pwm: cleanup and raise bitrate 2016-03-27 12:40:10 +02:00
Julian Oes ee7b9751ce px4_layer: removed leftover printf lie 2016-03-27 12:40:10 +02:00
Julian Oes a318c4a4cd px4.config: use the ESC J13 UART on Snapdragon 2016-03-27 12:40:10 +02:00
Julian Oes cd2f0eca95 uart_esc: major cleanup, raise UART bitrate
This remove all leftovers from Qualcomm's ESC. Also, the startup
commands are cleaned up, and the UART bitrate is raised to 921600.
2016-03-27 12:40:10 +02:00
Julian Oes 45b41e26cc uart_esc: accept n channels instead of just 8. 2016-03-27 12:40:10 +02:00
Julian Oes 4477566d73 snapdragon_rc_pwm: send RC anyway.
Let's always send RC even if nothing arrives on the UART just yet.
2016-03-27 12:40:10 +02:00
Julian Oes 05ad25e141 px4fmu-v4_default: compile snapdragon_rc_pwm 2016-03-27 12:40:10 +02:00
Julian Oes 1d30e352fe rcS: don't stop if mc_att_control not running
This stopped the startup for setups with SYS_AUTOSTART 0.
2016-03-27 12:40:10 +02:00
Julian Oes d06c6a3f5c rcS: don't stop Pixracer startup if no params 2016-03-27 12:40:10 +02:00
Julian Oes cf98894a23 df_mpu9250_wrapper: disable coning correction
The coning correction for the accel int slipped in by accident.
2016-03-27 12:40:10 +02:00
Julian Oes b04cfd3eee df_mpu9250_wrapper: publish at 250 Hz 2016-03-27 12:40:10 +02:00
Julian Oes 393bcad4b6 df_mpu9250_wrapper: add delta angles for MPU9250 2016-03-27 12:40:10 +02:00
Julian Oes 4effcc0ac7 cmake/posix-configs: switch to ekf2 on Snapdragon 2016-03-27 12:40:10 +02:00
Julian Oes 79426c32c7 DriverFramework: update submodule
The latest version must have gotten lost in the merge.
2016-03-24 14:56:54 +01:00
Julian Oes d3f710dbb5 mavlink: don't use the file logging on Snapdragon 2016-03-24 13:10:02 +01:00
Julian Oes c1d112e860 cmake: add define for the POSIX side of eagle 2016-03-24 13:10:02 +01:00
Julian Oes 13866400fa commander: workaround to get calibration status
If mavlink_log calls follow close after each other a later one will
replace the previous one. Therefore do a quick usleep to get the
calibration status out the door.
2016-03-24 13:10:02 +01:00
Julian Oes de0e467150 mavlink: bring buffering for log messages back 2016-03-24 13:10:02 +01:00
Julian Oes 1fc9b99307 commander: some rebase fixes 2016-03-24 13:10:02 +01:00
Julian Oes aecdd4e32f mavlink: add logging of mavlink messages back
The logging into a text file was commented out in the recent changes but
is added back in with this commit.
2016-03-24 13:10:02 +01:00
Julian Oes 198b8a299e mavlink: remove file added by accident 2016-03-24 13:10:02 +01:00
Julian Oes 4ed29bf66b mc_pos_control_multiplatform: comment mavlink_log
The mavlink log didn't seem to be used anyway. This should fix jenkins.
2016-03-24 13:10:02 +01:00
Julian Oes bba0d0384d drivers/modules: changes after mavlink_log change
The mavlink_log API changes lead to changes in all drivers/modules using
it.
2016-03-24 13:10:02 +01:00
Julian Oes b49b012d35 ringbuffer: update header file
The header file was not in source with the source file.
2016-03-24 13:09:16 +01:00
Julian Oes 2d4179a35b mavlink: refactor mavlink_log
This moves the mavlink_log interface from ioctl to uORB and enables the
mavlink statusmessage output for Snapdragon. The API changes will lead
to changes in all modules that are using it.
2016-03-24 13:09:16 +01:00
Julian Oes 790fa7667c commander: cherry-pick fixes 2016-03-24 13:08:31 +01:00
Julian Oes 37a1f6ea8d DriverFramework: updated submodule
This brings better support for device ids.
2016-03-24 13:08:31 +01:00
Julian Oes 88a812618c commander: fix the calibration for NuttX.
This fixes some regressions on the calibration using NuttX, especially
considering the PRIME param and the device ids.
2016-03-24 13:08:31 +01:00
Julian Oes d0e9ec0c67 commander: get PRIME parameter back
The PRIME param got lost on the way of the refactoring.
2016-03-24 13:08:31 +01:00
Julian Oes e949d6d18a commander: get PRIME parameter back
The PRIME param got lost on the way of the refactoring.
2016-03-24 13:08:31 +01:00
Julian Oes a6af53bcb4 df_mpu9250_wrapper: reset calibration if no params 2016-03-24 13:08:31 +01:00
Julian Oes 10ce1c19a2 mag_calibration: small fix for non QURT 2016-03-24 13:08:31 +01:00
Julian Oes 1b5210ca13 sensors/calibration: use params in DF wrappers
Instead of using a uORB topic with the calibration values published in
sensors and consumed by the DriverFramework driver wrappers, let's just
use the the params directly. This is quite a rough change and needs
definitely some cleanup and refactoring.
2016-03-24 13:08:31 +01:00
Julian Oes aa9d698204 mavlink_log: support telem printfs on QURT 2016-03-24 13:08:31 +01:00
Julian Oes 6a8bac2b30 df_hmc5883_wrapper: subscribe to calibration data 2016-03-24 13:08:31 +01:00
Julian Oes 23da6696d7 df_mpu9250_wrapper: comments only 2016-03-24 13:08:31 +01:00
Julian Oes c152f88f7f uavcan: fix after calibration refactor 2016-03-24 13:08:30 +01:00
Julian Oes e0c41632a6 drivers: some fixes for the calibration refactor 2016-03-24 13:08:30 +01:00
Julian Oes a8955553de hmc5883: missing semicolons 2016-03-24 13:08:30 +01:00
Julian Oes 8d096c4053 hmc5883: astyle 2016-03-24 13:08:30 +01:00
Julian Oes b9cc0b74e2 drivers: re-use calibration topic
E.g. instead of defining a gyro_scale struct in drv_gyro.h, use the
gyro_calibration message.
2016-03-24 13:08:30 +01:00
Julian Oes 98e407696e commander: whitespace only
Trailing whitespace all over.
2016-03-24 13:08:30 +01:00
Julian Oes f24b2a701f sensors: first part of a calibration refactor
This adds uORB messages to publish calibration data by sensors which is
then consumed by the sensors. Currently this is only used on Snapdragon
and guarded by QURT ifdefs.
2016-03-24 13:08:30 +01:00
Julian Oes a446a337e9 Revert "mavlink: send out parameters faster over UDP"
This reverts commit 213cdf1a91.

Raising the stream rate of param values had the nice effect that
receiving the params became really quick. However, on the downside it
set all other streams pretty slow. This needs to be fixed differently.
2016-03-23 11:46:25 +01:00
Julian Oes 2e3093cd8f sdlog2: put defines around QURT path 2016-03-22 22:22:30 +01:00
Julian Oes f006840f2a px4.config: remove rc_receiver
This was in there by accident.
2016-03-22 22:18:49 +01:00
Julian Oes 40c6ac94c7 cmake: include land_detector in QURT build 2016-03-22 22:12:40 +01:00
Julian Oes 4e1c6073ae px4.config: add SYS_AUTOSTART param for now 2016-03-22 21:28:15 +01:00
Julian Oes f06a27a53c posix-configs: unite mainapp-calib/mainapp-flight
There is no calibration config needed anymore.
2016-03-22 21:25:26 +01:00
Julian Oes e1aca91467 posix-configs: unite px4-calib and px4-flight
The calibration config is no longer needed.
2016-03-22 21:22:47 +01:00
Julian Oes d629f0912c px4-flight.config: add land_detector 2016-03-22 21:20:55 +01:00
Julian Oes bc85380439 px4-flight.config: fix rc_receiver command 2016-03-22 21:19:18 +01:00
Julian Oes 4a1e9d610b param_shmem: fix the "unknown param id" bug
The recent workaround to flag all params as used did not include
param_for_used_index(). However, this function got used in the case if
one param had not been received by QGC and was requested by its index.
2016-03-22 20:38:11 +01:00
Julian Oes acf9be488d Revert "px4flow: disable distance data transmission from px4flow sensor"
This reverts commit 47f79a66d1 because it
was just an intermediate debug commit.
2016-03-21 16:06:41 -04:00
Julian Oes a3967872f3 df_bmp280_wrapper: hack to publish altitude
Previously we only published pressure which wasn't inav for the position
estimator.
2016-03-21 11:38:07 +01:00
Julian Oes 8ea581189a DriverFramework: updated submodule
This brings various bugfixes for the framework, as well as Support for
RPi2 with Navio+.
2016-03-19 18:57:45 +04:00