Commit Graph

28 Commits

Author SHA1 Message Date
Mark Charlebois bb281f03f3 Added DSPAL as a git submodule of PX4
The DSPAL headers are required to build for qurt. When we move to
a cmake build system, the DSPAL headers can be conditionally included.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-09-04 11:35:55 -07:00
Mark Charlebois 54bae34a2c Build fixes for qurt after rebase on PX4 master
Removed the re-definitions of the usage method in the posix/main.cpp file.
Added qurt_external_hook interface to call externally linked module.
Fixed code format to comply with PX4 style.
Added usage information to main app and handled cases for unknown arguments.
Fixed the orb_priority interface to use int32_t instead of int.
Fixes to get hil working with led changes.
Added the config_eagle_adsp.mk file and update the make files to to use new
include/lib paths

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-09-04 11:09:29 -07:00
Lorenz Meier b2b7ed8dd5 Merge pull request #2785 from mcharleb/posix_daemon_mode
Add daemon mode to posix build
2015-08-31 17:49:59 +02:00
Daniel Agar bb696b756b reduce make verbosity 2015-08-29 19:32:02 -04:00
Mark Charlebois d94aa84657 Add daemon mode to posix build
In order to use upstart to run PX4 it needs to run in daemon mode.
Added ability to test if a task is running in order to gracefully
shut down muorb.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-08-28 16:06:36 -07:00
Mark Charlebois 3a47434749 Fixes for qurt HIL build
Workaround required Eigen downgrade to 3.2. Hexagon toolchain does
not support C++11 features of newest version of Eigen.

Running make qurt_fixup will downgrade and patch Eigen for qurt.
Running make restore will revert the patch and do a git submodule update
to restore the expected Eigen version.

Added a "restore" target to undo qurt_fixup

Before doing a qurt build run:

    make qurt_fixup

That will downgrade Eigen to 3.2 and apply the require patch.
To build another target after downgrading:

    make restore

Them make the desired target (other than qurt).

Fixed type used in orb_priority to be consistent with the code
(int* was used in declaration but int32_t* used in code)

Removed unused class member variable in sensors.cpp

Added cmake fix for unit tests. The location of px4_log.c changed.

Fixed the qurt drv_hrt.c implementation to use us instead of ms for time resolution

Added px4_led.c to nuttx platform layer
Use the posix version of px4_led.c for nuttx so we don't end up with
duplicate files. It was moved out of common because it is not used by qurt.

Changed PX4_DEBUG to PX4_WARN when checking for the error condition for store_poll_waiter in vdev.cpp

Updated the px4_log.h file to make calls to the qurt_log functions.
The qurt_log function is defined in the platforms/qurt layer.

Added an option to control starting the commander module in HIL mode.

Moved the flight specific drivers to the configuration file instead of adding them
to the common tool chain file because HIL mode does not need them.

Added the uorb Subscriber and Publisher classes

Call PX4_ISFINITE macro instead of isfinite().

Added px4_led.c to nuttx platform layer
Use the posix version of px4_led.c for nuttx so we don't end up with duplicate files.
It was moved out of common because it is not used by qurt.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-08-25 21:59:01 -07:00
Lorenz Meier 27ed06f3e5 Renamed hil to pwm_out_sim 2015-08-12 19:23:29 +02:00
Mark Charlebois 41722c2b51 Added missing include path for qurt
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-08-11 12:17:28 -07:00
Mark Charlebois 009f528266 Fixes for posix-arm and qurt builds
Ifdefed out deadcode in position_estimator_inav_main.c as the
deadcode does not compile for qurt.

Added fixes to get a successful build for posix-arm and qurt targets.
Removed CLOCK_REALTIME def from px4_time.h for qurt and removed unused
variables in att_est_q and mc_att_control.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-08-05 18:34:46 -07:00
Mark Charlebois b046caa97b QuRT: build configuration changes
Added DSPAL header paths to toolchain_hexagon.mk.

Made changes to build configuraion for QuRT to support HIL testing.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-07-30 16:48:10 -07:00
Mark Charlebois a96db1580f Platform cleanup - remove duplicate files
The POSIX and QURT platforms contain several duplicate files.
These files have been factored out into platforms/posix/work_queue.
The config files have been updated to include the
platforms/posix/work_queue module.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-07-28 20:08:50 -07:00
Mark Charlebois 851a020461 Eagle: posix-arm and qurt changes to support Eagle HW platform
The Eagle HW platform contains both a Krait (ARMv4hf compatible) cpu
cluster and a Hexagon DSP running QuRT.

These changes support the PX4 build for Eagle.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-07-01 09:48:50 -07:00
Mark Charlebois 26d2589e97 makefile cleanup
Moved nuttx specific make rules to files in makefiles/nuttx.

All target specific makefiles are in their target sub directories.

To minimize file duplication, targets that share rules include a
common file. For example the posix and posix-arm targets both use
makefiles/posix/posix_elf.mk

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-06-16 09:58:48 -07:00
Mark Charlebois cb231e89f6 QuRT: Changes to enable qurt target to build
QuRT doesn't support unlink and does not provide getpid().
The DSPAL layer provides access to usleep so an implementation is
no longer needed.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-06-08 22:22:00 -07:00
Mark Charlebois 58e263d534 Added posix-arm target and refactored toolchain_* files
The toolchain_* files are target OS specific so they were moved to
the target OS subdir.

The gcc_version.* files are only cleared once per make instantiation so
a build that creates multiple HW targets will try to link with an
incompatible .o file (i.e. x86 build linking ARM .o).  I created
posix-arm as a separate target to fix this problem.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-06-08 22:21:59 -07:00
Mark Charlebois 6cb26de74c Multi-uORB support changes - part 1
This adds support for a dynamic build for QuRT and initial
Multi-uORB changes to enable communication between the DSP and
the application processor.

This part of the changes do not affect the POSIX build. This is
enablement for the QuRT build using Multi-uORB. The second part
of the changes will be added in a new module under src/modules.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-06-08 22:21:59 -07:00
Mark Charlebois 43345e29dc Makefile multi-target support
NuttX is still the default target and all NuttX configs can still
be built with:

make

Individual NuttX, POSIX, and QuRT configs can now be built more
easily by specifying the target and configs:

make posix posix_default
make qurt qurt_hello
make nuttx aerocore_default

Running make with just the target will make all the configs for
that target:

make nuttx
make qurt
make posix

The help is also target specific:
make nuttx help
make qurt help
make posix help

"make help" will still assume you want help for the NuttX target

Added a new QuRT config called qurt_hello as a sample config to
test buiding in different commands for separate configs.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-20 19:19:08 -07:00
Mark Charlebois a3a0d0612c QuRT: enabled more modules
rgbled is now enabled.

Saving parameters causes a crash so those commands are not enabled.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-14 09:45:03 -07:00
Mark Charlebois 8e346a06fb QuRT: enable uORB, and simulator
uORB, the simulator and simulated devices now run

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-13 18:03:08 -07:00
Mark Charlebois 884f62878d QuRT: pthread API now working
The use of std::map and static initialization was an issue.

The code was refactored to not use static initialization.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-13 16:21:52 -07:00
Mark Charlebois 3db5f3bb3b QuRT: toolchain changes
Reworking toolchain and main.cpp for QuRT to a final link can be
done and the apps.h file is autogenerated.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-12 11:37:28 -07:00
Mark Charlebois 84ca66dcf7 QuRT: updated task support based on posix fixes
The posix layer implementations should work on QuRT.

QuRT needs to provide a way for getting the current time.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-07 22:58:51 -07:00
Mark Charlebois 632f77df49 QuRT: add drivers/led
The drivers/led module was missing from the QuRT config

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-07 11:55:24 -07:00
Mark Charlebois 20d35e33da Platform header file cleanup and consolidation
Removed obsolete porting cruft from px4_XXX.h files and merged the
POSIX changes in PreflightCheck_posix.cpp back to PreflightCheck.cpp

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-24 11:45:14 -07:00
Mark Charlebois 16d6068bfd QuRT: patch for eigen
This patch is required for QuRT. comlpex.h defines "I" and it replaces "I" in the
enum definition without this patch creating an error.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-24 10:52:07 -07:00
Mark Charlebois 3336fce1f4 QuRT and POSIX changes
Partial commit of the changes for QuRT and related changes for POSIX

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-24 00:52:44 -07:00
Mark Charlebois 5d60437164 Qurt: Added more support for the QuRT target
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-20 11:37:51 -07:00
Mark Charlebois 1126e7ed52 Added config files for QuRT
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-20 11:37:51 -07:00