GroupA / Mbed 2 deprecated Lab_6_WaG

Dependencies:   mbed

Fork of WaG by GroupA

Files at this revision

API Documentation at this revision

Comitter:
spm71
Date:
Fri Mar 23 19:32:39 2018 +0000
Parent:
37:7ec498a322c1
Child:
39:abf211b17e3c
Commit message:
troubleshooting

Changed in this revision

analog.h Show annotated file Show diff for this revision Revisions of this file
main.cpp Show annotated file Show diff for this revision Revisions of this file
utility.h Show annotated file Show diff for this revision Revisions of this file
--- a/analog.h	Thu Mar 22 16:41:52 2018 +0000
+++ b/analog.h	Fri Mar 23 19:32:39 2018 +0000
@@ -11,6 +11,8 @@
 * Last Modified: 03/20/2018
 *
 ******************************************************************************/
+#ifndef ANALOG_H
+#define ANALOG_H
 
 #include "mbed.h"
 #include "io_pins.h"
@@ -18,4 +20,6 @@
 #define MUX_CHANS 16
 
 void ana_init();
-void ana_scan_mux(float * an_array, int no_of_channels);
\ No newline at end of file
+void ana_scan_mux(float * an_array, int no_of_channels);
+
+#endif
\ No newline at end of file
--- a/main.cpp	Thu Mar 22 16:41:52 2018 +0000
+++ b/main.cpp	Fri Mar 23 19:32:39 2018 +0000
@@ -17,6 +17,7 @@
 #include "spi.h"
 #include "stepper.h"
 #include "utility.h"
+#include "analog.h"
 #include <stdlib.h>
 #include <stdio.h>
 #include <string.h>
@@ -34,11 +35,11 @@
 
 
 struct spi_cfg as1107{
-    SPI_AS1107_ID,
-    DSP_AS1107_NCS,
-    SPI_NO_ID,
-    AS1107_SPI_FREQ,
-    AS1107_SPI_NO_BITS,
+    SPI_AS1107_ID;
+    DSP_AS1107_NCS;
+    SPI_NO_ID;
+    AS1107_SPI_FREQ;
+    AS1107_SPI_NO_BITS;
 };
 
 
--- a/utility.h	Thu Mar 22 16:41:52 2018 +0000
+++ b/utility.h	Fri Mar 23 19:32:39 2018 +0000
@@ -11,8 +11,12 @@
 * Last Modified: 03/20/2018
 *
 ******************************************************************************/
+#ifndef UTILITY_H
+#define UTILITY_H
 
 #include "mbed.h"
 #include "io_pins.h"
 
-int uti_chk_ubutton();
\ No newline at end of file
+int uti_chk_ubutton();
+
+#endif
\ No newline at end of file