mick1221
-
Posts
8 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Gallery
Posts posted by mick1221
-
-
Final Question hopefully, CLoad32() using one of the CounterRegister.Load registers doesn't set the register to anything. If I set CounterMode.EncoderModeModuloNOn it treats The CounterRegister.Load registers like it's the CounterRegister.MaxLimit register and it will roll over on that value. Am I missing anything? There doesn't seem to be anything in the documentation relating to this
-
That still doesn't answer the question of which mode is quadrature, or are they both? If they both are how do I tell the direction ( Clockwise or Counter Clockwise) when using CounterMode.Encoder
-
For the Quad08 Is Quadrature Mode set through CounterMode.Encoder or CounterMode.Totalize?
I have an encoder wheel attached to a rail car for measuring distance and I need to know when it's moving forward or backward.
Everything I have read tells me that CounterMode.Encoder is the method for using Quadrature but I have only been able to get the card to count both up and down when using CounterMode.Totalize specifically
CounterMode mode = CounterMode.Bit32 | CounterMode.Totalize | CounterMode.ModuloNOn | CounterMode.UpDownOn;
When using Counter.Encoder I'm using
CounterMode mode = CounterMode.Encoder | CounterMode.EncoderModeX1 | CounterMode.EncoderModeBit32;
I did read the Edge Detection section in the docs but it seems to describe the methods for the UL and not the UL for .Net, I am using C#.
Any insight is appreciated, Thanks.
-
I'm currently reading from a Quad08 card into a c# program using the Universal library.
Here is how I'm configuring the counter I'm using
CounterMode mode = CounterMode.Bit32 | CounterMode.RangeLimitOn | CounterMode.Rollover; ErrorInfo err = board.CConfigScan(Axis, mode, CounterDebounceTime.DebounceNone, CounterDebounceMode.TriggerBeforeStable, CounterEdgeDetection.RisingEdge, CounterTickSize.Tick20ns, 0);
My understanding is that when setting a max limit it is supposed to roll over to the minimum limit when reached. When I set the max Limit it gets to the max limit and stops. I had Assumed that the minimum limit would default to 0. Unfortunately when it gets to 1000 it stops
err = board.CLoad32(CounterRegister.MaxLimitReg0, 1000);
So I tried setting the minimum limit to 0
err = board.CLoad32(CounterRegister.MinLimitReg0, 0);
However when I do this I receive the error
Bad counter arg passed to cbCLoad.
Is there something I'm missing here to be able to set and roll over at the limits?
-
1 hour ago, mick1221 said:
@JRysThis includes just reading values from it, I take it?
-
40 minutes ago, JRys said:
MCC's Universal Library does not support two programs controlling a single device. You can have two programs running on the same computer, but they must use separate devices. You can also control two or more devices from a single program.
This includes just reading values from it, I take it?
-
I have 2 pieces of software that read from the PCI-QUAD04
Software A is legacy and is being phased out
Software B is has it's own features but will eventually include software A's features
Currently we'd like to be able to run both at the same time.
When I run software A or B on their own everything is fine
When I run them both at the same time Software B will see the encoder count Jump around instead of steadily climb.
do the Drivers provided by MCC only support one piece of software at a time like a serial port?
note: I know the Quad04 isn't made anymore this is a bug we are trying to fix before adding support for the USB-Quad08 which is our replacement
Quad08 Quaderature Mode Question
in Measurement Computing (MCC)
Posted
Here is the test code I'm running, I have not set the max limit Register, only the Load Register...
It Outputs this
Counting up to 4000 then resetting when I set the load Regsiter
When I Remover the CounterMode.EncoderModeModuloNOn The CLoad32() Has no effect on the value read from the encoder
Is setting the counter not allowed when using Countermode.Encoder?