-
Notifications
You must be signed in to change notification settings - Fork 0
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/conn status #156
Feat/conn status #156
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks really good. Glad to see this get added. Once this is merged in the camera connection status can be displayed as well.
@@ -1,11 +1,14 @@ | |||
// See this page for reference of options: https://containers.dev/implementors/json_reference | |||
{ | |||
"name": "Existing Dockerfile", | |||
"image": "ghcr.io/tritonuas/obcpp:x86", | |||
"image": "ghcr.io/tritonuas/obcpp:main", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rip
@@ -46,6 +48,11 @@ GCSServer::~GCSServer() { | |||
} | |||
|
|||
void GCSServer::_bindHandlers() { | |||
this->server.Get("/", [](const httplib::Request& request, httplib::Response& response) { | |||
response.status = 200; | |||
response.set_content("Fort-nite", "text/plain"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interesting
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😳
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Related PR with tritonuas/gcs#121
Information for both here
On the OBC it implements a /connection route and a / route for connection testing purposes for the GCS. It also resets the container to :main because :x86 is currently broken.
On the GCS side of things it implements the obc connection page. There is shit CSS but it displays the info correctly.
Also, it links up the main status indicators on the topbar, but the only one that actually provides meaningful info is the obc one as we aren't really testing connection on the others I think
How To Test / Expected Behavior
Spawn up this branch's obcpp in one terminal.
Pull newest GCS and run
make build-docker
andmake run-compose
Open
localhost:5000
in web browserverify that after 2s the OBC connection is green
then visit the OBC connection page and see if it is giving the information (should be all false/null values because nothing is really connected)
Notes
General code quality on the GCS side is very bad. Also the CSS is awful. But It should work.