Remove dead code and references: ffb module, OpenJVS HAT, ghost declarations, and invalid ENCODINGS macro#152
Closed
Remove dead code and references: ffb module, OpenJVS HAT, ghost declarations, and invalid ENCODINGS macro#152
Conversation
Co-authored-by: dazzaXx <48131734+dazzaXx@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Remove unused code related to OpenJVS HAT
Remove unused OpenJVS HAT remnants from device.c and config
Mar 11, 2026
Co-authored-by: dazzaXx <48131734+dazzaXx@users.noreply.github.com>
Copilot
AI
changed the title
Remove unused OpenJVS HAT remnants from device.c and config
Remove dead code throughout codebase
Mar 11, 2026
Co-authored-by: dazzaXx <48131734+dazzaXx@users.noreply.github.com>
Copilot
AI
changed the title
Remove dead code throughout codebase
Remove dead code: ffb module, ghost declarations, and invalid ENCODINGS macro
Mar 11, 2026
Owner
|
@copilot check if the PR branch needs updating as the master branch as changed since this PR was made. |
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.
Audit and removal of code that is compiled or declared but never reachable. The
ENCODINGSmacro was additionally invalid C syntax (array literal expression used as a macro).Removed
src/ffb/— entire module deleted.initFFB(),bindController(),closeFFB()have no call sites outside the module. Removedffb.c,ffb.h, theCMakeLists.txtsource entry, and the stale#include "ffb/ffb.h"inmodernjvs.c.src/jvs/io.h—getCapabilities()andgetState()declared with no implementation inio.cand no call sites.src/jvs/jvs.h—DEVICE_ID,ENCODINGS(also syntactically invalid),STATUS_UNSUPPORTED,STATUS_OVERFLOW,REPORT_PARAMETER_ERROR2,REPORT_BUSY, and theJVS_STATUS_ERROR_UNSUPPORTED_COMMANDenum value — none referenced in any.cfile.src/hardware/device.h—setupGPIO()andsetGPIODirection()removed from the public header; both are only ever called withindevice.cvia internal forward-declarations.Also, OpenJVS HAT dead code, references were removed.
Hardening
Tightened the
setupGPIOreturn-value check from!setupGPIO()tosetupGPIO() != 1to be defensive against any future return-value range changes.✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.