Commit Graph

106 Commits

Author SHA1 Message Date
Andrew Tridgell d7d87f827e HAL_PX4: support voltage monitoring on multi-connector pin 5 2013-06-05 08:24:20 +10:00
Andrew Tridgell 2316c3bd11 AP_HAL: make storage->write_block() take a const pointer 2013-06-04 14:02:13 +10:00
Andrew Tridgell e391c34d1e AP_HAL_PX4: fixed indent-tabs-mode 2013-05-30 09:54:53 +10:00
Andrew Tridgell 2c149bac8e HAL_PX4: added new arming ioctls 2013-05-16 16:43:38 +10:00
Andrew Tridgell a5b20b4dfc AP_HAL: removed scaling factor on analog sources
these are not use anymore, as voltage_average() is used instead
2013-05-13 15:29:42 +10:00
Andrew Tridgell 589b8cdb58 AP_HAL: added voltage_average_ratiometric() call to AnalogIn
this is for ratiometric sensors such as the 3DR airspeed sensor and
the Maxbotix analog sonar
2013-05-13 15:12:43 +10:00
Andrew Tridgell 172faeea26 HAL_PX4: moved rc.APM to new ROMFS directory 2013-05-10 06:16:54 +10:00
Andrew Tridgell b3e21c6add HAL_PX4: include visibility.h
needed for new nuttx structure
2013-05-10 06:16:53 +10:00
Andrew Tridgell 9cd0af1132 HAL_PX4: make PX4 snprintf support %S format
just maps it to %s for normal printf
2013-05-08 16:17:06 +10:00
Andrew Tridgell 9bc48c9894 HAL_PX4: fixed build with new AnalogIn API
pin settle times not actually implemented on PX4 yet
2013-05-03 10:09:02 +10:00
Andrew Tridgell ccd38e58a1 HAL_PX4: fixed the scaling on the analog pins 2013-05-02 21:40:15 +10:00
Randy Mackay bbbd90c430 AP_HAL: rename RCInput's valid() fn to valid_channels 2013-04-29 15:05:53 +09:00
Andrew Tridgell ec1678db83 HAL_PX4: setup for 12 output channels
moved telemetry port to /dev/ttyS2 to free PWM outputs on FMU
2013-04-25 20:10:53 +10:00
Andrew Tridgell 709615159a HAL_PX4: support 12 output channels with PX4IO
first 8 on IO board, next 4 on FMU outputs
2013-04-25 20:10:53 +10:00
Andrew Tridgell af7381e9e0 AP_HAL: added register_io_process()
this is used to register a low priority IO task. Used for file IO in
DataFlash_File.cpp
2013-04-17 21:33:50 +10:00
Andrew Tridgell d01d754ba8 HAL_PX4: if we have lost RC input then set channel 3 to 900
this allows failsafe to kick in
2013-04-15 10:52:32 +10:00
Andrew Tridgell 6ddb99a50b HAL_PX4: create APM/boot.log on SD card
useful for debugging
2013-03-21 15:05:21 +11:00
Andrew Tridgell cc932973d6 HAL_PX4: remove the need for the fmu_only flag file 2013-03-21 15:05:21 +11:00
Andrew Tridgell 8766e86091 HAL_PX4: fixed blocking bulk writes to UARTs
this fixes a problem with uBlox initialisation on PX4
2013-03-20 15:41:52 +11:00
Andrew Tridgell 14911eff6c HAL_PX4: added a (disabled) trick for handling blocking ttyACM0
this doesn't work yet, but is worth having for debugging
2013-03-20 11:20:43 +11:00
Andrew Tridgell 93fc9c48e5 HAL_PX4: fixed startup bug in fmu_only mode 2013-03-19 07:57:13 +11:00
Andrew Tridgell ac69a531d3 HAL_PX4: workaround problem with APM file on SD card
this works around file redirection bug from earlier firmwares
2013-03-18 13:12:17 +11:00
Andrew Tridgell 6a1aad30f1 HAL_PX4: auto-create APM directory on SD card 2013-03-16 19:47:09 +11:00
Andrew Tridgell b1c27407a2 AP_HAL: added voltage_average() interface to AnalogIn
returns voltage in Volts, using averaged reading over samples.

Where possible this should be auto-scaled against a known reference
voltage
2013-03-03 16:16:01 +11:00
Pat Hickey e0457f21de AP_HAL_PX4: fix off-by-one error in RCOutput channel sending 2013-02-23 15:04:17 -08:00
Andrew Tridgell c373429a6e HAL_PX4: fixed a buffer handling bug
BUF_SPACE() was badly buggy, which could lead to memory corruption
2013-02-20 18:15:56 +11:00
Andrew Tridgell 160e5fa311 HAL_PX4: show a message if we fail to upgrade PX4IO firmware 2013-02-20 18:15:23 +11:00
Andrew Tridgell 02c5c3ec4a HAL_PX4: changed scheduler priorities
put sensor priority above main sketch, to prevent occasional blocking
for sensor data
2013-02-20 11:30:54 +11:00
Andrew Tridgell 54e7bce75e HAL_PX4: cope with O_NONBLOCK not working in NuttX on ttyACM0
writes will block anyway, which clags up APM
2013-02-19 12:02:46 +11:00
Andrew Tridgell 8041768c67 HAL_PX4: perform automatic update of px4io firmware 2013-02-18 13:55:58 +11:00
Andrew Tridgell 8e2a20bea8 HAL_PX4: enable ttyACM0 as main console, ttyS1 as telemetry port 2013-02-18 13:55:33 +11:00
Andrew Tridgell e45b137816 HAL_PX4: added run_debug_shell() implementation for PX4 2013-02-07 15:04:33 +11:00
Andrew Tridgell 4fd7630ec9 HAL_PX4: IO_SET_FEATURES is not needed any more 2013-01-27 15:05:28 +11:00
Andrew Tridgell 8375abdd99 HAL_PX4: fixed max storage write size 2013-01-27 15:04:47 +11:00
Andrew Tridgell e4a204d2f6 HAL_PX4: reopen storage file on any IO error 2013-01-27 13:39:11 +11:00
Andrew Tridgell 90e264d56a HAL_PX4: disable manual override in PX4 for now 2013-01-27 12:52:14 +11:00
Andrew Tridgell 02b4ecc273 HAL_PX4: get RC input from PX4IO board
this allows us to support DSM and SBUS receivers
2013-01-27 12:52:14 +11:00
Andrew Tridgell d7409b6a25 HAL_PX4: startup in low priority to fix CLI
this ensures that tight sensor loops in setup() can run without
sleeping
2013-01-25 20:44:36 +11:00
Andrew Tridgell 7359348e2c HAL_PX4: added support for /fs/microsd/APM/nostart
prevents APM startup
2013-01-25 20:44:36 +11:00
Andrew Tridgell 8f2f4b1bc5 HAL_PX4: use write() to /dev/pwm_output for servo output
this lowest the cost of PWM output a lot, but relies on the new I2C
based IO firmware
2013-01-25 20:44:36 +11:00
Andrew Tridgell f9d43f4c3e HAL_PX4: prevent loop() overruns using hrt
this ensures if loop() takes more than 1 second, the main task gets
its priority dropped until loop() completes
2013-01-24 15:04:57 +11:00
Andrew Tridgell 70227d5d93 HAL_PX4: added scheduler performance counters 2013-01-24 15:04:57 +11:00
Andrew Tridgell 0e79b93289 HAL_PX4: added storage performance counters 2013-01-24 15:04:57 +11:00
Andrew Tridgell fc8065b50f HAL_PX4: added UART performance counters 2013-01-24 15:04:57 +11:00
Andrew Tridgell 6cf1d5e1ff HAL_PX4: handle IO errors on microsd
this should handle EINTR gracefully
2013-01-24 15:04:57 +11:00
Andrew Tridgell 966b9b9b9c HAL_PX4: format panic messages with a newline 2013-01-23 16:54:44 +11:00
Andrew Tridgell c9799fb2b7 HAL_PX4: writing more than 512 bytes at a time can cause IO errors
the vfat fs in NuttX is really very picky!
2013-01-23 16:54:44 +11:00
Andrew Tridgell 952df2fced HAL_PX4: new buffered storeage driver for microsd cards
this does all IO in the timer thread, avoids writes that don't change
data, and does all writes in multiples of 128 byte chunks. This should
be about as friendly to SD cards as we can get.
2013-01-23 16:37:40 +11:00
Andrew Tridgell f72b532405 HAL_PX4: ensure all writes go via buffers
this prevents output corruption by direct fd writes
2013-01-23 09:22:51 +11:00
Andrew Tridgell 2a10727902 HAL_PX4: run timer thread as SCHED_FIFO
this ensures it never yields to the main thread, which would break our
locking assumptions
2013-01-23 09:21:50 +11:00