Measuring the Duration of a Digital Pulse from LEMO on V2495 and Reading It with a Register

How can I measure the duration of a digital input pulse from one of the LEMO connectors on the V2495 and read the result with a register?

To measure the duration of a digital input pulse from one of the LEMO connectors on the V2495, and then read the result using a register, you can follow these steps:

  1. Input Configuration:

    • First, configure the LEMO input as a digital pulse input. You can use G-PORT or one of the plugin board.
  2. Pulse Timing:

    • To measure the duration, you can use a counter or chronomer block inside your design. The timer will start when the pulse is detected (rising edge) and stop when the pulse ends (falling edge) .
    • You should connect the pin ENABLE to the lemo in
  3. Register Setup:

    • Once the duration is measured, store the result in a register. In SciCompiler, you can map this register to an address that can be read later.
    • The register will hold the value of the pulse duration in clock cycles, which can be converted to time based on the clock frequency of the board.
    • You can use an falling-edge detector to driver write of the register in order to hold the last value