X-Git-Url: https://oss.titaniummirror.com/gitweb/?a=blobdiff_plain;f=tos%2Fchips%2Fmsp430%2Fpins%2FHplMsp430GeneralIORenP.nc;h=e799bcd627af8cab408d34c3543ee9ec5dcffc39;hb=5d1185472b58034d288d276aa6a3d079099671c4;hp=82cb01486c488326d9695e69f8b6aeca9f1ce83e;hpb=10acc57d16a648d746eed9d5c6264850f7c52fde;p=tinyos-2.x.git diff --git a/tos/chips/msp430/pins/HplMsp430GeneralIORenP.nc b/tos/chips/msp430/pins/HplMsp430GeneralIORenP.nc index 82cb0148..e799bcd6 100644 --- a/tos/chips/msp430/pins/HplMsp430GeneralIORenP.nc +++ b/tos/chips/msp430/pins/HplMsp430GeneralIORenP.nc @@ -55,6 +55,8 @@ implementation async command void IO.set() { atomic PORTx |= (0x01 << pin); } async command void IO.clr() { atomic PORTx &= ~(0x01 << pin); } async command void IO.toggle() { atomic PORTx ^= (0x01 << pin); } + async command uint8_t IO.getOutRaw() { return PORTx & (0x01 << pin); } + async command bool IO.getOut() { return (call IO.getOutRaw() != 0); } async command uint8_t IO.getRaw() { return PORTxIN & (0x01 << pin); } async command bool IO.get() { return (call IO.getRaw() != 0); } async command void IO.makeInput() { atomic PORTxDIR &= ~(0x01 << pin); } @@ -67,4 +69,5 @@ implementation async command bool IO.isIOFunc() { return (PORTxSEL & (0x01<