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

2798 Commits

Author SHA1 Message Date
Richard Flay (Hyper)
5864219d27 Removed __attribute__((always_inline)) after review discussions. 2012-11-23 07:15:28 +10:30
Richard Flay (Hyper)
6c0b91dee7 Minor tweak for coding standard compliance. 2012-11-15 07:45:35 +10:30
Richard Flay (Hyper)
eda6b6a24a Improved type-safety. Replaced flight side UAVO access macros with inline functions to ensure that correct pointer types are always passed to UAVO access functions. 2012-11-10 20:47:10 +10:30
Richard Flay (Hyper)
10865221b9 Removed a spurious call to AccelsSet() that was causing garbage data to be transiently written to the Accels UAVO. Props to cyr for kicking off the discussion that led to the discovery of this bug. 2012-11-01 18:15:47 +10:30
lilvinz
3db04ea174 pios_jedec: fixed usage of uninitialized memory
When reading the jedec device id the code only transfered one byte via spi leaving
the expected input buffer uninitialized. This may lead to the problem that flash
initialization fails because the expected input may be whatever the stack was set
when entering the function. The impact of the bug is somewhat limited tough as the
initialization usually takes place before starting up the rtos and thus is pretty
deterministic. So if the code passed init while testing it should pass init in
production as well.
2012-10-28 14:34:20 +01:00
Stacey Sheldon
bc3a90c6a9 Merge branch 'one-way-telemetry' into next 2012-10-25 22:48:43 -04:00
Kenz Dale
1ab1ea5899 Save ~150 bytes by moving GPSDataProtocol to SystemSettings.
All credit to Anstron.
2012-10-22 16:47:22 +02:00
Stacey Sheldon
4892fdb33d telemetry: allow telemetry to flow when not connected to GCS
Previously, when unconnected, only the flighttelemetrystats
UAVO was Tx'd.  All other UAVOs were inhibited.  This led to
zero telemetry data when the connection to the GCS was gone.
This precluded getting useful telemetry from a receive-only
station.

This commit changes two main areas.

First, UAVO updates are now allowed regardless of the "connected"
state between the GCS/FC.

Second, it makes both the flighttelemetrystats and gcstelemetrystats
UAVOs un-acked.  This prevents these objects from blocking all
other UAVOs while they wait for their ack.  This is OK since the
real "connection" negotiation happens via the states exchanged in
the Status field of these UAVOs.
2012-10-21 22:51:17 -04:00
James Cotton
96afe7cffd Merge remote-tracking branch 'origin/stac/add-debug-consoles' into next 2012-10-12 08:07:44 -05:00
Stacey Sheldon
f0e0c2e79e console: add debug console via USB CDC/VCP interface
The USB VCP Port has a new DebugConsole setting that
routes all output destined for PIOS_COM_DEBUG to the
emulated serial port.

To enable this in your build, you'll have to build like:
 - make fw_coptercontrol_clean
 - make fw_coptercontrol ENABLE_DEBUG_CONSOLE=YES

You can then output formatted text to the console
like this:
  #if defined(PIOS_INCLUDE_DEBUG_CONSOLE)
  PIOS_COM_SendFormattedString(PIOS_COM_DEBUG,
                               "foo is %u\r\n",
                               foo);
  #endif	/* PIOS_INCLUDE_DEBUG_CONSOLE */

Please ensure that all of your debug output is
wrapped with these macros so that your debug
code doesn't bloat the firmware image.
2012-10-11 00:51:09 -04:00
Stacey Sheldon
75170177df console: example usage of the debug console 2012-10-11 00:22:07 -04:00
Stacey Sheldon
6088c05946 console: add support for serial debug consoles
Serial ports now have a new HW setting called DebugConsole
which can be used to dump internal state to a serial port
for debug.

To enable this feature, you need to:
 - make fw_coptercontrol_clean
 - make fw_coptercontrol ENABLE_DEBUG_CONSOLE=YES
 - configure one of the serial ports as DebugConsole in the GCS
 - save settings
 - power-cycle your board

Things to note:
 - The console is at 57600,8N1.
 - This is not currently configurable via the GCS.
 - You can only have a single console enabled at a time.
2012-10-11 00:22:07 -04:00
Laura Sebesta
c2b49b6ef3 Merge branch 'kenz/cc_hitl_merge' into next
Conflicts:
	ground/openpilotgcs/src/plugins/gcscontrol/gcscontrolgadgetoptionspage.ui
	ground/openpilotgcs/src/plugins/hitlnew/hitloptionspage.ui
	ground/openpilotgcs/src/plugins/hitlv2/hitlv2optionspage.ui
2012-10-08 15:30:27 +02:00
Stacey Sheldon
157aeac9fc Merge remote-tracking branch 'origin/stac/ppm-and-pwm-inputs' into next 2012-10-06 23:04:49 -04:00
sambas
9212bbeb20 DSMx bindmode delay was too long, satellite binding works again. 2012-10-07 12:09:42 +11:00
James Cotton
c8d9f89ea3 Default DIAG_TASK was on for PipX 2012-10-03 15:11:15 -05:00
James Cotton
897b07da02 Merge remote-tracking branch 'origin/kenz/diag_stack_split' into next 2012-10-02 14:20:08 -05:00
Stacey Sheldon
2f4b1e69dd rcvr: Support PPM and PWM at the same time on CC
Adds a new mode for the receiver port (PPM+PWM) which
will allow simultaneous use of 1 pin for PPM and the
rest of the pins for PWM inputs.
2012-09-29 19:11:48 -04:00
James Cotton
b0d8487e27 PIOS_RFM22: Make the irq return false for the exti changes 2012-09-28 02:14:15 -05:00
James Cotton
8979c00fba Merge branch 'exti_end_switching_isr' into next 2012-09-28 00:41:08 -05:00
James Cotton
519e3e2e3a PIOS_EXTI: Make the line task macro now take in the xHigherTaskPriority variable name 2012-09-28 00:40:36 -05:00
James Cotton
f12d5c04fb Merge remote-tracking branch 'origin/lilvinz/mpu6000_masked_locals_fix' into next 2012-09-27 14:43:54 -05:00
James Cotton
1ba40ee9b0 PIOS_EXTI: Make sure to use pdTRUE instead of true where appropriate. 2012-09-27 14:41:38 -05:00
James Cotton
1721479a12 Fix for vinz' merge to pios_mpu6000 exti changes 2012-09-27 14:34:11 -05:00
James Cotton
a021659b75 Merge remote-tracking branch 'origin/lilvinz/exti_end_switching_isr' into next 2012-09-27 14:31:16 -05:00
Laura Sebesta
8997df2438 Merge branch 'next' into kenz/diag_stack_split
Conflicts:
	flight/Modules/Stabilization/stabilization.c
2012-09-27 19:29:23 +02:00
Laura Sebesta
4923655cd3 Added global flag for enabling all diagnostic tools. 2012-09-27 18:51:12 +02:00
Stacey Sheldon
215ff56fe8 usbcdc: fix handling of CDC SET_LINE_CODING request
The SET_LINE_CODING request contains data and must be
handled as such.

Previously, the only requests that had data were IN
requests.  SET_LINE_CODING is an OUT request so it
required additional changes to support a new type of
data request.
2012-09-24 00:56:25 -04:00
Stacey Sheldon
5e37448814 usb: correct enum for CDC SET_CONTROL_LINE_STATE request 2012-09-24 00:53:52 -04:00
Stacey Sheldon
c056ac5261 usbcdc: don't assert on calls when CDC is not initialized
The CDC interface is always advertised in the FW USB
descriptors.  It is NOT always enabled/initialized at
runtime.  Specifically, it can be Disabled in HwSettings.

Previously, any CDC-related query that the host would send
resulted in an assert and a watchdog.

Now, a suitable return code indicating that the request is
unsupported is returned in this scenario.
2012-09-24 00:53:12 -04:00
Stacey Sheldon
14123069be gdb: add gdb config file for CC BU image 2012-09-16 21:13:42 -04:00
Stacey Sheldon
368d57bc92 Merge remote-tracking branch 'origin/lilvinz/OP-300' into next 2012-09-16 16:05:25 -04:00
lilvinz
a6a7ed8157 pios_exti: added returnvalues to exti handlers which allows to use portEND_SWITCHING_ISR 2012-09-16 21:44:09 +02:00
Stacey Sheldon
05483e2a74 simposix: adapt simposix to addition of relay tuning 2012-09-16 15:40:47 -04:00
lilvinz
524cff1c40 pios_mpu6000: fixed masked locals mistake 2012-09-16 21:25:06 +02:00
lilvinz
718062ed6e pios_led: added support for active_high connected leds 2012-09-16 18:19:27 +02:00
James Cotton
595083c982 PID: Fix small bug in setpoint weighting that had really ugly consequences 2012-09-12 00:07:17 -05:00
James Cotton
4717c376c0 Stabilization: For the inner loop call the setpoint shaping version so that
the derivative term can weight the sticks and gyros independently.
2012-09-11 13:21:53 -05:00
James Cotton
e4a167dca1 PID: Add a pid_apply_setpoint which takes in the setpoint and feedback term
This version allows performing setpoint weighting, currently on the derivative
component.
2012-09-11 13:21:19 -05:00
James Cotton
11b099b1ef Stabilization: Add configuration terms for the derivative calculation to the UAVO and pass
them in to the PID system.
2012-09-11 12:29:38 -05:00
James Cotton
42bbd52d68 PID: Add a function to set the cutoff for the derivative term
Also contains a term for setting the deriative setpoint in the future
2012-09-11 12:27:41 -05:00
James Cotton
fa9a616b4c PID: Add the 20 Hz low pass filter to the derivative term 2012-09-10 03:14:02 -05:00
James Cotton
9763a70364 Merge remote-tracking branch 'origin/igor/pidt1' into relay_tuning
Conflicts:
	flight/Modules/Stabilization/stabilization.c
2012-09-10 03:10:26 -05:00
Igor Van Airde
8ca99739ed Changed rate controller from PID to PIDT1 to improve flight stability.
Low pass on D-Term makes the D-Term usable to improve flight stability.
Affects rate and stabilize mode.
2012-09-09 13:07:25 +02:00
Werner Backes
2a4e135c81 Merge branch 'D-Lite/fix_CC3D_yawBias_correction' into next 2012-09-06 13:47:03 +02:00
Werner Backes
4803dfe99c Fix: yaw bias correction wasn't applied on CC3D. 2012-09-06 13:13:58 +02:00
Stacey Sheldon
97882dbef9 pipx: ensure pipx BL image is padded to fill its bank
This padding is required in order to properly align all
of the sections in the EF images.
2012-09-05 22:17:04 -04:00
Stacey Sheldon
803e3c4d1e ef: Add fwinfo to entireflash (EF) images
EF images were missing the firmware info blob that describes
which firmware is installed on the board.  The EF image is now
padded out to fill the firmware bank and the info blob is
properly placed at the tail end of the firmware bank.
2012-09-05 21:45:59 -04:00
James Cotton
2f65fc1e8e Merge branch 'next' into relay_tuning
Conflicts:
	shared/uavobjectdefinition/manualcontrolsettings.xml
	shared/uavobjectdefinition/taskinfo.xml
2012-09-04 10:43:04 -05:00
James Cotton
db083aa0e9 Merge branch 'android' into next 2012-09-02 19:19:23 -05:00