mirror of https://github.com/arendst/Tasmota.git
19 lines
412 B
Plaintext
19 lines
412 B
Plaintext
# register the command 'DisplayCalibrate'
|
|
#
|
|
# load the module in memory only when the command is first used
|
|
#
|
|
var wd = tasmota.wd # capture value of the first run
|
|
tasmota.add_cmd("DisplayCalibrate",
|
|
def ()
|
|
import sys
|
|
var path = sys.path()
|
|
|
|
path.push(wd)
|
|
import ts_calibrate
|
|
path.pop()
|
|
|
|
tasmota.set_timer(0, /-> ts_calibrate.start())
|
|
tasmota.resp_cmnd_done()
|
|
end
|
|
)
|