There are many settings falling into the RC_* category
that definitely should be reset when e.g. placing the autopilot
into a new airframe.
And even for RC calibration values: it's not the worst
if those are newly calibrated after a reset. Or if they
are not expected to change one can bake them into the
airframe file.
Signed-off-by: Silvan <silvan@auterion.com>
* sensors: add per-receiver GPS delay parameters
Add SENS_GPS{0,1}_DELAY params to vehicle_gps_position, following the
same device-ID matching pattern used for antenna offsets. Each receiver
can now have its own measurement delay relative to the IMU.
The delay is applied to timestamp_sample before blending. When PPS time
correction is active it takes priority over the parameter-based delay.
When a GPS driver already provides its own timestamp_sample the
per-receiver delay is not applied on top of it.
* fix(ekf2): remove EKF2_GPS_DELAY and perform param transation
* fix(param_translation): fix GPS param migration return values
Add missing return for EKF2_GPS_POS_Z and remove incorrect return for
EKF2_GPS_DELAY (1-to-many migration should not return PARAM_MODIFIED).
* fix(sensors,ekf2): rename pps_compensation and clarify delay default
* fix(ekf2): account for SENS_GPS*_DELAY in observation buffer sizing
* fix(docs): migrate EKF2_GPS_DELAY param
* sensors: move GPS antenna offsets to per-receiver parameters
Move antenna position configuration from the single EKF2_GPS_POS_X/Y/Z
parameter set into per-receiver SENS_GPS{0,1}_OFF{X,Y,Z} parameters in
the sensors module. Each offset slot is matched to a physical receiver
by device ID (SENS_GPS{0,1}_ID), falling back to uORB instance index
when no IDs are configured.
The antenna offset is now carried through the SensorGps uORB message
and blended alongside other GPS states when multi-receiver blending is
active, so EKF2 receives the correct lever arm for whichever receiver
(or weighted combination) is selected.
- Add antenna_offset_{x,y,z} fields to SensorGps.msg
- Remove EKF2_GPS_POS_X/Y/Z params; EKF2 reads offset from gnssSample
- Add SENS_GPS{0,1}_ID and SENS_GPS{0,1}_OFF{X,Y,Z} params (module.yaml)
- Blend antenna offsets in GpsBlending (weighted average)
- Add unit tests for single, blended, and failover antenna offset cases
- Migrate params.c to module.yaml for the vehicle_gps_position module
* sensors: gps_blending: add asymmetric weight and fallthrough offset tests
Add two additional antenna offset test cases:
- dualReceiverAsymmetricWeightAntennaOffset: verify that unequal eph
values produce correctly skewed blend weights (0.8/0.2) and that the
output antenna offset reflects the weighted average
- blendingFallthroughAntennaOffset: verify that when blending is enabled
but can_do_blending evaluates false (eph=0), the non-blending path
correctly assigns the selected receiver's antenna offset
* feat(param_translation): translate EKF2_GPS_POS_ to SENS_GPS0_OFF_
* fix(msgs): proper formatting
* chore(msg): 0 if invalid/unknown
* fix(ROMFS): migrate EKF2_GPS_POS_ params
* fix(docs): migrate EKF2_GPS_POS_ params
* fix(blending): unsigned param
* Update msg/SensorGps.msg
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* fix(sensors/gps): remove 'values:' tag in module.yaml
* fix(sensors/gps): unsigned instance index
* fix(blending): restore const on gps_blend_states()
Move antenna offset blending into blend_gps_data() where the
weights are computed, keeping gps_blend_states() const.
* fix(sensors/gps): fix msg annotation and restore SENS_GPS_PRIME values
Remove incorrect @invalid NaN annotation from antenna offset fields
(0.0 default is correct, not a sentinel). Restore values tag for
SENS_GPS_PRIME so QGC shows a dropdown.
* fix(gps_blending): fix pre-existing bug to clear _gps_updated flags
The loop iterates over i but always clears gps_select_index. The intent is to clear
all updated flags, but only the selected one gets cleared (N times)
* test(gps_blending): add stale update flag regression test
* fix(rcS): reset the flight mode assignments during an airframe reset
because there are many products that have a default flight mode assignment in the airframe file and if the user resets to airframe defaults the flight mode assignment stays custom and doesn't get reset to "factory settings". It's neither a unit specific calibration nor a parameter to track total flights or flight time. I suggest to reset it as well.
* fix(posix rcS): sync airframe reset with the px4 common startup script
to make simulation testing of an airframe reset more realistic.
* removed commented out parts
* changed the height controller to work in Altitude mode and moved the controller to the uuv_pos_control.hpp instead of uuv_att_control.hpp
* Updated format changes etc. Removed one parameter, that is not used anymore(UUV_HGT_MODE) added my correct email
* added a rotation to the thrust, that with different roll and pitch values, x y z thrust is still working as if roll/pitch is zero.
* fixed constant roll/pitch to be 0.0 again
* added parameter for maximum distance between controlled des height and current height.
Added state observation to reset the desired height to current height when altitude mode is turned on.
* added first short descriptions of manual modes.
* update descriptions
* removed vector dependency
* feat: updated gz submodule
* fix: newline
* fix: gz submodule
---------
Co-authored-by: Pedro Roque <roque@caltech.edu>
* moving raptor
bump
compiles and raptor mode appears
hovering with RAPTOR seems to work
Using Raptor to execute offboard commands works (using multirobot f03825a5795a77c5a095f799eeb8e0b646fe7176 to feed the trajectory_setpoint). Requires more testing
simplified rotmat
runtime inference frequency multiple
arming request response reflects actual readiness
adjusting to fit IMU gyro ratemax
relaxing control timing warning thresholds for SITL
Using mode registration to signal if offboard commands should be forwarded to trajectory_setpoint instead of just hardcoding vehicle_status.nav_state == vehicle_status_s::NAVIGATION_STATE_OFFBOARD
adopting new "request_offboard_setpoint" in raptor module
replace offboard seems good
mc_raptor: overwrite offboard parameter
separate raptor config
addendum
Raptor off by default
RAPTOR readme
Loading raptor checkpoint from tar works.
check if load was successful
refactoring: cutting out the pure C interface to allow direct testing of the policy input/output behavior from the file, without fully loading it into memory first
adapter not needed anymore
ripping out test observation mode (not used in a long time)
fixing warnings
bump RLtools to fix the remaining warnings
Loading RAPTOR checkpoint from sdcard seems to work on FMU-6C
embedding Raptor policy into flash works again
also printing checkpoint name when using the embedded policy
cleaner handling of the checkpoint name
back to reading from file
ripping out visual odometry checks
cleaner
more debug but no success
bump rlt
bump
pre next rebase
we can publish the no angvel update because we latch onto it with the scheduled work item anyways
this kind of runs on the 6c
still bad
SIH almost flying
saving stale traj setpoint yaw
new error. timestamp not the problem anymore
bump rlt; SIH works with executor
shaping up
bumping blob (include tar checkpoint)
cleaning up
fixing formatting
update readme
* moving raptor
bump
compiles and raptor mode appears
hovering with RAPTOR seems to work
Using Raptor to execute offboard commands works (using multirobot f03825a5795a77c5a095f799eeb8e0b646fe7176 to feed the trajectory_setpoint). Requires more testing
simplified rotmat
runtime inference frequency multiple
arming request response reflects actual readiness
adjusting to fit IMU gyro ratemax
relaxing control timing warning thresholds for SITL
Using mode registration to signal if offboard commands should be forwarded to trajectory_setpoint instead of just hardcoding vehicle_status.nav_state == vehicle_status_s::NAVIGATION_STATE_OFFBOARD
adopting new "request_offboard_setpoint" in raptor module
replace offboard seems good
mc_raptor: overwrite offboard parameter
separate raptor config
addendum
Raptor off by default
RAPTOR readme
Loading raptor checkpoint from tar works.
check if load was successful
refactoring: cutting out the pure C interface to allow direct testing of the policy input/output behavior from the file, without fully loading it into memory first
adapter not needed anymore
ripping out test observation mode (not used in a long time)
fixing warnings
bump RLtools to fix the remaining warnings
Loading RAPTOR checkpoint from sdcard seems to work on FMU-6C
embedding Raptor policy into flash works again
also printing checkpoint name when using the embedded policy
cleaner handling of the checkpoint name
back to reading from file
ripping out visual odometry checks
cleaner
more debug but no success
bump rlt
bump
pre next rebase
we can publish the no angvel update because we latch onto it with the scheduled work item anyways
this kind of runs on the 6c
still bad
SIH almost flying
saving stale traj setpoint yaw
new error. timestamp not the problem anymore
bump rlt; SIH works with executor
shaping up
bumping blob (include tar checkpoint)
cleaning up
fixing formatting
update readme
updating gitignore
* fixing format and declaring submodules as cmake dependencies
* adding uORB message documentation
* fixing comment alignment
* Adding option to restrict mc_raptor to not listen to the trajectory_setpoint (use the position and yaw at activation time as reference instead)
* bump RLtools; relax timing thresholds and adding real world readme
* smooth traj tracking performance
* Measuring trajectory_setpoint timing (providing stats in raptor_status); reverting accidental .gitignore modification
* More ideomatic way of setting the path to the policy checkpoint
* Reset trajectory_setpoint on raptor mode activation
* Adding internal trajectory generation (feeding trajectory_setpoint over Mavlink is too noisy). Quite agile trajectory tracking, good performance
* stable flight
* Update msg/versioned/RaptorInput.msg
Co-authored-by: Hamish Willee <hamishwillee@gmail.com>
* adopting message formatting conventions
* sort raptor.px4board
* Archiving RegisterExtComponentRequestV1.msg
* Add message versioning for VehicleStatus v2 and RegisterExtComponentRequest v2
* fixing formatting
* making internal reference configurable via command
* RAPTOR docs wip
* raptor internal reference documentation
* Finishing RAPTOR docs first draft
* adding logging instructions
* Fixing missing command documentation test error
* fixing format
* adding motor layout warning
* raptor minimal subedit - prettier, images etc
* Improve intro
* Fix up Neural_Networks version
* Mentioning "Adaptive" in the RAPTOR documentation's title
* Adding clarifications about the internal reference trajectory generator
* Removing "foundation policy" wording
* Fixing new-line check
* Removing redundant (evident through directory hierarchy) raptor_ from filenames
* Unifying Neural Network docs (mc_nn_control and mc_raptor) under the "Neural Network" topic
* Fix to standard structure
* Making the distinction between mc_nn_control and mc_raptor more clear and fixing the comparison table
* Removing trajectory_setpoint forwarding flag from external mode registration request and from the vehicle status
* Trivial layout and wording fixes
* fixing docs error
---------
Co-authored-by: Hamish Willee <hamishwillee@gmail.com>
* feat: added driver for tmp102 temperature sensor
* style: removed new line
* style: adjusted date in header
* style: removed duplicated logging
* fix: moved start-up command from rc.board_sensors to rc.sensors
* style: used consexpr for expected config reg value
* feat: added retry logic to probe function
* style: added _ as prefix to global variable
* style: used make format
* fix: corrected temperature calculation
* fix: mask AL-bit in probe function
* style: removed header files from CMakeLists
* style: used correct english in comments
* refactor: return error right after failure
* style: moved init call to correct place
* fix: corrected temperature calculation (again)
* refactor: removed _curr_pr variable => always have to set PR to desired register on read
* fix: add multi logged topic
I don't think we should change the logging profile based on the type of
airframe configured. Instead, this is an option you set based on the
phase of development/testing you're in.
This came up because the KakuteH7v2 which is 4050 by default would log
excessively which is not a good idea with only 128 MB flash storage.
* init: working towards dual-action ATMOS
* fix: update gz sim to latest
* fix: add motor number max fitting Actuator
* fix: revert non-necessary changes
* fix: ensure esc count does not exceed maximum number of ESCs
* feat: update gz to latest, includes ATMOS dual action
* fix: restore dds_topics
* fix: update gazebo model commit
* tla2528 basic implementation (restarting driver still fails)
* fixed probe function, restarting driver now works
* -added reset call to init
-added return value checks on all important transfers and retry if failed when possible
-removed comments
-removed unnecessary parameters of module
* Introduced initialization-states that can be executed multiple times on failure
* Added one more state s.t. init() only does probing
* added communication error count _comms_errors
* use get() instead of param_find
* changed scheduling interval
* start in reset state. check second byte in probe. add 2 retries to probe function
* add space in front of comments
* jump to reset state when another state fails
* changed SAMPLE_INTERVAL to 10_ms
* added static assert on number of channels in adc_report
* ROMFS: do not exit airframe loading if SYS_AUTOSTART is 0
Do not treat 0 as a magic value that skips the aiframe loading.
Instead leave it tot he rc.autostart to load an airframe that if finds
appropriate (can be defined in external aiframe).
Signed-off-by: Silvan <silvan@auterion.com>
* ROMFS: adjust airframe load spacing and message/comment wording
---------
Signed-off-by: Silvan <silvan@auterion.com>
Co-authored-by: Silvan <silvan@auterion.com>
* s32k3xx: EMIOS allow independent frequencies for each channel
* mr-canhubk3: update config
* mr-canhubk344: Fix adap board detect
* mr-canhubk344: Use LPSPI1 (Port P1A) for SD card
* airframes: Add B3RB Ackermann rover config
See https://nxp.gitbook.io/mr-b3rb for more information about the NXP
B3RB platform. PX4 Support basic control for now
In an effort to reduce configuration space.
I've not seen use for this option.
If a pilot flies manually in position mode he has some visual reference of the vehicle and can do better than an autonomous mode without position reference.
Also by now we have nudging in Descend mode so the pilot can still give input and the only difference is it automatically goes down instead of the pilot having to descend by stick to land.