[Tinyos-2-commits] CVS: tinyos-2.x/tos/chips/tda5250 HplTda5250Data.nc, 1.1.2.3, 1.1.2.3.10.1 Tda5250RadioP.nc, 1.1.2.7, 1.1.2.7.4.1

Vlado Handziski vlahan at users.sourceforge.net
Fri Jul 14 14:38:53 PDT 2006


Update of /cvsroot/tinyos/tinyos-2.x/tos/chips/tda5250
In directory sc8-pr-cvs10.sourceforge.net:/tmp/cvs-serv31891/tos/chips/tda5250

Modified Files:
      Tag: tos-2-msp430-usart-configure-candidate
	HplTda5250Data.nc Tda5250RadioP.nc 
Log Message:
TDA5250 update for the new Msp430UartControl/Configure interfaces

Index: HplTda5250Data.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/chips/tda5250/HplTda5250Data.nc,v
retrieving revision 1.1.2.3
retrieving revision 1.1.2.3.10.1
diff -C2 -d -r1.1.2.3 -r1.1.2.3.10.1
*** HplTda5250Data.nc	1 Feb 2006 17:44:18 -0000	1.1.2.3
--- HplTda5250Data.nc	14 Jul 2006 21:38:51 -0000	1.1.2.3.10.1
***************
*** 61,65 ****
     *         FALSE otherwise.
     */
!   async command bool isTxDone();
  
    /**
--- 61,65 ----
     *         FALSE otherwise.
     */
!   //async command bool isTxDone();
  
    /**
***************
*** 70,103 ****
  
    /**
!    * Enable transmitting over the radio.
!    *
     * @return SUCCESS on success
     *         FAIL otherwise.
     */
!   async command error_t enableTx();
  
-   /**
-    * Disable transmitting over the radio
-    *
-    * @return SUCCESS on success
-    *         FAIL otherwise.
-    */
-   async command error_t disableTx();
  
    /**
!    * Enable receiving over the radio
     *
     * @return SUCCESS on success
     *         FAIL otherwise.
    */
!   async command error_t enableRx();
! 
!   /**
!    * Disable receiving over the radio
!    *
!    * @return SUCCESS on success
!    *         FAIL otherwise.
!    */
!   async command error_t disableRx();
  }
  
--- 70,88 ----
  
    /**
!    * Sets the radio to transmit. 
!    * 
     * @return SUCCESS on success
     *         FAIL otherwise.
     */
!   async command error_t setToTx();
  
  
    /**
!    * Sets the radio to receive.
     *
     * @return SUCCESS on success
     *         FAIL otherwise.
    */
!   async command error_t setToRx();
  }
  

Index: Tda5250RadioP.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/chips/tda5250/Tda5250RadioP.nc,v
retrieving revision 1.1.2.7
retrieving revision 1.1.2.7.4.1
diff -C2 -d -r1.1.2.7 -r1.1.2.7.4.1
*** Tda5250RadioP.nc	21 Jun 2006 14:45:10 -0000	1.1.2.7
--- Tda5250RadioP.nc	14 Jul 2006 21:38:51 -0000	1.1.2.7.4.1
***************
*** 51,54 ****
--- 51,55 ----
      interface Tda5250Control;
      interface RadioByteComm;
+     // ResourceRequest;
    }
    uses {
***************
*** 57,60 ****
--- 58,63 ----
      interface Resource as ConfigResource;
      interface Resource as DataResource;
+     //interface ResourceRequested as DataResourceRequest;
+     
      interface Alarm<T32khz, uint16_t> as DelayTimer;
    }
***************
*** 152,155 ****
--- 155,159 ----
              call HplTda5250Config.SetSlaveMode();
              call HplTda5250Config.SetTxMode();
+             call ConfigResource.release();
              atomic delayTimer = TRANSMITTER_DELAY;
              call DelayTimer.start(TDA5250_TRANSMITTER_SETUP_TIME);
***************
*** 158,161 ****
--- 162,166 ----
              call HplTda5250Config.SetSlaveMode();
              call HplTda5250Config.SetRxMode();
+             call ConfigResource.release();
              atomic delayTimer = RECEIVER_DELAY;
              call DelayTimer.start(TDA5250_RECEIVER_SETUP_TIME);
***************
*** 187,196 ****
          switch(mode) {
            case RADIO_MODE_TX_TRANSITION:
!             call HplTda5250Data.enableTx();
              atomic radioMode = RADIO_MODE_TX;
              signal Tda5250Control.TxModeDone();
              break;
            case RADIO_MODE_RX_TRANSITION:
!             call HplTda5250Data.enableRx();
              atomic radioMode = RADIO_MODE_RX;
              signal Tda5250Control.RxModeDone();
--- 192,201 ----
          switch(mode) {
            case RADIO_MODE_TX_TRANSITION:
!             call HplTda5250Data.setToTx();
              atomic radioMode = RADIO_MODE_TX;
              signal Tda5250Control.TxModeDone();
              break;
            case RADIO_MODE_RX_TRANSITION:
!             call HplTda5250Data.setToRx();
              atomic radioMode = RADIO_MODE_RX;
              signal Tda5250Control.RxModeDone();
***************
*** 204,207 ****
--- 209,217 ----
          switchDataResource();
        }
+       
+ //       async event void DataResourceRequest.requested() {
+ //         signal ResourceRequested.requested();
+ //       }
+ 
  
    /**
***************
*** 219,227 ****
          if(radioMode == RADIO_MODE_TIMER_TRANSITION) {
            call DataResource.release();
!           if (call ConfigResource.immediateRequest() == SUCCESS) {
!             switchConfigResource();
!           } else {
              call ConfigResource.request();
!           }
            return SUCCESS;
          }
--- 229,237 ----
          if(radioMode == RADIO_MODE_TIMER_TRANSITION) {
            call DataResource.release();
!          if (call ConfigResource.immediateRequest() == SUCCESS) {
!            switchConfigResource();
!          } else {
              call ConfigResource.request();
!          }
            return SUCCESS;
          }
***************
*** 294,299 ****
          }
          if(mode == RADIO_MODE_SLEEP_TRANSITION) {
-           call HplTda5250Data.disableTx();	
-           call HplTda5250Data.disableRx();	
            call DataResource.release();
            if (call ConfigResource.immediateRequest() == SUCCESS) {
--- 304,307 ----
***************
*** 365,369 ****
  
        async command bool RadioByteComm.isTxDone() {
!         return call HplTda5250Data.isTxDone();
        }
        
--- 373,378 ----
  
        async command bool RadioByteComm.isTxDone() {
!         //return call HplTda5250Data.isTxDone();
!         return TRUE;
        }
        
***************
*** 379,383 ****
              delayTimer = RSSISTABLE_DELAY;
              call DelayTimer.start(TDA5250_RSSI_STABLE_TIME-TDA5250_RECEIVER_SETUP_TIME);
-             call ConfigResource.release();
              if (call DataResource.immediateRequest() == SUCCESS) {
                switchDataResource();
--- 388,391 ----
***************
*** 387,392 ****
              break;
            case TRANSMITTER_DELAY :
!             call ConfigResource.release();
!             if (call DataResource.immediateRequest() == SUCCESS) {
                switchDataResource();
              } else {
--- 395,399 ----
              break;
            case TRANSMITTER_DELAY :
!            if (call DataResource.immediateRequest() == SUCCESS) {
                switchDataResource();
              } else {



More information about the Tinyos-2-commits mailing list