1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2024-12-02 10:24:11 +01:00
Commit Graph

1133 Commits

Author SHA1 Message Date
peabody124
1142b1fb1e PiOS/USB_HID: No longer clear buffer after getting a NAK. This was required
before because if transmission got NAK then sending would stop.  Now the next
time data is added to the buffer a new send will be attempted.

fifoBuf: in clearData just set the read pointer to the write pointer.  This is
safer for multiple people accessing it assuming the reader will be clearing it.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2279 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-24 17:16:04 +00:00
peabody124
ba8351f60a PiOS/USB_HID: When using FreeRTOS use a sempahore to stop multiple tasks
pushing data to the transmit buffer

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2278 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-24 17:15:59 +00:00
pip
d072c30ba1 Settings additions.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2274 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-22 22:16:44 +00:00
cwabbott
7715a6d6cd PiOS.win32: Add MMCSS support for Vista onward, and smarter priority boosting to XP. Also, add the Actuator module and the fake pios_servo.c. If you run this using Windows 7 or Vista, then you need to run OpenPilot.exe as administrator once to set up the registry.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2270 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-22 14:47:42 +00:00
zedamota
14ef24a3de OP-21/Bootloader - Maximize flash space available for user code. Bring back delay on HID send (board->pc) it still hangs when blasted with data. AHRS is now Readable.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2263 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-21 17:25:24 +00:00
edouard
d8edab8371 Added a (fake) pios_servo module in PiOS.posix, this makes it possible to compile the Actuator module and see servo output values, or at least
what they would be on a real board. Also fixed a typo in stabilization.c which made me lose time when trying to understand the code...




git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2260 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-20 16:38:17 +00:00
osnwt
801568269c 2251 rev changes reverted. Let someone change UAVObjects to provide calibrated altitude and/or offset to HomeLocation and/or take off location (which can be quite different including elevation). But please do not forget that many of users do not have the GCS with Internet at field and/or do not have sufficient weather/baro/altitude condition info for their country. So the solution should provide also a way to 'drive-power-launch'.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2259 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-20 05:20:06 +00:00
corvus
1aa6a206db Sim_Posix: Updated Makefile to include some recently changed/new UAVObjects
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2253 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-19 11:29:24 +00:00
osnwt
7d084aca49 Added power-up barometric altitude calibration. Height accuracy is not sufficient, for better results we may want some filtering and/or another sensor/ADC. But at least now the BaroAltitude.Altitude object provides meaningful data comparing to uncalibrated zero height.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2251 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-18 23:40:17 +00:00
zedamota
7f00e88321 OP-21/Bootloader - House cleaning only, shouldn't brake anything.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2250 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-18 20:41:13 +00:00
cwabbott
0b985b2168 PiOS.win32: Various fixes to get it working again, added a sim_win32 option to the main makefile.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2249 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-18 18:41:37 +00:00
pip
e84b222272 PipX modem settings update .. note that they do not yet function.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2248 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-18 13:54:35 +00:00
peabody124
ac24d86f40 AHRS Makefile: PT accidentially turned on DEBUG=YES when checking in
FirmwareIAP to get me back for breaking Sys_Reset.  You got me! :)

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2246 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-18 08:56:12 +00:00
peabody124
f010502229 PiOS/I2C: Was throwing out repeated byte transmitted events but this is
required for longer sequences,  Need to deal with when it happens
inappropriately better.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2245 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-18 07:09:34 +00:00
peabody124
af99c31a61 PiOS/I2C: Fixed typo and also the values for I2C Diagnostics when disabled.
Enabled by default though.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2243 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-18 07:09:28 +00:00
zedamota
917f03121d Fixes a problem with the reset function introduced on the new ST libs migration, it was preventing the user space reset used with the bootloader to function properly.
I think someone still likes to honor his avatar :)

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2241 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-17 14:16:58 +00:00
peabody124
4b4a66c2d7 PiOS/I2C: Lots of small changes. Added a few weird bus events that are
sometimes thrown, and made errors not lock it up by default.  It works for me,
but since this has historically been associated with lots of lock ups please
check your systems carefully.

PiOS/I2C: Make the bus by default try to recover from errors instead of locking
up

PiOS/I2C: After a bus error and clocking all previous data create a STOP
condition to make sure bus is released (note, this also requires creating a
START condition first)

PiOS/I2C: If the same event hits the I2C bus twice in a row then disregard
second one, there is no situation where we should get the same event multiple
times that matters and this gets us out really quickly to catch the real
events.  I was seeing this with repeated 0x70084 which means byte transmitted.
This is related to STM32 bugs in the IRQ timings I believe.

PiOS/I2C: 1) Mask out some bits we don't care about in the event flags
2) Don't lock up if the give semaphore fails, although why it does is strange
3) Recover from bus failure through the "auto" state path instead of just
coding state

PiOS/I2C: Change the reset bus code to follow
http://www.analog.com/static/imported-files/application_notes/54305147357414AN686_0.pdf
(thanks for the reference Neontangerine).  Although this may actually NOT clear
the bus the first time through, subsequent bus errors should eventually clock
it out.  The up side is it is less likely to clock a bunch of 1s into an ESC
and make it run up.

PiOS/I2C: Some cleaned up code for getting a snippet of the history when
something strange happens

PiOS/I2C: Export logging information from I2C through a UAV object

PiOS/I2C: Improve the diagnostic information

PiOS/I2C: Need to handle the event 0x30084.  This seems to happen between a
byte transmitted and new byte started

PiOS/I2C: Handle the NACK condition by simply going to the stopping state.

PiOS/I2C: Add a new NACK state to handle sending the STOP signal after a NACK
following the STM documentation.  Other error conditions still are not dealt
with.

PiOS/I2C: Should handle the NACK condition from all the write cases.  Need to
think about read cases

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2239 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-17 07:01:58 +00:00
zedamota
c034a35d2c OP-21/Bootloader - Changes to the IAPObject. Implements MB and AHRS user mode IAPObject. Added user mode reset command to the CLI. To many changes to bootloading system to write here, a Wiki page will have to be writen.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2238 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-15 19:06:28 +00:00
peabody124
08e888ac8c Bootloader: Don't make it hang in bootloader by default. That's mean PT!
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2236 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-14 01:59:15 +00:00
peabody124
36ea75bc0d Flight/HID: Change how the HID code handles the transmit buffer getting empty
and starting transmission again.  This should address the bootloader locking up
on verify.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2235 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-14 01:43:16 +00:00
edouard
4be34fdb0f Modified all channel naming internally to use Channel 1 to Channel 8, instead of the previous convention of Channel0 to Channel7.
BEWARE: I have not flown my quad with this code, so please be careful, test, and report!



git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2234 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-13 23:54:30 +00:00
peabody124
68c656a724 AHRS: Add back the old 13 state INS if wanted and also code for tracking accel
bias as gravity vector facing down (bad for planes) which is diabled by
default.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2232 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-13 15:15:50 +00:00
peabody124
1086a6b567 Flight: Changes to STM library to work with our code. Basically all the
configuration structures are const which keeps them in flash instead of ram.
However the library needs to declare them const for the compiler to work.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2231 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-13 07:03:28 +00:00
peabody124
18858571ce Flight: Updated to the latest StdPeriph libraries
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2230 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-13 07:03:24 +00:00
peabody124
9250470c98 Guidance: In velocity control use maximum groundspeed to cap the velocity
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2229 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-13 07:03:04 +00:00
pip
9ceda82fba Updated UAVObjects
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2227 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-12 18:26:51 +00:00
pip
d5f6504aa2 Updated UAVObjects
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2224 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-12 18:16:24 +00:00
pip
b4e4d4ed5e Adding PipX modem settings/status UAVObjects
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2219 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-11 10:56:42 +00:00
pip
8b2e1c32d7 Adding PipX modem settings/status UAVObjects
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2218 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-11 10:56:33 +00:00
peabody124
f30aa1d719 AHRS Comms: Send FirmwareIAP object to AHRS so that it can be remotely
rebooted.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2214 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-10 21:03:29 +00:00
zedamota
cc5a4c2bb9 OP-21/Bootloader - NOT FUNCTIONAL
Implements RS232(Telemetry) uploads using Kokomo's protocol.
This is a test version, the code will never timeout and jump to user space code.
If USB is connected on Power Up it will be used, if not RS232 will be used instead.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2211 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-10 19:11:29 +00:00
peabody124
fd10c6ffff Guidance: Small sign error
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2209 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-10 17:14:35 +00:00
peabody124
d218e18ded AHRS: Make arm timeout of 0 disable feature for planes. Don't want them arming
out.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2205 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-08 20:07:34 +00:00
pip
5e91f46633 Added more telemetry baudrate options
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2198 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-06 08:31:24 +00:00
pip
49e99ea180 Added more telemetry baudrate options
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2195 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-06 08:23:20 +00:00
peabody124
e6a21977f1 OP-156 AHRS: Make the account for the fact the analog data is downsampled two
times for each EKF update

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2193 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-04 18:13:08 +00:00
peabody124
4e8c6588b6 OP-156 AHRS: Run the accel data through a fifo so it can output raw data faster
than the ekf runs and also be more tolerant of timing jitter

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2191 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-04 17:34:29 +00:00
peabody124
45e3ed27a7 OP-156 AHRS_ADC: Make the ADC system use a callback to better separate ADC code
from the AHRS code (which will facilitate code integration with new INS) and
also will help set up a fifo queue for the downsampled data to allow gyro data
output from AHRS faster than EKF output.  Also decreased ADC interrupt priority
so the SPI comms don't drop out.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2190 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-04 17:34:27 +00:00
peabody124
6f1e7b4e41 AHRS: Add a configuration to export the sensor data either with or without INS
bias correction.  This is useful for stabilization to get rid of the gyro bias.
Making it an option is important for calibration.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2189 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-04 17:34:25 +00:00
peabody124
81b2f88e75 AHRS: Swap to new code which tracks accel_bias and export the accelerometer
bias

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2188 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-04 17:34:22 +00:00
peabody124
e861bcb9d0 Flight/Guidance: Convert PositionPID mode to PositionPI + Velocity feedback.
Needs AHRS with accel_bias estimation to behave well.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2187 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-04 17:34:19 +00:00
peabody124
0679e8d472 AHRS: In indoor mode correct with a high variance 0 for position to keep it
bounded.  Velocity variance still comes from AHRSCalibration.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2186 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-04 17:34:18 +00:00
peabody124
a04e33ccc6 OP-192 Flight/ManualControl: Add an ArmedTimeout field to the
ManualControlSettings so that planes can disable the timeout
feature for gliding (holding roll on a plane not so good).

Note: This will require you to reconfigure your ManualControlSettings

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2185 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-04 17:34:16 +00:00
dschin
f99eb5b0c7 No changes to mainline code.
Three files added to  AHRS which add accelerometer biases (16 states) to the INS/GPS.  Added for evaluation (give it a try James).

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2182 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-02 02:39:01 +00:00
peabody124
4f21bee0d7 OP-192 Flight/ManualControl: Correctly convert to ms in timeout code so system
will automatically disarm after 30 seconds without motor.  This behavior will
need to be parameterized for planes which might idle for a while.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2181 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-12-01 22:12:01 +00:00
dschin
18809ce3dc AHRS - fixed time constant of baro altitude offset filter, added the offset to the EKF dump
Added new EKF data parser (m-file) to ground



git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2178 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-29 23:28:38 +00:00
peabody124
74249f8e41 OP-171 AHRS: I was flipping sign of baro when putting into INS but shouldn't
have been.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2175 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-29 08:44:43 +00:00
peabody124
f51a5a824e AHRS: Export the bias drift corrected gyro values to OP so stabilization see
more accurate roll rates

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2174 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-29 08:44:41 +00:00
pip
0cae6df8b0 Aligned fifo buffers to 32-bit for possible speed improvement.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2173 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-28 11:06:45 +00:00
pip
d4c24de556 Updated to use the new fifo_init function
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2172 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-28 11:00:20 +00:00
pip
912ba59cf9 You now supply a buffer address and buffer size when initializing the fifo buffer.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2171 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-28 10:59:24 +00:00
andrew
c94c76ce40 Minor change to give back manual control to an axis when it is set to stabilization = None
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2165 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-27 04:03:37 +00:00
edouard
b840c5ec40 Update ActuatorSettings to remove obsolete fields.
YOU WILL NEED TO RECONFIGURE YOUR ACTUATORS!



git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2162 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-26 20:55:05 +00:00
peabody124
75363896fb AHRS: In outdoor mode when no GPS for a few seconds start updating with zero
velocity to help stabilize attitude.  In principle the mag should be fine but
in practice I need this.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2160 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-26 15:57:14 +00:00
peabody124
b3251e2cfb AHRS: Accidentally was using mags when in indoor_nomag mode
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2159 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-26 15:57:13 +00:00
peabody124
6a33043297 AHRS: Tweak setting when mag is used to allow greater error in vector length
and start using from power up

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2158 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-26 15:57:12 +00:00
peabody124
e3d2645dea AHRS: Small bug in the conditions for using the mag
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2157 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-26 15:57:10 +00:00
peabody124
ebcb272da6 AHRS: Add a separate parameter for velocity and position variance and remove
indoor from the name since it's used for both indoor and outdoor mode now.
Increased default value to 0.4 to better reflect the GPS accuracy.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2156 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-26 15:57:08 +00:00
peabody124
ac734d5f65 AHRS: Move structure definitions out of main code. Organized variable scopes
properly.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2155 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-26 15:57:06 +00:00
peabody124
44069e64bc AHRS: Separated out code for debugging output from the main code and cleaned up
how various sensors are used in the INS update.  Also added slow filter to
track offset between GPS and baro in outdoor mode.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2154 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-26 15:57:04 +00:00
peabody124
444dd5c311 AHRS: Split various update modes into individual functions
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2153 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-26 15:57:03 +00:00
dschin
b2a538375c Changes in files supporting AHRS for new initialization methods.
Changes in ahrs.c for new initialization and to fix issues with outdoor algorithm.  The changes in ahrs.c are pretty messy, but committed mostly to get the code to Peabody for more extensive restructuring of ahrs.c.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2150 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-24 01:27:43 +00:00
peabody124
cfbdad5e0d Flight/USB_HID: Change to deal with buffer filling up when GCS not ACK'ing the
usb transmissions.  Clear TX buffer after any NAK.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2147 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-23 19:29:10 +00:00
peabody124
88a0ede73b OP-203: Flight/AHRS: Add fifo_buffer dependency for pios_usart
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2146 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-23 18:19:58 +00:00
peabody124
8ea727d10c AHRS/Makefile: Remove trailing CR
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2145 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-23 18:19:56 +00:00
peabody124
e89911bb8a OP-203 PIOS_USART: Don't disable interrupts for receive buffer since
only one receive task.  This is less generally safe but decreases the
frequency of resets in our current configuration

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2144 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-23 17:13:49 +00:00
peabody124
a454f06bf8 OP-203 PIOS_UART: Tweaked the way the interrupts are reenabled to get comms
stable again

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2143 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-23 17:13:48 +00:00
peabody124
300a3bc8ad OP-203 PIOS_USART: Get TX buffer using fifo_buffer
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2142 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-23 17:13:46 +00:00
peabody124
e3dd542609 OP-203 PIOS_USART: Make USART Rx code use fifo_buffer
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2141 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-23 17:13:44 +00:00
peabody124
d2b468d661 Flight/Stabilization: Need to either set or clear the alarm, but the way it was
before cleared at the end of each loop - including one after an alarm

Flight/Actuator: Similar change to make sure not having updates from
stabilization (i.e. no AHRS) doesn't trigger a watchdog reset

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2140 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-23 17:13:42 +00:00
zedamota
d57441e8f4 OP-21/Bootloader - forgot to commit this too..sorry (check last commit)
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2137 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-21 22:58:14 +00:00
zedamota
98b0f406dc OP-21/Bootloader - fixes GPS connected issues, enhances timings problems, further work on serial support
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2136 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-21 19:37:40 +00:00
osnwt
ed49f7fc40 Prevent some compiler warnings treated as errors during RELEASE build (possible use of uninitialized variables - CodeSourcery under Windows build system). It may be done with some #pragma as well, but this way is more portable.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2132 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-21 13:09:05 +00:00
cwabbott
2dde28843b PiOS/win32: UAVObject fixes.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2114 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-13 15:46:37 +00:00
peabody124
54aa09ce27 OP-163 Flight/Guidance: Take current position as desired position
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2111 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-12 16:57:16 +00:00
peabody124
6ebc8ccd57 OP-163 Flight/Guidance: Add variations on position hold to try out. Only one will end
up in the final code.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2110 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-12 16:57:13 +00:00
peabody124
5850c1804d OP-199 Flight/Stabilization: Increment a counter in actuatorDesired whenever an
update takes longer than 15 ms

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2109 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-12 04:36:04 +00:00
sambas
c74c9cc08e OP-73 Flight/PiOS: deinits started, still just for review
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2107 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-11 20:38:44 +00:00
sambas
f94dc41712 OP-73 Flight/PiOS: runtime RC input change, initial files just for review, not integrated to build yet
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2106 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-11 19:09:39 +00:00
corvus
bb1b6d8b8d sim_posix: added missing UAVobject source file to Makefile
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2086 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-06 15:33:54 +00:00
peabody124
834eecfc1f OP-200 Flight/Watchdog: Have flag that is set from actuator, ahrs_comms, manual
and stabilization that is monitored by watchdog.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2078 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-05 14:28:21 +00:00
peabody124
f950b9f6c0 Flight/ManualControl: Make it so the disarmed signal itself changes when GCS
lost.  Warning though: it takes ~5-10 seconds for the flight telemetry status
to go from connected so this solution still isn't great.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2070 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-04 02:30:53 +00:00
peabody124
7bdd900409 Flight/Manual: Cleaner solution to deal with timer wraparound
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2069 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-04 02:30:51 +00:00
peabody124
1f87715719 OP-192 Flight/ManualControl: Add a timeout to the armed signal. Leaving throttle < 0
for 30 seconds disables it.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2068 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-04 02:30:49 +00:00
peabody124
c69c4157f1 Flight/Actuator: Add failsafe for when flying via GCS to disarm at
lost connection

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2067 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-04 02:30:47 +00:00
corvus
ba781dec9a port.c optimized for linux
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2051 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-11-01 11:54:02 +00:00
pip
9b22bb07e6 Fixed a bad bug in the fifo_getData functions.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2044 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-31 04:58:34 +00:00
edouard
d5752dff34 Update BL Makefile for buffer.c removal.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2043 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-30 18:39:07 +00:00
peabody124
800e6cbe2c AHRS/INSGPS: Fix a swapped index Corvus caught
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2042 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-30 18:15:57 +00:00
peabody124
34bd4b7524 OP-198 Flight/GPS: Remove dependency on buffer.c, also made the detection of start and
end characters occur while sentence coming in instead of reprocessing whole
sentence for each character

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2041 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-30 18:15:52 +00:00
pip
ed03a45ee5 Added extra error checking - making sure the packet size is valid and that packet sizes match.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2039 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-30 15:00:36 +00:00
edouard
8087fda6f9 Update Makefile so that the bootloader still compiles with the latest buffer_XXX changes...
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2032 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-29 17:54:05 +00:00
pip
7bdaaa3930 Renamed fifoBuf_size to fifoBuf_getSize and got it to return the actual usable size of the buffer (one less than the buffer size).
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2031 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-28 21:10:43 +00:00
pip
91e6fb1485 Added fifoBuf_size function
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2030 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-28 15:14:44 +00:00
peabody124
42a02e5662 Flight/HID: USB priority to 8 instead of 1. Probably Need to make the HID layer use a
similar driver format to the PIOS_USART system.  (p.s. are you happy now, PT?)

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2029 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-28 15:07:07 +00:00
sambas
3f62776253 OP-97 flight/GPS: Few more fixes
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2028 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-28 14:58:39 +00:00
peabody124
b9f74a86c3 OP-198 Flight/Libraries: Swap to using circular buffer code from Pip because it
supports thread safe write/read simultaneously

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2027 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-28 14:30:03 +00:00
peabody124
0bdaf4d0df OP-197 Flight/USB: Make non-blocking send return -2 instead of -1 for not enough space
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2026 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-28 14:30:00 +00:00
sambas
365a2a121a OP-97 flight/GPS: Few fixes
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2025 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-28 13:50:34 +00:00
peabody124
aada18a0ea UAVTalk: Update protcol version number to go with new packet format and changed
a few constants to make it self documenting

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2017 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-27 17:41:41 +00:00
peabody124
4570d6df23 UAVTalk: Insert a sync byte (0x3C) and the packet size to facilitating handling
by PipX modems.  This is a change to UAVTalk so GCS and the hardware must all
be updated.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2016 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-27 17:16:29 +00:00
peabody124
33e6cbebdc AHRS debugging: Move dump to beginning of block to see the updated lines
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2015 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-27 17:16:25 +00:00
sambas
3e462b1434 OP-97 flight/GPS: Disable speed threshold command for those who knows it's needed, check gpsTask->DISABLE_GPS_TRESHOLD
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2014 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-27 15:51:33 +00:00
peabody124
4d7e053e06 AHRS Debugign code for dumping the EKF and importing into Matlab
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2013 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-27 14:31:34 +00:00
peabody124
2019edd612 AHRS: Store running time to make detect resets easier. Update OP and AHRS in
parallel for this update.  Also removed comment for rawhid

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2012 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-27 14:31:32 +00:00
sambas
f1ba558fa1 Flight/GPS: Some updates
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2011 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-27 10:39:38 +00:00
peabody124
a2e0cd2240 Stabilization: Dont make queue respond to both raw sensors and attitude because
causes it to trigger most of the time every 1 ms which is consuming tons of
CPU.  Also lower the failsafe timeout since its likely due to overloading the
event system and we don't want to delay 100 ms.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2005 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-24 20:00:05 +00:00
peabody124
9944cdfcb0 Flight/RateDesired: UAVObject for monitoring the desired rate out of
stabilization for diagnostics

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2004 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-24 20:00:02 +00:00
peabody124
acc6df4c2d Flight/USB_HID: Make the userspace command wait until not in interrupt before
running and block the interrupts while modifying the buffers

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2003 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-24 01:35:30 +00:00
ligi
523b6ad8f7 added hint on how to better distinguish FC/NC
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2001 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-22 12:36:47 +00:00
peabody124
098b2fd693 Flight/System: Double heart rate when system is armed. This is per request in
IRC, but suggestions are welcome.  In the long run we probably need a sensible
way of embedding some information in the LED but it's not obvious to me.  Also
could have done with callback - sue me. ;)

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1997 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-20 05:31:24 +00:00
peabody124
cd04845c3d Flight/HID: NAK instead of stall USB bus (former was mistake) and change
polling time to 4 ms

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1996 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-20 05:21:25 +00:00
corvus
50574841bd Moved non primary Stabilization modules into Branches
simple		- outdated - won't compile
Experimental	- outdated - won't compile
les		- development version - not stable
les+corvus	- development version - not stable




git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1993 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-19 19:12:37 +00:00
dankers
4ed3359f6f Comment was misleading.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1992 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-19 17:25:07 +00:00
sambas
0384e359ba My working eclipse workspace, atleast for windows
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1991 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-18 19:16:20 +00:00
corvus
8cb04a372f Stabilization: new stabilization variant based on les stabilization module, with several options for coordinate system transformation
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1990 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-18 14:46:45 +00:00
corvus
7a37dc1f32 PiOS.posix - added some debugging code
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1977 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-17 16:27:49 +00:00
edouard
82b702e239 Added the new Multirotor shapes to the SystemSettings object, as discussed on the forums. UID has not changed, but you should recompile still (sorry).
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1972 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-17 14:15:47 +00:00
corvus
43beec24d6 flight/documentation/Architecture - Updated Architecture diagrams to reflect most of the current UAVObjects
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1966 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-16 18:05:12 +00:00
les
2125e2479d Added AHRS boot loader SPI protocol
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1965 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-16 17:54:00 +00:00
cwabbott
dff66607c7 More UAVObject fixes, stuff to get PiOS.win32 compiling again.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1962 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-16 12:15:47 +00:00
peabody124
300195ff18 AHRS: A few small changes
1) Moved the criteria for using GPS to defines in anticipation of moving into
AHRSSettings
2) Only use the mags for updates if the vector length is within 20% of nominal
to avoid updating when it's nonsense
3) Reinitialize position when swapping between indoor and outdoor
4) Dont use mags for first 5 seconds after initialization, sometimes seems to
cause issues
5) Dont use mags until magnetic field at your location is set and a magnetic
field is loaded
6) Dont use GPS if home location hasnt been set

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1959 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-14 01:36:30 +00:00
peabody124
016bcad24a AHRS: Detect when more than 2 seconds since last GPS update and in that case
reinit INSGPS to new location

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1958 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-14 01:36:28 +00:00
pip
bd8ad90301 Added PipXtreme jtag cfg files.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1956 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-13 08:14:39 +00:00
pip
acadc4bc28 Added some files to the PipXtreme folder.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1955 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-13 07:49:05 +00:00
pip
a3ac3feae9 Added PipXtreme folder.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1954 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-13 07:43:32 +00:00
pip
0f7e0cf4db Removed PipBee folder
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1953 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-13 07:40:36 +00:00
les
6d6ec37474 Manual control: Changed 'Position' stabilization mode to 'Attitude'
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1944 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-11 17:58:11 +00:00
peabody124
dc10998152 Flight/Stabilization: Make any throttle < 0 reset the pid integral windup
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1933 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-10 00:46:06 +00:00
peabody124
5f601bf5ab Flight/Guidance: Enable for any type of quad airframe
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1932 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-10 00:46:04 +00:00
peabody124
e72b6051b5 AHRS: Make mag variance account for the vector length of magnetic field. Also
moved around where the axis are swapped and made the negative sign come from
calibration.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1931 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-10 00:46:01 +00:00
peabody124
ea85e98d7a Flight/Stabilization: Move update time storage to before the set to make sure
it goes

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1922 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-08 15:38:28 +00:00
peabody124
8308e4a4fe Whitespace change: get rid of CR
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1921 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-08 15:38:26 +00:00
peabody124
4e6f100ae5 Flight: Swap to Les' code for main line
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1920 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-08 15:38:23 +00:00
peabody124
0a9ab6ca5f AHRS: Send PositionActual and VelocityActual out
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1919 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-08 15:38:19 +00:00
edouard
85aeffed9a Removed example settings from OpenPilot flight SW makefile too..
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1914 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-07 17:42:59 +00:00
peabody124
c4cb494a22 UAVOBjects: Just ran object genearator to get things compiling again
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1913 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-07 13:09:35 +00:00
kokomojoe
a0b3b47c48 OP-21 Flight/Bootloader - experimental modules implementing a simple serial packet (SSP) protocol. ssp_test is a test framework. ssp is the module, main_ssp.c prototype module on how this could be used in the bootloader, it is not fully functional, additional logic required for start-up detection to decide if serial initialization is required.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1909 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-07 04:59:18 +00:00
darkz
6b8aba07b1 Updated Makefile.posix to reflect the removal of example code
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1907 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-07 02:50:12 +00:00
edouard
5c48c29612 Remove example objects from the flight code, not needed anymore
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1905 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-06 21:50:57 +00:00
sambas
e32ddd5230 Flight/AHRS: gyrotemp raw actually shows now raw temp
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1903 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-06 18:14:12 +00:00
peabody124
dea5c91646 AHRSCalibration: Make default values correct now Les extended
uavobjectgenerator to support multiple fields (thanks Les!).  Also
changed default scale on mag to +/-6g

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1899 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-06 14:26:42 +00:00
peabody124
66bf9d53d4 AHRS: Paramaterize the variance used for the indoor algorithm.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1898 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-06 14:26:40 +00:00
kokomojoe
946283d67e OP-185 Flight - Added FirmwareIAP to the module load list in makefile, added uavobjectsinit.c with firmware IAP init calls
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1896 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-06 05:30:48 +00:00
kokomojoe
7cf0e9ba31 OP-185 Flight support for firmware IAP object. added the pios_iap.c and firmwareiapobj.c
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1895 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-06 02:58:07 +00:00
kokomojoe
6499da40e3 OP-185 Flight Added init function for PIOS_IAP helper functions.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1892 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-06 02:07:11 +00:00
kokomojoe
2fe266650f OP-185 Flight - support files for Firmware IAP object
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1891 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-06 02:06:13 +00:00
kokomojoe
20c6e2292a OP-185 Flight helper functions for the firmware IAP object. Allows setting/clearing of back-up registers
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1890 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-06 02:02:37 +00:00
les
7ddb0f6f80 Stabilization: Changed to new switch format. Both position and rate modes work.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1886 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-05 14:51:33 +00:00
les
1e26ca11ee Manual control: Added some extra room at throttle zero when detecting a faulty signal
Before, moving your throttle trim slightly could cause ManualControl to think the receiver was not connected

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1885 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-05 14:50:03 +00:00
les
b2c81aceee Actuator: Fixed motors not going to min throttle in failsafe.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1884 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-05 14:47:48 +00:00
peabody124
ba3ecada1d Flight/ManualControl: Implemented settings to change what the Mode switch does
so it can also change parameters of Stabilization.  Please check your aircraft
behavior with this patch, but default behavior should be unchanged.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1878 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-04 19:48:09 +00:00
les
3aa72835d6 AHRS comms: Added GPL text
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1876 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-04 15:29:41 +00:00
peabody124
f03669733b Flight/Guidance: Merge back into one task because memory requirements of a task
exceed CPU requirements of PID.  Also add add lesstabilization UAVObject to Makefile
to fix compile errors.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1870 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-04 02:01:34 +00:00
peabody124
d71e9df8c5 Flight/UAVObjects: Add a few files that were missed earlier, and get posix
worlking again

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1869 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-04 02:01:31 +00:00
les
05a85c8c95 New stabilization module based on PI-P algorithm used in FlightOS
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1864 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 20:39:23 +00:00
les
dcef777ab0 AHRS SPI comms: Retries were not being tracked correctly
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1863 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 20:36:20 +00:00
peabody124
e743678d89 AHRS: This fixes the mags, I forgot to normalize the magnetic flux at your
home location.  If you use INSGPS_INDOORS make sure your HomeLocation.Be fields
are correct for your GPS coordinates
http://maps.alfiordalis.com/declination.html

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1862 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 20:35:22 +00:00
cwabbott
8d1a99ae15 PiOS.win32: Updated PiOS.win32 makefile for recent UAVObject changes, and also updated the experimental stabilization code to comply with recent changes to the simple code. Nobody uses SiTL anymore :( .
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1858 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 18:59:58 +00:00
les
11cf24a312 Actuator: Fixed uninitialised variables
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1857 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 18:37:07 +00:00
peabody124
1931c75a4c AHRS: Deal better with DMA errors
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1856 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 18:14:36 +00:00
peabody124
a9495e2cbb UAVObjects/AttitudeSettings: Remove unused object, moving data to AHRSettings.
Added attitude bias to AHRSSettings.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1855 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 18:14:34 +00:00
peabody124
754200f9cf UAVObjects/Delete old VTOLSettings object
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1854 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 18:14:27 +00:00
edouard
eeb5eab177 Flight/Stabilization: fix for -180/+180 yaw transition which caused glitches in the stab module.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1853 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 16:43:10 +00:00
peabody124
840df39b78 AHRS: Export gyro data as deg/s instead of rad/s to match the object label
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1851 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 15:22:09 +00:00
peabody124
9165fb87b2 AHRS: Calibration values were sent but not locked into EKF
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1847 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 04:34:07 +00:00
peabody124
87a822e3f9 AHRS: Add back home location setting north axis
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1846 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-03 04:34:05 +00:00
peabody124
5c9b5f4a99 AHRS: Get calibration working again
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1842 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-02 03:10:04 +00:00
peabody124
0c30101f54 AHRS: Made an object setting to allow the downsampling rate to be changed on the
fly (EKF rate up to a limit).  Also, now the algorithm selects if you are
indoor or outdoor as well as if you use a mag indoor (if you do set the z
variance higher than it calibrates to).

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1841 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-02 03:10:01 +00:00
peabody124
104dc165a9 AHRS: Max downsample that doesn't cause huge amounts of drops right now is 20
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1840 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-02 02:17:34 +00:00
peabody124
29b087703b Flight/AHRSComms: Decrease stack size, not needed to be that big. Also made
ActuatorDesired dT in ms like the uavobject indicates

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1839 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-02 02:17:32 +00:00
peabody124
6d39d85b8f UAVObjects/AHRSStatus: Remove unused fields
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1838 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-02 02:17:29 +00:00
peabody124
2050864e59 UAVObjects/VTOLStatus: Remove unused object. Also added update time to
indicate stabilization loop time.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1837 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-02 02:17:26 +00:00
peabody124
0fd9fda7a6 Flight/AHRS Comms: Whitespace fixes
gnuindent -npro -kr -i8 -ts8 -sob -ss -ncs -cp1 -il0 -hnl -l150

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1836 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-02 02:17:22 +00:00
peabody124
ea3fb03c7f Flight/AHRS Communications: Switch to Les' very nice UAVObject communication
scheme

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1835 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-02 02:17:18 +00:00
corvus
62300c9682 flight/Libraries/CoordinateConversion: ECEF2LLA() - Speed up the calculation with a primer coordinate.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1834 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 20:30:34 +00:00
peabody124
2a93f35807 UAVObjects/MixerSettings: Have values as int8, don't need float resolution
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1832 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 20:28:14 +00:00
les
683aa2b480 AHRS: Tidied up calibration sequence
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1831 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 19:41:00 +00:00
les
b2d56ca34c AHRS: Added UAVObject based SPI communication between AHRS and OP.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1830 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 17:31:13 +00:00
les
498f3d0fa6 PIOS SPI: Added a function to detect if the channel is busy
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1829 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 16:52:20 +00:00
edouard
d2c1014e29 Re-enabled yaw stabilization after SystemSettings changed. There might be a lingering issue when the
yaw angle crosses the zero-360 mark, beware.
You can disable yaw stabilization by setting all PID gains to zero for yaw.



git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1828 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 16:26:43 +00:00
peabody124
d54c6bf0f8 Flight/Actuator: Use dT in seconds. Forgot to change MaxAccel.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1825 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 14:37:03 +00:00
peabody124
0dfdad4fc4 Flight/Actuator: Reset critical alarm
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1824 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 14:09:14 +00:00
peabody124
c076a695ce UAVObjects/ActuatorSettings: Default values are all 1000 now so that an
unconfigured motor can't turn on.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1823 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 13:45:26 +00:00
peabody124
9f4e3906e3 Flight/Actuator: Made it use the detected dT for the feedforward computation
and removed the unused field from actuator settings (old setting time and all
the aircraft specific stuff).

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1820 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 12:33:33 +00:00
peabody124
2dc40d11a1 Flight/Stabilization: Use the system clock to determine time from previous
update since now drive by events.  This means StabilizationSettings object
changing so write down your settings.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1819 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 12:33:29 +00:00
peabody124
4461aba6d6 Flight/Stabilization: Move to object event system. Latency from ahrs_comm
update to actuator update now ~0.7 ms.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1818 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 12:33:26 +00:00
peabody124
b9943645e0 Flight/Actuator: Run actuator from queue again, latency well behaved.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1817 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-10-01 12:33:20 +00:00
peabody124
e2d63cbf19 Flight & Ground/AHRS Calibration: Made variance estimation into a two pass
approach again because ran out of numerical precision for single pass.  Also
made ground force the gyro signs to be correct.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1806 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-30 04:30:29 +00:00
sambas
ee4ca7b93a OP-177 Flight: All alarms fixed, AHRSComms stack size made critical stack alarm, event warning caused by queue that is not used at the moment.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1801 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-29 19:06:35 +00:00
peabody124
a4e0ee5fdf Flight/Actuator: Move Les' actuator to the active one
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1800 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-29 18:51:36 +00:00
peabody124
2f6f76d578 Flight/Actuator: Remove old mixer code
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1799 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-29 18:51:34 +00:00
sambas
2d90a80e22 Flight/PiOS: this patch makes dosfs work with both MBR and VBR formats. Backup your SD files in case this messes something!! Testing needed.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1798 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-29 16:29:38 +00:00
peabody124
c95b1e6117 Ground/UAVControl: Working joystick support although currently not configurable
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1794 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-29 03:59:03 +00:00
kokomojoe
6f1f990d85 OP-21 AHRS/Bootloader - Moved start of user code to 0x08002000. Must be used with latest AHRS Bootloader compiled with DEBUG=OFF.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1788 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-28 02:21:48 +00:00
fredericg
f090b4bcf8 OP-174 ET OSD: Fixed build errors due to UABObject changes
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1786 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-27 19:56:25 +00:00
peabody124
9b1d258a94 Flight/Les/Actuator: Space->Tab, somehow slipped passed previous patch
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1784 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-27 17:30:42 +00:00
peabody124
aa42256ad1 Flight/Stabilization: Convert all PID loops to units of seconds instead of ms.
THIS MEANS YOU MUST RETUNE YOUR PID LOOP IF YOU'RE FLYING WITH IT

Alternatively divide Kd by 1000 and multiply Ki by 1000

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1782 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-27 09:04:43 +00:00
peabody124
fef8cca5b6 Flight/Posix: Get compiling again (sorry Corvus, I think I messed up your
change earlier)

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1778 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-27 07:28:48 +00:00
peabody124
3c021c09d9 Flight/PiOS: Whitespace changes
find ./flight/PiOS/inc/ \! \( -name '*~' -a -prune \) -type f    | xargs -I{}
bash -c 'echo {}; dos2unix {}; gnuindent -npro -kr -i8 -ts8 -sob -ss -ncs -cp1
-il0 -hnl -l150 {};'

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@1777 ebee16cc-31ac-478f-84a7-5cbb03baadba
2010-09-27 07:28:45 +00:00