[Tinyos-contrib-commits] CVS: tinyos-1.x/contrib/handhelds/apps/MOBIUS/AnEx AnExM.nc, 1.1, 1.2

steve ayer ayer1 at users.sourceforge.net
Wed Dec 19 07:35:51 PST 2007


Update of /cvsroot/tinyos/tinyos-1.x/contrib/handhelds/apps/MOBIUS/AnEx
In directory sc8-pr-cvs10.sourceforge.net:/tmp/cvs-serv12943/AnEx

Modified Files:
	AnExM.nc 
Log Message:

all files:
---------
bluetooth api updates used: disableRemoteConfig() and setBaudrate().

xt2 bug fixes added (bcsctl2 init) 
dma transfer bug fix (changed dmadt_5, repeat, to dmadt_1, single
transfer).

SixAxisCmdCtrlM.nc only:
-----------------------
fixed datatype mismatch bug in sample frequency change routine.


Index: AnExM.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-1.x/contrib/handhelds/apps/MOBIUS/AnEx/AnExM.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** AnExM.nc	19 Nov 2007 18:51:03 -0000	1.1
--- AnExM.nc	19 Dec 2007 15:35:49 -0000	1.2
***************
*** 124,128 ****
  
    norace uint8_t current_buffer = 0, dma_blocks = 0;
!   uint16_t sbuf0[36], sbuf1[36], wheressbuf0, timestamp0, timestamp1;
  
    /* default sample frequency every time the sensor boots up */
--- 124,128 ----
  
    norace uint8_t current_buffer = 0, dma_blocks = 0;
!   uint16_t sbuf0[36], sbuf1[36], timestamp0, timestamp1;
  
    /* default sample frequency every time the sensor boots up */
***************
*** 155,160 ****
      call DMA0.setBlockSize(3);
  
!     // we want block transfer, repeated
!     DMA0CTL = DMADT_5 + DMADSTINCR_3 + DMASRCINCR_3;
    }
  
--- 155,160 ----
      call DMA0.setBlockSize(3);
  
!     // we want block transfer, single
!     DMA0CTL = DMADT_1 + DMADSTINCR_3 + DMASRCINCR_3;
    }
  
***************
*** 205,210 ****
      register uint8_t i;
  
-     wheressbuf0 = (uint16_t)&sbuf0;
- 
      atomic CLR_FLAG(BCSCTL1, XT2OFF); // basic clock system control reg, turn off XT2 osc
  
--- 205,208 ----
***************
*** 222,226 ****
      call Leds.yellowOn();
      TOSH_uwait(50000UL);
!     atomic SET_FLAG(BCSCTL2, SELM_2);
      
      call Leds.yellowOff();
--- 220,228 ----
      call Leds.yellowOn();
      TOSH_uwait(50000UL);
! 
!     atomic{ 
!       BCSCTL2 = 0; 
!       SET_FLAG(BCSCTL2, SELM_2); /* select master clock source, XT2CLK when XT2 oscillator present */
!     }                            /*on-chip. LFXT1CLK when XT2 oscillator not present on-chip. */
      
      call Leds.yellowOff();
***************
*** 255,258 ****
--- 257,264 ----
      }
      call BTStdControl.init();
+     call Bluetooth.disableRemoteConfig(TRUE);
+      /* if CPU=8Mhz then customise roving networks baudrate to suit 8Mhz/9 baud */
+     call Bluetooth.setBaudrate("452");    
+ 
      dma_blocks = 0;
      return SUCCESS;
***************
*** 531,534 ****
--- 537,541 ----
  
    event result_t SampleTimer.fired() {
+     call DMA0.beginTransfer();
      call DMA0.ADCbeginConversion();
      return SUCCESS;



More information about the Tinyos-contrib-commits mailing list