Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
Diff: Debug.h
- Revision:
- 10:258a1eca02cc
- Parent:
- 9:f6ba53e355a0
- Child:
- 11:6ae098535da9
--- a/Debug.h Wed May 06 14:37:34 2020 +0000
+++ b/Debug.h Wed May 06 19:51:22 2020 +0000
@@ -17,7 +17,7 @@
if(sin_debug(0, 32768))passed++;
if(sin_debug(512, 32768))passed++;
if(sin_debug(256, 65535))passed++;
-
+
if (passed==3) {
printf("Sin debug PASS\n");
return (1);
@@ -27,15 +27,34 @@
return (0);
}
}
-void run_LUTs_debug ()
+
+bool run_tri_debug()
+{
+ int passed=0;
+ if(tri_debug(50,0,0))passed++;
+ if(tri_debug(50,512, 65535))passed++;
+ //if(tri_debug(80,0,0))passed++;
+
+ if (passed==2) {
+ printf("Tri debug PASS\n");
+ return (1);
+ } else {
+ printf("Tri debug FAIL\n");
+ printf("tests passed = %d\n", passed);
+ return (0);
+ }
+}
+
+void run_LUTs_debug ()
{
int masterpass=0;
if(run_sin_debug())masterpass++;
- if(masterpass==1) {
+ if(run_tri_debug())masterpass++;
+ if(masterpass==2) {
printf("DEBUG PASSED\n");
- }else {
- printf("DEBUG FAIL tests passed = %d\n",masterpass);
- }
+ } else {
+ printf("DEBUG FAIL tests passed = %d\n",masterpass);
+ }
}