X-Git-Url: https://oss.titaniummirror.com/gitweb/?a=blobdiff_plain;f=tos%2Fchips%2Fsht11%2FSensirionSht11LogicP.nc;h=f3f02697b0737b2d783a9422d8f1ca767849ee13;hb=9b56ef4b539a83c099e348c2283a6717fc4b19a0;hp=ce4aa6ca68f7f46bfb54696af6d250853abdb7b4;hpb=d05948de7af127380b8bae332bf2560cd9693cd5;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(); }