CAD CAM EDM DRO - Yahoo Group Archive

Index and Encoders

on 1999-08-02 17:07:23 UTC
Hi,


First to Linux installs:

Someone said something wrong about the setup of the X- window
system. They said to run the FX86Setup. The correct name is
XF86Setup.

To anyone new to Linux: one way to test the spelling, do the
following: You ar looking for a command with X- something. Just
write the letter X, then hit the tab key a couple of times. It will
list all commands/programs starting with an X, - if you don't find
it, this way, it is maybe not on your system. All commands can be
use the tab key. If you start the command, it will automatically
expand the line. Example: You want to move into the emc directory.
If you do, cd /u and hit tab, it will fill inn "sr" - that is, you
got cd /usr. Add / and hit tab, it doesn't find anything that
match. Hit tab again and it will show all possible choices. I now
it is under local - so I add an "l" and hit tab.
First time it will not find any match, second hit on tab, will list
the possible directories beginning with an l.

I know it is local, so I started with /loc. There is only one
possible match and it will expand this on the first hit. Works in
several programs too, like emacs. This way you would very find the
spelling error very much faster. Try it out !

-------------------------
Jon Elson: index and encoder chips.
-------------------------

Yes, you are right. I didn't describe what I meant good enough. I
can't recall it at the moment, but someplace I came across a chip
that could do several things. It had some internal registers, that
was possible to get to work like this: an index pulse, would copy
the count registers to another "index" register bank. Not the read
out latch you use for reading the counter. This capture functions,
could be used so that it would capture the current count register
value, and have it saved until the next index would overwrite it.
On the stg board, you have to make a function like this in software,
but that is giving some problems. By the time your software would
read the counter, it would have changed. The way you said, - it
could be set up to latch the counter register - poses another
difficulty. If different processes should read this, - the motion
controller *will* read it, and this would ruin any other separate
process that should just monitor the surface probing,. What I meant,
- if there was a hardware capture, then if this was not needed by
the EMC, you could have written another module to sample the
probing.

The way you have to do this on a stg board, would be make *switch*
statement, so it would route the probing value to another module and
not the motion controller module. ( there is maybe many ways to do
this, I am just trying to explain what I meant in my original
statement.

There is something else, - the RT "kernel" and the Linux "kernel".
I think the RT part, is just polling the io, - and not using
hardware interrupts. And I don't know how to handle hardware
interrupts, as these has to start up a Interrupt service routine,
and signal the processes that should use this info. This could be
done with semaphores, IPC, fifos, shared memory or --- I just don't
know. I would use semaphores, and insert this set into the task
dispatcher, - but at the moment I don't know how to do this in Linux
and RTLinux. The problem is that without a hardware capture
function, you had to respond to the interrupt, - and this would have
to have I very high priority inside the dispatcher, in order to get
read the value fast enough.

I just write this without any much thought, - because I just wanted
to hear if someone else has thought of how to implement these
things. ( maybe I should address this to another forum, - but I
don't know who )

Hey - come on, - any ideas ?

Come to think of something, - if you don't use all the axis, maybe
preload a spare chip with the contents of one other position
counter, - and have them wired in parallel. Do as You said, let the
index pulse latch the output register on this spare counter, and
have another kernel module read this spare counter instead. This way
it would not interfere with the EMC module.

//ARNE




//ARNE

Discussion Thread

Arne Chr. Jorgensen 1999-08-02 17:07:23 UTC Index and Encoders Jon Elson 1999-08-02 23:16:38 UTC Re: Index and Encoders