]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - tos/chips/m16c62p/m16c62phardware.h
Added faster baud rate speed when using sm16cf to program Mulle.
[tinyos-2.x.git] / tos / chips / m16c62p / m16c62phardware.h
index 1603d661c7bb02f679fe7634dc06e13344d9de82..d4f892711d25b48175c5024166edf64974c0e6a5 100755 (executable)
@@ -47,6 +47,8 @@
 #include "interrupts.h"
 #include "iom16c62p.h"
 #include "bits.h"
+#include "uart/M16c62pUart.h"
+#include "pins/M16c62pPin.h"
 
 #define true 1
 #define false 0
@@ -117,10 +119,10 @@ typedef uint16_t __nesc_atomic_t;
 inline __nesc_atomic_t __nesc_atomic_start(void) @spontaneous()
 {
   __nesc_atomic_t result;
-  // Disable interrupts
-  __nesc_disable_interrupt();
   // Save the flag register (FLG)
   asm volatile ("stc flg, %0": "=r"(result): : "%flg");
+  // Disable interrupts
+  __nesc_disable_interrupt();
   asm volatile("" : : : "memory"); // ensure atomic section effect visibility
   return result;
 }
@@ -147,4 +149,49 @@ inline void __nesc_atomic_end(__nesc_atomic_t original_FLG) @spontaneous()
 #define PLL_MULTIPLIER M16C62P_PLL_2
 #endif
 
+// Default inactive pin states
+#ifndef PORT_P0_INACTIVE_STATE
+#define PORT_P0_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
+#ifndef PORT_P1_INACTIVE_STATE
+#define PORT_P1_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
+#ifndef PORT_P2_INACTIVE_STATE
+#define PORT_P2_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
+#ifndef PORT_P3_INACTIVE_STATE
+#define PORT_P3_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
+#ifndef PORT_P4_INACTIVE_STATE
+#define PORT_P4_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
+#ifndef PORT_P5_INACTIVE_STATE
+#define PORT_P5_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
+#ifndef PORT_P6_INACTIVE_STATE
+#define PORT_P6_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
+#ifndef PORT_P7_INACTIVE_STATE
+#define PORT_P7_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
+#ifndef PORT_P8_INACTIVE_STATE
+#define PORT_P8_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
+#ifndef PORT_P9_INACTIVE_STATE
+#define PORT_P9_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
+#ifndef PORT_P_10_INACTIVE_STATE
+#define PORT_P_10_INACTIVE_STATE M16C_PIN_INACTIVE_DONT_CARE
+#endif
+
 #endif  // __M16C62PHARDWARE_H__