]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - tos/sensorboards/im2sb/MAX136xInternalC.nc
Add a BusyWait interface for controlling SHT1X timing requirements.
[tinyos-2.x.git] / tos / sensorboards / im2sb / MAX136xInternalC.nc
index 3c564f27c78446ce54a3ae40aa31e030cb9f79b3..7f7bdbd4140c0f9962b6162c980b3b8d5afa3e1f 100644 (file)
@@ -42,23 +42,29 @@ configuration MAX136xInternalC {
 }
 
 implementation {
-  components new FcfsArbiterC( "MAX136x.Resource" )as Arbiter;
+  components new SimpleFcfsArbiterC( "MAX136x.Resource" )as Arbiter;
   components MainC;
   Resource = Arbiter;
-  MainC.SoftwareInit -> Arbiter;
 
   components new HplMAX136xLogicP(MAX136_SLAVE_ADDR) as Logic;
-  MainC.SoftwareInit -> Logic;
+  //MainC.SoftwareInit -> Logic;
 
-  components HalPXA27xI2CMasterC as I2CC;
+ components GeneralIOC;
+  Logic.InterruptAlert -> GeneralIOC.GpioInterrupt[GPIO_MAX1363_ANALOG_INT];
+  Logic.InterruptPin -> GeneralIOC.GeneralIO[GPIO_MAX1363_ANALOG_INT];
+
+  components new HalPXA27xI2CMasterC(TRUE) as I2CC;
   Logic.I2CPacket -> I2CC;
 
   components MAX136xInternalP as Internal;
   HplMAX136x = Internal.HplMAX136x;
   Internal.ToHPLC -> Logic.HplMAX136x;
-
+  Internal.SubInit -> Logic.Init;
+  Internal.InterruptAlert -> GeneralIOC.GpioInterrupt[GPIO_MAX1363_ANALOG_INT];
+  MainC.SoftwareInit -> Internal.Init;
   SplitControl = Logic;
 
   components HplPXA27xGPIOC;
   I2CC.I2CSCL -> HplPXA27xGPIOC.HplPXA27xGPIOPin[I2C_SCL];
   I2CC.I2CSDA -> HplPXA27xGPIOC.HplPXA27xGPIOPin[I2C_SDA];