]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - tos/platforms/tmirws/chips/scp1000/Scp1000PinsC.nc
Merge TinyOS 2.1.1 into master.
[tinyos-2.x.git] / tos / platforms / tmirws / chips / scp1000 / Scp1000PinsC.nc
index 96e9655f70d3e50228c09f75d5794834d83d8bce..525955e979451e19e600b3794b1bfd3bf5146900 100644 (file)
  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
  * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
+
 /**
  * Platform specific pin mapping for the Scp1000.
- * 
- * @author R. Steve McKown <smckown@gmail.com>
+ *
+ * @author R. Steve McKown <rsmckown@gmail.com>
  */
+
 configuration Scp1000PinsC {
   provides {
-    interface HplMsp430GeneralIO as CSn;
-    interface HplMsp430GeneralIO as PD;
-    interface HplMsp430GeneralIO as DRDY;
+    interface GeneralIO as CSn;
+    interface GeneralIO as PD;
+    interface GeneralIO as DRDY;
     interface GpioInterrupt as IntDRDY;
   }
 }
 implementation {
-#if 0
   components new Msp430GpioC() as CSn_;
   CSn = CSn_.GeneralIO;
 
-  components new Msp430GpioC() as PD_;
-  PD = PD_.GeneralIO;
-
   components new Msp430GpioC() as DRDY_;
   DRDY = DRDY_.GeneralIO;
-#endif
 
   components new Msp430InterruptC() as IntDRDY_;
   IntDRDY = IntDRDY_.Interrupt;
 
   components HplMsp430GeneralIOC as IOC;
-#if 0
   CSn_.HplGeneralIO -> IOC.Port43;
-  PD_.HplGeneralIO -> IOC.Port42;
   DRDY_.HplGeneralIO -> IOC.Port26;
-#else
-  CSn = IOC.Port43;
-  PD = IOC.Port42;
-  DRDY = IOC.Port26;
-#endif
 
   components HplMsp430InterruptC as IntC;
   IntDRDY_.HplInterrupt -> IntC.Port26;
+
+  components new Scp1000PinsP() as PinsP;
+  PD = PinsP.PD;
+  PinsP.CSn -> IOC.Port43;
+  PinsP._PD -> IOC.Port42;
+  PinsP.DRDY -> IOC.Port26;
+
+  components MainC;
+  MainC.SoftwareInit -> PinsP;
 }