From 2826bbb424f15d61c5ef917dcfd5444e7e607b56 Mon Sep 17 00:00:00 2001 From: iperry Date: Sun, 17 Jan 2010 02:57:17 +0000 Subject: Enabled 39 GPIOs for digitalWrite(), fixed timer/usart collisions on PWM/USART pins git-svn-id: https://leaflabs.googlecode.com/svn/trunk/library@120 749a229e-a60e-11de-b98f-4500b42dc123 --- src/main.cpp | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) (limited to 'src/main.cpp') diff --git a/src/main.cpp b/src/main.cpp index 78cdf13..78b0f89 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -4,34 +4,16 @@ #include "HardwareUsb.h" #include "usb.h" -HardwareUsb USB; - int ledPin = 13; void setup() { - pinMode(ledPin,OUTPUT); -// Serial2.begin(9600); - Serial3.begin(9600); - Serial3.println("hello"); + pinMode(ledPin, OUTPUT); } -volatile int toggle = 1; - -char c; +int toggle = 1; void loop() { digitalWrite(ledPin, toggle); toggle ^= 1; - delay(500); -// USB.print(millis()); -// Serial3.println("hello"); -// USB.println("\r"); -// Serial2.print(millis(), DEC); -// Serial2.print(": "); -// Serial2.print(USB.available(), DEC); -// Serial2.println(); - if (Serial3.available()){ - c = Serial3.read(); - Serial3.print(c); - } + delay(100); } int main(void) { -- cgit v1.2.3