Page 1 of 1

How to ceck a differential input status

Posted: Sun Apr 28, 2019 4:51 pm
by BepsIt
good morning Tom,
I just finished writing the "Ref" C-program for KmotionCnc and it's all full functionally. Currently it's working on the home switches. Because they are mechanical switches, I would want to refer the Axis on the encoders indexes for more precision. All encoders are connected to Kanalog JP1-JP2 differential input, the question is: how can i check the differential input status of index?
In particular i have X index on JP2/36-37, Y index on JP2/38-39 and Z index on JP2/40-41

Beppe

Re: How to ceck a differential input status

Posted: Sun Apr 28, 2019 6:14 pm
by TomKerekes
Hi Beppe,
In particular i have X index on JP2/36-37, Y index on JP2/38-39 and Z index on JP2/40-41
An index pulse is only one differential signal that will correspond to one input. So it doesn't make sense to say you have the X index connected to both inputs Bit 36 and Bit 37.

If you have the Index + and - signals connected to JP2 pins 1 and 2 (marked A4+ and A4-) then this would drive KFLOP Input 36.

See the example SimpleHomeIndexFunction.c and SimpleHomeIndexFunctionTest.c that is written to move to Limit switches and then to an Index Pulse.

Re: How to ceck a differential input status

Posted: Mon Apr 29, 2019 7:08 pm
by BepsIt
Hi Tom
of course i know that "An index pulse is only one differential signal".
I wrote:
i have X index on JP2/36-37, Y index on JP2/38-39 and Z index on JP2/40-41
only because in the Kanalog description you say:
JP2 converts 8 of the signals and connects them to Kflop I/O bits 36-43...
However, by testing the right bit, my C program is also fully functional

Thanks for your patience

Beppe