Add VirtualTerminalClient::get_state() - #14
Open
Arjan-Woltjer wants to merge 1 commit into
Open
Conversation
Mirrors TaskControllerClient::get_state(), which already exposes its internal state machine state via a public accessor -- VirtualTerminalClient had no equivalent. get_is_connected() only reports true once the entire handshake/upload/activate sequence completes, with no way for a consumer to distinguish "stuck waiting for VT status" from "uploading the pool" from "waiting for the end-of-pool response" while getting there. Build-verified against a real Teensy 4.1 ISOBUS project (teensy41 platform, arm-none-eabi toolchain) with a real consumer calling the new accessor.
Arjan-Woltjer
marked this pull request as ready for review
August 11, 2026 07:37
Arjan-Woltjer
commented
Aug 11, 2026
Arjan-Woltjer
left a comment
Author
There was a problem hiding this comment.
This commit acually helped a lot during testing of our objectpool. I think the upstream users should benefit from this as well.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Mirrors
TaskControllerClient::get_state(), which already exposes its internal state machine state via a public accessor --VirtualTerminalClienthad no equivalent.get_is_connected()is currently the only public signal, and it only reportstrueonce the entire handshake/upload/activate sequence completes -- there's no way for a consumer to distinguish "stuck waiting for VT status" from "uploading the pool" from "waiting for the end-of-pool response" while getting there.This is useful for diagnostics/debug UI during real hardware bring-up, where a bare boolean makes it hard to tell how far a stuck connection actually got.
Changes
isobus_virtual_terminal_client.hpp: declareStateMachineState get_state() const;next toget_is_connected().isobus_virtual_terminal_client.cpp: define it, returning the privatestatemember -- same shape asTaskControllerClient::get_state().Pure accessor addition, no behavioral change to existing code.
Test plan