Have written a working i2c input driver that monitors the MMA8452q chip via i2c-gpio in linux kernel 2.6.39-rc1. I can read the events generated by the accelerometer via evdev, /dev/input/event0. The accelerometer interrupt is based on GPIO 30 in the AT91SAM9G20.
Have had to move to kernel 3.7-rc1 due to other issues. In porting the accelerometer driver to 3.7-rc1, some board init changes were required. One, gpio_to_irq(), has changed from a #define to a function call, and thus i2c_board_info does not allow assigning the GPIO to irq in the definition.
GPIO definitions have changed between the kernel versions so what was 62 (GPIO PA30) in kernel 2.6.39-rc1 is now 30 in kernel 3.7-rc1.
Does anyone know of an issue with any of the following:
a. incorrect gpio_to_irq selection in the code?
b. i2c devices not registering interrupts with evdev?
In checking the initialization of the driver, the i2c framework is NOT retrieving the irq in the i2c_boardinfo.
Discussion around AT91RM9200 and SAM9 Series Products.
1 post • Page 1 of 1
Who is online
Users browsing this forum: No registered users and 8 guests