FrSky receivers such as the X8R receive telemetry information over the S.Port protocol. It would be great if LP could send telemetry data to the FrSky receiver directly so it's available on the radio.
proposes a solution based on SW serial:
regarding s.port, i was thinking about sw serial, using the same method I employed for ws2811
this is the application note that describes the approach http://www.st.com/web/en/catalog/tools/FM147/CL1794/SC961/SS1743/LN1734/PF262082?s_searchtype=keyword#
STSW-STM32156 - Implementing an emulated universal asynchronous receiver transmitter on STM32F4 microcontroller series (AN4457), STMicroelectronics, STSW-STM32156
given most of the usage are for TX only ports (frsky, leds, osd) I was thinking about this approach:
a generic serial engine based on the implementation above
a queue that is used to receive messages to be sent, together with configuration data
so, actually some kind of multiplexing for the serial engine
SW serial would only require one GPIO pin per and has the added benefit of not requiring external inverter circuit.
On the GCS side we would need some new port config template which enables the SW serial capability on some of the pins, without posing any limitations on other port functions. Probably the best bet is with flexi-io (receiver port).
Telemetry like GPS coords send from flight controller to frsky receiver would be awesome feature, that helps a lot in case of plane loss when battery disconnects in a crash. Inverter shouldn't be that hard to make with rectifiing diode, just the software part is needed. Could be hidden feature, not exposed through GUI, for people who know what they're doing.
Mindnever had a dev branch porting the Taulabs implementation which uses “uninverted” S.Port. This requires either to add an external inverter OR soldering a wire to the receivers “uninverted S.Port pad”. The latter seems to be quite common for other F4 based flight controllers and in fact most FrSky receivers have these ports easily accessible. See https://oscarliang.com/uninverted-sbus-smart-port-frsky-receivers/
This in combo with the F4’s “half duplex UART” capability is the quickest implementation, and I just ported that to the latest dev code base, pull request added. ( https://bitbucket.org/librepilot/librepilot/pull-requests/537 )