Replies: 1 comment 1 reply
-
I don't think Here's how to do that. You should move the body of the service function to a new function, remove anything that is |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello, I am using a Waveshare usb device in homeassistant RPi3 with HAOS, and are trying to read the 8 channel WaveShare modbus device. After getting advice from their Helpdesk and a working python script- I want to call this with HACS > pyscript integration.
I have this scripts (got it setup and working on the /pyscript folder - other scripts are working). The issue is to wait for the USB RS485 dongle to send back the registers info after asking the device for it. the issue is that time.sleep() worked until recently, now pyscript wants asyncio.sleep(1). This script is not reporting info back from the
log.error(f"Pyscript app modbus4 - modbus.readregisters - variables: {state_var_json}")
logs - so it looks like it is not working.Any ideas anyone?
Beta Was this translation helpful? Give feedback.
All reactions