1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-10-12 12:44:53 +03:00

Merged 1.0.3

This commit is contained in:
Cristian Maglie
2012-12-10 15:55:05 +01:00
49 changed files with 24128 additions and 16320 deletions

View File

@@ -10,9 +10,10 @@
three 10 kilohm resistors
3 220 ohm resistors
3 photoresistors
red green aand blue colored gels
red green and blue colored gels
Created 13 September 2012
Modified 14 November 2012
by Scott Fitzgerald
Thanks to Federico Vanzati for improvements
@@ -42,32 +43,32 @@ void setup() {
Serial.begin(9600);
// set the digital pins as outputs
pinMode(greenLedPin,OUTPUT);
pinMode(redLedPin,OUTPUT);
pinMode(blueLedPin,OUTPUT);
pinMode(greenLEDPin,OUTPUT);
pinMode(redLEDPin,OUTPUT);
pinMode(blueLEDPin,OUTPUT);
}
void loop() {
// Read the sensors first:
// read the value from the red-filtered photoresistor:
redsensorValue = analogRead(redsensorPin);
redSensorValue = analogRead(redSensorPin);
// give the ADC a moment to settle
delay(5);
// read the value from the green-filtered photoresistor:
greensensorValue = analogRead(greensensorPin);
greenSensorValue = analogRead(greenSensorPin);
// give the ADC a moment to settle
delay(5);
// read the value from the blue-filtered photoresistor:
bluesensorValue = analogRead(bluesensorPin);
blueSensorValue = analogRead(blueSensorPin);
// print out the values to the serial monitor
Serial.print("raw sensor Values \t red: ");
Serial.print(redsensorValue);
Serial.print(redSensorValue);
Serial.print("\t green: ");
Serial.print(greensensorValue);
Serial.print(greenSensorValue);
Serial.print("\t Blue: ");
Serial.println(bluesensorValue);
Serial.println(blueSensorValue);
/*
In order to use the values from the sensor for the LED,
@@ -75,9 +76,9 @@ void loop() {
but analogWrite() uses 8 bits. You'll want to divide your
sensor readings by 4 to keep them in range of the output.
*/
redValue = redsensorValue/4;
greenValue = greensensorValue/4;
blueValue = bluesensorValue/4;
redValue = redSensorValue/4;
greenValue = greenSensorValue/4;
blueValue = blueSensorValue/4;
// print out the mapped values
Serial.print("Mapped sensor Values \t red: ");
@@ -90,8 +91,8 @@ void loop() {
/*
Now that you have a usable value, it's time to PWM the LED.
*/
analogWrite(redLedPin, redValue);
analogWrite(greenLedPin, greenValue);
analogWrite(blueLedPin, blueValue);
analogWrite(redLEDPin, redValue);
analogWrite(greenLEDPin, greenValue);
analogWrite(blueLEDPin, blueValue);
}

View File

@@ -48,6 +48,7 @@ null KEYWORD1
private KEYWORD1
protected KEYWORD1
public KEYWORD1
register KEYWORD1
return KEYWORD1 Return
short KEYWORD1
signed KEYWORD1

View File

@@ -53,6 +53,33 @@ ARDUINO BETA 1.5 - 2012.10.22
* For more info refer to this press release:
http://arduino.cc/blog/2012/10/22/arduino-1-5-support-for-the-due-and-other-processors-easier-library-installation-simplified-board-menu-etc/
ARDUINO 1.0.3 - 2012.12.10
[hardware]
* Added support for the Arduino Esplora
[environment]
* Signed application for MacOSX 10.8
[core]
* Fixed power-up-starts-bootloader in Leonardo (and derivative)
bootloaders. (Kristian Lauszus)
(https://github.com/arduino/Arduino/pull/118)
* Fixed digital_pin_to_timer_PGM array in Leonardo variant.
* Published updated Wifi firmware
* Updated source code for atmega8 bootloader
[libraries]
* Added 600 baud support in SoftwareSerial (Sébastien Jean)
(http://github.com/arduino/Arduino/issues/1146)
ARDUINO 1.0.2 - 2012.11.05
[hardware]

View File

@@ -0,0 +1,107 @@
;************************************************************
; Windows USB CDC ACM Setup File
; Copyright (c) 2000 Microsoft Corporation
[Version]
Signature="$Windows NT$"
Class=Ports
ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318}
Provider=%MFGNAME%
LayoutFile=layout.inf
CatalogFile=%MFGFILENAME%.cat
DriverVer=11/15/2007,5.1.2600.0
[Manufacturer]
%MFGNAME%=DeviceList, NTamd64
[DestinationDirs]
DefaultDestDir=12
;------------------------------------------------------------------------------
; Windows 2000/XP/Vista-32bit Sections
;------------------------------------------------------------------------------
[DriverInstall.nt]
include=mdmcpq.inf
CopyFiles=DriverCopyFiles.nt
AddReg=DriverInstall.nt.AddReg
[DriverCopyFiles.nt]
usbser.sys,,,0x20
[DriverInstall.nt.AddReg]
HKR,,DevLoader,,*ntkern
HKR,,NTMPDriver,,%DRIVERFILENAME%.sys
HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider"
[DriverInstall.nt.Services]
AddService=usbser, 0x00000002, DriverService.nt
[DriverService.nt]
DisplayName=%SERVICE%
ServiceType=1
StartType=3
ErrorControl=1
ServiceBinary=%12%\%DRIVERFILENAME%.sys
;------------------------------------------------------------------------------
; Vista-64bit Sections
;------------------------------------------------------------------------------
[DriverInstall.NTamd64]
include=mdmcpq.inf
CopyFiles=DriverCopyFiles.NTamd64
AddReg=DriverInstall.NTamd64.AddReg
[DriverCopyFiles.NTamd64]
%DRIVERFILENAME%.sys,,,0x20
[DriverInstall.NTamd64.AddReg]
HKR,,DevLoader,,*ntkern
HKR,,NTMPDriver,,%DRIVERFILENAME%.sys
HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider"
[DriverInstall.NTamd64.Services]
AddService=usbser, 0x00000002, DriverService.NTamd64
[DriverService.NTamd64]
DisplayName=%SERVICE%
ServiceType=1
StartType=3
ErrorControl=1
ServiceBinary=%12%\%DRIVERFILENAME%.sys
;------------------------------------------------------------------------------
; Vendor and Product ID Definitions
;------------------------------------------------------------------------------
; When developing your USB device, the VID and PID used in the PC side
; application program and the firmware on the microcontroller must match.
; Modify the below line to use your VID and PID. Use the format as shown below.
; Note: One INF file can be used for multiple devices with different VID and PIDs.
; For each supported device, append ",USB\VID_xxxx&PID_yyyy" to the end of the line.
;------------------------------------------------------------------------------
[SourceDisksFiles]
[SourceDisksNames]
[DeviceList]
%DESCRIPTION%=DriverInstall, USB\VID_2341&PID_003C
%DESCRIPTION%=DriverInstall, USB\VID_2341&PID_803C&MI_00
[DeviceList.NTamd64]
%DESCRIPTION%=DriverInstall, USB\VID_2341&PID_003C
%DESCRIPTION%=DriverInstall, USB\VID_2341&PID_803C&MI_00
;------------------------------------------------------------------------------
; String Definitions
;------------------------------------------------------------------------------
;Modify these strings to customize your device
;------------------------------------------------------------------------------
[Strings]
MFGFILENAME="CDC_vista"
DRIVERFILENAME ="usbser"
MFGNAME="Arduino LLC (www.arduino.cc)"
INSTDISK="Arduino Esplora Driver Installer"
DESCRIPTION="Arduino Esplora"
SERVICE="USB RS-232 Emulation Driver"