Connecting Jetson Nano with Arduino Mega(Connected to brushless motors)

You might find these references give you ideas:

Jetson/Tutorials/Communicate To Arduino - eLinux.org

Ultrasonic Sensor for the Jetbot - thestrongestlink