Forked PololuLedStrip and modified it to work with the KL25Z. Renamed it to Adafruit_NeoPixel.

Dependents:   idd_hw3 idd_fa15_hw3_lauren_bill_tomas idd_fa15_hw3_lauren_bill_tomas Raiden ... more

Fork of PololuLedStrip by David Grayson

Revision:
19:46d7ab0ba3e7
Parent:
12:b6df8ac053c8
Child:
20:656bbcb64e3b
--- a/led_strip_write_color.s	Fri Mar 01 05:17:02 2013 +0000
+++ b/led_strip_write_color.s	Wed Oct 09 01:13:49 2013 +0000
@@ -49,29 +49,36 @@
 send_led_strip_bit
     str r3, [r1]       ; Drive the line high.
     
-    delay #0
+    ; It doesn't really matter exactly how long we delay here as long as it is
+    ; less than 540 microseconds.
+    nop
+    nop
+    nop
+    nop
+    nop
+    nop
     
     ldr r4, =0x80000000
     tst r6, r4
-    bne delay1
+    bne delay0
     str r3, [r2]       ; If the bit to send it 0, drive the line low.
-delay1
+delay0
 
-    delay #1
+    delay #0
 
     ldr r4, =0x80000000
     tst r6, r4
-    beq delay2
+    beq delay1
     str r3, [r2]       ; If the bit to send is 1, drive the line low.
-delay2
+delay1
     
-    delay #2
+    delay #1
     
     lsls r6, r6, #1           ; Shift color bits.
     subs r7, r7, #1           ; Decrement the loop counter.
     bne send_led_strip_bit    ; Send another bit if we have not reached zero.   
     pop {r4, r5, r6, r7, pc}  ; Otherwise, restore the registers and return.
-    
+    bx lr;
 
 delay_region
     ; The following is 128 nops.