- Configuring LinuxCNC
- Advanced Configuration
- EtherCAT
- In using ECR60+NPN(GPIO), I encountered an issue.
In using ECR60+NPN(GPIO), I encountered an issue.
26 Nov 2023 20:49 #286579
by rodw
Replied by rodw on topic In using ECR60+NPN(GPIO), I encountered an issue.
When I look at the modified code, that code has been commented out and the following error limits have been set to a massive number.
I'm not sure this makes sense..
I'm not sure this makes sense..
Please Log in or Create an account to join the conversation.
26 Nov 2023 21:31 #286583
by Hakan
Replied by Hakan on topic In using ECR60+NPN(GPIO), I encountered an issue.
The current github cia402 comp code doesn't do like that either, it reports the actual-position as far as I can tell.
Increasing the following error limit makes sense. The drive moves freely and reports its position while homing.
That will cause a following error, it makes sense to temporarily increase those limits while homing.
The cia402.n.stat_homing pin can be used for that it seems like.
Increasing the following error limit makes sense. The drive moves freely and reports its position while homing.
That will cause a following error, it makes sense to temporarily increase those limits while homing.
The cia402.n.stat_homing pin can be used for that it seems like.
Please Log in or Create an account to join the conversation.
26 Nov 2023 23:56 #286593
by rodw
Replied by rodw on topic In using ECR60+NPN(GPIO), I encountered an issue.
Dominics CIA402 component in GIT does not work with the drives that have limit switches connected. He assured me it worked on his hardware but I think it may have homed to index or something.
I will try to write a homecomp one day.
I will try to write a homecomp one day.
Please Log in or Create an account to join the conversation.
27 Nov 2023 00:09 #286594
by Hakan
Replied by Hakan on topic In using ECR60+NPN(GPIO), I encountered an issue.
What is the advantage of using internal homing? I struggle to see why one want to do that with linuxcnc.
Please Log in or Create an account to join the conversation.
27 Nov 2023 01:03 #286596
by rodw
Replied by rodw on topic In using ECR60+NPN(GPIO), I encountered an issue.
well it should be more accurate than Linuxcnc becasue of our coarse 1 ms servo thread. Other than that, it will make a much tidier install.
Imagine a large gantry machine using 220v servos with the drives mounted beside the motors. All you would need to do is route the AC around the table (with appropriate fit for purpose cabling) and add the ethernet cables.
Imagine a large gantry machine using 220v servos with the drives mounted beside the motors. All you would need to do is route the AC around the table (with appropriate fit for purpose cabling) and add the ethernet cables.
Please Log in or Create an account to join the conversation.
27 Nov 2023 02:17 #286598
by MakerYang
Replied by MakerYang on topic In using ECR60+NPN(GPIO), I encountered an issue.
I viewed the relevant data using this method, and it appears to be normal. I didn't record a video, but I took a few photos during the zeroing process.
In fact, the zeroing operation didn't produce any relevant errors, and it met expectations. The only issue is that it cannot reflect the current tool position information in real-time on the visualization interface. The 'actual_position' data retrieved from Python remains unchanged, while only the data for 'joint,' 'joint_actual_position,' and 'joint_position' show variations.
I use the following formula in the visualization interface to display and align the tool's position:
This section of the program can provide relevant information and real-time position feedback during normal jogging control and machining operations. The only time it doesn't show any data changes is during the zeroing process.
In fact, the zeroing operation didn't produce any relevant errors, and it met expectations. The only issue is that it cannot reflect the current tool position information in real-time on the visualization interface. The 'actual_position' data retrieved from Python remains unchanged, while only the data for 'joint,' 'joint_actual_position,' and 'joint_position' show variations.
I use the following formula in the visualization interface to display and align the tool's position:
axis_tmp = copy.copy(self.father.framework.machine.info["axis"])
g_offset_tmp = copy.copy(self.father.framework.machine.info["actual_position"])
g5x_offset_tmp = copy.copy(self.father.framework.machine.info["g5x_offset"])
g92_offset_tmp = copy.copy(self.father.framework.machine.info["g92_offset"])
dtg_offset_tmp = copy.copy(self.father.framework.machine.info["dtg"])
for i in range(0, len(user_data["axes"])):
actual_position = self.father.framework.machine.info["actual_position"]
axis_name = user_data["axes"][i]
axis_num = self.father.framework.machine.get_axis_num(axis_name)
axis = actual_position[axis_num] - g5x_offset_tmp[axis_num] - self.father.framework.machine.info["tool_offset"][axis_num]
axis -= g92_offset_tmp[axis_num]
axis = "{:.3f}".format(axis)
user_data["data"]["position"][i] = axis
This section of the program can provide relevant information and real-time position feedback during normal jogging control and machining operations. The only time it doesn't show any data changes is during the zeroing process.
Attachments:
Please Log in or Create an account to join the conversation.
27 Nov 2023 04:20 #286603
by MakerYang
Replied by MakerYang on topic In using ECR60+NPN(GPIO), I encountered an issue.
I have reconfigured the program as mentioned above. My approach is that if the current axis is in a homing state, I will retrieve relevant data from 'joint_actual_position' for calculations to update the data in the visualization interface as well as the tool position. Otherwise, I will continue to obtain data from 'actual_position'.
While this approach meets my requirements, after restarting LinuxCNC, the values of 'joint_actual_position' may become quite large. However, this zeroing issue can be resolved using the following method.
Because I haven't been using LinuxCNC for long, my knowledge and understanding of LinuxCNC are relatively limited. I'm not sure if the approach I've taken to address this issue is reasonable.
axis_tmp = copy.copy(self.father.framework.machine.info["axis"])
g_offset_tmp = copy.copy(self.father.framework.machine.info["actual_position"])
g5x_offset_tmp = copy.copy(self.father.framework.machine.info["g5x_offset"])
g92_offset_tmp = copy.copy(self.father.framework.machine.info["g92_offset"])
dtg_offset_tmp = copy.copy(self.father.framework.machine.info["dtg"])
for i in range(0, len(user_data["axes"])):
actual_position = self.father.framework.machine.info["actual_position"]
axis_name = user_data["axes"][i]
axis_num = self.father.framework.machine.get_axis_num(axis_name)
axis = actual_position[axis_num] - g5x_offset_tmp[axis_num] - self.father.framework.machine.info["tool_offset"][axis_num]
if self.father.framework.machine.info["joint"][axis_num]["homing"] == 1:
axis = self.father.framework.machine.info["joint_actual_position"][axis_num] - g5x_offset_tmp[axis_num] - self.father.framework.machine.info["tool_offset"][axis_num]
axis -= g92_offset_tmp[axis_num]
axis = "{:.3f}".format(axis)
user_data["data"]["position"][i] = axis
While this approach meets my requirements, after restarting LinuxCNC, the values of 'joint_actual_position' may become quite large. However, this zeroing issue can be resolved using the following method.
def override_limits(self):
self.set_mode(linuxcnc.MODE_MANUAL, 0.5)
self.api.override_limits()
self.api.wait_complete(0.5)
Because I haven't been using LinuxCNC for long, my knowledge and understanding of LinuxCNC are relatively limited. I'm not sure if the approach I've taken to address this issue is reasonable.
Please Log in or Create an account to join the conversation.
28 Nov 2023 06:31 #286662
by MakerYang
Replied by MakerYang on topic In using ECR60+NPN(GPIO), I encountered an issue.
I'm not sure if the approach I've taken to address this issue is reasonable.
Please Log in or Create an account to join the conversation.
28 Nov 2023 10:21 #286680
by MakerYang
Replied by MakerYang on topic In using ECR60+NPN(GPIO), I encountered an issue.
I have updated my approach in this discussion, and I am not quite sure if my method is correct.
I hope to get your help.
I hope to get your help.
Please Log in or Create an account to join the conversation.
28 Nov 2023 11:30 - 28 Nov 2023 11:31 #286696
by rodw
Replied by rodw on topic In using ECR60+NPN(GPIO), I encountered an issue.
I don't really understand why you are using Python or where you are putting it for homing when its a real time process.
Last edit: 28 Nov 2023 11:31 by rodw.
Please Log in or Create an account to join the conversation.
- Configuring LinuxCNC
- Advanced Configuration
- EtherCAT
- In using ECR60+NPN(GPIO), I encountered an issue.
Time to create page: 0.143 seconds