train~ Reference

Pulse train generator

train~

Examples

Arguments

width [auto]

Optional

Controls the pulse width or duty cycle. A value of 0 has the smallest "on" pulse size, while a value of 1 has the largest. A value of 0.5 makes a pulse with half the time at 1 and half the time at 0.

pulsephase [auto]

Optional

Sets the phase of the onset of the "on" portion of the pulse. A value of 0 places the "on" portion at the beginning of the interval, while other values (up to 1, which is the same as 0) delay the "on" portion by a fraction of the total inter-pulse interval.

Inlets

interval [auto]

Specifies the period (time interval between pulse cycles), in milliseconds, of the pulse train signal sent out the left outlet.

width [auto]

Controls the pulse width or duty cycle. A value of 0 has the smallest "on" pulse size, while a value of 1 has the largest. A value of 0.5 makes a pulse with half the time at 1 and half the time at 0.

pulsephase [auto]

Sets the phase of the onset of the "on" portion of the pulse. A value of 0 places the "on" portion at the beginning of the interval, while other values (up to 1, which is the same as 0) delay the "on" portion by a fraction of the total inter-pulse interval.

Outlets

out1 [signal]

A pulse (square) wave train having the specified interval, width, and phase.

Dynamic Attributes

These attributes can be modified in the code during execution using the set object

interval [auto]

Specifies the period (time interval between pulse cycles), in milliseconds, of the pulse train signal sent out the left outlet.

pulsephase [auto]

Sets the phase of the onset of the "on" portion of the pulse. A value of 0 places the "on" portion at the beginning of the interval, while other values (up to 1, which is the same as 0) delay the "on" portion by a fraction of the total inter-pulse interval.

reset [bang] (default: 0)

Banging this attribute will reset the object to its default state.

width [auto]

Controls the pulse width or duty cycle. A value of 0 has the smallest "on" pulse size, while a value of 1 has the largest. A value of 0.5 makes a pulse with half the time at 1 and half the time at 0.

See Also

Name Description
train~ Pulse train generator
<~ Is less than, comparison of two signals
>~ Is greater than, comparison of two signals
clip~ Clip an input to a range within an upper and lower bound.
sah~ Sample and hold operator (Schmitt trigger)
phasor~ Generate sawtooth signals