Arduino Uno Quick Start Manual page 246

Hide thumbs Also See for Arduino Uno:
Table of Contents

Advertisement

Blaminatrs are perfect office toys that you can use in many situations. For
software developers, it can be a good idea to attach one to your continuous
integration (CI) system. Continuous integration systems, such as Jenkins,
help you continuously check whether your software is in good shape.
Whenever a developer checks in changes, the CI automatically compiles the
software and runs all tests. Then it publishes the results via email or as an
RSS feed. You can easily write a small piece of software that subscribes to
such a feed. Whenever someone breaks the build, you ll find a notification in
the feed, and you can use the Blaminatr to point to the name of the developer
who has committed the latest changes.
In the previous section, you learned all about the servo motor you need to
build the Blaminatr. Now we need only some creativity to build the device s
display, and we need more elaborate software. We start with a class named
Team
that represents the members of our team; that is, the potential "blamees":
Motors/Blaminatr/Blaminatr.ino
const unsigned int
Line 1
-
class
Team {
-
const
char** _members;
-
unsigned int
_num_members;
5
unsigned int
_positions[MAX_MEMBERS];
-
public:
-
Team(const
char** members) {
-
_members = members;
-
_num_members = 0;
10
const
char** member = _members;
-
while
(*member++)
-
_num_members++;
-
-
const unsigned int
15
unsigned int
-
for (unsigned int
-
_positions[i] = pos;
-
pos += share;
-
}
20
}
-
-
int get_position(const
-
int
position = 0;
-
for (unsigned int
25
if
(!strcmp(_members[i], name)) {
-
3.
http://jenkins-ci.org//
4.
At
http://urbanhonking.com/ideasfordozens/2010/05/19/the_github_stoplight/
project. It uses a traffic light to indicate your project s current status.
MAX_MEMBERS = 10;
share = 180 / _num_members;
pos = share / 2;
i = 0; i < _num_members; i++) {
char* name)
const
i = 0; i < _num_members; i++) {
www.it-ebooks.info
Building a Blaminatr
4
{
, you can see an alternative
231
3
report erratum
discuss

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the Arduino Uno and is the answer not in the manual?

Subscribe to Our Youtube Channel

Table of Contents