The official version of Jetson Nano's GPIO is the python version, but some big guys have open sourced the C++ version. C++ GPIO project address
Clone from Github and install it.
git clone [email protected]:pjueon/JetsonGPIO.git
cd JetsonGPIO
mkdir build
cd build
cmake ..
sudo make install
Add the following statement to the .pro file to introduce GPIO into the project
# gpio
LIBS += /usr/local/lib/lib* \
-L/usr/local/lib
INCLUDEPATH += /usr/local/include
For GPIO API details, check the warehouse address, and you can refer to the Python version of the API