Skip to content

Commit 4191477

Browse files
actions working, load and unload not tested
1 parent bf41fe8 commit 4191477

File tree

6 files changed

+626
-215
lines changed

6 files changed

+626
-215
lines changed

examples/__init__.py

Whitespace-only changes.

pdm.lock

Lines changed: 153 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ authors = [
1111
{name = "Tobias Ginsburg", email = "tginsburg@anl.gov"},
1212
]
1313
dependencies = [
14-
"madsci.node_module~=0.4.3",
15-
"madsci.common~=0.4.3",
16-
"madsci.client~=0.4.3",
14+
"madsci.node_module~=0.5.3",
15+
"madsci.common~=0.5.3",
16+
"madsci.client~=0.5.3",
1717
]
1818
requires-python = ">=3.9.21"
1919
readme = "README.md"

src/LiconicRestNode.info.yaml

Lines changed: 263 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,263 @@
1+
node_name: LiconicRestNode
2+
node_id: 01KA230NXHZAS739FRRP42K4DP
3+
node_description: null
4+
node_type: device
5+
module_name: LiconicRestNode
6+
module_version: 0.0.1
7+
capabilities:
8+
get_info: true
9+
get_state: true
10+
get_status: true
11+
send_action: true
12+
get_action_status: true
13+
get_action_result: true
14+
get_action_history: true
15+
action_files: true
16+
send_admin_commands: true
17+
set_config: true
18+
get_resources: false
19+
get_log: true
20+
admin_commands:
21+
- lock
22+
- reset
23+
- shutdown
24+
- unlock
25+
node_url: null
26+
actions:
27+
set_target_temp:
28+
name: set_target_temp
29+
description: Set the target temperature of the incubator
30+
args:
31+
temp:
32+
name: temp
33+
description: target temperature in celsius
34+
argument_type: float
35+
required: true
36+
default: null
37+
locations: {}
38+
files: {}
39+
results: {}
40+
blocking: false
41+
asynchronous: true
42+
accepts_var_args: false
43+
accepts_var_kwargs: false
44+
var_args_schema: null
45+
var_kwargs_schema: null
46+
set_target_humidity:
47+
name: set_target_humidity
48+
description: Set the target humidity of the incubator
49+
args:
50+
humidity:
51+
name: humidity
52+
description: target humidity
53+
argument_type: float
54+
required: true
55+
default: null
56+
locations: {}
57+
files: {}
58+
results: {}
59+
blocking: false
60+
asynchronous: true
61+
accepts_var_args: false
62+
accepts_var_kwargs: false
63+
var_args_schema: null
64+
var_kwargs_schema: null
65+
begin_shake:
66+
name: begin_shake
67+
description: Begin shaking the incubator at the specified speed
68+
args:
69+
shaker_id:
70+
name: shaker_id
71+
description: shaker id (shaker 1 = stacks 1 and 2, shaker 2 = stacks 3 and
72+
4 , or None for both shakers)
73+
argument_type: int
74+
required: false
75+
default: null
76+
shaker_speed:
77+
name: shaker_speed
78+
description: shaker speed (1-50 valid, default 20 = 200rpm)
79+
argument_type: int
80+
required: false
81+
default: 20
82+
locations: {}
83+
files: {}
84+
results: {}
85+
blocking: false
86+
asynchronous: true
87+
accepts_var_args: false
88+
accepts_var_kwargs: false
89+
var_args_schema: null
90+
var_kwargs_schema: null
91+
end_shake:
92+
name: end_shake
93+
description: Stop shaking the incubator
94+
args:
95+
shaker_id:
96+
name: shaker_id
97+
description: shaker id (shaker 1 = stacks 1 and 2, shaker 2 = stacks 3 and
98+
4 , or None for both shakers)
99+
argument_type: int
100+
required: false
101+
default: null
102+
locations: {}
103+
files: {}
104+
results: {}
105+
blocking: false
106+
asynchronous: true
107+
accepts_var_args: false
108+
accepts_var_kwargs: false
109+
var_args_schema: null
110+
var_kwargs_schema: null
111+
load_plate:
112+
name: load_plate
113+
description: Load a plate into the incubator
114+
args:
115+
plate_type:
116+
name: plate_type
117+
description: plate type (flat_bottom_96well, deep_96well, etc.)
118+
argument_type: str
119+
required: true
120+
default: null
121+
plate_id:
122+
name: plate_id
123+
description: plate id
124+
argument_type: str
125+
required: false
126+
default: null
127+
stack:
128+
name: stack
129+
description: stack number (1-4), must also specify slot
130+
argument_type: int
131+
required: false
132+
default: null
133+
slot:
134+
name: slot
135+
description: slot number (1-22 for stacks 1 and 2, 1-10 for stacks 3 and 4,
136+
must also specify stack)
137+
argument_type: int
138+
required: false
139+
default: null
140+
locations: {}
141+
files: {}
142+
results: {}
143+
blocking: false
144+
asynchronous: true
145+
accepts_var_args: false
146+
accepts_var_kwargs: false
147+
var_args_schema: null
148+
var_kwargs_schema: null
149+
unload_plate:
150+
name: unload_plate
151+
description: Unload a plate from the incubator
152+
args:
153+
plate_id:
154+
name: plate_id
155+
description: plate id
156+
argument_type: str
157+
required: false
158+
default: null
159+
stack:
160+
name: stack
161+
description: stacker number (1-4)
162+
argument_type: int
163+
required: false
164+
default: null
165+
slot:
166+
name: slot
167+
description: slot number (1-22 for stacks 1 and 2, 1-10 for stacks 3 and 4)
168+
argument_type: int
169+
required: false
170+
default: null
171+
locations: {}
172+
files: {}
173+
results: {}
174+
blocking: false
175+
asynchronous: true
176+
accepts_var_args: false
177+
accepts_var_kwargs: false
178+
var_args_schema: null
179+
var_kwargs_schema: null
180+
config:
181+
node_definition: default.node.yaml
182+
node_info_path: null
183+
update_node_files: true
184+
status_update_interval: 2.0
185+
state_update_interval: 2.0
186+
node_url: http://hudson01.cels.anl.gov:2005/
187+
uvicorn_kwargs: {}
188+
liconic_driver_port: 3333
189+
liconic_driver_host: localhost
190+
resources_path: C:\Users\svcaibio\.madsci\liconic\liconic_resources.yaml
191+
config_schema:
192+
description: Configuration for the LiCONiC REST node
193+
properties:
194+
node_definition:
195+
anyOf:
196+
- type: string
197+
- format: path
198+
type: string
199+
- type: 'null'
200+
default: default.node.yaml
201+
description: Path to the node definition file to use. If set, the node will
202+
load the definition from this file on startup. Otherwise, a default configuration
203+
will be created.
204+
title: Node Definition File
205+
node_info_path:
206+
anyOf:
207+
- type: string
208+
- format: path
209+
type: string
210+
- type: 'null'
211+
default: null
212+
description: Path to export the generated node info file. If not set, will use
213+
the node name and the node_definition's path.
214+
title: Node Info Path
215+
update_node_files:
216+
default: true
217+
description: Whether to update the node definition and info files on startup.
218+
If set to False, the node will not update the files even if they are out of
219+
date.
220+
title: Update Node Files
221+
type: boolean
222+
status_update_interval:
223+
anyOf:
224+
- type: number
225+
- type: 'null'
226+
default: 2.0
227+
description: The interval in seconds at which the node should update its status.
228+
title: Status Update Interval
229+
state_update_interval:
230+
anyOf:
231+
- type: number
232+
- type: 'null'
233+
default: 2.0
234+
description: The interval in seconds at which the node should update its state.
235+
title: State Update Interval
236+
node_url:
237+
default: http://127.0.0.1:2000/
238+
description: The URL used to communicate with the node. This is the base URL
239+
for the REST API.
240+
format: uri
241+
minLength: 1
242+
title: Node URL
243+
type: string
244+
uvicorn_kwargs:
245+
additionalProperties: true
246+
description: Configuration for the Uvicorn server that runs the REST API.
247+
title: Uvicorn Configuration
248+
type: object
249+
liconic_driver_port:
250+
default: 3333
251+
title: Liconic Driver Port
252+
type: integer
253+
liconic_driver_host:
254+
default: localhost
255+
title: Liconic Driver Host
256+
type: string
257+
resources_path:
258+
default: C:\Users\svcaibio\.madsci\liconic\liconic_resources.yaml
259+
format: path
260+
title: Resources Path
261+
type: string
262+
title: LiconicNodeConfig
263+
type: object

src/default.node.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
node_name: LiconicRestNode
2+
node_id: 01KA230NXHZAS739FRRP42K4DP
3+
node_description: null
4+
node_type: device
5+
module_name: LiconicRestNode
6+
module_version: 0.0.1
7+
capabilities: null

0 commit comments

Comments
 (0)