i am trying to get a new camera running on MX6Solo. I have the CSI running, and able to capture single-shots using a small console capture program (no gui, no preview). I.e. the route from camera to /dev/video0 seem OK.
I have also enabled the CSI test mode to generate a checker-board. I see this too when I capture with my little console program.
However; If I start the camera app on the phone, now involving Android and possibly preview, I get a kernel stop. A stop with no messages, no dump, nothing, it simply hangs!
The lights go out just after I do "ipu_cm_write(ipu, reg | IPU_CONF_CSI0_EN, IPU_CONF);" (ipu_common.c).
The strange thing is that my small capture program works ok. So I *suspect* it may be in regard with the preview or something else caused by Android.
- I have tried to log interrupts, and it does not seem I am getting any interrupts after the 'enable' of CSI0, so I don't think it is an interrupt hanging. Maybe it is a bad DMA setup? (however I need a good idea of how to look into that).
- I have tried hardcoding IPU_CONF to just IPU_CONF_CSI0_EN (to disable as much IPU flow as possible), but it still dies.
- I have tried skipping the "enable"-line of code, and then the code does NOT crash or hang.
So: In short: I enable CSI0, and the platform stops!
Any ideas are appreciated!
I have logged the following registers just prior to enabling CSI0: They look much the same as for my console capture. Only exception is: IPU_INT_CTRL(10) = 0x777F000F.
IPU_CONF = 0x000007A0
IDMAC_CONF = 0x0000002F
IDMAC_CHA_EN1 = 0x00800001
IDMAC_CHA_EN2 = 0x00000000
IDMAC_CHA_PRI1 = 0x18800001
IDMAC_CHA_PRI2 = 0x00000000
IDMAC_BAND_EN1 = 0x00000000
IDMAC_BAND_EN2 = 0x00000000
IPU_CHA_DB_MODE_SEL0 = 0x00000001
IPU_CHA_DB_MODE_SEL1 = 0x00000000
IPU_CHA_TRB_MODE_SEL0 = 0x00800000
IPU_CHA_TRB_MODE_SEL1 = 0x00000000
DMFC_WR_CHAN = 0x00000090
DMFC_WR_CHAN_DEF = 0x202020F6
DMFC_DP_CHAN = 0x00009694
DMFC_DP_CHAN_DEF = 0x2020F6F6
DMFC_IC_CTRL = 0x00000002
IPU_FS_PROC_FLOW1 = 0x00000000
IPU_FS_PROC_FLOW2 = 0x00000000
IPU_FS_PROC_FLOW3 = 0x00000000
IPU_FS_DISP_FLOW1 = 0x00000000
IPU_VDIC_VDI_FSIZE = 0x00000000
IPU_VDIC_VDI_C = 0x00000000
IPU_IC_CONF = 0x00000000
IPU_INT_CTRL(1) = 0x80000001
IPU_INT_CTRL(2) = 0x00080000
IPU_INT_CTRL(3) = 0x00000000
IPU_INT_CTRL(4) = 0x00000000
IPU_INT_CTRL(5) = 0xBFFEFF2F
IPU_INT_CTRL(6) = 0x001FFF02
IPU_INT_CTRL(7) = 0x00000000
IPU_INT_CTRL(8) = 0x00000000
IPU_INT_CTRL(9) = 0xDC000001
IPU_INT_CTRL(10) = 0x777F000E
IPU_INT_CTRL(11) = 0x00000000
IPU_INT_CTRL(12) = 0x00000000
IPU_INT_CTRL(13) = 0x00000000
IPU_INT_CTRL(14) = 0x00000000
IPU_INT_CTRL(15) = 0x00000000
IPU_SDMA(1) = 0x00000000
IPU_SDMA(2) = 0x00000000
IPU_SDMA(3) = 0x00000000
IPU_SDMA(4) = 0x00000000
IPU_SDMA(5) = 0x00000000
IPU_SDMA(6) = 0x00000000
IPU_SDMA(7) = 0x00000000
IPU_SDMA(8) = 0x00000000
IPU_SDMA(9) = 0x00000000
IPU_SDMA(10) = 0x00000000
IPU_SDMA(11) = 0x00000100
IPU_SDMA(12) = 0x06050803
IPU_SDMA(13) = 0x00000000
IPU_SDMA(14) = 0x00000000
IPU_SDMA(15) = 0x00000000
CSI information for csi0
CSI_CONF = 0x040A8818
CSI_SENS_FRM_SIZE = 0x01DF027F
CSI_ACT_FRM_SIZE = 0x01DF027F
CSI_OUT_FRM_CTRL = 0x00000000
CSI_TST_CTRL = 0x017FFF7F