-
Notifications
You must be signed in to change notification settings - Fork 58
-
Hi, I install hassos on vmm on Synology. I want to connect to serial interface to enable modbus devices.
here is what I have done:
- the serial interface is setup on the VMM,
- I can test the serial interface by command in hass vmm terminal
domes | grep tty
which results in
ch341-uart converter now attached to ttyUSB0
- I setup pyscript up correctly, some Services I have - does execute
Until I want to run a pyscript that uses import serial
.
I have imported the serial interface by hand with:
apk add --update py-pip
pip install serial
But when I run an app in pyserial (properly configured - with it registed in config.yaml)
I get import serial ^ ModuleNotFoundError: import of serial not allowed
Any ideas?
Beta Was this translation helpful? Give feedback.
All reactions
Replies: 1 comment
-
And here is the app in pyscript, named init.py with the import that causes it:
#!/usr/bin/env python3
# -*- coding:utf-8 -*-
@service # ("testpython.serialversion")
def testPythonSerial():
import serial
log.warning(serial.__version__)
Beta Was this translation helpful? Give feedback.
All reactions
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment