A newer version of Max is available. Click here to access the latest version of the documentation

past Reference

Notify when a threshold is passed

past

Description

Sends a bang when a number rises above a certain specified value.

Examples

Send out bang only when the input goes past the threshold in an upward direction

Arguments

list [list]

Sets the numbers which must be exceeded by the numbers received in the inlet. Output will be triggered when any of the threshold values are met or exceeded.

number [int]

Triggers output when the number is met or exceeded.

Attributes

Common Box Attributes

Messages

int

Arguments

input [int]
If there is only one argument, and the input is greater than the argument, and the previous input was not greater than or equal to it, past sends a bang out the outlet.

float

Arguments

input [float]
If there is only one argument, and the input is greater than the argument, and the previous input was not greater than or equal to it, past sends a bang out the outlet.

list

Arguments

input [list]
The numbers in the list are compared to the arguments. If all of the numbers in the list are greater than or equal to the corresponding arguments, a bang is sent out the outlet. Before a bang is sent again, however, past must receive a clear message, or must receive another list in which the number that equaled or exceeded its argument goes back below (is less than) its argument.

clear

Causes past to forget previously received input, readying it to send a bang message again.

set

Arguments

watch-list [list]
The word set, followed by one or more numbers, sets the numbers which must be equaled or exceeded by the numbers received in the past object's inlet.

Output

bang

If all of the arguments are equaled or exceeded by the numbers received in the inlet, past sends out a bang. Otherwise, past does nothing. If there is a single argument, a bang is sent only as a number increases past its threshold. Once the threshold has been passed, the number must go below the threshold again, then increase past it, before another bang will be sent.

See Also

Name Description
maximum
peak
>