I’ve created a very simple integration (https://github.com/Misiu/argon40) that has only a single service.
The communication with the device is done via I2C, so if the user doesn’t enable it the integration won’t loa (and old versions of HA will crash)
My idea is to add config flow without any input, that will check if I2C is enabled and that will try to communicate with the device (the device has a fixed address). Only if everything will success the integration will be set-up.
My integration is based on https://github.com/custom-components/blueprint.
I try to follow https://github.com/custom-components/blueprint/blob/99b07e5a7ae5dd4e949607b5377afe3128dd2d83/custom_components/blueprint/config_flow.py but as I wrote before, I don’t expect any input from the user, only hardware validation and I2C check.
Id like to ask for a hint or a sample that shows how to create a config flow that doesn’t require any input from the user and that can check is specific conditions are met before the integration is set-up.