This is about my Robot Arm project. My Robot Arm is your AL5A Robot Arm.
I made a phone call yesterday. You told me your Atom pro allows me to control only one stick and the whole arm will go the way I want. That sounds perfect. Couple questions before I purchase your solution.
What part do I need to purchase? PS2 Robot Controller(RC-01), PS2 Wireless Controller Receiver (PS2R-01), Bot Board II (ABB-01), BASIC Atom Pro 28 Pin (BAP-02), anything else?
Servo, 180 degree servo or 90 degree servo?
When I use this solution, can you give me a simple description how to operate PS2 controller to operate the Robot Arm?
Thank you for your info. They are very helpful. I have another question. In the your program, you have preset AL5A, AL5B, AL5C, and AL5D. But, I cannot use those Arms because the project requires a lot longer arm. We have to make one ourselves. In this case, what can we do?
We received all components. Now, we are trying to figure out how to load the program into the Atom Pro 28. I connect 9v battery to Bot Board II, the green light come up fine. I ran find processor, it found processor on com5. Therefore, my USB to serial connection is fine.
When I tried to run program. I got a message “A Basic Atom Pro Processor Must be connected for automatic detection”. I click on Debug, I got the same thing.
I was studying the code I download from the link you provide. The program name is ps2arm1.bas. Open the file in the Basic Micro Studio. Can you help to point out where do we need to modify if we use the arm designed by ourselves. Our Arm is similar to your AL5D just a little bit longer.
So Studio can find your board and the chip is probably installed correctly. What I normally do, is to set the drop down lists in the toolbar of Studio to my specific settings. That is.
The first drop down is set to “BasicAtomPro”. The 2nd is set to “BAP 28”. The 3rd is set to the comm port that is connected to your board. In this case “Com5”. I do this as when you use the Auto settings you must always have your board plugged in and powered up when you try building your program.
As for What to set, you probably need to set the constants that are currently in #ifdef blocks…
#IFDEF AL5A
HumerusLength con 94 ;Length of the Humerus [mm]
UlnaLength con 108 ;Length of the Ulna [mm]
InitWristPosX con 20 ;Init position X
InitWristPosY con 145 ;Init position Y
InitGripperAngle1 con -400;Init Angle gripper [/code]
There are whole sets of these, that are currently controlled by the block above this:
[code];Select Arm type
;NOTE: Enable only one arm!
;AL5A con 1
;AL5B con 1
;AL5C con 1
AL5D con 1
You can either define one of these and then modify it, or you could define a new one…
Also depending on how different your arm is, you may need to update the min and max angles for each of the servos.
Rigth now, everything is moving. But, still need some modification.
Coordination system. In the code, there are three lines. Asking position X and Y of the initWrist. Where is the origin, and what is positive X and Positive Y in your program?
InitWristPosX con 60 ;Init position X
InitWristPosY con 150 ;Init position Y
InitGripperAngle1 con -550 ;Init Angle gripper
Can I increase servo speed?
I have a hand. In the code, there are only Humerus and Ulna. How can I handle hand? What does InitGripperAngles1 mean?
HumerusLength con 275 ;Length of the Humerus [mm]
UlnaLength con 180 ;Length of the Ulna [mm]
InitWristPosX con 60 ;Init position X
InitWristPosY con 150 ;Init position Y
InitGripperAngle1 con -550 ;Init Angle gripper
Where we are operating the PS2 controller, the robot went crazy and them stop with red LED flashing, then that happen, the controller stop working. We have to reset the controller in order to get it to work again. Is this normal?
Is there a way we can view the program in the Atom pro 28 to make sure the program is correctly loaded.
That is the bright side. You are free to make as many modifications as you would like. The code you see is the code that is being used. So if you need a different starting position, try changing it and then simply reprogram the controller.
Yes. What have you tried? There are several ways to try to make it work differently/faster. You might try changing some of the code and see if you like the results.
Things like:
So there are comments here in the code talking about the Left stick moving either Up/down or Left/right. Each section appears to be updating a position by some value returned from the PS2 divided by 18. What happens if you change 18 to 10? does it work better?
b) You might try changing the time for each movement. In the code you have:
GOSUB Movement-BaseAngle1, -ShoulderAngle1, -ElbowAngle1, -WristAngle1, -Gripper1, -WristRotateAngle1, 100] ; kje - convert to integers
In here the 100 is the time in milliseconds, so try changing to 75 or …
Just comeback from a trip. Thank you for your reply. The crazy beep is because I connect PS2 control in wrong way. Sorry about that. Things improve a little bit. We think the problem is calibration. Everything reacts to the control and moving. But couple things still not under control. Is there a way to calibrate the arm? I saw you have a program that can calibrate the robot. Does that also works for BB II Atom28 pro without SSC32 board?