]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - tos/lib/tosboot/TOSBootM.nc
accelerometer cleanup
[tinyos-2.x.git] / tos / lib / tosboot / TOSBootM.nc
index fa1893c72c93f176fc4ee26fc672524e410d6871..b24b176223829e60fbe95d44632ca083a55ed524 100644 (file)
@@ -96,10 +96,11 @@ implementation {
   }
 
   bool verifyImage(ex_flash_addr_t startAddr) {
-    uint16_t addr;
+    uint32_t addr;
     uint8_t  numPgs;
     uint8_t  i;
 
+
     if (!verifyBlock(startAddr + offsetof(DelugeIdent,crc),
                     startAddr, offsetof(DelugeIdent,crc)))
       return FALSE;
@@ -118,9 +119,6 @@ implementation {
     for ( i = 0; i < numPgs; i++ ) {
       if (!verifyBlock(startAddr + i*sizeof(uint16_t),
                       startAddr + addr, DELUGE_BYTES_PER_PAGE)) {
-       if (i == 0)
-         while (1)
-           call Leds.flash(1);
        return FALSE;
       }
       addr += DELUGE_BYTES_PER_PAGE;
@@ -131,7 +129,7 @@ implementation {
 
   error_t programImage(ex_flash_addr_t startAddr) {
     uint8_t  buf[TOSBOOT_INT_PAGE_SIZE];
-    uint16_t pageAddr, newPageAddr;
+    uint32_t pageAddr, newPageAddr;
     in_flash_addr_t intAddr;
     in_flash_addr_t secLength;
     ex_flash_addr_t curAddr;
@@ -147,10 +145,12 @@ implementation {
     secLength = extFlashReadAddr();
     curAddr = curAddr + 8;
 
-#if defined(PLATFORM_TELOSB)
+#if defined(PLATFORM_TELOSB) || defined (PLATFORM_EPIC)
     if (intAddr != TOSBOOT_END) {
 #elif defined(PLATFORM_MICAZ) || defined(PLATFORM_IRIS)
     if (intAddr != 0) {
+#elif defined(PLATFORM_MULLE)
+    if (intAddr != 0xA0000) {
 #else
   #error "Target platform is not currently supported by Deluge T2"
 #endif