* [PATCH 1/2] ap325 control camera power
@ 2009-01-22 0:33 Kuninori Morimoto
2009-01-27 0:22 ` Paul Mundt
0 siblings, 1 reply; 2+ messages in thread
From: Kuninori Morimoto @ 2009-01-22 0:33 UTC (permalink / raw)
To: linux-sh
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Magnus Damm <damm@igel.co.jp>
---
arch/sh/boards/board-ap325rxa.c | 10 +++++++++-
1 files changed, 9 insertions(+), 1 deletions(-)
diff --git a/arch/sh/boards/board-ap325rxa.c b/arch/sh/boards/board-ap325rxa.c
index caf4c33..72da416 100644
--- a/arch/sh/boards/board-ap325rxa.c
+++ b/arch/sh/boards/board-ap325rxa.c
@@ -216,6 +216,12 @@ static struct platform_device lcdc_device = {
},
};
+static void camera_power(int val)
+{
+ gpio_set_value(GPIO_PTZ5, val); /* RST_CAM/RSTB */
+ mdelay(10);
+}
+
#ifdef CONFIG_I2C
static unsigned char camera_ncm03j_magic[] {
@@ -245,9 +251,11 @@ static int camera_set_capture(struct soc_camera_platform_info *info,
int ret = 0;
int i;
+ camera_power(0);
if (!enable)
return 0; /* no disable for now */
+ camera_power(1);
for (i = 0; i < ARRAY_SIZE(camera_ncm03j_magic); i += 2) {
u_int8_t buf[8];
@@ -426,7 +434,7 @@ static int __init ap325rxa_devices_setup(void)
gpio_request(GPIO_PTZ6, NULL);
gpio_direction_output(GPIO_PTZ6, 0); /* STBY_CAM */
gpio_request(GPIO_PTZ5, NULL);
- gpio_direction_output(GPIO_PTZ5, 1); /* RST_CAM */
+ gpio_direction_output(GPIO_PTZ5, 0); /* RST_CAM */
gpio_request(GPIO_PTZ4, NULL);
gpio_direction_output(GPIO_PTZ4, 0); /* SADDR */
--
1.5.6.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 1/2] ap325 control camera power
2009-01-22 0:33 [PATCH 1/2] ap325 control camera power Kuninori Morimoto
@ 2009-01-27 0:22 ` Paul Mundt
0 siblings, 0 replies; 2+ messages in thread
From: Paul Mundt @ 2009-01-27 0:22 UTC (permalink / raw)
To: linux-sh
On Thu, Jan 22, 2009 at 09:38:31AM +0900, Kuninori Morimoto wrote:
> This patch add ov772x camera settings to ap325,
> Old camera is still supported. And it will be 2nd camera
> if you select ov772x and soc_camera_platform in same time.
>
> Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
> Signed-off-by: Magnus Damm <damm@igel.co.jp>
These are applied also, care to send a defconfig update?
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-01-27 0:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-22 0:33 [PATCH 1/2] ap325 control camera power Kuninori Morimoto
2009-01-27 0:22 ` Paul Mundt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox