Slide 16
Slide 16 text
ؤுͬͨͱ͜Ζ
# ίϚϯυͷඪ४ग़ྗΛड͚औΔ
proc = subprocess.run(
["./bin/2jcieev01-baro"],
stdout = subprocess.PIPE,
stderr = subprocess.PIPE
)
out = proc.stdout.decode("utf8").strip()
# ඪ४ग़ྗͷจࣈྻΛׂͯ͠ؾѹͱؾԹͷσʔλΛऔಘ͢Δ
# ['100154.6','32.840','a463d4','665d03','return code: 0']
data = list(map(lambda str: str.strip(), out.split(',')))
https://github.com/isaaxug/omron-env/blob/master/demo.py#L23-L33