MissionPlanner icon indicating copy to clipboard operation
MissionPlanner copied to clipboard

Dronecan set param function sending incorrect value for integer strings

Open mwrightE38 opened this issue 3 years ago • 2 comments

Issue details

Large strings that can equate as an integer number cause the dronecan set parameter function to send in scientific notation.

Version

1.3.74 checked on master and it's still present.

Platform

[ X] All [ ] AntennaTracker [ ] Copter [ ] Plane [ ] Rover [ ] Sub

Airframe type

Any

Hardware type

Cube orange / bluemark remote ID module. Hardware type doesn't effect the issue.

Logs

No logs but in the function here https://github.com/ArduPilot/MissionPlanner/blob/master/ExtLibs/DroneCAN/DroneCAN.cs#L2024

When a string is greater than 12 digits all numeric (probably less than this number. This is the length of the number I was using.) the object converts the string into to scientific notation.

mwrightE38 avatar May 01 '23 20:05 mwrightE38

Example number?

meee1 avatar May 01 '23 23:05 meee1

ok found it

https://dotnetfiddle.net/NkezWD

meee1 avatar May 01 '23 23:05 meee1