JPEG Decoder Not Working

Hi All,

I've been having a few issues trying to build my own AI person detection kit using an Arduino BLE Sense.

I've been following these instructions from github (https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/micro/examples/person_detection/README.md#debugging-image-capture) and so far so good but when I run the code and open the serial monitor it appears that the JPEG Decoder isn't working.

In their example, their reading 3080 bytes from a 2mp ArduCAM, and only a second later it goes on to decode the JPEG. When I run it, it doesn't decode the JPEG at all and only picks up 8 bytes from my 5mp ArduCAM.

I've inserted a copy of what my serial monitor says.

Any help with the issue would be great!

Thanks,
J

14:17:50.714 -> Starting capture
11:35:50.714 -> Image captured
11:35:50.784 -> Reading 8 bytes from ArduCAM
11:35:50.887 -> Finished reading
11:35:50.887 -> Decoding JPEG and converting to greyscal

You have the source - can't you add extra debug?

I'm only a beginner with this sort of stuff, don't understand what you mean

The reason the decoder is giving up after eight bytes is probably because it has decided the data it has been given does not have JPEG tags, or tags it doesn't recognise.

Ah ok, thanks!

Is this an easy fix? I'm using a 5MP camera because the 2mp is out of stock everywhere, and I'm trying to get this working for my final uni project due next month..!

A quick Google tells me the 5 MP ArduCam has several output formats: 5MP OV5642 1080P.RAW, RGB, YUV, JPEG.

For starters, make sure your camera does in fact produce JPEG output.