API ReferenceGE Extensionsflowgraphnodestech
Get Ultrasonic Readings (Flowgraph Node)
- **Node Name:** `Get Ultrasonic Readings`
Overview
- Node Name:
Get Ultrasonic Readings - Category:
repeat_instant - File:
extensions/flowgraph/nodes/tech/getUltrasonicReadings.lua
Retrieves ultrasonic sensor readings for a previously created sensor.
Pin Schema
Input Pins
| Pin | Type | Description |
|---|---|---|
sensorId | number | ID of the ultrasonic sensor to read from |
Output Pins
None (data is currently dumped to log).
Behavior
work()- Callsextensions.tech_sensors.getUltrasonicReadings(sensorId)and dumps the result to the console viadump().
How It Works
- First create an ultrasonic sensor using the
setupUltrasonicSensornode to get asensorId. - Connect that ID to this node's
sensorIdinput. - Each frame, the node fetches and logs the sensor readings.
-- The node calls:
local data = extensions.tech_sensors.getUltrasonicReadings(sensorId)
dump(data) -- outputs to consoleNotes
- This node currently only logs readings via
dump()- no output pins expose the data. - Intended for tech/research sensor workflows.
Key Dependencies
extensions.tech_sensors.getUltrasonicReadings()- Retrieves sensor data
Additional Methods
C:init()
Initializes the node, setting up pins and default properties.
See Also
- Create Ultrasonic Sensor (Flowgraph Node) - Related reference
- FlowGraph Guide - Guide