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

51 Commits

Author SHA1 Message Date
James Cotton
03a8bd7674 Statically initialize object handles to null to make sure the uavobjectmanager
can catch it and return -1.  Do NOT panic when they are null as this is
something that should be caugth at run time in some cases.

Ideally as a compromise in a task start it could have a set of
PIOS_Assert(ObjectNameHandle()) to make sure the minimal set of objects it
needs are there.
2011-08-19 10:12:39 -05:00
James Cotton
ced29e221e Revert "Debugging: Add PIOS_DEBUG_Panic() call wen an UAVObject handle is requested but object is uninitialized, make PiOS.posix bail in case of a Panic with an error message"
We do not want to panic in this case as we want the ability to detect if
objects exist at run time

This reverts commit 78e42470d4.
2011-08-19 09:45:10 -05:00
Corvus Corax
78e42470d4 Debugging: Add PIOS_DEBUG_Panic() call wen an UAVObject handle is requested but object is uninitialized, make PiOS.posix bail in case of a Panic with an error message 2011-08-19 12:56:26 +02:00
Corvus Corax
f86e53bf91 Merge branch 'OP-536_CorvusCorax_ObjectOrientedFirmwareUAVTalk' into next
Conflicts:
	flight/Modules/Telemetry/telemetry.c
2011-08-19 12:10:40 +02:00
Corvus Corax
6fe495c088 Merge remote branch 'origin/next' into OP-536_CorvusCorax_ObjectOrientedFirmwareUAVTalk
Conflicts:
	flight/Modules/Telemetry/telemetry.c
2011-08-17 08:30:32 +02:00
James Cotton
86b652bbab Merge branch 'next' into camera_stabilization 2011-08-14 18:07:57 -05:00
James Cotton
f766ba47aa Increase the size of the eventdispatcher task and lower the maximum queue size. 2011-08-13 19:21:58 -05:00
James Cotton
9c7799dfe6 UAVObject Init: Get rid of deprecated linker init code 2011-08-10 22:48:42 -05:00
James Cotton
96c2d24253 Merge branch 'next' into camera_stabilization
Conflicts:
	flight/CopterControl/Makefile
	flight/CopterControl/System/coptercontrol.c
	flight/Modules/Actuator/actuator.c
	flight/Modules/GPS/GPS.c
	flight/Modules/ManualControl/manualcontrol.c
	flight/Modules/Stabilization/stabilization.c
	flight/Modules/System/systemmod.c
	shared/uavobjectdefinition/manualcontrolsettings.xml
	shared/uavobjectdefinition/stabilizationdesired.xml
2011-07-30 10:06:10 +09:00
James Cotton
2fe7ee40b1 Merge branch 'OP-423_Mathieu_Change_Init_To_Reduce_Memory_Footprint' 2011-07-12 12:44:59 -05:00
James Cotton
c33d3057cc Dos2unix evendispatcher file 2011-07-12 12:36:20 -05:00
James Cotton
15a2b85729 For OpenPilot use the minimal stack size (512 words) for eventdispatcher as
this is necessary for object saving.  Creating a new define to override this
for CopterControl down to 96.
2011-07-12 12:34:40 -05:00
Mathieu Rondonneau
d38f6167e3 OP-423:
Also reduce heap has it does not fit in SRAM anymore (not with current compiler).
(that's ok since if there is more space available, it will be reclaimed).

Merge branch 'master' into OP-423_Mathieu_Change_Init_To_Reduce_Memory_Footprint

Conflicts:
	flight/CopterControl/System/inc/pios_config.h
	flight/Modules/ManualControl/manualcontrol.c
2011-07-08 06:29:34 -07:00
Stacey Sheldon
0c4facac46 heap: reduce stack size on IDLE and Event tasks
The FreeRTOS IDLE task was using 512 bytes of stack.
The UAVObject Event task was also using 512 bytes of stack.

Both have been reduced, recovering 400+ bytes of heap.
2011-07-05 20:13:00 -04:00
Mathieu Rondonneau
de55c56427 OP-423: Change capital on macro to be uppercase for consistency. 2011-06-24 22:03:03 -07:00
Corvus Corax
f52f6d30c6 VTalk (flight): Buffers allocated dynamically with size calculated by UAVObjGenerator. Support for tx packet sizes < object size.i 2011-06-24 02:08:20 +02:00
James Cotton
2218ff6fe9 Change to object template so when they are already registered it doesn't
initialize them a second time (which causes the handle to get lost)
2011-06-18 14:21:14 -05:00
James Cotton
4f47c06547 Merge branch 'saving_crc' into bugfix-flight 2011-06-05 15:37:44 -05:00
James Cotton
56faad594e OP-423: Make sure to unlock semaphore before returning from error condition 2011-06-05 08:41:21 -05:00
James Cotton
599483d5ac OP-152: Save CRC for object and header into flash and only load object if CRC
matches.  Read the flash first bytewise to compute CRC instead of buffering
which is more RAM efficient but very inefficient as it sets up many one byte
SPI transfers.

Also incremented the filesystem magic flag to trigger an automatic flash wipe
on this upgrade.
2011-06-04 18:36:38 -05:00
Mathieu Rondonneau
31a06a5ae7 OP-423 add set/get uavobjects functions to access objects fields separately. 2011-06-02 21:18:34 -07:00
James Cotton
d883c8af9f Whitespace and line endings 2011-05-14 15:15:33 -05:00
James Cotton
934addfdcc OP-216: Silly typo 2011-05-14 15:11:33 -05:00
James Cotton
2087441006 OP-216: Make the object manager use new flash fs for objects 2011-05-14 14:23:02 -05:00
marcus bueschleb
b7eba1f9b9 made all periods unsigned 2011-04-20 12:33:16 +02:00
corvus
afdaf88d4a UAVObjects: Allow Generation and Initialisation of individual UAVObjects
per target as defined in Makefile (and/or Make include file) For
OpenPilot this is flight/OpenPilot/UAVObjects.inc For sim_posix and
sim_win32 needs rebuild of uavobjectgenerator and uavobjects!

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2736 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-02-05 22:17:40 +00:00
corvus
8de340b5a8 UAVObjectgenerator: Autogenerate Make include-file for flight UAVObjects to be used in firmware Makefiles.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2701 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-02-02 20:15:16 +00:00
peabody124
d33d044088 Revert "Revert "Fix to make stacs auto-loading of UAVObjects downwards compatible, since its not working on all architectures""
Putting Corvus patch back in.  Need to delete uavobjects-synthetics directory
for this to work.

This reverts commit 9cd98bec8fb5e0679c625eb256a94d161a8ce345.

Conflicts:

	flight/CopterControl/Makefile

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2671 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-02-01 15:46:59 +00:00
peabody124
8b2034ea05 CC-15 Settings: Delete settings from flash chip (hacky sector based saving)
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2663 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-02-01 02:18:15 +00:00
peabody124
97acaa2402 CC-15 Gets settings saved to flash chip on CC using crude sector based storage.
Sector based on Object ID so could overlap :-(.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2662 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-02-01 02:18:12 +00:00
peabody124
bbbdea26b9 Revert "Fix to make stacs auto-loading of UAVObjects downwards compatible, since its not working on all architectures"
Note: This patch did not build after a clean build.

This reverts commit 7e75b5d16481a32689433c868b67916816d8b9fb.

Conflicts:

	flight/CopterControl/Makefile

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2651 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-02-01 01:56:02 +00:00
corvus
c2ba1f517b Fix to make stacs auto-loading of UAVObjects downwards compatible, since its not working on all architectures
On architectures supporting automatic initializing, flight/UAVObjects/uavobjectsinit_linker.c is used
On architectures NOT supporting automatic initializing, an uavobjectgenerated file build/uavobject-synthetics/flight/init/uavobjectsinit.c is used
build/uavobjects-synthetics/flight/uavobjectsinit.c went away, so that a wildcard include in the Makefile will not include the (wrong) initialisation code in either version



git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2640 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-31 20:37:11 +00:00
stac
b5426e09d0 uavobj: Convert CC over to use autogenerated uavobjinit
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2631 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-30 22:46:51 +00:00
stac
083e2b01a9 uavobject: Use linker to produce uavobj initcalls
The UAVObject initcall list is now automatically
generated at link time based on the exact set of
UAVObjects linked into the firmware image.

This will allow any subset of UAVObjects to be
used in any firmware image.

The uavobj_initcall() macro automatically adds the
marked function's address into the .initcalluavobj.init
ELF section.

The UAVObjectsInitializeAll() function now simply
iterates over the functions listed in the
.initcalluavobj.init section and calls them.

You can see the contents of this section in the ELF file
like this:
  ./tools/arm-2009q3/bin/arm-none-eabi-objdump \
      --syms -j .initcalluavobj.init \
      ./build/openpilot/OpenPilot.elf

This is fundamentally the same mechanism that the Linux
kernel uses to initialize the specific set of components
that the user has selected in their kernel configuration.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2630 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-30 22:46:48 +00:00
corvus
04d3a9649d CopterControl: reverting previous commit - doesn't work on windows due to command line length limitations
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2624 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-29 16:15:16 +00:00
corvus
000a45f1bf CopterControl - Build CopterControl with a Makefile specified subset of UAVObjects - code generation by uavobjgenerator
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2622 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-29 12:36:41 +00:00
peabody124
23599ee59f CC: Set the buffer size of USART smaller and register teh AHRSSettings
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2573 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-24 07:51:59 +00:00
peabody124
99fcd089d4 OP-291 PIOS/Servo: Make the remapping of timers a part of the driver structure
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2569 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-24 07:51:48 +00:00
peabody124
c55d40bdbc CC-3 Setting up monolithic task template to keep code size down. Importantly
switch to heap_1.c which saves a lot of money.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2561 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-24 07:51:22 +00:00
peabody124
95e7017674 OP-286 UAVObjectManager memory usage: Since first element in linked list always
exists, no need to store pointers to it, but put the structure for the first LL
object in the ObjectListStruct

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2560 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-24 07:51:20 +00:00
peabody124
3fc8169330 OP-286 UAVObjectManager: Dont store pointer to initialize function for
UAVObjects, but pass it in from the macro definition.  Saves memory for each
objects.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2559 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-24 07:51:17 +00:00
pip
8b5ae6aef9 Removed PipXtreme entries
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2491 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-20 20:41:43 +00:00
corvus
75a6b406cd OP-273 - UAVTalk - prevent object update-bursts caused by involuntary synchronization in case of long delays or time-jumps
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2450 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-16 15:28:49 +00:00
corvus
6c3b887ae4 fixed line endings - mixed LF and CR+LF present - please keep it to either one of those or my editor gets crazy
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2448 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-16 11:24:43 +00:00
osnwt
290c9c538f Replace decimal OBJID representation in auto-generated headers by hexadecimal (taking advantage of new UAVObjGenerator). It makes easier to read and compare them with files on SD card. This does not change OBJID values and should be completely transparent.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2434 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-15 17:00:17 +00:00
peabody124
94ff276522 OP-265 CC: Tweaking objects included and the memory requirements
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2426 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-14 01:38:49 +00:00
peabody124
8a32d88b10 OP-265 CC: More work to get it running
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2425 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-14 01:38:47 +00:00
peabody124
c59a1ff018 OP-265 OP-266: FreeRTOS configuration per project because of available heap
size (may eventually need to be per revision if we get bigger ram).  Typo in a
the ifdefs to get allow disabling SDCARD

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2423 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-14 01:38:42 +00:00
peabody124
9cf3ee9fb3 OP-267 Flight/UAVObjectManager: Make all references to DFS function depend on
PIOS_USD_SDCARD.  However, this needs to be cleaned up and abstracted out of
the UAVObjectManager who shouldn't care about the storage layer.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2417 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-14 01:38:27 +00:00
peabody124
940792db5c OP-265 CopterControl: Fork main OpenPilot directory
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2416 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-14 01:38:24 +00:00