Commit Graph

17 Commits

Author SHA1 Message Date
Staroselskii Georgii 8d2b587f71 AP_HAL_Linux: RPI: set signal handler iff nobody has already done it before 2016-07-27 21:30:19 +10:00
Staroselskii Georgii 5e8edcb1db AP_HAL_Linux: use NSIG instead of a hardcoded number in RCInput_RPI 2016-07-27 21:30:19 +10:00
Lucas De Marchi 71e10c9132 AP_HAL_Linux: fix include order
Sort include alphabetically and make them in order:

Main header
system headers
library headers
local headers

While reordering, change a include of endian.h to our sparse-endian.h
which is more reliant to toolchain changes.
2016-05-18 23:05:56 -03:00
Ricardo de Almeida Gonzaga 2236640f66 AP_HAL_Linux: Fix typos 2016-05-13 19:20:06 -03:00
Lucas De Marchi 2d3a62eae3 AP_HAL_Linux: RCInput_RPI: revert PWM support
This reverts support for RCInput via PWM. This is causing trouble in
some RPI-based boards, receiving a SIGSEGV. Let's revert it for now and
retry this later.

This reverts commit 5629f38b2c.
This reverts commit 51fd0b3d55.
This reverts commit 79d56073f7.
2016-01-18 20:07:42 -02:00
Lucas De Marchi c8947c3e9c AP_HAL_Linux: RCInput_RPI: provide signal information
Otherwise it's difficult to know what signal is causing the program to
exit.
2016-01-18 19:20:44 -02:00
Lucas De Marchi 5629f38b2c AP_HAL_Linux: RCInput_RPI: fix use of uninitiliazed value
../../libraries/AP_HAL_Linux/RCInput_RPI.cpp: In member function ‘virtual void Linux::RCInput_RPI::_timer_tick()’:
../../libraries/AP_HAL_Linux/RCInput_RPI.cpp:489:127: warning: ‘x’ may be used uninitialized in this function [-Wmaybe-uninitialized]
     counter = circle_buffer->bytes_available(curr_pointer, circle_buffer->get_offset(circle_buffer->_virt_pages, (uintptr_t)x));
                                                                                                                               ^
2016-01-18 19:19:36 -02:00
Lucas De Marchi 51fd0b3d55 AP_HAL_Linux: RCInput_RPI: fix coding style
- Remove trailing whitespaces
 - Remove some uneeded comments
 - Fix indentation
 - Replace some breaks inside the loop by checking in the loop itself
2016-01-15 00:16:14 -02:00
Aaron Wang Shi 79d56073f7 AP_HAL_Linux: support PWM input for BH hat 2016-01-15 00:16:14 -02:00
Lucas De Marchi a803cfd1e8 AP_HAL_Linux: RCInput: use GPIO5 for PPMSUM in bhat 2016-01-07 10:28:16 -02:00
Lucas De Marchi 321803919c Revert "AP_HAL_Linux: support PWM input for BH hat"
This reverts commit 8cca0beba9.

The PWM input using the RPI DMA is causing trouble with RPI boards using
PPMSUM. Let's revert it until the solution is found. We still leave the
ifdef in RCInput for BH hat.
2016-01-07 10:27:07 -02:00
Lucas De Marchi e0d19dc87d AP_HAL_Linux: RCInput_RPI: fix coding style 2016-01-05 15:35:34 -02:00
Víctor Mayoral Vilches fdf490dad1 HAL_Linux: RCInput support for PXFmini 2016-01-05 15:34:50 -02:00
Aaron Wang Shi 8cca0beba9 AP_HAL_Linux: support PWM input for BH hat
Support 8 PWM channels as RCInput.
2015-12-21 15:54:31 +11:00
Lucas De Marchi 2439826c19 AP_HAL_Linux: use init() method without arguments
Override the init() method from parent class that doesn't have a
parameter since it's not used here.
2015-12-02 14:49:11 -02:00
Caio Marcelo de Oliveira Filho 7675913d5b AP_HAL_Linux: use millis/micros/panic functions 2015-11-20 12:31:04 +09:00
Víctor Mayoral Vilches 47d43c64ef AP_HAL_Linux: Add RCInput_RPI, merge common code 2015-11-04 13:58:24 +11:00