Incorrect Axis Motion
- sanmd
- Offline
- New Member
-
Less
More
- Posts: 6
- Thank you received: 0
18 Jul 2017 23:52 #96027
by sanmd
Replied by sanmd on topic Incorrect Axis Motion
Will do on the Notepad++.
As for the source pins, I have the following lines:
These lines are all below the net lines I listed in the above post but the device kind of works so I assume hal doesn't exactly read top to bottom? A question I have is about the meaning of the numbers after stepgen. I thought those related to the axis or port or something and tried changing the parport lines like this:
to this (changing the '0' to a '1'):
only to get errors. Also, is there anything else that needs to be done for source pins? So far, I think I've figured out there's a problem with the dir pins because the tool only moves towards one direction.
As for the source pins, I have the following lines:
net xstep <= stepgen.0.step
net xdir <= stepgen.0.dir
net ystep <= stepgen.1.step
net ydir <= stepgen.1.dir
net zstep <= stepgen.2.step
net zdir <= stepgen.2.dir
net ystep => parport.0.pin-04-out
setp parport.0.pin-04-out-reset 1
net ystep => parport.1.pin-04-out
setp parport.1.pin-04-out-reset 1
Please Log in or Create an account to join the conversation.
- PCW
-
- Away
- Moderator
-
Less
More
- Posts: 18592
- Thank you received: 5113
19 Jul 2017 00:13 - 19 Jul 2017 00:15 #96028
by PCW
Replied by PCW on topic Incorrect Axis Motion
parport.1.xxxxxx would refer to the second parallel port (parallel ports are numbered 0,1,2,3 etc)
If you dont have two parallel ports or if the second port is not in output mode,
the pin parport.1.pin-04-out-reset would not exist, so you would get a error
The order of net commands does not matter
The numbers after stepgen are enumerations, that is how you separate one stepgen from another,
so if you had 3 stepgens for as 3 axis machine they would normally be numbered 0,1,2
They are commonly assigned
0 = X
1 = Y
2 = Z
but this is arbitrary
If you dont have two parallel ports or if the second port is not in output mode,
the pin parport.1.pin-04-out-reset would not exist, so you would get a error
The order of net commands does not matter
The numbers after stepgen are enumerations, that is how you separate one stepgen from another,
so if you had 3 stepgens for as 3 axis machine they would normally be numbered 0,1,2
They are commonly assigned
0 = X
1 = Y
2 = Z
but this is arbitrary
Last edit: 19 Jul 2017 00:15 by PCW.
Please Log in or Create an account to join the conversation.
- sanmd
- Offline
- New Member
-
Less
More
- Posts: 6
- Thank you received: 0
04 Aug 2017 08:23 #96995
by sanmd
Replied by sanmd on topic Incorrect Axis Motion
Turns out the code was OK. There was a misplaced jumper on the board that was causing problems. With that reset, the axes actually move normally again. Thank you all for the help!
On a separate note, does LinuxCNC automatically deal with homing and limit switches in their own unique way? I'm having an issue where the home switches act like limit switches though they are clearly coded as home switches. I get an error along the lines ofwhich I think is resulting from homing not happening before a limit switch is thrown so that'll probably be sorted when homing is.
Is it possible to hard-code an origin for the machine and have it return there every time it finishes up so that it doesn't have to home?
Thank you!
On a separate note, does LinuxCNC automatically deal with homing and limit switches in their own unique way? I'm having an issue where the home switches act like limit switches though they are clearly coded as home switches. I get an error along the lines of
joint 0 ..... <something, something>
Is it possible to hard-code an origin for the machine and have it return there every time it finishes up so that it doesn't have to home?
Thank you!
Please Log in or Create an account to join the conversation.
- andypugh
-
- Offline
- Moderator
-
Less
More
- Posts: 23323
- Thank you received: 4948
04 Aug 2017 09:28 #96996
by andypugh
Yes. In HAL there is a separate input for home and for max and min limit.
A common setup is(I might well not have the pin names 100% correct there)
Each of the three inputs does a different thing, but they can all be connected to the same physical input pin.
If the home switches and limit switches are the same input, then you need to setin the INI file to tell LinuxCNC to ignore the limit switches when homing.
Replied by andypugh on topic Incorrect Axis Motion
On a separate note, does LinuxCNC automatically deal with homing and limit switches in their own unique way?
Yes. In HAL there is a separate input for home and for max and min limit.
A common setup is
net both-x parport.0.pin-01-in => joint.0.pos-lim-sw-in joint.0.neg-lim-sw-in joint.0.home-sw-in
Each of the three inputs does a different thing, but they can all be connected to the same physical input pin.
If the home switches and limit switches are the same input, then you need to set
HOME_IGNORE_LIMITS
Please Log in or Create an account to join the conversation.
Time to create page: 0.070 seconds