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

Make SendableChooser dashboard widget have priority over robot #206

Closed
bradamiller opened this issue Aug 18, 2016 · 5 comments
Closed

Make SendableChooser dashboard widget have priority over robot #206

bradamiller opened this issue Aug 18, 2016 · 5 comments

Comments

@bradamiller
Copy link
Contributor

When a team selects an autonomous mode on the dashboard, then restarts (or starts) the robot, the robots default value for the sendable chooser overwrites the user selected value since it came in after the dashboard started. The desktop value should have priority so they can set preferences before the robot is finished booting. This seems to make sense unless someone can come up with a counter-example where the newer robot value should take priority over the users input at the dashboard.

I think the list of values is showing up because the dashboard layout is saved.

@AustinShalit
Copy link
Member

AustinShalit commented Aug 18, 2016

Could we flag the selected value as persistent to achieve the result?

@ThadHouse
Copy link
Member

Persistent values wouldn't work for this in certain cases. For instance, if the persistent value is set to mode 2, but the SmartDashboard selects mode 3 for the next match, mode 2 would be the one selected. This is because when a client connects to a server it overwrites any client entries with ones the server has.

One way to solve this would be to use SetDefault on the RobRio side to set the value at startup, and then a change in the NetworkTables protocol to allow certain values to be flagged as client override, where if the server is sending a value on initial connection that exists on the client already, the client ignores it, and sends the proper value back to the server.

@PeterJohnson what do you think?

@bradamiller
Copy link
Contributor Author

I was thinking that if the user explicitly set the value in the UI in the dashboard, they meant it to have that value and it shouldn't get overridden by the default value that is in the robot on startup.

@AustinShalit
Copy link
Member

Closes with wpilibsuite/SmartDashboard#6

@PeterJohnson
Copy link
Member

wpilibsuite/SmartDashboard#6 has been merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants