mirror of
https://github.com/DCC-EX/CommandStation-EX.git
synced 2024-11-23 16:16:13 +01:00
Uno Wifi compiling
This commit is contained in:
parent
eececa322a
commit
d96c919fee
|
@ -11,7 +11,7 @@
|
||||||
#include "ATMEGA2560/Timer.h"
|
#include "ATMEGA2560/Timer.h"
|
||||||
#elif defined(ARDUINO_AVR_UNO)
|
#elif defined(ARDUINO_AVR_UNO)
|
||||||
#include "ATMEGA328/Timer.h"
|
#include "ATMEGA328/Timer.h"
|
||||||
#elif defined(ARDUINO_ARCH_MEGAAVR)
|
#elif defined(ARDUINO_AVR_UNO_WIFI_DEV_ED)
|
||||||
#include "ATMEGA4809/Timer.h"
|
#include "ATMEGA4809/Timer.h"
|
||||||
#else
|
#else
|
||||||
#error "Cannot compile - ArduinoTimers library does not support your board, or you are missing compatible build flags."
|
#error "Cannot compile - ArduinoTimers library does not support your board, or you are missing compatible build flags."
|
||||||
|
|
2
DCC.h
2
DCC.h
|
@ -155,7 +155,7 @@ private:
|
||||||
#define ARDUINO_TYPE "NANO"
|
#define ARDUINO_TYPE "NANO"
|
||||||
#elif defined(ARDUINO_AVR_MEGA2560)
|
#elif defined(ARDUINO_AVR_MEGA2560)
|
||||||
#define ARDUINO_TYPE "MEGA"
|
#define ARDUINO_TYPE "MEGA"
|
||||||
#elif defined(ARDUINO_ARCH_MEGAAVR)
|
#elif defined(ARDUINO_AVR_UNO_WIFI_DEV_ED)
|
||||||
#define ARDUINO_TYPE "UNOWIFIR2"
|
#define ARDUINO_TYPE "UNOWIFIR2"
|
||||||
#else
|
#else
|
||||||
#error CANNOT COMPILE - DCC++ EX ONLY WORKS WITH AN ARDUINO UNO, NANO 328, OR ARDUINO MEGA 1280/2560
|
#error CANNOT COMPILE - DCC++ EX ONLY WORKS WITH AN ARDUINO UNO, NANO 328, OR ARDUINO MEGA 1280/2560
|
||||||
|
|
|
@ -41,9 +41,11 @@ void DCCWaveform::begin(MotorDriver * mainDriver, MotorDriver * progDriver, byte
|
||||||
progTrack.setPowerMode(POWERMODE::OFF);
|
progTrack.setPowerMode(POWERMODE::OFF);
|
||||||
switch (timerNumber) {
|
switch (timerNumber) {
|
||||||
case 1: interruptTimer= &TimerA; break;
|
case 1: interruptTimer= &TimerA; break;
|
||||||
|
#ifndef ARDUINO_AVR_UNO_WIFI_DEV_ED
|
||||||
case 2: interruptTimer= &TimerB; break;
|
case 2: interruptTimer= &TimerB; break;
|
||||||
#ifndef ARDUINO_AVR_UNO
|
#ifndef ARDUINO_AVR_UNO
|
||||||
case 3: interruptTimer= &TimerC; break;
|
case 3: interruptTimer= &TimerC; break;
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
default:
|
default:
|
||||||
DIAG(F("\n\n *** Invalid Timer number %d requested. Only 1..3 valid. DCC will not work.*** \n\n"), timerNumber);
|
DIAG(F("\n\n *** Invalid Timer number %d requested. Only 1..3 valid. DCC will not work.*** \n\n"), timerNumber);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user