ArduCAM / Arduino

This is ArduCAM library for Arduino boards
MIT License
479 stars 351 forks source link

OV2640 2MP Mini: Take RAW Grayscale image #206

Open dilpreetdan opened 7 years ago

dilpreetdan commented 7 years ago

Hello, How can we take a grayscale RAW image from the OV2640 2MP Mini camera? I need a 160*120 image with 8 bits per pixel data.

Can you please provide some code for the same.

Thanks!

dilpreetdan commented 7 years ago

Hello, Any help in this would be really appreciated!

UCTRONICS commented 7 years ago

@dilpreetdan Hi, Very sorry for we do not provide source code of Host V2.

Let us know if you need more help. Regards, ArduCAM support team.

dilpreetdan commented 7 years ago

Thanks for responding.

Firstly, I think this is another thread to reply to. Secondly, I see that the source code of Version 1 was available. Thirdly, using the source code of version 1, I could verify that the bitmap image is not getting produced. (https://github.com/ArduCAM/Arduino/issues/205) Please rectify such problems so that a correct BMP image is produced.

Thanks!

UCTRONICS commented 7 years ago

@dilpreetdan Hi, We have tested our host_V2 and Video_Streaming code and they can work fine for getting BMP image .

Pleaase download our Host_V2 from https://github.com/ArduCAM/Arduino/tree/master/ArduCAM/examples/host_app/ArduCAM_Host_V2.0_Windows Please download this code: https://github.com/ArduCAM/Arduino/tree/master/ArduCAM/examples/mini/ArduCAM_Mini_Video_Streaming

Let us know if you need more help. Regards, ArduCAM support team.

dilpreetdan commented 7 years ago

206

As you can see from the image, temp=0x31 and temp=0x30 doesn't happen in the order. While the instructions on the top of the file say:

// 8. If receive 0x31 ,set camera to BMP output mode. // 6. If receive 0x30,camera will capture a BMP photo and buffer the image to FIFO.Then write datas to Serial port.

This should help you identify the problem. Please can you verify in your BMP image if the header is correct. Thanks!

dilpreetdan commented 7 years ago

Surprisingly, with Arducm Host v1.exe this is not the issue. I could verify that from the source code. 206 1

I think in the python script where I receive the data, I should be counting length <153664 and it should help with the BMP.

UCTRONICS commented 7 years ago

@dilpreetdan Hi, Thank you for your advice and we will optimize our host V2 as soon as quickly. Regards.

dilpreetdan commented 7 years ago

Hello, Please provide some feedback on grayscale image. How do I take a grayscale image (like .PGM format).

Thanks!

nikita-kotsehub commented 3 years ago

Any updates on the RAW grayscale image? @dilpreetdan @UCTRONICS