Ulrik – Week 8
The designing of the spacers and fittings for the gantry has been done this week and I have gotten them 3d Printed. I have assembled the gantry and added it to the V-profile, but the number of wheel-bearings needed was 2x, so I need 8 more for the other side. One side, one to go.
I have been spending a lot more time than expected on the gantries, both in terms of lacking shelf-parts and availability. The want for designing the needed parts instead of just buying a complete set was chosen for the learning of it.
The whole robot has a clear stability-issue regarding the height of the crane and the thickness/fastening of the plexiglass-plates. To combat this problem, I have designed some bracings to be fitted to the rigid legs and feet. The engines on top will power the movement, and the crane is way over dimensioned, so I will try to replace them with smaller one. This should also make the momentum created by movement significantly smaller. Adding photos.
My plan for this week is to fit the bracings and the gantry without bearings. Fastening Will be done by gluing.
Sondre – Week 8
This week, I have same as last week, been participating in military exercise.
I started to investigate and design a gear and rack for the stepper motor in SolidWorks.
Jon-Eirik – Week 8
This week I worked with Kristian on Monday again. Our goal was to be able for all the 4 motors to work together. We have 2 motors who work on the same axis, 1 motor that works on the opposite axis and the last one that works to pick up the pieces.
I also learned that the sensors we planned 2 weeks prior were not possible to order as it would take too much time to get here, so we talked with Steven and ended up ordering Neodymium magnets and Hall Linear sensors for our board.
These sensors work the same way as the KY-003 chips we were planning to use, so it’s just a little more work soldering these together on our setup. They have 3 pins where pins 1 is for CVV, pin 2 is for GND and pin 3 is for Output. This is where we will read the state of the sensor to watch how the pieces on the board have been moved. The signal it sends helps our AI understand what move has been done and it can then calculate the best move it can do.
Kristian – Week 8
I started this week testing some code I had done the week before, but there was some trouble in paradise. I couldn’t fathom why the z axis motors didn’t move at all…. Luckily Jon Eirik managed to find a couple stupid mistakes in the code regarding the motor setup for the z axis motor. After he found the mistakes, I corrected them, and the motors worked as intended.
This week I decided to change the order of operation for the robot moving chess pieces. Before it would go: Home -> to chess piece -> pick up -> go home -> go to destination for piece -> put down -> home
now: Home -> chess piece -> pick up -> destination -> put down -> home
This is a much less time-consuming operation and will look way smoother.
The robot couldn’t handle a situation where it had to take an opponent’s piece, but now it can. It can move a piece to an empty chess square or remove enemy chess piece and then moving its piece to the destination square (which held the opponent’s piece)
There is an if statement there that will later check if the destination square holds an opponent’s piece. There is some code missing for the statement to work at this point, but when that piece of the code is implemented, the new code should work as expected.
altered code:
Emil – Week 8
So, this week I’ve been working on the code since last week to make it work. Now it’s working and you can now easily put in all the coordinates or how far the 2 motors are supposed to go to reach each square. Same as last week we have 3 different arrays, one that has each position, a1, b2, c3 etc. Then we use that array to locate what position the square that we want is located in.
My problem last time was that I couldn’t get the proper values, now we do. What I needed to change was put the arrays for Xmotor and Ymotor in setup instead of inside the function. Then I had to create the values for Xcord and Ycord already in the function receivestockfishmove so that it could send this as well to the other function. Then I put a default value on Xcord and Ycord being -1 so I could know there is issues here. For the for loop, it’s pretty much the same, only that I’ve added so it does both motors instead of only one.
The code:
Pictures of the program working:
This is right before i send a move which is d7d5. And here is after:
To test and show that everything works we can test with values a1 and h1, this should be values 1 and 8, wich it is.