Misty Community Forum

How to focus Misty's camera when taking picture?

Hi, I am making a skill that involves extracting text from a picture. The picture is taken using misty.takePicture(). However, the picture is always out of focus. Here’s an example.

When I move it closer to the camera, it is also blurred.

How does the camera focus work? Is there any way to improve this? Thank you!

Hi @Zetzaus,

Misty’s camera is designed to be a fixed focus camera, with a focal length at infinity. In other words, she should be focusing but it doesn’t appear she is. If you take a picture through the Command Center, do you get the same result or does she end up focusing?

We did have a small batch of cameras that ended up being defective. Would you mind emailing support@mistyrobotics with your Misty type (Basic, Standard, Enhanced), and its serial number?

Hi @scott.bobbitt, thanks for the reply.

I reached out to the support team, and the camera most likely is not defective.

Taking a picture from the command center and the skill results in the same thing.

One thing that improves this a lot is by putting down the phone, meaning that the blur is heavily affected by my shaky hands. Another factor is that capturing text in a display is also more complicated than capturing text in a paper.

However, there’s this strange phenomenon that Misty loses focus after some time of operation. When the robot is turned on (after a “long” off time), the focus is at its best. After running the skill for some time, the focus reduces.

This is the image when the robot is just turned on.

This is the image after running the skill for ~15 minutes (zoom in and you can see the difference)

The skill itself is just taking a picture and sending it to a local server. Misty listens to the head front sensor. When touched, Misty takes a picture and sends it to my local server.

I have also checked that the image received by the server and the image saved by Misty in her local memory is identical.

Any idea what is the problem?

Apologies for the slow reply, and yes, this is a strange symptom. A couple of details will help to gain an understanding of what might be happening:

  • Is this result consistent, and if so, does it always occur after a particular amount of time?
  • When this occurs, what else is the robot doing?
  • Subjectively, do you notice any lighting variations when this is happening?

Interestingly, in looking at your images, the effect isn’t uniform. The COVID sign in the top part of the picture looks pretty close in both pictures. There’s a bit of a difference in the brightness of the pictures, which is likely the effect of either auto exposure or auto white balance in the camera module itself.