From 9cfd9ba5d6e2933e72dd93b048e62b9e9494fafb Mon Sep 17 00:00:00 2001 From: Marti Bolivar Date: Tue, 10 May 2011 16:41:37 -0400 Subject: Converting all files to UNIX newlines. Committing the results of running the following on the libmaple root directory: $ fromdos `grep --exclude-dir='[.]git' -Ilsr $'\r$' .` --- examples/blinky.cpp | 64 ++++++++++++++++++++++++++--------------------------- 1 file changed, 32 insertions(+), 32 deletions(-) (limited to 'examples/blinky.cpp') diff --git a/examples/blinky.cpp b/examples/blinky.cpp index 91d1a47..dd72514 100644 --- a/examples/blinky.cpp +++ b/examples/blinky.cpp @@ -1,32 +1,32 @@ -// Blinks the built-in LED - -#include "wirish.h" - -void setup() { - pinMode(BOARD_LED_PIN, OUTPUT); -} - -int toggle = 1; - -void loop() { - // You could just use toggleLED() instead, but this illustrates - // the use of digitalWrite(): - digitalWrite(BOARD_LED_PIN, toggle); - toggle ^= 1; - delay(100); -} - -// Force init to be called *first*, i.e. before static object allocation. -// Otherwise, statically allocated objects that need libmaple may fail. -__attribute__((constructor)) void premain() { - init(); -} - -int main(void) { - setup(); - - while (true) { - loop(); - } - return 0; -} +// Blinks the built-in LED + +#include "wirish.h" + +void setup() { + pinMode(BOARD_LED_PIN, OUTPUT); +} + +int toggle = 1; + +void loop() { + // You could just use toggleLED() instead, but this illustrates + // the use of digitalWrite(): + digitalWrite(BOARD_LED_PIN, toggle); + toggle ^= 1; + delay(100); +} + +// Force init to be called *first*, i.e. before static object allocation. +// Otherwise, statically allocated objects that need libmaple may fail. +__attribute__((constructor)) void premain() { + init(); +} + +int main(void) { + setup(); + + while (true) { + loop(); + } + return 0; +} -- cgit v1.2.3