Notice: This page contains information for the legacy Phidget21 Library. Phidget21 does not support VINT Phidgets, and will not support any new Phidgets. Phidget21 will be maintained until 2020. We recommend that new projects be developed against the Phidget22 Library.
1054 User Guide
|Go to this device's product page|
Checking the Contents
You should have received:
In order to test your new Phidget you will also need:
Connecting the Pieces
Testing Using Windows 2000 / XP / Vista / 7
Make sure you have the current version of the Phidget library installed on your PC. If you don't, follow these steps:
- Go to the Quick Downloads section on the Windows page
- Download and run the Phidget21 Installer (32-bit, or 64-bit, depending on your system)
- You should see the icon on the right hand corner of the Task Bar.
Running Phidgets Sample Program
Double clicking on the icon loads the Phidget Control Panel; we will use this program to ensure that your new Phidget works properly.
The source code for the FrequencyCounter-full sample program can be found in the quick downloads section on the C# Language Page. If you'd like to see examples in other languages, you can visit our Languages page.
Updating Device Firmware
If an entry in this list is red, it means the firmware for that device is out of date. Double click on the entry to be given the option of updating the firmware. If you choose not to update the firmware, you can still run the example for that device after refusing.
Double Click on the icon to activate the Phidget Control Panel and make sure that the PhidgetFrequencyCounter is properly attached to your PC.
Testing Using Mac OS X
- Go to the Quick Downloads section on the Mac OS X page
- Download and run the Phidget OS X Installer
- Click on System Preferences >> Phidgets (under Other) to activate the Preference Pane
- Make sure that the PhidgetFrequencyCounter is properly attached.
- Double Click on PhidgetFrequencyCounter in the Phidget Preference Pane to bring up the FrequencyCounter-full Sample program. This program will function in a similar way as the Windows version.
For a step-by-step guide on getting Phidgets running on Linux, check the Linux page.
Using Windows Mobile / CE 5.0 / CE 6.0
For a step-by-step guide on getting Phidgets running on Windows CE, check the Windows CE page.
The PhidgetFrequencyCounter contains two channels to sense two different inputs. Each channel has two different circuits to sense for logic level-frequencies or zero-centered frequencies. The measurable frequency is accurate to 0.25% up to 1MHz. The Frequency Counter may measure frequencies past 1 Mhz, but the input voltage specifications will not hold. The PhidgetFrequencyCounter can measure frequencies down to ~ 0.01Hz. However the response time of these measurements is directly related to the frequency, thus it could take 1 or 2 periods(100-200s) to detect the input frequency.
The logic-level sensing circuit has a hysteresis range from 0.9V to 2.4V. This will allow the circuit to count both 3.3V and 5V logic levels. In addition to logic-level signals, this will also accept the pulses from sensors with open collector outputs. When the input signals are either 3.3V or 5V, the maximum sensed frequency is 1.5Mhz. Most digital sensors that are powered from a signal positive power supply will output a logic-level frequency.
The zero-centered sensing circuit can be used for input signals where you want to count as it crosses zero volts. A hysteresis of 30mVpp filters noise. At maximum frequency (1Mhz), a signal of 400mVPP is required for reliable counting. A common application that uses a zero centered frequency output is a simple magnetic tachometer, which produces a sine wave around 0 volts.
The PhidgetFrequencyCounter uses differential inputs - that is, the voltage being compared is the difference between the (+) and (-) inputs. If your application has a slightly different ground from your USB ground, the common mode rejection in the 1054 will handle small differences in ground. For many applications, the signal being measured is single ended - that is, your sensor outputs only one signal, and you can directly connect the ground of the sensor to the ground of the 1054. In this case, ensure the (-) input is tied to ground. Never allow either input to be left unconnected.
USB Voltage is passed directly to the +5V terminal on the green blocks.
We document API Calls specific to this product in this section. Functions common to all Phidgets and functions not applicable to this device are not covered here. This section is deliberately generic. For calling conventions under a specific language, refer to the associated API manual in the Quick Downloads section for that language. For exact values, refer to the device specifications.
- ZERO_CROSSING = 1,
- Determines the signal type that the PhidgetFrequencyCounter responds to.
double Frequency(int ChannelIndex) [get]
- Gets the last calculated frequency on the specified channel, in Hz. This function will return 0 if The Timeout value elapses without detecting a signal. Frequency is recalculated up to 31.25 times a second, depending on the pulse rate.
int64 TotalCount(int ChannelIndex) [get]
- Gets the total number of pulses detected on the specified channel since the Phidget was opened, or since the last reset.
int64 TotalTime(int ChannelIndex) [get]
- Gets the total elapsed time since Phidget was opened, or since the last reset, in microseconds. This property complements the TotalCount property.
- Gets or set the Timeout value, in microseconds. This value is used to set the time to wait without detecting a signal before reporting 0 Hz. The valid range in 0.1 - 100 seconds (100,000 - 100,000,000 microseconds). 1/Timeout represents the lowest frequency that will be measurable.
int Filter(int ChannelIndex, FilterType filter) [get, set]
- Gets or set the channel filter mode. This controls the type of signal that the frequency counter will respond to - either a zero-centered signal, or a logic level signal.
bool Enabled(int ChannelIndex) [get, set]
- Gets or sets the enabled state on the specified channel. When a channel is disabled, it will no longer register counts. TotalTime and TotalCount properties will not be incremented until the channel is re-enabled.
void reset(int ChannelIndex)
- Resets the TotalCount and TotalTime counters to 0 for the specified channel. For best precision/reliability, this should be called when the channel is disabled.
Count(int ChannelIndex, int time, int counts) [event]
- An event that is issued whenever some counts have been detected. This event will fire at up to 31.25 times a second, depending on the pulse rate. The time is in microseconds and represents the amount of time in which the number of counts occurred. This event can be used to calculate frequency independently of the phidget21 library frequency implementation.
- This event will fire with a count of 0 once, after the Timeout time has elapsed with no counts for a channel, to indicate 0Hz.
|Date||Board Revision||Device Version||Comment|
|May 2011||0||100||Product Release|
|May 2011||0||101||getLabelString fixed for labels longer than 7 characters|