Add
This function block sums multiple numeric values into a single numeric result. It is ideal for aggregating counters, sensor readings, or calculated numbers from other function blocks.
π₯ Inputs
Number One or more numeric inputs. Default setup provides two inputs but the total number of inputs can be changed using the control described below.
(Each input accepts any numeric value produced by other function blocks.)
π€ Outputs
Number The sum of all connected numeric inputs.
πΉοΈ Controls
Input size A dropdown control to select how many numeric input sockets the block provides. Changing this value will add or remove input sockets so you can sum more or fewer values.
π¨ Features
Dynamic input count: easily change how many numeric values you want to sum without adding multiple blocks.
Single numeric output: convenient to feed aggregated values into downstream processing, logging, or display blocks.
Ignores unconnected inputs: only connected numeric inputs are considered when producing the sum.
π Usage Instructions
Use the
Input sizecontrol to set how many numeric inputs you need.Connect the numeric outputs from other function blocks to the provided
Numberinputs.Read the summed result from the block's
Numberoutput and pass it to downstream blocks.
π Evaluation
When run, this block adds together all numeric values currently connected to its inputs and outputs the total as a single numeric value.
π‘ Tips and Tricks
Sum manual values with a
Number Inputblock to create setpoints or offsets before further processing.Combine counts from multiple detectors by feeding their
Object Countoutputs (for example fromObject Detection) into this block to get a total object count.Use with
Counterto accumulate events and withGet Batch Sizewhen processing batches to compute totals per batch.Chain with
Divideto compute averages (sum Γ· count) or withRoundto format numeric results for display/export.Use alongside analysis blocks such as
Mean Value of ImageorMeasure Position Distanceto combine measurement results into a single summary value.
π οΈ Troubleshooting
If the output is lower than expected, check that all intended numeric sources are connected to the block.
If you change the
Input sizeand donβt see the expected number of sockets, re-open the layout or reselect theInput sizeoption to refresh the displayed sockets.Non-numeric or missing inputs are ignored; ensure upstream blocks produce numeric values before connecting.
Last updated
Was this helpful?