dez 2025
This commit is contained in:
16
script/test/test_daqbuf.py
Normal file
16
script/test/test_daqbuf.py
Normal file
@@ -0,0 +1,16 @@
|
||||
from java.util import Date
|
||||
from java.text import SimpleDateFormat
|
||||
|
||||
channel = "ARS07-CECL-DPCT:BIN-PCT-STAT0-BIN"
|
||||
bins = 0
|
||||
time_range = 30
|
||||
|
||||
now = System.currentTimeMillis()
|
||||
fmt = SimpleDateFormat("yyyy-MM-dd HH:mm:ss")
|
||||
start = fmt.format(Date(now_ms - time_range * 1000 ))
|
||||
end = fmt.format(Date(now))
|
||||
|
||||
set_exec_pars(reset=True) # A different file on each time
|
||||
filename = get_exec_pars().path
|
||||
d=Daqbuf(None, "sls-archiver")
|
||||
d.saveQuery(filename, channel, start, end, bins)
|
||||
Reference in New Issue
Block a user