0

I'm studying and developing a module to stream and control a CSI-2 camera, but I don't have device(It's being shipped). I added device tree, code for config, read/write on I2C bus, defined some v4l2 operator functions,..

Could you tell me how to to test a module without device? Thanks in advance!

Thtam
  • 21
  • 1
  • 5
  • 1
    You need to replace all communication with hardware by fake hardcoded data. If it uses DMA and on your platform is no DMA engine that supports memory-to-memory transfers, you will need to write a fake driver of DMA engine. – 0andriy Mar 14 '20 at 16:20
  • 1
    Basically, if you want to do it correctly, it is 10x times more complicated work, then the original driver. – 0andriy Mar 14 '20 at 16:23
  • Thank @0andriy, as i understand, testing code is always more complex than real code. In my case, I will wait for device is better. But I want to learn how to do this. You could recommend some methods to test or any examples ? – Thtam Mar 15 '20 at 07:15

0 Answers0