# timing::OneShot

    sys::Obj
      sys::Virtual
        sys::Component
          timing::OneShot

`public class OneShot` `[niagaraIcon="module://icons/x16/control/control.png"]`

OneShot: Boolean one-shot pulse generator

       out = true for pulseWidth sec, beginning at rising edge of in
       pulse retriggers on each rising edge of in, if canRetrig = true

canRetrig

  `public property bool canRetrig [config]`

  If true, subsequent edges on input will restart pulse width measurement

         (resulting in wider overall output pulse)

in

  `public property bool in`

  Input signal

out

  `public property bool out [readonly]`

  Output signal

pulseWidth

  `public property float pulseWidth [min=0, config, unit="second"]`

  Width of desired output pulse, in seconds

clear

  `public action void clear()`

  Clears the output immediately, cancelling any pulse in progress

execute

  `public virtual override void execute()`

  Execute is called once every scan.

start

  `public virtual override void start()`

  Callback when component is first started in an app.