summaryrefslogtreecommitdiff
path: root/kvmd/plugins/atx
diff options
context:
space:
mode:
authorMaxim Devaev <[email protected]>2022-08-07 19:35:08 +0300
committerMaxim Devaev <[email protected]>2022-08-07 19:35:08 +0300
commite37a7254d5cf7e4cfa5dcfbbaf5b0e9d7474d154 (patch)
treec25210abfceb0da0725798105a389c5598694ff7 /kvmd/plugins/atx
parentfdc3edfa799b21f04a83676459bab7a4e67b056f (diff)
using shield_fg() in atomic (now atomic_fg)
Diffstat (limited to 'kvmd/plugins/atx')
-rw-r--r--kvmd/plugins/atx/gpio.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/kvmd/plugins/atx/gpio.py b/kvmd/plugins/atx/gpio.py
index a4dabdfc..8d41e53d 100644
--- a/kvmd/plugins/atx/gpio.py
+++ b/kvmd/plugins/atx/gpio.py
@@ -185,7 +185,7 @@ class Plugin(BaseAtx): # pylint: disable=too-many-instance-attributes
async def __get_power(self) -> bool:
return (await self.get_state())["leds"]["power"]
- @aiotools.atomic
+ @aiotools.atomic_fg
async def __click(self, name: str, line: gpiod.Line, delay: float, wait: bool) -> None:
if wait:
async with self.__region:
@@ -196,7 +196,7 @@ class Plugin(BaseAtx): # pylint: disable=too-many-instance-attributes
self.__region, self.__inner_click, name, line, delay,
)
- @aiotools.atomic
+ @aiotools.atomic_fg
async def __inner_click(self, name: str, line: gpiod.Line, delay: float) -> None:
await aiogp.pulse(line, delay, 1)
get_logger(0).info("Clicked ATX button %r", name)