wip gg
This commit is contained in:
parent
d9b09debb2
commit
a490db9138
@ -23,7 +23,7 @@ archive_endpoint: https://r5portal.it/api/echo/
|
|||||||
images_path: data/images
|
images_path: data/images
|
||||||
poll_time: 60
|
poll_time: 60
|
||||||
hold_time: 1
|
hold_time: 1
|
||||||
service_account_json: data/secrets/MACHINE-bucket-sevice-account_errecinque-prodserver-HEXHEXHEXHEX.json
|
service_account_json: data/secrets/errecinque-prodserver-9d4024fe9eed.json
|
||||||
bucket_id: MACHINE
|
bucket_id: MACHINE
|
||||||
|
|
||||||
[label_printer]
|
[label_printer]
|
||||||
|
|||||||
@ -1,4 +1,5 @@
|
|||||||
import sys
|
import sys
|
||||||
|
import traceback
|
||||||
|
|
||||||
if "--sim-serial" in sys.argv:
|
if "--sim-serial" in sys.argv:
|
||||||
from components.dummies.serial import serial
|
from components.dummies.serial import serial
|
||||||
@ -57,8 +58,9 @@ class ModbusComponent(Component):
|
|||||||
read = self.client.read_holding_registers(register, count=count)
|
read = self.client.read_holding_registers(register, count=count)
|
||||||
self.lock.unlock()
|
self.lock.unlock()
|
||||||
if read.isError():
|
if read.isError():
|
||||||
# self.log.exception(traceback.format_exception(type(read), read, read.__traceback__))
|
self.log.exception(traceback.format_exception(type(read), read, read.__traceback__))
|
||||||
raise read
|
# raise read
|
||||||
|
return None
|
||||||
return read
|
return read
|
||||||
|
|
||||||
def _write(self, register, value):
|
def _write(self, register, value):
|
||||||
|
|||||||
@ -77,7 +77,7 @@ try:
|
|||||||
self.config = ConfigReader()
|
self.config = ConfigReader()
|
||||||
# INIT COMPONENT
|
# INIT COMPONENT
|
||||||
self.components_specs = {
|
self.components_specs = {
|
||||||
"archive_synchronizer": {"c": ArchiveSynchronizer},
|
# "archive_synchronizer": {"c": ArchiveSynchronizer},
|
||||||
"galaxy_camera": {"c": GalaxyCamera, "k": {"paused": True}},
|
"galaxy_camera": {"c": GalaxyCamera, "k": {"paused": True}},
|
||||||
"label_printer": {"c": Os_Label_Printer, "t": False},
|
"label_printer": {"c": Os_Label_Printer, "t": False},
|
||||||
"neo_pixels": {"c": NeoPixels, "t": False},
|
"neo_pixels": {"c": NeoPixels, "t": False},
|
||||||
|
|||||||
@ -53,7 +53,7 @@ def main():
|
|||||||
cam.stream_on()
|
cam.stream_on()
|
||||||
time.sleep(0.1)
|
time.sleep(0.1)
|
||||||
# acquisition image: num is the image number
|
# acquisition image: num is the image number
|
||||||
num = 1
|
num = 10
|
||||||
for i in range(num):
|
for i in range(num):
|
||||||
# get raw image
|
# get raw image
|
||||||
raw_image = cam.data_stream[0].get_image()
|
raw_image = cam.data_stream[0].get_image()
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user