On Tue, 30 Dec 2014, John Alexander Stewart wrote:

> Date: Tue, 30 Dec 2014 21:45:14 -0500
> From: John Alexander Stewart <[email protected]>
> Reply-To: "Enhanced Machine Controller (EMC)"
>     <[email protected]>
> To: "Enhanced Machine Controller (EMC)" <[email protected]>
> Subject: [Emc-users] Possibly dumb question - 7i76 encoder for spindle speed
>     feedback
> 
> Hi all;
>
> I'm back working on my mill with spindle tachometer, to utilize Andy Pugh's
> automatic spindle speed selector example code.
>
> I have, from the spindle sensor, input going to a 6N138 optoisolator's
> input. Ground and voltage source tied to machine. It sources enough current
> to drive the input quite well. (originally sent to the input of an Amtel
> processor in the LED spindle speed display)
>
> Output of 6N138, with +5v, ground, to the 7i76 ENCA+ and surrounding
> connectors on the 7i76.
>
> Looking with Halscope gives me a pretty good signal on
> hm2_5i25.0.encoder.00.input-a. Running at 1,000 rpm gives me 14 "square"
> teeth, running at 500 rpm gives me 7, and running at 300rpm gives me 4.
> (not that the counts mean much, except that the reading tracks spindle
> speed linearly)
>
> The 7i76 jumper is set for TTL input. ONLY the ENCA+ input pin has anything
> connected, the IDX, ENCB+/- and ENCA- are all left floating.
>
> The issue I have is that the velocity never seems to do much other than
> just futz around between 6 and 40, no matter what the spindle speed.
>
> Here's my ini code:
>
>    setp hm2_5i25.0.encoder.00.counter-mode  1
>    setp hm2_5i25.0.encoder.00.filter 1
>    setp hm2_5i25.0.encoder.00.index-invert 0
>    setp hm2_5i25.0.encoder.00.index-mask 0
>    setp hm2_5i25.0.encoder.00.index-mask-invert 0
>    setp hm2_5i25.0.encoder.00.latch-enable 0
>    setp hm2_5i25.0.encoder.00.scale -16
>    setp hm2_5i25.0.encoder.00.vel-timeout 1.0
>
> Should I tie the other encoder lines high/low or to somewhere? (especially
> the index pulse)
>
> Anybody with some advice?
>
> Thank you - John A. Stewart.

If the inputs are jumpered for TTL levels you must leave the -inputs 
unconnected. The + inputs have 2K pullups to 5V so will be in a high state if 
left open. I forget the 7I76 encoder polarity but you may need to ground the
ENCB+ input to get the count direction correct (ENCB is the direction input in
count = COUNT/DIR mode )




> ------------------------------------------------------------------------------
> Dive into the World of Parallel Programming! The Go Parallel Website,
> sponsored by Intel and developed in partnership with Slashdot Media, is your
> hub for all things parallel software development, from weekly thought
> leadership blogs to news, videos, case studies, tutorials and more. Take a
> look and join the conversation now. http://goparallel.sourceforge.net
> _______________________________________________
> Emc-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/emc-users
>

Peter Wallace
Mesa Electronics

(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.


------------------------------------------------------------------------------
Dive into the World of Parallel Programming! The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net
_______________________________________________
Emc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to