This approach uses Windows Subsystems for Linux, WSL for short.
- Go to Microsoft Store and install Ubnutu 18.04 LTS (for ROS Melodic) or Ubnutu 16.04 LTS (for ROS Kinetic) follow this video
- Open the installed Ubuntu distro you just installed and install ROS on it
- In install MobaXterm and follow the following article
Add the following lines to your ~/.bashrc
export DISPLAY=192.168.0.183:0.0 # or whatever you read on MobaXterm
alias open='explorer.exe .'
alias coding='cd /mnt/c( or any partion name like d or e)/[folder where your code is]'
If faced with error messages related to D-bus read this article
If faced with error related to Segmentation error Segmentation fault (core dumped) add the following to your ~/.bashrc
export LIBGL_ALWAYS_INDIRECT=
The solution was found here
With the help of this
Open Windows Terminal and press Ctrl+, and copy the setting in profile.json
Add this to ~/.bashrc
env=~/.ssh/agent.env
agent_load_env () { test -f "$env" && . "$env" >| /dev/null ; }
agent_start () {
(umask 077; ssh-agent >| "$env")
. "$env" >| /dev/null ; }
agent_load_env
# agent_run_state: 0=agent running w/ key; 1=agent w/o key; 2= agent not running
agent_run_state=$(ssh-add -l >| /dev/null 2>&1; echo $?)
if [ ! "$SSH_AUTH_SOCK" ] || [ $agent_run_state = 2 ]; then
agent_start
ssh-add
elif [ "$SSH_AUTH_SOCK" ] && [ $agent_run_state = 1 ]; then
ssh-add
fi
unset env
Add these to ~/.bashrc
source /opt/ros/kinetic/setup.bash
source /mnt/d/coding/svea_research/devel/setup.bash
alias qtdesigner='qtchooser -run-tool=designer -qt=5'