Lathe gui reconfiguration ***NEAR SUCCESS***

More
06 Oct 2019 22:17 #147297 by Scot
So if you've been following my trek to change the Gui from a standard Axis Mill config to a lathe GUI using Pico-systems boards, keep reading. If you contributed to what I've been doing THANK YOU!

So with the help of awesome folks on this forum, I managed to figure out that my issue <I didn't have a standard lathe GUI for Pico Boards> was both a wiring and code issue.

The code issue was solved with a bit of help from phillc54 and OT-CNC. phillc54 was the one to point out that this was a wiring issue rather than just a code issue, not in so many words. But it was just that, a wiring issue more than anything. Switching the motor's encoder signals and PWM direction signals from the Y position to the Z axis position on the Pico System's PWM board was the key. Everything was recognized immediately. The machine comes out of estop, it powers the servo amps and it jogs. The X homes and some simple but slick, new code was added by OT-CNC to home all the axes at the same time, which wasn't standard on the Axis setup for Pico boards.

There is only ONE problem. When I go to home the Z, which was formerly Y, even though I'm nearly 99.9% sure that the wiring is correct, when the Z moves toward the home position, rather than stopping on the switch after it trips and setting it's home point, it gives a joint 2 limit switch error then continues PAST the tripped switch and stops at the end of the screw with that servo just whining away until it faults the amp. Not very 'home-y" if you know what I mean.

Now I don't know the whole system on this setup, but in my limited knowledge, I did some simple tests. One was to restart the system with the limit switch in it's un-tripped position, then move the axis in both directions to see what it would do when it came into contact with the switches. Keep in mind, this setup was the same as it was before, sans the wiring being in a different place on the board and it homed perfectly, albeit without the name of the axis being what I am trying to achieve in the gui. So it if everything was the same in code for those inputs on a different axis and nothing is damaged on the board, then it should function fine when homed.

What I found was that in an pre-homed state, the axis jogged fine then tripped the switch and stopped on both ends of travel. But when sent to the home position, the switch did NOT stop the axis with the HOME_IGNORE_LIMITS=YES.

Then I switched the "HOME_IGNORE_LIMITS = " line in the axis I was working on, in the .ini file to NO and then tried to home it. It stopped at the switch, rather than continuing past it when homed with the HOME_IGNORE_LIMITS = value being YES. And it threw two errors. One was "hit limit in home state 7" and the other was "joint 2 on limit switch" Going the opposite direction to the negative limit, gives a "joint 2 on limit switch" error. This tells me that the switches are functioning and the PWM board and controller are functioning. *probably* The board could be wonky on those terminals but I'm unsure. It doesn't appear to be the case since it tripped and gave an error that it hit the limit in the home state. Normally, if it hits a limit switch when homed, it just gives a joint limit switch error.

If anyone out there who had the gumption to read this wall of text and may have the know-how to see what I don't, let me know. The .hal file for the io's on that board are attached, as well as the wiring schematic for the board. I understand a tiny bit of the code. But I don't have enough info to understand what to change if there is a software or hardware problem for sure.

The sections on P4, P3 and P2 of the schematic are now wired so that the second motor goes to the third set of terminals. That's what allowed for the PWM board to "see" the motor. The limit switches are also wired in the section where it's outlined as the Z, now on 8, 9 and 10 of that terminal block, P4. Those were wired in the Y's positions of 4, 5 and 6 on that terminal block before.

I just need to get the paperweight homed and she will turn parts at breakneck speed after I get the spindle to move properly.

Thanks for taking the time to read this and thanks for all the help! You guys are fantastic!

Scot
Attachments:

Please Log in or Create an account to join the conversation.

More
07 Oct 2019 07:18 #147313 by pl7i92
any images to see your work in progress

Please Log in or Create an account to join the conversation.

More
07 Oct 2019 07:31 #147316 by Scot
I wasn't going to post any unless someone asked. She's not much to look at. But she's a bit like the Millennium Falcon that way. She's fast. There are hours on her chassis that I care not to even imagine. But these old Hardinge spindles are near bulletproof. I'll have her opened up for a bit, but when I put the sheetmetal back on, I'll get some pictures. The lathe has been in storage for a long time. There is surface rust on the bed and the paint is chipped pretty heavily.

But sure. I'll get some photos if folks are interested.

Please Log in or Create an account to join the conversation.

More
07 Oct 2019 07:54 #147317 by Scot
Incidentally, I got the machine to home tonight. It's awesome with brushless servos and the homing accuracy was finally achieved tonight, too.. The slide snaps to position, abeit, it needs the servos tuned a teeny bit. Then the last thing to do is set up the VFD and DAC and it should be able to be assembled and run parts to test the real world accuracy.

Please Log in or Create an account to join the conversation.

More
14 May 2021 23:30 #208873 by eighthaxis
Any chance you could share your solution?

Please Log in or Create an account to join the conversation.

Time to create page: 0.066 seconds
Powered by Kunena Forum