vernier photogate events lab

3
Vernier Photogate Count Events Lab This lab introduces the student to the Vernier Photogate Sensor and teaches concepts in counters. The student must learn how to connect to the ELVIS II prototyping board to make the necessary signal connections for the sensor. Theory: Vernier offers a sensor that measures the movement of objects passing through or outside of the gate arms. In the internal gate mode, an infrared beam is detected by a fast IR detector. Any object passing through the gate interrupts the signal. How to build the experiment: The Photogate Sensor is attached to the Digital Proto Board Connector (BTD-ELV), which is connected to the NI-ELVIS II prototyping board. Figure 1 and the following steps show how to wire the connector. Figure 1: Prototyping Board for the Vernier Photogate Sensor Events Lab

Upload: others

Post on 22-Mar-2022

3 views

Category:

Documents


0 download

TRANSCRIPT

Vernier Photogate Count Events Lab

This lab introduces the student to the Vernier Photogate Sensor and teaches concepts in

counters. The student must learn how to connect to the ELVIS II prototyping board to

make the necessary signal connections for the sensor.

Theory:

Vernier offers a sensor that measures the movement of objects passing through or outside

of the gate arms. In the internal gate mode, an infrared beam is detected by a fast IR

detector. Any object passing through the gate interrupts the signal.

How to build the experiment:

The Photogate Sensor is attached to the Digital Proto Board Connector (BTD-ELV),

which is connected to the NI-ELVIS II prototyping board.

Figure 1 and the following steps show how to wire the connector.

Figure 1: Prototyping Board for the Vernier Photogate Sensor Events Lab

Wire the following pins:

1) CTR0 - Source pin from the Elvis Counters to DIO0 pin of the Digital Proto

Board Connector

2) ELVIS DC Power Supply +5V to 5 V pin of the Digital Proto Board Connector

3) ELVIS DC Power Supply Ground to GND pin of the Digital Proto Board

Connector

How the Photogate Count Events VI runs:

1) DAQmx VIs: A counter input edge-counting task is created to read the signal

from counter 0 on the NI ELVIS II.

2) Displaying the Data: Each time a rising edge, selected on the front panel, is

detected, the count increments and displays in the Data indicator.

3) Stopping the Loop: The loop will run until one of the stop conditions is met. If an

error occurs, the loop will terminate. Otherwise, the loop continues to run until

the stop button is pressed.

Figure 2 below shows the LabVIEW code.

Figure 2: Photogate Count Events VI Block Diagram

Running the Photogate Count Events VI:

Before running the Photogate Count Events VI, verify that the counter selected is ctr0 on

your ELVIS II device. The default pin for the source of Counter 0 is PFI8, selected from

the CI.CountEdges.Term control. Check that the shutter on the Photogate Sensor arm is

open. You will be using the internal gate mode, so the red LED on the sensor should not

be lit.

Press the Run button and pass an object through the Photogate Sensor arms. Each time

you do, the number displayed in Data should increase by one.

Figure 3: Photogate Count Events VI Front Panel

Summary:

With the Vernier sensors, you can take advantage of NI ELVIS II to acquire data by

plugging in with a simple Proto Board Connector. Use the Photogate Sensor and

LabVIEW to count the number of times an object passes through the sensor arms.