Color Segmentation

Part of my current project, I need to implement a “Color Segmentation” solution that runs on a microcontroller (no OpenCV or other stuff). I got my serial camera up and running, got my model posing fr me, now all I need is to understand how this works :-)

Ok, is not that bad, already managed to get a basic color segmentation working pretty fine actually for now:

Well, this is captured by the camera, connected to an MBED microcontroller, streaming to the computer and displayed through Processing. All works pretty well @128 x 128 pixels can squeeze a few fps, pretty ok for what I’m planning to use it: very basic navigation. Looking to get a more powerful but cheaper microcontroller connected to a OV7670 camera using the parallel port instead, which will give me a higher fps. But for now, just trying to understand how this entire image processing part working…

Update will come shortly ^_^


5 thoughts on “Color Segmentation

  1. Hi, I am wulan.
    I have question. can you help me how to make color segmentation for OV7670 Camera using ARM Cortex M3?
    I need to make a line follower robot.


    • Hi Wulan, not sure what you mean. Color segmentation is just refering to an image processing basic algorythm that will allow you to select one particular color from an image. The easiest one is to convert from RGB to YCrCb. FYI, OV7670 can be configured to output YUV and even YCrYCb, can see details in the manual.
      Once you get your microntroller talk with your camera module, you should be able to have the image as a line or array, then everything else is only math to separate the color you track and create an algorythm that will calculate and interpret the blobs having that color… Hope this helps, good luck with your project!

  2. Thank you claud for your suggest.. ^^
    In this case. I use my camera to track the line.
    So, it’s just to detect of the line that’s color black and white.
    May I ask u’r program sample of color segmentation using ov7670 ?
    Or.. have you try this camera on ARM Cortex M3 board module? Because I used ARM Cortex M3 as my microcontroller to talk with camera module.

    • You are welcome.
      I do have the first version done on LPC1769 but is only the control part and a more complex image processing algorythm. I’ve switched to Atmega8 cause can make my own board and i find development faster on AVRstudio then on ARM IDE… Plus can focus more on code optimization and memory usage. Plan to build a bigger projecton ARM Cortex with stereoscopic vision, if the time allows, sometime soon.
      Will try to post some code but now rushing preparing for a few weeks trip, so not sure when i’ll have time.
      Good luck with your project! Let me know how it goes ^_^

  3. Hello
    I was a student. I am from vietnam and i am doing a project on arduino uno and ov7670 fifo and i find that this is quite difficult for a student not good at english. So gentlemen can share how a uno and ov7670 camera can work so. I thank you gentlemen.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s