Open ivomarino opened 3 years ago
I also had to modify this to exclude radio2
:
async def discover_wireless(self) -> dict:
result = dict(ap=[], mesh=[])
if not self.is_api_supported("network.wireless"):
return result
try:
response = await self._ubus.api_call('network.wireless', 'status', {})
for radio, item in response.items():
if radio != 'radio2': <-------------------------- modified here
for iface in item['interfaces']:
conf = dict(ifname=iface['ifname'],network=iface['config']['network'][0])
if iface['config']['mode'] == 'ap':
result['ap'].append(conf)
if iface['config']['mode'] == 'mesh':
conf['mesh_id'] = iface['config']['mesh_id']
result['mesh'].append(conf)
except NameError as err:
_LOGGER.warning(
f"Device [{self._id}] doesn't support wireless: {err}")
return result
radio2
is a device which ist not active on a wrt3200acm, it's added to the config on boot. This interface needs to be skipped, if not we get a Python KeyError
Hi,
on my OpenWRT instance I don't have WPS so I hade to disable this part in the code
I've made WPS support optional. Please fetch the latest version and re-add your device. (there should be WPS support checkbox)
radio2 is a device which ist not active on a wrt3200acm, it's added to the config on boot
if you're not using it, why it's not disabled in the config then?
if not we get a Python KeyError
Where exactly did you get this error?
Hi and thanks for this great integration, on my OpenWRT instance I don't have WPS so I hade to disable this part in the code:
I just have normal AP clients cause running in AP mode, like:
would be great if we could add support also for this use case, thanks;)