SomeArmbianForumUser

  • Posts

    26
  • Joined

  • Last visited

Recent Profile Visitors

947 profile views

SomeArmbianForumUser's Achievements

  1. MPD as installed by Armbian needs this audio_output configuration in /etc/mpd.conf in order to use the volume control of the on-board sound with Armbian mainline kernel 5.x on the BananaPi M1 (and maybe other A20 boards): audio_output { type "alsa" name "BananaPi BuiltIn" device "hw:0,0" mixer_type "hardware" mixer_device "default" mixer_control "Power Amplifier" }
  2. BananaPi M1 with Armbian 21.02: How to Enable TV Output through the Composite Connector A Banana Pi M1 set up as in the previous post, when connected to a display via the composite connector, will display only early boot messages. When the linux kernel is started, the display at the composite connector will go dark, and video will only be output through HDMI. To prevent this, blacklist the HDMI output module: echo blacklist sun4i_drm_hdmi | sudo tee /etc/modprobe.d/composite.conf However, in the current kernel, the HDMI output not compiled as a module, and therefore cannot be effectively blocked in this way. But it was compiled as a module in Armbian kernel version 5.8.6. Use sudo armbian-config to install this kernel version (under System -> Other) and reboot. The screen (console) will now show on the screen attached to the composite output. Security-wise, changing to an older kernel is probably a bad move. For devices that need to access the internet, it may be better to recompile the current kernel instead after configuring that the above driver is compiled as a module. As this is not a concern for me, I have not tried this.
  3. BananaPi M1 with Armbian 21.02: How to Enable Dallas One-Wire Temperature Sensor The following step-by-step guide may be too detailed: 1) Write the Armbian image for Banana Pi to SD card. xzcat <~/Downloads/Armbian_21.02.3_Bananapi_buster_current_5.10.21.img.xz | sudo dd of=/dev/mmcblk0 bs=1M 2) Set host name of the Banana Pi Pop out SD card out of the laptop / PC and push back in. # Replace occurrences of bananapi with desired hostname. sudo sed -i s/bananapi/test-w1/ /media/*/*f*/etc/host{s,name} # umount sdcard, put in banana pi, Connect banana pi to network, power on 3) SSH to Banana Pi and Configure 1Wire ssh root@test-w1 # Follow instructions to change password and create user. Reconnect as user. sudo armbian-config # Navigate: System -> Hardware. Select w1-gpio. Save. Back. Reboot. # Reconnect after reboot as user. dmesg | grep wire [ 8.560693] Driver for 1-wire Dallas network protocol. [ 8.581436] gpio-271 (onewire@0): enforced open drain please flag it properly in DT/ACPI DSDT/board file [ 60.628063] w1_master_driver w1_bus_master1: Attaching one wire slave 00.800000000000 crc 8c cat /sys/kernel/debug/pinctrl/*/pinmux-pins Pinmux settings per pin Format: pin (name): ... ... pin 259 (PI3): (MUX UNCLAIMED) (GPIO UNCLAIMED) ... pin 271 (PI15): onewire@0 1c20800.pinctrl:271 function gpio_in group PI15 ... GPIO 271 does not seem to be available on the GPIO header of the BananaPi. For Linux, GPIO seem to either have a (high) number, or a name like PH8 or PI15. I have only found one source that shows the location of these type of pin names on the Banana Pi's GPIO Header: The table at the bottom of this page: http://www.elektronik-kompendium.de/sites/raspberry-pi/1907101.htm If gives this mapping for the Banana Pi M1 GPIO Header to these names: 3V3 1 2 5V PB21 3 4 5V PB20 5 6 GND PI03 7 8 PH00 GND 9 10 PH01 PI19 11 12 PH02 PI18 13 14 GND PI17 15 16 PH20 3V3 17 18 PH21 PI12 19 20 GND PI13 21 22 PI16 PI11 23 24 PI10 GND 25 26 PI14 This shows that PI3 (which is the same as PI03) is available at pin 7. In order to use this pin for one-wire, edit file /boot/armbianEnv.txt on the banana pi. Add a line: param_w1_pin=PI3 Save and reboot. Connect a temperature sensor to 3V3, GND, pin 7, and a suitable resistor. Then the temperature can be read by cat /sys/bus/w1/devices/w1_bus_master*/28-*/temperature
  4. I found that it is not easy to use the Dallas one-wire temperature sensors and the composite TV-Out on the Banana Pi with the current Armbian version. I have searched for posts on these topics in the forum. The posts that I have found in this forum describe solutions for outdated Armbian versions or do not give enough detail. The following posts in this thread will describe how to solve these problems for the current Armbian version for the Banana Pi M1.
  5. For more aggressive log rotation, I have now changed /etc/logrotate.d/rsyslog like this: root@micro:~# diff /etc/logrotate.d/rsyslog{~,} -u --- /etc/logrotate.d/rsyslog~ 2017-01-18 23:14:38.000000000 +0100 +++ /etc/logrotate.d/rsyslog 2018-01-23 13:25:45.141409984 +0100 @@ -1,10 +1,9 @@ /var/log/syslog { - rotate 7 + rotate 4 daily missingok - notifempty - delaycompress + ifempty compress postrotate invoke-rc.d rsyslog rotate > /dev/null @@ -25,11 +24,10 @@ /var/log/messages { rotate 4 - weekly + daily missingok - notifempty + ifempty compress - delaycompress sharedscripts postrotate invoke-rc.d rsyslog rotate > /dev/null And created a new logrotate file for openhab2: root@micro:~# cat /etc/logrotate.d/openhab2 /var/log/openhab2/*.log { rotate 4 daily missingok ifempty compress postrotate service openhab2 restart endscript } Invoking these files with logrotate --force --verbose <filename> produces no error, and performs the expected operations. If this works out in the long run, I can probably reduce the ramlog size back to 50MB.
  6. I have now found root@micro:~# find / -name log2ram* /etc/default/log2ram Where I can increase the size of that file system. I can still not upload armbianmonitor - seems like the armbian server has trouble: root@micro:~# armbianmonitor -u System diagnosis information will now be uploaded to curl: (56) Recv failure: Connection reset by peer Please post the URL in the forum where you've been asked for. root@micro:~# armbianmonitor -u System diagnosis information will now be uploaded to <html> <head> <title>500 Internal Server Error</title> </head> <body> <h1>500 Internal Server Error</h1> The server has either erred or is incapable of performing the requested operation.<br /><br /> </body> </html>Please post the URL in the forum where you've been asked for. root@micro:~# armbianmonitor -u System diagnosis information will now be uploaded to <html> <head> <title>500 Internal Server Error</title> </head> <body> <h1>500 Internal Server Error</h1> The server has either erred or is incapable of performing the requested operation.<br /><br /> </body> </html>Please post the URL in the forum where you've been asked for. I would still like advice how to increase the logrotate aggressiveness - delete old logs earlier, so they do not take as much space in ramlog.
  7. Apparently, I can't: root@micro:~# armbianmonitor -u System diagnosis information will now be uploaded to /usr/bin/armbianmonitor: line 374: [: -gt: unary operator expected /usr/bin/armbianmonitor: line 374: [: -gt: unary operator expected /usr/bin/armbianmonitor: line 374: [: -gt: unary operator expected /usr/bin/armbianmonitor: line 374: [: -gt: unary operator expected <html> <head> <title>500 Internal Server Error</title> </head> <body> <h1>500 Internal Server Error</h1> The server has either erred or is incapable of performing the requested operation.<br /><br /> </body> </html>Please post the URL in the forum where you've been asked for. Interesting. In the meantime I had deleted the largest file in /var/log, but this is not reflected in the output of df for the log2ram filesystem. After the armbianmonitor error, I tried rebooting and manually unmounting /var/log in an attempt to maybe get armbianmonitor -u to work, but no success. My openhab2 continues to run just fine on that device.
  8. Thanks for Ramlog. I have installed Armbian_5.35_Micro_Debian_stretch_next_4.13.16 and not done anything in terms of Ramlog setup. What should I do when it is full? Or to avoid that it gets full? Symptoms: * Aptitude complained about "no space left on device" on exit. * df: root@micro:~# df -h Filesystem Size Used Avail Use% Mounted on udev 432M 0 432M 0% /dev tmpfs 100M 12M 89M 12% /run /dev/mmcblk0p1 29G 3.0G 26G 11% / tmpfs 499M 0 499M 0% /dev/shm tmpfs 5.0M 4.0K 5.0M 1% /run/lock tmpfs 499M 0 499M 0% /sys/fs/cgroup tmpfs 499M 36K 499M 1% /tmp log2ram 50M 50M 0 100% /var/log tmpfs 100M 0 100M 0% /run/user/0 * usage: root@micro:~# du /var/log/* | sort -n 0 /var/log/armhwinfo.log 0 /var/log/debug 0 /var/log/influxdb 0 /var/log/ntpstats 0 /var/log/sysstat 0 /var/log/user.log 4 /var/log/btmp 4 /var/log/debug.1 4 /var/log/kern.log 4 /var/log/messages 8 /var/log/aptitude 8 /var/log/auth.log 8 /var/log/unattended-upgrades 24 /var/log/faillog 28 /var/log/wtmp 36 /var/log/user.log.1 44 /var/log/alternatives.log 48 /var/log/armhwinfo.log.1.gz 52 /var/log/syslog.3.gz 60 /var/log/bootstrap.log 136 /var/log/auth.log.1 140 /var/log/apt 160 /var/log/kern.log.1 192 /var/log/messages.1 248 /var/log/syslog.2.gz 288 /var/log/lastlog 348 /var/log/dpkg.log 3060 /var/log/daemon.log 3092 /var/log/syslog 10208 /var/log/openhab2 14912 /var/log/syslog.1 18084 /var/log/daemon.log.1 I know that openHAB2 is causing the majority of the log messages. That's the purpose of that computer. How can I increase the amount of RAM used for Ramlog, or make the log rotation more aggressive?
  9. Why are you messing with wpa_supplicant when you were already "able to connect to [your] wifi AP using nmtui, and now [you're] trying to share the internet with any device that is connected in eth0 ...". In the simplest realization this would just need a static private IP address for eth0, ip forwarding, a NAT iptables rule, static addresses, routes, and dns settings on the connected devices. You say you are tired from trying out so many things but you do not describe what went wrong in even a single try.
  10. Why choose the orange pi zero for this? It does not have bluetooth on board.
  11. That link says "an encrypted wireless network requires entropy". That's understood. No questions about that. You have suggested that also my unencrypted example network from post 13 requires entropy. Could you please explain why? Actually I see a rise in available entropy from the start of hostapd. That alone does not contradict your suggestion, as there might be an entropy valley during the start that I do not detect with my before and after measurements.
  12. I am surprised that an unencrypted, open wireless network (cf post #13) needs entropy. Why is that?
  13. You have made the same mistake graphically that I made physically at first. Sorry for not being clear enough. In that picture, you have actually encircled R353/R352. These are _not_ identical to R135/R136. R135/R136 sit directly below the encircled resistors in that picture. R353/R352 can stay, R135/R136 have to go. A correctly modified board looks like this (test if I can include images from the sunxi wiki): I have now corrected the wiki page. I could not replace the image with the wrong resistors highlighted, so I uploaded a new one with a different name and used this in the article to highlight the R135/R136 resistor positions:
  14. Success: My First OPZ runs on PoE. I have used this PoE Injector, extended it with this fuse holder, currently it contains a 200mA slow acting fuse. I'm using this 24V 0.5A power supply and these buck converters. I would not recommend the buck converters, because they are very tricky to adjust.