summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/i386/ts_386ex/tools/debug_ada/debug.adb
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--c/src/lib/libbsp/i386/ts_386ex/tools/debug_ada/debug.adb32
1 files changed, 32 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/i386/ts_386ex/tools/debug_ada/debug.adb b/c/src/lib/libbsp/i386/ts_386ex/tools/debug_ada/debug.adb
new file mode 100644
index 0000000000..fd9215c978
--- /dev/null
+++ b/c/src/lib/libbsp/i386/ts_386ex/tools/debug_ada/debug.adb
@@ -0,0 +1,32 @@
+with Ada.Text_IO; use Ada.Text_IO;
+with Ada.Numerics.Discrete_Random;
+
+with TS1325.LED; use TS1325.LED;
+
+with Serial_Debug; use Serial_Debug;
+
+procedure Debug is
+
+ package Random_LED_Colour is
+ new Ada.Numerics.Discrete_Random (LED_Colour);
+ use Random_LED_Colour;
+
+ Colour_Gen: Random_LED_Colour.Generator;
+
+ New_Colour: LED_Colour;
+
+ Count: Integer := 0;
+
+begin
+ Breakpoint;
+
+ Put_Line ("******* Starting Random LED Debug Test *******");
+
+ for I in 1 .. 10_000 loop
+ Count := Count + 1;
+ New_Colour := Random_LED_Colour.Random (Colour_Gen);
+ LED_State.Set (New_Colour);
+ end loop;
+
+ Put_Line ("******* Finished Random LED Debug Test *******");
+end Debug;