Software SPI allows non-standard SPI pins to be used for interfacing with SPI devices - izmijenjen polariti na SW CLK

Dependents:   Nokia_FRDM Nokia_FRDM_v2

Fork of SWSPI by Dave Van Wagner

Revision:
1:3a9981048283
Parent:
0:6a500a08c7fd
--- a/SWSPI.cpp	Tue Feb 04 06:54:01 2014 +0000
+++ b/SWSPI.cpp	Fri May 20 23:24:09 2016 +0000
@@ -66,7 +66,8 @@
                 read |= (1 << bit);
         }
 
-        sclk->write(!polarity);
+        //sclk->write(!polarity);
+        sclk->write(polarity);
 
         wait(1.0/freq/2);
 
@@ -76,7 +77,8 @@
                 read |= (1 << bit);
         }
 
-        sclk->write(polarity);
+        //sclk->write(polarity);
+        sclk->write(!polarity);
 
         wait(1.0/freq/2);
     }