Scara Setup
-
Davis is machinePos the coordinates reported in the web interface? Trying to work through the math….
-
Hi Bill,
One problem I have spotted is that the crosstalk factors must currently be specified in motor steps, not amounts of movement. In other words, your proximal to distal crosstalk factor of -1 means that each forward step of the proximal motor needs to be countered by one reverse step of the distal motor. As you are using different steps/mm for your proximal and distal arms, -1 is not correct for your machine. I think the correct value is -67/28.25 instead.
Thinking about it, it would be more logical to make the crosstalk based on amount of movement instead so as to be independent of the steps/mm. I'll make this change in the next 1.20 beta version.
-
Ok thanks I'll give it a shot
I think I will try this on my duet Wi-Fi just to make sure it is not just a problem with using the 0.6 board
-
I agree that cross talk based on movement would be better.
I think there may be a issue with the minRadius calculation (I could be wrong of course). When I input my values into the calculation I come up with a number that I do not believe is correct. Since my scara has limited movement (everything forms a right angled triangle at the limits because it can only rotate 90 degrees from 0) it is very easy to calculate some of the values. For instance the minRadius of my arm I believe is just the hypotenuse of the triangle it forms. I have a value of 150 or so for min radius based on this. When i put my numbers into the code I get a value of 211 or so(I may have done this wrong who know's just trying to pick away at things). My max radius is only 210.8. Let me know what you think about this.
-
You are right, the minimum radius calculation is wrong. Thanks for pointing this out. I've just corrected it in the source code and the next 1.20 beta will include the fix. I've also changed the way the crosstalk factors work, to relate the distances moved instead of the motor steps - in degrees for the arms and in mm for Z.
-
So I have switched everything over from the v0.6 to my wifi and I won't say everything works as expected but everything works. So there is definitely something that doesn't work with the v0.6. Jogging buttons on the web interface do not result in crazy movements, but still not the movements I would expect. Are the jog buttons going to arm move angles or coordinates? I still have not been able to get the proper movements I am expecting. Homing coordinates still do not seem right to me. Homing now reports the same numbers as before
2:38:58 PM
M114
X:95.221 Y:-58.365 Z:0.000 E0:0.0 E1:0.0 E2:0.0 E3:0.0 E4:0.0 E5:0.0 E6:0.0 E7:0.0 E8:0.0 Count -5695 -2401 0 User 95.2 -58.4 0.0I am running all the latest firmware and web control files. When I try to print a test file I get a bunch of errors from DWC, and cannot connect until the file is finished. Is there a way to see what the errors say? They seem to go away before I can copy them.
I will keep playing with this now that I can get some movements.
Thanks again
-
The error messages that pop up in DWC can be viewed on the GCode Console page. You can also configure how long they remain as popups before they time out.
The jog buttons should jog the XY coordinates.
SCARA support is currently working well on at least 2 printers that do not require crosstalk parameters in the M669 command.
As you are now running on a Duet WiFi, I'll make a pre-release 1.20beta7 release available for you to try when I am back in the office.
-
As my arms only turn 90 degrees i would expect my home position to be something like x -110 (proximal arm length)y -100(distal arm length). Does this make sense to you?
-
With zero X and Y origin offset in the M669 command, X0 Y0 is the location of the proximal joint, and +X is the direction that the proximal arm points at angle zero. So if both arms home to 90 degrees clockwise, then X= -distal arm length and Y= -proximal arm length sounds right to me. This is assuming that you don't have any other arm movement commands in homeall.g after the homing move, and that you have corrected the crosstalk factor to allow for the different steps/mm as we discussed previously.
Please try the following:
1. With power off, set both arms at 0 degrees. This is the position that the firmware assumes at power on.
2. Power on. The web interface should report the position as X= sum of arm lengths, Y= 0. Does it? M114 should report the step counts as zero.
3. Send G91 followed by G1 S2 Y90 to move the distal arm clockwise 90 degrees. Does the web interface report the correct position?
-
With the arms at 0 the printer turns on and reports x = 210.7 y = 0. Lengths of the arms would be 211.8 as defined in config.
I think this happens on this command
maxRadius *= 0.995; Which gives the 210.741
M669 K4 P111.4 D100.4 A-85:85 B-85:85 C-2.37:0:0 S150 T0.1 X0 Y0;
7:52:36 PM
M114
X:210.741 Y:0.000 Z:0.000 E0:0.0 E1:0.0 E2:0.0 E3:0.0 E4:0.0 E5:0.0 E6:0.0 E7:0.0 E8:0.0 Count -365 -41 0 User 210.7 -0.0 0.0Sending g91 followed by g1 s2 y90 rotates the distal arm clockwise 90 degrees. The web interface reports x = 100.3 y=89.3. I would expect x=111.4 y=100.4 or something close to this?
-
I can see what's happened. The original position is outside maxRadius, so the firmware has "corrected" it to be within maxRadius as if it were a position commanded by the user, by assuming the distal arm is rotated clockwise a few degrees (hence the motor step count of -41) and the proximal arm is rotated the same number of degrees clockwise. That's why the reported position doesn't agree exactly with the actual position.
When you home the printer, what is the reported position now?
-
11:18:00 AM
M114
X:95.221 Y:-58.365 Z:0.000 E0:0.0 E1:0.0 E2:0.0 E3:0.0 E4:0.0 E5:0.0 E6:0.0 E7:0.0 E8:0.0 Count -5695 -2401 0 User 95.2 -58.4 0.0This is with the printer sitting at the homing switches, same as before.
-
Your config says the homing positions are at -85deg for each arm. So by my calculations the position should be:
X = P * cos(85) + D * cos(85+85) = -89.17mm
Y = P * sin(85) + D * sin(85+85) = -128.41mmDo you agree?
I think I see what is happening. When the distal homing switch is triggered, the firmware is setting the distal motor position without allowing for the effect that the proximal motor has on the distal joint position. I'll fix this in the next beta.
As a temporary workaround, try this in your homeall.g file:
1. G1 S1 X… move to home the proximal joint.
2. G2 S2 X85 move to put the proximal joint at zero degrees.
3. Then home the distal joint.
-
There is a point where the crosstalk parameter starts to cause erratic movement. I will wait till I try your new release for further testing.
-
OK, I've just built the new version, so I'll test it with a view to releasing it shortly.
-
Installed new firmware this is results of M114 which is now right.
8:47:37 PM
M114
X:-89.163 Y:-128.423 Z:0.000 E0:0.0 E1:0.0 E2:0.0 E3:0.0 E4:0.0 E5:0.0 E6:0.0 E7:0.0 E8:0.0 Count -5695 -8092 0 User -89.2 -128.4 0.0Homing then rotating back to 0 angle results in x211.8 y0 which is right. Sometimes says y0.1 ?
OK David very good. I am able to send coordinates that make sense and it draws lines that are close to accurate. Can I expect the robot to change arm positions when just sending g1 commands or will it only work when running files?
-
Once you have homed all axes, it should respond to normal G1 commands from any source. G1 moves will be in straight lines. G0 moves will generally be curved.
-
I knew that was not clear enough question. If I were to command it to move to a coordinate that would require the use of the opposite distal/proximal arm angle should it switch. Also should I be able to manually command it to go to positions past the min radius.
-
If you give it a G0 command that requires an arm mode switch, then it should switch. A G1 command won't because G1 commands are supposed to be straight line movements. However, my own SCARA printer is only capable of one arm mode, so that is untested.
Positions below the min radius or above the max radius are unreachable, so if you command movement to such a position, the destination coordinate will be changed to an achievable position.
-
Just wanted to thank you again for helping with this David. I was able to get things dialed in fairly well using M579 to scale the y axis by 1.06. Further testing needed but I have confidence that this will work for me. Cross talk seems to be working with a value of -1, anything too far away from -1 get out whack? I have test printed (with a pen) a number of cubes rectangles and other shapes and designs with good results. Thanks again.