python-halow-client.py

MikroTik KNOT Gateway HL9 · File : python-halow-client.py · Language : Python · Use case : Tester la connectivité Wi-Fi HaLow 915 MHz en envoyant des requêtes HTTP vers un serveur distant.

Simple HTTP client to check the stability of the long-range HaLow link.

The Morse Micro SoC handles the HaLow physical layer. This script uses the wlan1 interface configured in HaLow client mode. Ideal for testing latency and packet loss over long distances. Requires the 'requests' library.

python-halow-client.py

import requests
import time

URL = "http://192.168.88.1/api/status" # Example internal or external endpoint

while True:
    try:
        response = requests.get(URL, timeout=5)
        print(f"Status: {response.status_code}, Time: {time.time()}")
    except Exception as e:
        print(f"Error: {e}")
    time.sleep(60)

← Back to the board