# MAVSDK server wait forever, no error information

**URL:** <https://discuss.px4.io/t/mavsdk-server-wait-forever-no-error-information/33794>\
**Category:** MAVSDK\
**Created:** [August 14, 2023, 8:36am UTC](https://discuss.px4.io/t/mavsdk-server-wait-forever-no-error-information/33794 "2023-08-14T08:36:44Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Liwei\_Wang](https://discuss.px4.io/user_avatar/discuss.px4.io/liwei_wang/32/14225_2.png) [@Liwei\_Wang](https://discuss.px4.io/u/Liwei_Wang)\
**Post date:** [August 14, 2023, 8:36am UTC](https://discuss.px4.io/t/mavsdk-server-wait-forever-no-error-information/33794/1 "2023-08-14T08:36:44Z")

</div>

Hi, I am trying to connect to HereLink devices using MAVSDK java. However when I run the server, the thread is blocked forever, no following codes can be invoked, and there is no error information. Can anyone help?

This is my codes:

```auto
MavsdkEventQueue.executor().execute {
           val mavsdkServerPort: Int = mavsdkServer.run(
               "udp://192.168.144.10:14552"
           )
           // Following codes will never be invoked
           Log.i(TAG, "startMavsdkServer $mavsdkServerPort")
           drone = System("udp://192.168.144.10:14552", mavsdkServerPort)
       }

```

This is the logcat:

```auto
2023-08-14 10:21:02.035 14634-14712/io.mavsdk.androidclient I/Mavsdk: MAVSDK version: v1.4.11
2023-08-14 10:21:02.035 14634-14712/io.mavsdk.androidclient D/MAVSDK-Server: Running mavsdk_server with connection url: udp://192.168.144.10:14552
2023-08-14 10:21:02.035 14634-14712/io.mavsdk.androidclient I/Mavsdk: Waiting to discover system on udp://192.168.144.10:14552...
2023-08-14 10:21:02.036 14634-14712/io.mavsdk.androidclient D/Mavsdk: Initializing connection to remote system...
2023-08-14 10:21:02.084 14634-14639/io.mavsdk.androidclient I/art: Do partial code cache collection, code=47KB, data=54KB
2023-08-14 10:21:02.085 14634-14639/io.mavsdk.androidclient I/art: After code cache collection, code=47KB, data=54KB
2023-08-14 10:21:02.085 14634-14639/io.mavsdk.androidclient I/art: Increasing code cache capacity to 256KB
2023-08-14 10:21:02.250 14634-14715/io.mavsdk.androidclient D/Mavsdk: New: System ID: 42 Comp ID: 250
2023-08-14 10:21:02.250 14634-14715/io.mavsdk.androidclient D/Mavsdk: Component Unsupported component (250) added.
2023-08-14 10:21:02.486 14634-14715/io.mavsdk.androidclient D/Mavsdk: Component Unsupported component (68) added.
2023-08-14 10:21:02.800 14634-14715/io.mavsdk.androidclient D/Mavsdk: Component Camera 1 (100) added.

```

---

<div class="post-metadata">

**Author:** ![umexsa](https://discuss.px4.io/user_avatar/discuss.px4.io/umexsa/32/14233_2.png) [@umexsa](https://discuss.px4.io/u/umexsa)\
**Post date:** [September 6, 2023, 10:26pm UTC](https://discuss.px4.io/t/mavsdk-server-wait-forever-no-error-information/33794/2 "2023-09-06T22:26:35Z")

</div>

Hi @Liwei_Wang, what autopilot are you connecting to, SITL or a real autopilot? Is it running PX4 or Ardu firmware. What I have found with Ardu on SITL and the Cube is that you need to send a SET\_RATE\_x message to the port you are connecting to, otherwise it won’t wake up. One way to test this… start your SITL or autopilot and connect QGC to the port you are using (i.e. 14552). Once QGC has connected, disconnect QGC and then run your code. If it works, it’s the SET\_RATE\_x message issue.
