basic SSH
SSH lets us connect to a computer through the internet. Its useful because for the jetson we don’t need to bring a monitor+keyboard everywhere we go. We just need a laptop and a connection to connect to the jetson. It is also useful for wireless setups so when the robot is moving so we can still be connected to the jetson.
SSH command
Note: make sure you are on the same wifi as the jetson / computer you want to connect to (for Rose students you may need to use a VPN if your off campus)
How to get the ip of your jetson without a monitor?
Follow this guide: Connect to jetson using USB
How do I get the ip of a computer?
run:
ifconfig
and look at where it says inet: ...
To make check if you laptop can “see” the other computer run:
ping <ip of computer to ssh into>
example:
If you get a response then that likely means the computers can ssh to each other
Forward windows
If you want to see a window pop up in your program over SSH say for example an OpenCV window of what your camera you can add the -X
flag
ssh -X <username>@<ip of computer to ssh into>
you can test this by running xclock
though the ssh connection and see a window get passed though
Tailscale
Tailscale is a vpn that lets you buy pass the problem of always getting the ip of the jetson
SSH with VS code
I recommend ssh with this method so you are able to edit files and not need to use vim or nano. You are also able to open multiple terminals this way too.
Another nice feature is, if you saved your workspace, every time you reopen vs code it automatically tries to connect via ssh.