Richard Wackerbarth преди 9 години
родител
ревизия
4683645036

+ 284
- 0
ArduinoAddons/Arduino_1.6.x/hardware/marlin/avr/boards.txt Целия файл

@@ -0,0 +1,284 @@
1
+# See: https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5---3rd-party-Hardware-specification
2
+# See: http://code.google.com/p/arduino/wiki/Platforms
3
+
4
+##############################################################
5
+
6
+menu.cpu=Processor
7
+
8
+########################################
9
+## Arduino Mega or Mega 2560
10
+########################################
11
+
12
+mega.name=Arduino Mega or Mega 2560
13
+
14
+mega.vid.0=0x2341
15
+mega.pid.0=0x0010
16
+mega.vid.1=0x2341
17
+mega.pid.1=0x0042
18
+mega.vid.2=0x2A03
19
+mega.pid.2=0x0010
20
+mega.vid.3=0x2A03
21
+mega.pid.3=0x0042
22
+
23
+mega.upload.tool=avrdude
24
+mega.upload.maximum_data_size=8192
25
+
26
+mega.bootloader.tool=avrdude
27
+mega.bootloader.low_fuses=0xFF
28
+mega.bootloader.unlock_bits=0x3F
29
+mega.bootloader.lock_bits=0x0F
30
+
31
+mega.build.f_cpu=16000000L
32
+mega.build.core=arduino
33
+mega.build.variant=mega
34
+# default board  may be overridden by the cpu menu
35
+mega.build.board=AVR_MEGA2560
36
+mega.build.mcu=atmega2560
37
+
38
+## Arduino Mega w/ ATmega2560
39
+## -------------------------
40
+mega.menu.cpu.atmega2560=ATmega2560 (Mega 2560)
41
+
42
+mega.menu.cpu.atmega2560.upload.protocol=wiring
43
+mega.menu.cpu.atmega2560.upload.maximum_size=253952
44
+mega.menu.cpu.atmega2560.upload.speed=115200
45
+
46
+mega.menu.cpu.atmega2560.bootloader.high_fuses=0xD8
47
+mega.menu.cpu.atmega2560.bootloader.extended_fuses=0xFD
48
+mega.menu.cpu.atmega2560.bootloader.file=stk500v2/stk500boot_v2_mega2560.hex
49
+
50
+mega.menu.cpu.atmega2560.build.mcu=atmega2560
51
+mega.menu.cpu.atmega2560.build.board=AVR_MEGA2560
52
+
53
+## Arduino Mega w/ ATmega1280
54
+## -------------------------
55
+mega.menu.cpu.atmega1280=ATmega1280
56
+
57
+mega.menu.cpu.atmega1280.upload.protocol=arduino
58
+mega.menu.cpu.atmega1280.upload.maximum_size=126976
59
+mega.menu.cpu.atmega1280.upload.speed=57600
60
+
61
+mega.menu.cpu.atmega1280.bootloader.high_fuses=0xDA
62
+mega.menu.cpu.atmega1280.bootloader.extended_fuses=0xF5
63
+mega.menu.cpu.atmega1280.bootloader.file=atmega/ATmegaBOOT_168_atmega1280.hex
64
+
65
+mega.menu.cpu.atmega1280.build.mcu=atmega1280
66
+mega.menu.cpu.atmega1280.build.board=AVR_MEGA
67
+
68
+########################################
69
+## RAMBo
70
+########################################
71
+rambo.name=RAMBo
72
+
73
+rambo.upload.tool=arduino:avrdude
74
+rambo.upload.protocol=wiring
75
+rambo.upload.maximum_size=258048
76
+rambo.upload.speed=115200
77
+
78
+rambo.bootloader.low_fuses=0xFF
79
+rambo.bootloader.high_fuses=0xD8
80
+rambo.bootloader.extended_fuses=0xFD
81
+rambo.bootloader.path=stk500v2
82
+rambo.bootloader.file=stk500boot_v2_mega2560.hex
83
+rambo.bootloader.unlock_bits=0x3F
84
+rambo.bootloader.lock_bits=0x0F
85
+
86
+rambo.build.mcu=atmega2560
87
+rambo.build.f_cpu=16000000L
88
+rambo.build.board=AVR_RAMBO
89
+rambo.build.core=arduino:arduino
90
+rambo.build.variant=rambo
91
+
92
+########################################
93
+## Sanguino
94
+########################################
95
+sanguino.name=Sanguino
96
+
97
+sanguino.upload.tool=arduino:avrdude
98
+sanguino.upload.protocol=stk500
99
+sanguino.upload.maximum_size=131072
100
+sanguino.upload.speed=57600
101
+
102
+sanguino.bootloader.low_fuses=0xD6
103
+sanguino.bootloader.high_fuses=0xDA
104
+sanguino.bootloader.extended_fuses=0xFD
105
+sanguino.bootloader.path=atmega
106
+sanguino.bootloader.unlock_bits=0x3F
107
+sanguino.bootloader.lock_bits=0x0F
108
+
109
+sanguino.build.mcu=atmega1284p
110
+sanguino.build.f_cpu=16000000L
111
+sanguino.build.board=AVR_SANGUINO
112
+sanguino.build.core=arduino:arduino
113
+sanguino.build.variant=sanguino
114
+
115
+sanguino.menu.cpu.atmega644=ATmega644P
116
+sanguino.menu.cpu.atmega644.upload.maximum_size=63488
117
+sanguino.menu.cpu.atmega644.bootloader.low_fuses=0xFF
118
+sanguino.menu.cpu.atmega644.bootloader.high_fuses=0x9A
119
+sanguino.menu.cpu.atmega644.bootloader.extended_fuses=0xFF
120
+sanguino.menu.cpu.atmega644.bootloader.file=ATmegaBOOT_168_atmega644p.hex
121
+sanguino.menu.cpu.atmega644.build.mcu=atmega644p
122
+
123
+sanguino.menu.cpu.atmega12848m=ATmega1284p 8MHz
124
+sanguino.menu.cpu.atmega12848m.upload.speed=19200
125
+sanguino.menu.cpu.atmega12848m.bootloader.file=ATmegaBOOT_168_atmega1284p_8m.hex
126
+sanguino.menu.cpu.atmega12848m.build.f_cpu=8000000L
127
+
128
+sanguino.menu.cpu.atmega1284=ATmega1284p 16MHz
129
+sanguino.menu.cpu.atmega1284.bootloader.file=ATmegaBOOT_168_atmega1284p.hex
130
+
131
+sanguino.menu.cpu.atmega1284m=ATmega1284p 20MHz
132
+sanguino.menu.cpu.atmega1284m.bootloader.file=ATmegaBOOT_168_atmega1284p.hex
133
+sanguino.menu.cpu.atmega1284m.build.f_cpu=20000000L
134
+
135
+########################################
136
+## Brainwave
137
+########################################
138
+Brainwave.name=Brainwave
139
+
140
+Brainwave.bootloader.tool=avrdude
141
+Brainwave.bootloader.low_fuses=0xFF
142
+Brainwave.bootloader.high_fuses=0x99
143
+Brainwave.bootloader.extended_fuses=0xF0
144
+Brainwave.bootloader.unlock_bits=0x3F
145
+Brainwave.bootloader.lock_bits=0x02F
146
+Brainwave.bootloader.path=brainwave
147
+Brainwave.bootloader.file=Brainwave-646-LUFA.hex
148
+
149
+Brainwave.upload.tool=avrdude
150
+Brainwave.upload.protocol=avr109
151
+Brainwave.upload.maximum_size=61440
152
+Brainwave.upload.speed=115200
153
+Brainwave.upload.disable_flushing=true
154
+
155
+Brainwave.build.mcu=at90usb646
156
+Brainwave.build.f_cpu=16000000L
157
+Brainwave.build.board=AVR_BRAINWAVE
158
+Brainwave.build.core=at90usb
159
+Brainwave.build.dependency=true
160
+Brainwave.build.variant=brainwave
161
+Brainwave.build.vid=0x16D0
162
+Brainwave.build.pid=0x076B
163
+
164
+########################################
165
+## BrainwavePro (CDC)
166
+########################################
167
+BrainwavePro.name=Brainwave Pro (CDC)
168
+
169
+BrainwavePro.bootloader.tool=avrdude
170
+BrainwavePro.bootloader.low_fuses=0xFF
171
+BrainwavePro.bootloader.high_fuses=0x9B
172
+BrainwavePro.bootloader.extended_fuses=0xF0
173
+BrainwavePro.bootloader.unlock_bits=0x3F
174
+BrainwavePro.bootloader.lock_bits=0x02F
175
+BrainwavePro.bootloader.path=at90usb
176
+BrainwavePro.bootloader.file=BrainwavePro-1286-LUFA.hex
177
+
178
+BrainwavePro.upload.tool=avrdude
179
+BrainwavePro.upload.protocol=avr109
180
+BrainwavePro.upload.maximum_size=126976
181
+BrainwavePro.upload.speed=115200
182
+BrainwavePro.upload.disable_flushing=true
183
+
184
+BrainwavePro.build.mcu=at90usb1286
185
+BrainwavePro.build.f_cpu=16000000L
186
+BrainwavePro.build.board=AVR_BRAINWAVEPRO
187
+BrainwavePro.build.core=at90usb
188
+BrainwavePro.build.dependency=true
189
+BrainwavePro.build.variant=at90usb
190
+BrainwavePro.build.vid=0x16D0
191
+BrainwavePro.build.pid=0x076B
192
+BrainwavePro.build.extra_flags=-DAT90USBxx_TEENSYPP_ASSIGNMENTS -DUSB_VID={build.vid} -DUSB_PID={build.pid}
193
+
194
+########################################
195
+## KosselPro -- BrainwavePro with HID boot
196
+########################################
197
+KosselPro.name=Kossel Pro (HID Bootloader)
198
+
199
+KosselPro.bootloader.tool=avrdude
200
+KosselPro.bootloader.low_fuses=0xFF
201
+KosselPro.bootloader.high_fuses=0x9B
202
+KosselPro.bootloader.extended_fuses=0xF0
203
+KosselPro.bootloader.unlock_bits=0x3F
204
+KosselPro.bootloader.lock_bits=0x02F
205
+KosselPro.bootloader.path=at90usb
206
+KosselPro.bootloader.file=BootloaderHID.hex
207
+
208
+KosselPro.upload.tool=hidloader
209
+KosselPro.upload.protocol=halfkay
210
+KosselPro.upload.maximum_size=126976
211
+KosselPro.upload.maximum_ram_size=8192
212
+KosselPro.upload.speed=115200
213
+KosselPro.upload.disable_flushing=true
214
+
215
+KosselPro.build.mcu=at90usb1286
216
+KosselPro.build.f_cpu=16000000L
217
+KosselPro.build.board=AVR_BRAINWAVEPRO
218
+KosselPro.build.core=at90usb
219
+KosselPro.build.dependency=true
220
+KosselPro.build.variant=at90usb
221
+KosselPro.build.vid=0x16D0
222
+KosselPro.build.pid=0x076B
223
+KosselPro.build.extra_flags=-DAT90USBxx_TEENSYPP_ASSIGNMENTS -DUSB_VID={build.vid} -DUSB_PID={build.pid}
224
+
225
+########################################
226
+## SAVMkI (CDC)
227
+########################################
228
+SAVMkI.name=SAV MkI (CDC)
229
+
230
+SAVMkI.bootloader.tool=avrdude
231
+SAVMkI.bootloader.low_fuses=0xDE
232
+SAVMkI.bootloader.high_fuses=0xDB
233
+SAVMkI.bootloader.extended_fuses=0xF1
234
+SAVMkI.bootloader.unlock_bits=0x3F
235
+SAVMkI.bootloader.lock_bits=0x02F
236
+SAVMkI.bootloader.path=SAVMkI
237
+SAVMkI.bootloader.file=SAVMkI-1286-LUFA.hex
238
+
239
+SAVMkI.upload.tool=avrdude
240
+SAVMkI.upload.protocol=avr109
241
+SAVMkI.upload.maximum_size=126976
242
+SAVMkI.upload.speed=115200
243
+SAVMkI.upload.disable_flushing=true
244
+
245
+SAVMkI.build.mcu=at90usb1286
246
+SAVMkI.build.f_cpu=16000000L
247
+SAVMkI.build.board=AVR_SAVMkI
248
+SAVMkI.build.core=at90usb
249
+SAVMkI.build.dependency=true
250
+SAVMkI.build.variant=at90usb
251
+SAVMkI.build.vid=0x16D0
252
+SAVMkI.build.pid=0x076B
253
+SAVMkI.build.extra_flags=-DUSB_VID={build.vid} -DUSB_PID={build.pid}
254
+
255
+########################################
256
+## SAVMkI (HID)
257
+########################################
258
+SAVMkI_HID.name=SAV MkI (HID Bootloader)
259
+
260
+SAVMkI_HID.bootloader.tool=avrdude
261
+SAVMkI_HID.bootloader.low_fuses=0xDE
262
+SAVMkI_HID.bootloader.high_fuses=0xDB
263
+SAVMkI_HID.bootloader.extended_fuses=0xF1
264
+SAVMkI_HID.bootloader.unlock_bits=0x3F
265
+SAVMkI_HID.bootloader.lock_bits=0x02F
266
+SAVMkI_HID.bootloader.path=SAVMkI
267
+SAVMkI_HID.bootloader.file=SAVMkI_HID.hex
268
+
269
+SAVMkI_HID.upload.tool=hidloader
270
+SAVMkI_HID.upload.protocol=halfkay
271
+SAVMkI_HID.upload.maximum_size=126976
272
+SAVMkI_HID.upload.maximum_ram_size=8192
273
+SAVMkI_HID.upload.speed=115200
274
+SAVMkI_HID.upload.disable_flushing=true
275
+
276
+SAVMkI_HID.build.mcu=at90usb1286
277
+SAVMkI_HID.build.f_cpu=16000000L
278
+SAVMkI_HID.build.board=AVR_SAVMkI
279
+SAVMkI_HID.build.core=at90usb
280
+SAVMkI_HID.build.dependency=true
281
+SAVMkI_HID.build.variant=at90usb
282
+SAVMkI_HID.build.vid=0x16D0
283
+SAVMkI_HID.build.pid=0x076B
284
+SAVMkI_HID.build.extra_flags=-DUSB_VID={build.vid} -DUSB_PID={build.pid}

+ 2
- 0
ArduinoAddons/Arduino_1.6.x/hardware/marlin/avr/platform.local.txt Целия файл

@@ -0,0 +1,2 @@
1
+compiler.cpp.extra_flags=-DHAS_AUTOMATIC_VERSIONING
2
+recipe.hooks.prebuild.pattern=generate_version_header_for_marlin "{build.source.path}" "{build.path}/_Version.h"

+ 120
- 0
ArduinoAddons/Arduino_1.6.x/hardware/marlin/avr/platform.txt Целия файл

@@ -0,0 +1,120 @@
1
+
2
+# Arduino AVR Core and platform.
3
+# ------------------------------
4
+
5
+# For more info:
6
+# https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5---3rd-party-Hardware-specification
7
+
8
+name=Marlin AVR Boards
9
+version=1.5.6
10
+
11
+# AVR compile variables
12
+# ---------------------
13
+
14
+# Default "compiler.path" is correct, change only if you want to overidde the initial value
15
+compiler.path={runtime.tools.avr-gcc.path}/bin/
16
+compiler.c.cmd=avr-gcc
17
+compiler.c.flags=-c -g -Os -w -ffunction-sections -fdata-sections -MMD
18
+# -w flag added to avoid printing a wrong warning http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59396
19
+# This is fixed in gcc 4.8.3 and will be removed as soon as we update the toolchain
20
+compiler.c.elf.flags=-w -Os -Wl,--gc-sections
21
+compiler.c.elf.cmd=avr-gcc
22
+compiler.S.flags=-c -g -x assembler-with-cpp
23
+compiler.cpp.cmd=avr-g++
24
+compiler.cpp.flags=-c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD
25
+compiler.ar.cmd=avr-ar
26
+compiler.ar.flags=rcs
27
+compiler.objcopy.cmd=avr-objcopy
28
+compiler.objcopy.eep.flags=-O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0
29
+compiler.elf2hex.flags=-O ihex -R .eeprom
30
+compiler.elf2hex.cmd=avr-objcopy
31
+compiler.ldflags=
32
+compiler.size.cmd=avr-size
33
+
34
+# This can be overriden in boards.txt
35
+build.extra_flags=
36
+
37
+# These can be overridden in platform.local.txt
38
+compiler.c.extra_flags=
39
+compiler.c.elf.extra_flags=
40
+compiler.S.extra_flags=
41
+compiler.cpp.extra_flags=
42
+compiler.ar.extra_flags=
43
+compiler.objcopy.eep.extra_flags=
44
+compiler.elf2hex.extra_flags=
45
+
46
+# AVR compile patterns
47
+# --------------------
48
+
49
+## Compile c files
50
+recipe.c.o.pattern="{compiler.path}{compiler.c.cmd}" {compiler.c.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} {compiler.c.extra_flags} {build.extra_flags} {includes} "{source_file}" -o "{object_file}"
51
+
52
+## Compile c++ files
53
+recipe.cpp.o.pattern="{compiler.path}{compiler.cpp.cmd}" {compiler.cpp.flags} {compiler.cpp.extra_flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} {build.extra_flags} {includes} "{source_file}" -o "{object_file}"
54
+
55
+## Compile S files
56
+recipe.S.o.pattern="{compiler.path}{compiler.c.cmd}" {compiler.S.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} {compiler.S.extra_flags} {build.extra_flags} {includes} "{source_file}" -o "{object_file}"
57
+
58
+## Create archives
59
+recipe.ar.pattern="{compiler.path}{compiler.ar.cmd}" {compiler.ar.flags} {compiler.ar.extra_flags} "{build.path}/{archive_file}" "{object_file}"
60
+
61
+## Combine gc-sections, archives, and objects
62
+recipe.c.combine.pattern="{compiler.path}{compiler.c.elf.cmd}" {compiler.c.elf.flags} -mmcu={build.mcu} {compiler.c.elf.extra_flags} -o "{build.path}/{build.project_name}.elf" {object_files} "{build.path}/{archive_file}" "-L{build.path}" -lm
63
+
64
+## Create eeprom
65
+recipe.objcopy.eep.pattern="{compiler.path}{compiler.objcopy.cmd}" {compiler.objcopy.eep.flags} {compiler.objcopy.eep.extra_flags} "{build.path}/{build.project_name}.elf" "{build.path}/{build.project_name}.eep"
66
+
67
+## Create hex
68
+recipe.objcopy.hex.pattern="{compiler.path}{compiler.elf2hex.cmd}" {compiler.elf2hex.flags} {compiler.elf2hex.extra_flags} "{build.path}/{build.project_name}.elf" "{build.path}/{build.project_name}.hex"
69
+
70
+## Compute size
71
+recipe.size.pattern="{compiler.path}{compiler.size.cmd}" -A "{build.path}/{build.project_name}.elf"
72
+recipe.size.regex=^(?:\.text|\.data|\.bootloader)\s+([0-9]+).*
73
+recipe.size.regex.data=^(?:\.data|\.bss|\.noinit)\s+([0-9]+).*
74
+recipe.size.regex.eeprom=^(?:\.eeprom)\s+([0-9]+).*
75
+
76
+
77
+# AVR Uploader/Programmers tools
78
+# ------------------------------
79
+
80
+tools.avrdude.path={runtime.tools.avrdude.path}
81
+tools.avrdude.cmd.path={path}/bin/avrdude
82
+tools.avrdude.config.path={path}/etc/avrdude.conf
83
+
84
+tools.avrdude.upload.params.verbose=-v
85
+tools.avrdude.upload.params.quiet=-q -q
86
+tools.avrdude.upload.pattern="{cmd.path}" "-C{config.path}" {upload.verbose} -p{build.mcu} -c{upload.protocol} -P{serial.port} -b{upload.speed} -D "-Uflash:w:{build.path}/{build.project_name}.hex:i"
87
+
88
+tools.avrdude.program.params.verbose=-v
89
+tools.avrdude.program.params.quiet=-q -q
90
+tools.avrdude.program.pattern="{cmd.path}" "-C{config.path}" {program.verbose} -p{build.mcu} -c{protocol} {program.extra_params} "-Uflash:w:{build.path}/{build.project_name}.hex:i"
91
+
92
+tools.avrdude.erase.params.verbose=-v
93
+tools.avrdude.erase.params.quiet=-q -q
94
+tools.avrdude.erase.pattern="{cmd.path}" "-C{config.path}" {erase.verbose} -p{build.mcu} -c{protocol} {program.extra_params} -e -Ulock:w:{bootloader.unlock_bits}:m -Uefuse:w:{bootloader.extended_fuses}:m -Uhfuse:w:{bootloader.high_fuses}:m -Ulfuse:w:{bootloader.low_fuses}:m
95
+
96
+tools.avrdude.bootloader.params.verbose=-v
97
+tools.avrdude.bootloader.params.quiet=-q -q
98
+tools.avrdude.bootloader.pattern="{cmd.path}" "-C{config.path}" {bootloader.verbose} -p{build.mcu} -c{protocol} {program.extra_params} "-Uflash:w:{runtime.platform.path}/bootloaders/{bootloader.path}/{bootloader.file}:i" -Ulock:w:{bootloader.lock_bits}:m
99
+
100
+tools.hidloader.cmd.path=/usr/local/bin/HIDUploader
101
+
102
+tools.hidloader.upload.params.verbose=-v
103
+tools.hidloader.upload.params.quiet=
104
+tools.hidloader.upload.pattern="{cmd.path}" --upload -mmcu={build.mcu} {upload.verbose} -w "{build.path}/{build.project_name}.hex"
105
+tools.nativehid.program.params.verbose=-v
106
+tools.nativehid.program.params.quiet=-q -q
107
+
108
+tools.hidloader.program.params.verbose=-v
109
+tools.hidloader.program.params.quiet=-q -q
110
+tools.hidloader.program.pattern="{cmd.path}" -mmcu={build.mcu} {upload.verbose} -w "{build.path}/{build.project_name}.hex"
111
+
112
+tools.hidloader.erase.params.verbose=-v
113
+tools.hidloader.erase.params.quiet=-q -q
114
+tools.hidloader.erase.pattern="{cmd.path}" --erase "-C{config.path}" {erase.verbose} -p{build.mcu} -c{protocol} {program.extra_params} -e -Ulock:w:{bootloader.unlock_bits}:m -Uefuse:w:{bootloader.extended_fuses}:m -Uhfuse:w:{bootloader.high_fuses}:m -Ulfuse:w:{bootloader.low_fuses}:m
115
+
116
+# USB Default Flags
117
+# Default blank usb manufacturer will be filled it at compile time
118
+# - from numeric vendor ID, set to Unknown otherwise
119
+build.usb_manufacturer=
120
+build.usb_flags=-DUSB_VID={build.vid} -DUSB_PID={build.pid} '-DUSB_MANUFACTURER={build.usb_manufacturer}' '-DUSB_PRODUCT={build.usb_product}'

+ 278
- 0
ArduinoAddons/Arduino_1.6.x/hardware/marlin/avr/variants/at90usb/pins_arduino.h Целия файл

@@ -0,0 +1,278 @@
1
+/*
2
+  pins_arduino.h - Pin definition functions for Arduino
3
+  Part of Arduino - http://www.arduino.cc/
4
+
5
+  Copyright (c) 2007 David A. Mellis
6
+  Modified 2012 by Fredrik Hubinette
7
+  Modified 2014-2015 by Matthew Wilson
8
+
9
+  This library is free software; you can redistribute it and/or
10
+  modify it under the terms of the GNU Lesser General Public
11
+  License as published by the Free Software Foundation; either
12
+  version 2.1 of the License, or (at your option) any later version.
13
+
14
+  This library is distributed in the hope that it will be useful,
15
+  but WITHOUT ANY WARRANTY; without even the implied warranty of
16
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
17
+  Lesser General Public License for more details.
18
+
19
+  You should have received a copy of the GNU Lesser General
20
+  Public License along with this library; if not, write to the
21
+  Free Software Foundation, Inc., 59 Temple Place, Suite 330,
22
+  Boston, MA  02111-1307  USA
23
+
24
+  $Id: wiring.h 249 2007-02-03 16:52:51Z mellis $
25
+*/
26
+
27
+#ifndef Pins_Arduino_h
28
+#define Pins_Arduino_h
29
+
30
+#include <avr/pgmspace.h>
31
+
32
+#define NUM_DIGITAL_PINS            48
33
+#define NUM_ANALOG_INPUTS           8
34
+
35
+// PE7 is our status LED
36
+#define TX_RX_LED_INIT		DDRE |= (1<<7)
37
+#define TXLED0			0
38
+#define TXLED1			0
39
+#define RXLED0			PORTE |= (1<<7)
40
+#define RXLED1			PORTE &= ~(1<<7)
41
+
42
+static const uint8_t SDA = 1;
43
+static const uint8_t SCL = 0;
44
+
45
+// Map SPI port to 'new' pins D14..D17
46
+static const uint8_t SS   = 20;
47
+static const uint8_t MOSI = 22;
48
+static const uint8_t MISO = 23;
49
+static const uint8_t SCK  = 21;
50
+
51
+// Mapping of analog pins as digital I/O
52
+// A6-A11 share with digital pins
53
+static const uint8_t A0 = 38;   // F0
54
+static const uint8_t A1 = 39;   // F1
55
+static const uint8_t A2 = 40;   // F2
56
+static const uint8_t A3 = 41;   // F3
57
+static const uint8_t A4 = 42;   // F4
58
+static const uint8_t A5 = 43;   // F5
59
+static const uint8_t A6 = 44;	// F6
60
+static const uint8_t A7 = 45;	// F7
61
+
62
+#define analogInputToDigitalPin(p)  ((p < 8) ? (p) + 38 : -1)
63
+
64
+// Pins below still needs to be configured - Hubbe.
65
+
66
+#define digitalPinToPCICR(p)    ((((p) >= 0 && (p) <= 3) || ((p) >= 18 && (p) <= 19) || ((p) >= 36 && (p) <= 37)) ? (&PCICR) : ((uint8_t *)0))
67
+#define digitalPinToPCICRbit(p) 0
68
+#define digitalPinToPCMSK(p)    ((((p) >= 0 && (p) <= 3) || ((p) >= 18 && (p) <= 19) || ((p) >= 36 && (p) <= 37)) ? (&PCMSK0) : ((uint8_t *)0))
69
+#define digitalPinToPCMSKbit(p) ( ((p) >= 0 && (p) <= 3) ? (p) : ((p) == 18 ? 6 : ((p) == 19 ? 7 : ((p) == 36 ? 4 : ((p) == 37 ? 5 : (-1))))))
70
+
71
+#define digitalPinHasPWM(p)     ((p) == 0 || (p) == 1 || (p) == 14 || (p) == 15 || (p) == 16 || (p) == 24 || (p) == 25 || (p) == 26 || (p) == 27)
72
+
73
+//	__AVR_ATmega32U4__ has an unusual mapping of pins to channels
74
+extern const uint8_t PROGMEM analog_pin_to_channel_PGM[];
75
+#define analogPinToChannel(P)  ( pgm_read_byte( analog_pin_to_channel_PGM + (P) ) )
76
+
77
+#ifdef ARDUINO_MAIN
78
+
79
+
80
+// these arrays map port names (e.g. port B) to the
81
+// appropriate addresses for various functions (e.g. reading
82
+// and writing)
83
+// Note PA == 1, PB == 2, etc. (GAH!)
84
+const uint16_t PROGMEM port_to_mode_PGM[] = {
85
+  NOT_A_PORT,
86
+  (uint16_t) &DDRA,
87
+  (uint16_t) &DDRB,
88
+  (uint16_t) &DDRC,
89
+  (uint16_t) &DDRD,
90
+  (uint16_t) &DDRE,
91
+};
92
+
93
+const uint16_t PROGMEM port_to_output_PGM[] = {
94
+  NOT_A_PORT,
95
+  (uint16_t) &PORTA,
96
+  (uint16_t) &PORTB,
97
+  (uint16_t) &PORTC,
98
+  (uint16_t) &PORTD,
99
+  (uint16_t) &PORTE,
100
+};
101
+
102
+const uint16_t PROGMEM port_to_input_PGM[] = {
103
+  NOT_A_PORT,
104
+  (uint16_t) &PINA,
105
+  (uint16_t) &PINB,
106
+  (uint16_t) &PINC,
107
+  (uint16_t) &PIND,
108
+  (uint16_t) &PINE,
109
+};
110
+
111
+const uint8_t PROGMEM digital_pin_to_port_PGM[] = {
112
+  PD, // 0  - PD0 - INT0 - PWM
113
+  PD, // 1  - PD1 - INT1 - PWM
114
+  PD, // 2  - PD2 - INT2 - RX
115
+  PD, // 3  - PD3 - INT3 - TX
116
+  PD, // 4  - PD4
117
+  PD, // 5  - PD5
118
+  PD, // 6  - PD6
119
+  PD, // 7  - PD7
120
+  PE, // 8  - PE0
121
+  PE, // 9  - PE1
122
+  PC, // 10 - PC0
123
+  PC, // 11 - PC1
124
+  PC, // 12 - PC2
125
+  PC, // 13 - PC3
126
+  PC, // 14 - PC4 - PWM
127
+  PC, // 15 - PC5 - PWM
128
+  PC, // 16 - PC6 - PWM
129
+  PC, // 17 - PC7
130
+  PE, // 18 - PE6 - INT6
131
+  PE, // 19 - PE7 - INT7
132
+  PB, // 20 - PB0
133
+  PB, // 21 - PB1
134
+  PB, // 22 - PB2
135
+  PB, // 23 - PB3
136
+  PB, // 24 - PB4 - PWM
137
+  PB, // 25 - PB5 - PWM
138
+  PB, // 26 - PB6 - PWM
139
+  PB, // 27 - PB7 - PWM
140
+  PA, // 28 - PA0
141
+  PA, // 29 - PA1
142
+  PA, // 30 - PA2
143
+  PA, // 31 - PA3
144
+  PA, // 32 - PA4
145
+  PA, // 33 - PA5
146
+  PA, // 34 - PA6
147
+  PA, // 35 - PA7
148
+  PE, // 36 - PE4 - INT4
149
+  PE, // 37 - PE5 - INT5
150
+  PF, // 38 - PF0 - A0
151
+  PF, // 39 - PF1 - A1
152
+  PF, // 40 - PF2 - A2
153
+  PF, // 41 - PF3 - A3
154
+  PF, // 42 - PF4 - A4
155
+  PF, // 43 - PF5 - A5
156
+  PF, // 44 - PF6 - A6
157
+  PF, // 45 - PF7 - A7
158
+  PE, // 46 - PE2 (not defined in teensy)
159
+  PE, // 47 - PE3 (not defined in teensy)
160
+};
161
+
162
+const uint8_t PROGMEM digital_pin_to_bit_mask_PGM[] = {
163
+  _BV(0), // 0  - PD0 - INT0 - PWM
164
+  _BV(1), // 1  - PD1 - INT1 - PWM
165
+  _BV(2), // 2  - PD2 - INT2 - RX
166
+  _BV(3), // 3  - PD3 - INT3 - TX
167
+  _BV(4), // 4  - PD4
168
+  _BV(5), // 5  - PD5
169
+  _BV(6), // 6  - PD6
170
+  _BV(7), // 7  - PD7
171
+  _BV(0), // 8  - PE0
172
+  _BV(1), // 9  - PE1
173
+  _BV(0), // 10 - PC0
174
+  _BV(1), // 11 - PC1
175
+  _BV(2), // 12 - PC2
176
+  _BV(3), // 13 - PC3
177
+  _BV(4), // 14 - PC4 - PWM
178
+  _BV(5), // 15 - PC5 - PWM
179
+  _BV(6), // 16 - PC6 - PWM
180
+  _BV(7), // 17 - PC7
181
+  _BV(6), // 18 - PE6 - INT6
182
+  _BV(7), // 19 - PE7 - INT7
183
+  _BV(0), // 20 - PB0
184
+  _BV(1), // 21 - PB1
185
+  _BV(2), // 22 - PB2
186
+  _BV(3), // 23 - PB3
187
+  _BV(4), // 24 - PB4 - PWM
188
+  _BV(5), // 25 - PB5 - PWM
189
+  _BV(6), // 26 - PB6 - PWM
190
+  _BV(7), // 27 - PB7 - PWM
191
+  _BV(0), // 28 - PA0
192
+  _BV(1), // 29 - PA1
193
+  _BV(2), // 30 - PA2
194
+  _BV(3), // 31 - PA3
195
+  _BV(4), // 32 - PA4
196
+  _BV(5), // 33 - PA5
197
+  _BV(6), // 34 - PA6
198
+  _BV(7), // 35 - PA7
199
+  _BV(4), // 36 - PE4 - INT4
200
+  _BV(5), // 37 - PE5 - INT5
201
+  _BV(0), // 38 - PF0 - A0
202
+  _BV(1), // 39 - PF1 - A1
203
+  _BV(2), // 40 - PF2 - A2
204
+  _BV(3), // 41 - PF3 - A3
205
+  _BV(4), // 42 - PF4 - A4
206
+  _BV(5), // 43 - PF5 - A5
207
+  _BV(6), // 44 - PF6 - A6
208
+  _BV(7), // 45 - PF7 - A7
209
+  _BV(2), // 46 - PE2 (not defined in teensy)
210
+  _BV(3), // 47 - PE3 (not defined in teensy)
211
+};
212
+
213
+
214
+// TODO(unrepentantgeek) complete this map of PWM capable pins
215
+const uint8_t PROGMEM digital_pin_to_timer_PGM[] = {
216
+  TIMER0A,      // 0  - PD0 - INT0 - PWM
217
+  TIMER2B,      // 1  - PD1 - INT1 - PWM
218
+  NOT_ON_TIMER, // 2  - PD2 - INT2 - RX
219
+  NOT_ON_TIMER, // 3  - PD3 - INT3 - TX
220
+  NOT_ON_TIMER, // 4  - PD4
221
+  NOT_ON_TIMER, // 5  - PD5
222
+  NOT_ON_TIMER, // 6  - PD6
223
+  NOT_ON_TIMER, // 7  - PD7
224
+  NOT_ON_TIMER, // 8  - PE0
225
+  NOT_ON_TIMER, // 9  - PE1
226
+  NOT_ON_TIMER, // 10 - PC0
227
+  NOT_ON_TIMER, // 11 - PC1
228
+  NOT_ON_TIMER, // 12 - PC2
229
+  NOT_ON_TIMER, // 13 - PC3
230
+  TIMER3C,      // 14 - PC4 - PWM
231
+  TIMER3B,      // 15 - PC5 - PWM
232
+  TIMER3A,      // 16 - PC6 - PWM
233
+  NOT_ON_TIMER, // 17 - PC7
234
+  NOT_ON_TIMER, // 18 - PE6 - INT6
235
+  NOT_ON_TIMER, // 19 - PE7 - INT7
236
+  NOT_ON_TIMER, // 20 - PB0
237
+  NOT_ON_TIMER, // 21 - PB1
238
+  NOT_ON_TIMER, // 22 - PB2
239
+  NOT_ON_TIMER, // 23 - PB3
240
+  TIMER2A,      // 24 - PB4 - PWM
241
+  TIMER1A,      // 25 - PB5 - PWM
242
+  TIMER1B,      // 26 - PB6 - PWM
243
+  NOT_ON_TIMER, // 27 - PB7 - PWM  // This should be on TIMER1C
244
+  NOT_ON_TIMER, // 28 - PA0
245
+  NOT_ON_TIMER, // 29 - PA1
246
+  NOT_ON_TIMER, // 30 - PA2
247
+  NOT_ON_TIMER, // 31 - PA3
248
+  NOT_ON_TIMER, // 32 - PA4
249
+  NOT_ON_TIMER, // 33 - PA5
250
+  NOT_ON_TIMER, // 34 - PA6
251
+  NOT_ON_TIMER, // 35 - PA7
252
+  NOT_ON_TIMER, // 36 - PE4 - INT4
253
+  NOT_ON_TIMER, // 37 - PE5 - INT5
254
+  NOT_ON_TIMER, // 38 - PF0 - A0
255
+  NOT_ON_TIMER, // 39 - PF1 - A1
256
+  NOT_ON_TIMER, // 40 - PF2 - A2
257
+  NOT_ON_TIMER, // 41 - PF3 - A3
258
+  NOT_ON_TIMER, // 42 - PF4 - A4
259
+  NOT_ON_TIMER, // 43 - PF5 - A5
260
+  NOT_ON_TIMER, // 44 - PF6 - A6
261
+  NOT_ON_TIMER, // 45 - PF7 - A7
262
+  NOT_ON_TIMER, // 46 - PE2 (not defined in teensy)
263
+  NOT_ON_TIMER, // 47 - PE3 (not defined in teensy)
264
+};
265
+
266
+const uint8_t PROGMEM analog_pin_to_channel_PGM[8] = {
267
+	0,	// A0		PF0	ADC0
268
+	1,	// A1		PF1	ADC1
269
+	2,	// A2		PF2	ADC2
270
+	3,	// A3		PF3	ADC3
271
+	4,	// A4		PF4	ADC4
272
+	5,	// A5		PF5	ADC5
273
+	6,	// A6	  	PD6	ADC6
274
+	7,	// A7		PD7	ADC7
275
+};
276
+
277
+#endif /* ARDUINO_MAIN */
278
+#endif /* Pins_Arduino_h */

+ 281
- 0
ArduinoAddons/Arduino_1.6.x/hardware/marlin/avr/variants/brainwave/pins_arduino.h Целия файл

@@ -0,0 +1,281 @@
1
+/*
2
+  pins_arduino.h - Pin definition functions for Arduino
3
+  Part of Arduino - http://www.arduino.cc/
4
+
5
+  Copyright (c) 2007 David A. Mellis
6
+  Modified 2012 by Fredrik Hubinette
7
+
8
+  This library is free software; you can redistribute it and/or
9
+  modify it under the terms of the GNU Lesser General Public
10
+  License as published by the Free Software Foundation; either
11
+  version 2.1 of the License, or (at your option) any later version.
12
+
13
+  This library is distributed in the hope that it will be useful,
14
+  but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16
+  Lesser General Public License for more details.
17
+
18
+  You should have received a copy of the GNU Lesser General
19
+  Public License along with this library; if not, write to the
20
+  Free Software Foundation, Inc., 59 Temple Place, Suite 330,
21
+  Boston, MA  02111-1307  USA
22
+
23
+  $Id: wiring.h 249 2007-02-03 16:52:51Z mellis $
24
+*/
25
+
26
+#ifndef Pins_Arduino_h
27
+#define Pins_Arduino_h
28
+
29
+#include <avr/pgmspace.h>
30
+
31
+#define NUM_DIGITAL_PINS            48
32
+#define NUM_ANALOG_INPUTS           8
33
+
34
+#define TX_RX_LED_INIT		DDRE |= (1<<7)
35
+#define TXLED0			0
36
+#define TXLED1			0
37
+#define RXLED0			PORTE |= (1<<7)
38
+#define RXLED1			PORTE &= ~(1<<7)
39
+
40
+static const uint8_t SDA = 0;
41
+static const uint8_t SCL = 1;
42
+
43
+// Map SPI port to 'new' pins D14..D17
44
+static const uint8_t SS   = 20;
45
+static const uint8_t MOSI = 22;
46
+static const uint8_t MISO = 23;
47
+static const uint8_t SCK  = 21;
48
+
49
+// Mapping of analog pins as digital I/O
50
+// A6-A11 share with digital pins
51
+static const uint8_t A0 = 38;   // F0
52
+static const uint8_t A1 = 39;   // F1
53
+static const uint8_t A2 = 40;   // F2
54
+static const uint8_t A3 = 41;   // F3
55
+static const uint8_t A4 = 42;   // F4
56
+static const uint8_t A5 = 43;   // F5
57
+static const uint8_t A6 = 44;	// F6
58
+static const uint8_t A7 = 45;	// F7
59
+
60
+#define analogInputToDigitalPin(p)  ((p < 16) ? (p) + 54 : -1)
61
+
62
+// Pins below still needs to be configured - Hubbe.
63
+
64
+#define digitalPinToPCICR(p)    ((((p) >= 8 && (p) <= 11) || ((p) >= 14 && (p) <= 17) || ((p) >= A8 && (p) <= A10)) ? (&PCICR) : ((uint8_t *)0))
65
+#define digitalPinToPCICRbit(p) 0
66
+#define digitalPinToPCMSK(p)    ((((p) >= 8 && (p) <= 11) || ((p) >= 14 && (p) <= 17) || ((p) >= A8 && (p) <= A10)) ? (&PCMSK0) : ((uint8_t *)0))
67
+#define digitalPinToPCMSKbit(p) ( ((p) >= 8 && (p) <= 11) ? (p) - 4 : ((p) == 14 ? 3 : ((p) == 15 ? 1 : ((p) == 16 ? 2 : ((p) == 17 ? 0 : (p - A8 + 4))))))
68
+
69
+
70
+#define digitalPinHasPWM(p)         ((p) == 12 || (p) == 13 || (p) == 14 || (p) == 20 || (p) == 21 || (p) == 22)
71
+
72
+//	__AVR_ATmega32U4__ has an unusual mapping of pins to channels
73
+extern const uint8_t PROGMEM analog_pin_to_channel_PGM[];
74
+#define analogPinToChannel(P)  ( pgm_read_byte( analog_pin_to_channel_PGM + (P) ) )
75
+
76
+#ifdef ARDUINO_MAIN
77
+
78
+
79
+// these arrays map port names (e.g. port B) to the
80
+// appropriate addresses for various functions (e.g. reading
81
+// and writing)
82
+// Note PA == 1, PB == 2, etc. (GAH!)
83
+const uint16_t PROGMEM port_to_mode_PGM[] = {
84
+  NOT_A_PORT,
85
+  (uint16_t) &DDRA,
86
+  (uint16_t) &DDRB,
87
+  (uint16_t) &DDRC,
88
+  (uint16_t) &DDRD,
89
+  (uint16_t) &DDRE,
90
+};
91
+
92
+const uint16_t PROGMEM port_to_output_PGM[] = {
93
+  NOT_A_PORT,
94
+  (uint16_t) &PORTA,
95
+  (uint16_t) &PORTB,
96
+  (uint16_t) &PORTC,
97
+  (uint16_t) &PORTD,
98
+  (uint16_t) &PORTE,
99
+};
100
+
101
+const uint16_t PROGMEM port_to_input_PGM[] = {
102
+  NOT_A_PORT,
103
+  (uint16_t) &PINA,
104
+  (uint16_t) &PINB,
105
+  (uint16_t) &PINC,
106
+  (uint16_t) &PIND,
107
+  (uint16_t) &PINE,
108
+};
109
+
110
+const uint8_t PROGMEM digital_pin_to_port_PGM[] = {
111
+  PA, // 0
112
+  PA,
113
+  PA,
114
+  PA,
115
+  PA,
116
+  PA,
117
+  PA,
118
+  PA,
119
+  PB, // 8
120
+  PB,
121
+  PB,
122
+  PB,
123
+  PB,
124
+  PB,
125
+  PB,
126
+  PB,
127
+  PC, // 16
128
+  PC,
129
+  PC,
130
+  PC,
131
+  PC,
132
+  PC,
133
+  PC,
134
+  PC,
135
+  PD, // 24
136
+  PD,
137
+  PD,
138
+  PD,
139
+  PD,
140
+  PD,
141
+  PD,
142
+  PD,
143
+  PE, // 32
144
+  PE,
145
+  PE,
146
+  PE,
147
+  PE,
148
+  PE,
149
+  PE,
150
+  PE, // 39 - PE7
151
+  PF, // 40 - A0 - PF0
152
+  PF,
153
+  PF,
154
+  PF,
155
+  PF,
156
+  PF,
157
+  PF,
158
+  PF, // 47 - A7 - PF7
159
+};
160
+
161
+const uint8_t PROGMEM digital_pin_to_bit_mask_PGM[] = {
162
+  _BV(0), // PA0
163
+  _BV(1),
164
+  _BV(2),
165
+  _BV(3),
166
+  _BV(4),
167
+  _BV(5),
168
+  _BV(6),
169
+  _BV(7),
170
+  _BV(0), // PB0
171
+  _BV(1),
172
+  _BV(2),
173
+  _BV(3),
174
+  _BV(4),
175
+  _BV(5),
176
+  _BV(6),
177
+  _BV(7),
178
+  _BV(0), // PC0
179
+  _BV(1),
180
+  _BV(2),
181
+  _BV(3),
182
+  _BV(4),
183
+  _BV(5),
184
+  _BV(6),
185
+  _BV(7),
186
+  _BV(0), // PD0
187
+  _BV(1),
188
+  _BV(2),
189
+  _BV(3),
190
+  _BV(4),
191
+  _BV(5),
192
+  _BV(6),
193
+  _BV(7),
194
+  _BV(0), // PE0
195
+  _BV(1),
196
+  _BV(2),
197
+  _BV(3),
198
+  _BV(4),
199
+  _BV(5),
200
+  _BV(6),
201
+  _BV(7),
202
+  _BV(0), // PF0
203
+  _BV(1),
204
+  _BV(2),
205
+  _BV(3),
206
+  _BV(4),
207
+  _BV(5),
208
+  _BV(6),
209
+  _BV(7),
210
+};
211
+
212
+
213
+// TODO(unrepentantgeek) complete this map of PWM capable pins
214
+const uint8_t PROGMEM digital_pin_to_timer_PGM[] = {
215
+  NOT_ON_TIMER, //  0 - PA0
216
+  NOT_ON_TIMER, //  1 - PA1
217
+  NOT_ON_TIMER, //  2 - PA2
218
+  NOT_ON_TIMER, //  3 - PA3
219
+  NOT_ON_TIMER, //  4 - PA4
220
+  NOT_ON_TIMER, //  5 - PA5
221
+  NOT_ON_TIMER, //  6 - PA6
222
+  NOT_ON_TIMER, //  7 - PA7
223
+  NOT_ON_TIMER, //  8 - PB0
224
+  NOT_ON_TIMER, //  9 - PB1
225
+  NOT_ON_TIMER, // 10 - PB2
226
+  NOT_ON_TIMER, // 11 - PB3
227
+  TIMER2A,      // 12 - PB4
228
+  TIMER1A,      // 13 - PB5
229
+  TIMER1B,      // 14 - PB6
230
+  NOT_ON_TIMER, // 15 - PB7
231
+  NOT_ON_TIMER, // 16 - PC0
232
+  NOT_ON_TIMER, // 17 - PC1
233
+  NOT_ON_TIMER, // 18 - PC2
234
+  NOT_ON_TIMER, // 19 - PC3
235
+  TIMER3C,      // 20 - PC4
236
+  TIMER3B,      // 21 - PC5
237
+  TIMER3A,      // 22 - PC6
238
+  NOT_ON_TIMER, // 23 - PC7
239
+  NOT_ON_TIMER, // 24 - PD0
240
+  NOT_ON_TIMER, // 25 - PD1
241
+  NOT_ON_TIMER, // 26 - PD2
242
+  NOT_ON_TIMER, // 27 - PD3
243
+  NOT_ON_TIMER, // 28 - PD4
244
+  NOT_ON_TIMER, // 29 - PD5
245
+  NOT_ON_TIMER, // 30 - PD6
246
+  NOT_ON_TIMER, // 31 - PD7
247
+  NOT_ON_TIMER, // 32 - PE0
248
+  NOT_ON_TIMER, // 33 - PE1
249
+  NOT_ON_TIMER, // 34 - PE2
250
+  NOT_ON_TIMER, // 35 - PE3
251
+  NOT_ON_TIMER, // 36 - PE4
252
+  NOT_ON_TIMER, // 37 - PE5
253
+  NOT_ON_TIMER, // 38 - PE6
254
+  NOT_ON_TIMER, // 39 - PE7
255
+  NOT_ON_TIMER, // 40 - A0 - PF0
256
+  NOT_ON_TIMER, // 41 - A1 - PF1
257
+  NOT_ON_TIMER, // 42 - A2 - PF2
258
+  NOT_ON_TIMER, // 43 - A3 - PF3
259
+  NOT_ON_TIMER, // 44 - A4 - PF4
260
+  NOT_ON_TIMER, // 45 - A5 - PF5
261
+  NOT_ON_TIMER, // 46 - A6 - PF6
262
+  NOT_ON_TIMER, // 47 - A7 - PF7
263
+};
264
+
265
+const uint8_t PROGMEM analog_pin_to_channel_PGM[12] = {
266
+	7,	// A0				PF7					ADC7
267
+	6,	// A1				PF6					ADC6
268
+	5,	// A2				PF5					ADC5
269
+	4,	// A3				PF4					ADC4
270
+	1,	// A4				PF1					ADC1
271
+	0,	// A5				PF0					ADC0
272
+	8,	// A6		D4		PD4					ADC8
273
+	10,	// A7		D6		PD7					ADC10
274
+	11,	// A8		D8		PB4					ADC11
275
+	12,	// A9		D9		PB5					ADC12
276
+	13,	// A10		D10		PB6					ADC13
277
+	9	// A11		D12		PD6					ADC9
278
+};
279
+
280
+#endif /* ARDUINO_MAIN */
281
+#endif /* Pins_Arduino_h */

+ 389
- 0
ArduinoAddons/Arduino_1.6.x/hardware/marlin/avr/variants/mega/pins_arduino.h Целия файл

@@ -0,0 +1,389 @@
1
+/*
2
+  pins_arduino.h - Pin definition functions for Arduino
3
+  Part of Arduino - http://www.arduino.cc/
4
+
5
+  Copyright (c) 2007 David A. Mellis
6
+
7
+  This library is free software; you can redistribute it and/or
8
+  modify it under the terms of the GNU Lesser General Public
9
+  License as published by the Free Software Foundation; either
10
+  version 2.1 of the License, or (at your option) any later version.
11
+
12
+  This library is distributed in the hope that it will be useful,
13
+  but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15
+  Lesser General Public License for more details.
16
+
17
+  You should have received a copy of the GNU Lesser General
18
+  Public License along with this library; if not, write to the
19
+  Free Software Foundation, Inc., 59 Temple Place, Suite 330,
20
+  Boston, MA  02111-1307  USA
21
+
22
+  $Id: wiring.h 249 2007-02-03 16:52:51Z mellis $
23
+*/
24
+
25
+#ifndef Pins_Arduino_h
26
+#define Pins_Arduino_h
27
+
28
+#include <avr/pgmspace.h>
29
+
30
+#define NUM_DIGITAL_PINS            70
31
+#define NUM_ANALOG_INPUTS           16
32
+#define analogInputToDigitalPin(p)  ((p < 16) ? (p) + 54 : -1)
33
+#define digitalPinHasPWM(p)         (((p) >= 2 && (p) <= 13) || ((p) >= 44 && (p)<= 46))
34
+
35
+static const uint8_t SS   = 53;
36
+static const uint8_t MOSI = 51;
37
+static const uint8_t MISO = 50;
38
+static const uint8_t SCK  = 52;
39
+
40
+static const uint8_t SDA = 20;
41
+static const uint8_t SCL = 21;
42
+#define LED_BUILTIN 13
43
+
44
+static const uint8_t A0 = 54;
45
+static const uint8_t A1 = 55;
46
+static const uint8_t A2 = 56;
47
+static const uint8_t A3 = 57;
48
+static const uint8_t A4 = 58;
49
+static const uint8_t A5 = 59;
50
+static const uint8_t A6 = 60;
51
+static const uint8_t A7 = 61;
52
+static const uint8_t A8 = 62;
53
+static const uint8_t A9 = 63;
54
+static const uint8_t A10 = 64;
55
+static const uint8_t A11 = 65;
56
+static const uint8_t A12 = 66;
57
+static const uint8_t A13 = 67;
58
+static const uint8_t A14 = 68;
59
+static const uint8_t A15 = 69;
60
+
61
+// A majority of the pins are NOT PCINTs, SO BE WARNED (i.e. you cannot use them as receive pins)
62
+// Only pins available for RECEIVE (TRANSMIT can be on any pin):
63
+// (I've deliberately left out pin mapping to the Hardware USARTs - seems senseless to me)
64
+// Pins: 10, 11, 12, 13,  50, 51, 52, 53,  62, 63, 64, 65, 66, 67, 68, 69
65
+
66
+#define digitalPinToPCICR(p)    ( (((p) >= 10) && ((p) <= 13)) || \
67
+                                  (((p) >= 50) && ((p) <= 53)) || \
68
+                                  (((p) >= 62) && ((p) <= 69)) ? (&PCICR) : ((uint8_t *)0) )
69
+
70
+#define digitalPinToPCICRbit(p) ( (((p) >= 10) && ((p) <= 13)) || (((p) >= 50) && ((p) <= 53)) ? 0 : \
71
+                                ( (((p) >= 62) && ((p) <= 69)) ? 2 : \
72
+                                0 ) )
73
+
74
+#define digitalPinToPCMSK(p)    ( (((p) >= 10) && ((p) <= 13)) || (((p) >= 50) && ((p) <= 53)) ? (&PCMSK0) : \
75
+                                ( (((p) >= 62) && ((p) <= 69)) ? (&PCMSK2) : \
76
+                                ((uint8_t *)0) ) )
77
+
78
+#define digitalPinToPCMSKbit(p) ( (((p) >= 10) && ((p) <= 13)) ? ((p) - 6) : \
79
+                                ( ((p) == 50) ? 3 : \
80
+                                ( ((p) == 51) ? 2 : \
81
+                                ( ((p) == 52) ? 1 : \
82
+                                ( ((p) == 53) ? 0 : \
83
+                                ( (((p) >= 62) && ((p) <= 69)) ? ((p) - 62) : \
84
+                                0 ) ) ) ) ) )
85
+
86
+#define digitalPinToInterrupt(p) ((p) == 2 ? 0 : ((p) == 3 ? 1 : ((p) >= 18 && (p) <= 21 ? 23 - (p) : NOT_AN_INTERRUPT)))
87
+
88
+#ifdef ARDUINO_MAIN
89
+
90
+const uint16_t PROGMEM port_to_mode_PGM[] = {
91
+	NOT_A_PORT,
92
+	(uint16_t) &DDRA,
93
+	(uint16_t) &DDRB,
94
+	(uint16_t) &DDRC,
95
+	(uint16_t) &DDRD,
96
+	(uint16_t) &DDRE,
97
+	(uint16_t) &DDRF,
98
+	(uint16_t) &DDRG,
99
+	(uint16_t) &DDRH,
100
+	NOT_A_PORT,
101
+	(uint16_t) &DDRJ,
102
+	(uint16_t) &DDRK,
103
+	(uint16_t) &DDRL,
104
+};
105
+
106
+const uint16_t PROGMEM port_to_output_PGM[] = {
107
+	NOT_A_PORT,
108
+	(uint16_t) &PORTA,
109
+	(uint16_t) &PORTB,
110
+	(uint16_t) &PORTC,
111
+	(uint16_t) &PORTD,
112
+	(uint16_t) &PORTE,
113
+	(uint16_t) &PORTF,
114
+	(uint16_t) &PORTG,
115
+	(uint16_t) &PORTH,
116
+	NOT_A_PORT,
117
+	(uint16_t) &PORTJ,
118
+	(uint16_t) &PORTK,
119
+	(uint16_t) &PORTL,
120
+};
121
+
122
+const uint16_t PROGMEM port_to_input_PGM[] = {
123
+	NOT_A_PIN,
124
+	(uint16_t) &PINA,
125
+	(uint16_t) &PINB,
126
+	(uint16_t) &PINC,
127
+	(uint16_t) &PIND,
128
+	(uint16_t) &PINE,
129
+	(uint16_t) &PINF,
130
+	(uint16_t) &PING,
131
+	(uint16_t) &PINH,
132
+	NOT_A_PIN,
133
+	(uint16_t) &PINJ,
134
+	(uint16_t) &PINK,
135
+	(uint16_t) &PINL,
136
+};
137
+
138
+const uint8_t PROGMEM digital_pin_to_port_PGM[] = {
139
+	// PORTLIST		
140
+	// -------------------------------------------		
141
+	PE	, // PE 0 ** 0 ** USART0_RX	
142
+	PE	, // PE 1 ** 1 ** USART0_TX	
143
+	PE	, // PE 4 ** 2 ** PWM2	
144
+	PE	, // PE 5 ** 3 ** PWM3	
145
+	PG	, // PG 5 ** 4 ** PWM4	
146
+	PE	, // PE 3 ** 5 ** PWM5	
147
+	PH	, // PH 3 ** 6 ** PWM6	
148
+	PH	, // PH 4 ** 7 ** PWM7	
149
+	PH	, // PH 5 ** 8 ** PWM8	
150
+	PH	, // PH 6 ** 9 ** PWM9	
151
+	PB	, // PB 4 ** 10 ** PWM10	
152
+	PB	, // PB 5 ** 11 ** PWM11	
153
+	PB	, // PB 6 ** 12 ** PWM12	
154
+	PB	, // PB 7 ** 13 ** PWM13	
155
+	PJ	, // PJ 1 ** 14 ** USART3_TX	
156
+	PJ	, // PJ 0 ** 15 ** USART3_RX	
157
+	PH	, // PH 1 ** 16 ** USART2_TX	
158
+	PH	, // PH 0 ** 17 ** USART2_RX	
159
+	PD	, // PD 3 ** 18 ** USART1_TX	
160
+	PD	, // PD 2 ** 19 ** USART1_RX	
161
+	PD	, // PD 1 ** 20 ** I2C_SDA	
162
+	PD	, // PD 0 ** 21 ** I2C_SCL	
163
+	PA	, // PA 0 ** 22 ** D22	
164
+	PA	, // PA 1 ** 23 ** D23	
165
+	PA	, // PA 2 ** 24 ** D24	
166
+	PA	, // PA 3 ** 25 ** D25	
167
+	PA	, // PA 4 ** 26 ** D26	
168
+	PA	, // PA 5 ** 27 ** D27	
169
+	PA	, // PA 6 ** 28 ** D28	
170
+	PA	, // PA 7 ** 29 ** D29	
171
+	PC	, // PC 7 ** 30 ** D30	
172
+	PC	, // PC 6 ** 31 ** D31	
173
+	PC	, // PC 5 ** 32 ** D32	
174
+	PC	, // PC 4 ** 33 ** D33	
175
+	PC	, // PC 3 ** 34 ** D34	
176
+	PC	, // PC 2 ** 35 ** D35	
177
+	PC	, // PC 1 ** 36 ** D36	
178
+	PC	, // PC 0 ** 37 ** D37	
179
+	PD	, // PD 7 ** 38 ** D38	
180
+	PG	, // PG 2 ** 39 ** D39	
181
+	PG	, // PG 1 ** 40 ** D40	
182
+	PG	, // PG 0 ** 41 ** D41	
183
+	PL	, // PL 7 ** 42 ** D42	
184
+	PL	, // PL 6 ** 43 ** D43	
185
+	PL	, // PL 5 ** 44 ** D44	
186
+	PL	, // PL 4 ** 45 ** D45	
187
+	PL	, // PL 3 ** 46 ** D46	
188
+	PL	, // PL 2 ** 47 ** D47	
189
+	PL	, // PL 1 ** 48 ** D48	
190
+	PL	, // PL 0 ** 49 ** D49	
191
+	PB	, // PB 3 ** 50 ** SPI_MISO	
192
+	PB	, // PB 2 ** 51 ** SPI_MOSI	
193
+	PB	, // PB 1 ** 52 ** SPI_SCK	
194
+	PB	, // PB 0 ** 53 ** SPI_SS	
195
+	PF	, // PF 0 ** 54 ** A0	
196
+	PF	, // PF 1 ** 55 ** A1	
197
+	PF	, // PF 2 ** 56 ** A2	
198
+	PF	, // PF 3 ** 57 ** A3	
199
+	PF	, // PF 4 ** 58 ** A4	
200
+	PF	, // PF 5 ** 59 ** A5	
201
+	PF	, // PF 6 ** 60 ** A6	
202
+	PF	, // PF 7 ** 61 ** A7	
203
+	PK	, // PK 0 ** 62 ** A8	
204
+	PK	, // PK 1 ** 63 ** A9	
205
+	PK	, // PK 2 ** 64 ** A10	
206
+	PK	, // PK 3 ** 65 ** A11	
207
+	PK	, // PK 4 ** 66 ** A12	
208
+	PK	, // PK 5 ** 67 ** A13	
209
+	PK	, // PK 6 ** 68 ** A14	
210
+	PK	, // PK 7 ** 69 ** A15	
211
+};
212
+
213
+const uint8_t PROGMEM digital_pin_to_bit_mask_PGM[] = {
214
+	// PIN IN PORT		
215
+	// -------------------------------------------		
216
+	_BV( 0 )	, // PE 0 ** 0 ** USART0_RX	
217
+	_BV( 1 )	, // PE 1 ** 1 ** USART0_TX	
218
+	_BV( 4 )	, // PE 4 ** 2 ** PWM2	
219
+	_BV( 5 )	, // PE 5 ** 3 ** PWM3	
220
+	_BV( 5 )	, // PG 5 ** 4 ** PWM4	
221
+	_BV( 3 )	, // PE 3 ** 5 ** PWM5	
222
+	_BV( 3 )	, // PH 3 ** 6 ** PWM6	
223
+	_BV( 4 )	, // PH 4 ** 7 ** PWM7	
224
+	_BV( 5 )	, // PH 5 ** 8 ** PWM8	
225
+	_BV( 6 )	, // PH 6 ** 9 ** PWM9	
226
+	_BV( 4 )	, // PB 4 ** 10 ** PWM10	
227
+	_BV( 5 )	, // PB 5 ** 11 ** PWM11	
228
+	_BV( 6 )	, // PB 6 ** 12 ** PWM12	
229
+	_BV( 7 )	, // PB 7 ** 13 ** PWM13	
230
+	_BV( 1 )	, // PJ 1 ** 14 ** USART3_TX	
231
+	_BV( 0 )	, // PJ 0 ** 15 ** USART3_RX	
232
+	_BV( 1 )	, // PH 1 ** 16 ** USART2_TX	
233
+	_BV( 0 )	, // PH 0 ** 17 ** USART2_RX	
234
+	_BV( 3 )	, // PD 3 ** 18 ** USART1_TX	
235
+	_BV( 2 )	, // PD 2 ** 19 ** USART1_RX	
236
+	_BV( 1 )	, // PD 1 ** 20 ** I2C_SDA	
237
+	_BV( 0 )	, // PD 0 ** 21 ** I2C_SCL	
238
+	_BV( 0 )	, // PA 0 ** 22 ** D22	
239
+	_BV( 1 )	, // PA 1 ** 23 ** D23	
240
+	_BV( 2 )	, // PA 2 ** 24 ** D24	
241
+	_BV( 3 )	, // PA 3 ** 25 ** D25	
242
+	_BV( 4 )	, // PA 4 ** 26 ** D26	
243
+	_BV( 5 )	, // PA 5 ** 27 ** D27	
244
+	_BV( 6 )	, // PA 6 ** 28 ** D28	
245
+	_BV( 7 )	, // PA 7 ** 29 ** D29	
246
+	_BV( 7 )	, // PC 7 ** 30 ** D30	
247
+	_BV( 6 )	, // PC 6 ** 31 ** D31	
248
+	_BV( 5 )	, // PC 5 ** 32 ** D32	
249
+	_BV( 4 )	, // PC 4 ** 33 ** D33	
250
+	_BV( 3 )	, // PC 3 ** 34 ** D34	
251
+	_BV( 2 )	, // PC 2 ** 35 ** D35	
252
+	_BV( 1 )	, // PC 1 ** 36 ** D36	
253
+	_BV( 0 )	, // PC 0 ** 37 ** D37	
254
+	_BV( 7 )	, // PD 7 ** 38 ** D38	
255
+	_BV( 2 )	, // PG 2 ** 39 ** D39	
256
+	_BV( 1 )	, // PG 1 ** 40 ** D40	
257
+	_BV( 0 )	, // PG 0 ** 41 ** D41	
258
+	_BV( 7 )	, // PL 7 ** 42 ** D42	
259
+	_BV( 6 )	, // PL 6 ** 43 ** D43	
260
+	_BV( 5 )	, // PL 5 ** 44 ** D44	
261
+	_BV( 4 )	, // PL 4 ** 45 ** D45	
262
+	_BV( 3 )	, // PL 3 ** 46 ** D46	
263
+	_BV( 2 )	, // PL 2 ** 47 ** D47	
264
+	_BV( 1 )	, // PL 1 ** 48 ** D48	
265
+	_BV( 0 )	, // PL 0 ** 49 ** D49	
266
+	_BV( 3 )	, // PB 3 ** 50 ** SPI_MISO	
267
+	_BV( 2 )	, // PB 2 ** 51 ** SPI_MOSI	
268
+	_BV( 1 )	, // PB 1 ** 52 ** SPI_SCK	
269
+	_BV( 0 )	, // PB 0 ** 53 ** SPI_SS	
270
+	_BV( 0 )	, // PF 0 ** 54 ** A0	
271
+	_BV( 1 )	, // PF 1 ** 55 ** A1	
272
+	_BV( 2 )	, // PF 2 ** 56 ** A2	
273
+	_BV( 3 )	, // PF 3 ** 57 ** A3	
274
+	_BV( 4 )	, // PF 4 ** 58 ** A4	
275
+	_BV( 5 )	, // PF 5 ** 59 ** A5	
276
+	_BV( 6 )	, // PF 6 ** 60 ** A6	
277
+	_BV( 7 )	, // PF 7 ** 61 ** A7	
278
+	_BV( 0 )	, // PK 0 ** 62 ** A8	
279
+	_BV( 1 )	, // PK 1 ** 63 ** A9	
280
+	_BV( 2 )	, // PK 2 ** 64 ** A10	
281
+	_BV( 3 )	, // PK 3 ** 65 ** A11	
282
+	_BV( 4 )	, // PK 4 ** 66 ** A12	
283
+	_BV( 5 )	, // PK 5 ** 67 ** A13	
284
+	_BV( 6 )	, // PK 6 ** 68 ** A14	
285
+	_BV( 7 )	, // PK 7 ** 69 ** A15	
286
+};
287
+
288
+const uint8_t PROGMEM digital_pin_to_timer_PGM[] = {
289
+	// TIMERS		
290
+	// -------------------------------------------		
291
+	NOT_ON_TIMER	, // PE 0 ** 0 ** USART0_RX	
292
+	NOT_ON_TIMER	, // PE 1 ** 1 ** USART0_TX	
293
+	TIMER3B	, // PE 4 ** 2 ** PWM2	
294
+	TIMER3C	, // PE 5 ** 3 ** PWM3	
295
+	TIMER0B	, // PG 5 ** 4 ** PWM4	
296
+	TIMER3A	, // PE 3 ** 5 ** PWM5	
297
+	TIMER4A	, // PH 3 ** 6 ** PWM6	
298
+	TIMER4B	, // PH 4 ** 7 ** PWM7	
299
+	TIMER4C	, // PH 5 ** 8 ** PWM8	
300
+	TIMER2B	, // PH 6 ** 9 ** PWM9	
301
+	TIMER2A	, // PB 4 ** 10 ** PWM10	
302
+	TIMER1A	, // PB 5 ** 11 ** PWM11	
303
+	TIMER1B	, // PB 6 ** 12 ** PWM12	
304
+	TIMER0A	, // PB 7 ** 13 ** PWM13	
305
+	NOT_ON_TIMER	, // PJ 1 ** 14 ** USART3_TX	
306
+	NOT_ON_TIMER	, // PJ 0 ** 15 ** USART3_RX	
307
+	NOT_ON_TIMER	, // PH 1 ** 16 ** USART2_TX	
308
+	NOT_ON_TIMER	, // PH 0 ** 17 ** USART2_RX	
309
+	NOT_ON_TIMER	, // PD 3 ** 18 ** USART1_TX	
310
+	NOT_ON_TIMER	, // PD 2 ** 19 ** USART1_RX	
311
+	NOT_ON_TIMER	, // PD 1 ** 20 ** I2C_SDA	
312
+	NOT_ON_TIMER	, // PD 0 ** 21 ** I2C_SCL	
313
+	NOT_ON_TIMER	, // PA 0 ** 22 ** D22	
314
+	NOT_ON_TIMER	, // PA 1 ** 23 ** D23	
315
+	NOT_ON_TIMER	, // PA 2 ** 24 ** D24	
316
+	NOT_ON_TIMER	, // PA 3 ** 25 ** D25	
317
+	NOT_ON_TIMER	, // PA 4 ** 26 ** D26	
318
+	NOT_ON_TIMER	, // PA 5 ** 27 ** D27	
319
+	NOT_ON_TIMER	, // PA 6 ** 28 ** D28	
320
+	NOT_ON_TIMER	, // PA 7 ** 29 ** D29	
321
+	NOT_ON_TIMER	, // PC 7 ** 30 ** D30	
322
+	NOT_ON_TIMER	, // PC 6 ** 31 ** D31	
323
+	NOT_ON_TIMER	, // PC 5 ** 32 ** D32	
324
+	NOT_ON_TIMER	, // PC 4 ** 33 ** D33	
325
+	NOT_ON_TIMER	, // PC 3 ** 34 ** D34	
326
+	NOT_ON_TIMER	, // PC 2 ** 35 ** D35	
327
+	NOT_ON_TIMER	, // PC 1 ** 36 ** D36	
328
+	NOT_ON_TIMER	, // PC 0 ** 37 ** D37	
329
+	NOT_ON_TIMER	, // PD 7 ** 38 ** D38	
330
+	NOT_ON_TIMER	, // PG 2 ** 39 ** D39	
331
+	NOT_ON_TIMER	, // PG 1 ** 40 ** D40	
332
+	NOT_ON_TIMER	, // PG 0 ** 41 ** D41	
333
+	NOT_ON_TIMER	, // PL 7 ** 42 ** D42	
334
+	NOT_ON_TIMER	, // PL 6 ** 43 ** D43	
335
+	TIMER5C	, // PL 5 ** 44 ** D44	
336
+	TIMER5B	, // PL 4 ** 45 ** D45	
337
+	TIMER5A	, // PL 3 ** 46 ** D46	
338
+	NOT_ON_TIMER	, // PL 2 ** 47 ** D47	
339
+	NOT_ON_TIMER	, // PL 1 ** 48 ** D48	
340
+	NOT_ON_TIMER	, // PL 0 ** 49 ** D49	
341
+	NOT_ON_TIMER	, // PB 3 ** 50 ** SPI_MISO	
342
+	NOT_ON_TIMER	, // PB 2 ** 51 ** SPI_MOSI	
343
+	NOT_ON_TIMER	, // PB 1 ** 52 ** SPI_SCK	
344
+	NOT_ON_TIMER	, // PB 0 ** 53 ** SPI_SS	
345
+	NOT_ON_TIMER	, // PF 0 ** 54 ** A0	
346
+	NOT_ON_TIMER	, // PF 1 ** 55 ** A1	
347
+	NOT_ON_TIMER	, // PF 2 ** 56 ** A2	
348
+	NOT_ON_TIMER	, // PF 3 ** 57 ** A3	
349
+	NOT_ON_TIMER	, // PF 4 ** 58 ** A4	
350
+	NOT_ON_TIMER	, // PF 5 ** 59 ** A5	
351
+	NOT_ON_TIMER	, // PF 6 ** 60 ** A6	
352
+	NOT_ON_TIMER	, // PF 7 ** 61 ** A7	
353
+	NOT_ON_TIMER	, // PK 0 ** 62 ** A8	
354
+	NOT_ON_TIMER	, // PK 1 ** 63 ** A9	
355
+	NOT_ON_TIMER	, // PK 2 ** 64 ** A10	
356
+	NOT_ON_TIMER	, // PK 3 ** 65 ** A11	
357
+	NOT_ON_TIMER	, // PK 4 ** 66 ** A12	
358
+	NOT_ON_TIMER	, // PK 5 ** 67 ** A13	
359
+	NOT_ON_TIMER	, // PK 6 ** 68 ** A14	
360
+	NOT_ON_TIMER	, // PK 7 ** 69 ** A15	
361
+};
362
+
363
+#endif
364
+
365
+// These serial port names are intended to allow libraries and architecture-neutral
366
+// sketches to automatically default to the correct port name for a particular type
367
+// of use.  For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN,
368
+// the first hardware serial port whose RX/TX pins are not dedicated to another use.
369
+//
370
+// SERIAL_PORT_MONITOR        Port which normally prints to the Arduino Serial Monitor
371
+//
372
+// SERIAL_PORT_USBVIRTUAL     Port which is USB virtual serial
373
+//
374
+// SERIAL_PORT_LINUXBRIDGE    Port which connects to a Linux system via Bridge library
375
+//
376
+// SERIAL_PORT_HARDWARE       Hardware serial port, physical RX & TX pins.
377
+//
378
+// SERIAL_PORT_HARDWARE_OPEN  Hardware serial ports which are open for use.  Their RX & TX
379
+//                            pins are NOT connected to anything by default.
380
+#define SERIAL_PORT_MONITOR         Serial
381
+#define SERIAL_PORT_HARDWARE        Serial
382
+#define SERIAL_PORT_HARDWARE1       Serial1
383
+#define SERIAL_PORT_HARDWARE2       Serial2
384
+#define SERIAL_PORT_HARDWARE3       Serial3
385
+#define SERIAL_PORT_HARDWARE_OPEN   Serial1
386
+#define SERIAL_PORT_HARDWARE_OPEN1  Serial2
387
+#define SERIAL_PORT_HARDWARE_OPEN2  Serial3
388
+
389
+#endif

+ 411
- 0
ArduinoAddons/Arduino_1.6.x/hardware/marlin/avr/variants/rambo/pins_arduino.h Целия файл

@@ -0,0 +1,411 @@
1
+/*
2
+  pins_arduino.h - Pin definition functions for Arduino
3
+  Part of Arduino - http://www.arduino.cc/
4
+
5
+  Copyright (c) 2007 David A. Mellis
6
+
7
+  This library is free software; you can redistribute it and/or
8
+  modify it under the terms of the GNU Lesser General Public
9
+  License as published by the Free Software Foundation; either
10
+  version 2.1 of the License, or (at your option) any later version.
11
+
12
+  This library is distributed in the hope that it will be useful,
13
+  but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15
+  Lesser General Public License for more details.
16
+
17
+  You should have received a copy of the GNU Lesser General
18
+  Public License along with this library; if not, write to the
19
+  Free Software Foundation, Inc., 59 Temple Place, Suite 330,
20
+  Boston, MA  02111-1307  USA
21
+
22
+  $Id: wiring.h 249 2007-02-03 16:52:51Z mellis $
23
+*/
24
+
25
+#ifndef Pins_Arduino_h
26
+#define Pins_Arduino_h
27
+
28
+#include <avr/pgmspace.h>
29
+
30
+#define NUM_DIGITAL_PINS            82
31
+#define NUM_ANALOG_INPUTS           16
32
+#define analogInputToDigitalPin(p)  ((p < 16) ? (p) + 54 : -1)
33
+#define digitalPinHasPWM(p)         (((p) >= 2 && (p) <= 13) || ((p) >= 44 && (p)<= 46))
34
+
35
+static const uint8_t SS   = 53;
36
+static const uint8_t MOSI = 51;
37
+static const uint8_t MISO = 50;
38
+static const uint8_t SCK  = 52;
39
+
40
+static const uint8_t SDA = 20;
41
+static const uint8_t SCL = 21;
42
+static const uint8_t LED_BUILTIN = 13;
43
+
44
+static const uint8_t A0 = 54;
45
+static const uint8_t A1 = 55;
46
+static const uint8_t A2 = 56;
47
+static const uint8_t A3 = 57;
48
+static const uint8_t A4 = 58;
49
+static const uint8_t A5 = 59;
50
+static const uint8_t A6 = 60;
51
+static const uint8_t A7 = 61;
52
+static const uint8_t A8 = 62;
53
+static const uint8_t A9 = 63;
54
+static const uint8_t A10 = 64;
55
+static const uint8_t A11 = 65;
56
+static const uint8_t A12 = 66;
57
+static const uint8_t A13 = 67;
58
+static const uint8_t A14 = 68;
59
+static const uint8_t A15 = 69;
60
+
61
+// A majority of the pins are NOT PCINTs, SO BE WARNED (i.e. you cannot use them as receive pins)
62
+// Only pins available for RECEIVE (TRANSMIT can be on any pin):
63
+// (I've deliberately left out pin mapping to the Hardware USARTs - seems senseless to me)
64
+// Pins: 10, 11, 12, 13,  50, 51, 52, 53,  62, 63, 64, 65, 66, 67, 68, 69
65
+
66
+#define digitalPinToPCICR(p)    ( (((p) >= 10) && ((p) <= 13)) || \
67
+                                  (((p) >= 50) && ((p) <= 53)) || \
68
+                                  (((p) >= 62) && ((p) <= 69)) ? (&PCICR) : ((uint8_t *)0) )
69
+
70
+#define digitalPinToPCICRbit(p) ( (((p) >= 10) && ((p) <= 13)) || (((p) >= 50) && ((p) <= 53)) ? 0 : \
71
+                                ( (((p) >= 62) && ((p) <= 69)) ? 2 : \
72
+                                0 ) )
73
+
74
+#define digitalPinToPCMSK(p)    ( (((p) >= 10) && ((p) <= 13)) || (((p) >= 50) && ((p) <= 53)) ? (&PCMSK0) : \
75
+                                ( (((p) >= 62) && ((p) <= 69)) ? (&PCMSK2) : \
76
+                                ((uint8_t *)0) ) )
77
+
78
+#define digitalPinToPCMSKbit(p) ( (((p) >= 10) && ((p) <= 13)) ? ((p) - 6) : \
79
+                                ( ((p) == 50) ? 3 : \
80
+                                ( ((p) == 51) ? 2 : \
81
+                                ( ((p) == 52) ? 1 : \
82
+                                ( ((p) == 53) ? 0 : \
83
+                                ( (((p) >= 62) && ((p) <= 69)) ? ((p) - 62) : \
84
+                                0 ) ) ) ) ) )
85
+
86
+#ifdef ARDUINO_MAIN
87
+
88
+const uint16_t PROGMEM port_to_mode_PGM[] = {
89
+	NOT_A_PORT,
90
+	(uint16_t) &DDRA,
91
+	(uint16_t) &DDRB,
92
+	(uint16_t) &DDRC,
93
+	(uint16_t) &DDRD,
94
+	(uint16_t) &DDRE,
95
+	(uint16_t) &DDRF,
96
+	(uint16_t) &DDRG,
97
+	(uint16_t) &DDRH,
98
+	NOT_A_PORT,
99
+	(uint16_t) &DDRJ,
100
+	(uint16_t) &DDRK,
101
+	(uint16_t) &DDRL,
102
+};
103
+
104
+const uint16_t PROGMEM port_to_output_PGM[] = {
105
+	NOT_A_PORT,
106
+	(uint16_t) &PORTA,
107
+	(uint16_t) &PORTB,
108
+	(uint16_t) &PORTC,
109
+	(uint16_t) &PORTD,
110
+	(uint16_t) &PORTE,
111
+	(uint16_t) &PORTF,
112
+	(uint16_t) &PORTG,
113
+	(uint16_t) &PORTH,
114
+	NOT_A_PORT,
115
+	(uint16_t) &PORTJ,
116
+	(uint16_t) &PORTK,
117
+	(uint16_t) &PORTL,
118
+};
119
+
120
+const uint16_t PROGMEM port_to_input_PGM[] = {
121
+	NOT_A_PIN,
122
+	(uint16_t) &PINA,
123
+	(uint16_t) &PINB,
124
+	(uint16_t) &PINC,
125
+	(uint16_t) &PIND,
126
+	(uint16_t) &PINE,
127
+	(uint16_t) &PINF,
128
+	(uint16_t) &PING,
129
+	(uint16_t) &PINH,
130
+	NOT_A_PIN,
131
+	(uint16_t) &PINJ,
132
+	(uint16_t) &PINK,
133
+	(uint16_t) &PINL,
134
+};
135
+
136
+const uint8_t PROGMEM digital_pin_to_port_PGM[] = {
137
+	// PORTLIST
138
+	// -------------------------------------------
139
+	PE	, // PE 0 ** 0 ** USART0_RX
140
+	PE	, // PE 1 ** 1 ** USART0_TX
141
+	PE	, // PE 4 ** 2 ** PWM2
142
+	PE	, // PE 5 ** 3 ** PWM3
143
+	PG	, // PG 5 ** 4 ** PWM4
144
+	PE	, // PE 3 ** 5 ** PWM5
145
+	PH	, // PH 3 ** 6 ** PWM6
146
+	PH	, // PH 4 ** 7 ** PWM7
147
+	PH	, // PH 5 ** 8 ** PWM8
148
+	PH	, // PH 6 ** 9 ** PWM9
149
+	PB	, // PB 4 ** 10 ** PWM10
150
+	PB	, // PB 5 ** 11 ** PWM11
151
+	PB	, // PB 6 ** 12 ** PWM12
152
+	PB	, // PB 7 ** 13 ** PWM13
153
+	PJ	, // PJ 1 ** 14 ** USART3_TX
154
+	PJ	, // PJ 0 ** 15 ** USART3_RX
155
+	PH	, // PH 1 ** 16 ** USART2_TX
156
+	PH	, // PH 0 ** 17 ** USART2_RX
157
+	PD	, // PD 3 ** 18 ** USART1_TX
158
+	PD	, // PD 2 ** 19 ** USART1_RX
159
+	PD	, // PD 1 ** 20 ** I2C_SDA
160
+	PD	, // PD 0 ** 21 ** I2C_SCL
161
+	PA	, // PA 0 ** 22 ** D22
162
+	PA	, // PA 1 ** 23 ** D23
163
+	PA	, // PA 2 ** 24 ** D24
164
+	PA	, // PA 3 ** 25 ** D25
165
+	PA	, // PA 4 ** 26 ** D26
166
+	PA	, // PA 5 ** 27 ** D27
167
+	PA	, // PA 6 ** 28 ** D28
168
+	PA	, // PA 7 ** 29 ** D29
169
+	PC	, // PC 7 ** 30 ** D30
170
+	PC	, // PC 6 ** 31 ** D31
171
+	PC	, // PC 5 ** 32 ** D32
172
+	PC	, // PC 4 ** 33 ** D33
173
+	PC	, // PC 3 ** 34 ** D34
174
+	PC	, // PC 2 ** 35 ** D35
175
+	PC	, // PC 1 ** 36 ** D36
176
+	PC	, // PC 0 ** 37 ** D37
177
+	PD	, // PD 7 ** 38 ** D38
178
+	PG	, // PG 2 ** 39 ** D39
179
+	PG	, // PG 1 ** 40 ** D40
180
+	PG	, // PG 0 ** 41 ** D41
181
+	PL	, // PL 7 ** 42 ** D42
182
+	PL	, // PL 6 ** 43 ** D43
183
+	PL	, // PL 5 ** 44 ** D44
184
+	PL	, // PL 4 ** 45 ** D45
185
+	PL	, // PL 3 ** 46 ** D46
186
+	PL	, // PL 2 ** 47 ** D47
187
+	PL	, // PL 1 ** 48 ** D48
188
+	PL	, // PL 0 ** 49 ** D49
189
+	PB	, // PB 3 ** 50 ** SPI_MISO
190
+	PB	, // PB 2 ** 51 ** SPI_MOSI
191
+	PB	, // PB 1 ** 52 ** SPI_SCK
192
+	PB	, // PB 0 ** 53 ** SPI_SS
193
+	PF	, // PF 0 ** 54 ** A0
194
+	PF	, // PF 1 ** 55 ** A1
195
+	PF	, // PF 2 ** 56 ** A2
196
+	PF	, // PF 3 ** 57 ** A3
197
+	PF	, // PF 4 ** 58 ** A4
198
+	PF	, // PF 5 ** 59 ** A5
199
+	PF	, // PF 6 ** 60 ** A6
200
+	PF	, // PF 7 ** 61 ** A7
201
+	PK	, // PK 0 ** 62 ** A8
202
+	PK	, // PK 1 ** 63 ** A9
203
+	PK	, // PK 2 ** 64 ** A10
204
+	PK	, // PK 3 ** 65 ** A11
205
+	PK	, // PK 4 ** 66 ** A12
206
+	PK	, // PK 5 ** 67 ** A13
207
+	PK	, // PK 6 ** 68 ** A14
208
+	PK	, // PK 7 ** 69 ** A15
209
+	PG 	, // PG 4 ** 70 ** D70
210
+	PG 	, // PG 3 ** 71 ** D71
211
+	PJ 	, // PJ 2 ** 72 ** D72
212
+	PJ 	, // PJ 3 ** 73 ** D73
213
+	PJ 	, // PJ 7 ** 74 ** D74
214
+	PJ 	, // PJ 4 ** 75 ** D75
215
+	PJ 	, // PJ 5 ** 76 ** D76
216
+	PJ 	, // PJ 6 ** 77 ** D77
217
+	PE 	, // PE 2 ** 78 ** D78
218
+	PE 	, // PE 6 ** 79 ** D79
219
+	PE 	, // PE 7 ** 80 ** D80
220
+	PD 	, // PD 4 ** 81 ** D81
221
+	PD 	, // PD 5 ** 82 ** D82
222
+	PD 	, // PD 6 ** 83 ** D83
223
+	PH 	, // PH 2 ** 84 ** D84
224
+	PH 	, // PH 7 ** 85 ** D85
225
+};
226
+
227
+const uint8_t PROGMEM digital_pin_to_bit_mask_PGM[] = {
228
+	// PIN IN PORT
229
+	// -------------------------------------------
230
+	_BV( 0 )	, // PE 0 ** 0 ** USART0_RX
231
+	_BV( 1 )	, // PE 1 ** 1 ** USART0_TX
232
+	_BV( 4 )	, // PE 4 ** 2 ** PWM2
233
+	_BV( 5 )	, // PE 5 ** 3 ** PWM3
234
+	_BV( 5 )	, // PG 5 ** 4 ** PWM4
235
+	_BV( 3 )	, // PE 3 ** 5 ** PWM5
236
+	_BV( 3 )	, // PH 3 ** 6 ** PWM6
237
+	_BV( 4 )	, // PH 4 ** 7 ** PWM7
238
+	_BV( 5 )	, // PH 5 ** 8 ** PWM8
239
+	_BV( 6 )	, // PH 6 ** 9 ** PWM9
240
+	_BV( 4 )	, // PB 4 ** 10 ** PWM10
241
+	_BV( 5 )	, // PB 5 ** 11 ** PWM11
242
+	_BV( 6 )	, // PB 6 ** 12 ** PWM12
243
+	_BV( 7 )	, // PB 7 ** 13 ** PWM13
244
+	_BV( 1 )	, // PJ 1 ** 14 ** USART3_TX
245
+	_BV( 0 )	, // PJ 0 ** 15 ** USART3_RX
246
+	_BV( 1 )	, // PH 1 ** 16 ** USART2_TX
247
+	_BV( 0 )	, // PH 0 ** 17 ** USART2_RX
248
+	_BV( 3 )	, // PD 3 ** 18 ** USART1_TX
249
+	_BV( 2 )	, // PD 2 ** 19 ** USART1_RX
250
+	_BV( 1 )	, // PD 1 ** 20 ** I2C_SDA
251
+	_BV( 0 )	, // PD 0 ** 21 ** I2C_SCL
252
+	_BV( 0 )	, // PA 0 ** 22 ** D22
253
+	_BV( 1 )	, // PA 1 ** 23 ** D23
254
+	_BV( 2 )	, // PA 2 ** 24 ** D24
255
+	_BV( 3 )	, // PA 3 ** 25 ** D25
256
+	_BV( 4 )	, // PA 4 ** 26 ** D26
257
+	_BV( 5 )	, // PA 5 ** 27 ** D27
258
+	_BV( 6 )	, // PA 6 ** 28 ** D28
259
+	_BV( 7 )	, // PA 7 ** 29 ** D29
260
+	_BV( 7 )	, // PC 7 ** 30 ** D30
261
+	_BV( 6 )	, // PC 6 ** 31 ** D31
262
+	_BV( 5 )	, // PC 5 ** 32 ** D32
263
+	_BV( 4 )	, // PC 4 ** 33 ** D33
264
+	_BV( 3 )	, // PC 3 ** 34 ** D34
265
+	_BV( 2 )	, // PC 2 ** 35 ** D35
266
+	_BV( 1 )	, // PC 1 ** 36 ** D36
267
+	_BV( 0 )	, // PC 0 ** 37 ** D37
268
+	_BV( 7 )	, // PD 7 ** 38 ** D38
269
+	_BV( 2 )	, // PG 2 ** 39 ** D39
270
+	_BV( 1 )	, // PG 1 ** 40 ** D40
271
+	_BV( 0 )	, // PG 0 ** 41 ** D41
272
+	_BV( 7 )	, // PL 7 ** 42 ** D42
273
+	_BV( 6 )	, // PL 6 ** 43 ** D43
274
+	_BV( 5 )	, // PL 5 ** 44 ** D44
275
+	_BV( 4 )	, // PL 4 ** 45 ** D45
276
+	_BV( 3 )	, // PL 3 ** 46 ** D46
277
+	_BV( 2 )	, // PL 2 ** 47 ** D47
278
+	_BV( 1 )	, // PL 1 ** 48 ** D48
279
+	_BV( 0 )	, // PL 0 ** 49 ** D49
280
+	_BV( 3 )	, // PB 3 ** 50 ** SPI_MISO
281
+	_BV( 2 )	, // PB 2 ** 51 ** SPI_MOSI
282
+	_BV( 1 )	, // PB 1 ** 52 ** SPI_SCK
283
+	_BV( 0 )	, // PB 0 ** 53 ** SPI_SS
284
+	_BV( 0 )	, // PF 0 ** 54 ** A0
285
+	_BV( 1 )	, // PF 1 ** 55 ** A1
286
+	_BV( 2 )	, // PF 2 ** 56 ** A2
287
+	_BV( 3 )	, // PF 3 ** 57 ** A3
288
+	_BV( 4 )	, // PF 4 ** 58 ** A4
289
+	_BV( 5 )	, // PF 5 ** 59 ** A5
290
+	_BV( 6 )	, // PF 6 ** 60 ** A6
291
+	_BV( 7 )	, // PF 7 ** 61 ** A7
292
+	_BV( 0 )	, // PK 0 ** 62 ** A8
293
+	_BV( 1 )	, // PK 1 ** 63 ** A9
294
+	_BV( 2 )	, // PK 2 ** 64 ** A10
295
+	_BV( 3 )	, // PK 3 ** 65 ** A11
296
+	_BV( 4 )	, // PK 4 ** 66 ** A12
297
+	_BV( 5 )	, // PK 5 ** 67 ** A13
298
+	_BV( 6 )	, // PK 6 ** 68 ** A14
299
+	_BV( 7 )	, // PK 7 ** 69 ** A15
300
+	_BV( 4 )	, // PG 4 ** 70 ** D70
301
+	_BV( 3 )	, // PG 3 ** 71 ** D71
302
+	_BV( 2 )	, // PJ 2 ** 72 ** D72
303
+	_BV( 3 )	, // PJ 3 ** 73 ** D73
304
+	_BV( 7 )	, // PJ 7 ** 74 ** D74
305
+	_BV( 4 )	, // PJ 4 ** 75 ** D75
306
+	_BV( 5 )	, // PJ 5 ** 76 ** D76
307
+	_BV( 6 )	, // PJ 6 ** 77 ** D77
308
+	_BV( 2 )	, // PE 2 ** 78 ** D78
309
+	_BV( 6 )	, // PE 6 ** 79 ** D79
310
+	_BV( 7 )	, // PE 7 ** 80 ** D80
311
+	_BV( 4 )	, // PD 4 ** 81 ** D81
312
+	_BV( 5 ) 	, // PD 5 ** 82 ** D82
313
+	_BV( 6 ) 	, // PD 6 ** 83 ** D83
314
+	_BV( 2 ) 	, // PH 2 ** 84 ** D84
315
+	_BV( 7 ) 	, // PH 7 ** 85 ** D85
316
+};
317
+
318
+const uint8_t PROGMEM digital_pin_to_timer_PGM[] = {
319
+	// TIMERS
320
+	// -------------------------------------------
321
+	NOT_ON_TIMER	, // PE 0 ** 0 ** USART0_RX
322
+	NOT_ON_TIMER	, // PE 1 ** 1 ** USART0_TX
323
+	TIMER3B		, // PE 4 ** 2 ** PWM2
324
+	TIMER3C		, // PE 5 ** 3 ** PWM3
325
+	TIMER0B		, // PG 5 ** 4 ** PWM4
326
+	TIMER3A		, // PE 3 ** 5 ** PWM5
327
+	TIMER4A		, // PH 3 ** 6 ** PWM6
328
+	TIMER4B		, // PH 4 ** 7 ** PWM7
329
+	TIMER4C		, // PH 5 ** 8 ** PWM8
330
+	TIMER2B		, // PH 6 ** 9 ** PWM9
331
+	TIMER2A		, // PB 4 ** 10 ** PWM10
332
+	TIMER1A		, // PB 5 ** 11 ** PWM11
333
+	TIMER1B		, // PB 6 ** 12 ** PWM12
334
+	TIMER0A		, // PB 7 ** 13 ** PWM13
335
+	NOT_ON_TIMER	, // PJ 1 ** 14 ** USART3_TX
336
+	NOT_ON_TIMER	, // PJ 0 ** 15 ** USART3_RX
337
+	NOT_ON_TIMER	, // PH 1 ** 16 ** USART2_TX
338
+	NOT_ON_TIMER	, // PH 0 ** 17 ** USART2_RX
339
+	NOT_ON_TIMER	, // PD 3 ** 18 ** USART1_TX
340
+	NOT_ON_TIMER	, // PD 2 ** 19 ** USART1_RX
341
+	NOT_ON_TIMER	, // PD 1 ** 20 ** I2C_SDA
342
+	NOT_ON_TIMER	, // PD 0 ** 21 ** I2C_SCL
343
+	NOT_ON_TIMER	, // PA 0 ** 22 ** D22
344
+	NOT_ON_TIMER	, // PA 1 ** 23 ** D23
345
+	NOT_ON_TIMER	, // PA 2 ** 24 ** D24
346
+	NOT_ON_TIMER	, // PA 3 ** 25 ** D25
347
+	NOT_ON_TIMER	, // PA 4 ** 26 ** D26
348
+	NOT_ON_TIMER	, // PA 5 ** 27 ** D27
349
+	NOT_ON_TIMER	, // PA 6 ** 28 ** D28
350
+	NOT_ON_TIMER	, // PA 7 ** 29 ** D29
351
+	NOT_ON_TIMER	, // PC 7 ** 30 ** D30
352
+	NOT_ON_TIMER	, // PC 6 ** 31 ** D31
353
+	NOT_ON_TIMER	, // PC 5 ** 32 ** D32
354
+	NOT_ON_TIMER	, // PC 4 ** 33 ** D33
355
+	NOT_ON_TIMER	, // PC 3 ** 34 ** D34
356
+	NOT_ON_TIMER	, // PC 2 ** 35 ** D35
357
+	NOT_ON_TIMER	, // PC 1 ** 36 ** D36
358
+	NOT_ON_TIMER	, // PC 0 ** 37 ** D37
359
+	NOT_ON_TIMER	, // PD 7 ** 38 ** D38
360
+	NOT_ON_TIMER	, // PG 2 ** 39 ** D39
361
+	NOT_ON_TIMER	, // PG 1 ** 40 ** D40
362
+	NOT_ON_TIMER	, // PG 0 ** 41 ** D41
363
+	NOT_ON_TIMER	, // PL 7 ** 42 ** D42
364
+	NOT_ON_TIMER	, // PL 6 ** 43 ** D43
365
+	TIMER5C		, // PL 5 ** 44 ** D44
366
+	TIMER5B		, // PL 4 ** 45 ** D45
367
+	TIMER5A		, // PL 3 ** 46 ** D46
368
+	NOT_ON_TIMER	, // PL 2 ** 47 ** D47
369
+	NOT_ON_TIMER	, // PL 1 ** 48 ** D48
370
+	NOT_ON_TIMER	, // PL 0 ** 49 ** D49
371
+	NOT_ON_TIMER	, // PB 3 ** 50 ** SPI_MISO
372
+	NOT_ON_TIMER	, // PB 2 ** 51 ** SPI_MOSI
373
+	NOT_ON_TIMER	, // PB 1 ** 52 ** SPI_SCK
374
+	NOT_ON_TIMER	, // PB 0 ** 53 ** SPI_SS
375
+	NOT_ON_TIMER	, // PF 0 ** 54 ** A0	
376
+	NOT_ON_TIMER	, // PF 1 ** 55 ** A1	
377
+	NOT_ON_TIMER	, // PF 2 ** 56 ** A2	
378
+	NOT_ON_TIMER	, // PF 3 ** 57 ** A3	
379
+	NOT_ON_TIMER	, // PF 4 ** 58 ** A4	
380
+	NOT_ON_TIMER	, // PF 5 ** 59 ** A5	
381
+	NOT_ON_TIMER	, // PF 6 ** 60 ** A6	
382
+	NOT_ON_TIMER	, // PF 7 ** 61 ** A7	
383
+	NOT_ON_TIMER	, // PK 0 ** 62 ** A8	
384
+	NOT_ON_TIMER	, // PK 1 ** 63 ** A9	
385
+	NOT_ON_TIMER	, // PK 2 ** 64 ** A10	
386
+	NOT_ON_TIMER	, // PK 3 ** 65 ** A11	
387
+	NOT_ON_TIMER	, // PK 4 ** 66 ** A12	
388
+	NOT_ON_TIMER	, // PK 5 ** 67 ** A13	
389
+	NOT_ON_TIMER	, // PK 6 ** 68 ** A14	
390
+	NOT_ON_TIMER	, // PK 7 ** 69 ** A15
391
+	NOT_ON_TIMER	, // PG 4 ** 70 ** D70
392
+	NOT_ON_TIMER	, // PG 3 ** 71 ** D71
393
+	NOT_ON_TIMER	, // PJ 2 ** 72 ** D72
394
+	NOT_ON_TIMER	, // PJ 3 ** 73 ** D73
395
+	NOT_ON_TIMER	, // PJ 7 ** 74 ** D74
396
+	NOT_ON_TIMER	, // PJ 4 ** 75 ** D75
397
+	NOT_ON_TIMER	, // PJ 5 ** 76 ** D76
398
+	NOT_ON_TIMER	, // PJ 6 ** 77 ** D77
399
+	NOT_ON_TIMER	, // PE 2 ** 78 ** D78
400
+	NOT_ON_TIMER	, // PE 6 ** 79 ** D79
401
+	NOT_ON_TIMER	, // PE 7 ** 80 ** D80
402
+	NOT_ON_TIMER	, // PD 4 ** 81 ** D81
403
+	NOT_ON_TIMER 	, // PD 5 ** 82 ** D82
404
+	NOT_ON_TIMER 	, // PD 6 ** 83 ** D83
405
+	NOT_ON_TIMER 	, // PH 2 ** 84 ** D84
406
+	NOT_ON_TIMER 	, // PH 7 ** 85 ** D85
407
+};
408
+
409
+#endif
410
+
411
+#endif

+ 285
- 0
ArduinoAddons/Arduino_1.6.x/hardware/marlin/avr/variants/sanguino/pins_arduino.h Целия файл

@@ -0,0 +1,285 @@
1
+/*
2
+  pins_arduino.h - Pin definition functions for Arduino
3
+  Part of Arduino - http://www.arduino.cc/
4
+
5
+  Copyright (c) 2007 David A. Mellis
6
+
7
+  This library is free software; you can redistribute it and/or
8
+  modify it under the terms of the GNU Lesser General Public
9
+  License as published by the Free Software Foundation; either
10
+  version 2.1 of the License, or (at your option) any later version.
11
+
12
+  This library is distributed in the hope that it will be useful,
13
+  but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15
+  Lesser General Public License for more details.
16
+
17
+  You should have received a copy of the GNU Lesser General
18
+  Public License along with this library; if not, write to the
19
+  Free Software Foundation, Inc., 59 Temple Place, Suite 330,
20
+  Boston, MA  02111-1307  USA
21
+
22
+  $Id: wiring.h 249 2007-02-03 16:52:51Z mellis $
23
+
24
+  Changelog
25
+  -----------
26
+  11/25/11  - ryan@ryanmsutton.com - Add pins for Sanguino 644P and 1284P
27
+  07/15/12  - ryan@ryanmsutton.com - Updated for arduino0101
28
+*/
29
+
30
+#ifndef Pins_Arduino_h
31
+#define Pins_Arduino_h
32
+
33
+#include <avr/pgmspace.h>
34
+
35
+#define NOT_A_PIN 0
36
+#define NOT_A_PORT 0
37
+
38
+#define NOT_ON_TIMER 0
39
+#define TIMER0A 1
40
+#define TIMER0B 2
41
+#define TIMER1A 3
42
+#define TIMER1B 4
43
+#define TIMER2  5
44
+#define TIMER2A 6
45
+#define TIMER2B 7
46
+
47
+#define TIMER3A 8
48
+#define TIMER3B 9
49
+#define TIMER3C 10
50
+#define TIMER4A 11
51
+#define TIMER4B 12
52
+#define TIMER4C 13
53
+#define TIMER5A 14
54
+#define TIMER5B 15
55
+#define TIMER5C 16
56
+
57
+const static uint8_t SS   = 4;
58
+const static uint8_t MOSI = 5;
59
+const static uint8_t MISO = 6;
60
+const static uint8_t SCK  = 7;
61
+
62
+static const uint8_t SDA = 17;
63
+static const uint8_t SCL = 16;
64
+static const uint8_t LED_BUILTIN = 13;
65
+
66
+static const uint8_t A0 = 31;
67
+static const uint8_t A1 = 30;
68
+static const uint8_t A2 = 29;
69
+static const uint8_t A3 = 28;
70
+static const uint8_t A4 = 27;
71
+static const uint8_t A5 = 26;
72
+static const uint8_t A6 = 25;
73
+static const uint8_t A7 = 24;
74
+
75
+// On the ATmega1280, the addresses of some of the port registers are
76
+// greater than 255, so we can't store them in uint8_t's.
77
+// extern const uint16_t PROGMEM port_to_mode_PGM[];
78
+// extern const uint16_t PROGMEM port_to_input_PGM[];
79
+// extern const uint16_t PROGMEM port_to_output_PGM[];
80
+
81
+// extern const uint8_t PROGMEM digital_pin_to_port_PGM[];
82
+// extern const uint8_t PROGMEM digital_pin_to_bit_PGM[];
83
+// extern const uint8_t PROGMEM digital_pin_to_bit_mask_PGM[];
84
+// extern const uint8_t PROGMEM digital_pin_to_timer_PGM[];
85
+
86
+// ATMEL ATMEGA644P / SANGUINO
87
+//
88
+//                   +---\/---+
89
+//  INT0 (D 0) PB0  1|        |40  PA0 (AI 0 / D31)
90
+//  INT1 (D 1) PB1  2|        |39  PA1 (AI 1 / D30)
91
+//  INT2 (D 2) PB2  3|        |38  PA2 (AI 2 / D29)
92
+//   PWM (D 3) PB3  4|        |37  PA3 (AI 3 / D28)
93
+//   PWM (D 4) PB4  5|        |36  PA4 (AI 4 / D27)
94
+//  MOSI (D 5) PB5  6|        |35  PA5 (AI 5 / D26)
95
+//  MISO (D 6) PB6  7|        |34  PA6 (AI 6 / D25)
96
+//   SCK (D 7) PB7  8|        |33  PA7 (AI 7 / D24)
97
+//             RST  9|        |32  AREF
98
+//             VCC 10|        |31  GND 
99
+//             GND 11|        |30  AVCC
100
+//           XTAL2 12|        |29  PC7 (D 23)
101
+//           XTAL1 13|        |28  PC6 (D 22)
102
+//  RX0 (D 8)  PD0 14|        |27  PC5 (D 21) TDI
103
+//  TX0 (D 9)  PD1 15|        |26  PC4 (D 20) TDO
104
+//  RX1 (D 10) PD2 16|        |25  PC3 (D 19) TMS
105
+//  TX1 (D 11) PD3 17|        |24  PC2 (D 18) TCK
106
+//  PWM (D 12) PD4 18|        |23  PC1 (D 17) SDA
107
+//  PWM (D 13) PD5 19|        |22  PC0 (D 16) SCL
108
+//  PWM (D 14) PD6 20|        |21  PD7 (D 15) PWM
109
+//                   +--------+
110
+//
111
+#define NUM_DIGITAL_PINS            24
112
+#define NUM_ANALOG_INPUTS           8
113
+#define analogInputToDigitalPin(p)  ((p < 7) ? (p) + 24 : -1)
114
+
115
+#define digitalPinHasPWM(p)         ((p) == 3 || (p) == 4 || (p) == 12 || (p) == 13 || (p) == 14 || (p) == 15 )
116
+
117
+#define digitalPinToPCICR(p)    ( (((p) >= 0) && ((p) <= 31)) ? (&PCICR) : ((uint8_t *)0) )
118
+
119
+#define digitalPinToPCICRbit(p) ( (((p) >= 24) && ((p) <= 31)) ? 0 : \
120
+                                ( (((p) >=  0) && ((p) <=  7)) ? 1 : \
121
+                                ( (((p) >= 16) && ((p) <= 23)) ? 2 : \
122
+                                ( (((p) >=  8) && ((p) <= 15)) ? 3 : \
123
+                                0 ) ) ) )
124
+
125
+#define digitalPinToPCMSK(p)    ( (((p) >= 24) && ((p) <= 31)) ? (&PCMSK0) : \
126
+                                ( (((p) >=  0) && ((p) <=  7)) ? (&PCMSK1) : \
127
+                                ( (((p) >= 16) && ((p) <= 23)) ? (&PCMSK2) : \
128
+                                ( (((p) >=  8) && ((p) <= 15)) ? (&PCMSK3) : \
129
+                                ((uint8_t *)0) ) ) ) )
130
+
131
+
132
+#define digitalPinToPCMSKbit(p) ( (((p) >= 24) && ((p) <= 31)) ? (31 - (p)) : \
133
+                                ( (((p) >=  0) && ((p) <=  7)) ? (p) : \
134
+                                ( (((p) >= 16) && ((p) <= 23)) ? ((p) - 16) : \
135
+                                ( (((p) >=  8) && ((p) <= 15)) ? ((p) - 8) : \
136
+                                0 ) ) ) )
137
+
138
+#define PA 1
139
+#define PB 2
140
+#define PC 3
141
+#define PD 4
142
+#define PE 5
143
+#define PF 6
144
+#define PG 7
145
+#define PH 8
146
+#define PJ 10
147
+#define PK 11
148
+#define PL 12
149
+
150
+#ifdef ARDUINO_MAIN
151
+// these arrays map port names (e.g. port B) to the
152
+// appropriate addresses for various functions (e.g. reading
153
+// and writing)
154
+const uint16_t PROGMEM port_to_mode_PGM[] =
155
+{
156
+        NOT_A_PORT,
157
+        (uint16_t) &DDRA,
158
+        (uint16_t) &DDRB,
159
+        (uint16_t) &DDRC,
160
+        (uint16_t) &DDRD,
161
+};
162
+
163
+const uint16_t PROGMEM port_to_output_PGM[] =
164
+{
165
+        NOT_A_PORT,
166
+        (uint16_t) &PORTA,
167
+        (uint16_t) &PORTB,
168
+        (uint16_t) &PORTC,
169
+        (uint16_t) &PORTD,
170
+};
171
+const uint16_t PROGMEM port_to_input_PGM[] =
172
+{
173
+        NOT_A_PORT,
174
+        (uint16_t) &PINA,
175
+        (uint16_t) &PINB,
176
+        (uint16_t) &PINC,
177
+        (uint16_t) &PIND,
178
+};
179
+const uint8_t PROGMEM digital_pin_to_port_PGM[] =
180
+{
181
+        PB, /* 0 */
182
+        PB,
183
+        PB,
184
+        PB,
185
+        PB,
186
+        PB,
187
+        PB,
188
+        PB,
189
+        PD, /* 8 */
190
+        PD,
191
+        PD,
192
+        PD,
193
+        PD,
194
+        PD,
195
+        PD,
196
+        PD,
197
+        PC, /* 16 */
198
+        PC,
199
+        PC,
200
+        PC,
201
+        PC,
202
+        PC,
203
+        PC,
204
+        PC,
205
+        PA, /* 24 */
206
+        PA,
207
+        PA,
208
+        PA,
209
+        PA,
210
+        PA,
211
+        PA,
212
+        PA  /* 31 */
213
+};
214
+const uint8_t PROGMEM digital_pin_to_bit_mask_PGM[] =
215
+{
216
+        _BV(0), /* 0, port B */
217
+        _BV(1),
218
+        _BV(2),
219
+        _BV(3),
220
+        _BV(4),
221
+        _BV(5),
222
+        _BV(6),
223
+        _BV(7),
224
+        _BV(0), /* 8, port D */
225
+        _BV(1),
226
+        _BV(2),
227
+        _BV(3),
228
+        _BV(4),
229
+        _BV(5),
230
+        _BV(6),
231
+        _BV(7),
232
+        _BV(0), /* 16, port C */
233
+        _BV(1),
234
+        _BV(2),
235
+        _BV(3),
236
+        _BV(4),
237
+        _BV(5),
238
+        _BV(6),
239
+        _BV(7),
240
+        _BV(7), /* 24, port A */
241
+        _BV(6),
242
+        _BV(5),
243
+        _BV(4),
244
+        _BV(3),
245
+        _BV(2),
246
+        _BV(1),
247
+        _BV(0)
248
+};
249
+const uint8_t PROGMEM digital_pin_to_timer_PGM[] =
250
+{
251
+        NOT_ON_TIMER,   /* 0  - PB0 */
252
+        NOT_ON_TIMER,   /* 1  - PB1 */
253
+        NOT_ON_TIMER,   /* 2  - PB2 */
254
+        TIMER0A,        /* 3  - PB3 */
255
+        TIMER0B,                /* 4  - PB4 */
256
+        NOT_ON_TIMER,   /* 5  - PB5 */
257
+        NOT_ON_TIMER,   /* 6  - PB6 */
258
+        NOT_ON_TIMER,   /* 7  - PB7 */
259
+        NOT_ON_TIMER,   /* 8  - PD0 */
260
+        NOT_ON_TIMER,   /* 9  - PD1 */
261
+        NOT_ON_TIMER,   /* 10 - PD2 */
262
+        NOT_ON_TIMER,   /* 11 - PD3 */
263
+        TIMER1B,        /* 12 - PD4 */
264
+        TIMER1A,        /* 13 - PD5 */
265
+        TIMER2B,        /* 14 - PD6 */
266
+        TIMER2A,        /* 15 - PD7 */
267
+        NOT_ON_TIMER,   /* 16 - PC0 */
268
+        NOT_ON_TIMER,   /* 17 - PC1 */
269
+        NOT_ON_TIMER,   /* 18 - PC2 */
270
+        NOT_ON_TIMER,   /* 19 - PC3 */
271
+        NOT_ON_TIMER,   /* 20 - PC4 */
272
+        NOT_ON_TIMER,   /* 21 - PC5 */
273
+        NOT_ON_TIMER,   /* 22 - PC6 */
274
+        NOT_ON_TIMER,   /* 23 - PC7 */
275
+        NOT_ON_TIMER,   /* 24 - PA0 */
276
+        NOT_ON_TIMER,   /* 25 - PA1 */
277
+        NOT_ON_TIMER,   /* 26 - PA2 */
278
+        NOT_ON_TIMER,   /* 27 - PA3 */
279
+        NOT_ON_TIMER,   /* 28 - PA4 */
280
+        NOT_ON_TIMER,   /* 29 - PA5 */
281
+        NOT_ON_TIMER,   /* 30 - PA6 */
282
+        NOT_ON_TIMER   /* 31 - PA7 */
283
+};
284
+#endif
285
+#endif

+ 238
- 0
ArduinoAddons/Arduino_1.6.x/hardware/marlin/avr/variants/standard/pins_arduino.h Целия файл

@@ -0,0 +1,238 @@
1
+/*
2
+  pins_arduino.h - Pin definition functions for Arduino
3
+  Part of Arduino - http://www.arduino.cc/
4
+
5
+  Copyright (c) 2007 David A. Mellis
6
+
7
+  This library is free software; you can redistribute it and/or
8
+  modify it under the terms of the GNU Lesser General Public
9
+  License as published by the Free Software Foundation; either
10
+  version 2.1 of the License, or (at your option) any later version.
11
+
12
+  This library is distributed in the hope that it will be useful,
13
+  but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15
+  Lesser General Public License for more details.
16
+
17
+  You should have received a copy of the GNU Lesser General
18
+  Public License along with this library; if not, write to the
19
+  Free Software Foundation, Inc., 59 Temple Place, Suite 330,
20
+  Boston, MA  02111-1307  USA
21
+
22
+  $Id: wiring.h 249 2007-02-03 16:52:51Z mellis $
23
+*/
24
+
25
+#ifndef Pins_Arduino_h
26
+#define Pins_Arduino_h
27
+
28
+#include <avr/pgmspace.h>
29
+
30
+#define NUM_DIGITAL_PINS            20
31
+#define NUM_ANALOG_INPUTS           6
32
+#define analogInputToDigitalPin(p)  ((p < 6) ? (p) + 14 : -1)
33
+
34
+#if defined(__AVR_ATmega8__)
35
+#define digitalPinHasPWM(p)         ((p) == 9 || (p) == 10 || (p) == 11)
36
+#else
37
+#define digitalPinHasPWM(p)         ((p) == 3 || (p) == 5 || (p) == 6 || (p) == 9 || (p) == 10 || (p) == 11)
38
+#endif
39
+
40
+static const uint8_t SS   = 10;
41
+static const uint8_t MOSI = 11;
42
+static const uint8_t MISO = 12;
43
+static const uint8_t SCK  = 13;
44
+
45
+static const uint8_t SDA = 18;
46
+static const uint8_t SCL = 19;
47
+#define LED_BUILTIN 13
48
+
49
+static const uint8_t A0 = 14;
50
+static const uint8_t A1 = 15;
51
+static const uint8_t A2 = 16;
52
+static const uint8_t A3 = 17;
53
+static const uint8_t A4 = 18;
54
+static const uint8_t A5 = 19;
55
+static const uint8_t A6 = 20;
56
+static const uint8_t A7 = 21;
57
+
58
+#define digitalPinToPCICR(p)    (((p) >= 0 && (p) <= 21) ? (&PCICR) : ((uint8_t *)0))
59
+#define digitalPinToPCICRbit(p) (((p) <= 7) ? 2 : (((p) <= 13) ? 0 : 1))
60
+#define digitalPinToPCMSK(p)    (((p) <= 7) ? (&PCMSK2) : (((p) <= 13) ? (&PCMSK0) : (((p) <= 21) ? (&PCMSK1) : ((uint8_t *)0))))
61
+#define digitalPinToPCMSKbit(p) (((p) <= 7) ? (p) : (((p) <= 13) ? ((p) - 8) : ((p) - 14)))
62
+
63
+#define digitalPinToInterrupt(p)  ((p) == 2 ? 0 : ((p) == 3 ? 1 : NOT_AN_INTERRUPT))
64
+
65
+#ifdef ARDUINO_MAIN
66
+
67
+// On the Arduino board, digital pins are also used
68
+// for the analog output (software PWM).  Analog input
69
+// pins are a separate set.
70
+
71
+// ATMEL ATMEGA8 & 168 / ARDUINO
72
+//
73
+//                  +-\/-+
74
+//            PC6  1|    |28  PC5 (AI 5)
75
+//      (D 0) PD0  2|    |27  PC4 (AI 4)
76
+//      (D 1) PD1  3|    |26  PC3 (AI 3)
77
+//      (D 2) PD2  4|    |25  PC2 (AI 2)
78
+// PWM+ (D 3) PD3  5|    |24  PC1 (AI 1)
79
+//      (D 4) PD4  6|    |23  PC0 (AI 0)
80
+//            VCC  7|    |22  GND
81
+//            GND  8|    |21  AREF
82
+//            PB6  9|    |20  AVCC
83
+//            PB7 10|    |19  PB5 (D 13)
84
+// PWM+ (D 5) PD5 11|    |18  PB4 (D 12)
85
+// PWM+ (D 6) PD6 12|    |17  PB3 (D 11) PWM
86
+//      (D 7) PD7 13|    |16  PB2 (D 10) PWM
87
+//      (D 8) PB0 14|    |15  PB1 (D 9) PWM
88
+//                  +----+
89
+//
90
+// (PWM+ indicates the additional PWM pins on the ATmega168.)
91
+
92
+// ATMEL ATMEGA1280 / ARDUINO
93
+//
94
+// 0-7 PE0-PE7   works
95
+// 8-13 PB0-PB5  works
96
+// 14-21 PA0-PA7 works 
97
+// 22-29 PH0-PH7 works
98
+// 30-35 PG5-PG0 works
99
+// 36-43 PC7-PC0 works
100
+// 44-51 PJ7-PJ0 works
101
+// 52-59 PL7-PL0 works
102
+// 60-67 PD7-PD0 works
103
+// A0-A7 PF0-PF7
104
+// A8-A15 PK0-PK7
105
+
106
+
107
+// these arrays map port names (e.g. port B) to the
108
+// appropriate addresses for various functions (e.g. reading
109
+// and writing)
110
+const uint16_t PROGMEM port_to_mode_PGM[] = {
111
+	NOT_A_PORT,
112
+	NOT_A_PORT,
113
+	(uint16_t) &DDRB,
114
+	(uint16_t) &DDRC,
115
+	(uint16_t) &DDRD,
116
+};
117
+
118
+const uint16_t PROGMEM port_to_output_PGM[] = {
119
+	NOT_A_PORT,
120
+	NOT_A_PORT,
121
+	(uint16_t) &PORTB,
122
+	(uint16_t) &PORTC,
123
+	(uint16_t) &PORTD,
124
+};
125
+
126
+const uint16_t PROGMEM port_to_input_PGM[] = {
127
+	NOT_A_PORT,
128
+	NOT_A_PORT,
129
+	(uint16_t) &PINB,
130
+	(uint16_t) &PINC,
131
+	(uint16_t) &PIND,
132
+};
133
+
134
+const uint8_t PROGMEM digital_pin_to_port_PGM[] = {
135
+	PD, /* 0 */
136
+	PD,
137
+	PD,
138
+	PD,
139
+	PD,
140
+	PD,
141
+	PD,
142
+	PD,
143
+	PB, /* 8 */
144
+	PB,
145
+	PB,
146
+	PB,
147
+	PB,
148
+	PB,
149
+	PC, /* 14 */
150
+	PC,
151
+	PC,
152
+	PC,
153
+	PC,
154
+	PC,
155
+};
156
+
157
+const uint8_t PROGMEM digital_pin_to_bit_mask_PGM[] = {
158
+	_BV(0), /* 0, port D */
159
+	_BV(1),
160
+	_BV(2),
161
+	_BV(3),
162
+	_BV(4),
163
+	_BV(5),
164
+	_BV(6),
165
+	_BV(7),
166
+	_BV(0), /* 8, port B */
167
+	_BV(1),
168
+	_BV(2),
169
+	_BV(3),
170
+	_BV(4),
171
+	_BV(5),
172
+	_BV(0), /* 14, port C */
173
+	_BV(1),
174
+	_BV(2),
175
+	_BV(3),
176
+	_BV(4),
177
+	_BV(5),
178
+};
179
+
180
+const uint8_t PROGMEM digital_pin_to_timer_PGM[] = {
181
+	NOT_ON_TIMER, /* 0 - port D */
182
+	NOT_ON_TIMER,
183
+	NOT_ON_TIMER,
184
+	// on the ATmega168, digital pin 3 has hardware pwm
185
+#if defined(__AVR_ATmega8__)
186
+	NOT_ON_TIMER,
187
+#else
188
+	TIMER2B,
189
+#endif
190
+	NOT_ON_TIMER,
191
+	// on the ATmega168, digital pins 5 and 6 have hardware pwm
192
+#if defined(__AVR_ATmega8__)
193
+	NOT_ON_TIMER,
194
+	NOT_ON_TIMER,
195
+#else
196
+	TIMER0B,
197
+	TIMER0A,
198
+#endif
199
+	NOT_ON_TIMER,
200
+	NOT_ON_TIMER, /* 8 - port B */
201
+	TIMER1A,
202
+	TIMER1B,
203
+#if defined(__AVR_ATmega8__)
204
+	TIMER2,
205
+#else
206
+	TIMER2A,
207
+#endif
208
+	NOT_ON_TIMER,
209
+	NOT_ON_TIMER,
210
+	NOT_ON_TIMER,
211
+	NOT_ON_TIMER, /* 14 - port C */
212
+	NOT_ON_TIMER,
213
+	NOT_ON_TIMER,
214
+	NOT_ON_TIMER,
215
+	NOT_ON_TIMER,
216
+};
217
+
218
+#endif
219
+
220
+// These serial port names are intended to allow libraries and architecture-neutral
221
+// sketches to automatically default to the correct port name for a particular type
222
+// of use.  For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN,
223
+// the first hardware serial port whose RX/TX pins are not dedicated to another use.
224
+//
225
+// SERIAL_PORT_MONITOR        Port which normally prints to the Arduino Serial Monitor
226
+//
227
+// SERIAL_PORT_USBVIRTUAL     Port which is USB virtual serial
228
+//
229
+// SERIAL_PORT_LINUXBRIDGE    Port which connects to a Linux system via Bridge library
230
+//
231
+// SERIAL_PORT_HARDWARE       Hardware serial port, physical RX & TX pins.
232
+//
233
+// SERIAL_PORT_HARDWARE_OPEN  Hardware serial ports which are open for use.  Their RX & TX
234
+//                            pins are NOT connected to anything by default.
235
+#define SERIAL_PORT_MONITOR   Serial
236
+#define SERIAL_PORT_HARDWARE  Serial
237
+
238
+#endif

Loading…
Отказ
Запис