Skip to content

Jetson NX Setup

Bryan Zheng edited this page Nov 18, 2021 · 5 revisions

ROS Installation

TODO

Remote Desktop Setup

VNC Server Setup

$ sudo apt install x11vnc 
$ mkdir ~/.vnc && echo [PASSWORD] > ~/.vnc/password # Create a password file. Replace `[PASSWORD]` accordingly.

To start the VNC server automatically at startup, go to ‘startup applications’ and create a new startup command. Give it a name and the following command:

/usr/bin/x11vnc -auth guess -forever -loop -noxdamage -repeat -passwdfile ~/.vnc/password -rfbport 5900 -shared

VNC Viewer on another PC can now be used to access the Jetson remotely by connecting to the Jetson's IP address and using the password previously set. Ensure that a HDMI emulator is connected to the Jetson, otherwise the resolution will be low.

Static IP Address Setup

To prevent the IP address of the Jetson from changing every time it boots, a static IP address can be assigned by running the following commands

$ sudo nmcli c mod [CONNECTION_NAME] ipv4.address [NEW_ADDRESS]/[CIDR]
$ sudo nmcli c mod [CONNECTION_NAME] ipv4.gateway [GATEWAY_IP]
$ sudo nmcli c mod [CONNECTION_NAME] ipv4.dns "[DNS_SERVERS]"
$ sudo nmcli c mod [CONNECTION_NAME] ipv4.method manual
$ sudo nmcli c up [CONNECTION_NAME]

Replace:

  • [CONNECTION_NAME] with the Wi-Fi connection name. Run nmcli c show to display the list of current connections.
  • [NEW_ADDRESS] with the static IP address to set.
  • [CIDR] with the CIDR representation of the subnet (usually 24).
  • [GATEWAY_IP] with the IP address of the Wi-Fi network’s gateway/router. Run nmcli dev show wlan0 | grep GATEWAY to display the address.
  • [DNS_SERVERS] with a comma-separated list of DNS server IP addresses. Google DNS servers at 8.8.8.8 and 8.8.4.4 are recommended.

Udev Rules Setup

Create /etc/udev/rules.d/99-vesc.rules and paste in the following:

KERNEL=="ttyACM[0-9]*", ACTION=="add", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="5740", MODE="0666", GROUP="dialout", SYMLINK+="sensors/vesc"

Create /etc/udev/rules.d/99-rplidar.rules and paste in the following:

KERNEL=="ttyUSB[0-9]*", ACTION=="add", ATTRS{idVendor}=="10c4", ATTRS{idProduct}=="ea60", MODE="0666", GROUP="dialout", SYMLINK+="sensors/rplidar"

Activate the rules by running

$ sudo ​udevadm control --reload-rules
$ sudo udevadm trigger​

Overclocking

sudo bash
for i in /sys/devices/system/cpu/cpu*/cpufreq/scaling_max_freq; do echo 1907200 > $i; done

References

https://f1tenth.readthedocs.io/en/latest/getting_started/software_setup/optional_software_nx.html#configuring-wifi-and-ssh https://f1tenth.readthedocs.io/en/latest/getting_started/software_setup/software_advance.html#doc-software-advance https://f1tenth.readthedocs.io/en/stable/getting_started/firmware/drive_workspace.html#udev-rules-setup