Commit Graph

13783 Commits

Author SHA1 Message Date
Lucas De Marchi
d3e9f7ce66 AP_HAL: add HAL_PX4_HAVE_PX4IO 2017-03-24 12:06:19 +11:00
Lucas De Marchi
7f5b551050 AP_HAL: add HAL_PX4_HAVE_MTD_SUPPORT 2017-03-24 12:06:19 +11:00
Lucas De Marchi
c7fc3ffbc4 AP_HAL: add HAL_HAVE_BOARD_VOLTAGE 2017-03-24 12:06:19 +11:00
Lucas De Marchi
37a050eed9 AP_HAL: add comments and allow for board overrides 2017-03-24 12:06:19 +11:00
Lucas De Marchi
2e4e4365d0 AP_InertialSensor: enable fast sampling for aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
9a83f05714 AP_BoardConfig: enable voltage monitoring on aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
7c1f255258 AP_HAL_PX4: add pin to monitor battery 2017-03-24 12:06:19 +11:00
Lucas De Marchi
5787b5a5c5 AP_Compass: IST8310: rename macros
Having "BIT" in the name gives the impression we are using the macro is
the bit position; however they have the values for those actions, not
the bit position. Rename BIT to VAL to be less confusing.
2017-03-24 12:06:19 +11:00
Lucas De Marchi
4bba643abb AP_Compass: IST8310: use variable periodic callback
This is the equivalent of sleep and wait for the conversion time,
after had triggered a new sample request. However it also has the added
benefits of sharing a thread with other sensors on the same bus.

Now we don't read the status register anymore since we have a guaranteed
wait time.
2017-03-24 12:06:19 +11:00
Lucas De Marchi
ce1a13aa8f AP_Compass: IST8310: use FSR to reject samples 2017-03-24 12:06:19 +11:00
Lucas De Marchi
d84851d8fa AP_Compass: IST8310: improve initialization
- Make sure device is reset while initializing.
 - Give better names to register macros
 - Average X, Y and Z by 16: sensor is internally running at 200 sps
   (theoretical, ~160 pratical). The wait time is ~6msec averaging
   by 16. We do 10msec.
2017-03-24 12:06:19 +11:00
Tom Pittenger
c0691afc1f AP_Compass: reject outlier data in IST8310 data by detecting >14bit data 2017-03-24 12:06:19 +11:00
Lucas De Marchi
91dabbe418 AP_HAL_PX4: implement method to ajust periodic callback
Just setting up the periodic callback sampling time on initialization
may not work well for sensors that need to request for a sample with a
bus transaction, sleep and then read the new data. That's because the
function will be kept calling at a periodic rate, while the time in
which we can read the value is not really that sampling time, but rather
the time in which sensor was last read + the time spent in the function
before sending a new sample request.

Instead of creating a new type of thread to handle this case, just
implement the minimal and easy case of updating the period for this
callback, that can only be called from inside the callback function.
2017-03-24 12:06:19 +11:00
Tom Pittenger
8415fde697 AP_Compass: IST8310 chip does not follow right-hand rule format, flip z 2017-03-24 12:06:19 +11:00
Lucas De Marchi
b339050e45 AP_Compass: IST8310: account for errors in measurment requests
If we don't recover for errors in the request for new sample, we may get
stuck with no sample anymore. Recover from bad transfers.
2017-03-24 12:06:19 +11:00
Lucas De Marchi
2349909033 AP_BoardConfig: start mtd driver 2017-03-24 12:06:19 +11:00
Lucas De Marchi
da68612f4b AP_BoardConfig: make error function public and static
So it can be used by other parts of the code calling px4_start_driver().
2017-03-24 12:06:19 +11:00
Tom Pittenger
fb24a03faf AP_Baro: don't compile drivers for devices that don't use them 2017-03-24 12:06:19 +11:00
Lucas De Marchi
156efd6fec AP_Compass: use IST8310 for aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
fad583b259 AP_HAL_PX4: RCOoutput_Tap: map to [ RPMSTOPPED, RPMMAX ] range
When it's not armed we get _esc_pwm_min from the AP_Motors library,
which would cause motors to start spinning.  Map it to start from
RPMSTOPPED so it doesn't spin when it's not armed.
2017-03-24 12:06:19 +11:00
Lucas De Marchi
5e26940070 AP_HAL_PX4: disable safety switch for aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
a682bb837a AP_SerialManager: uartA with 460800 baud for aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
20c5e9ec08 Add support for external mag on aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
327de91b5c AP_HAL_Px4: use RCOutput_Tap for aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
75977cd890 AP_HAL_PX4: implement motor output for aerofc
This uses tap ESCs, as found on the PX4 project, translated to our
internal APIs. It doesn't have the feedback from ESCs yet.
2017-03-24 12:06:19 +11:00
Lucas De Marchi
ce9013b8ee AP_HAL_PX4: add RCOutput skeleton for aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
87846fe049 AP_InertialSensor: use MPU6500 on aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
b4d0569339 AP_HAL_PX4: Use empty RCOutput driver for aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
00c2949dfb Add support for baro on aerofc 2017-03-24 12:06:19 +11:00
Lucas De Marchi
b17acfee12 Add aerofc support
Flight Controller board that comes on Intel Aero RTF Drone.
2017-03-24 12:06:19 +11:00
Andrew Tridgell
2d603c1cba SRV_Channel: fixed reversing on servo gimbals 2017-03-23 11:02:07 +09:00
Jacob Walser
1b00dfb642 AP_GPS: Fix parameter metadata 2017-03-22 16:16:26 -07:00
Jacob Walser
a9a8521383 AP_OpticalFlow: Fix parameter metadata 2017-03-22 16:16:26 -07:00
Jacob Walser
646d68c76d AP_NavEKF2: Fix parameter metadata 2017-03-22 16:16:26 -07:00
Jacob Walser
84e5e088de AP_BoardConfig: Fix parameter metadata 2017-03-22 16:16:26 -07:00
murata
1a781f44cc AP_Notify: Correct the display area clear of the text message. 2017-03-22 01:24:21 +00:00
Francisco Ferreira
c0238be345
AP_FrSky_Telem: fix sending messages 3 times
Initialize variable
Also some small style changes
2017-03-22 01:23:26 +00:00
Florent Martel
02c0885cfd AP_Frsky_Telem: fixes #5862
MAVLink strings of exactly 50 characters are not NULL terminated, so
instead we must check that the 50th character has been reached.
2017-03-22 01:22:14 +00:00
Siddharth Bharat Purohit
5029dd1bab AP_HAL_PX4: GPIO: return correct FMU pin read even if IO not connected/detected 2017-03-22 12:15:05 +11:00
Michael du Breuil
2aec41e0ef AP_HAL_SITL: Fix SIM_GPS_DISABLE not disabling the ublox GPS with PVT support 2017-03-19 23:13:11 -07:00
Eugene Shamaev
41fe4d0515 AP_Landing: fix to remove reorder warning 2017-03-20 07:32:36 +11:00
Pierre Kancir
1a374aa9f6 SIM_Gazebo: add a timeout to reset timestamp check 2017-03-18 19:58:11 +11:00
Pierre Kancir
d4a0a92b8b SITL: cmdline reorder help and param for better readability and futher extension
add missing options
2017-03-18 19:58:11 +11:00
Pierre Kancir
29d35699f2 SITL: Gazebo, throw old paquet based on timestamp as we are using UDP
Add some comments
2017-03-18 19:58:11 +11:00
Pierre Kancir
d612209c19 SITL: Gazebo fix implicit cast 2017-03-18 19:58:11 +11:00
Pierre Kancir
ee7355a301 SITL: Reduce some variables scope and include 2017-03-18 19:58:11 +11:00
Pierre Kancir
8054405521 SITL: Change interface port to a generic solution for external simulator 2017-03-18 19:58:11 +11:00
Pierre Kancir
6e0319d513 SITL: Add RCout port option to cmdline 2017-03-18 19:58:11 +11:00
Pierre Kancir
a8d5079a38 SITL: Ensure that Instance parameter don't override manualy setted port 2017-03-18 19:58:11 +11:00
Tully Foote
25fad0a8c2 SITL: Add more command line arguments for port selection. 2017-03-18 19:58:11 +11:00