Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: idd_hw3 idd_fa15_hw3_lauren_bill_tomas idd_fa15_hw3_lauren_bill_tomas Raiden ... more
Fork of PololuLedStrip by
LedStripGradient.cpp
00001 //#include "mbed.h" 00002 //#include "PololuLedStrip.h" 00003 // 00004 //PololuLedStrip ledStrip(PTC8); 00005 // 00006 //#define LED_COUNT 60 00007 //rgb_color colors[LED_COUNT]; 00008 // 00009 //Timer timer; 00010 // 00011 //int main() 00012 //{ 00013 // timer.start(); 00014 // 00015 // while(1) 00016 // { 00017 // // Update the colors array. 00018 // uint8_t time = timer.read_ms() >> 2; 00019 // for(uint32_t i = 0; i < LED_COUNT; i++) 00020 // { 00021 // uint8_t x = time - 8*i; 00022 // colors[i] = (rgb_color){ x, 255 - x, x }; 00023 // } 00024 // 00025 // // Send the colors to the LED strip. 00026 // ledStrip.write(colors, LED_COUNT); 00027 // wait_ms(10); 00028 // } 00029 //}
Generated on Wed Jul 13 2022 01:18:34 by
1.7.2
