Thermomether sensor to detect nearby objects.
This sensor emulates a Thermometer, measuring the temperature with respect to the distance to heat sources. It defines a default temperature throughout the scenario, which is affected by local fire sources. The temperature rises exponentially when the distance between the sensor and the heat source decreases.
The default temperature is specified as a parameter Temperature of the Scene_Script_Holder Empty object in the simulation file. It is expressed in degrees Celsius.
No configurable parameter.
This sensor exports these datafields at each simulation step:
temperature in Celsius
Interface support:
Returns the current data stored in the sensor.
Return value
a dictionary of the current sensor’s data
The following example shows how to use this component in a Builder script:
from morse.builder import *
robot = ATRV()
# creates a new instance of the sensor
thermometer = Thermometer()
# place your component at the correct location
thermometer.translate(<x>, <y>, <z>)
thermometer.rotate(<rx>, <ry>, <rz>)
robot.append(thermometer)
# define one or several communication interface, like 'socket'
thermometer.add_interface(<interface>)
env = Environment('empty')
(This page has been auto-generated from MORSE module morse.sensors.thermometer.)