This week I worked with my team to do some initial system integration. We found a few kinks that we were able to work through. The OpenCV algorithm requires some adjustments, which I’ve been working on.
Firstly there needs to be some refining of the line detection. Running it realtime led to unstable lines, so the current plan is to initialize those locations with a clear board prior to starting the game. Doing this and getting all the lines to be clear has been a little more difficult to prove. My current solution has involved some adaptive thresholding, working on isolating the boards as solid colors, unfortunately the camera is able to pick up the slight variations in wood grain and those carry through, so this has been a work in progress.
Additionally I began work on my move detection. The current work seems very promising, which involves image subtraction, finding contours, and finding the centers. The issue with this is that shadows seem to break the contours apart, so some refining has to be done still.
Unfortunately I forgot to save screenshots while testing the code, so I will have to show them during the demo on Monday.
This upcoming week I plan on continuing to refine these two parts of the OpenCV. I also plan to begin transitioning the code from its current testing form consisting of a large loop, to a more usable code base. Previously I mentioned that I wanted to figure out what to send the Arduino in order to control the gantry, however this is being pushed back and I will work with Juan to make sure they interface well.