[Tinyos-beta-commits] CVS: tinyos-1.x/beta/STM25P/TestStorage
Makefile, NONE, 1.1 TestFormatStorage.nc, NONE,
1.1 TestFormatStorageM.nc, NONE, 1.1
Jonathan Hui
jwhui at users.sourceforge.net
Fri Mar 11 13:44:14 PST 2005
- Previous message: [Tinyos-beta-commits]
CVS: tinyos-1.x/beta/STM25P BlockRead.nc, 1.3,
NONE BlockStorage.h, 1.2, NONE BlockStorageC.nc, 1.3,
NONE BlockStorageM.nc, 1.5, NONE BlockWrite.nc, 1.2,
NONE FlashWP.nc, 1.1, NONE FlashWPC.nc, 1.2, NONE FlashWPM.nc,
1.3, NONE HALSTM25P.h, 1.1, NONE HALSTM25P.nc, 1.1,
NONE HALSTM25PC.nc, 1.1, NONE HALSTM25PM.nc, 1.1,
NONE HPLSTM25P.nc, 1.2, NONE Mount.nc, 1.1, NONE Storage.h,
1.1, NONE StorageManager.h, 1.1, NONE StorageManagerC.nc, 1.1,
NONE StorageManagerM.nc, 1.2, NONE StorageRemap.nc, 1.1, NONE
- Next message: [Tinyos-beta-commits] CVS: tinyos-1.x/beta/STM25P/STM25P
BlockRead.nc, NONE, 1.1 BlockStorage.h, NONE,
1.1 BlockStorageC.nc, NONE, 1.1 BlockStorageM.nc, NONE,
1.1 BlockWrite.nc, NONE, 1.1 FlashWP.nc, NONE, 1.1 FlashWPC.nc,
NONE, 1.1 FlashWPM.nc, NONE, 1.1 FormatStorage.nc, NONE,
1.1 FormatStorageC.nc, NONE, 1.1 FormatStorageM.nc, NONE,
1.1 HALSTM25P.h, NONE, 1.1 HALSTM25P.nc, NONE,
1.1 HALSTM25PC.nc, NONE, 1.1 HALSTM25PM.nc, NONE,
1.1 HPLSTM25P.nc, NONE, 1.1 LogRead.nc, NONE, 1.1 LogStorage.h,
NONE, 1.1 LogStorageC.nc, NONE, 1.1 LogStorageM.nc, NONE,
1.1 LogWrite.nc, NONE, 1.1 Mount.nc, NONE,
1.1 SectorStorage.nc, NONE, 1.1 Storage.h, NONE,
1.1 StorageManager.nc, NONE, 1.1 StorageManagerC.nc, NONE,
1.1 StorageManagerM.nc, NONE, 1.1 StorageRemap.nc, NONE,
1.1 Storage_chip.h, NONE, 1.1
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/tinyos/tinyos-1.x/beta/STM25P/TestStorage
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25492/TestStorage
Added Files:
Makefile TestFormatStorage.nc TestFormatStorageM.nc
Log Message:
- This directory contains the storage stack implementation for the
STM25P family of chips. The implementation follows proposed TinyOS
Storage Abstraction being introduced in TinyOS 2.x and detailed in
tep103.
- The new storage stack now requires formatting the flash before it
can be used. The flash is partitioned into segments with size equal to
a multiple of STORAGE_BLOCK_SIZE. An example for formating the flash
is included in beta/STM25P/TestStorage/.
- Implementation Status:
- BlockStorage: nearly complete except commit()/verify(). Well
tested under Deluge.
- LogStorage: nearly complete except seek()/sync(). Limited testing.
- ConfigStorage: not implemented
--- NEW FILE: Makefile ---
#COMPONENT?=TestLogStorage
#COMPONENT?=TestBlockStorage
COMPONENT?=TestFormatStorage
#COMPONENT?=TestHALSTM25P
#COMPONENT?=TestStorageManager
include $(TOSDIR)/../apps/Makerules
--- NEW FILE: TestFormatStorage.nc ---
// $Id: TestFormatStorage.nc,v 1.1 2005/03/11 21:44:11 jwhui Exp $
/* tab:2
* "Copyright (c) 2000-2004 The Regents of the University of California.
* All rights reserved.
*
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without written agreement 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
* AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
* ON AN "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO
* PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS."
*/
/*
* @author: Jonathan Hui <jwhui at cs.berkeley.edu>
*/
configuration TestFormatStorage {
}
implementation {
components Main, TestFormatStorageM, FormatStorageC, TimerC, LedsC;
Main.StdControl -> TestFormatStorageM;
Main.StdControl -> TimerC;
TestFormatStorageM.FormatStorage -> FormatStorageC;
TestFormatStorageM.Leds -> LedsC;
TestFormatStorageM.Timer -> TimerC.Timer[unique("Timer")];
}
--- NEW FILE: TestFormatStorageM.nc ---
// $Id: TestFormatStorageM.nc,v 1.1 2005/03/11 21:44:11 jwhui Exp $
/* tab:2
* "Copyright (c) 2000-2004 The Regents of the University of California.
* All rights reserved.
*
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without written agreement 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
* AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
* ON AN "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO
* PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS."
*/
/*
* @author: Jonathan Hui <jwhui at cs.berkeley.edu>
*/
module TestFormatStorageM {
provides {
interface StdControl;
}
uses {
interface FormatStorage;
interface Leds;
interface Timer;
}
}
implementation {
command result_t StdControl.init() {
call Leds.init();
return SUCCESS;
}
command result_t StdControl.start() {
call Timer.start(TIMER_ONE_SHOT, 1024);
return SUCCESS;
}
command result_t StdControl.stop() {
return SUCCESS;
}
event result_t Timer.fired() {
result_t result;
call Leds.yellowOn();
result = call FormatStorage.init();
result = rcombine(call FormatStorage.allocate(0xD0, STORAGE_BLOCK_SIZE), result);
result = rcombine(call FormatStorage.allocate(0xD1, STORAGE_BLOCK_SIZE), result);
result = rcombine(call FormatStorage.allocateFixed(0xDF, 0xF0000, STORAGE_BLOCK_SIZE), result);
result = rcombine(call FormatStorage.commit(), result);
if (result != SUCCESS)
call Leds.yellowOff();
return SUCCESS;
}
event void FormatStorage.commitDone(storage_result_t result) {
if (result == STORAGE_OK)
call Leds.greenOn();
else
call Leds.redOn();
}
}
- Previous message: [Tinyos-beta-commits]
CVS: tinyos-1.x/beta/STM25P BlockRead.nc, 1.3,
NONE BlockStorage.h, 1.2, NONE BlockStorageC.nc, 1.3,
NONE BlockStorageM.nc, 1.5, NONE BlockWrite.nc, 1.2,
NONE FlashWP.nc, 1.1, NONE FlashWPC.nc, 1.2, NONE FlashWPM.nc,
1.3, NONE HALSTM25P.h, 1.1, NONE HALSTM25P.nc, 1.1,
NONE HALSTM25PC.nc, 1.1, NONE HALSTM25PM.nc, 1.1,
NONE HPLSTM25P.nc, 1.2, NONE Mount.nc, 1.1, NONE Storage.h,
1.1, NONE StorageManager.h, 1.1, NONE StorageManagerC.nc, 1.1,
NONE StorageManagerM.nc, 1.2, NONE StorageRemap.nc, 1.1, NONE
- Next message: [Tinyos-beta-commits] CVS: tinyos-1.x/beta/STM25P/STM25P
BlockRead.nc, NONE, 1.1 BlockStorage.h, NONE,
1.1 BlockStorageC.nc, NONE, 1.1 BlockStorageM.nc, NONE,
1.1 BlockWrite.nc, NONE, 1.1 FlashWP.nc, NONE, 1.1 FlashWPC.nc,
NONE, 1.1 FlashWPM.nc, NONE, 1.1 FormatStorage.nc, NONE,
1.1 FormatStorageC.nc, NONE, 1.1 FormatStorageM.nc, NONE,
1.1 HALSTM25P.h, NONE, 1.1 HALSTM25P.nc, NONE,
1.1 HALSTM25PC.nc, NONE, 1.1 HALSTM25PM.nc, NONE,
1.1 HPLSTM25P.nc, NONE, 1.1 LogRead.nc, NONE, 1.1 LogStorage.h,
NONE, 1.1 LogStorageC.nc, NONE, 1.1 LogStorageM.nc, NONE,
1.1 LogWrite.nc, NONE, 1.1 Mount.nc, NONE,
1.1 SectorStorage.nc, NONE, 1.1 Storage.h, NONE,
1.1 StorageManager.nc, NONE, 1.1 StorageManagerC.nc, NONE,
1.1 StorageManagerM.nc, NONE, 1.1 StorageRemap.nc, NONE,
1.1 Storage_chip.h, NONE, 1.1
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the Tinyos-beta-commits
mailing list