Hi,
I’m a french student (sorry for my english) and I’ve got a project to do at school. I have to make my Lynxmotion arm playing tic tac toe. And I’ve been asking to program it in Java. But I don’t know how to provide Java to the robot. Please can someone help me ?
Tu as un projet très intéressant.
Si tu utilise un bras Lynxmotion version SSC-32, tout ce que tu auras a faire c’est de créer ton programme Java et envoyer des commande série au SSC-32.
Une version comme celle-ci par exemple:
Regarde le manuel du SSC-32 pour te donner plus de détails.
Et bien sure, n’hésite pas a poser des questions ici…!
(Je te répond en Francais, mais si tu veux des réponses des autres membre, en Anglais c’est mieux)
Yes it’s a SSC-32 robot I’m am using. I’m going to read and work with the informations you gave me and I’ll keep you informed how the project is doing.
To help me on the projet I found a book writen by Scott Pretson called “The Definitive Guide to Building Java Robots”. It is really usefull but I still stuck on a lot of problems.
One I can’t tackle, is on “OutputStream” java method. I’ve got an error “java.lang.NullPointerExecption” and I don’t really get what it means. Can you help me ?
NullPointerExecption would mean that a variable you are passing to the method is Null when it should contain an object. If you can post your code, we may be able to quickly review it…
My goal is to send strings to the robot trough serial port. I worked with the Arduino link you gave before and it seem to work. But there is an error that I don’t understand :
Exception in thread “main” java.io.FileNotFoundException: COM3 (Accès refusé)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.(Unknown Source)
at java.io.FileOutputStream.(Unknown Source)
at java.io.PrintStream.(Unknown Source)
at AL5C.Déplacement.main(Déplacement.java:107)
In fact I thought that as soon as I was connected with the port and I wrote a string in the outStream, my robot was going to move.
What am I doing wrong ?
(I think it’s the right thing to do because I’m also using LynxTerm and when I wrote something like "#2 P1000 T2000 " it moves).
My project is almost finished. I’ve created a Java tic-tac-toe app and when you clic on a square, the robot takes the piece and put it at the right place. Then an AI choose a move, and the robot execute it. Unforunately, some “bugs” are still existing on our AI (sometimes, the player can win) but I’m working on it.