[Tinyos-2-commits] CVS: tinyos-2.x/tos/lib/serial SerialDispatcherC.nc, 1.1.2.9, 1.1.2.10 Serial.h, 1.1.2.13, 1.1.2.14 SerialP.nc, 1.1.2.11, 1.1.2.12 SerialAMImplP.nc, 1.1.2.3, NONE

Philipp Huppertz phihup at users.sourceforge.net
Thu Aug 3 11:21:10 PDT 2006


Update of /cvsroot/tinyos/tinyos-2.x/tos/lib/serial
In directory sc8-pr-cvs10.sourceforge.net:/tmp/cvs-serv28274/tos/lib/serial

Modified Files:
      Tag: tinyos-2_0_devel-BRANCH
	SerialDispatcherC.nc Serial.h SerialP.nc 
Removed Files:
      Tag: tinyos-2_0_devel-BRANCH
	SerialAMImplP.nc 
Log Message:
- updated lib/serial from tos-2-msp430-usart-configure-candidate


Index: SerialDispatcherC.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/serial/SerialDispatcherC.nc,v
retrieving revision 1.1.2.9
retrieving revision 1.1.2.10
diff -C2 -d -r1.1.2.9 -r1.1.2.10
*** SerialDispatcherC.nc	2 Oct 2005 22:08:02 -0000	1.1.2.9
--- SerialDispatcherC.nc	3 Aug 2006 18:21:08 -0000	1.1.2.10
***************
*** 1,5 ****
  //$Id$
  
! /* "Copyright (c) 2005 The Regents of the University of California.  
   * All rights reserved.
   *
--- 1,5 ----
  //$Id$
  
! /* "Copyright (c) 2005 The Regents of the University of California.
   * All rights reserved.
   *
***************
*** 8,17 ****
   * is hereby granted, provided that the above copyright notice, the following
   * two paragraphs and the author appear in all copies of this software.
!  * 
   * IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR
   * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT
   * OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY
   * OF CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
!  * 
   * THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
   * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
--- 8,17 ----
   * is hereby granted, provided that the above copyright notice, the following
   * two paragraphs and the author appear in all copies of this software.
!  *
   * IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR
   * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT
   * OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY
   * OF CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
!  *
   * THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
   * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
***************
*** 47,61 ****
  }
  implementation {
!   components SerialP, new SerialDispatcherP(), 
!     HdlcTranslateC, 
      PlatformSerialC;
!   
    Send = SerialDispatcherP;
    Receive = SerialDispatcherP;
    SerialPacketInfo = SerialDispatcherP.PacketInfo;
    SplitControl = SerialP;
!   
    Init = SerialP;
-   Init = PlatformSerialC;
    Leds = SerialP;
    Leds = SerialDispatcherP;
--- 47,60 ----
  }
  implementation {
!   components SerialP, new SerialDispatcherP(),
!     HdlcTranslateC,
      PlatformSerialC;
! 
    Send = SerialDispatcherP;
    Receive = SerialDispatcherP;
    SerialPacketInfo = SerialDispatcherP.PacketInfo;
    SplitControl = SerialP;
! 
    Init = SerialP;
    Leds = SerialP;
    Leds = SerialDispatcherP;
***************
*** 64,72 ****
    SerialDispatcherP.ReceiveBytePacket -> SerialP;
    SerialDispatcherP.SendBytePacket -> SerialP;
!   
    SerialP.SerialFrameComm -> HdlcTranslateC;
    SerialP.SerialControl -> PlatformSerialC;
!   
    HdlcTranslateC.SerialByteComm -> PlatformSerialC;
!   
  }
--- 63,71 ----
    SerialDispatcherP.ReceiveBytePacket -> SerialP;
    SerialDispatcherP.SendBytePacket -> SerialP;
! 
    SerialP.SerialFrameComm -> HdlcTranslateC;
    SerialP.SerialControl -> PlatformSerialC;
! 
    HdlcTranslateC.SerialByteComm -> PlatformSerialC;
! 
  }

Index: Serial.h
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/serial/Serial.h,v
retrieving revision 1.1.2.13
retrieving revision 1.1.2.14
diff -C2 -d -r1.1.2.13 -r1.1.2.14
*** Serial.h	27 Jun 2006 20:32:19 -0000	1.1.2.13
--- Serial.h	3 Aug 2006 18:21:08 -0000	1.1.2.14
***************
*** 90,96 ****
  // Framer-level dispatch
  enum {
!   SERIAL_PROTO_ACK = 67,
!   SERIAL_PROTO_PACKET_ACK = 68,
!   SERIAL_PROTO_PACKET_NOACK = 69,
    SERIAL_PROTO_PACKET_UNKNOWN = 255
  };
--- 90,96 ----
  // Framer-level dispatch
  enum {
!   SERIAL_PROTO_ACK = 64,
!   SERIAL_PROTO_PACKET_ACK = 65,
!   SERIAL_PROTO_PACKET_NOACK = 66,
    SERIAL_PROTO_PACKET_UNKNOWN = 255
  };

Index: SerialP.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/serial/SerialP.nc,v
retrieving revision 1.1.2.11
retrieving revision 1.1.2.12
diff -C2 -d -r1.1.2.11 -r1.1.2.12
*** SerialP.nc	16 Jun 2006 18:09:07 -0000	1.1.2.11
--- SerialP.nc	3 Aug 2006 18:21:08 -0000	1.1.2.12
***************
*** 671,674 ****
--- 671,676 ----
        case TXSTATE_INFO:
          atomic {
+           uint8_t nextByte;
+ 
            txResult = call SerialFrameComm.putData(txBuf[txIndex].buf);
            txCRC = crcByte(txCRC,txBuf[txIndex].buf);
***************
*** 676,691 ****
            
            if (txIndex == TX_DATA_INDEX){
-             uint8_t nextByte;
              nextByte = signal SendBytePacket.nextByte();
-             if (txBuf[txIndex].state == BUFFER_COMPLETE || txByteCnt >= SERIAL_MTU){
-               txState = TXSTATE_FCS1;
-             }
-             else { /* never called on ack b/c ack is BUFFER_COMPLETE initially */
-               txBuf[txIndex].buf = nextByte;
-             }
            }
!           else { // TX_ACK_INDEX
              txState = TXSTATE_FCS1;
            }
          }
          break;
--- 678,689 ----
            
            if (txIndex == TX_DATA_INDEX){
              nextByte = signal SendBytePacket.nextByte();
            }
!           if (txBuf[txIndex].state == BUFFER_COMPLETE || txByteCnt >= SERIAL_MTU){
              txState = TXSTATE_FCS1;
            }
+           else { /* never called on ack b/c ack is BUFFER_COMPLETE initially */
+             txBuf[txIndex].buf = nextByte;
+           }
          }
          break;

--- SerialAMImplP.nc DELETED ---



More information about the Tinyos-2-commits mailing list