All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] Fix OV5645 capture issue with 400kHz i2c bus frequency
@ 2024-02-13 14:02 Biju Das
  2024-02-13 14:02 ` [PATCH 1/2] media: i2c: ov5645: Move the register 0x3008 from ov5645_global_init_setting Biju Das
  2024-02-13 14:02 ` [PATCH 2/2] media: i2c: ov5645: Add a small delay after writes in ov5645_set_register_array() Biju Das
  0 siblings, 2 replies; 13+ messages in thread
From: Biju Das @ 2024-02-13 14:02 UTC (permalink / raw)
  To: Sakari Ailus, Mauro Carvalho Chehab
  Cc: Biju Das, linux-media, Geert Uytterhoeven, Prabhakar Mahadev Lad,
	Biju Das, linux-renesas-soc

This patch series aims to fix OV5645 capture issue with 400kHz i2c bus
frequency observed on RZ/G2L SMARC EVK platform.

Testing OV5645 with i2c bus frequency @400kHz on RZ/G2L SMARC EVL platform
shows issues like the captured image is either greenish or it is not
capturing the image at all. However, It is working ok when the i2c
frequency is 100kHz. From this, it is clear that we have a timing issue
at high speed. The testing also shows that if we add a delay >= 1 msec
after register write {0x3008, 0x82}, then the captured image is always
good.

Since OV5645 is showing issues @400kHz, it makes sense to add a small
delay after register writes for settling the register values. So introduce
a small delay by adding a read() after write() and also add a debug code
for data mismatch.

Biju Das (2):
  media: i2c: ov5645: Move the register 0x3008 from
    ov5645_global_init_setting
  media: i2c: ov5645: Add a small delay after writes in
    ov5645_set_register_array()

 drivers/media/i2c/ov5645.c | 26 +++++++++++++++++++++++---
 1 file changed, 23 insertions(+), 3 deletions(-)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2024-02-14 23:34 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-13 14:02 [PATCH 0/2] Fix OV5645 capture issue with 400kHz i2c bus frequency Biju Das
2024-02-13 14:02 ` [PATCH 1/2] media: i2c: ov5645: Move the register 0x3008 from ov5645_global_init_setting Biju Das
2024-02-13 22:27   ` Wolfram Sang
2024-02-14  7:44     ` Biju Das
2024-02-14  8:31       ` Wolfram Sang
2024-02-14 20:25         ` Biju Das
2024-02-14 20:49           ` Sakari Ailus
2024-02-14 20:54             ` Biju Das
2024-02-14 20:57               ` Biju Das
2024-02-14 23:34                 ` Kieran Bingham
2024-02-13 14:02 ` [PATCH 2/2] media: i2c: ov5645: Add a small delay after writes in ov5645_set_register_array() Biju Das
2024-02-13 22:32   ` Wolfram Sang
2024-02-14 20:30     ` Biju Das

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.