Define udd_g_ctrlreq in main.c instead of usb_device.c#438
Closed
brentfpage wants to merge 1 commit intoespotek-org:masterfrom
Closed
Define udd_g_ctrlreq in main.c instead of usb_device.c#438brentfpage wants to merge 1 commit intoespotek-org:masterfrom
brentfpage wants to merge 1 commit intoespotek-org:masterfrom
Conversation
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.
Update: turned out to be unrelated to the firmware (#439)
It turns out that removing the definition ofudd_g_ctrlreqfrom main.c in the firmware caused mode-changes (e.g., Ch1 scope -> Ch1 and Ch2 scope) to no longer work. This was done in #404 becauseudd_g_ctrlreqwas also defined in usb_device.c, which led to a compilation error. The definition in usb_device.c was kept.This PR moves the sole definition ofudd_g_ctrlreqfrom usb_device.c to main.c. Mode-changes now work again, but I'm at a loss as to why. How is main.c special apart from containing the entry point for the program (int main(void) {...})?My bad – mode-changes are non-functional in the repo's current firmware source code (NOT in compiled versions that are packaged with the applications; those are functional), but I'm now almost certain that the revisions above don't fix things. I plan to next check the casts that I made in udc.c in #404 .