TC: fix working width discovery - #618
Conversation
|
@GwnDaan I made the changes but not sure why the Build started to fail. It doesn't make sense. previous build only had clang-format error... |
|
@ad3154 @martonmiklos something isn't right with our tests .. for me they seem to fail randomly... |
Yeah, it's the timing related stuff... the tests do actual thread delays and read actual system time everywhere, which is prone to unpredictability. Ideally we just need to add an abstraction to our timing interface to allow overriding it from a test environment. Adding this abstraction would also greatly speed up the tests.... |
I have opened a PR that should finally completely fix the random test failures. It was not fun, but it needed to happen, haha. |
|
Added a few more tests and implemented the same for the booms. |
2e8152b to
2f32fbe
Compare
Working Width Discovery Fix - SummaryThe PR is squashed into a single commit on top of current ProblemSection and sub boom widths were only read from Width priority (ISO 11783-10, DDI 290 SetpointWorkState)
Other changes
Tests (
|
cecac3f to
f80f4ee
Compare
Section and sub boom working widths were only read from Actual Working Width (DDI 67). Devices such as Müller Elektronik sprayers only provide Maximum or Default Working Width, so widths were missing. Per ISO 11783-10 DDI 290 (SetpointWorkState), the width is now chosen with priority Actual (DDI 67) > Maximum (DDI 70) > Default (DDI 68), independent of the order the properties appear in the DDOP. All three values are exposed; width_mm is kept for backward compatibility. Also, in the TC server, log a specific error when a working set master reports zero members. When it reports more than one member, the client is still accepted, and the unsupported member count is logged. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
95c08bb to
0cce6a8
Compare
I noticed that the Müller Elektronik sprayer working widths weren't correct.
Now it has fallbacks according to: https://www.isobus.net/isobus/attachments/345/ISO11783-11-DDI-290-SetpointWorkState-v1.pdf
Each Section Device Element shall at least provide one type of Working Width. If
more than one type of Working Width is provided, then the Section Controller shall be
capable to use the different Working Width types with the following priority: