/OPi5

Primary LanguagePython

GPIO setup in Orange Pi 5

Pinout setup for orange pi 5

Download

Clone OPi5 repository

  mkdir Your-project-name
  cd Your-project-name
  git clone https://github.com/hyphen04/OPi5.git
  #if Folder name is OPi5-main rename it into OPi5

Led Blinking Test

Create Python file

  touch BlinkLed.py 

BlinkLed.py

Paste this code into BlinkLed.py

  import OPi5.GPIO as GPIO
  pin = 13   					# physical pin number of gpio
  GPIO.setmode(GPIO.BOARD)
  GPIO.setup(pin, GPIO.OUT)
  GPIO.output(pin, GPIO.HIGH)

You can find out physical pin number using this command:

  gpio readall