bluerobotics / cockpit

An intuitive and customizable cross-platform ground control station for remote vehicles of all types.
https://docs.bluerobotics.com/ardusub-zola/software/control-station/Cockpit-1.0/overview/
Other
41 stars 18 forks source link

Allow changing the RTC configuration #1005

Closed rafaellehmkuhl closed 2 weeks ago

rafaellehmkuhl commented 2 weeks ago

This patch allows a persistent configuration of the WebRTC configurations. This allow the usage of Cockpit with BlueSim.

To test it, open a BlueSim instance and access the following address:

http://localhost:5173/?webRTCConfiguration={"iceServers":[{"urls":"stun:stun.l.google.com:19302"}]}&webRTCSignallingURI=ws://BLUE-SIM-IP:6041

You can also remove the "webRTCConfiguration" from the query parameters and set it directly in the general configuration menu. The "webRTCSignallingURI" parameter is needed since setting it in the menu is broken until #938 is merged.

image

Fix #925

ArturoManzoli commented 2 weeks ago

Just by adding the blueSim IP on the 'Global Vehicle Address' I could control the sim's ROV but the video stream didn't show up, even after I tinkered a lot with the configs.

Should it have worked?

Maybe I'm missing some config steps..

rafaellehmkuhl commented 2 weeks ago

Just by adding the blueSim IP on the 'Global Vehicle Address' I could control the sim's ROV but the video stream didn't show up, even after I tinkered a lot with the configs.

Should it have worked?

Maybe I'm missing some config steps..

Have you accessed by that URL with query parameters?

ArturoManzoli commented 2 weeks ago

Have you accessed by that URL with query parameters?

Yes, just changing the 'BLUE-SIM-IP' to the current one

Let me try again anyway

rafaellehmkuhl commented 2 weeks ago

Have you accessed by that URL with query parameters?

Yes, just changing the 'BLUE-SIM-IP' to the current one

Let me try again anyway

Remember that the BlueSim has a 5min inactivity shutdown. Once it starts, you have that time to connect.

From my experience, the ardupilot instance continues to run for 30 minutes, but the MCM does not.

ArturoManzoli commented 2 weeks ago

This is what I got: image

using: image

rafaellehmkuhl commented 2 weeks ago

This is what I got:

I feel like this is a problem with your BlueSim instance shutting down, but I will call you after lunch so we can check.

ArturoManzoli commented 2 weeks ago

Nice, the feature works well. About the interface, I have a suggestion:

Can you add a checkbox to enable/disable (with text fading) to the Custom RTC configuration? It's not clear if what is in there is already being used, or if any modifications are enabled or not:

image

rafaellehmkuhl commented 2 weeks ago

Nice, the feature works well. About the interface, I have a suggestion:

Can you add a checkbox to enable/disable (with text fading) to the Custom RTC configuration? It's not clear if what is in there is already being used, or if any modifications are enabled or not:

Good idea! Done!