Commit Graph
44 Commits
Author SHA1 Message Date
ChristophTobler 0fcc54f95f mb12xx: update for new orientation convention
add possibility to specify orientation and adapt to new defaults and use px4_getopt
2017-09-25 08:52:21 +02:00
Beat Küng 546bd2b4d0 drivers: remove the overflow perf counter
This was used together with the read() interface, but we don't use that
so the counters are wrong.
2017-03-20 09:11:34 +01:00
Beat Küng 241fd629ce ERROR macro: get rid of the many 'oddly, ERROR is not defined for c++', use PX4_ERROR 2016-09-30 13:50:51 +02:00
Julian Oes 8ff237c69f Remove size optimization for individual modules
It makes more sense to set the optimization flags on a platform basis
instead of individually for each module. This allows for different
optimization options for SITL, NuttX, Snapdragon, etc.
2016-09-30 08:11:51 +02:00
Lorenz Meier 7398164fcc Updated PX4 use / API of low level GPIO and other hardware-centric system facilities 2016-05-28 14:56:17 +02:00
Daniel Agar 76387b1693 uorb autogeneration 2016-05-14 11:27:07 +02:00
Lorenz Meier fdf57e14a1 Use shorter perf names for MB12xx 2016-03-28 13:03:25 +02:00
Kabir Mohammed 792f1747c7 rangefinders : remove annoying gotos 2015-10-28 22:38:38 +01:00
Kabir Mohammed 832780b966 Fix ranger multi-advertise 2015-10-28 22:38:38 +01:00
Lorenz Meier 3c2252fa0d mb12xx: Fixed code style 2015-10-19 13:14:12 +02:00
Lorenz Meier fa5071b3c5 Remove module.mk files to prevent confusion of adopters upgrading 2015-10-06 11:23:20 +02:00
James Goppert 1d6b31d196 Switch to cmake build system. 2015-09-07 20:37:45 -04:00
Mark Charlebois a589d15c52 Refactored debug() and log() in CDev
These functions used vprintf which is not available on all platforms.
They also do not enable line and file debug output.

Changed to macros that preserve the output format.  Uses new macro that
can be used to implement per object, runtime selectable logging

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-08-11 12:07:06 -07:00
Lorenz Meier af28016a10 Merge pull request #2236 from TSC21/drivers_cleanup
drivers: added validity check
2015-06-26 07:39:09 +02:00
Lorenz Meier 4565f57468 Merged release_v1.0.0 into master 2015-05-27 15:28:41 -07:00
Lorenz Meier 7bfeb1f5ac mb12xx: Update topic names 2015-05-27 15:21:33 -07:00
Mark Charlebois 1ca05aaa64 orb_advert_t changed to void * and checks changed to nullptr
The existing orb_advert_t use thoughout the code sometimes tries
to treat it as a file descriptor and there are checks for < 0
and ::close calls on orb_advert_t types which is an invalid use
of an object pointer, which is what orb_advert_t really is.

Initially I had changed the -1 initializations to 0 but it was
suggested that this should be nullptr. That was a good recommendation
but the definition of orb_advert_t had to change to void * because
you cannot initialize a uintptr_t as nullptr.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-27 14:42:49 -07:00
Mark Charlebois a734fc96d1 extensive orb_advert_t fixes
The calls to orb_advertise were being mishandled throughout the code.
There were ::close() calls on memory pointers, there were checks
against < 0 when it is a pointer to a object and values larger than
0x7ffffffff are valid. Some places orb_advert_t variables were
being initialized as 0 other places as -1.

The orb_advert_t type was changed to uintptr_t so the pointer value
would not be wrapped as a negative number. This was causing a failure
on ARM.

Tests for < 0 were changed to == 0 since a null pointer is the valid
representation for error, or uninitialized.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-27 14:41:33 -07:00
TSC21 79e084a154 drivers: added validity check 2015-05-26 18:05:26 +01:00
Ban Siesta 9f314dd191 drivers: corrected log string 2015-05-24 20:56:25 +01:00
Ban Siesta 69cbbd9b5e distance_sensor: changed all distance sensors to orb_advertise_multi 2015-05-24 19:20:25 +01:00
Ban Siesta 0128fef8e0 drivers: more adaptations to changed message 2015-05-24 15:57:42 +01:00
Ban Siesta 103d59e9be distance_sensor: adapted message to float for distance and adapted the drivers 2015-05-24 14:28:19 +01:00
Ban Siesta a0011d2163 Merge remote-tracking branch 'px4/pr/2200' into lidarlite_merge 2015-05-24 13:59:18 +01:00
Ban Siesta 21dfd0243d drivers: use new ringbuffer namespace everywhere 2015-05-24 10:04:38 +01:00
TSC21 98d0204087 distance_sensor: update drivers 2015-05-23 21:06:19 +01:00
TSC21 43668cc8c8 distance_sensor: adopt message in both range drivers and on ekf_att_pos_estimator 2015-05-23 17:49:52 +01:00
Mark Charlebois 9758112e31 Use px4_config.h instead of nuttx/config.h
Modified code to use OS independent header file for config settings.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-20 10:55:41 -07:00
Lorenz Meier 5a2692cf3a MB12xx: move to 0 based index 2015-02-09 22:56:24 +01:00
Lorenz Meier b14e849fc4 Sonar: Set min/max distance properly, add usleep for detection 2015-01-23 16:33:24 +01:00
Jon Verbeke a23c39eec4 Sonar driver by jverbeke 2015-01-23 16:13:55 +01:00
Lorenz Meier 193a210b51 Multi sonar support by jverbeke 2015-01-23 14:51:49 +01:00
Thomas Gubler 682f30afe6 mb12xx: write min and max to report 2014-12-14 12:10:28 +01:00
Lorenz Meier 5f8baed876 mb12xx: flash efficiency 2014-07-12 21:33:34 +02:00
Lorenz Meier f2cbc7fe27 MB12xx: Fix initialiser order in class 2014-07-08 13:53:10 +02:00
akdslr ba54983cdf MB12XX Driver: Added a class instance and device specific path 2014-07-08 12:03:47 +02:00
Lorenz Meier 290b07920c Fixed missing reset of poll rate after test exit in ultrasound driver 2014-03-11 10:52:26 +01:00
Lorenz Meier 5c86eb6dd0 Fix code style of mb12xx driver, no functional changes 2014-03-08 18:48:24 +01:00
Andrew Tridgell 4893509344 drivers: report error_count in drivers where possible 2013-09-12 09:26:49 +02:00
px4dev cefc7ac00e Rework the ringbuffer class so that it's not templated, and refactor its clients so they aren't dancing around the linker anymore. 2013-09-12 00:53:08 +02:00
Andrew Tridgell b8ffb574ca mb12xx: convert to using RingBuffer class 2013-09-12 00:52:38 +02:00
Andrew Tridgell fdbc09e2a5 avoid counters going above limit in INCREMENT()
when using INCREMENT() the counter would temporarily read equal to
limit, which could cause an issue if the task is preempted.

(this macro should be in a common header, though which header?)
2013-08-28 11:16:30 +02:00
px4dev 9d6ec6b365 Restructure things so that the PX4 configs move out of the NuttX tree, and most of the PX4-specific board configuration data moves out of the config and into the board driver.
Rename some directories that got left behind in the great board renaming.
2013-08-02 22:34:55 -07:00
Lorenz Meier 5974c37abb Moved the bulk of sensor drivers to the new world 2013-04-27 14:06:23 +02:00