(Please visit the site to view this file) the ads7846 .c comes from linux-3.14 branch, and I compare the latest version in linux-4.0, seems no obvious change. and according to my recent debug, I find maybe our SPI operation cause this. I use the oscillosope, and get the SPI clock, mosi, miso sigal. firstly, our spi work in DMA mode, and in linux driver, every time we sent a spi cmd, we will then recevie the date through miso, during the miso have valid data, the mosi also contain some cmd. we find that the cmd on mosi looks strange, every time spi send a cmd, for example, when we send the last cmd 0x90, actually, we can see three cmd were sent, they are 0x90, 0xc0, 0x92. so the last cmd seems is 0x92, and this is not powerdown cmd, then we disable the dma mode in spi, and did the same test, when we send cmd 0x90, also three cmd sent out , they are 0x90, 0x00, 0x00. To tsc2046 , all control cmd need to start with 1, so the real last cmd for tsc2046 is 0x90, then we find the status of X+ and PENIRQ return to normal. So currently, the X+ and PENIRQ return to normal if we set SPI work in cpu mode (disable DMA mode). But we find another issue, we find the coordinate value we get is not correct. Do you have any suggestion?
↧