1 | /*
|
---|
2 | * WRBB Main
|
---|
3 | *
|
---|
4 | * Copyright (c) 2015 Minao Yamamoto
|
---|
5 | *
|
---|
6 | * This software is released under the MIT License.
|
---|
7 | *
|
---|
8 | * http://opensource.org/licenses/mit-license.php
|
---|
9 | *
|
---|
10 | * Light weight Lanuage Board Ruby
|
---|
11 | * Wakayamarb board
|
---|
12 | *
|
---|
13 | */
|
---|
14 | #ifndef _LLBRUBY_H_
|
---|
15 | #define _LLBRUBY_H_ 1
|
---|
16 |
|
---|
17 | #define RUBY_CODE_SIZE (1024 * 4) //4kBã¾ã§å®è¡å¯è½ã¨ãã
|
---|
18 |
|
---|
19 | //ãã¤ãã³ã¼ããã¼ã¸ã§ã³ãå®ç¾©ãã¾ã
|
---|
20 | #define BYTE_CODE2 2
|
---|
21 | #define BYTE_CODE3 3
|
---|
22 |
|
---|
23 | //ãã¡ã¼ã ã¦ã§ã¢ã®ãã¼ã¸ã§ã³ãå®ç¾©ãã¾ã
|
---|
24 | #define MASTER 1000
|
---|
25 | #define JAM 1001
|
---|
26 | #define SDBT 1002
|
---|
27 | #define SDWF 1003
|
---|
28 |
|
---|
29 |
|
---|
30 | //åºæ¿ã®è¨è¨ãã¼ã¸ã§ã³ãå®ç¾©ãã¾ã
|
---|
31 | #define BOARD_GR 0
|
---|
32 | #define BOARD_P01 1
|
---|
33 | #define BOARD_P02 2
|
---|
34 | #define BOARD_P03 3
|
---|
35 | #define BOARD_P04 4
|
---|
36 |
|
---|
37 |
|
---|
38 | //ãã¤ãã³ã¼ããã©ã¼ãããã®è¨å®
|
---|
39 | #define BYTECODE BYTE_CODE3
|
---|
40 |
|
---|
41 | //åºæ¿ã®ã¿ã¤ãè¨å®
|
---|
42 | #define BOARD BOARD_GR
|
---|
43 |
|
---|
44 | //ãã¡ã¼ã ã¦ã§ã¢è¨å®
|
---|
45 | #define FIRMWARE MASTER
|
---|
46 | //#define FIRMWARE JAM
|
---|
47 | //#define FIRMWARE SDBT
|
---|
48 | //#define FIRMWARE SDWF
|
---|
49 |
|
---|
50 | //#define DEBUG 1 // Define if you want to debug
|
---|
51 |
|
---|
52 | #ifdef DEBUG
|
---|
53 | # define DEBUG_PRINT(m,v) { Serial.print("** "); Serial.print((m)); Serial.print(":"); Serial.println((v)); }
|
---|
54 | #else
|
---|
55 | # define DEBUG_PRINT(m,v) // do nothing
|
---|
56 | #endif
|
---|
57 |
|
---|
58 | #define FILE_LOAD PORT3.PIDR.BIT.B5 //PORT 3-5
|
---|
59 |
|
---|
60 | #define XML_FILENAME "wrbb.xml"
|
---|
61 | #define RUBY_FILENAME "main.mrb"
|
---|
62 | #define RUBY_FILENAME_SIZE 32
|
---|
63 |
|
---|
64 | #define REALTIMECLOCK 1
|
---|
65 |
|
---|
66 | #if BYTECODE == BYTE_CODE2
|
---|
67 | #if FIRMWARE == MASTER
|
---|
68 | #define WRBB_VERSION "SakuRuby-1.13(2015/7/19)f2"
|
---|
69 | #elif FIRMWARE == JAM
|
---|
70 | #define WRBB_VERSION "SakuraJam-1.13(2015/7/19)f2"
|
---|
71 | #endif
|
---|
72 | #elif BYTECODE == BYTE_CODE3
|
---|
73 | #if FIRMWARE == MASTER
|
---|
74 | #define WRBB_VERSION "SakuRuby-1.30(2015/12/19)f3"
|
---|
75 | #elif FIRMWARE == JAM
|
---|
76 | #define WRBB_VERSION "SakuraJam-1.30(2015/12/19)f3"
|
---|
77 | #endif
|
---|
78 | #endif
|
---|
79 |
|
---|
80 | #define RB_PIN0 0
|
---|
81 | #define RB_PIN1 1
|
---|
82 | #define RB_PIN18 18
|
---|
83 | #define RB_PIN19 19
|
---|
84 | #define RB_PIN2 2
|
---|
85 | #define RB_PIN3 3
|
---|
86 | #define RB_PIN4 4
|
---|
87 | #define RB_PIN5 5
|
---|
88 | #define RB_PIN6 6
|
---|
89 | #define RB_PIN7 7
|
---|
90 | #define RB_PIN8 8
|
---|
91 | #define RB_PIN9 9
|
---|
92 | #define RB_PIN10 10
|
---|
93 | #define RB_PIN11 11
|
---|
94 | #define RB_PIN12 12
|
---|
95 | #define RB_PIN13 13
|
---|
96 | #define RB_PIN14 14
|
---|
97 | #define RB_PIN15 15
|
---|
98 | #define RB_PIN16 16
|
---|
99 | #define RB_PIN17 17
|
---|
100 |
|
---|
101 | #define RB_PIN20 20
|
---|
102 | #define RB_PIN21 21
|
---|
103 | #define RB_PIN22 22
|
---|
104 | #define RB_PIN23 23
|
---|
105 | #define RB_PIN24 24
|
---|
106 | #define RB_PIN25 25
|
---|
107 |
|
---|
108 | #define PIN_LED0 LED1
|
---|
109 | #define PIN_LED1 LED2
|
---|
110 | #define PIN_LED2 LED3
|
---|
111 | #define PIN_LED3 LED4
|
---|
112 | #define RB_LED PIN_LED0
|
---|
113 |
|
---|
114 |
|
---|
115 | #endif // _LLBRUBY_H_
|
---|
116 |
|
---|