Mach3 -> Camtronics -> Parallel P Replacement

More
5 years 6 months ago #204900 by robertspark
I did wonder if there was a hal component, and did also wonder if it could be used with Mesa hardware as I presumed that the encoder to spindle synchronisation happened within the Mesa hardware so you would then need a hardware solution prior to Mesa device ((I haven't read the whole thread so was not sure if this was a pp / Mesa hardware discussion)
The following user(s) said Thank You: rdeeming

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

More
5 years 6 months ago - 5 years 6 months ago #204903 by rdeeming
Yes I changed out the encoder to one that has Z. Thanks to tommylight for shedding the light on that issue I had.

I will work on making the changes to the HAL that you shared.

This might explain the luck of the draw at times and the shredding of threads I assume lol.
Last edit: 5 years 6 months ago by rdeeming.

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

More
5 years 6 months ago #205177 by andypugh
Note that it is possible to source an index elsewhere, for example a proximity sensor looking at a keyway on the spindle shaft, or an optical slot sensor looking at a hole in the toothed belt pulley flange.

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

More
5 years 6 months ago #205205 by rdeeming
For $13 I have another 40 tooth wheel coming. But I want to learn while I wait on amazon.

I am new to all this so this is probably more of a big deal to me than most.

I verified my encoder index is working and in fact is triggering twice. Basically extracted from this to come up with commands that were relevant to my config.

halcmd show pin hm2_7i76e.0.encoder.00.index-enable
Component Pins:
Owner Type Dir Value Name
26 bit I/O FALSE hm2_7i76e.0.encoder.00.index-enable <=> spindle-index-enable

halcmd unlinkp hm2_7i76e.0.encoder.00.index-enable
halcmd setp hm2_7i76e.0.encoder.00.index-enable 1

halcmd show pin hm2_7i76e.0.encoder.00.index-enable
Component Pins:
Owner Type Dir Value Name
26 bit I/O TRUE hm2_7i76e.0.encoder.00.index-enable

Hand spin the spindle half a turn and the value goes back to FALSE.


Off to translate what Andy has given about flipflop and not...

I inserted a few lines in hal to get the party started.

loadrt flipflop
loadrt not
addf flipflop.0 servo-thread

halcmd show pin flipflop not
Component Pins:
Owner Type Dir Value Name
41 bit IN FALSE flipflop.0.clk
41 bit IN FALSE flipflop.0.data
41 bit I/O FALSE flipflop.0.out
41 bit IN FALSE flipflop.0.reset
41 bit IN FALSE flipflop.0.set
41 s32 OUT 64 flipflop.0.time
44 bit IN FALSE not.0.in
44 bit OUT FALSE not.0.out
44 s32 OUT 0 not.0.time

This is where I am at and have run out of general lack of knowledge connecting the dots to get the latch working with my config.

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

More
5 years 6 months ago #205212 by andypugh
For some reason I thought that you were using a parallel port.

It isn't actually possible to interfere with the index pulse with a Mesa card config.

(Well, it is just about possible, by taking the signal in to HAL and then out again back to the mesa board)

Sorry for leading you astray.
The following user(s) said Thank You: rdeeming

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

More
5 years 6 months ago #205213 by rdeeming
No biggie. I got a few days waiting for a same size gear and there is just enough room and belt to shove it in there.

It just forced me to learn a little more ;-)

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

Time to create page: 0.276 seconds
Powered by Kunena Forum