add adc support for 328 mega

This commit is contained in:
andvikt
2021-09-18 22:08:52 +03:00
parent 1ec581b08b
commit e134a874fa
3 changed files with 25 additions and 1 deletions

21
.bumpversion.cfg Normal file
View File

@@ -0,0 +1,21 @@
[bumpversion]
current_version = 1.0.10b0
parse = (?P<major>\d+)(\.(?P<minor>\d+))(\.(?P<patch>\d))(?P<release>[bf]*)(?P<build>\d*)
commit = True
tag = True
serialize =
{major}.{minor}.{patch}{release}{build}
{major}.{minor}.{patch}
[bumpversion:part:release]
optional_value = f
values =
b
f
[bumpversion:part:build]
first_value = 0
[bumpversion:file:custom_components/mega/manifest.json]
search = "version": "v{current_version}"
replace = "version": "v{new_version}"

View File

@@ -566,6 +566,9 @@ class MegaD:
elif cfg.pty == '4' and cfg.m == '2': elif cfg.pty == '4' and cfg.m == '2':
# scl исключаем из сканирования # scl исключаем из сканирования
continue continue
elif cfg.pty is None and nports < 30:
# вроде как это ADC на 328 меге
ret['sensor'][port].append(dict())
elif cfg.pty in ('3', '2', '4'): elif cfg.pty in ('3', '2', '4'):
http_cmd = 'get' http_cmd = 'get'
if cfg.d == '5' and cfg.pty == '3': if cfg.d == '5' and cfg.pty == '3':

View File

@@ -15,5 +15,5 @@
"@andvikt" "@andvikt"
], ],
"issue_tracker": "https://github.com/andvikt/mega_hacs/issues", "issue_tracker": "https://github.com/andvikt/mega_hacs/issues",
"version": "v1.0.9" "version": "v1.0.10b0"
} }