


The schematic is shown here.Solution 1: Create a Device ID for your NVIDIA Graphics Card The sample code used above is modified and two GPIO pins on the expansion header are connected to the control pins of the H bridge on the L293D motor driver. The L293D H-bridge motor controller is used with a DC motor to control the motor in either direction. The GPIO pins can be used to simply trigger digital signals to control the motor driver running a DC motor. Controlling a DC Motor Using a Python Application GPIO.cleanup() is used to reset the pin condition to default. Using the GPIO.output(), the output_pin value is toggled every second.

In the setup line, the output_pin is set as OUTPUT and the initial state is set HIGH. Inside the main function, the GPIO mode is set to BCM. The available modes are BOARD, BCM, CVM, and TEGRA_SOC. These pin modes are configurable via the Jetson.GPIO library API. The expansion header is designed to be compatible with multiple pin numbering styles followed on other platforms like the RPi. The output_pin is defined as 18 for the BCM layout corresponding to physical pin 12 on the J41 expansion header. Run the following commands in the terminal.Connect an LED to the J41 expansion header with the +ve end to pin 12 and -ve pin to GND.While the pins on the header provide very low current, it is sufficient enough to light up a small LED.

The documentation provided by Nvidia explains the involved steps but is a fairly complicated task. Thus, to use the PWM hardware, the system PinMux must be configured to provide the functionality to the PWM pins. Unfortunately, the Nano module is not inherently configured to define the connection to the PWM hardware. It does not support any software-generated PWM. The expansion header only has 2 PWM channels directly connected to the hardware PWM controllers. The expansion header has multiple ground pins as well. The board also provides two 3.3V (pins 1 and 17) and two 5V (pins 2 and 4) power sources. Pins 8 and 10 are the UART transmitter (TX) and receiver (Rx) pins, respectively. These are pins 3 and 5 (I2C SDA pins) and pins 27 and 28 (I2C SCL pins). The I2C pins are connected to an intermediate level shifter to change voltages from 1.8V on the module to 3.3V on the standard I2C interface. All except the I2C communication pins on the header are directly connected to the Jetson Nano module.
