Repository navigation
Expand file tree
/
Copy pathMaxMatrixConfig.h
More file actions
67 lines (61 loc) · 3.96 KB
/
Copy pathMaxMatrixConfig.h
File metadata and controls
67 lines (61 loc) · 3.96 KB
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
/******************************************************************************************************************************************************
* COPYRIGHT
* ---------------------------------------------------------------------------------------------------------------------------------------------------
* \verbatim
* Copyright (c) Andreas Burnickl All rights reserved.
*
* \endverbatim
* ---------------------------------------------------------------------------------------------------------------------------------------------------
* FILE DESCRIPTION
* -------------------------------------------------------------------------------------------------------------------------------------------------*/
/** \file MaxMatrixConfig.h
* \brief Configuration of the MaxMatrix library
*
* \details The parameters every part of the library builds on: the size of the chain and how it is driven.
*
*****************************************************************************************************************************************************/
#ifndef _MAXMATRIX_CONFIG_H_
#define _MAXMATRIX_CONFIG_H_
/******************************************************************************************************************************************************
* INCLUDES
*****************************************************************************************************************************************************/
#include "MaxMatrixStandardTypes.h"
/******************************************************************************************************************************************************
* GLOBAL CONSTANT MACROS
*****************************************************************************************************************************************************/
/* MaxMatrix Configuration Parameter
* Each one can be given on the compiler command line instead, which is how the tests build both the bit banging and the
* SPI variant. The Arduino IDE does not pass a sketch's defines to a library, so for a sketch they are changed here. */
#ifndef MAXMATRIX_NUMBER_OF_MODULES
#define MAXMATRIX_NUMBER_OF_MODULES 4
#endif
#ifndef MAXMATRIX_USE_SPI
#define MAXMATRIX_USE_SPI STD_OFF
#endif
#ifndef MAXMATRIX_USE_DIGITAL_WRITE_FAST
#define MAXMATRIX_USE_DIGITAL_WRITE_FAST STD_OFF
#endif
#ifndef MAXMATRIX_SPI_CLOCK_SPEED
#define MAXMATRIX_SPI_CLOCK_SPEED 10000000 /* MAX7219 supports max. 10 MHz */
#endif
#ifndef MAXMATRIX_SPACE_BETWEEN_CHARS_INIT_VALUE
#define MAXMATRIX_SPACE_BETWEEN_CHARS_INIT_VALUE 1
#endif
#ifndef MAXMATRIX_INTENSITY_INIT_VALUE
#define MAXMATRIX_INTENSITY_INIT_VALUE 5
#endif
#ifndef MAXMATRIX_COMMAND_LINE_LENGTH
#define MAXMATRIX_COMMAND_LINE_LENGTH 64 /* chars of a command line, RAM twice over */
#endif
#ifndef MAXMATRIX_SHIFT_INTERVAL_INIT_VALUE
#define MAXMATRIX_SHIFT_INTERVAL_INIT_VALUE 50 /* ms per column, 0 for a step on every call */
#endif
/* MaxMatrix Parameter */
#define MAXMATRIX_COLUMN_NUMBER_OF_MODULE 8
#define MAXMATRIX_ROW_NUMBER_OF_MODULE 8
#define MAXMATRIX_NUMBER_OF_COLUMNS (MAXMATRIX_NUMBER_OF_MODULES * MAXMATRIX_COLUMN_NUMBER_OF_MODULE)
#define MAXMATRIX_BUFFER_SIZE MAXMATRIX_NUMBER_OF_COLUMNS
#endif
/******************************************************************************************************************************************************
* E N D O F F I L E
*****************************************************************************************************************************************************/