EdgeTX / edgetx

EdgeTX is the cutting edge open source firmware for your R/C radio
https://edgetx.org
GNU General Public License v2.0
1.49k stars 314 forks source link

DSMR Telemetry inconsistent refresh for telemetry and Spektrum DSMR Smart ESC RPM Value issue #5231

Open jslatten opened 3 days ago

jslatten commented 3 days ago

Is there an existing issue for this problem?

What part of EdgeTX is the focus of this bug?

Transmitter firmware

Current Behavior

I'm currently facing two issues with telemetry with my recently purchased Radiomaster MT12 4in1 transmitter and Spektrum SR315 DSMR receiver. I'm running the latest release of EdgeTX 2.10.1 and have updated the Multimod firmware to V1.3.4.0 (TAER channel mapping if it matters).

The first issue is related to extremely inconsistent telemetry updates from the connected Spektrum Firma Smart ESC (120a - 4s Max) when connected from my Radiomaster MT12 radio to the Spektrum SR315 Receiver. Sometimes I'll receive refreshed telemetry data every several seconds and other times I'll only get updated telemetry once every 1-2 minutes. Sometimes I'll get no telemetry data at all which typically requires powering the vehicle and transmitter off and on several times until I eventually start to receive telemetry data from the Smart ESC again. I'm within 1-5 feet from the vehicle/receiver for all of these tests. I'm looking to receive consistently quick updates of the data for the following sources: Erpm, EVIN, TFET, ECUR, ETHR, and A2. On the other hand I believe there are several other telemetry sources from the SR315 receiver or from the RM MT12 that seem to be consistently available and refresh quite often i.e TRSS, FDEa, FLss, Hold. I believe I'm receiving those every 1 second or possibly more often than that.

I also have a Spektrum DX6C transmitter that has full telemetry and I've ran a number of tests with the Spektrum transmitter and it seems to have a live stream of all of the ESC telemetry that I'm interested in and it's being refreshed more than once per second it seems. Prior to switching to the RM MT12 transmitter I haven't experienced any issues with receiving telemetry on the Spektrum DX6C transmitter so I don't think it's the Spektrum receiver.

My second issue is related to the Erpm telemetry source that I'm receiving from the Spektrum Smart ESC...The data source is auto-detected with rpm unit type. I had noticed that the Erpm value was around double what the maximum should have been. Measured with Spektrum DX6C the RPM value was about 30500 rpm, but I was seeing values of close to 65,000+ rpm. I tried changing the number of poles to 4 to match the motor, but it was still incorrect. Afterwords, I changed the unit type from rpm to undefined and noticed the value reported was way too low so I tried different values for Ratio and Offset and ended up landing on around 13 for Ratio and 0 for offset. I think I'm in the general ballpark of where it should be, but may be slightly off with the ratio. I'd suspect the right Ratio value is in the range of 12.9 to 13.1. With how inconsistent telemetry refreshes are happening I was having a difficult time setting up a good test between the DX6C transmitter and the MT12. I would end up running the battery down which would make finding the max rpm at 100% Throttle in order to properly compare between the two difficult.

I'm at a loss as to why these issues are occurring, and I'm hoping that someone can assist in debugging this issue.

Expected Behavior

Receive nearly live updates of all Spektrum Smart ESC Telemetry i.e Erpm, ECUR, EVIN, etc

Steps To Reproduce

  1. Bind Radiomaster MT12 to Spektrum DSMR receiver using type DSM subtype R 1F.
  2. Go to Model > Telemetry and Detect telemetry.
  3. Monitor telemetry values coming from connected Spektrum Smart ESC i.e Erpm, EVIN, ECUR, ETHR, etc.

Version

2.10.1

Transmitter

RadioMaster MT12

Operating System (OS)

Linux

OS Version

Ubuntu 23.10

Anything else?

No response

3djc commented 3 days ago

@frankiearzu any thoughts ?

frankiearzu commented 2 days ago

Don't have a surface RX to test, but with Avian ESC and Smart RX (very similar in telemetry) refreshes properly Erpm, Evin,ECur, etc. The EdgeTX Telemetry DSM code process the telemetry as soon as is passes from the Multi-Module. Maybe this could be a good question for the multi-module forum or github.

As for the Erpm sensor adjustment.

  1. The Unit RPM is calculated DisplayRPM = (SensorRPM * multiplier) / blades. So for 1/2, set Multiplier=1, and Blades/Poles=2
  2. If you use the generic unit (ratio/offset), ratio can be use to divide. Ratio=25.5 is 100%, so if you need 1/2, that will be a Ratio=12.7 (There is already an enhancement in the queue for that page to display percentage :-).

Option 1 (Unit RPM) is preferable.

jslatten commented 11 hours ago

Thank you for the proper settings for RPM. I'm pretty new to RC so I'm still a bit confused about the poles/blades setting being set to 2. I thought it meant the number of poles on the motor which I thought is 4 for my brushless.

So for the inconsistent telemetry you are saying it's something with the multi-module firmware instead - I'll try posting something on their project as well to see if I can uncover why its not updating correctly. It's very very annoying and makes most of the telemetry I have almost unusable.

frankiearzu commented 8 hours ago

Without knowing the formula is not that easy to decirpher what values to use. Had to read the code to remember :-)

For the telemetry refresh, I see my ESC data refreshed periodically without delayed.. but is an AVIAN ESC with an AR637 (For planes). Don't have any surface RX to try to replicate. Maybe Pascal (from Multi-module) can replicate it. Is not normal that is gets that slow. The signal quality are refreshed very fast, example FLss (Frames Looses). The ESC should also refresh at least once per sencond.