Cooler Mann
Cooler Mann

Reputation: 81

getting error qt.qpa.xcb: could not connect to display, while trying to install X11 for remote access

Im working on a ROS Project. I want to connect a RPLIdar to my raspberry PI(Ubuntu Server 20.04 with lightdm) and display the results on my laptop (Windows with Ubuntu 20.04 VM)

Im using a guide and applying every step. However on the step about trying out the turtletim and it should display it on my pc (i hope i understood it right) im getting this error:

`qt.qpa.xcb: could not connect to display MY_CLIENT_IP:0.0 qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found. This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, xcb.

Aborted (core dumped) `

I followed this step by step tutorial: https://www.pcbway.com/project/shareproject/LiDAR_integration_with_ROS_Noetic_and_Ubuntu_on_Raspberry_Pi.html

I hope im using the right ip. On my client im using the command $ hostname -I to get the right IP

maybe im doing it too difficult? Is there an simple way to remote access your raspberry pi data? I dont really want to stream the screen, i want to use the applications on the laptop.

Sincerly Pascal

i tried some different IPs on the export Display step, i tried looking for alternatives for desktop streaming, but i didnt find anything usefull

Upvotes: 0

Views: 1869

Answers (1)

ignacio
ignacio

Reputation: 1197

You can set up the ROS_MASTER_URI and ROS_IP environment variables. If you Raspberry needs a static IP though.

Assuming that your IP is 192.168.1.204 run the commands in your raspberry pi terminal that will launch the ros nodes (or add it to your ~/.bashrc:

export ROS_MASTER_URI=http://192.168.1.204:11311
export ROS_IP=192.168.1.204

now on your machine, (assuming it has an IP 192.168.1.10 run:

export ROS_MASTER_URI=http://192.168.1.204:11311
export ROS_IP=192.168.1.10

You should be able to listen and publish topics on your machine that will interact with the ROS_MASTER setup in your Raspberry (including RViz)

Upvotes: 0

Related Questions