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

12 Commits

Author SHA1 Message Date
Brian Webb
43f6458f86 Reduced the sizeof the UAVObject metadata by:
1) Combining all binary or mode values into a single byte
  2) Adding accessor functions to read/write the flag bits
  3) Reduced the size of the time values from 32 bits to 16 bits
2012-02-20 18:45:18 -07:00
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
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
Mathieu Rondonneau
de55c56427 OP-423: Change capital on macro to be uppercase for consistency. 2011-06-24 22:03:03 -07: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
Mathieu Rondonneau
31a06a5ae7 OP-423 add set/get uavobjects functions to access objects fields separately. 2011-06-02 21:18:34 -07: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
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
peabody124
fc54159369 OP-265 Flight reorganization of UAVObjects and Modules up a directory
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2415 ebee16cc-31ac-478f-84a7-5cbb03baadba
2011-01-14 01:38:19 +00:00