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>
Made the logging macros generic so they can be used for multiple targets.
Fixed toolchain_native.mk so err.h is included from src/systemlib for posix.
Reduced debug output for uORB.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
Added -D__QDSP6_DINKUM_PTHREAD_TYPES__ to makefiles/toolchain_hexagon.mk
so the pthreads functions are properly defined.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
In the upstream tree ringbuffer.h includes the method implementations
in the header file which causes multiple definitions in the link for
other targets. Changed so ringbuffer.cpp is build separately for other
platforms and is included by ringbuffer.h on NuttX.
uORB changes do not link without uORBTest_UnitTest.cpp enabled for
the NuttX build.
px4_getopt was not exported and wasn't visible in NuttX build.
The makefiles were restored to be as close as possible to upstream
so the NuttX build builtin's work again. The code will have to be
refactored after the merge.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
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>
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>
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>
ld.gold does not support the -Ur flags and it seems some people have
ld as a link to ld.gold.
Made LD = ld.bfd to avoid confusion.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
GCC was more picky about prototypes for inlines being required.
The generate_listener.py script used incorrect printf formats and
was casting %f params to float, but printf casts all %f params to
double per the spec.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
The build fails when modules override this flag with a larger value,
and this lower value is still checked. The new flag seems to be in
addition to the old flag, not a replacement.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
There were some missed calls to open and ioctl that need to be
px4_open and px4_ioctl.
QuRT also does not provide usleep() so px4_time.h has to be included
in files calling usleep.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
The variable MAVLINK_SRC was defined and then redefined.
Commented out the first definition and moved beside that overriding
definition for visibility.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
The changes to the simulator added an include of
mavlink/include/v1.0/... to simulator.h which was not in the included paths.
The included header file also causes clang to issue a -Wpacked warning that
had to be silenced.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
Added simulated tone_alarm class and enabled led class for posix build.
The simulator implements the led_init, led_on, led_off, led_toggle calls.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
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>
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>
DSPAL for QuRT is still missing the pthreads exports and there is no
exported sleep function. These functions are stubbed out for the time being.
This is based on the 6.4.05 version of the Hexagon tools.
The Hexagon tools and DSPAL are needed to build the qurt target.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
Changed "linux" target to "posix". Most of the changes are shared with
QuRT and with OSX. The Linux specific parts are in for i2c which uses
<linux/i2c.h> and <linux/i2c-dev.h>.
There is also a check for __PX4_LINUX in mavlink for a tty ioctl that is
not supported.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
The commander module now compiles for Linux.
state_machine_helper_linux.cpp iterates over the virtual devices vs
all devices under /dev as per NuttX when disabling publishing.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
The name of the app was adc but should have been adcsim.
Added a barometer simulator.
This will allow ms56711_linux to depend on real devices and not
simulation.
Signed-off-by: Mark Charlebois <charlebm@gmail.com>