-
-
Notifications
You must be signed in to change notification settings - Fork 520
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
example: added example for multiple drones #675
Conversation
Presumably this needs some work/refactoring in the connection layer. Right now all messages are sent to all links. |
Ok, refactoring done. This now works for me. |
<< "Connection error: " << connection_result_str(connection_result) | ||
<< NORMAL_CONSOLE_TEXT << std::endl; | ||
; | ||
return 1; |
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.
So if any of the port is already busy, the example exits ? Lets say I am controlling 3 drones, and 1 of them is QGC port! So, can't I just continue with those two of them ?
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.
Good point, thanks. That can be improved!
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.
I think I'd leave it like that because it's really something unexpected and it will make it harder to debug why things are not working after that.
for (int i = 1; i < argc; ++i) { | ||
ConnectionResult connection_result = dc.add_any_connection(argv[i]); | ||
if (connection_result != ConnectionResult::SUCCESS) { | ||
std::cout << ERROR_CONSOLE_TEXT |
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.
Its better std::cerr
for error messages, so that one may filter out errors only, while debugging.
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.
Its a useful example!
Thanks for the review @shakthi-prashanth-m ! |
Coveralls.io API status was orange, so let's hope it's just that. |
Still seems to fail because of coveralls... |
This adds the example started by Shayaan Haider and shared via Slack. The current state doesn't seem to be functional just yet, only one of two drones responds.
This keeps track of which system ID is behind which remote UDP port. This enables several drones to connect to one UDP sink and the SDK to talk back.
135ee9a
to
dcc2e10
Compare
This adds the example started by Shayaan Haider and shared via Slack.
The current state doesn't seem to be functional just yet, only one of
two drones responds.