Remove SetupEvent/AnimatedEvent — dome drive is now a plain object#67
Merged
thePunderWoman merged 1 commit intomainfrom Apr 21, 2026
Merged
Conversation
DomeDriveRoboClaw no longer inherits SetupEvent or AnimatedEvent. setup() and animate() are now called explicitly by AmidalaController, which is already in the ReelTwo event pool. This also fixes a subtle ordering bug: previously fDomeDrive.setup() was called before AmidalaController::setup() (members register before the class itself), so homing started with default config values. Now setup() is called explicitly at the end of the RoboClaw config block, after all parameters from EEPROM/config.txt have been applied. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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
DomeDriveRoboClawno longer inheritsSetupEventorAnimatedEvent. It is a plain C++ class with no ReelTwo event-loop dependency.setup()andanimate()are called explicitly byAmidalaController, which is already in the ReelTwo event pool.Bonus fix: setup ordering bug
Previously,
fDomeDrive.setup()was called beforeAmidalaController::setup()because member objects register withSetupEventbefore the owning class does. This meant homing started with default config values (default QPPS, front offset, stall timeout, etc.) — the EEPROM/config.txt values were applied only after homing had already begun.Now
fDomeDrive.setup()is called explicitly at the end of the RoboClaw config block inAmidalaController::setup(), after all parameters are applied.What's left of ReelTwo in the dome drive
JoystickController— the hardware state struct for the PS controllerReelTwo.h— forDEBUG_PRINT/DEBUG_PRINTLNmacrosNeither is a structural dependency on the ReelTwo architecture.
Test plan
pio run)pio test -e native)🤖 Generated with Claude Code