We made a web interface version of connect 3 where you can choose to play against another human or one of our many CPU strategies, or someone playing on our physical board! But the board may have a mind of it's own...


It is an attempt to broaden skills in multiple areas. Also connect 4 is fun but too hard so we made connect 3.

What it does:

We have a web interface for connect 3 that lets the user choose players 1 and 2 from a list of choices including themselves, other people, various kinds of CPUs, and our physical board. Our physical board is a way of interfacing with the server without using the website, and due to it's internet connectivity can be used from around the world.

How we built it:

We had four teams: Web design, hardware, server, and AI. The project was intentionally kept quite modular that way it would still work even if some parts would not be completed in time. Fortunately, everything was completed, and so our product is fully functional.

Challenges we ran into:

1) Java really doesn't like running servers with JavaScript web interfaces, nor does it like connecting to arduinos. There was a lot of library shuffling and working to figure out encoding of data during transfer. 2) The distance sensors used in our physical implementation of the board do not function all that well. This is not due to code, but largely due to poor hardware. That said, we were able to make it quite entertaining as well. 3) MinMax doesn't work quickly on large state spaces. The solution to this was to encode the board in a series of base 3 ints and changing the tree structure so that the state space didn't have to be re-explored nearly as often. This alone got the run time down to about 3 seconds on an empty board from the original 2+ hours.

Accomplishments that we're proud of:

Getting the server connected across many languages and figuring out how to minimize the search time on MinMax definitely top the list. That said, reaching out into areas that we didn't have as much experience with and innovating to do something new was quite enjoyable.

What we learned:

A lot, mainly about how interactions between different coding environments worked. In addition, it taught us some new ways to think creatively to reduce run time and conserve memory space as efficiently as possible.

What's next:

We would like to fix the hardware side; as fun as it is using the phantom inputs as another kind of CPU (which actually works pretty well because the phantom inputs tend to be from residual movement on the board, meaning that it will effectively blocks it's opponent) we would like to be able to use it as intended, and hopefully build it with better materials.

Built with:

Largely erector set parts with basic electronics, an arduino, and some "distance sensors" that work better as random number generators.

Prizes we're going for:

Arteck HB030 Portable Keyboard

Intel® Movidius™ Neural Compute Stick

$100 Amazon Gift Cards

Grand Prize

Jetbrains Pro Software

Team Members

Cole Smith, Shirley Xu, Sam Baltrus, Will Hammond, Julie Bosworth
View on Github