|
MPScara G92 and machine coordinate issues January 31, 2026 08:24PM |
Registered: 5 months ago Posts: 28 |
|
Re: MPScara G92 and machine coordinate issues February 05, 2026 07:07PM |
Registered: 6 years ago Posts: 119 |
I have a working SCARA printer running Marlin, but it required a fair amount of modification. You can search through some of my posts in this section from a few years ago helping other people with it. It would take some time to get back familiarized with it, and I haven't checked if the main branch has been changed in the intervening years so the necessary modifications could be different now. And I'm not really familiar with RRF at all.|
Re: MPScara G92 and machine coordinate issues February 06, 2026 02:38PM |
Registered: 5 months ago Posts: 28 |
|
Re: MPScara G92 and machine coordinate issues February 06, 2026 08:42PM |
Registered: 6 years ago Posts: 119 |
|
Re: MPScara G92 and machine coordinate issues February 06, 2026 09:53PM |
Registered: 5 months ago Posts: 28 |
|
Re: MPScara G92 and machine coordinate issues February 07, 2026 03:12AM |
Registered: 6 years ago Posts: 119 |
|
Re: MPScara G92 and machine coordinate issues February 07, 2026 10:17PM |
Registered: 5 months ago Posts: 28 |
|
Re: MPScara G92 and machine coordinate issues February 08, 2026 01:09AM |
Registered: 6 years ago Posts: 119 |
void scara_set_axis_is_at_home(const AxisEnum axis) {
if (axis == Z_AXIS)
current_position.z = Z_HOME_POS;
else {
delta.a = SCARA_OFFSET_THETA1 - scara_home_offset.a;
delta.b = SCARA_OFFSET_THETA2 - scara_home_offset.a - scara_home_offset.b;
forward_kinematics(delta.a, delta.b);
current_position[axis] = cartes[axis];
//DEBUG_ECHOLNPGM("homeposition A:", delta.a, " B:", delta.b);
//DEBUG_ECHOLNPGM_P(PSTR("Cartesian X"), current_position.x, SP_Y_LBL, current_position.y);
update_software_endstops(axis);
}
}
Recompiling and uploading the firmware for every change is extremely tedious.|
Re: MPScara G92 and machine coordinate issues February 08, 2026 05:50PM |
Registered: 5 months ago Posts: 28 |
|
Re: MPScara G92 and machine coordinate issues February 09, 2026 08:16PM |
Registered: 6 years ago Posts: 119 |
#if !HAS_Y_AXIS #error "No Y axis" #endif
|
Re: MPScara G92 and machine coordinate issues February 09, 2026 10:45PM |
Registered: 5 months ago Posts: 28 |
Connecting... Printer is now online. >>> m111 s32 SENDING:M111 S32 echoEBUG
ETAIL >>> G28 SENDING:G28 >>> G28 X317.00 Y317.00 Z0.00 Machine Type: SCARA Probe: NOZZLE_AS_PROBE Probe Offset X0 Y0 Z0.00 (Same Z as Nozzle) Auto Bed Leveling: BILINEAR (disabled) >>> set_bed_leveling_enabled X317.00 Y317.00 Z0.00 <<< set_bed_leveling_enabled X317.00 Y317.00 Z0.00 Raise Z before homing: do_blocking_move_to_z(5.00, 4.00) >>> do_blocking_move_to X317.00 Y317.00 Z0.00 > X317.00 Y317.00 Z5.00 destination= X317.00 Y317.00 Z5.00 : prepare_fast_move_to_destination destination= X317.00 Y317.00 Z5.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X317.00 Y317.00 Z5.00 >>> homeaxis(Z) current_position= X317.00 Y317.00 Z5.00 : Probe::set_deployed deploy: 1 Probe::do_z_raise(10.00) do_blocking_move_to_z(10.00, 4.00) >>> do_blocking_move_to X317.00 Y317.00 Z5.00 > X317.00 Y317.00 Z10.00 destination= X317.00 Y317.00 Z10.00 : prepare_fast_move_to_destination destination= X317.00 Y317.00 Z10.00 : prepare_fast_move_to_destination echo:busy: processing <<< do_blocking_move_to X317.00 Y317.00 Z10.00 >>> do_blocking_move_to X317.00 Y317.00 Z10.00 > X317.00 Y317.00 Z10.00 destination= X317.00 Y317.00 Z10.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X317.00 Y317.00 Z10.00 Home Fast: -42.00mm >>> do_homing_move X317.00 Y317.00 Z10.00 ...(Z, -42.00, [4.00]) current_position= X317.00 Y317.00 Z0.00 : sync_plan_position <<< do_homing_move X317.00 Y317.00 Z-42.00 Move Away: 5.00mm >>> do_homing_move X317.00 Y317.00 Z-42.00 ...(Z, 5.00, 4.00) current_position= X317.00 Y317.00 Z0.00 : sync_plan_position echo:busy: processing <<< do_homing_move X317.00 Y317.00 Z5.00 Re-bump: -10.00mm >>> do_homing_move X317.00 Y317.00 Z5.00 ...(Z, -10.00, 2.00) current_position= X317.00 Y317.00 Z0.00 : sync_plan_position <<< do_homing_move X317.00 Y317.00 Z-10.00 >>> set_axis_is_at_home(Z) *** Z HOMED WITH PROBE (Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN) *** > probe.offset.z = 0.00 current_position= X317.00 Y317.00 Z0.00 : <<< set_axis_is_at_home(Z) current_position= X317.00 Y317.00 Z0.00 : sync_plan_position current_position= X317.00 Y317.00 Z0.00 : Probe::set_deployed deploy: 0 >>> do_blocking_move_to X317.00 Y317.00 Z0.00 > X317.00 Y317.00 Z0.00 destination= X317.00 Y317.00 Z0.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X317.00 Y317.00 Z0.00 <<< homeaxis(Z) >>> move_z_after_homing X317.00 Y317.00 Z0.00 >>> move_z_after_probing X317.00 Y317.00 Z0.00 <<< move_z_after_probing X317.00 Y317.00 Z0.00 <<< move_z_after_homing X317.00 Y317.00 Z0.00 current_position= X317.00 Y317.00 Z0.00 : sync_plan_position SCARA Theta:-13.17 Psi:103.17 <<< G28 X317.00 Y317.00 Z0.00
>>> G28 A B SENDING:G28 A B >>> G28 X317.00 Y317.00 Z0.00 Machine Type: SCARA Probe: NOZZLE_AS_PROBE Probe Offset X0 Y0 Z0.00 (Same Z as Nozzle) Auto Bed Leveling: BILINEAR (disabled) >>> set_bed_leveling_enabled X317.00 Y317.00 Z0.00 <<< set_bed_leveling_enabled X317.00 Y317.00 Z0.00 Raise Z before homing: do_blocking_move_to_z(5.00, 4.00) >>> do_blocking_move_to X317.00 Y317.00 Z0.00 > X317.00 Y317.00 Z5.00 destination= X317.00 Y317.00 Z5.00 : prepare_fast_move_to_destination destination= X317.00 Y317.00 Z5.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X317.00 Y317.00 Z5.00 >>> homeaxis(Z) current_position= X317.00 Y317.00 Z5.00 : Probe::set_deployed deploy: 1 Probe::do_z_raise(10.00) do_blocking_move_to_z(10.00, 4.00) >>> do_blocking_move_to X317.00 Y317.00 Z5.00 > X317.00 Y317.00 Z10.00 destination= X317.00 Y317.00 Z10.00 : prepare_fast_move_to_destination destination= X317.00 Y317.00 Z10.00 : prepare_fast_move_to_destination echo:busy: processing <<< do_blocking_move_to X317.00 Y317.00 Z10.00 >>> do_blocking_move_to X317.00 Y317.00 Z10.00 > X317.00 Y317.00 Z10.00 destination= X317.00 Y317.00 Z10.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X317.00 Y317.00 Z10.00 Home Fast: -42.00mm >>> do_homing_move X317.00 Y317.00 Z10.00 ...(Z, -42.00, [4.00]) current_position= X317.00 Y317.00 Z0.00 : sync_plan_position <<< do_homing_move X317.00 Y317.00 Z-42.00 Move Away: 5.00mm >>> do_homing_move X317.00 Y317.00 Z-42.00 ...(Z, 5.00, 4.00) current_position= X317.00 Y317.00 Z0.00 : sync_plan_position echo:busy: processing <<< do_homing_move X317.00 Y317.00 Z5.00 Re-bump: -10.00mm >>> do_homing_move X317.00 Y317.00 Z5.00 ...(Z, -10.00, 2.00) current_position= X317.00 Y317.00 Z0.00 : sync_plan_position echo:busy: processing echo:busy: processing echo:Homing Failed Errorrinter halted. kill() called! [ERROR] Error
rinter halted. kill() called!
|
Re: MPScara G92 and machine coordinate issues February 10, 2026 12:19AM |
Registered: 6 years ago Posts: 119 |
#if ENABLED(QUICK_HOME) #error "Dang it, who's still enabling quickhome" #endif
|
Re: MPScara G92 and machine coordinate issues February 10, 2026 10:07PM |
Registered: 5 months ago Posts: 28 |
#define SCARA_OFFSET_THETA1 90 - 1.287 // degrees
#define SCARA_OFFSET_THETA2 90 + 130.976 // degrees
void GcodeSuite::G28() {
DEBUG_SECTION(log_G28, "G28", DEBUGGING(LEVELING));
if (DEBUGGING(LEVELING)) log_machine_info();
#if !HAS_Y_AXIS
#error "No Y axis"
#endif
#if ENABLED(QUICK_HOME)
#error "Dang it, who's still enabling quickhome"
#endif
>>> m111 s32 SENDING:M111 S32 echoEBUG
ETAIL >>> g28 SENDING:G28 >>> G28 X0.00 Y0.00 Z0.00 Machine Type: SCARA Probe: NOZZLE_AS_PROBE Probe Offset X0 Y0 Z0.00 (Same Z as Nozzle) Auto Bed Leveling: BILINEAR (disabled) >>> set_bed_leveling_enabled X0.00 Y0.00 Z0.00 <<< set_bed_leveling_enabled X0.00 Y0.00 Z0.00 Raise Z before homing: do_blocking_move_to_z(5.00, 4.00) >>> do_blocking_move_to X0.00 Y0.00 Z0.00 > X0.00 Y0.00 Z5.00 destination= X0.00 Y0.00 Z5.00 : prepare_fast_move_to_destination destination= X0.00 Y0.00 Z5.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X0.00 Y0.00 Z5.00 >>> homeaxis(Z) current_position= X0.00 Y0.00 Z5.00 : Probe::set_deployed deploy: 1 Probe::do_z_raise(10.00) do_blocking_move_to_z(10.00, 4.00) >>> do_blocking_move_to X0.00 Y0.00 Z5.00 > X0.00 Y0.00 Z10.00 destination= X0.00 Y0.00 Z10.00 : prepare_fast_move_to_destination destination= X0.00 Y0.00 Z10.00 : prepare_fast_move_to_destination echo:busy: processing <<< do_blocking_move_to X0.00 Y0.00 Z10.00 >>> do_blocking_move_to X0.00 Y0.00 Z10.00 > X0.00 Y0.00 Z10.00 destination= X0.00 Y0.00 Z10.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X0.00 Y0.00 Z10.00 Home Fast: -42.00mm >>> do_homing_move X0.00 Y0.00 Z10.00 ...(Z, -42.00, [4.00]) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position echo:busy: processing echo:busy: processing <<< do_homing_move X0.00 Y0.00 Z-42.00 Move Away: 5.00mm >>> do_homing_move X0.00 Y0.00 Z-42.00 ...(Z, 5.00, 4.00) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position <<< do_homing_move X0.00 Y0.00 Z5.00 Re-bump: -10.00mm >>> do_homing_move X0.00 Y0.00 Z5.00 ...(Z, -10.00, 2.00) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position echo:busy: processing <<< do_homing_move X0.00 Y0.00 Z-10.00 >>> set_axis_is_at_home(Z) *** Z HOMED WITH PROBE (Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN) *** > probe.offset.z = 0.00 current_position= X0.00 Y0.00 Z0.00 : <<< set_axis_is_at_home(Z) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position current_position= X0.00 Y0.00 Z0.00 : Probe::set_deployed deploy: 0 >>> do_blocking_move_to X0.00 Y0.00 Z0.00 > X0.00 Y0.00 Z0.00 destination= X0.00 Y0.00 Z0.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X0.00 Y0.00 Z0.00 <<< homeaxis(Z) >>> move_z_after_homing X0.00 Y0.00 Z0.00 >>> move_z_after_probing X0.00 Y0.00 Z0.00 <<< move_z_after_probing X0.00 Y0.00 Z0.00 <<< move_z_after_homing X0.00 Y0.00 Z0.00 current_position= X0.00 Y0.00 Z0.00 : sync_plan_position SCARA Theta:0.00 Psi:0.00 <<< G28 X0.00 Y0.00 Z0.00
|
Re: MPScara G92 and machine coordinate issues February 12, 2026 04:55AM |
Registered: 12 years ago Posts: 14,691 |
|
Re: MPScara G92 and machine coordinate issues February 12, 2026 04:58AM |
Registered: 5 months ago Posts: 28 |
|
Re: MPScara G92 and machine coordinate issues February 13, 2026 02:57AM |
Registered: 6 years ago Posts: 119 |
char str[256];
sprintf(str, "needX %i, homeX %i, doX %i, trusted %i, homed %i, should %i",
needX, homeX, doX, axis_is_trusted(X), axis_was_homed(X), axis_should_home(X));
DEBUG_ECHOLNPGM(str);
G28 X Y Zsince lines 383 and 384 look like that will force homing X and Y even if it doesn't think they need it for whatever reason.
|
Re: MPScara G92 and machine coordinate issues February 13, 2026 04:54PM |
Registered: 5 months ago Posts: 28 |
),
home_all = NUM_AXIS_GANG( // Home-all if all or none are flagged
homeX == homeX, && homeY == homeX, && homeZ == homeX,
&& homeI == homeX, && homeJ == homeX, && homeK == homeX,
&& homeU == homeX, && homeV == homeX, && homeW == homeX
char str[256];
sprintf(str, "needX %i, homeX %i, doX %i, trusted %i, homed %i, should %i",
needX, homeX, doX, axis_is_trusted(X), axis_was_homed(X), axis_should_home(X));
DEBUG_ECHOLNPGM(str);
),
NUM_AXIS_LIST(
doX = home_all || homeX, doY = home_all || homeY, doZ = home_all || homeZ,
doI = home_all || homeI, doJ = home_all || homeJ, doK = home_all || homeK,
doU = home_all || homeU, doV = home_all || homeV, doW = home_all || homeW
);
Connecting... Printer is now online. >>> m111 S32 SENDING:M111 S32 echoEBUG
ETAIL >>> G28 SENDING:G28 >>> G28 X0.00 Y0.00 Z0.00 Machine Type: SCARA Probe: NOZZLE_AS_PROBE Probe Offset X0 Y0 Z0.00 (Same Z as Nozzle) Auto Bed Leveling: BILINEAR (disabled) >>> set_bed_leveling_enabled X0.00 Y0.00 Z0.00 <<< set_bed_leveling_enabled X0.00 Y0.00 Z0.00 Raise Z before homing: do_blocking_move_to_z(5.00, 4.00) >>> do_blocking_move_to X0.00 Y0.00 Z0.00 > X0.00 Y0.00 Z5.00 destination= X0.00 Y0.00 Z5.00 : prepare_fast_move_to_destination destination= X0.00 Y0.00 Z5.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X0.00 Y0.00 Z5.00 >>> homeaxis(Z) current_position= X0.00 Y0.00 Z5.00 : Probe::set_deployed deploy: 1 Probe::do_z_raise(10.00) do_blocking_move_to_z(10.00, 4.00) >>> do_blocking_move_to X0.00 Y0.00 Z5.00 > X0.00 Y0.00 Z10.00 destination= X0.00 Y0.00 Z10.00 : prepare_fast_move_to_destination destination= X0.00 Y0.00 Z10.00 : prepare_fast_move_to_destination echo:busy: processing <<< do_blocking_move_to X0.00 Y0.00 Z10.00 >>> do_blocking_move_to X0.00 Y0.00 Z10.00 > X0.00 Y0.00 Z10.00 destination= X0.00 Y0.00 Z10.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X0.00 Y0.00 Z10.00 Home Fast: -42.00mm >>> do_homing_move X0.00 Y0.00 Z10.00 ...(Z, -42.00, [4.00]) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position <<< do_homing_move X0.00 Y0.00 Z-42.00 Move Away: 5.00mm >>> do_homing_move X0.00 Y0.00 Z-42.00 ...(Z, 5.00, 4.00) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position echo:busy: processing <<< do_homing_move X0.00 Y0.00 Z5.00 Re-bump: -10.00mm >>> do_homing_move X0.00 Y0.00 Z5.00 ...(Z, -10.00, 2.00) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position echo:busy: processing <<< do_homing_move X0.00 Y0.00 Z-10.00 >>> set_axis_is_at_home(Z) *** Z HOMED WITH PROBE (Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN) *** > probe.offset.z = 0.00 current_position= X0.00 Y0.00 Z0.00 : <<< set_axis_is_at_home(Z) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position current_position= X0.00 Y0.00 Z0.00 : Probe::set_deployed deploy: 0 >>> do_blocking_move_to X0.00 Y0.00 Z0.00 > X0.00 Y0.00 Z0.00 destination= X0.00 Y0.00 Z0.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X0.00 Y0.00 Z0.00 <<< homeaxis(Z) >>> move_z_after_homing X0.00 Y0.00 Z0.00 >>> move_z_after_probing X0.00 Y0.00 Z0.00 <<< move_z_after_probing X0.00 Y0.00 Z0.00 <<< move_z_after_homing X0.00 Y0.00 Z0.00 current_position= X0.00 Y0.00 Z0.00 : sync_plan_position SCARA Theta:0.00 Psi:0.00 <<< G28 X0.00 Y0.00 Z0.00
>> G28 X Y Z SENDING:G28 X Y Z >>> G28 X0.00 Y0.00 Z0.00 Machine Type: SCARA Probe: NOZZLE_AS_PROBE Probe Offset X0 Y0 Z0.00 (Same Z as Nozzle) Auto Bed Leveling: BILINEAR (disabled) >>> set_bed_leveling_enabled X0.00 Y0.00 Z0.00 <<< set_bed_leveling_enabled X0.00 Y0.00 Z0.00 Raise Z before homing: do_blocking_move_to_z(5.00, 4.00) >>> do_blocking_move_to X0.00 Y0.00 Z0.00 > X0.00 Y0.00 Z5.00 destination= X0.00 Y0.00 Z5.00 : prepare_fast_move_to_destination destination= X0.00 Y0.00 Z5.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X0.00 Y0.00 Z5.00 >>> homeaxis(Z) current_position= X0.00 Y0.00 Z5.00 : Probe::set_deployed deploy: 1 Probe::do_z_raise(10.00) do_blocking_move_to_z(10.00, 4.00) >>> do_blocking_move_to X0.00 Y0.00 Z5.00 > X0.00 Y0.00 Z10.00 destination= X0.00 Y0.00 Z10.00 : prepare_fast_move_to_destination destination= X0.00 Y0.00 Z10.00 : prepare_fast_move_to_destination echo:busy: processing <<< do_blocking_move_to X0.00 Y0.00 Z10.00 >>> do_blocking_move_to X0.00 Y0.00 Z10.00 > X0.00 Y0.00 Z10.00 destination= X0.00 Y0.00 Z10.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X0.00 Y0.00 Z10.00 Home Fast: -42.00mm >>> do_homing_move X0.00 Y0.00 Z10.00 ...(Z, -42.00, [4.00]) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position <<< do_homing_move X0.00 Y0.00 Z-42.00 Move Away: 5.00mm >>> do_homing_move X0.00 Y0.00 Z-42.00 ...(Z, 5.00, 4.00) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position echo:busy: processing <<< do_homing_move X0.00 Y0.00 Z5.00 Re-bump: -10.00mm >>> do_homing_move X0.00 Y0.00 Z5.00 ...(Z, -10.00, 2.00) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position <<< do_homing_move X0.00 Y0.00 Z-10.00 >>> set_axis_is_at_home(Z) *** Z HOMED WITH PROBE (Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN) *** > probe.offset.z = 0.00 current_position= X0.00 Y0.00 Z0.00 : <<< set_axis_is_at_home(Z) current_position= X0.00 Y0.00 Z0.00 : sync_plan_position current_position= X0.00 Y0.00 Z0.00 : Probe::set_deployed deploy: 0 >>> do_blocking_move_to X0.00 Y0.00 Z0.00 > X0.00 Y0.00 Z0.00 destination= X0.00 Y0.00 Z0.00 : prepare_fast_move_to_destination <<< do_blocking_move_to X0.00 Y0.00 Z0.00 <<< homeaxis(Z) >>> move_z_after_homing X0.00 Y0.00 Z0.00 >>> move_z_after_probing X0.00 Y0.00 Z0.00 <<< move_z_after_probing X0.00 Y0.00 Z0.00 <<< move_z_after_homing X0.00 Y0.00 Z0.00 current_position= X0.00 Y0.00 Z0.00 : sync_plan_position SCARA Theta:0.00 Psi:0.00 <<< G28 X0.00 Y0.00 Z0.00
|
Re: MPScara G92 and machine coordinate issues February 15, 2026 11:25PM |
Registered: 6 years ago Posts: 119 |
I don't see the printout from it, but since G28 X Y Z didn't work, I think the problem is somewhere else anyway. At this point I'd really have to spam print messages throughout that function to reveal the path it takes, and probably a few more rounds tracing other functions from there before we finally discover what broke it. Too much trouble, I think. If you'd like, I can post my working firmware based on version 2.0.9.2. Otherwise I think you'll have to keep trying with RRF.
|
Re: MPScara G92 and machine coordinate issues February 16, 2026 01:31AM |
Registered: 5 months ago Posts: 28 |
|
Re: MPScara G92 and machine coordinate issues February 16, 2026 04:26AM |
Registered: 6 years ago Posts: 119 |
|
Re: MPScara G92 and machine coordinate issues February 16, 2026 04:38AM |
Registered: 5 months ago Posts: 28 |
|
Re: MPScara G92 and machine coordinate issues February 21, 2026 02:07AM |
Registered: 6 years ago Posts: 119 |
|
Re: MPScara G92 and machine coordinate issues February 21, 2026 09:55PM |
Registered: 5 months ago Posts: 28 |
|
Re: MPScara G92 and machine coordinate issues February 22, 2026 01:48AM |
Registered: 6 years ago Posts: 119 |
lol, I intentionally didn't explain that so I could use you as a guinea pig, and apparently the comment above it is not clear enough after allQuote
Chip Bark
One question I had when going through config.h was SCARA_HOME_DIST_TO_NOZZLE. I put the number in as the direct diagonal distance from shoulder axis to nozzle at 0,0, but if it needs to measured some other way or if it is ignored fully, then so be it.
It should work with 352.6486, or you can ignore it and just set THETA2 to (90+130.976) or 220.976 like before. I calculated THETA2 that way since it's easy to measure the shoulder-to-nozzle distance on my printer after homing, whereas measuring the exact elbow angle is not. But I'll probably just remove that value entirely. I added handling of the M665 values for MPSCARA since then, so now it's easy enough to start with the nominal elbow angle and adjust while printing rectangles until the lines are straight and square, rather than trying to get it perfect by measuring the printer itself.Positive X is right, positive Y is up, zero angle points to the right (along positive X), positive angle rotates counterclockwise. So there is still a problem with the configuration if it's moving in the opposite directions. Is it possible your motor directions are wrong? You could try setting INVERT_X_DIR and Y to true, or to be more certain, compile it as a non-scara printer and see if positive X and Y moves cause counterclockwise motion like they should.Quote
Another point is, like with the confusion on RRF firmware, the offset theta: is it based on X axis to the right (when looking down on the machine) or is it on Y towards up? RRF is the former, but I want to say Marlin was the latter.
|
Re: MPScara G92 and machine coordinate issues February 22, 2026 02:16AM |
Registered: 5 months ago Posts: 28 |
|
Re: MPScara G92 and machine coordinate issues February 22, 2026 04:03AM |
Registered: 6 years ago Posts: 119 |
motion.delta.set(
DEGREES(THETA1),
DEGREES(THETA2 - THETA1 * SCARA_CROSSTALK_FACTOR),
z - (THETA1 + THETA2) * (8/(M_PI*2))); // Convert from radians to 8mm per leadscrew revolution
Delta requires movement of all motors for Z, so hopefully SCARA will call its kinematic function for Z-only moves too. Homing may still be a problem since we disabled the SCARA bit in do_homing_move so each axis motor moves separately (Z probably won't get the correction). But if we re-enable it, then it's impossible to disable the elbow motor while homing the shoulder, so the arm can crash into itself depending on where it starts from. Same with quickhome (which moves both motors simultaneously), plus then the elbow may get a wrong value if it reaches its endstop first and then the shoulder continues moving and crosstalking it to a different angle. I suppose in the worst case you could use quickhome and manually position the arm in such a way that it will reach the shoulder endstop first.|
Re: MPScara G92 and machine coordinate issues February 22, 2026 07:41PM |
Registered: 5 months ago Posts: 28 |
Marlin\src\module\scara.cpp:173:7: error: 'Z' was not declared in this scope
173 | Z - (THETA1 + THETA2) * (8/(M_PI*2))); //Convert from radians to 8mm per leadscrew revolution
| ^
|
Re: MPScara G92 and machine coordinate issues February 22, 2026 10:54PM |
Registered: 6 years ago Posts: 119 |
|
Re: MPScara G92 and machine coordinate issues February 22, 2026 11:05PM |
Registered: 5 months ago Posts: 28 |
Marlin\src\module\scara.cpp:173:7: error: 'z' was not declared in this scope
173 | z - (THETA1 + THETA2) * (8/(M_PI*2))); //Convert from radians to 8mm per leadscrew revolution
| ^
*** [.pio\build\STM32H723VG_btt\src\src\module\scara.cpp.o] Error 1
Marlin\src\module\scara.cpp:173:7: error: 'z' was not declared in this scope
173 | z - (THETA1 + THETA2) * (8/(M_PI*2))); // Convert from radians to 8mm per leadscrew revolution
| ^
|
Re: MPScara G92 and machine coordinate issues February 22, 2026 11:44PM |
Registered: 6 years ago Posts: 119 |