You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Devices in pslab.external, such as sensors, motors, and displays, should include some kind of meta data so that front ends like pslab-desktop and pslab-cli can use them without large amounts of custom code.
One possible solution is a JSON file for every supported device, with a structure like this:
Devices in
pslab.external
, such as sensors, motors, and displays, should include some kind of meta data so that front ends like pslab-desktop and pslab-cli can use them without large amounts of custom code.One possible solution is a JSON file for every supported device, with a structure like this:
This file specifies that the MLX90614 class has:
set
method which accepts "source" followed by either"object"
or"ambient"
as its argument.get
method which accepts "temperature" and returns a float between -127 degC and 128 degC.A more complex example:
This file specifies that the BMP180 class has:
BMP180.mode
property, the default being "thermometer".By reading these files, the front end does not need to know any details about the sensors and requires no custom code. @orangecms what do you think?
The text was updated successfully, but these errors were encountered: