tinyusb  0.4
Click here to lend your support to tinyusb donation and make a donation at pledgie.com
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
nand.h
1 /*****************************************************************************
2  *
3  * Copyright(C) 2011, Embedded Artists AB
4  * All rights reserved.
5  *
6  ******************************************************************************
7  * Software that is described herein is for illustrative purposes only
8  * which provides customers with programming information regarding the
9  * products. This software is supplied "AS IS" without any warranties.
10  * Embedded Artists AB assumes no responsibility or liability for the
11  * use of the software, conveys no license or title under any patent,
12  * copyright, or mask work right to the product. Embedded Artists AB
13  * reserves the right to make changes in the software without
14  * notification. Embedded Artists AB also make no representation or
15  * warranty that such application will be suitable for the specified
16  * use without further testing or modification.
17  *****************************************************************************/
18 #ifndef __NAND_H
19 #define __NAND_H
20 
21 #define NAND_NUM_BLOCKS (1024)
22 
23 extern uint32_t nand_init (void);
24 extern uint32_t nand_getPageSize(void);
25 extern uint32_t nand_getBlockSize(void);
26 extern uint32_t nand_getRedundantSize(void);
27 extern uint32_t nand_isBlockValid(uint32_t blockNum);
28 uint32_t nand_readPage(uint32_t block, uint32_t page, uint8_t* pageBuf);
29 uint32_t nand_writePage(uint32_t block, uint32_t page, uint8_t* pageBuf);
30 uint32_t nand_eraseBlock(uint32_t block);
31 
32 
33 #endif /* end __NAND_H */
34 /****************************************************************************
35 ** End Of File
36 *****************************************************************************/