Karhu85
(Karhu85)
September 21, 2021, 8:04am
1
Hi!
I want to split the config to smaller parts. I have already spitted the modbus, but when I try to separate the Beckhoff ADS, I get this error.
I have added the ADS to config like this:
script: !include scripts.yaml
scene: !include scenes.yaml
modbus: !include_dir_merge_list modbus
ads: !include_dir_merge_list ads
And the ADS file:
#ads
device: ‘192.168.1.13.1.1’
port: 801
ip_address: 192.168.1.13
It has worked when its in the config file before separation:
ads
device: ‘192.168.1.13.1.1’
port: 801
ip_address: 192.168.1.13
Could some guide me in the right directions, as I don´t see what is wrong. I made the splitting as the modbus that works.
Thanks for your help.
pedolsky
(Pedolsky)
September 21, 2021, 8:16am
2
Hello Karhu85, welcome!
You want to include a list, so I would try with a dash:
- device: '192.168.1.13.1.1'
port: 801
ip_address: 192.168.1.13
Karhu85
(Karhu85)
September 21, 2021, 12:44pm
3
Hi Pedolsky,
thanks for your help!
I tried your solution, but got a new error when checking the config:
It seems to point to the include section:
Is there something else, that I could try?
BR
Karhu
koying
(Chris B)
September 21, 2021, 12:55pm
4
You can only do includes of configuration items taking a list (i.e. ones with dashes).
ads:
is just the definition of the integration, you cannot split it up.
Karhu85
(Karhu85)
September 21, 2021, 1:06pm
5
Hi Koying,
thanks for your help.
Ok, ads cannot be split, so I will leave the declaration to the main config file and make own splits for the switched and sensors.
BR,
Karhu