Closed ih8ms closed 1 year ago
I have a keyboard connected to I2C bus 3 (on Radxa Zero physical GPIO pins 3 and 5, I2C_EE_M3_SDA and I2C_EE_M3_SCL).
The keyboard isn't working. It looks like the driver was loaded OK, but I don't get any (input) events from the keyboard.
uname -a Linux beepberry 5.10.69-13-amlogic-g104342c59952 #amlogic SMP PREEMPT Thu Sep 15 13:06:12 UTC 2022 aarch64 aarch64 aarch64 GNU/Linux
lsmod | grep bbq bbq10kbd 20480 0
modinfo bbq10kbd filename: /lib/modules/5.10.69-13-amlogic-g104342c59952/extra/bbq10kbd.ko version: 0.1 description: bbq10kbd i2c keyboard driver author: Billy Lindeman <billylindeman@gmail.com> license: GPL srcversion: 7FFB438E1A711E042ECA860 alias: i2c:bbq10kbd depends: name: bbq10kbd vermagic: 5.10.69-13-amlogic-g104342c59952 SMP preempt mod_unload aarch64
dmesg | egrep -i 'i2c|kbd|input|keyboard'[ 2.900607] i2c /dev entries driver [ 5.115499] systemd[1]: Starting Set the console keyboard layout... [ 5.402078] bbq10kbd: initialising i2c... [ 5.402172] bbq10kbd 3-001f: there is not valid maps for state 0 [ 5.405805] bbq10kbd: probing [ 5.405810] bbq10kbd: configuring i2c device [ 5.919171] bb10kbd: firmware version = -110 [ 6.435234] bbq10kbd: requesting irq handler 38 [ 6.439438] bbq10kbd: initialising internal input... [ 6.439619] input: bbq10kbd-i2c-keyboard as /devices/virtual/input/input0 [ 6.442804] bbq10kbd: initialised input device with 255 keycodes [ 6.442812] bbq10kbd: initialising internal input... [ 6.442907] input: bbq10kbd-i2c-mouse as /devices/virtual/input/input1 [ 6.451864] bbq10kbd: initialised input pointer [ 6.459402] bbq10kbd: probed. [ 6.459773] bbq10kbd: inited [ 6.677168] OF: graph: no port node found in /soc/bus@ffd00000/i2c@1c000/fusb302@22
sudo libinput list-devices Device: bbq10kbd-i2c-keyboard Kernel: /dev/input/event0 Group: 1 Seat: seat0, default Capabilities: keyboard Tap-to-click: n/a Tap-and-drag: n/a Tap drag lock: n/a Left-handed: n/a Nat.scrolling: n/a Middle emulation: n/a Calibration: n/a Scroll methods: none Click methods: none Disable-w-typing: n/a Accel profiles: n/a Rotation: n/a Device: bbq10kbd-i2c-mouse Kernel: /dev/input/event1 Group: 2 Seat: seat0, default Capabilities: pointer Tap-to-click: n/a Tap-and-drag: n/a Tap drag lock: n/a Left-handed: disabled Nat.scrolling: disabled Middle emulation: n/a Calibration: n/a Scroll methods: button Click methods: none Disable-w-typing: n/a Accel profiles: flat *adaptive Rotation: n/a
sudo i2cdetect -y 3 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- -- -- -- -- -- 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- UU 20: -- -- UU -- -- -- -- -- -- -- -- -- -- -- -- -- 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 70: -- -- -- -- -- -- -- --
sudo libinput debug-events -event0 DEVICE_ADDED bbq10kbd-i2c-keyboard seat0 default group1 cap:k -event1 DEVICE_ADDED bbq10kbd-i2c-mouse seat0 default group2 cap:p left scroll-nat scroll-button
cat /boot/uEnv.txt verbosity=7 console=ttyAML0,115200 overlay_prefix=meson rootfstype=ext4 fdtfile=amlogic/meson-g12a-radxa-zero.dtb overlays=meson-g12a-uart-ao-a-on-gpioao-0-gpioao-1 meson-g12a-spi-spidev sharp meson-g12a-i2c-ee-m3-gpioa-14-gpioa-15 bbq10kbd-radxa-zero rootuuid=a1d6d1b5-7219-4126-8ecd-e5cf6265cfc6 initrdsize=0x101b1d3 kernelversion=5.10.69-13-amlogic-g104342c59952 initrdimg=initrd.img-5.10.69-13-amlogic-g104342c59952 kernelimg=vmlinuz-5.10.69-13-amlogic-g104342c59952 param_spidev_spi_bus=1 param_spidev_max_freq=10000000 extraargs=fbcon=map:0 fbcon=font:VGA8x8 framebuffer_width=400 framebuffer_height=240 framebuffer_depth=1
Got it, it works wit the following settings:
irq-gpio = <&gpio 451 2>; interrupts = <3 2>;
I have a keyboard connected to I2C bus 3 (on Radxa Zero physical GPIO pins 3 and 5, I2C_EE_M3_SDA and I2C_EE_M3_SCL).
The keyboard isn't working. It looks like the driver was loaded OK, but I don't get any (input) events from the keyboard.