WindShape

WindVision

Manage Mesh and Acquisitions

Acquisitions

When taking measurement in WindVision, you can acquire data in a mesh you've defined.

The data read by the WindProbe is only added to the Mesh when the acquisition is active.

You can start and stop this acquisition from the SDK.

#code

start_acquisition.py
import os
import threading

from dotenv import load_dotenv
from windsuite_sdk import WindsuiteSDK

load_dotenv()

SERVER_IP_ADDRESS = os.getenv("SERVER_IP_ADDRESS", default="192.168.88.40")

stop_event = threading.Event()


def main() -> None:
    base_url = f"http://{SERVER_IP_ADDRESS}"

    print(f"Connecting to WindSuite server at {base_url}")

    sdk = WindsuiteSDK(base_url=base_url)
    sdk.start_communication()

    try:
        success = sdk.start_acquisition(name="test-001")
        if success:
            print("Acquisition started successfully.")
        else:
            print("Failed to start acquisition.")
            stop_event.set()

    except KeyboardInterrupt:
        print("\nShutting down...")
        stop_event.set()
    finally:
        sdk.fan_controller.set_intensity(0).apply()
        sdk.cleanup()
        print("SDK stopped")

if __name__ == "__main__":
    main()
You can off-course also stop the acquisition using sdk.stop_acquisition()