Jump to content

reptile

Members
  • Posts

    7
  • Joined

  • Last visited

  1. Hi Guys, My Orange Pi Zero LTS H5 had a short circuit and no longer power up. worst that it seems that i cannot find any replacement for it as market is full of H2 & H3 variants but non is H5. Perhaps its time to upgrade Armbian & Hardware by inserting the SD card in one of the below boards: - Orange Pi Zero 2 1GB RAM with Allwinner H616 - Orange Pi R1 Plus LTS 1GB RAM RK3328 -Nanopi NEO3 Mini RK3328 (though not Orange pi but seems very similar) Though i'm not sure OS would boot on different CPU / board, (i remember doing such upgrade from h3 to 5h or zero 2 to lts) I would like to avoid re-building the OS with my programs and configurations. Would it be possible to make such upgrade? and what i will need to do in such case. Many thanks
  2. Hey All, I moved my armbian OS from OPI H5 Zero Plus2 to OPI H5 Zero Plus (the one with the LAN), the WiFi is working perfectly but the LAN is not recognized, nor i can find any sign on dmesg or boot (but its there, i see it). ifconfig and ifconfig -a show only the "wlan0" and "lo". I am using ARMBIAN 5.64.181015 nightly Ubuntu 16.04.5 LTS 4.14.76-sunxi64 with (armbian-config for Zero Plus 2) As it took me pretty much time to spin-up the OS, i would like to avoid burning a new OS. Is there a way to activate it or add/build it drivers? Many thanks
  3. As an update, on OrangePI H5 Zero Plus (the one with the LAN) the LED triggering command is a bit different (though i am using the same OS that was on Zero plus 2) echo 1 > /sys/class/leds/orangepi:green:pwr/brightness echo 0 > /sys/class/leds/orangepi:green:pwr/brightness echo 1 > /sys/class/leds/orangepi:red:status/brightness echo 0 > /sys/class/leds/orangepi:red:status/brightness
  4. I thought to use in few scenarios: -Slow Blink red on boot until rc.local -Steady or Fast red blink in rc.local depend on network connection status -Green blink in python script when all is working I'm not sure how to do it on boot, but my starting point is the simple shell echo command that i could use in rc.local and python using the line: os.system('echo 1 > /sys/class/gpio/gpio362/value') then somehow to blink it like in arduino Though it just seem too easy and good to be true, so I'm looking around for some more complex examples of blink and "direct access" to GPIOs from python Thanks for the links, i think the pyGPIO could be my neat start to blink led in python.
  5. I was wondering about the same and i answered it here: For anyone landing here and can't find answer..
  6. ok, 2nd day and starting to better understand this, will explain it loudly for myself and anyone else: Though the answer was there from the beginning, too bad that it wasn't clear for meL http://linux-sunxi.org/GPIO First we need to "create" or "attach" the GPIO port using this command: sudo echo XX > /sys/class/gpio/export The XX is a complex calculation of the GPIO: so for Orange PI Zero plus 2 H5 (should be same for h3/h2) the RED led would on GPIO PA17 and GREEN LED on GPIO PL10 (Info from here: http://linux-sunxi.org/Xunlong_Orange_Pi_Zero_Plus_2 ) The calculation would be (Letter A is 1, the "P" not counted): (1 -0) * 32 + 17 = 17 (For RED LED) while for Green LED: (12 - 1) * 32 + 10 = 362 sudo echo 362 > /sys/class/gpio/export sudo echo 17 > /sys/class/gpio/export Now lets check the status of the GPIOs: cat /sys/kernel/debug/gpio gpiochip1: GPIOs 0-223, parent: platform/1c20800.pinctrl, 1c20800.pinctrl: gpio-9 ( |reset ) out hi gpio-14 ( |sysfs ) out hi gpio-17 ( |sysfs ) in lo gpio-110 ( |sysfs ) in lo gpio-166 ( |cd ) in hi IRQ gpio-204 ( |usb0_id_det ) in lo IRQ gpiochip0: GPIOs 352-383, parent: platform/1f02c00.pinctrl, 1f02c00.pinctrl: gpio-358 ( |? ) out lo gpio-362 ( |sysfs ) in lo The GPIOs should be "out" direction (i guess because we are outputting to it), so lets fix them: sudo echo out > /sys/class/gpio/gpio362/direction sudo echo out > /sys/class/gpio/gpio17/direction Now that the direction is correct, lets try to switch them on or off: sudo echo 1 > /sys/class/gpio/gpio362/value sudo echo 0 > /sys/class/gpio/gpio362/value sudo echo 1 > /sys/class/gpio/gpio17/value sudo echo 0 > /sys/class/gpio/gpio17/value Now that the LEDs are controllable, The next challenge would be adding some rhythm to the led per hardware occasions such as heart beet, read/write.. i hope it will be easier than above
  7. Hi All, Its been a week learning, battling and reading posts on armbian forum which was very much helpful - i now starting to master orange pi and armbian! However i can't seem to understand how to trigger the two on board LEDs (Red & Green), in one of the armbian images i tested this was implemented but not in the armbian version suggested for he Orange PI Zero Plus 2 H5: https://www.armbian.com/orange-pi-zero-2-h5/ It seems that my leds folder is empty, where to download or how to populate the missing files? ls /sys/class/leds Empty folder uname -r 4.14.4-sunxi64 modprobe gpio-sunxi modprobe: FATAL: Module gpio-sunxi not found in directory /lib/modules/4.14.4-sunxi64 ls /sys/class/gpio export gpiochip0 gpiochip352 unexport ls /sys/class backlight devcoredump drm hidraw ieee80211 mdio_bus mtd pps regulator scsi_disk spi_master udc watchdog bdi devfreq extcon hwmon input mem net ptp rfkill scsi_generic spi_slave vc zram-control block devfreq-event gpio i2c-adapter iommu misc phy pwm rtc scsi_host thermal virtio-ports bsg dma graphics i2c-dev leds mmc_host power_supply rc scsi_device sound tty vtconsole Many thanks!
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines