Commit Graph

737 Commits

Author SHA1 Message Date
Andrew Tridgell 097632eeb3 AP_HAL: try to prevent use of double maths functions
this will help reduce the number of misuses of double precision maths
functions
2018-05-07 11:43:23 +10:00
Andrew Tridgell 84a4f9dc96 AP_HAL: added boost_end() method to Scheduler API
this allows for a better method of controlling main thread priority
2018-05-05 07:45:53 +10:00
Lucas De Marchi b54b95de12 AP_HAL: minlure: search for specific I2C controller
The number can change from one kernel version to another and even from
one boot to another. Find the I2C controller on sysfs and stick to that,
like it's done for PCA9685.
2018-05-04 11:47:04 -07:00
Lucas De Marchi 2000e17646 AP_HAL: move get_device() method from AP_HAL_Linux
This way it's possible to use the method in platform-independent code
without a need to up cast.
2018-05-04 11:47:04 -07:00
Lucas De Marchi 4f2498947b AP_HAL_Linux: remove redundant ifdef
CONFIG_HAL_BOARD_SUBTYPE should be set in the boards header.
2018-05-04 11:42:55 -07:00
mirkix ee86418587 AP_HAL: change PocketPilot to final baro sensor 2018-05-04 08:00:49 +10:00
night-ghost 9f1e45509a support for Matek F405-CTR board, causes minor changes in I2C descriptor block 2018-04-26 07:51:06 +10:00
Andrew Tridgell 33a26ac0a8 AP_HAL: enable DEVO telemetry on F4Light 2018-04-24 10:44:28 +10:00
Alexander Malishev ca33ff04d9 ChibiOS: add support for omnibusf4pro board 2018-04-14 09:25:15 +10:00
Andrew Tridgell 943e433be6 AP_HAL: added device name for bmp280 for ChibiOS 2018-04-12 11:50:44 +10:00
night-ghost 677fc1875b HAL_F4Light: some modes disabled by default 2018-04-11 10:13:08 +10:00
Andrew Tridgell a7711ab9f7 AP_HAL: don't require GPIO defines for RCOU serial on ChibiOS 2018-04-09 15:32:04 +10:00
Andrew Tridgell 0bb2c4564d AP_HAL: make hal aware of oneshot125
this separates oneshot and oneshot125 at the HAL layer, allowing the
HAL to properly handle the high timing resolution of oneshot125
(needed to use 125ns time steps, to get the full 1000 throttle steps)
2018-04-07 09:10:29 +10:00
Andrew Tridgell dacbef2120 AP_HAL: added get_esc_scaling() API for rcout 2018-04-07 09:10:29 +10:00
Andrew Tridgell 85ae6f60a8 AP_HAL: added UART locking interface
used to gain exclusive access to a UART. This is needed for the BLHeli
MSP protocol to prevent protocol corruption due to console writes
2018-04-07 09:10:29 +10:00
Andrew Tridgell 69c623270c AP_HAL: added telem request to RCOutput 2018-04-07 09:10:29 +10:00
Andrew Tridgell 74bf83c39f AP_HAL: added check for RCOUT serial support 2018-04-07 09:10:29 +10:00
Andrew Tridgell 7d3cce98d0 AP_HAL: allow override of MS5611 name
for fmuv4-beta
2018-04-07 09:10:29 +10:00
Andrew Tridgell d2075b4b67 AP_HAL: added irq save/restore API to hal.scheduler
these are used by RPM driver
2018-04-07 09:10:29 +10:00
Andrew Tridgell dcfec21b46 AP_HAL: added support for serial output to ESCs 2018-04-07 09:10:29 +10:00
Andrew Tridgell e7dc304f4e AP_HAL: support DShot output modes 2018-04-07 09:10:29 +10:00
Alexey Bulatov 4d08ec8c85 AP_HAL: Edge: set storage directory to /edge/ardupilot 2018-04-04 09:29:16 +09:00
kozinalexey 5df2b1a3ac chibios hal config for F4BY 2018-03-24 06:39:09 +11:00
Peter Barker 6c7c916c78 AP_HAL: eliminate AP_HAL::Print and AP_HAL::Stream
Just *way* too many layers involved here
2018-03-23 08:12:38 +11:00
Pierre Kancir f66c83a59e AP_HAL: fix FALLTHROUGH 2018-03-21 08:24:56 +09:00
LinJieqiang c73e7f0cf3 add IST8310 compass sensors in AP_Compass.cpp 2018-03-09 11:25:35 -08:00
night-ghost 7fad79ca81 HAL_F4Light: fixed parameter's numbers for some boards 2018-03-09 11:15:12 -08:00
Andrew Tridgell af8476ae08 AP_HAL: added DPS280 and FBM320 defines 2018-03-05 10:27:09 +00:00
Andrew Tridgell 64bda71da5 AP_HAL: added generic ChibiOS board type 2018-03-02 12:52:50 +11:00
Andrew Tridgell 3c0e5a315f AP_HAL: started on OMNIBUSF7V2 support 2018-03-02 12:52:50 +11:00
Andrew Tridgell 2b0a3272fd AP_HAL: support LPS25H on MPU AUX 2018-03-02 12:52:50 +11:00
night-ghost b773334008 AP_HAL_F4Light: disable AP_Stats to reduce flash degradation 2018-03-02 07:23:35 +11:00
Andrew Tridgell 60b6f4c11d AP_HAL: added crazyflie2 2018-02-14 18:27:00 +11:00
Andrew Tridgell 310acd333e AP_HAL: use 1/0 not HIGH/LOW for LEDs in ChibiOS 2018-02-14 18:27:00 +11:00
Andrew Tridgell ceeb5e6892 AP_HAL: use 1/0 not HIGH/LOW for LED polarity
this fixes the build for pixracerled driver on px4-v2
2018-02-14 18:27:00 +11:00
ljwang 59ee3c8f62 AP_HAL: support mini-pix 2018-02-14 18:27:00 +11:00
Tom Pittenger a2f1f63ab3 AP_HAL: add param defaults for EMLID_EDGE for GPS_TYPE=9 and CAN_DRIVER=1 2018-02-13 15:29:53 +11:00
Alexey Bulatov 8369f125ce AP_HAL: Edge: add define HAL_WITH_UAVCAN 2018-02-13 13:52:44 +11:00
murata 7be15cab45 AP_HAL: disable copter winch on f4light boards 2018-02-12 12:17:12 +09:00
mirkix 3aa211b325 AP_HAL: fix BeagleBone Blue external I2C number 2018-02-12 09:49:56 +09:00
Andrew Tridgell d5be04dc8f AP_HAL: fixed AP_MODULE_SUPPORTED 2018-02-10 10:50:22 +11:00
night-ghost f8569ac39e AP_HAL: added F4Light HAL 2018-02-10 09:14:41 +11:00
Andrew Tridgell f8e16008f6 AP_HAL: updated cypress radio bus pins for skyviper 2018-02-08 18:56:51 +11:00
Andrew Tridgell 6bc3d126bb AP_HAL: added sensor defines for BMM150 and ICM20789 2018-02-08 17:36:33 +11:00
Peter Barker beb5a41389 AP_HAL: add radio defines for PixHawk
This facilitates testing a diret-attached-radio using a PixHawk1

The AUX5 pin is used as an interrupt line.
2018-02-08 17:36:33 +11:00
Andrew Tridgell bc96cb8a19 AP_HAL: fixed build warnings 2018-02-07 20:33:45 +11:00
Siddharth Purohit 5bcbc4c142 AP_HAL: default to not UAVCAN support for chibios boards 2018-02-07 20:33:45 +11:00
Siddharth Purohit d539a157b7 AP_HAL: move to having ICanDriver as member instead of inheriting it
this is to support having drivers using libuavcan supplied helper objects, a method which can lead to much less duplication of code
2018-02-07 20:33:45 +11:00
Andrew Tridgell 5da17e5b60 AP_HAL: added MINIPIX board type 2018-02-07 20:33:45 +11:00
Andrew Tridgell 472ba5bde7 AP_HAL: make _timer_tick() in Storage available in all HALs
this makes using the Empty::Storage easier
2018-02-07 20:33:45 +11:00
Andrew Tridgell 3e65347b97 AP_HAL: added REVOMINI board type 2018-02-07 20:33:45 +11:00
Andrew Tridgell 5179d13dbf AP_HAL: added virtual _timer_tick method on UARTDriver
this is needed to allow HALs to update UARTs when the number of UARTs
they bhave varies (some may be instances of HAL_Empty)
2018-02-07 20:33:45 +11:00
Igor Anokhin 5cf15db966 AP_HAL: add LSM9DS1 defines
Add defines for name and number sensor
2018-02-06 09:31:26 -08:00
LukeMike bfcece7edd VRBRAIN / AP_HAL: some update for new VR Brain 5.2E (EEPROM version) 2018-02-05 08:26:49 +11:00
LukeMike dab8f93628 VRBRAIN / AP_HAL: changed vrbrain board configuration file 2018-02-05 08:26:49 +11:00
night-ghost 2065cc879c AP_HAL: mAG3110 driver 2018-02-02 21:07:40 +11:00
Lucas De Marchi 184b017b33 AP_HAL: fix warning from having undefined HAL_WITH_IO_MCU
In file included from ../../libraries/AP_IOMCU/AP_IOMCU.cpp:8:0:
../../libraries/AP_IOMCU/AP_IOMCU.h:10:5: warning: "HAL_WITH_IO_MCU" is not defined [-Wundef]
 #if HAL_WITH_IO_MCU
     ^
../../libraries/AP_IOMCU/AP_IOMCU.cpp:10:5: warning: "HAL_WITH_IO_MCU" is not defined [-Wundef]
 #if HAL_WITH_IO_MCU
     ^
And so on.
2018-02-02 09:11:46 +09:00
Andrew Tridgell 93a993c575 AP_HAL: setup RTSCTS and SBUS_OUT 2018-01-20 17:40:07 +11:00
Andrew Tridgell d030f2888b AP_HAL: added multi-object push to RingBuffer
this is much more efficient than pushing them one at a time
2018-01-20 17:40:07 +11:00
Peter Barker 87be7fea0c AP_HAL: added support for Sparky2 STM23F405 board 2018-01-20 17:40:07 +11:00
Nikita Tomilov a50e6c6dd7 AP_HAL: board: linux: Add default CAN interface name 2018-01-17 07:24:17 -08:00
Alexey Bulatov 09de8e852d AP_HAL: Make methods get_UAVCAN and set_UAVCAN pure 2018-01-17 07:24:17 -08:00
Andrew Tridgell 3f5534eed5 AP_HAL: use calloc in preferance to malloc 2018-01-17 11:22:05 +11:00
Andrew Tridgell 4322ef7ca4 AP_HAL: prevent valgrind errors in EKF
ensure that EKF memory is zero on start
2018-01-17 11:22:05 +11:00
Andrew Tridgell d2c04aa649 AP_HAL: moved board defines to hwdef.dat 2018-01-15 11:46:02 +11:00
Andrew Tridgell 2773b17fad AP_HAL: added support for AP_Terrain for ChibiOS 2018-01-15 11:46:02 +11:00
Andrew Tridgell c80149123f AP_HAL: use hwdef.h for config options in chibios 2018-01-15 11:46:02 +11:00
Andrew Tridgell 8699b6233a AP_HAL: support MindPX-v2 2018-01-15 11:46:02 +11:00
Andrew Tridgell c7fd455f6a AP_HAL: added FMUv4 port for ChibiOS 2018-01-15 11:46:02 +11:00
bugobliterator 9d6ab78376 AP_HAL: add support for memory allocation by region type 2018-01-15 11:46:02 +11:00
Andrew Tridgell 8260b3f65f AP_HAL: allow bus speed and SMBUS enable on I2C
this allows a driver to request a bus speed for a device, and whether
the device should be in SMBUS mode. It also allows a min timeout to be
specified, to allow for slow devices
2018-01-15 11:46:02 +11:00
Andrew Tridgell 347c774665 AP_HAL: fixed example build on ChibiOS 2018-01-15 11:46:02 +11:00
Andrew Tridgell 391affc02d AP_HAL: support ChibiOS 2018-01-15 11:46:02 +11:00
mirkix 0e7ade6f0c AP_HAL: add new board PocketPilot 2017-12-27 16:01:55 +00:00
Mark Whitehorn 66c4b7d986 AP_HAL: support SBusOut
rename enable_sbus_out to enable_px4io_sbus_out
2017-11-30 10:20:04 +11:00
HeBin 895b5f34b8 AP_HAL: add Robsense PhenixPro Devkit Board support 2017-11-22 10:10:21 -08:00
Chinese66 700aaf2e8f AP_HAL: add delay to UART_test example
For AC3.5 and higher version, serial uartA-USBconsole cannot work. Maybe the code before "setup" has been changed. Ensure that the uartA can be initialized
2017-11-22 09:05:17 +09:00
Georgii Staroselskii 6326e23682 AP_HAL: Navio: add defs for BoardLED 2017-11-17 09:20:55 -08:00
alexshirley 065b00eb81 AP_HAL: Remove SBUS macro from ocpoc target 2017-11-01 10:28:40 -07:00
Lucas De Marchi 7fd10921c3 AP_HAL: Linux: add define for storage dir
This mantains compatibility with what the boards were already using,
except for Aero and Minlure in which I'm changing it already as this is
desired.
2017-10-30 16:57:37 -07:00
Lucas De Marchi 591b846e2d AP_HAL: switch aero and minlure to new log/terrain directory
Additionally make Edge use the default.
2017-10-30 16:57:37 -07:00
Lucas De Marchi d2ba8409d0 AP_HAL: provide default directory for Linux boards
/var/lib/<project> is more in line to where projects save their data.
Also, remove APM from dir name as it should had been done some time
ago.

This is only the default (and recommended for any new board). Existing
boards that want to adopt the default can remove their defines.
2017-10-30 16:57:37 -07:00
Georgii Staroselskii 4e2028c32f AP_HAL: Edge: enable Heat PWM 2017-10-20 13:03:08 -07:00
Georgii Staroselskii db9f427617 AP_HAL: Edge: add compass settings
Use HMC5883L as default before UAVCAN Linux support is in place
2017-10-20 13:03:08 -07:00
Georgii Staroselskii 2dd68243a2 AP_HAL: add Edge support 2017-10-20 13:03:08 -07:00
Francisco Ferreira be1f0801a3
AP_HAL: stop defining a default Lightware I2C bus
When a specific bus isn't defined we now search I2C buses 0 and 1
2017-10-09 11:57:02 +01:00
Lucas De Marchi 7edde571e1 AP_HAL: RCOutput_Tap: make LEDs blink on non-Aero ESCs
The protocol defines bits for controlling possible LEDs. On Aero the ESC
firmware simply ignores these bits and blink with a fixed frequency.
Add logic to be able to blink the ESC if not flashed with the Aero
version of the firmware.
2017-09-28 08:59:52 -07:00
Lucas De Marchi 2c3054cbae AP_HAL: RCOutput_Tap: remove feedback from ESCs
This is not currently working on Aero, the only user of it right now,
and it has been commented out. Remove dead code.
2017-09-28 08:59:52 -07:00
Lucas De Marchi d3a1ed9792 AP_HAL: RCOutput_Tap: fix comment with protocol bits 2017-09-28 08:59:52 -07:00
Lucas De Marchi 58ae139b8f AP_HAL: add possible external compasses for aero 2017-09-27 09:25:34 -07:00
Andrew Tridgell 08344557d9 AP_HAL: fixed missing LPS25H define 2017-09-27 16:42:31 +10:00
fnoop 149188de12 AP_HAL: Add size() method to RingBuffer ObjectArray 2017-09-22 09:56:00 -07:00
fnoop 3ddd9a6bca AP_HAL: RingBuffer: Prefix private members with underscore 2017-09-22 09:55:49 -07:00
Lucas De Marchi 68b3e5ccab AP_HAL: aero: define uart RCOutput_Tap 2017-09-21 07:59:20 -07:00
Lucas De Marchi 51665a2ea9 AP_HAL: RCOutput_Tap: split baudrate set for Linux and Nuttx
On Linux (and in most of posix-like systems) the baudrate set in struct
termios via cfset[io]speed is actually the index of the standard
baudrates, it's not the baudrate per se (hence the use of B* macros).

On Linux it's possible to set the baudrate by passing the baudrate
itself to TCSETS2 ioctl.  Unfortunately it's not possible to include
asm/termbits.h and termios.h in the same compilation unit, so we need to
split it. Here we split into a Linux and a NuttX implementation.
2017-09-21 07:59:20 -07:00
Lucas De Marchi 58a76adc13 AP_HAL: RCOutput_Tap: allow different device to be used 2017-09-21 07:59:20 -07:00
Lucas De Marchi f6b1099896 AP_HAL: move in tap esc implementation
This can be shared with Linux.
2017-09-21 07:59:20 -07:00
Peter Barker 68652867e1 AP_HAL: make in_main_thread public, pure and virtual 2017-09-19 09:40:11 +10:00
Lucas De Marchi 13f4ba7392 AP_HAL: remove raspilot 2017-09-12 15:06:19 -07:00
Francisco Ferreira 51a8aa3d1f AP_HAL: remove URUS 2017-09-11 10:04:11 -07:00