Fumbling through new hardware/software

Moderators: TomKerekes, dynomotion

Post Reply
Garage14
Posts: 3
Joined: Thu Jan 02, 2020 10:57 pm

Fumbling through new hardware/software

Post by Garage14 » Fri Jan 03, 2020 12:29 am

Hello Tom! It seems that you field all of the support for the Dynomotion product line. I guess this is the best forum section to start this particular string of questions and to start off my project utilizing your board. I came upon the kflop because I recently bought a techno Isel router table at auction which was missing the PCI "brain" board, and needed a motion control solution that could handle analog dc brushed motors. I have scratch built a 3d printer and another router table that worked under 2 different motion controllers but this is my first foray into servo motors and C+ based firmware. I have broken down the SCSI cable that acts as the wired connection between the box which houses the power supply and servo amps and the original PCI "controller" card, and connected it to what I think are the appropriate screw terminals on the kanalog board. I have tested the servo amps directly with 1.5V battery as analog input and gotten a motor to turn. Now I am at the point where I want to get a motor to turn via a jog button in the control software and I am playing with the Kmotion interface. I loaded Kmotion and configured the 0 axis and hit the save, compile, download, run button. My first couple questions arise from the following, I figured out that the opto in at J15 needs power so I took 5V+ from the kanalog and hooked it to 0+ and made the limit switch for the axis I am testing (the limits on this machine are 2 micro switches wired in series for home and limit per axis) brake ground on the 0- terminal. When I go to the digital I/O tab in Kmotion all of the home and limit state boxes randomly cycle on and off but the kanalog opto in bit 136 functions as I expect (depress a limit microswitch and state check mark goes away, release switch it comes back) I don't know if that is normal or not for state boxes on the kflop page to cycle. The cycling of state on the home and limit boxes freaks me out. I have crashed my other machines more than once because of limit switch issues. My other question is based on the encoder and dac side. When I first connected via laptop to the kanalog and started poking around Kmotion, I got a voltage reading on the DACs side of analog I/O when I manually turned the encoder but after loading a config onto the board and dorking with wiring to the limit switches now I don't see a change there. I do get a change in position on the axis page though. Am I ready to try a jog button for this axis in KmotionCNC or do I have a problem with the home and limit and or encoder? Thank you in advance for any help. Sincerely, Dave.
Attachments
20200102_161209.jpg
20200102_161157.jpg

User avatar
TomKerekes
Posts: 988
Joined: Mon Dec 04, 2017 1:49 am

Re: Fumbling through new hardware/software

Post by TomKerekes » Fri Jan 03, 2020 7:05 pm

Hi Garage14,
When I go to the digital I/O tab in Kmotion all of the home and limit state boxes randomly cycle on and off but the kanalog opto in bit 136 functions as I expect (depress a limit microswitch and state check mark goes away, release switch it comes back) I don't know if that is normal or not for state boxes on the kflop page to cycle. The cycling of state on the home and limit boxes freaks me out.
That all sounds normal. The home and limits marked are just possibilities for systems without Kanalog. Limits are configured in software and any IO bit can be used. See here. With Kanalog those bits are used to communicate with Kanalog and so will toggle at high speeds. Ignore this.


My other question is based on the encoder and dac side. When I first connected via laptop to the kanalog and started poking around Kmotion, I got a voltage reading on the DACs side of analog I/O when I manually turned the encoder but after loading a config onto the board and dorking with wiring to the limit switches now I don't see a change there. I do get a change in position on the axis page though. Am I ready to try a jog button for this axis in KmotionCNC or do I have a problem with the home and limit and or encoder? T
If the axis is configured properly and enabled, then turning the encoder should create an position error and some DAC output should be present.

Please get the axis configured, tested, and tuned using the KMotion.exe before attempting to run KMotion.exe or jogging.

Please folow the steps described here and let us know of the results.
Regards,

Tom Kerekes
Dynomotion, Inc.

Garage14
Posts: 3
Joined: Thu Jan 02, 2020 10:57 pm

Re: Fumbling through new hardware/software

Post by Garage14 » Mon Jan 06, 2020 10:54 pm

Ok so I followed the initial setup in the analog amp test section that you linked and loaded a fresh default config for the 0 axis. The test steps 1,2 and 3 all worked. I went back and reconfigured the axis the way I think it's supposed to be based on the example from the manual and I have partially discovered why I wasn't getting the DAC reading on the analog I/O tab. With the limit switch settings set to watch limit and bit 136 for both negative and positive and kill motor drive as action, I get Neg Limit Disabled Axis:0 in the console window and I can't enable the drive on the axis tab. I've got +5V wired straight to the positive terminal and the negative terminal straight to ground for 0 at jp15 so there is no chance it's a bad switch. The state box in the kanalog tab of digital I/O changes back and forth if I open or close that opto relay but something about my configuration settings is not right. Is the negative and positive on the configuration page referring to machine direction and thus 2 different physical switches or the negative and positive electrical polarity printed on the board for the opto switch? How does the software decide the negative limit should be disabled for 136 if the circuit is complete and that opto has power? Thanks again -Dave

User avatar
TomKerekes
Posts: 988
Joined: Mon Dec 04, 2017 1:49 am

Re: Fumbling through new hardware/software

Post by TomKerekes » Tue Jan 07, 2020 1:46 am

Hi Garage14,
With the limit switch settings set to watch limit and bit 136 for both negative and positive and kill motor drive as action, I get Neg Limit Disabled Axis:0 in the console window and I can't enable the drive on the axis tab.
Yes as described in the manual.

Kill Motor Drive - will completely disable the axis whenever the limit condition is present. Note that it will not be possible to re-enable the axis (and move out of the limit) while the limit condition is still present and this mode remains to be selected.

The state box in the kanalog tab of digital I/O changes back and forth if I open or close that opto relay but something about my configuration settings is not right. Is the negative and positive on the configuration page referring to machine direction and thus 2 different physical switches
Yes, the configuration allows you to specify 2 different inputs for the two different limits of travel. If you use two separate inputs then it is possible for KFLOP to know which limit is made, where the axis is, and which direction should be allowed.

The software can be configured to trigger when then the Limit input goes active or inactive with the "Stop when low" option.

or the negative and positive electrical polarity printed on the board for the opto switch?
It isn't clear what you mean. The + and - on the opto inputs is the electrical polarity that must be applied to the opto input for it to activate. It has nothing to do with Limits or directions of motion.

How does the software decide the negative limit should be disabled for 136 if the circuit is complete and that opto has power?
Do you want the axis to stop when the opto has power or when it doesn't have power? If both limits are active no motion will be allowed in either direction.
Regards,

Tom Kerekes
Dynomotion, Inc.

Garage14
Posts: 3
Joined: Thu Jan 02, 2020 10:57 pm

Re: Fumbling through new hardware/software

Post by Garage14 » Tue Jan 07, 2020 6:37 pm

Ok I think I have it now. I didn't understand the nomenclature because my previous boards just asked for NO or NC for each limit. The stop when low caught me up since it wasn't checked in the example and I didn't know what it meant. I see now that I need it checked to set an NC limit circuit to trigger when becoming open (low). I've not had to deal with anything in terms of "logic" terminology just basic hard wiring. I also changed the kill drive option to stop movement because I need to be able to hit limits to home the machine and I think that it would result in a fault and no further movement after hitting the first limit with the kill drive option checked.

User avatar
TomKerekes
Posts: 988
Joined: Mon Dec 04, 2017 1:49 am

Re: Fumbling through new hardware/software

Post by TomKerekes » Wed Jan 08, 2020 1:10 am

Hi Garage14,
Ok I think I have it now. I didn't understand the nomenclature because my previous boards just asked for NO or NC for each limit. The stop when low caught me up since it wasn't checked in the example and I didn't know what it meant. I see now that I need it checked to set an NC limit circuit to trigger when becoming open (low). I've not had to deal with anything in terms of "logic" terminology just basic hard wiring.
ok great.

I also changed the kill drive option to stop movement because I need to be able to hit limits to home the machine and I think that it would result in a fault and no further movement after hitting the first limit with the kill drive option checked.
That's fine but we typically use a Homing routine that disables the limits, jogs to the limit, stops, backs out of the limit, zeros, re-enables the limit. You might see the SimpleHomeIndexFunctionTest.c example which uses the function defined in SimpleHomeIndexFunction.c.
Regards,

Tom Kerekes
Dynomotion, Inc.

Post Reply