rad 0.2.9 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +5 -0
- data/Manifest.txt +4 -0
- data/bin/rad +215 -152
- data/lib/examples/software_serial.rb +10 -0
- data/lib/rad/generators/makefile/makefile.erb +1 -1
- data/lib/rad/progressbar.rb +236 -0
- data/lib/rad/version.rb +2 -2
- data/test/hello_world_test/Makefile +436 -0
- data/test/hello_world_test/hello_world.cpp +23 -0
- data/website/index.html +14 -57
- metadata +16 -2
data/website/index.html
CHANGED
@@ -9,7 +9,7 @@
|
|
9
9
|
</title>
|
10
10
|
<script src="javascripts/rounded_corners_lite.inc.js" type="text/javascript"></script>
|
11
11
|
<style>
|
12
|
-
|
12
|
+
|
13
13
|
</style>
|
14
14
|
<script type="text/javascript">
|
15
15
|
window.onload = function() {
|
@@ -29,26 +29,13 @@
|
|
29
29
|
</head>
|
30
30
|
<body>
|
31
31
|
<div id="main">
|
32
|
-
|
33
|
-
<div id="version" class="clickable" onclick='document.location = "http://rubyforge.org/projects/rad"; return false'>
|
34
|
-
<p>Get Version</p>
|
35
|
-
<a href="http://rubyforge.org/projects/rad" class="numbers">0.2.2</a>
|
36
|
-
</div>
|
37
|
-
<div id="buy-arduino">
|
38
|
-
<h3>Sponsored by:</h3>
|
39
|
-
<h4>The Shoppe at Wulfden</h4>
|
40
|
-
<a href="http://www.wulfden.org/freeduino/freeduino.shtml">
|
41
|
-
<img src="http://www.wulfden.org/freeduino/freeduino-1.jpg" /><br />
|
42
|
-
</a>
|
43
|
-
<h4><a href="http://www.wulfden.org/freeduino/freeduino.shtml">Totally Open Arduino-Compatible Hardware</a></h4>
|
44
|
-
|
45
|
-
|
46
|
-
</div>
|
47
|
-
</div>
|
32
|
+
|
48
33
|
<h1>RAD</h1>
|
34
|
+
<div id="version" class="clickable" onclick='document.location = "http://rubyforge.org/projects/rad"; return false'>
|
35
|
+
<p>Get Version</p>
|
36
|
+
<a href="http://rubyforge.org/projects/rad" class="numbers">0.3.0</a>
|
37
|
+
</div>
|
49
38
|
<h1>→ ‘Ruby Arduino Development’</h1>
|
50
|
-
|
51
|
-
|
52
39
|
|
53
40
|
|
54
41
|
<h2>What?</h2>
|
@@ -56,15 +43,7 @@
|
|
56
43
|
|
57
44
|
<p><span class="caps">RAD</span> is a framework for programming the Arduino physcial computing platform using Ruby. <span class="caps">RAD</span> converts Ruby scripts written using a set of Rails-like conventions and helpers into C source code which can be compiled and run on the Arduino microcontroller. It also provides a set of Rake tasks for automating the compilation and upload process.</p>
|
58
45
|
|
59
|
-
<br style="clear:both" />
|
60
46
|
|
61
|
-
<h2>Demo: 'Hello World'</h2>
|
62
|
-
|
63
|
-
<p>Here's a basic demo of <span class="caps">RAD</span> in action. In this movie, we'll write, compile, and upload the universal physical computing 'Hello World': a single flashing LED.
|
64
|
-
<div class="movie"><object width="425" height="355"><param name="movie" value="http://www.youtube.com/v/AKbHcMaC_cA&hl=en"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/AKbHcMaC_cA&hl=en" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"></embed></object></div>
|
65
|
-
<em>Note: This movie was made using an old version of the Arduino board which required a hardware reset before being able to accept a new sketch. More recent versions of the board don't have this requirement and hence as of version 0.2.0, <span class="caps">RAD</span> no longer prompts for reset when running 'rake make:upload' (thought the option is still available for older boards.)</em>
|
66
|
-
</p>
|
67
|
-
<br style="clear:both" />
|
68
47
|
<h2>Why?</h2>
|
69
48
|
|
70
49
|
|
@@ -77,7 +56,7 @@
|
|
77
56
|
<p><code>$ sudo gem install rad</code></p>
|
78
57
|
|
79
58
|
|
80
|
-
<p>You’ll also need to have the Arduino environment installed, which you can get from <a href="http://www.arduino.cc/en/Main/Software">the Arduino website</a>. <span class="caps">RAD</span> currently requires Arduino
|
59
|
+
<p>You’ll also need to have the Arduino environment installed, which you can get from <a href="http://www.arduino.cc/en/Main/Software">the Arduino website</a>. <span class="caps">RAD</span> currently requires Arduino 0010, but we try to keep it up-to-date with new Arduino releases.</p>
|
81
60
|
|
82
61
|
|
83
62
|
<h2>The Basics</h2>
|
@@ -116,22 +95,12 @@ end
|
|
116
95
|
</ul>
|
117
96
|
|
118
97
|
|
119
|
-
<h2>
|
98
|
+
<h2>The Arduino <span class="caps">API</span></h2>
|
120
99
|
|
121
100
|
|
122
|
-
<p>
|
101
|
+
<p>With the exception of the still-experimental Serial interface, most of <a href="http://www.arduino.cc/en/Reference/HomePage">the Arduino software <span class="caps">API</span></a> should be working correctly at this point. Documentation for the Ruby versions of the methods is forthcoming, but it is mostly what you’d expect: methods with identical names and arguments to their Arduino counterparts with the exception of using ‘true’ and ‘false’ for <span class="caps">HIGH</span> and <span class="caps">LOW</span>.</p>
|
123
102
|
|
124
|
-
<h2>Demo: Serial Communication</h2>
|
125
|
-
<p>
|
126
|
-
To demonstrate some of the more advanced features of <span class="caps">RAD</span>, here's a movie showing how to program the Arduino to listen to serial communication from a computer.
|
127
|
-
<div class="movie">
|
128
|
-
<object width="425" height="355"><param name="movie" value="http://www.youtube.com/v/7OguEBfdTe0&hl=en"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/7OguEBfdTe0&hl=en" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"></embed></object> </div>
|
129
103
|
|
130
|
-
<em>Note: The same comment from above applies here about the hardware reset. Also, extra points are available if you recognize the logo on the flag in the video.</em>
|
131
|
-
</p>
|
132
|
-
<br style="clear:both" />
|
133
|
-
|
134
|
-
<p>For more examples of <span class="caps">RAD</span> in action, see <a href="http://rad.rubyforge.org/examples">the RAD example directory</a>.</p>
|
135
104
|
<h2><span class="caps">RAD</span> Needs You!</h2>
|
136
105
|
|
137
106
|
|
@@ -141,38 +110,26 @@ end
|
|
141
110
|
<p>There’s lots to do.</p>
|
142
111
|
|
143
112
|
|
144
|
-
<p>If you’re looking for a place to dive in and don’t know quite where, <a href="mailto:
|
113
|
+
<p>If you’re looking for a place to dive in and don’t know quite where, <a href="mailto:greg@grabb.it">email Greg</a>. If you want to start by taking a log at the code, the trunk repository is <code>svn://rubyforge.org/var/svn/rad/trunk</code> for anonymous access.</p>
|
145
114
|
|
146
115
|
|
147
116
|
<h2>License</h2>
|
148
117
|
|
149
118
|
|
150
|
-
<p>This code is free to use under the terms of the <span class="caps">GPL</span
|
119
|
+
<p>This code is free to use under the terms of the <span class="caps">GPL 2</span>.0 license, just like the Arduino software library itself.</p>
|
151
120
|
|
152
121
|
|
153
122
|
<h2>Contact</h2>
|
154
123
|
|
155
124
|
|
156
|
-
<p>Comments, questions, heckles, attacks, praises, and, (most especially) patches and contributions are welcome! Send email to <a href="mailto:
|
157
|
-
|
158
|
-
<h2>Who</h2>
|
159
|
-
<p><a href="http://urbanhonking.com/ideasfordozens">Greg Borenstein</a> is RAD's original author and main maintainer with significant contributions from <a href="http://blog.bleything.net/">Ben Bleything</a> and <a href="http://www.wulfden.org/TheShoppe.shtml">Brian Riley</a>, patches from Scott Windsor and David Michael, and the support of the <a href="http://groups.google.com/group/ruby-arduino-development">the Ruby Arduino Development Google Group</a>.</p>
|
160
|
-
|
125
|
+
<p>Comments, questions, heckles, attacks, praises, and, (most especially) patches and contributions are welcome! Send email to <a href="mailto:greg@grabb.it">Greg Borenstein</a>.</p>
|
161
126
|
<p class="coda">
|
162
|
-
<a href="mailto:drnicwilliams@gmail.com">Dr Nic</a>,
|
127
|
+
<a href="mailto:drnicwilliams@gmail.com">Dr Nic</a>, 21st September 2008<br>
|
163
128
|
Theme extended from <a href="http://rb2js.rubyforge.org/">Paul Battley</a>
|
164
129
|
</p>
|
165
130
|
</div>
|
166
131
|
|
167
132
|
<!-- insert site tracking codes here, like Google Urchin -->
|
168
|
-
|
169
|
-
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
|
170
|
-
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
|
171
|
-
</script>
|
172
|
-
<script type="text/javascript">
|
173
|
-
var pageTracker = _gat._getTracker("UA-3885443-1");
|
174
|
-
pageTracker._initData();
|
175
|
-
pageTracker._trackPageview();
|
176
|
-
</script>
|
133
|
+
|
177
134
|
</body>
|
178
135
|
</html>
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rad
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Greg Borenstein
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2008-09-
|
12
|
+
date: 2008-09-24 00:00:00 -07:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -22,6 +22,16 @@ dependencies:
|
|
22
22
|
- !ruby/object:Gem::Version
|
23
23
|
version: 1.0.0
|
24
24
|
version:
|
25
|
+
- !ruby/object:Gem::Dependency
|
26
|
+
name: hoe
|
27
|
+
type: :development
|
28
|
+
version_requirement:
|
29
|
+
version_requirements: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 1.7.0
|
34
|
+
version:
|
25
35
|
description: A framework for programming the Arduino physcial computing platform using Ruby. RAD converts Ruby scripts written using a set of Rails-like conventions and helpers into C source code which can be compiled and run on the Arduino microcontroller.
|
26
36
|
email: greg@mfdz.com
|
27
37
|
executables:
|
@@ -83,6 +93,7 @@ files:
|
|
83
93
|
- lib/examples/servo_buttons.rb
|
84
94
|
- lib/examples/servo_calibrate_continuous.rb
|
85
95
|
- lib/examples/servo_throttle.rb
|
96
|
+
- lib/examples/software_serial.rb
|
86
97
|
- lib/examples/sparkfun_lcd.rb
|
87
98
|
- lib/examples/spectra_soft_pot.rb
|
88
99
|
- lib/examples/times_method.rb
|
@@ -150,6 +161,7 @@ files:
|
|
150
161
|
- lib/rad/generators/makefile/makefile.rb
|
151
162
|
- lib/rad/hardware_library.rb
|
152
163
|
- lib/rad/init.rb
|
164
|
+
- lib/rad/progressbar.rb
|
153
165
|
- lib/rad/rad_processor.rb
|
154
166
|
- lib/rad/rad_rewriter.rb
|
155
167
|
- lib/rad/rad_type_checker.rb
|
@@ -169,6 +181,8 @@ files:
|
|
169
181
|
- spec/models/spec_helper.rb
|
170
182
|
- spec/sim/hello_world_spec.rb
|
171
183
|
- spec/spec.opts
|
184
|
+
- test/hello_world_test/Makefile
|
185
|
+
- test/hello_world_test/hello_world.cpp
|
172
186
|
- test/test_array_processing.rb
|
173
187
|
- test/test_plugin_loading.rb
|
174
188
|
- test/test_translation_post_processing.rb
|