Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(color): customizable switch UI support #5025

Closed
wants to merge 7 commits into from

Conversation

3djc
Copy link
Collaborator

@3djc 3djc commented May 17, 2024

Add custom switch UI support to main branch.

Hardware support was already introduced as part of adc refactor

@pfeerick pfeerick changed the title feat: colorlcd custom switch UI support feat(color): customizable switch UI support May 17, 2024
@pfeerick pfeerick added color Related generally to color LCD radios house keeping 🧹 Cleanup of code and house keeping labels May 17, 2024
@pfeerick pfeerick added this to the 2.11 milestone May 17, 2024
@pfeerick pfeerick added the enhancement ✨ New feature or request label May 17, 2024
@pfeerick
Copy link
Member

I have no problem with fd52437 being reverted... while it does reduce the amount of repetition, I think it starts to blur the lines between driver and UI/helper code too much... It seems like instead of via includable headers for files like led_driver, some function protos are declared in board.cpp as needed? Some protos are in the wrong place though... as getFSLogicalState getFSPhysicalState , getFSPreviousPhysicalState and evalFunctionSwitches are all defined in switches.cpp, but not declared in switches.h

@3djc
Copy link
Collaborator Author

3djc commented May 18, 2024

Not sure I'm following your comment @pfeerick . Seems to me it is now, thanks to Philmoz changes, quite nice

@pfeerick
Copy link
Member

Not sure I'm following your comment

Why were getFSPhysicalState , getFSPreviousPhysicalState and evalFunctionSwitches declared in board.h instead of switches.h?

I can see why

void fsLedOff(uint8_t);
void fsLedOn(uint8_t);

were since there is no other header defining them.

@3djc
Copy link
Collaborator Author

3djc commented May 18, 2024

History (or copy/paste of history). i think having those under switches.h like Phil changed is much better, but I think we all violently agree :D

@pfeerick
Copy link
Member

Like I changed, actually 😆 Ok, good, just wanted to make sure I wasn't missing something. Think I will need to move fsLedOn / fsLedOff / getFSLedState back into board.h as they actually come out of led_driver.cpp, but the rest can stay where they are.

@3djc
Copy link
Collaborator Author

3djc commented May 18, 2024

My appologies ! No no makes a lot more sense this way.

@pfeerick
Copy link
Member

Nice! :)

@3djc
Copy link
Collaborator Author

3djc commented Jun 2, 2024

This PR is now obsolete given some of the changes that have happened. I think I'll probably do very soon a t15 pr for 2.11 that will include an updated version of this

@pfeerick
Copy link
Member

pfeerick commented Jun 3, 2024

May also need some changes as 40fd258 may not actually work once the T15 is added to the mix... it seems the build will still break either with that radio, or once DEBUG build is added to the mix.

@3djc 3djc closed this Jun 3, 2024
@3djc 3djc reopened this Jun 3, 2024
@3djc 3djc closed this Jun 3, 2024
@3djc 3djc mentioned this pull request Jun 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
color Related generally to color LCD radios enhancement ✨ New feature or request house keeping 🧹 Cleanup of code and house keeping
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants