temporary hardcoding of addresses, ready for test

This commit is contained in:
0xEmm 2024-05-21 15:47:01 +02:00
parent 8a3eb2de70
commit b665085833
4 changed files with 14 additions and 7 deletions

View file

@ -33,6 +33,7 @@ class EAMValue:
def field_to_eam_telnet_code(field: EAMValue) -> str:
_io = str(field.io + field.id)
# cursed conversion to extron speak, this is how it was in the documentation
_val = str(int(float(field.val) * 10) + 2048) if field.act == ActionType.Gain else \
(1 if field.val == "ON" else 0)
return f"\e{field.act}{_io}*{_val}AU\r\n"