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

investigate consolidation of reading generation #2

Open
edaniszewski opened this issue May 18, 2020 · 0 comments
Open

investigate consolidation of reading generation #2

edaniszewski opened this issue May 18, 2020 · 0 comments

Comments

@edaniszewski
Copy link
Contributor

In the current implementation, the translation from value in the GPB message to a synse reading is very manual and a bit tedious, as it is just a wall of something like

outputs.Boolean.MakeReading(stat.GetLaneLaserReceiverPowerHighWarning()).WithContext(map[string]string{
	"lane_number": laneNumber,
	"metric":      "lane_laser_receiver_power_high_warning",
})

Not sure yet if it is possible to perhaps use reflection and some util methods to generate these in a way that is easier to read/maintain. Will need to spend some time experimenting.

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

1 participant