SYSFS GPIO Firmware Problem Prevents Export to Linux


Heads up folks the same problem as with ADC affects the export of the external GPIO 36/… if you have a I2C MUX you need to set the MUX to 0 before exporting the GPIO …

Errors as per dmesg

[  408.717839] qup_i2c qup_i2c.0: QUP: I2C status flags :0x1300c8, irq:187
[  408.725163] qup_i2c qup_i2c.0: I2C slave addr:0x3a not connected
[  408.800335] swimcu_set_fault_mask: 0x4, cnt 6
[  408.804028] Failed to receive frame from MCU -106
[  408.808454] Failed to receive a frame -106
[  408.812849] swimcu_gpio_request: gpio4 error ret=-5
[  408.817305] gpio-104 (?): gpiod_request: status -5
[  408.817335] export_store: status -5


Error Status 5 is with respect to I/O error. I think gpio 104 pin is not there or it is not configured.
status of the pin configured can be seen using as below:
root@swi-mdm9x28:~# microcom -E /dev/ttyAT
+WIOCFG: 2,0,0,0,1,0,0
+WIOCFG: 7,0,0,0,1,0,0
+WIOCFG: 8,0,0,0,1,0,0
+WIOCFG: 13,0,0,0,1,0,0
+WIOCFG: 21,0,0,0,1,0,0
+WIOCFG: 22,0,0,0,1,0,0
+WIOCFG: 23,0,0,0,1,0,0
+WIOCFG: 24,0,0,0,1,0,0
+WIOCFG: 25,0,0,0,1,0,0
+WIOCFG: 32,0,0,0,1,0,0
+WIOCFG: 33,0,0,0,1,0,0
+WIOCFG: 35,0,0,0,1,0,0
+WIOCFG: 42,0,0,0,1,0,0

where 1st element refers to GPIO pin number.where as if 2nd element is 16 mean it is configured and can be used.if 2nd element is 0 mean it is not can configure it via the command,
which mean you are configuring GPIO 36 and you can use.