[Tinyos-2-commits] CVS: tinyos-2.x/tos/chips/atm128/pins
HplAtm128GeneralIOPinP.nc, 1.1.2.3,
1.1.2.4 HplAtm128GeneralIOSlowPinP.nc, 1.1.2.2, 1.1.2.3
Jonathan Hui
jwhui at users.sourceforge.net
Thu Sep 28 12:57:10 PDT 2006
Update of /cvsroot/tinyos/tinyos-2.x/tos/chips/atm128/pins
In directory sc8-pr-cvs10.sourceforge.net:/tmp/cvs-serv10355/chips/atm128/pins
Modified Files:
Tag: tinyos-2_0_devel-BRANCH
HplAtm128GeneralIOPinP.nc HplAtm128GeneralIOSlowPinP.nc
Log Message:
Updates to include isInput() and isOutput()
Index: HplAtm128GeneralIOPinP.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/chips/atm128/pins/HplAtm128GeneralIOPinP.nc,v
retrieving revision 1.1.2.3
retrieving revision 1.1.2.4
diff -C2 -d -r1.1.2.3 -r1.1.2.4
*** HplAtm128GeneralIOPinP.nc 25 Apr 2006 23:50:30 -0000 1.1.2.3
--- HplAtm128GeneralIOPinP.nc 28 Sep 2006 19:57:08 -0000 1.1.2.4
***************
*** 49,53 ****
--- 49,55 ----
inline async command void IO.makeInput() { CLR_BIT (ddr, bit); }
+ inline async command bool IO.isInput() { return !READ_BIT(ddr, bit); }
inline async command void IO.makeOutput() { SET_BIT (ddr, bit); }
+ inline async command bool IO.isOutput() { return READ_BIT(ddr, bit); }
}
Index: HplAtm128GeneralIOSlowPinP.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/chips/atm128/pins/HplAtm128GeneralIOSlowPinP.nc,v
retrieving revision 1.1.2.2
retrieving revision 1.1.2.3
diff -C2 -d -r1.1.2.2 -r1.1.2.3
*** HplAtm128GeneralIOSlowPinP.nc 27 Jan 2006 21:55:55 -0000 1.1.2.2
--- HplAtm128GeneralIOSlowPinP.nc 28 Sep 2006 19:57:08 -0000 1.1.2.3
***************
*** 50,53 ****
--- 50,55 ----
inline async command void IO.makeInput() { atomic CLR_BIT (ddr, bit); }
+ inline async command bool IO.isInput() { return !READ_BIT(ddr, bit); }
inline async command void IO.makeOutput() { atomic SET_BIT (ddr, bit); }
+ inline async command bool IO.isOutput() { return READ_BIT(ddr, bit); }
}
More information about the Tinyos-2-commits
mailing list