Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
Schwimmwinkelsensor MA
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Ricco Müller
Schwimmwinkelsensor MA
Commits
6941cad0
Commit
6941cad0
authored
11 months ago
by
Ricco Müller
Browse files
Options
Downloads
Patches
Plain Diff
Upload New File
parent
d43a9b2f
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Arduino Code/RGB_Blink/RGB_Blink.ino
+65
-0
65 additions, 0 deletions
Arduino Code/RGB_Blink/RGB_Blink.ino
with
65 additions
and
0 deletions
Arduino Code/RGB_Blink/RGB_Blink.ino
0 → 100644
+
65
−
0
View file @
6941cad0
/*
Blink
Turns an LED on for one second, then off for one second, repeatedly.
Most Arduinos have an on-board LED you can control. On the UNO, MEGA and ZERO
it is attached to digital pin 13, on MKR1000 on pin 6. LED_BUILTIN is set to
the correct LED pin independent of which board is used.
If you want to know what pin the on-board LED is connected to on your Arduino
model, check the Technical Specs of your board at:
https://www.arduino.cc/en/Main/Products
modified 8 May 2014
by Scott Fitzgerald
modified 2 Sep 2016
by Arturo Guadalupi
modified 8 Sep 2016
by Colby Newman
This example code is in the public domain.
https://www.arduino.cc/en/Tutorial/BuiltInExamples/Blink
*/
#include
"LED_status.h"
// the setup function runs once when you press reset or power the board
void
setup
()
{
// initialize digital pin LED_BUILTIN as an output.
pinMode
(
LED_RED_PIN
,
OUTPUT
);
pinMode
(
LED_GREEN_PIN
,
OUTPUT
);
pinMode
(
LED_BLUE_PIN
,
OUTPUT
);
digitalWrite
(
LED_RED_PIN
,
LOW
);
digitalWrite
(
LED_GREEN_PIN
,
HIGH
);
digitalWrite
(
LED_BLUE_PIN
,
HIGH
);
delay
(
2000
);
digitalWrite
(
LED_RED_PIN
,
HIGH
);
digitalWrite
(
LED_GREEN_PIN
,
LOW
);
digitalWrite
(
LED_BLUE_PIN
,
HIGH
);
delay
(
2000
);
digitalWrite
(
LED_RED_PIN
,
HIGH
);
digitalWrite
(
LED_GREEN_PIN
,
HIGH
);
digitalWrite
(
LED_BLUE_PIN
,
LOW
);
delay
(
2000
);
init_LED
();
}
// the loop function runs over and over again forever
void
loop
()
{
delay
(
1000
);
setLEDColor
(
20
,
0
,
0
);
delay
(
1000
);
setLEDColor
(
255
,
50
,
0
);
delay
(
1000
);
setLEDColor
(
0
,
20
,
0
);
delay
(
1000
);
setLEDColor
(
0
,
255
,
20
);
delay
(
1000
);
setLEDColor
(
0
,
0
,
120
);
delay
(
1000
);
setLEDColor
(
255
,
0
,
120
);
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment