From c9e2e8068faf12400c8b05db70a2b5bb361bb6a8 Mon Sep 17 00:00:00 2001 From: mj Date: Wed, 22 Dec 2021 18:49:26 +0100 Subject: [PATCH] Added file for 485 fuzz test --- tests/test_485_fuzz.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 tests/test_485_fuzz.py diff --git a/tests/test_485_fuzz.py b/tests/test_485_fuzz.py new file mode 100644 index 0000000..687783e --- /dev/null +++ b/tests/test_485_fuzz.py @@ -0,0 +1,14 @@ +#!/usr/bin/env python3 +# +# Test: 485 fuzzer +# ---------------- +# Repeatedly write random data to sensor via 485. +# After that, try to read some input registers. +# (address and baudrate is hardcoded) +# +# Return 0 if read was successful, 1 otherwise. +# +import serial +import minimalmodbus + +