Jump to content

TRay

Members
  • Posts

    39
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Hi How to disable HDMI audio and audiocodec 0 [audiocodec ]: audiocodec - audiocodec audiocodec 1 [SoundCard ]: USB-Audio - USB PnP Sound Device C-Media Electronics Inc. USB PnP Sound Device at usb-5200400.usb-1, full speed 2 [HDMI ]: HDMI - HDMI HDMI I don't need this because I use external sound card on USB and I would like prefer USB Sound card on index number 0 I try use /etc/modprobe.d/alsa.conf with options snd_usb_audio index=0 but don't work
  2. I can add that Orange Pi Zero 3 users have similar problems, i.e. after turning on the power or, for example, after reboot. This is not a cyclical phenomenon. So when it happens that you need to reboot remotely, it may turn out that Orange Pi Zero 3 requires physical intervention by turning the power on and off.
  3. The only thing I haven't been able to eliminate is this message [ 5.019754] gpio-74 (onewire@0): enforced open drain please flag it properly in DT/ACPI DSDT/board file I tried setting the GPIO flag for GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN but unfortunately, it doesn't work but it doesn't affect the operation of w1-gpio It seems that the GPIO pins do not have an "open drain" mode, they do outputs and inputs. It is a warning about what something sees as an invalid or incomplete configuration in Device Tree, rather than a real problem with the hardware.
  4. Hi, for me w1-gpio on OZPI v3 working now very well via overlay dts file please read my last post in:
  5. Reading many others documents about OPEN DRAIN flag , OZPI v3 and others like Raspberry Pi don't support Open DRAIN, but they should work in emulated mode, switching between input and output-driving-low. So for this reason if we set flag for GPIO with OPEN DARIN it looks not influence and not need setting this flag for w1-gpio for this SBC
  6. Hi, I managed to make w1-GPIO work in Orange Pi Zero v3 for, for example, the DS18B20 sensor. However, I have some doubts about setting the GPIO flags for w1-gpio. Many examples provide flags in the form gpios = <&pio 0 7 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>; but in the dts file when I use this form it does not work (syntax error) so I have to provide the flags in digital form. A description of flags and bits is here https://elixir.bootlin.com/linux/v6.6.30/source/include/dt-bindings/gpio/gpio.h If I would like to set GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN then the digital value for these bits will be for set bits: 0110000 = 48 because GPIO_OPEN_DRAIN it is (GPIO_SINGLE_ENDED | GPIO_LINE_OPEN_DRAIN) Please help me and confirm whether I understood it correctly I wanted to get rid of the message in the logs for w1-gpio [ 4.994183] gpio-74 (onewire@0): enforced open drain please flag it properly in DT/ACPI DSDT/board file which understands that I need to set the GPIO flag GPIO_OPEN_DRAIN in the dts file I see one problem with this source https://www.kernel.org/doc/Documentation/devicetree/bindings/gpio/gpio.txt where a number of bits to set is 6 in source https://elixir.bootlin.com/linux/v6.6.30/source/include/dt-bindings/gpio/gpio.h number of bits to set is 7 I hope I posted this question in the right section, if not please move it
  7. I used simple dts file as possible : /dts-v1/; /plugin/; / { model = "OrangePi Zero3"; compatible = "xunlong,orangepi-zero3", "allwinner,sun50i-h618"; fragment@0 { target-path = "/"; __overlay__ { w1: onewire@0 { compatible = "w1-gpio"; pinctrl-names = "default"; gpios = <&pio 2 7 0>; status = "okay"; }; }; }; }; compiled: armbian-add-overlay w1-gpio.dts and works 🙂 with armbianEnv.txt user_overlays=w1-gpio param_w1_pin=PC10 param_w1_pin_int_pullup=0 demsg show [ 5.015541] Driver for 1-wire Dallas network protocol. [ 5.019754] gpio-74 (onewire@0): enforced open drain please flag it properly in DT/ACPI DSDT/board file [ 5.046831] w1_master_driver w1_bus_master1: Attaching one wire slave 28.03165129ecff crc 24 and cat /sys//bus/w1/devices/28-03165129ecff/w1_slave 76 01 4b 46 7f ff 0c 10 d3 : crc=d3 YES 76 01 4b 46 7f ff 0c 10 d3 t=23375 SBC DS18B20 VCC (3V3) Pin 1 ---------- VCC DS18B20 | R1 = 4k7 | GPIO74 Pin 26 --------- Data DS18B20 GND Pin 6 ---------- GND DS18B20
  8. I would like to ask about the entry in armbiaEnv.txt in the ArmBian distribution for Orange Pi Zero 3 overlay_prefix=sun50i-h616 does it have anything to do with the file in the directory? /boot/dtb-6.6.30-current-sunxi64/allwinner/sun50i-h618-orangepi-zero3.dtb For OZPI version 3 there is a prefix sun50i-h618 and in armbianEnv.txt there is overlay_prefix=sun50i-h616 shouldn't it be sun50i-h618 ?? I'm asking about this because I have a problem with using overlay for w1-gpio for OZPI v3, so I am looking for the source of the problem in various places
  9. I try to understand problem [ 4.997793] sun50i-h616-pinctrl 300b000.pinctrl: pin PC10 already requested by onewire@0; cannot claim for 300b000.pinctrl:74 and I see this message is generate by: https://github.com/torvalds/linux/blob/master/drivers/pinctrl/pinmux.c#L102 /** * pin_request() - request a single pin to be muxed in, typically for GPIO * @pctldev: the associated pin controller device * @pin: the pin number in the global pin space * @owner: a representation of the owner of this pin; typically the device * name that controls its mux function, or the requested GPIO name * @gpio_range: the range matching the GPIO pin if this is a request for a * single GPIO pin */ ...... if ((!gpio_range || ops->strict) && desc->mux_usecount && strcmp(desc->mux_owner, owner)) { dev_err(pctldev->dev, "pin %s already requested by %s; cannot claim for %s\n", desc->name, desc->mux_owner, owner); goto out; } if ((gpio_range || ops->strict) && desc->gpio_owner) { dev_err(pctldev->dev, "pin %s already requested by %s; cannot claim for %s\n", desc->name, desc->gpio_owner, owner); goto out; } .....
  10. Maybe I need a change in my w1-gpio.dts looking to https://elixir.bootlin.com/linux/v6.6.30/source/arch/arm64/boot/dts/allwinner compatible = "allwinner,sun50i-h616"; to model = "OrangePi Zero3"; compatible = "xunlong,orangepi-zero3", "allwinner,sun50i-h618"; and add #include "sun50i-h616-orangepi-zero.dtsi" like in https://elixir.bootlin.com/linux/v6.6.30/source/arch/arm64/boot/dts/allwinner/sun50i-h618-orangepi-zero3.dts
  11. Unfortunately, my programming knowledge is low and knowledge of DTS Overlays + source code of w1-gpio linux kernel does not allow me to find the source of the problem [ 4.997793] sun50i-h616-pinctrl 300b000.pinctrl: pin PC10 already requested by onewire@0; cannot claim for 300b000.pinctrl:74
  12. Ha, interesting ... I have put in armbianEnv.txt instead pc10 now param_w1_pin=gpio71 where gpio71 is number line for PC7 which is not connected DS18B20 🙂 at current is nothing connected and working w1-gpio with info log where is show PC10/gpio-74 [ 4.957396] Driver for 1-wire Dallas network protocol. [ 4.960325] w1-gpio onewire@0: there is not valid maps for state default [ 4.960433] gpio-74 (onewire@0): enforced open drain please flag it properly in DT/ACPI DSDT/board file [ 4.986579] w1_master_driver w1_bus_master1: Attaching one wire slave 28.03165129ecff crc 24 cat /sys/bus/w1/devices/28-03165129ecff/w1_slave 5f 01 4b 46 7f ff 0c 10 12 : crc=12 YES 5f 01 4b 46 7f ff 0c 10 12 t=21937 I can not understand this
  13. Summary, In all examples to use w1-gpio in Armbian in armbinaEnv.txt always is name of gpio is write in capital letters for example PC10 param_w1_pin=PC10 but when we use PC10 w1-gpio not works and in log is message: [ 4.997793] sun50i-h616-pinctrl 300b000.pinctrl: pin PC10 already requested by onewire@0; cannot claim for 300b000.pinctrl:74 command cat /sys/kernel/debug/gpio did not show that gpio 74 / PC10 is used command but when we use name gpio in lowercase letters pc10 w1-gpio works and show data from DS18B20 but show message in log [ 9.366246] w1-gpio onewire@0: there is not valid maps for state default command cat /sys/kernel/debug/gpio show gpiochip0: GPIOs 0-287, parent: platform/300b000.pinctrl, 300b000.pinctrl: gpio-74 ( |onewire@0 ) out hi and we can see data from DS18B20 cat /sys/bus/w1/devices/28-03165129ecff/w1_slave 53 01 4b 46 7f ff 0c 10 2d : crc=2d YES 53 01 4b 46 7f ff 0c 10 2d t=21187 for me, it is bug or in kernel 6.6.30 or overlay for Ornage Pi Zreo v3
  14. I have checked what hapen when on Ornage Pi Zero v1 with kernel 6.1.63 in armbianEnv.txt use pa14 instead PA14 in log I see [ 9.358693] Driver for 1-wire Dallas network protocol. [ 9.366246] w1-gpio onewire@0: there is not valid maps for state default [ 9.368019] gpio-110 (onewire@0): enforced open drain please flag it properly in DT/ACPI DSDT/board file and w1-gpio not working and no files in /sys/bus/w1/devices/ but we see marked in red the same information that I have on OZPI v3 when I use pc10 instead of PC10 but on OZPI v3 DS18B20 works and on OZPI v1 it doesn't work when I use the lower case name gpio This looks like some kind of bug in kernel 6.6.30 on OZPI v3
  15. Yes, that's right, I can ignore it when I have a working w1-gpio on OZPI v3, but it would be nice to see how to fix it so that it works correctly. But what's strange to me is that I have to use the gpio name in lower case and not in upper case as it was always described in the w1-gpio examples. I tried to use the name with gpiod, i.e. "gpio74", instead of names like PC10, but it didn't work, so it occurred to me to try writing the name in lower case "pc10" instead of capital letters as usual, and I found that it worked, but I think it's not normal since capital letters have been used so far, I will check on OZP v1 whether it will work if I change to lowercase letters Thank you for exchanging ideas and tips on solving the problem
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines