-
Notifications
You must be signed in to change notification settings - Fork 0
/
Small_NAND_Test.h
49 lines (41 loc) · 1.83 KB
/
Small_NAND_Test.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
/*
* IncFile1.h
*
* Created: 3/9/2018 6:04:58 PM
* Author: kmcarrin
*/
#ifndef SMALL_NAND_TEST_H_
#define SMALL_NAND_TEST_H_
#include "NAND_Flash.h"
#include "usb_start.h"
#define TEST_DATA_SIZE (10240) /* 5 pages (2048 * 5) */
#define NUM_TEST_BLOCKS (5) /* Number of blocks to write data to total. */
/*************************************************************
* STRINGS
* ------------------------------------------------------------
* These strings are used for input and output messages that
* are printed to a PC console over serial connection.
**************************************************************/
/*************************************************************
* TEST DATA
* ------------------------------------------------------------
* This array contains test data that will be written to the
* flash device. The data was randomly generated by a script
* before it was added to the array. The amount of data is
* given by TEST_DATA_SIZE, which is adjustable. To make this
* data set larger or smaller, the value of TEST_DATA_SIZE must
* be edited in the define above as well as in the script that
* generates these values.
**************************************************************/
extern uint8_t TEST_DATA[TEST_DATA_SIZE];
uint8_t small_nand_test_driver();
/*************************************************************
* FUNCTION: nand_test_load_data()
* -----------------------------------------------------------
* This function loads a page of data based on the PAGE_SIZE.
* Data is taken from a static TEST_DATA array containing
* TEST_DATA_SIZE elements. The value of TEST_DATA_SIZE must
* be greater than PAGE_SIZE.
*************************************************************/
void small_nand_test_load_data(uint8_t page[], const int PAGE_SIZE);
#endif /* SMALL_NAND_TEST_H_ */