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

Spurious send tries in backend #609

Closed
julianoes opened this issue Nov 23, 2018 · 9 comments
Closed

Spurious send tries in backend #609

julianoes opened this issue Nov 23, 2018 · 9 comments
Labels
beginner A good issue for someone that only gets started bug help wanted

Comments

@julianoes
Copy link
Collaborator

julianoes commented Nov 23, 2018

When the backend is started, something tries to send messages even though we have not discovered a vehicle.

The output is this:

[03:39:09|Info ] DronecodeSDK version: 0.9.0 (dronecode_sdk_impl.cpp:24)
[03:39:09|Debug] New: System ID: 0 Comp ID: 0 (dronecode_sdk_impl.cpp:284)
[03:39:09|Info ] Server set to listen on 0.0.0.0:50051 (grpc_server.cpp:40)
[03:39:09|Info ] Server started (grpc_server.cpp:24)
[03:39:09|Info ] Waiting to discover system... (connection_initiator.h:57)
[03:39:10|Error] No known remotes (udp_connection.cpp:130)
[03:39:10|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:11|Error] No known remotes (udp_connection.cpp:130)
[03:39:11|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:12|Error] No known remotes (udp_connection.cpp:130)
[03:39:12|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:13|Error] No known remotes (udp_connection.cpp:130)
[03:39:13|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:14|Error] No known remotes (udp_connection.cpp:130)
[03:39:14|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:15|Error] No known remotes (udp_connection.cpp:130)
[03:39:15|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:16|Error] No known remotes (udp_connection.cpp:130)
[03:39:16|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:17|Error] No known remotes (udp_connection.cpp:130)
[03:39:17|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:18|Error] No known remotes (udp_connection.cpp:130)
[03:39:18|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:19|Error] No known remotes (udp_connection.cpp:130)
[03:39:19|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:20|Error] No known remotes (udp_connection.cpp:130)
[03:39:20|Error] send fail (dronecode_sdk_impl.cpp:90)
[03:39:21|Error] No known remotes (udp_connection.cpp:130)
[03:39:21|Error] send fail (dronecode_sdk_impl.cpp:90)

Steps to reproduce:

  1. Don't run PX4 SITL, make sure nothing would connect.
  2. make BUILD_BACKEND=1 && build/default/backend/src/backend_bin
@julianoes julianoes added bug help wanted beginner A good issue for someone that only gets started labels Nov 23, 2018
@jarednm
Copy link

jarednm commented Jan 7, 2019

Any update on this? I have the same issue.

@JonasVautherin
Copy link
Collaborator

As it is a "beginner" issue, we're keeping it open, hoping that somebody will feel like contributing :-)

@kaili302
Copy link
Contributor

Bug found^^ My laptop is too slow to build the project, will send a pr tomorrow

@hamishwillee
Copy link
Collaborator

You know that MAVLink components should publish heartbeats even if they haven't discovered other systems yet, right?

@julianoes
Copy link
Collaborator Author

You know that MAVLink components should publish heartbeats even if they haven't discovered other systems yet, right?

From my understanding that's not true. Systems such as drones should be sending heartbeats and ground stations are supposed to listen for heartbeats. Once they receive something, they can (don't have to) respond using heartbeats.

@hamishwillee
Copy link
Collaborator

You know that MAVLink components should publish heartbeats even if they haven't discovered other systems yet, right?

From my understanding that's not true. Systems such as drones should be sending heartbeats and ground stations are supposed to listen for heartbeats. Once they receive something, they can (don't have to) respond using heartbeats.

Not what the spec says. Which does not mean you are wrong, but that we need this confirmed.
I will confirm in dev call.

@julianoes
Copy link
Collaborator Author

As far as I know, QGC does not do it either, at least on UDP because it would not even know where to send heartbeats. The port was not defined until recently when it was written in the port diagram. The other example is MAVROS which does send stuff by assuming the SITL port which just always happened to be the same (14557 I think).

@hamishwillee
Copy link
Collaborator

As discussed in devcall. You have a good point, with the result that you now have action to work out best way to handle connection, vehicle discovery and system id allocation mechanisms. That'll learn ya!

@julianoes
Copy link
Collaborator Author

Fixed by #674.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
beginner A good issue for someone that only gets started bug help wanted
Projects
None yet
Development

No branches or pull requests

5 participants