From 46ea58a45770ee7945bbf22800e443a05ef0d41f Mon Sep 17 00:00:00 2001 From: livello Date: Thu, 15 Mar 2018 07:03:44 +0300 Subject: [PATCH] remove spi.begin --- lighthub/sd_card_w5100.cpp | 3 +-- platformio.ini | 6 ++++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/lighthub/sd_card_w5100.cpp b/lighthub/sd_card_w5100.cpp index f75b0be..714d1bb 100644 --- a/lighthub/sd_card_w5100.cpp +++ b/lighthub/sd_card_w5100.cpp @@ -148,8 +148,7 @@ void sd_card_w5100_setup() { // Note that even if it's not used as the CS pin, the hardware SS pin // (10 on most Arduino boards, 53 on the Mega) must be left as an output // or the SD library functions will not work. - pinMode(chipSelect, OUTPUT); // change this to 53 on a mega - SPI.begin(chipSelect); //but it didn'temp_DHT22 workt wiht it and whitout it [/b] // change this to 53 on a mega + pinMode(chipSelect, OUTPUT); if (!card.init(SPI_FULL_SPEED, chipSelect)) { Serial.println("initialization failed. Things to check:"); diff --git a/platformio.ini b/platformio.ini index beb3fc8..9e74558 100644 --- a/platformio.ini +++ b/platformio.ini @@ -10,8 +10,8 @@ [platformio] src_dir = lighthub env_default = -; megaatmega2560 - due + megaatmega2560 +; due [env:due] platform = atmelsam @@ -59,6 +59,8 @@ lib_deps = https://github.com/knolleary/pubsubclient.git https://github.com/anklimov/Artnet.git FastLED + 161 + 322 [env:due-5500] platform = atmelsam