olivluca

Members
  • Content count

    36
  • Joined

  • Last visited

  1. AFAIK drive level refers to the current that a gpio configured as output can supply, unfortunately I don't remember where I read it and cannot find the documentation right now.
  2. Does anyone sell an Orange Pi Plus 2 or 2E?

    You can buy from aliexpress, shipments to Spain lately are reasonably fast (2/3 weeks)
  3. It turns out that after a few hours of running motion the captured image have a green tint (not like the above sample at 1600x1200, just a normal image with almost no red-blue components). Since I'm using the beta repository I though it was a problem of the kernel of the day, in fact updating and rebooting solved the issue. It turns out that's enough to stop and start motion to get a normally coloured image. Do you think it's an hardware or driver issue?
  4. how to clone microsd card data only

    You could resize the partition with gparted, but I don't know if is there an equivalent that runs under windows.
  5. I made my previous tests using an headphone, now, connected to an amplifier and speakers, the effect is much less pronounced. One channel still bleeds into the other but I think it is usable for my purpose.
  6. Strangely enough the IOCTL interface works (strange because, looking at the source of sunxi_wdt in theory either writing to the device or using the ioctl should trigger the same function watchdog_kick) import time import fcntl f=open('/dev/watchdog','w') try: while True: time.sleep(1) print '.' fcntl.ioctl(f,0x80045705) #WDIOC_KEEPALIVE except KeyboardInterrupt: print 'end' f.write('V') f.close()
  7. I have a different problem: I'm trying to ping /dev/watchdog directly, without using the watchdog package. The problem is that the watchdog resets the board (opi pc, legacy kernel) even if I keep writing to /dev/watchdog. If I write the magic char 'V' to /dev/watchdog before the timeout expires then it doesn't reset (and that's ok). This is the test python script I'm using, I'm using chr(0) because that's what the sample program does, but anything (except 'V' for obvious reasons) should work: import time f=open('/dev/watchdog','w') try: while True: time.sleep(1) print '.' f.write(chr(0)) except KeyboardInterrupt: print 'end' f.write('V') f.close()
  8. Found it, the csi interface isn't supported in mainline kernel
  9. Today I tried mainline kernel but there's no gc2035 module there. Is it so or did I miss something?
  10. This patch solves it for me (Edit but I think there should be a better way) diff --git a/OPi/GPIO.py b/OPi/GPIO.py index 775134e..aa8e77b 100644 --- a/OPi/GPIO.py +++ b/OPi/GPIO.py @@ -239,6 +239,7 @@ Methods """ import warnings +import time from OPi.constants import IN, OUT from OPi.constants import LOW, HIGH # noqa: F401 @@ -358,6 +359,7 @@ def setup(channel, direction, initial=None, pull_up_down=None): else: raise e + time.sleep(0.1) sysfs.direction(pin, direction) _exports[channel] = direction if direction == OUT and initial is not None:
  11. On my orangepi pc (legacy kernel) I'm trying to using separately the left and right channel as two separate sound cards (to be used by two different programs). I have a working asoundrc for that, but the problem is that the left channel leaks into the right one and viceversa. They also do the same on my laptop, but there it's hardly noticeable. It's not a matter of my asounrc, I confirmed it also with speaker-test. I suppose it's a hardware issue, right? BTW the right and left channel are inverted (and that could be a driver issue). This is the my asoundrc, the !default line is because one of the two programs is linphone and I couldn't find a way to make it use a named, virtual, soundcard. pcm.my_card { type hw card 0 } pcm.my_card_dmix { type dmix ipc_key 1024 ipc_key_add_uid 1 ipc_perm 0666 slave { pcm "my_card" channels 2 } bindings { 0 0 1 1 } } pcm.mono_zone1 { type plug slave { pcm "my_card_dmix" channels 2 } ttable.0.0 1 } pcm.!default { type plug slave { pcm "my_card_dmix" channels 2 } ttable.0.1 1 }
  12. \var\log & \var\log.hdd

    And file ownership should also be fixed # dpkg -L linux-xenial-root-orangepipc | xargs ls -n | grep '1001 1001' ls: cannot access '/etc/update-motd.d/99-point-to-faq': No such file or directory ls: cannot access 'package': No such file or directory ls: cannot access 'diverts': No such file or directory ls: cannot access 'others': No such file or directory ls: cannot access 'to:': No such file or directory ls: cannot access '/etc/mpv/mpv-dist.conf': No such file or directory -rw-r--r-- 1 1001 1001 56 Aug 1 15:17 /etc/apt/apt.conf.d/71-no-recommends -rwxr-xr-x 1 1001 1001 36 Aug 1 15:17 /etc/cron.daily/log2ram -rw-r--r-- 1 1001 1001 83 Aug 1 15:17 /etc/cron.d/armbian-updates -rw-r--r-- 1 1001 1001 156 Aug 1 15:17 /etc/default/armbian-motd.dpkg-dist -rw-r--r-- 1 1001 1001 280 Aug 1 15:17 /etc/default/log2ram.dpkg-dist -rwxr-xr-x 1 1001 1001 308 Aug 1 15:17 /etc/initramfs/post-update.d/99-uboot -rwxr-xr-x 1 1001 1001 1022 Aug 1 15:17 /etc/kernel/preinst.d/initramfs-cleanup -rw-r--r-- 1 1001 1001 525 Aug 1 15:17 /etc/network/interfaces.bonding -rw-r--r-- 1 1001 1001 1028 Sep 10 12:16 /etc/network/interfaces.default -rw-r--r-- 1 1001 1001 280 Aug 1 15:17 /etc/network/interfaces.espressobin -rw-r--r-- 1 1001 1001 197 Aug 1 15:17 /etc/network/interfaces.hostapd -rw-r--r-- 1 1001 1001 218 Aug 1 15:17 /etc/network/interfaces.network-manager -rw-r--r-- 1 1001 1001 495 Aug 1 15:17 /etc/network/interfaces.r1 -rw-r--r-- 1 1001 1001 610 Aug 1 15:17 /etc/network/interfaces.r1router -rw-r--r-- 1 1001 1001 359 Aug 1 15:17 /etc/network/interfaces.r1switch -rw-r--r-- 1 1001 1001 212 Aug 1 15:17 /etc/profile.d/check_first_login_reboot.sh -rw-r--r-- 1 1001 1001 174 Aug 1 15:17 /etc/profile.d/ssh-title.sh -rw-r--r-- 1 1001 1001 217 Aug 1 15:17 /etc/X11/xorg.conf.d/01-armbian-defaults.conf -rw-r--r-- 1 1001 1001 384 Aug 1 15:17 /lib/systemd/system/firstrun.service -rw-r--r-- 1 1001 1001 30 Aug 1 15:17 /lib/systemd/system/getty@tty1.service.d/10-noclear.conf -rw-r--r-- 1 1001 1001 448 Aug 1 15:17 /lib/systemd/system/log2ram.service -rw-r--r-- 1 1001 1001 426 Aug 1 15:17 /lib/systemd/system/resize2fs.service -rw-r--r-- 1 1001 1001 33 Aug 1 15:17 /lib/systemd/system/serial-getty@.service.d/10-term.conf -rw-r--r-- 1 1001 1001 28 Aug 1 15:17 /lib/systemd/system/systemd-modules-load.service.d/10-timeout.conf -rw-r--r-- 1 1001 1001 287 Aug 1 15:17 /lib/udev/rules.d/71-axp-power-button.rules -rwxr-xr-x 1 1001 1001 3783 Aug 1 15:17 /usr/lib/armbian/apt-updates -rw-r--r-- 1 1001 1001 84132 Aug 1 15:17 /usr/lib/nand-sata-install/a10/bootloader/boot.axf -rw-r--r-- 1 1001 1001 126 Aug 1 15:17 /usr/lib/nand-sata-install/a10/bootloader/boot.ini -rw-r--r-- 1 1001 1001 146 Aug 1 15:17 /usr/lib/nand-sata-install/a10/bootloader/linux/linux.ini -rw-r--r-- 1 1001 1001 321016 Aug 1 15:17 /usr/lib/nand-sata-install/a10/bootloader/u-boot.bin -rw-r--r-- 1 1001 1001 118912 Aug 1 15:17 /usr/lib/nand-sata-install/a20/bootloader/boot.axf -rw-r--r-- 1 1001 1001 91 Aug 1 15:17 /usr/lib/nand-sata-install/a20/bootloader/boot.ini -rw-r--r-- 1 1001 1001 152 Aug 1 15:17 /usr/lib/nand-sata-install/a20/bootloader/linux/linux.ini -rw-r--r-- 1 1001 1001 309228 Aug 1 15:17 /usr/lib/nand-sata-install/a20/bootloader/linux/u-boot.bin -rw-r--r-- 1 1001 1001 60 Aug 1 15:17 /usr/lib/nand-sata-install/exclude.txt -rwxr-xr-x 1 1001 1001 1458 Aug 1 15:17 /usr/sbin/log2ram -rw-r--r-- 1 1001 1001 1067 Aug 1 15:17 /usr/share/log2ram/LICENSE -rw-r--r-- 1 1001 1001 56 Aug 1 15:17 71-no-recommends -rw-r--r-- 1 1001 1001 83 Aug 1 15:17 armbian-updates -rwxr-xr-x 1 1001 1001 36 Aug 1 15:17 log2ram -rw-r--r-- 1 1001 1001 156 Aug 1 15:17 armbian-motd.dpkg-dist -rw-r--r-- 1 1001 1001 280 Aug 1 15:17 log2ram.dpkg-dist -rwxr-xr-x 1 1001 1001 308 Aug 1 15:17 99-uboot -rwxr-xr-x 1 1001 1001 1022 Aug 1 15:17 initramfs-cleanup -rw-r--r-- 1 1001 1001 525 Aug 1 15:17 interfaces.bonding -rw-r--r-- 1 1001 1001 1028 Sep 10 12:16 interfaces.default -rw-r--r-- 1 1001 1001 280 Aug 1 15:17 interfaces.espressobin -rw-r--r-- 1 1001 1001 197 Aug 1 15:17 interfaces.hostapd -rw-r--r-- 1 1001 1001 218 Aug 1 15:17 interfaces.network-manager -rw-r--r-- 1 1001 1001 495 Aug 1 15:17 interfaces.r1 -rw-r--r-- 1 1001 1001 610 Aug 1 15:17 interfaces.r1router -rw-r--r-- 1 1001 1001 359 Aug 1 15:17 interfaces.r1switch -rw-r--r-- 1 1001 1001 212 Aug 1 15:17 check_first_login_reboot.sh -rw-r--r-- 1 1001 1001 174 Aug 1 15:17 ssh-title.sh -rw-r--r-- 1 1001 1001 217 Aug 1 15:17 01-armbian-defaults.conf -rw-r--r-- 1 1001 1001 384 Aug 1 15:17 firstrun.service drwxr-xr-x 2 1001 1001 4096 Sep 11 12:49 getty@tty1.service.d -rw-r--r-- 1 1001 1001 448 Aug 1 15:17 log2ram.service -rw-r--r-- 1 1001 1001 426 Aug 1 15:17 resize2fs.service drwxr-xr-x 2 1001 1001 4096 Sep 11 12:49 serial-getty@.service.d drwxr-xr-x 2 1001 1001 4096 Sep 11 12:49 systemd-modules-load.service.d -rw-r--r-- 1 1001 1001 30 Aug 1 15:17 10-noclear.conf -rw-r--r-- 1 1001 1001 33 Aug 1 15:17 10-term.conf -rw-r--r-- 1 1001 1001 28 Aug 1 15:17 10-timeout.conf -rw-r--r-- 1 1001 1001 287 Aug 1 15:17 71-axp-power-button.rules -rwxr-xr-x 1 1001 1001 3783 Aug 1 15:17 apt-updates -rw-r--r-- 1 1001 1001 60 Aug 1 15:17 exclude.txt -rw-r--r-- 1 1001 1001 84132 Aug 1 15:17 boot.axf -rw-r--r-- 1 1001 1001 126 Aug 1 15:17 boot.ini -rw-r--r-- 1 1001 1001 321016 Aug 1 15:17 u-boot.bin -rw-r--r-- 1 1001 1001 146 Aug 1 15:17 linux.ini -rw-r--r-- 1 1001 1001 118912 Aug 1 15:17 boot.axf -rw-r--r-- 1 1001 1001 91 Aug 1 15:17 boot.ini -rw-r--r-- 1 1001 1001 152 Aug 1 15:17 linux.ini -rw-r--r-- 1 1001 1001 309228 Aug 1 15:17 u-boot.bin -rwxr-xr-x 1 1001 1001 1458 Aug 1 15:17 log2ram -rw-r--r-- 1 1001 1001 1067 Aug 1 15:17 LICENSE
  13. \var\log & \var\log.hdd

    I'm not too familiar with deb packaging, but maybe just using the same condition as the line above it would be enough: [ remove = "$1" ] || [ abort-install = "$1" ] &&
  14. \var\log & \var\log.hdd

    There's this line in the postrm of linux-xenial-root-orangepipc systemctl disable log2ram.service armhwinfo.service >/dev/null 2>&1 but I don't think the postrm is called on upgrade, is it? Edit: yes it does