LEGO Tic-Tac-Toe robot

This was actually built for a competition where robots played other robots… no human intervention allowed. It only uses 3 motors, but can clean up after itself… something I’m still working on with my children.

For more information on the details, I’ve put up a comic strip explaination of sorts on Brickshelf:

http://www.brickshelf.com/cgi-bin/gallery.cgi?f=161188

Duration : 0:1:55


Related Reading:

Uncategorized

Be Sociable, Share!

Technorati Tags: lego, rcx, robot, Tic-tac-toe

25 thoughts on “LEGO Tic-Tac-Toe robot

  1. i no its funny lost …
    i no its funny lost by your own invention omg it could be to powerfull runnnnnnn for you lifeeeeesssssssssss…………….lol

  2. This was programmed …
    This was programmed in NQC, a “C-like” language built on top of the stock LEGO firmware for the RCX. The method is a simple (custom) evaluation function applied to every cell, with the piece being played in the cell with the highest “score”. I really should have looked on-line first, but figuring it out myself was far more fun.

  3. No actually – this …
    No actually – this was done with a single RCX. I have a friend who has built one based on the NXT (named W.O.P.R. – search for that + NXT here on YT), but I’ve yet to redo this.

  4. That’s not a bad …
    That’s not a bad suggestion – perhaps I will. It’s still very easy to explain, but not as well-known a variation, so it might be more “interesting” for the human player.

  5. Nice! I think you …
    Nice! I think you should change the functionallity a bit.

    1) Let each player only place three pieces on the board.
    2) When a player have three pieces on the board, let the player pick up one piece and places it somewhere else on the game board.

    This will make it more realistic.

    By player, I mean you and the robot.

  6. So does the robot …
    So does the robot have to touch all the pieces to see were there at so it can know wat spaces are empty and which are not?

    But anywais good job i did one similar to this.

  7. Yes… that’s a …
    Yes… that’s a feature I really loved about it, and in fact it does better than my kids on that point 🙂

  8. amazing…
    i’m now …

    amazing…
    i’m now startin to build the parts…
    its a project from school…so no legos included…just PIC and work…
    Thanks …congratulations !

  9. Yes, well… I * …
    Yes, well… I *might* have done that on purpose so that the video would show something more interesting than yet another “cat” (draw).

  10. Building it took a …
    Building it took a few days – the hard part was the gripper that would raise/lower/open/close all using one motor, and the rest took a single evening. Programming it too a little longer, perhaps another four evenings more or less.

  11. Its really amazing. …
    Its really amazing…could you tell me how long did you take to do that?…. i am looking to build one of this, but without lego…
    thanks

  12. wow man.

    I just …
    wow man.

    I just think thats really amazing. and your right, you could in fact get it to play chess with just a slight nodification to its programming.

    instead of scanning and going back and picking up a peice, it would only need to scan, and then decide which peice to move and move it.

    very amazing dude. that rocks. you should work for a robotics company of some sort.

  13. You could make it …
    You could make it do 4×4, or bigger – the mechanism I used can be expanded rather easily, and would scale up to a much larger board. And the programming is, well, just programming – there’s no reason it couldn’t play chess (although the amount of memory and processing power is rather limited). In fact, I’ve thought of adapting Gardner’s mini-chess (5×5 board, all types of pieces & legal moves), but haven’t moved that way… yet.

    Yes, you could make this an adaptive learning program as well.

  14. dude thats so cool …
    dude thats so cool though.

    you basically made something that in a way, learns…until it gets reset, but still.

    hey, think you could make it do a 4×4, or even bigger?

  15. Actually… it …
    Actually… it doesn’t. Since each turn only one square should be marked, it just looks for the single cell or square that has a new block (it remembers where all the blocks from the last turn were. If you watch it’s only checking previously empty cells each turn for this reason.

    Yes, you can “cheat” and move blocks around, or put in two at once, etc. It umes the human will play a fair game. Otherwise, it would require more checking to catch such cheating.

  16. oh man.

    thats …
    oh man.

    thats cool.

    how does it destinguish the blacks and whites….. wow that sounds racist

  17. Fair enough – I …
    Fair enough – I couldn’t answer right away because I was hiking in the Rockies, doing off-trail routes up 12,000′ peaks. Honest. What were you doing this week 🙂 ?

    And yes, I still get things like this built “for fun”.

  18. dude u neeeed to …
    dude u neeeed to get out of ur room…smell the precious life u’ve so sadly wasted away =(

Leave a Reply