S.BUS Connection with FRSKY R9 not working on latest emlid Raspbian image

On flashing to the latest emlid image, communication with FRSKY R9 S.BUS receivers seems to be broken. The observed behavior is that the receiver receives power at startup, gains signal from the controller (ie, the light goes green and flashes as data is transmitted); and using an oscilloscope I am able to observe that a proper S.BUS signal is being sent across the signal pin to the navio2. However when attempting to perform controller calibration with QGC or Mission Planner, there is no apparent incoming signal as all channels are stuck at 0.

Tested setups: Two different navio2 boards; 2 separate RPI 3’s and an RPI 3b+ on separate burns on separate cards of separate downloads of the latest emlid image; two FRSKY R9 receivers and one FRSKY R9 slim receiver (unfortunately I don’t have any regular frequency FRSKY’s laying around at the moment - though I will have some passing through on builds next week I can test with). Rebuilding vanilla Ardupilot 3.5.5 and 3.6.0-rc4 from the mainline repo resulted in sysfs PWM issues; applying Emlid’s patches to these versions resulted in the same observed behavior.

Updating to the latest packages unfortunately does not affect the observed behavior.

Reverting to a clean download of 2017-03-23, all of the above setups (excepting the latest RPI) work again, including running a vanilla Ardupilot 3.6.0-rc4 compiled on top of 2017-03-23 (because DSHOT!).

Has anyone else run into this?

So I’ll have to admit I’m at a bit of a loss at what exactly fixed this, but I managed to knock some internal state somewhere into line in a nice deterministic way.

My intention was to bisect rcio-dkms to find out where the issue was introduced, starting at 0.9.1 - after swapping 1.0.0 for 0.9.1 (with #8572754 cherry-picked for the kernel to work), doing a shutdown with power cycle, and things worked. Eventually I stepped all the way back up to 1.0.0.

My initial thought was that I must have introduced some type of build variance, so the natural next step was to go back and compare again with a clean image. The clean image now works.

I managed to duplicate this on both of the navio2’s I have on my desk at the moment - backing off rcio-dkms to 0.9.1, playing around with the radio and watching it in your configurator of choice, shutting down and powering off, and then going back to the clean version of emlid raspbian resolves the issue permanently.

Also, it’s worth noting that this process worked equally well on the board running the updated rcio (updated before the entire process as initial troubleshooting) and non-updated rcio (updated after the entire process was completed and the receiver signal was getting through). Everything was latest versions as of 7/7/18 1000Z.