14.11.2024, 15:20
Hello,
I created a script to connect my LM from my Mikrotik device to check if my car is at home, like the example https://kb.logicmachine.net/integration/mikrotik/
But with the latest firmware this doesn't work. Maybe because you can't send the username and password this way.
How to solve this?
I created a script to connect my LM from my Mikrotik device to check if my car is at home, like the example https://kb.logicmachine.net/integration/mikrotik/
Code:
# tesla
:global auto01Stor
:local auto01 [/ip arp find mac-address="XX:XX:XX:XX:XX:XX" and complete=yes];
# tesla model 3
:if ($auto01 != $auto01Stor) do={
:if ($auto01 != "") do={
/tool fetch url="http://xxxxx:xxxxxxxx@x.x.x.x/scada-remote" http-data="m=json&r=grp&fn=write&alias=32/1/4&value=1" http-method=post;
} else= {
/tool fetch url="http:// xxxxx:xxxxxxxx@x.x.x.x /scada-remote" http-data="m=json&r=grp&fn=write&alias=32/1/4&value=0" http-method=post;
}
:set auto01Stor $auto01;
}
But with the latest firmware this doesn't work. Maybe because you can't send the username and password this way.
How to solve this?