Commit Graph
100 Commits
Author SHA1 Message Date
Julian Oes 6c61b67fd5 shmem: fix eagle build 2016-05-05 14:28:35 +02:00
Julian Oes bdaa1b58f6 uart_esc: fix eagle build 2016-05-05 14:28:20 +02:00
Julian Oes 3e165c51d4 cmake: copy over changes that rebase missed 2016-05-05 09:14:11 +02:00
Julian Oes efd20373ff cmake: re-use the QURT build as well
Instead of calling the eagle cmake script from excelsior, use a shared
sdflight cmake file like in it is done for the POSIX build on
Snapdragon.
2016-05-05 09:12:46 +02:00
Julian Oes 805ef9fff1 cmake: added some comments about eagle/excelsior 2016-05-05 09:11:59 +02:00
Julian Oes 01ad1b642b Makefile: whitespace only 2016-05-05 09:11:29 +02:00
Julian Oes 0c5c111cdd cmake: no param sculling for all eagle configs 2016-05-05 08:09:59 +02:00
Julian Oes aafcae7e6f MPU9250: integrate using the FIFO sample interval
Instead of calculating time offsets between samples, it is easier just
to assume a constant sampling time. Then all samples can be integrated,
and published every forth time the FIFO buffer has been emptied.

The sampling in the sensor happens at 8kHz, the driver empties the
buffer at 1kHz, and publishes (and resets the integration) at 250 Hz.
2016-05-04 22:28:19 +02:00
Julian Oes f528c63030 integrator: add a put method for known intervals
This adds a second put method to the integrator class. This allows to
integrate with known intervals between samples, rather than based on
timestamps. This makes integrating the samples coming out of the MPU9250
FIFO buffer easier.
2016-05-04 22:28:19 +02:00
Julian Oes a6e1df06d9 Merge pull request #4422 from PX4/fix_snappy_muorbinit
muorb: call `initialize()` before `get_instance()`
2016-05-03 15:51:21 +02:00
Julian Oes ef6892a885 sdlog2 bugfix of vehicle_status conflicting with commander_state (#4402)
* sdlog2: move from STAT.MainState to COMM.MainState

This fixes a bug where vehicle_system_status and the commander internal
state were conflicting.

This will need adaptations in logging tools.

* sdlog2: don't bother changing STAT.MainState

For compatibility reasons, let's stick to the used log field (but still
fix the bug where the buffer (union) was overwrittern.
2016-04-29 17:16:45 +02:00
Julian Oes eb1ab4011a sensors: the ifdef logic was inverted (#4401) 2016-04-29 16:21:52 +02:00
Julian Oes 49ae3e17d5 land_detector: fix wrong astyle formatting (#4399) 2016-04-29 15:36:18 +02:00
Julian Oes 234068989b sensors: treat RPi like QURT 2016-04-29 13:50:18 +02:00
Julian Oes 08f88d006f sensors: use the empty sensor init for RPi as well
The RPi build is based on the same DriverFramework base like the QURT
build, therefore it should use the same empty sensor init function.
2016-04-29 10:02:53 +02:00
Julian Oes 0c0d251003 Intersil wrapper continued
* Qflight: add intersil sensor driver

* df_isl_wrapper: change driver lib name to isl

* posix-config: add df_isl_wrapper start command to eagle startup

* isl_wrapper: cleanup isl wrapper

* isl: remove unused option -R

* isl: change the driver name to isl29501

* DriverFramework: updated submodule again

This is to get the latest `make fix-style` changes.

* df_isl29501_wrapper: rename wrapper all the way
2016-04-28 15:31:40 +02:00
Julian Oes 99286cf1bd ekf2: replace !isnan with PX4_ISFINITE (#4374) 2016-04-26 22:15:30 +02:00
Julian Oes ea3adee28a shmem_qurt: fix format 2016-04-26 10:23:39 +02:00
Julian Oes e3c9135ac2 param_shmem: fix bug where params didn't stick
There was the case where a param was changed on the Linux side but the
change did not get saved on the DSP side because the param was not in
the local list of changed params on the DSP side. On save, the param
index is now refreshed, and param_get is called on all params that have
changed. This is a hacky workaround but resolves the problem for now.
2016-04-26 10:21:01 +02:00
Julian Oes f454d74a51 mavlink: fix Snapdragon build 2016-04-25 15:35:22 +02:00
Julian Oes 2e476ce6bf gps/devices: updated submodule
This includes the mtk bugfix for Snapdragon.
2016-04-25 06:21:36 -07:00
Julian Oes 5e5af9c37f posix px4_layer: fix Mac build 2016-04-25 06:21:36 -07:00
Julian Oes ee57055b99 posix px4_layer: fix linking error on QURT 2016-04-25 06:21:36 -07:00
Julian Oes c975d01200 gps: fix Snapdragon build 2016-04-25 06:21:36 -07:00
Julian Oes 0031220c1a df_mpu9250_wrapper: add reporting for range hits
We now send log messages over mavlink in case excessive vibrations are
detected.
2016-04-25 12:48:48 +02:00
Julian Oes 84c87696fe df_mpu9250_wrapper: use the elapsed counter 2016-04-25 12:48:48 +02:00
Julian Oes 20e494410a df_mpu9250_wrapper: add an info function 2016-04-25 12:48:48 +02:00
Julian Oes 23f882063e df_mpu9250_wrapper: also free the perf_counters 2016-04-25 12:48:48 +02:00
Julian Oes 1cf7de8fdb perf_counter: perf_print_counter now works on QURT 2016-04-25 12:48:48 +02:00
Julian Oes d55b4802f1 df_mpu9250_wrapper: add perf counters 2016-04-25 12:48:48 +02:00
Julian Oes 4ac67f69d1 DriverFramework: updated submodule
This brings the latest renamed counters.
2016-04-25 12:48:48 +02:00
Julian Oes 944acfaf75 simulator: change after perf_counter API change 2016-04-25 12:48:48 +02:00
Julian Oes fa6fe4ca96 px4io: small change after perf_counter API change 2016-04-25 12:48:48 +02:00
Julian Oes 662c097803 perf_counter: add function to set a count
This needed the set function which sets elapsed to change the name to
avoid ambiguities.
2016-04-25 12:48:48 +02:00
Julian Oes 08a1941fd6 df_mpu9250_wrapper: fix style 2016-04-25 12:48:48 +02:00
Julian Oes 75444ae084 df_mpu9250_wrapper: use FIFO time offsets
- Make use of the FIFO time offsets provided by the MPU9250 driver.
  It allows to use proper dt for the integration.
- Got rid of the unnecessary perf_counters for now.
- Properly use the changed integrator lib.
- Provide integral_dt for ekf2.
2016-04-25 12:48:48 +02:00
Julian Oes d824ca3a14 integrator: fix style 2016-04-25 12:48:48 +02:00
Julian Oes 544f0b70a9 DriverFramework: updated submodule
This brings error counters and timestamp offsets between FIFO samples.
2016-04-25 12:48:48 +02:00
Julian Oes 302bf879de integrator: improvements and cleanup
The integrator had an untested read mode which did not apply the coning
correction. Instead of keeping two integrals (auto/read) it is now one
and the reset mechanism can be selected by setting the
auto_reset_interval to 0 to disable it or some positive number else.

Also, the integrator could potentially explode if a (single) timestamp
was wrong, so before the last integrated one. This is now caught with a
dt of 0 instead of inf/nan.
2016-04-25 12:48:48 +02:00
Julian Oes f91be1e281 DriverFramework: updated submodule
This raises the sampling frequency from 500 Hz to 8kHz using the FIFO
buffer.
2016-04-25 12:48:48 +02:00
Julian Oes a302e79bb6 param_shmem: be less chatty, printf cleanup 2016-04-24 20:03:10 +02:00
Julian Oes 92afa7c258 mag_calibration: bugfix for device ID of mag
The device ID is defined as a uint32_t in the driver and topic but
stored as a int32_t param. It is therefore sufficient if the device ID
is not 0 in order to be valid.
2016-04-24 17:07:37 +02:00
Julian Oes 8e5091703c commander: no message due to LED/buzzer not found
The LED init and Buzzer init messages were only annoying and not helpful
on Snapdragon and SITL. Therefore they are replaced with only developer
printfs.
2016-04-21 21:22:52 +02:00
Julian Oes 88626cf5f1 px4io: remove leftover printf 2016-04-21 13:34:46 +02:00
Julian Oes 482ce55d57 px4io: allow 0 as a PWM signal 2016-04-21 13:32:38 +02:00
Julian Oes d5cc9e0873 snapdragon_rc_pwm: allow the driver to be stopped 2016-04-21 13:00:08 +02:00
Julian Oes 91133021d6 posix/qurt cmake: fix eagle upload 2016-04-19 15:10:43 +01:00
Julian Oes 0438bf6a8b mavlink: get the ifdefs correct 2016-04-12 10:13:52 -07:00
Julian Oes 72be6de0cf mavlink: whitespace fix 2016-04-12 10:13:52 -07:00
Julian Oes 361c057412 mavlink: get mavlink reconnection working 2016-04-12 10:13:52 -07:00
Julian Oes 22847e49e7 param_shmem: fix style 2016-04-12 13:15:50 +02:00
Julian Oes 9cfffc9747 param_shmem: do fsync after param write 2016-04-12 13:15:50 +02:00
Julian Oes 015d7431a7 sdlog2: comment fix 2016-04-12 13:13:50 +02:00
Julian Oes 1aa45cede8 sdlog2: workaround for Snapdragon
This fixes an issue where topics where not subscribed to on the Linux
side on Snapdragon. It's a hack until there is a proper fix for the
orb_exists() call.
2016-04-12 13:13:50 +02:00
Julian Oes fbd7c73043 drv_hrt: fix comment 2016-04-12 08:56:34 +02:00
Julian Oes 6abc55c303 navigator: whitespace 2016-04-11 18:01:49 +02:00
Julian Oes 34e504aec5 navigator: fix after rebase 2016-04-11 18:01:49 +02:00
Julian Oes c9ac9c7dbd commander: fixes after rebase 2016-04-11 18:01:49 +02:00
Julian Oes 32f2b89252 sdlog2: comment fix 2016-04-11 18:01:49 +02:00
Julian Oes 3c9f9540dc commander: add failsafe flag back in 2016-04-11 18:01:49 +02:00
Julian Oes 11c2b6784d msg: fix comment in commander_state 2016-04-11 18:01:49 +02:00
Julian Oes 974223bdd1 commander: pass battery status to preflight check
A low battery check was recently added to the preflight check, therefore
we need to pass on the information about the battery.
2016-04-11 18:01:49 +02:00
Julian Oes 68a69c9d46 cmake: add commander_state message to ROS build 2016-04-11 18:01:49 +02:00
Julian Oes a325b77adf ros-commander: refactor changes 2016-04-11 18:01:49 +02:00
Julian Oes 3b806235ac sdlog2: compile fixes after rebase 2016-04-11 18:01:49 +02:00
Julian Oes 50c36296fa navigator: compile fixes after rebase 2016-04-11 18:01:49 +02:00
Julian Oes 08ce231d76 ekf2: compile fixes after rebase 2016-04-11 18:01:49 +02:00
Julian Oes e91f587438 commander; various compile fixes after rebase 2016-04-11 18:01:49 +02:00
Julian Oes 9859d43fe2 frsky_telemetry: fixed build 2016-04-11 18:01:49 +02:00
Julian Oes 05d64b3342 navigator: fix for vehicle status refactor 2016-04-11 18:01:49 +02:00
Julian Oes 03a0788207 fw_pos_control_l1: fix for vehicle status refactor 2016-04-11 18:01:49 +02:00
Julian Oes f21f82223c ekf2: fix stupid bug caught by travis on Mac 2016-04-11 18:01:49 +02:00
Julian Oes be2fe78c82 commander: publish internal state 2016-04-11 18:01:48 +02:00
Julian Oes 315c202824 sensors: removed more leftover variables 2016-04-11 18:01:48 +02:00
Julian Oes c87fa43b68 sensors: removed unused variable 2016-04-11 18:01:48 +02:00
Julian Oes 9512a71cf8 commander: cleanup the status messages 2016-04-11 18:01:48 +02:00
Julian Oes 2cd05dea4d commander: try different mavlink include 2016-04-11 18:01:48 +02:00
Julian Oes 5ca5af5fcd commander: take main_state out of vehicle_status
This state is only commander internal. Therefore it doesn't need to be
in vehicle_status. Instead it is now in the commander_state message.
2016-04-11 18:01:48 +02:00
Julian Oes 1ad0ee0fae mc_att_control: don't use main state for RATTITUDE
Instead of the state use the boolean flags.
2016-04-11 18:01:48 +02:00
Julian Oes 5c9713f05b commander: try to get the travis include right 2016-04-11 18:01:48 +02:00
Julian Oes 70cff975cc commander: move some flags out of vehicle_status
All the removed flags were not used anywhere else than inside the
commander.
2016-04-11 18:01:48 +02:00
Julian Oes 0988fef831 commander: forgot to close fd 2016-04-11 18:01:48 +02:00
Julian Oes 23df992cc5 commander: moved offboard bools into status_flags
The offboard status bools were not used anywhere but in the commander.
Therefore they are now moved to the local status_flags topic.
2016-04-11 18:01:48 +02:00
Julian Oes a11a986df8 mavlink: removed leftover debug printf 2016-04-11 18:01:48 +02:00
Julian Oes 1f44fb1efd commander: internalize system status bools
Most condition bools in the commander are not used anywhere but in the
commander. It therefore makes sense to move them to a different internal
struct and remove them from the vehicle_status message.

Also, the land_detected should be used by all the modules instead of
getting it through the commander and system_status.
2016-04-11 18:01:47 +02:00
Julian Oes 705979e3c7 simulator: use new battery systemlib 2016-04-11 18:01:47 +02:00
Julian Oes 2dfc644f17 sensors: only publish battery topic if valid 2016-04-11 18:01:47 +02:00
Julian Oes 4ddd1bbf03 battery: fix segfault
The name was set NULL which lead to a segfault on POSIX.
2016-04-11 18:01:47 +02:00
Julian Oes 141b984d5b commander: take previous main state out of status 2016-04-11 18:01:47 +02:00
Julian Oes 181eb49da8 commander: remove calibration_enabled
This flag is not used anywhere, it therefore doesn't need to be in
vehicle_status.
2016-04-11 18:01:47 +02:00
Julian Oes fe85841a1d commander: remove counter
The counter variable in system status wasn't used anywhere.
2016-04-11 18:01:47 +02:00
Julian Oes 1cc43a00d6 battery: astyle 2016-04-11 18:01:47 +02:00
Julian Oes 76c66a4e92 frsk_telemetry: astyle 2016-04-11 18:01:47 +02:00
Julian Oes 69b0b75151 px4io: astyle 2016-04-11 18:01:47 +02:00
Julian Oes 32c3135788 commander: move battery calculations to systemlib
The commander used to consume the battery_status topic and write the
contents after some calculations into the system state. Instead, the
calculations now happen in library calls in systemlib/battery.

This moves the battery fields out of the vehicle_status message into the
battery_status topic.

This brought quite some changes in all modules that need battery
information. The current state is compiling but untested.
2016-04-11 18:01:47 +02:00
Julian Oes 699b08c9fd commander: move battery warning
The battery warning is not consumed anywhere, therefore scrap it from
the vehicle_status message.
2016-04-11 18:01:47 +02:00
Julian Oes 8e9e9f8a8b vehicle_status: move vtol_vehicle_status enum
It makes more sense to have the VTOL status in its own message.
2016-04-11 18:01:47 +02:00
Julian Oes 74072dbe74 vehicle_status.msg: delete unused mavlink stuff
The MAV_TYPE enum was not in sync with the mavlink specs anymore. It
makes therefore sense to remove the duplication and include the correct
mavlink header file where it is needed.
Also, error counts which are not populated, can be scrapped.
2016-04-11 18:01:47 +02:00
Julian Oes 5f3a23a253 commander: remove circuit breakers from status msg
Since the circuit breaker bools are not actually used anywhere else than
in the commander, it is safe to remove them and replace them with local
bools.
2016-04-11 18:01:47 +02:00
Julian Oes 441d7aacbb gps: fix build, unused var ERROR 2016-04-11 13:51:04 +02:00