X-Git-Url: https://oss.titaniummirror.com/gitweb/?a=blobdiff_plain;f=tos%2Fchips%2Fsht11%2FSensirionSht11LogicP.nc;h=f3f02697b0737b2d783a9422d8f1ca767849ee13;hb=4122e4dfb28f7b5e72c9dd1c401e19d93ca82820;hp=ce4aa6ca68f7f46bfb54696af6d250853abdb7b4;hpb=4ef669e6eea48bc320936d45f2fdb8a2d6d5190b;p=tinyos-2.x.git diff --git a/tos/chips/sht11/SensirionSht11LogicP.nc b/tos/chips/sht11/SensirionSht11LogicP.nc index ce4aa6ca..f3f02697 100644 --- a/tos/chips/sht11/SensirionSht11LogicP.nc +++ b/tos/chips/sht11/SensirionSht11LogicP.nc @@ -57,6 +57,7 @@ generic module SensirionSht11LogicP() { uses interface GeneralIO as CLOCK; uses interface GpioInterrupt as InterruptDATA; + uses interface BusyWait; uses interface Timer; uses interface Leds; @@ -240,11 +241,17 @@ implementation { call DATA.makeOutput(); call DATA.set(); call CLOCK.clr(); + call BusyWait.wait(5); call CLOCK.set(); + call BusyWait.wait(5); call DATA.clr(); + call BusyWait.wait(5); call CLOCK.clr(); + call BusyWait.wait(5); call CLOCK.set(); + call BusyWait.wait(5); call DATA.set(); + call BusyWait.wait(5); call CLOCK.clr(); } @@ -261,6 +268,7 @@ implementation { call DATA.clr(); byte = byte << 1; call CLOCK.set(); + call BusyWait.wait(5); call CLOCK.clr(); } } @@ -373,6 +381,7 @@ implementation { call DATA.makeOutput(); call DATA.clr(); call CLOCK.set(); + call BusyWait.wait(5); call CLOCK.clr(); call DATA.makeInput(); call DATA.set(); @@ -382,6 +391,7 @@ implementation { call DATA.makeOutput(); call DATA.set(); call CLOCK.set(); + call BusyWait.wait(5); call CLOCK.clr(); }