- Configuring LinuxCNC
- Configuration Tools
- StepConf Wizard
- Confused by reversed axis direction vs. homing
Confused by reversed axis direction vs. homing
- munki
- Offline
- New Member
- Posts: 5
- Thank you received: 0
The preamble: I'm very new to CNC stuff in general. This is my first mill. I apologize in advance if I get any terminology mixed up, as I likely will...also, sorry if I get wordy. I'm a sucker for details, not all of them worthwhile.
The installation: It's based on a design called the Brute II and I got the plans from some guy who's website I seem to have lost in the shuffle. The plans were good, the mill seems solid and logical enough. I left the horizontal axes longer than they were designed, by quite a bit, and turned the z axis around backwards for clearance, but that's neither here nor there. I'm pleased with the construction. It's a setup wherein the z-axis just moves up and down and the x- and y-axes move about underneath it, so that the workpiece is what moves instead of the spindle. For the control hardware, I'm using a fet-3 roadster from stepperworld. For software, I'm running the version of emc2 that comes on the 8.04 livecd. I would be using the more recent 10.x version, but to make a long story short, it wouldn't take on my computer and I was forced to go back to 8. The computer itself is just an old desktop with a P4 of some sort.
The lead-in: Because my table moves under the spindle, rather than the spindle moving across the table, I have to reverse the direction on my x- and y-axes. Looking at the mill from the "front," when the table is in the far right corner, the spindle is at 0,0. When the table is at the near left corner, the spindle is at 12,12. I put home switches on each axis such that they are depressed when the table is moved to the 0,0 position, meaning the y-home switch is at the far end of that axis, and the x-home switch is at the far right of that axis.
The setup: When I tell emc to home an axis, it sends the table marching off in the correct direction until it finds the switch, as one would expect. This works for both axes. Once homed, it displays on the 3D model of the toolpath view (not sure what the proper term there is) with the tool as being in the lower left corner of the workspace, which (relatively) it really is. It shows the bounding box of the working space as extending away (from the front of the machine) and to the right. All seems well. If I manually jog using the +/- controls, everything moves as you would expect. For instance, with the x-axis, pressing + moves the table to the left, thereby moving the spindle in the positive direction in the working space. Pressing - does the opposite. Similarly, for the y-axis, pressing + moves the table towards the front of the machine, thereby moving the spindle in the positive direction in the working space, and of course vice versa for -. The entire toolpath is displayed as being well inside my available working space. The 3D view corresponds precisely to the spindle is doing relative to the working space.
The punchline: When I tell it to GO and start running the program, suddenly it acts as if emc has no idea which direction is up, in, out, or around. While the 3D view shows the tool following the toolpath, the directions are all suddenly reversed on the actual mill, as it immediately attempts to move in the opposite directions. As the software thinks the tool is zipping towards the middle of the working space, my mill is actually hitting the hard stops almost immediately and my motors stall out with nowhere else to go.
It's like everything is perfectly in order until it tries to actually run the program, at which point it forgets that everything should be reversed. I've tried turning the direction flipping on and off in the stepconf wizard, I've tried claiming the home switches are at opposite ends, and both combinations thereof.
I'm sure I must just have some confused notion of what +/- means in this case, but I'm completely baffled as to how to fix it. It seems like this ought to be a no-brainer to someone who's more familiar with configuring this stuff, but I'm at a loss. 2AM last night found me staring at stepconf wizard for the hundredth time, ready to pull my hair out.
Here's the mill itself, viewing from what I've been considering the front-right (the z-axis mounts at the "back"). The table is currently in the home position, such that the tool is at 0,0:
And here's the config file as it currently stands:
pastebin.com/NWjAMDAX
Any help at all that can be offered would be much appreciated. I'm going batty over here trying to figure out what I'm not grasping.
Please Log in or Create an account to join the conversation.
- munki
- Offline
- New Member
- Posts: 5
- Thank you received: 0
Please Log in or Create an account to join the conversation.
- Rick G
- Offline
- Junior Member
- Posts: 28
- Thank you received: 156
If not you might want to get that running properly and then attack the home switches.
The pastebin is a bit hard to read on my computer.
Rick G
Please Log in or Create an account to join the conversation.
- andypugh
- Offline
- Moderator
- Posts: 23310
- Thank you received: 4858
If I manually jog using the +/- controls, everything moves as you would expect. For instance, with the x-axis, pressing + moves the table to the left, thereby moving the spindle in the positive direction in the working space.
Stationary spindle, moving work is conventional for a mill, so that isn't a problem.
When you jog X + what does the digital display of X numbers show? Does the number get bigger, or smaller?
Rather than use stepconf, you can try editing the ini file directly, negating the stepgen scale might well sort things out.
Initially you should probably try ignoring the home switches (you can put NO_FORCE_HOMING=1 in the [TRAJ] section of the INI file temporarily)
Please Log in or Create an account to join the conversation.
- munki
- Offline
- New Member
- Posts: 5
- Thank you received: 0
This right here was powerfully useful, thanks!(you can put NO_FORCE_HOMING=1 in the [TRAJ] section of the INI file temporarily)
So I now have it sorted out for sure which direction is "up" on this thing. I ran through the little EMC2 demo file, and it made all the movements accurately and correctly. Being able to actually run programs now that I don't have to count on the homing switches did a ton to help sort out the directionality of everything.
Now that I know the axes themselves are all properly configured (and fixed my max speed/acceleration values, that certainly made for some lovely noise the first time) I can continue to futz with the home switches. Before I do that, though, I seriously need to make some chips, just to prove I can.
Thanks a ton!
Please Log in or Create an account to join the conversation.
- BigJohnT
- Offline
- Administrator
- Posts: 7106
- Thank you received: 1177
John
Please Log in or Create an account to join the conversation.
- munki
- Offline
- New Member
- Posts: 5
- Thank you received: 0
Learned something tonight: foam core cuts really nicely...scrap pine does not.
Anyhow, I've officially made chips, and that's the biggest hurdle I've been looking to overcome. Now I just need to a) learn how to produce useful gcode instead of just the sample files that came with EMC2, and b) learn how to better use EMC2 itself.
Please Log in or Create an account to join the conversation.
- BigJohnT
- Offline
- Administrator
- Posts: 7106
- Thank you received: 1177
John
Please Log in or Create an account to join the conversation.
- munki
- Offline
- New Member
- Posts: 5
- Thank you received: 0
Please Log in or Create an account to join the conversation.
- Configuring LinuxCNC
- Configuration Tools
- StepConf Wizard
- Confused by reversed axis direction vs. homing