Commit Graph

39 Commits

Author SHA1 Message Date
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 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
Lorenz Meier fa5071b3c5 Remove module.mk files to prevent confusion of adopters upgrading 2015-10-06 11:23:20 +02:00
James Goppert 1d6b31d196 Switch to cmake build system. 2015-09-07 20:37:45 -04:00
Lorenz Meier 18ee3a2bf9 BlinkM: Fix code style 2015-09-05 22:10:09 +02:00
Mark Charlebois a589d15c52 Refactored debug() and log() in CDev
These functions used vprintf which is not available on all platforms.
They also do not enable line and file debug output.

Changed to macros that preserve the output format.  Uses new macro that
can be used to implement per object, runtime selectable logging

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-08-11 12:07:06 -07:00
Mark Charlebois a0d58552a0 blinkm: merged NuttX and POSIX impelmentations
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-06 16:24:18 -07:00
Mark Charlebois 190814bc97 Merge remote-tracking branch 'upstream/master' into linux
Signed-off-by: Mark Charlebois <charlebm@gmail.com>

Conflicts:
	src/drivers/rgbled/rgbled.cpp
	src/modules/commander/PreflightCheck.cpp
	src/modules/commander/airspeed_calibration.cpp
	src/modules/commander/calibration_routines.cpp
	src/modules/commander/gyro_calibration.cpp
	src/modules/commander/mag_calibration.cpp
	src/modules/mc_att_control/mc_att_control_main.cpp
2015-04-28 11:48:26 -07:00
Lorenz Meier 346798b129 blinkm: Let user know that we just did not find one and this is not an error 2015-04-27 09:07:52 +02:00
Mark Charlebois d913ec8dc9 Changed device::px4_device_handle_t to device::file_t
This change allowed the _posix.cpp file changes to be merged
back into the original files.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-24 17:49:35 -07:00
Mark Charlebois f3b5076d70 Linux to posix conversion
Changed "linux" target to "posix". Most of the changes are shared with
QuRT and with OSX. The Linux specific parts are in for i2c which uses
<linux/i2c.h> and <linux/i2c-dev.h>.

There is also a check for __PX4_LINUX in mavlink for a tty ioctl that is
not supported.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-21 09:53:09 -07:00
Mark Charlebois 13d84ef17b Linux: I2C opens /dev/i2c-x
For now it uses the bus number as the id. Not sure how this should
actually be mapped.

Seems like the I2C devices come up in random order and have random
id but that a specific device can be found in the /sys/bus/i2c
interface.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-20 11:13:24 -07:00
Mark Charlebois df53defca6 Linux: Add support for blinkm to test I2C layering
Running the blinkm device to test I2C

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-20 11:13:24 -07:00
Mark Charlebois cd30b4d5ca Linux: added I2C class
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-20 11:13:24 -07:00
Mark Charlebois 9758112e31 Use px4_config.h instead of nuttx/config.h
Modified code to use OS independent header file for config settings.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-20 10:55:41 -07:00
Lorenz Meier 21bc9e4839 BlinkM: Move to 0-based index 2015-02-09 22:56:21 +01:00
Thomas Gubler 2d124852c1 propagate uorb contants change through all modules/drivers 2015-01-28 16:31:41 +01:00
Lorenz Meier c059fb03ea blinkm: Make driver flash efficient 2014-07-12 21:33:09 +02:00
Don Gagne b9299e68d4 Compiler warning fixes 2014-07-05 13:35:12 -07:00
Kynos 503ebddc1b Merged upstream master into gnss_rework branch 2014-06-30 01:34:12 +02:00
Kynos 9bad828bc0 U-blox driver rework, step 2
Moved satellite info from vehicle_gps_position_s into a new uORB topic
satellite_info.
Renamed satellites_visible to satellites_used to reflect true content.
sdlog2 will log info for GPS satellites only for now.
2014-05-30 14:30:25 +02:00
Julian Oes ed6c2a5168 commander and navigator: lot's of changes, failsafe handling in commander, navigator only for execution (WIP) 2014-05-27 21:56:32 +02:00
Lorenz Meier 227d52b02c blinkm: Remove the barrage of static variables in mainloop, eating up RAM for everybody 2014-05-13 08:04:53 +02:00
Anton Babushkin 88b18bbad1 ALTCTRL/POSCTRL renamed to ALTCTL/POSCTL 2014-05-11 13:35:05 +02:00
TickTock- 31089a290b Replaces poshold/althold with posctrl/altctrl 2014-04-28 21:47:45 -07:00
TickTock- 269800b48c renamed EASY to POSHOLD and SEATBELT to ALTHOLD 2014-04-27 14:06:00 -07:00
TickTock- 967e9b6878 Fixed blinkm state indication (was not properly reporting flight mode). Added flashing orange safety disarmed state indicator and solid blue failsafe indicator. Changed safety on state to solid cyan. Increased LiPo cellcount support to 6. 2014-04-16 21:41:00 -07:00
Julian Oes 55cfa5152c Made low/critical warnings consisting 2013-08-29 16:41:59 +02:00
Julian Oes 56575eb068 Merge remote-tracking branch 'px4/new_state_machine_drton' into fmuv2_bringup_new_state_machine_drton
Conflicts:
	src/drivers/blinkm/blinkm.cpp
	src/drivers/px4io/px4io.cpp
	src/modules/commander/state_machine_helper.c
	src/modules/px4iofirmware/protocol.h
	src/modules/px4iofirmware/registers.c
	src/modules/systemlib/systemlib.h
	src/systemcmds/reboot/reboot.c
2013-08-15 14:04:46 +02:00
px4dev 9d6ec6b365 Restructure things so that the PX4 configs move out of the NuttX tree, and most of the PX4-specific board configuration data moves out of the config and into the board driver.
Rename some directories that got left behind in the great board renaming.
2013-08-02 22:34:55 -07:00
Lorenz Meier 4e5eb9740b Fixed led and reboot linker challenges in C++ environments 2013-07-28 14:50:27 +02:00
Lorenz Meier eb52eae153 Code style for BlinkM 2013-07-20 13:48:19 +02:00
Julian Oes bcdedd9a35 Changed location of lots of flags and conditions, needs testing and more work 2013-07-16 18:56:31 +02:00
Julian Oes 1b38cf715d Renamed actuator_safety back to actuator_armed, compiling but untested 2013-07-15 22:15:15 +02:00
Julian Oes 202792294a Merge remote-tracking branch 'upstream/io_fixes' into new_state_machine
Conflicts:
	src/drivers/px4io/px4io.cpp
	src/modules/commander/commander.c
	src/modules/commander/state_machine_helper.c
	src/modules/commander/state_machine_helper.h
	src/modules/px4iofirmware/mixer.cpp
	src/modules/uORB/topics/actuator_controls.h
	src/modules/uORB/topics/vehicle_status.h
2013-06-18 15:35:26 +02:00
Julian Oes 90f5e30f2a Introduced new actuator_safety topic 2013-06-14 13:53:26 +02:00
Lorenz Meier 4ef87206ec Code formatting and warning fixes 2013-06-09 14:03:49 +02:00
Julian Oes f5c157e74d Merge remote-tracking branch 'upstream/master' into new_state_machine
Conflicts:
	src/drivers/px4io/px4io.cpp
	src/modules/commander/commander.c
	src/modules/commander/state_machine_helper.c
2013-05-17 11:24:02 +02:00
Lorenz Meier 5974c37abb Moved the bulk of sensor drivers to the new world 2013-04-27 14:06:23 +02:00