vianpl wrote: ↑
Thu Nov 29, 2018 9:39 am
I've been working on getting the touchscreen to work with mainline Linux. I used "disable_touchscreen=1" and modified the relevant upstream driver poll the touchscreen directly trough I2C. Seems to work fine
One thing I can't seem to achieve is to get interrupts from the int pin on the display's board. Am I missing something? Should I enable them somehow?
Interrupts aren't used. Leave it disconnected.
vianpl wrote:I also realized that disabling the firmware touchscreen polling also disabled the back-light functionality. Is there any way to bypass that restriction? or even access the registers directly?
The backlight is controlled through a small Atmel processor on the I2C bus. I2C address 0x45.
No guarantees on this, but it appears to be a 2 byte write of 0x86 <pwm value>. Values below 128 appear to be mapped to 0 in the firmware for some reason (probably it's not bright enough to see anything).
Please note that that Atmel is also responsible for configuring the TC358762 bridge chip, therefore the firmware WILL be talking to it during the early stages of boot via i2c0.
And based on your rpi-linux post, please be very aware that connecting i2c1 onto the header of the display board has just bridged i2c0 and i2c1 on most boards. The I2C controller does not support multiple masters, therefore i2c0 is then effectively dead, the camera won't work (it shares the pins with the display), and generally you've introduced the potential for odd I2C issues.
You'd be better off sorting the pinmuxing correctly for using i2c0 via the relevant GPIOs. I had started using i2c-mux-pinctrl to allow Linux to address the buses correctly, but got bogged down in other things.
https://lists.infradead.org/pipermail/l ... 07210.html
https://lists.infradead.org/pipermail/l ... 07214.html
It still doesn't get over the issue of the firmware / ARM arbitration over the i2c0, but at least means that you aren't causing further grief by bridging the two buses.
Software Engineer at Raspberry Pi Trading. Views expressed are still personal views.
I'm not interested in doing contracts for bespoke functionality - please don't ask.