Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor board level RC_IN definitions and useage #6777

Merged
merged 12 commits into from Mar 31, 2017

Conversation

Projects
None yet
7 participants
@davids5
Copy link
Member

davids5 commented Mar 11, 2017

@sirPerna This should resolve the RC_INPUT is pulled to VCC issue.

Removed the legacy FMUv4 define that was activating a nonexistent
pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
to VDD.

Also detailed the connections of this pins for the board.

The simplest connection is RC_IN to a timer capture pin
and a UART.
In this case the UART_RX pin and just be left as is.
While the pin can be configured as the PPM_IN (Timer capture)
or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
facilitate binding.

Renamed the macros and defines to be more explicit as to what
Is being done and the sense of the parameters

@davids5

This comment has been minimized.

Copy link
Member Author

davids5 commented Mar 11, 2017

@pkocmoud, @eflyinghi, @iZhangHui, @zehortigoza, @PX4TestFlights

There was a ripple to many of the boards configs of a feature that was on an early prototype, that was removed. This potentially would have left an input pin driven as an output. This PR corrects that issue.

I have checked the schematics that I have, and changed the board_config and init code where applicable.

I need your help.
If you would please build and check this PR on your respective HW.

The things to vet are related to the RC_IN signal aka in SW/board config as PPM_IN aka RC_IN aka SPEKTRUM_RX. The affected features would be dsm, sbus, ppm. The other thing to look for would be falsely depending on the RC_IN to be at VDD.

Thank you!

David

David Sidrane added some commits Mar 11, 2017

David Sidrane
tap-v1 Remove GPIO_RC_OUT and vetted RC_IN wiring
   Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
David Sidrane
mindpx-v2 Remove GPIO_RC_OUT and vetted RC_IN wiring
   Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
David Sidrane
px4fmu-v4 Remove GPIO_RC_OUT and vetted RC_IN wiring
   Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
David Sidrane
fmu: Remove Legacy FMUv4 and use the abstaction SPEKTRUM_POWER
   Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Use the abstaction SPEKTRUM_POWER to enable the interface not
   the define for the GPIO pin.
David Sidrane
dsm Use the abstaction SPEKTRUM_POWER to enable the interface
   Use the abstaction SPEKTRUM_POWER to enable the interface not
   the define for the GPIO pin.

   Use the clearer macro definitions
David Sidrane
px4fmu-v4pro Remove GPIO_RC_OUT and vetted RC_IN wiring
   Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
David Sidrane
px4fmu-v5 Remove GPIO_RC_OUT and vetted RC_IN wiring
   Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_R
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
David Sidrane
px4io-v1 Remove GPIO_RC_OUT and vetted RC_IN wiring
   Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
David Sidrane
px4io-v2 Remove GPIO_RC_OUT and vetted RC_IN wiring
   Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
David Sidrane
px4nucleoF767ZI-v1 Remove GPIO_RC_OUT and vetted RC_IN wiring
   Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate bindin

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters
David Sidrane
aerofc-v1 Remove GPIO_RC_OUT and vetted RC_IN wiring
   Removed the legacy FMUv4 define that was activating a nonexistent
   pull up and on some HW driving the PPM_IN aka RC_IN aka SPEKTRUM_RX
   to VDD.

   Also detailed the connections of this pins for the board.

   The simplest connection is RC_IN to a timer capture pin
   and a UART.
   In this case the UART_RX pin and just be left as is.
   While the pin can be configured as the PPM_IN (Timer capture)
   or as SPEKTRUM_RX_AS_GPIO_OUTPUT to use it as and GPIO to
   facilitate binding.

  Renamed the macros and defines to be more explicit as to what
  Is being done and the sense of the parameters

@davids5 davids5 force-pushed the master_refactor_RC_IN branch from 1047c80 to 04a837a Mar 13, 2017

David Sidrane
Removed all SPEKTUM Power and Bind Control
   FMUv4 PRO HW does not have a controlable V3.3 on the connector
   it therefore can not support the SPEKTUM binding.
   This PR removes the Power switch controls or binding control
   interfaces from the board config
@davids5

This comment has been minimized.

Copy link
Member Author

davids5 commented Mar 13, 2017

@klopezal - rebased on on master with SAFETY SW/LED changes all SPEKTRUM Power and BIND control has been removed.

@davids5 davids5 changed the title Refactor boar level RC_IN definitions and useage Refactor board level RC_IN definitions and useage Mar 13, 2017

@pkocmoud

This comment has been minimized.

Copy link
Contributor

pkocmoud commented Mar 13, 2017

@davids5 - I have tested the following receivers using a Pixracer RC14:

FrSky X4R- SB using sBus
Spektrum AR7700 using PPM
Spektrum DSMx Satellite SPM9636 using Spektrum input and confirmed binding via QGC
Lemon DSMx RX Satellite using Spektrum input and confirmed binding via QGC
Spektrum DSM2 Satellite using Spektrum input and confirmed binding via QGC

From my testing this change causes no issues with the Pixracer.

@davids5

This comment has been minimized.

Copy link
Member Author

davids5 commented Mar 13, 2017

Thanks @pkocmoud for testing!

@eflyinghi, @iZhangHui, @zehortigoza, @PX4TestFlights - please test ASAP.

@zehortigoza

This comment has been minimized.

Copy link
Member

zehortigoza commented Mar 14, 2017

+1 Tested in AeroFC

@sirPerna

This comment has been minimized.

Copy link
Contributor

sirPerna commented Mar 14, 2017

@davids5 Tested F7. PPM is working not yet SBUS.

@davids5

This comment has been minimized.

Copy link
Member Author

davids5 commented Mar 14, 2017

@LorenzMeier - How long do you want to wait for a response from @eflyinghi or @iZhangHui before merge?

@davids5

This comment has been minimized.

Copy link
Member Author

davids5 commented Mar 21, 2017

@pkocmoud - Would you reload this and test the RC post calibration.

@iZhangHui

This comment has been minimized.

Copy link
Contributor

iZhangHui commented Mar 21, 2017

@davids5 Sorry, we will give test results today.

@iZhangHui

This comment has been minimized.

Copy link
Contributor

iZhangHui commented Mar 21, 2017

@davids5 Tested in MindPX. All of PPM, FrSky sBus, Spektrum DSM2 are working.

@davids5 davids5 requested a review from julianoes Mar 21, 2017

@davids5

This comment has been minimized.

Copy link
Member Author

davids5 commented Mar 21, 2017

@iZhangHui

Thank you for testing it.

@LorenzMeier - This is ready. Any issues that were found on FMUv4 are from the "HIL reset fix" already on master.

@julianoes
Copy link
Contributor

julianoes left a comment

Reviewed

@davids5 davids5 merged commit eb86730 into master Mar 31, 2017

6 checks passed

ci/circleci Your tests passed on CircleCI!
Details
continuous-integration/sitl/pr Build finished.
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
coverage/coveralls Coverage increased (+0.03%) to 18.028%
Details
semaphoreci The build passed on Semaphore.
Details

@julianoes julianoes deleted the master_refactor_RC_IN branch Mar 31, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.