-
Notifications
You must be signed in to change notification settings - Fork 3
Description
The HM01B0 PIO driver appears to have a desync issue, where bits and/or bytes are lost in the datastream, resulting in corrupted images.
As a test, I pointed the camera at the following test image:
Sometimes the frame is mostly fine, but the top and/or bottom are corrupted:
Sometimes there are weird color shifts:
Much of the time, there is a "static" appearance:
Sometimes all of these artifacts appear several times in a single image (this also has a significant shift in the color wheel's position to the left):
I suspect this is caused by a desync with the pixel stream from the camera. I'm really not sure why this would be, because the driver uses the PIO and DMA with almost zero CPU input except for the vsync IRQ (I believe this finishes in ~100us from previous testing). It's especially bizarre, because I have some test code in Arduino that sets up the PIO and DMA in almost exactly the same way, and it works totally fine there.
The images above were captured by triggering the camera one frame at a time, so there shouldn't be any issues with the same buffer getting overwritten or anything like that.