<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/atom10full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:blogger="http://schemas.google.com/blogger/2008" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" gd:etag="W/&quot;CE8EQnk8fCp7ImA9WhBaFU0.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869</id><updated>2013-05-25T13:26:43.774-04:00</updated><category term="Duino644" /><category term="bluetooth" /><category term="SD card" /><category term="dual LED matrix" /><category term="software" /><category term="tips and tricks" /><category term="Wise Clock 2" /><category term="Wide Clock" /><category term="serial communication" /><category term="DWex" /><category term="buy" /><category term="XBee" /><category term="Wise Clock 3" /><category term="hacking" /><category term="BookClock" /><category term="Wise Clock" /><category term="Wise4Sure" /><category term="led matrix" /><category term="ClockTHREE" /><category term="general" /><category term="Wiseduino" /><category term="WiFi" /><category term="I2C" /><category term="Wise Clock 4" /><title>Wise time with Arduino</title><subtitle type="html">Learn. Think. Make.</subtitle><link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/posts/default" /><link rel="alternate" type="text/html" href="http://timewitharduino.blogspot.com/" /><link rel="next" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default?start-index=26&amp;max-results=25&amp;redirect=false&amp;v=2" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><generator version="7.00" uri="http://www.blogger.com">Blogger</generator><openSearch:totalResults>182</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/atom+xml" href="http://feeds.feedburner.com/blogspot/MsTK" /><feedburner:info uri="blogspot/mstk" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><entry gd:etag="W/&quot;A0YMQH47fip7ImA9WhBbFks.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-1178654209892188089</id><published>2013-05-15T20:13:00.003-04:00</published><updated>2013-05-15T21:53:01.006-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-05-15T21:53:01.006-04:00</app:edited><title>Play WAV files from SD card with Wise Clock 3/4 board</title><content type="html">The video below shows&amp;nbsp;&lt;a href="http://timewitharduino.blogspot.ca/2013/05/hacking-wise-clock-34.html"&gt;another hack&lt;/a&gt; for &lt;b&gt;Wise Clock 3/4&lt;/b&gt;, playing a WAV file directly (not using extra hardware) from SD card, with the help of the&amp;nbsp;&lt;a href="https://github.com/TMRh20/TMRpcm"&gt;TMRpcm library&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;iframe allowfullscreen="" frameborder="0" height="300" mozallowfullscreen="" src="http://player.vimeo.com/video/66121709?title=0&amp;amp;byline=0&amp;amp;portrait=0" webkitallowfullscreen="" width="400"&gt;&lt;/iframe&gt;&lt;br /&gt;
&lt;br /&gt;
The TMRpcm software uses the standard SD library (coming with Arduino IDE 1.0 and later) to read WAV files from SD card. To output the audio while buffering the content of the SD file, TMRpcm uses ISR triggered by internal timer. The buzzer/speaker can be connected only to certain pins of the processor. For ATmega1284/ATmega644 (used in &lt;b&gt;Wise Clock 3/4&lt;/b&gt;), these pins are D3, D4, D12, D13, D14 and D15, as shown in the definition below (from sanguino core file &lt;i&gt;pins_arduino.c&lt;/i&gt;).&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://4.bp.blogspot.com/-vJl9ydYcTzI/UY7QhmGaU6I/AAAAAAAABEY/97XvVEGDzPw/s1600/pin2timer.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="368" src="http://4.bp.blogspot.com/-vJl9ydYcTzI/UY7QhmGaU6I/AAAAAAAABEY/97XvVEGDzPw/s400/pin2timer.JPG" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
From the perspective of TMRpcm library, the buzzer in &lt;b&gt;Wise Clock 4&lt;/b&gt; is connected to the "wrong" pins, D22 and D23, which are not eligible for this trick. I chose to connect another speaker to pin D13, but that's already taken by the display (CS, pin 1). So I had to cut the trace from D13 to the display, and connect pin 1 of the display to D18 (another choice was D19, the only other available I/O left).&lt;br /&gt;
&lt;br /&gt;
From now on it's only software.&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;modify this line in&amp;nbsp;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;HT1632.cpp:&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&amp;nbsp; &amp;nbsp; #define HT1632_CS&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;18&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;// &amp;nbsp;Chip Select (pin 1 of display&amp;nbsp;connector)&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;add line&lt;/li&gt;
&lt;/ul&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp;#define SPEAKER_PIN1 &amp;nbsp;13&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
Then follow from step 4 of &lt;a href="http://timewitharduino.blogspot.ca/2013/05/hacking-wise-clock-34.html"&gt;this previous post&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
Unfortunately, this will not work with &lt;b&gt;Wise Clock 4&lt;/b&gt; software as is, and the main reason is the timer interrupts used by TMRpcm library, which disrupt the "SPI-like" commands for the display.&lt;br /&gt;
&lt;br /&gt;
The video above may seem like another &lt;b&gt;Wise Clock "app"&lt;/b&gt;, but it is just a "cheating" sketch running standalone, shown below.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#include "Arduino.h&lt;/span&gt;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;"&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#include "Wire.h&lt;/span&gt;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;"&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#include "DS3231.h"&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#include "HT1632.h"&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#include "AlarmClock.h"&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#include "WiseClock.h"&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#include "SD.h&lt;/span&gt;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;"&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#include "TMRpcm.h&lt;/span&gt;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;"&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#define SD_ChipSelectPin &amp;nbsp; 4&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#define AudioPin &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;13 &amp;nbsp;// must be PWM pin&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;TMRpcm tmrpcm;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;//**********************&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;void setup()&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; Serial.begin(9600);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; // disable JTAG (to use pin D18);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; uint8_t tmp = 1&amp;lt;&lt;jtd font=""&gt;&lt;/jtd&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; MCUCR = tmp;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; MCUCR = tmp;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; ht1632_setup();&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; SD.begin(SD_ChipSelectPin);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; tmrpcm.speakerPin = AudioPin;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;//*********************&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;void loop()&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; alarmClock.isAlarmEnabled = true;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; alarmClock.getTimeFromRTC();&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; Serial.print("Time is: ");&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; Serial.print(alarmClock.hour, DEC);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; Serial.print(":");&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; Serial.print(alarmClock.minute, DEC);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; Serial.print(":");&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; Serial.println(alarmClock.second, DEC);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; if (!tmrpcm.isPlaying())&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_putTinyString(0, 0, "Playing", RED);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; wiseClock.displayTime(8, false);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; tmrpcm.play("dancing.wav");&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; delay(2000);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
The display is statically updated once, before the WAV file starts playing.&lt;br /&gt;
&lt;br /&gt;
It would probably be possible to update the display between playing short WAV files (with interrupts disabled right after each file is played). But that may open a door to other set of problems, since the display is practically frozen for the duration of the file playing. On the other hand, the I2C (through Wire library) works just fine (that's because I2C is hardware driven), so getting the current time from RTC while playing music is not an issue.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Conclusion&lt;/b&gt;&lt;br /&gt;
Although in theory would be possible to integrate TMRpcm library in the Wise Clock software (to play WAV files from SD card while the clock functionality is not affected), in practice that would take a lot of programming effort. A much easier and cheaper way to include audio into &lt;b&gt;Wise Clock 4&lt;/b&gt; (hardware and software) would be through the use of serially controlled audio-playback specialized modules, like &lt;a href="https://www.sparkfun.com/products/11125"&gt;this one&lt;/a&gt;&amp;nbsp;(or maybe even the radio/MP3 module I reviewed &lt;a href="http://timewitharduino.blogspot.ca/2011/02/fm-radio-mp3-player-module.html"&gt;here&lt;/a&gt;, if I ever find it in my pile of stuff).&lt;br /&gt;
&lt;br /&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/_HiE0H_hjlE" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/1178654209892188089/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2013/05/play-wav-files-from-sd-card-with-wise.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/1178654209892188089?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/1178654209892188089?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/_HiE0H_hjlE/play-wav-files-from-sd-card-with-wise.html" title="Play WAV files from SD card with Wise Clock 3/4 board" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://4.bp.blogspot.com/-vJl9ydYcTzI/UY7QhmGaU6I/AAAAAAAABEY/97XvVEGDzPw/s72-c/pin2timer.JPG" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2013/05/play-wav-files-from-sd-card-with-wise.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DUUER3g9eip7ImA9WhBbEUQ.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-6133919887184109665</id><published>2013-05-10T10:45:00.000-04:00</published><updated>2013-05-10T10:46:46.662-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-05-10T10:46:46.662-04:00</app:edited><title>Miscellaneous</title><content type="html">&lt;b&gt;1.&lt;/b&gt; Some time ago I did some (unpaid and&amp;nbsp;unaccredited) work for a kickstarter project that ultimately failed to raise the required funds. My task was to develop a prototype board that can read data from a sensor and post it over WiFi to a web site (&lt;a href="http://cosm.com/"&gt;cosm.com&lt;/a&gt;-like). The board I designed was based on &lt;a href="http://readiymate.com/"&gt;readiymate&lt;/a&gt;, piggybacking on its capability to update the software "over the air" (through WiFi), which at the time seemed to be the only board offering this feature. Although a readiymate-based system is not cheap nor sophisticated enough (design and feature-wise) to become a commercial success (like the &lt;a href="http://nest.com/"&gt;Nest thermostat&lt;/a&gt;, for instance), it relies on easy-to-find off-the-shelf components, it is open source and Arduino-compatible. So, it is easy to modify, adapt, hack and support.&lt;br /&gt;
&lt;br /&gt;
Here are some photos of my readiymate-derivative board, for the record, and also with the hope that someone may find it interesting enough to pick up the pieces and develop it further.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://4.bp.blogspot.com/-V3HtKTdYUXs/UYbR7HPb-YI/AAAAAAAABDA/p4InpdYqvCE/s1600/vioPCB.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://4.bp.blogspot.com/-V3HtKTdYUXs/UYbR7HPb-YI/AAAAAAAABDA/p4InpdYqvCE/s320/vioPCB.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://4.bp.blogspot.com/-qOih07FInho/UYbSQN8gpgI/AAAAAAAABDI/WaXpvFhh5YA/s1600/vioboard.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://4.bp.blogspot.com/-qOih07FInho/UYbSQN8gpgI/AAAAAAAABDI/WaXpvFhh5YA/s320/vioboard.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The board (which was not even given a name), has just 2 major components: the &lt;a href="http://www.atmel.ca/Images/doc2549.pdf"&gt;ATmega1280&lt;/a&gt; microcontroller (also found in the first generation Arduino Mega) and the &lt;a href="http://ww1.microchip.com/downloads/en/DeviceDoc/WiFly-RN-171-DS-ver3.1r.pdf"&gt;WiFly RN171&lt;/a&gt; module.&lt;br /&gt;
The sensor module gets plugged in the pair of 6-pin female headers (compatible with the JeeLab's &lt;a href="http://jeelabs.net/projects/cafe/wiki/"&gt;JeeNode&lt;/a&gt;, apparently). The button is normally used for switching to setup mode (allowing user-configuration of the board, so it can get the name of the WiFi network and the password), as described in &lt;a href="http://timewitharduino.blogspot.ca/2013/02/user-friendly-configuration-of-wi-fi.html"&gt;this post&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://2.bp.blogspot.com/-10jpH6Zgefo/UYbXBwANC1I/AAAAAAAABDY/J1FcDw9sk9Q/s1600/vioschematic.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="232" src="http://2.bp.blogspot.com/-10jpH6Zgefo/UYbXBwANC1I/AAAAAAAABDY/J1FcDw9sk9Q/s400/vioschematic.JPG" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
At some point we considered replacing the ATmega1280 with the cheaper, but as powerful, ATmega1284 (as used in &lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2011/12/buy-complete-wise-clock-4-kit-includes.html"&gt;Wise Clock 4&lt;/a&gt;&lt;/b&gt;), thus saving about $4 per board. Although the bootloader could be easily adapted, due to time constraints we preferred to go with the tested and proven solution (ATmega1280) instead.&lt;br /&gt;
&lt;br /&gt;
A project that comes close (it is actually way ahead of the one shown here) in terms of requirements (size, cost, power etc.) and functionality ("over the air" software updates etc.) is the &lt;a href="http://www.kickstarter.com/projects/sparkdevices/spark-core-wi-fi-for-everything-arduino-compatible?ref=live"&gt;SparkCore: Wi-Fi for Everything (Arduino compatible)&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;2.&lt;/b&gt; Posterous.com blog site (which hosted some quite interesting microcontroller projects authored by "rossum", as far as I remember) just closed its doors. Could this happen to blogger.com /blogspot.com? I honestly thought that the internet can only grow, and every piece of contribution is recorded forever. Well, I was obviously wrong, if the internet is ever to become a "living" thing, some parts of it must die off occasionally, like branches of a tree, I imagine.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;3.&lt;/b&gt; I recently discovered some interesting open source clocks that use the same 3216 display as &lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2011/12/buy-complete-wise-clock-4-kit-includes.html"&gt;Wise Clock 4&lt;/a&gt;&lt;/b&gt;:&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="http://xronosclock.com/"&gt;Xronos Alarm clock&lt;/a&gt;&amp;nbsp;- ATmega644, sound with adafruit &lt;a href="http://www.adafruit.com/products/94"&gt;Wave Shield&lt;/a&gt;;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://clock.bonsignore.com/"&gt;Open Clock project&lt;/a&gt;&amp;nbsp;- Arduino with ATmega328, touch screen, sound with Wave Shield;&lt;/li&gt;
&lt;/ul&gt;
&lt;div&gt;
Both clocks look like well-designed finished products, with elaborate enclosures and lots of features, including playing audio files from SD card (using the Wave Shield).&lt;/div&gt;
&lt;br /&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/PsrLMGOZtfA" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/6133919887184109665/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2013/05/miscellaneous.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/6133919887184109665?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/6133919887184109665?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/PsrLMGOZtfA/miscellaneous.html" title="Miscellaneous" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://4.bp.blogspot.com/-V3HtKTdYUXs/UYbR7HPb-YI/AAAAAAAABDA/p4InpdYqvCE/s72-c/vioPCB.JPG" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2013/05/miscellaneous.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DUQCQHo-fCp7ImA9WhBUGE0.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-6020748003685449030</id><published>2013-05-04T18:16:00.002-04:00</published><updated>2013-05-05T22:29:21.454-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-05-05T22:29:21.454-04:00</app:edited><title>Hacking Wise Clock 3/4</title><content type="html">For those who asked how to add hardware and software to their &lt;b&gt;Wise Clock 3&lt;/b&gt; or &lt;b&gt;4&lt;/b&gt;, here is a step-by-step recipe, using the example of a digital vu-meter.&amp;nbsp;The hardware itself is &lt;a href="http://nuewire.com/info-archive/msgeq7-by-j-skoba/"&gt;nothing new&lt;/a&gt;, based on the &lt;a href="https://www.sparkfun.com/datasheets/Components/General/MSGEQ7.pdf"&gt;MSGEQ7&lt;/a&gt; "graphic equalizer display filter" chip. The minor challenge is adding the multi-band vu-meter application to the existing &lt;b&gt;Wise Clock 3/4&lt;/b&gt; software.&lt;br /&gt;
&lt;br /&gt;
&lt;h3 class="r" style="background-color: white; color: #222222; font-family: arial, sans-serif; font-size: medium; font-weight: normal; margin: 0px; overflow: hidden; padding: 0px; text-overflow: ellipsis; white-space: nowrap;"&gt;
&lt;/h3&gt;
&lt;b&gt;Step 1.&lt;/b&gt;&lt;br /&gt;
First make sure that the new hardware works on its own. Connect it to an Arduino and test it with a sketch that performs the desired functionality. This sketch will be the base code for your new &lt;b&gt;Wise Clock 4&lt;/b&gt; "app".&lt;br /&gt;
&lt;br /&gt;
In my example, I assembled the circuit shown below, where the MSGEQ7 and the 3216 display are connected to an old seeeduino. The 3216 display is connected to the same digital pins used in &lt;b&gt;Wise Clock 4&lt;/b&gt; (D12, D13, D14, D15). The MSGEQ7 chip uses analog pin A2 and digital pins D2 and D3 (these will &amp;nbsp;need to be later adapted for&amp;nbsp;&lt;b&gt;Wise Clock 4&lt;/b&gt;).&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://3.bp.blogspot.com/-_ZofJkpPP8M/UX7_hK0eP8I/AAAAAAAABCQ/K9BhCbiYtrQ/s1600/MSGEQ7.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://3.bp.blogspot.com/-_ZofJkpPP8M/UX7_hK0eP8I/AAAAAAAABCQ/K9BhCbiYtrQ/s320/MSGEQ7.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The little green "appendix" connected to the MSGEQ7 board is the &lt;a href="http://www.inexglobal.com/products.php?model=zxsound"&gt;IN-ZX-Sound&lt;/a&gt; microphone amplifier, which could be replaced with the cheaper and probably better &lt;a href="http://adafruit.com/products/1063"&gt;version from Adafruit&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
The working vu-meter sketch (compiled and tested in Arduino 1.0) can be found &lt;a href="https://code.google.com/p/wiseclock2/downloads/detail?name=vu.ino&amp;amp;can=2&amp;amp;q=#makechanges"&gt;here&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Step 2.&lt;/b&gt;&lt;br /&gt;
Re-wire the hardware to the &lt;b&gt;Wise Clock 3/4&lt;/b&gt;&amp;nbsp;board, using digital and/or analog pins that are not already taken, like D18, D19 and A0-A7 (check &lt;a href="http://3.bp.blogspot.com/-OHw-nXpbLUU/TtFfoeGHv5I/AAAAAAAAA1I/sdaKJyHrmzw/s1600/WiseClock4sch.JPG"&gt;schematic here&lt;/a&gt;).&lt;br /&gt;
&lt;br /&gt;
&lt;i&gt;Note: Some "already taken" pins could be re-assigned, but the original functionality that they provide will be lost. For example, you could re-use D20 and D21, which are currently involved in serial communication with the BT module (through SoftwareSerial library, look for&amp;nbsp;USE_SOFTWARE_SERIAL macro in WiseClock.cpp), but then communication with the module will be disabled.&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
In the example, since the 3216 display is already connected (D12-D15), I only had to find two available digital pins (the only choice being D18 and D19) and one analog pin (A0) to connect the MSGEQ7 chip to the ATmega644/1284.&lt;br /&gt;
&lt;br /&gt;
After soldering the 5 wires (3 signal, Vcc and GND), the hacked &lt;b&gt;WC4&lt;/b&gt;&amp;nbsp;board looks like this. (Note that the yellow wire in the photo is left unconnected.)&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://3.bp.blogspot.com/-ORtJYxtpluY/UYVzCwzOQ0I/AAAAAAAABCg/LIUnzdaXLMo/s1600/msgeq7wc4brd.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://3.bp.blogspot.com/-ORtJYxtpluY/UYVzCwzOQ0I/AAAAAAAABCg/LIUnzdaXLMo/s320/msgeq7wc4brd.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;&lt;br /&gt;&lt;/b&gt;
&lt;b&gt;Step 3.&lt;/b&gt;&lt;br /&gt;
Make sure that the code that worked with Arduino (in &lt;b&gt;Step 1&lt;/b&gt;) still works with the &lt;b&gt;Wise Clock 4&lt;/b&gt;&amp;nbsp;board (target board "Sanguino" or "Sanguino with Atmega1284/16MHz" in Arduino IDE), after the hardware and software changes.&lt;br /&gt;
In my example, because I am using D18 and D19 (also used by JTAG), I had to disable JTAG in the code, using these lines:&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;uint8_t tmp = 1&lt;/span&gt;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;lt;JTD;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;MCUCR = tmp;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;MCUCR = tmp;&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
This is the&amp;nbsp;&lt;b&gt;Wise Clock 4&lt;/b&gt; with the display and the attached VU-meter board:&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://3.bp.blogspot.com/-x48_ZEgflek/UYWMyfHRsiI/AAAAAAAABCw/04kveMT-ZCY/s1600/msgeq7wc4.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://3.bp.blogspot.com/-x48_ZEgflek/UYWMyfHRsiI/AAAAAAAABCw/04kveMT-ZCY/s320/msgeq7wc4.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;b&gt;Step 4.&lt;/b&gt;&lt;br /&gt;
Now we focus completely on the software. To add a new app to the existing &lt;b&gt;Wise Clock&lt;/b&gt;&amp;nbsp;sketch, start with creating 2 new files (.h and .cpp) for the new app class. One easy way, for example, is to copy the files &lt;span style="font-family: Courier New, Courier, monospace;"&gt;AppLife.h&lt;/span&gt; and &lt;span style="font-family: Courier New, Courier, monospace;"&gt;AppLife.cpp&lt;/span&gt; and rename those copies &lt;span style="font-family: Courier New, Courier, monospace;"&gt;AppVu.h&lt;/span&gt; and &lt;span style="font-family: Courier New, Courier, monospace;"&gt;AppVu.cpp&lt;/span&gt;, then delete the implementations of the 2 functions (&lt;span style="font-family: Courier New, Courier, monospace;"&gt;init()&lt;/span&gt; and &lt;span style="font-family: Courier New, Courier, monospace;"&gt;run()&lt;/span&gt;) . After updating their content, the 2 new files should look like the ones below.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;// file AppVu.h&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#ifndef _APP_VU_H_&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#define _APP_VU_H_&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;#include "Arduino.h"&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;class CAppVu&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;public:&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; void init();&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; int16_t run();&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;};&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;extern CAppVu appVu;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#endif &amp;nbsp;// _APP_VU_H_&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;// file AppVu.cpp&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;#include "AppVu.h"&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#include "HT1632.h"&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;void CAppVu::init()&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; // todo:&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;int16_t CAppVu::run()&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; // todo:&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;CAppVu appVu;&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Step 5.&lt;/b&gt;&lt;br /&gt;
Modify &lt;span style="font-family: Courier New, Courier, monospace;"&gt;WiseClock.cpp&lt;/span&gt; to include the new header, add new menu item ("VU"), reference the global single instance of this class (named &lt;span style="font-family: Courier New, Courier, monospace;"&gt;appVu&lt;/span&gt; in this case) etc. Basically, add the following lines (in the appropriate places):&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#include "AppVu.h"&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;...&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;// add to enum of menu item indexes&lt;/span&gt;&lt;/div&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;#ifdef _APP_VU_H_&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;MENU_VU,&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#endif&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;...&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;// add the menu item display string&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#ifdef _APP_VU_H_&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;const char menu_str_vu[]&amp;nbsp;PROGMEM = "VU";&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#endif&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;...&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;// add to const char * menu[]&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;PROGMEM = {...&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#ifdef _APP_VU_H_&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;menu_str_vu,&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#endif&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;...&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;// in&amp;nbsp;WiseClock::processButtonSet()&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#ifdef _APP_VU_H_&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;case MENU_VU:&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;crtApp&amp;nbsp;=&amp;nbsp;APP_VU;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;appVu.init();&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;--item;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;isMenuActive&amp;nbsp;=&amp;nbsp;false;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;break;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#endif&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;...&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;// in&amp;nbsp;WiseClock::runCrtApp()&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#ifdef _APP_VU_H_&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;case APP_VU:&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;ms = appVu.run();&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;break;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;#endif&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
In file &lt;span style="font-family: Courier New, Courier, monospace;"&gt;WiseClock.h&lt;/span&gt; add the name of the new app (APP_VU) at the end of the enum:&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;// names of the possible "applications";&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;enum {&amp;nbsp;APP_QUOTE, APP_UTC, APP_BIG, APP_LIFE, APP_DEMO, APP_PONG, &amp;nbsp;APP_PACMAN, APP_LIVED,&amp;nbsp;APP_SCORE, APP_STOPW, APP_CNT_DOWN, APP_WORDS, APP_MSG, APP_STATS, APP_TCLOK,&amp;nbsp;APP_TIX, APP_LINES, APP_SUN, APP_ANIM, APP_LOG_CLEAR, APP_TMP, APP_NEWSD, APP_VU };&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
After all these changes are done, make sure that the &lt;b&gt;Wise Clock&lt;/b&gt; sketch still compiles (even without the functions &lt;span style="font-family: Courier New, Courier, monospace;"&gt;CAppVu::init()&lt;/span&gt; and &lt;span style="font-family: Courier New, Courier, monospace;"&gt;CAppVu::run()&lt;/span&gt; implemented).&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Step 6.&lt;/b&gt;&lt;br /&gt;
Implement the functions&amp;nbsp;&lt;span style="font-family: Courier New, Courier, monospace;"&gt;init()&lt;/span&gt; and &lt;span style="font-family: Courier New, Courier, monospace;"&gt;run()&lt;/span&gt; of the new class (&lt;span style="font-family: Courier New, Courier, monospace;"&gt;CAppVu::init()&lt;/span&gt; and &lt;span style="font-family: Courier New, Courier, monospace;"&gt;CAppVu::run()&lt;/span&gt; in my example). The code for &lt;span style="font-family: Courier New, Courier, monospace;"&gt;init()&lt;/span&gt; should be copied from the function &lt;span style="font-family: Courier New, Courier, monospace;"&gt;setup()&lt;/span&gt; of the prototype sketch (in &lt;b&gt;Step 1&lt;/b&gt;).&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;void CAppVu::init()&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; // disable JTAG;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; uint8_t tmp = 1&lt;/span&gt;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;lt;JTD;&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp;MCUCR = tmp;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; MCUCR = tmp;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; // MSGEQ7;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; pinMode(analogPin, INPUT);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; pinMode(strobePin, OUTPUT);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; pinMode(resetPin, OUTPUT);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; analogReference(DEFAULT);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; digitalWrite(resetPin, LOW);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; digitalWrite(strobePin, HIGH);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; clearDisplay();&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
The code for &lt;span style="font-family: Courier New, Courier, monospace;"&gt;run()&lt;/span&gt; comes from the &lt;span style="font-family: Courier New, Courier, monospace;"&gt;loop()&lt;/span&gt; function in the prototype sketch of &lt;b&gt;Step 1&lt;/b&gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;// show 2-columns bars for each of the 7 channels;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;int16_t CAppVu::run()&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;clearDisplay();&lt;/span&gt;&lt;br /&gt;
&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;&lt;span style="font-family: Courier New, Courier, monospace;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;digitalWrite(resetPin, HIGH);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;digitalWrite(resetPin, LOW);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;for (int i = 0; i &amp;lt; 7; i++)&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;digitalWrite(strobePin, LOW);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;delayMicroseconds(30); // allow output to settle;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;spectrumValue[i] = analogRead(analogPin);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;digitalWrite(strobePin, HIGH);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; // try to eliminate some noise;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;if (spectrumValue[i] &amp;lt; 100)&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; spectrumValue[i] = 0;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;int x = i*5;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt;  &lt;/span&gt;int vu = spectrumValue[i]/64;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; if (vu &amp;lt;= 8)&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x, 15, x, 15-vu, GREEN);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x+1, 15, x+1, 15-vu, GREEN);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; else if (vu &amp;lt;= 12)&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x, 15, x, 8, GREEN);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x+1, 15, x+1, 8, GREEN);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x, 7, x, 15-vu, ORANGE);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x+1, 7, x+1, 15-vu, ORANGE);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; else&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x, 15, x, 8, GREEN);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x+1, 15, x+1, 8, GREEN);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x, &amp;nbsp;7, x, 4, ORANGE);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x+1,7, x+1, 4, ORANGE);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x, &amp;nbsp;3, x, 16-vu, RED);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; ht1632_line(x+1,3, x+1, 16-vu, RED);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: Courier New, Courier, monospace;"&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Note that the &lt;span style="font-family: Courier New, Courier, monospace;"&gt;CAppVu::run()&lt;/span&gt; uses a new display function&amp;nbsp;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;ht1632_line(...)&lt;/span&gt;, which needs to be added to &lt;span style="font-family: Georgia, Times New Roman, serif;"&gt;HT1632.h&lt;/span&gt; and &lt;span style="font-family: Courier New, Courier, monospace;"&gt;cpp&lt;/span&gt;.&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Step 7.&lt;/b&gt;&lt;br /&gt;
Compile, upload and test. Then improve, extend, publish and brag about it :)&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;object width="320" height="266" class="BLOGGER-youtube-video" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" data-thumbnail-src="http://i.ytimg.com/vi/TnDEQtsf8ew/0.jpg"&gt;&lt;param name="movie" value="http://www.youtube.com/v/TnDEQtsf8ew?version=3&amp;f=user_uploads&amp;c=google-webdrive-0&amp;app=youtube_gdata" /&gt;&lt;param name="bgcolor" value="#FFFFFF" /&gt;&lt;param name="allowFullScreen" value="true" /&gt;&lt;embed width="320" height="266"  src="http://www.youtube.com/v/TnDEQtsf8ew?version=3&amp;f=user_uploads&amp;c=google-webdrive-0&amp;app=youtube_gdata" type="application/x-shockwave-flash" allowfullscreen="true"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Homework&lt;/b&gt;&lt;br /&gt;
Add graphic effects (e.g. display like a 6-inflection point graph), selectable from menu (follow example of the UTC app).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/8_Lj9aX-UjU" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/6020748003685449030/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2013/05/hacking-wise-clock-34.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/6020748003685449030?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/6020748003685449030?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/8_Lj9aX-UjU/hacking-wise-clock-34.html" title="Hacking Wise Clock 3/4" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/-_ZofJkpPP8M/UX7_hK0eP8I/AAAAAAAABCQ/K9BhCbiYtrQ/s72-c/MSGEQ7.JPG" height="72" width="72" /><thr:total>2</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2013/05/hacking-wise-clock-34.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D0AHQnczfSp7ImA9WhBUGE0.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-3774552105104396246</id><published>2013-04-04T11:28:00.001-04:00</published><updated>2013-05-05T22:02:13.985-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-05-05T22:02:13.985-04:00</app:edited><title>The Akafugu Nixie Clock</title><content type="html">I like Nixie tubes, especially when they are used in clocks, like&lt;a href="http://timewitharduino.blogspot.ca/2010/08/nixie-clock.html"&gt; this one&lt;/a&gt; I built a while ago. Although almost&amp;nbsp;all Nixie clocks look the same, sometimes there is one that catches the eye. Such as the case of &lt;b&gt;&lt;a href="http://www.akafugu.jp/posts/products/nixie/"&gt;Agafuku Nixie Clock&lt;/a&gt;,&lt;/b&gt;&amp;nbsp;designed in (and shipped from) Japan. The first thing to notice is that the final clock built from this kit is complete with enclosure, a rare find in the world of Nixie clock kits. Then, there is the look: simple, yet elegant, compact, yet functional. Obviously, I wanted one. Per, from Akafugu Corporation, graciously accepted to barter their Nixie clock kit for my &lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2011/12/buy-complete-wise-clock-4-kit-includes.html"&gt;Wise Clock 4 kit&lt;/a&gt;&lt;/b&gt;. Following is my brief review.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &lt;b&gt;Akafugu Nixie clock&lt;/b&gt; kit looks professional starting with the box. Here are a few photos to prove that, taken as I was opening the package.&lt;br /&gt;
&lt;br /&gt;
&lt;div style="text-align: left;"&gt;
&lt;a href="http://2.bp.blogspot.com/-BkX_QKHzT4Q/UVyyNBJ-lrI/AAAAAAAABBA/mcZtVAxtlGk/s1600/aka_box.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://2.bp.blogspot.com/-BkX_QKHzT4Q/UVyyNBJ-lrI/AAAAAAAABBA/mcZtVAxtlGk/s320/aka_box.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://4.bp.blogspot.com/-BoHBOSd_hgY/UVyyVM9oRcI/AAAAAAAABBI/TDDyibsm44I/s1600/aka_box2.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://4.bp.blogspot.com/-BoHBOSd_hgY/UVyyVM9oRcI/AAAAAAAABBI/TDDyibsm44I/s320/aka_box2.JPG" width="240" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
I was surprised to find a power adapter included!&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://3.bp.blogspot.com/-y5nEC9qX1QA/UVyyfgzK5OI/AAAAAAAABBQ/OUWMBIyM7j4/s1600/aka_in1.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://3.bp.blogspot.com/-y5nEC9qX1QA/UVyyfgzK5OI/AAAAAAAABBQ/OUWMBIyM7j4/s320/aka_in1.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://2.bp.blogspot.com/-QXxP-fSW9VM/UVyypHepRkI/AAAAAAAABBY/PkK5eXH3nlw/s1600/aka_in2.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://2.bp.blogspot.com/-QXxP-fSW9VM/UVyypHepRkI/AAAAAAAABBY/PkK5eXH3nlw/s320/aka_in2.JPG" width="320" /&gt;&lt;/a&gt;&lt;a href="http://2.bp.blogspot.com/-QXxP-fSW9VM/UVyypHepRkI/AAAAAAAABBY/PkK5eXH3nlw/s1600/aka_in2.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;br /&gt;&lt;/a&gt;&lt;a href="http://2.bp.blogspot.com/-QXxP-fSW9VM/UVyypHepRkI/AAAAAAAABBY/PkK5eXH3nlw/s1600/aka_in2.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;br /&gt;&lt;/a&gt;
&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The clock's electronics are distributed onto three PCBs, shown in the photo below:&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;the power board (on the left), containing the 5V regulator and the high voltage switching-mode power supply; this board is SMD-only and all parts are pre-soldered;&lt;/li&gt;
&lt;li&gt;the control board (on the right), which contains the microcontroller and the Nixie driver; this board is mainly through hole, the sole SMD component (pre-soldered) being the RTC (DS3231);&lt;/li&gt;
&lt;li&gt;the display board (middle of the photo), designed to fit IN12 Russian Nixie tubes; this board also has some SMD parts pre-soldered (LEDs, connectors etc).&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://2.bp.blogspot.com/-3cMdpYWOk7w/UVzGJ-ou1lI/AAAAAAAABBo/31tuu10vtPI/s1600/aka_boards.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://2.bp.blogspot.com/-3cMdpYWOk7w/UVzGJ-ou1lI/AAAAAAAABBo/31tuu10vtPI/s320/aka_boards.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Remarkable and original is the fact that two of the PCBs are actually part of the enclosure: the power board is the back panel, the display board being the front panel. For the back panel, this is pulled off by using only SMDs, with no traces or pads on the outside part of the board. Did I mention that the power board comes with all (SMD) parts already soldered?&lt;br /&gt;
&lt;br /&gt;
The inclusion of the boards as part of the case is a novel approach, worth applying to future projects, with obvious advantages (reduces the number of fasteners/screws/standoffs, eliminates the attachments between the PCBs and the front/end panels etc).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
I assembled the clock following the &lt;a href="http://www.akafugu.jp/posts/products/nixie/assembly/"&gt;detailed instructions provided&lt;/a&gt;. Most of the required soldering is on the control board. Some attention must also be paid to positioning of the Nixie tubes on the display board before soldering them. After about an hour of work I had the &lt;b&gt;Akafugu Nixie clock&lt;/b&gt;&amp;nbsp;up and running. The result is shown in the photos below.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://3.bp.blogspot.com/-KBRj0TBCKd0/UVzXSP1ZqcI/AAAAAAAABB4/jrEt-7tPnyI/s1600/aka_on.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://3.bp.blogspot.com/-KBRj0TBCKd0/UVzXSP1ZqcI/AAAAAAAABB4/jrEt-7tPnyI/s320/aka_on.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://1.bp.blogspot.com/-yq7CYyw-2os/UVzXZf2lV3I/AAAAAAAABCA/K0z-O9SlwJ8/s1600/aka_hand.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://1.bp.blogspot.com/-yq7CYyw-2os/UVzXZf2lV3I/AAAAAAAABCA/K0z-O9SlwJ8/s320/aka_hand.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Beside being a cool geeky gadget, &lt;b&gt;Akafugu Nixie clock&lt;/b&gt; can also be used as a functional alarm clock. The clock's functions are set by using the rotary encoder. Each tube can be lit up by an RGB LED (placed right under). The &lt;a href="https://github.com/akafugu/akafugu_nixie_clock"&gt;software&lt;/a&gt;, Arduino-compatible, is open source and can be modified using the Arduino IDE, then uploaded through the 6-pin FTDI interface/connector.&lt;br /&gt;
&lt;br /&gt;
An improvement I would do is to allow for the easy replacement of the Nixie tubes, in case one gets burnt out (as it could happen with tubes, in general). This can be achieved by soldering tube socket pins on the display board instead of soldering the tubes directly to the board. I am sure Akafugu thought of this already, but they may have opted against it because it makes the Nixies stick out a bit more. I was actually going to follow up myself with this improvement, but the socket pins I found are too thick (~2mm) to go through the 1.5mm holes.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Overall, I was impressed with how nicely designed and&amp;nbsp;well engineered&amp;nbsp;this clock is. As a kit maker myself, I can appreciate the amount of work that went into creating this kit, from designing the hardware, to choosing the components, to cramming them all in such a compact space, to writing the software. Kudos for making it so easy to assemble, even by a beginner, with spectacular results.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
For someone who likes Nixie clocks, the&amp;nbsp;&lt;b&gt;Akafugu Nixie clock&lt;/b&gt;&amp;nbsp;is definitely a must-have.&lt;br /&gt;
Those who like clocks&amp;nbsp;should add the&amp;nbsp;&lt;b&gt;Akafugu Nixie clock&lt;/b&gt;&amp;nbsp;to their collection.&lt;br /&gt;
Those who like electronic kits&amp;nbsp;will find the&amp;nbsp;&lt;b&gt;Akafugu Nixie clock&lt;/b&gt;&amp;nbsp;kit&amp;nbsp;inspirational.&lt;br /&gt;
&lt;br /&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/xpwtv8GruGo" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/3774552105104396246/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2013/04/the-akafugu-nixie-clock.html#comment-form" title="7 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/3774552105104396246?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/3774552105104396246?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/xpwtv8GruGo/the-akafugu-nixie-clock.html" title="The Akafugu Nixie Clock" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-BkX_QKHzT4Q/UVyyNBJ-lrI/AAAAAAAABBA/mcZtVAxtlGk/s72-c/aka_box.JPG" height="72" width="72" /><thr:total>7</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2013/04/the-akafugu-nixie-clock.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DEAHSX05fSp7ImA9WhBSFk8.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-909823886774351858</id><published>2013-02-22T12:13:00.000-05:00</published><updated>2013-02-23T08:38:58.325-05:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-02-23T08:38:58.325-05:00</app:edited><title>User-friendly configuration of a Wi-Fi device</title><content type="html">My &lt;a href="http://timewitharduino.blogspot.ca/2012/12/user-interaction-when-connecting-wifi.html"&gt;previous post&lt;/a&gt; enumerated a few methods for configuring a device to connect to the home Wi-Fi network.&lt;br /&gt;
One of the friendliest way was number 4 (&lt;b style="background-color: white; color: #333333; font-family: Georgia, serif; font-size: 15px; line-height: 20.796875px; text-indent: -24px;"&gt;Creating a temporary ad-hoc Wi-Fi network&lt;/b&gt;). This method was chosen by &lt;a href="http://www.kickstarter.com/projects/supermechanical/twine-listen-to-your-world-talk-to-the-internet?ref=live"&gt;Twine&lt;/a&gt; and also by &lt;a href="http://www.kickstarter.com/projects/474874800/heatmeter-stay-informed-save-energy?ref=live"&gt;HeatMeter&lt;/a&gt;&amp;nbsp;and &lt;a href="http://www.belkin.com/us/support-article?rnId=7073"&gt;Belkin WeMo&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
In normal use, the device connects to the home Wi-Fi network as a client, then sends (http GET/POST) the collected data to a web server.&lt;br /&gt;
&lt;br /&gt;
Sometimes, when the device needs to be configured, it creates its own Wi-Fi network and runs a local web server. At this moment it allows other Wi-Fi devices (PC, smart phone etc) to connect, as clients, to the local web server and send configuration data, specifically the name of the home Wi-Fi network and the password. Once this configuration data is acquired and stored internally (in eeprom), the device returns to its normal state and uses it to connect to the home Wi-Fi network.&lt;br /&gt;
The configuration mode is selected by the user. One simple method is by holding down a button after a reset. Another is by placing the device (which has on-board accelerometer or even a tilt sensor) in a specific orientation (as done by Twine).&lt;br /&gt;
&lt;br /&gt;
Below are diagrams I drew to show these two modes of operation (configuration mode and regular use mode).&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://2.bp.blogspot.com/-q78aclMVKuo/USekGh6HqWI/AAAAAAAABAY/LXoCHCxsZNo/s1600/wificfg3.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="300" src="http://2.bp.blogspot.com/-q78aclMVKuo/USekGh6HqWI/AAAAAAAABAY/LXoCHCxsZNo/s400/wificfg3.jpg" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The steps are:&lt;br /&gt;
&lt;span style="font-size: 12pt;"&gt;1.&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt;"&gt;After
reset, if a switch&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt; is pressed by the user, the board
enters the configuration mode. This makes &amp;nbsp;the Wi-Fi module a Wi-Fi server.&lt;/span&gt;&lt;br /&gt;
&lt;div style="direction: ltr; margin-bottom: 0pt; margin-left: 0.25in; margin-top: 0pt; text-indent: -0.25in; unicode-bidi: embed; word-break: normal;"&gt;
&lt;span style="font-size: 12.0pt;"&gt;2.&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;The user connects to it from laptop. Then
user is presented with a web page that contains a form allowing the selection
of the Wi-Fi networks that were detected, and the password.&lt;/span&gt;&lt;/div&gt;
&lt;div style="direction: ltr; margin-bottom: 0pt; margin-left: 0.25in; margin-top: 0pt; text-indent: -0.25in; unicode-bidi: embed; word-break: normal;"&gt;
&lt;span style="font-size: 12.0pt;"&gt;3.&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;These 2 elements (network name and
password) are then saved in the &lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;eeprom&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;. They will be used later to access the
Wi-Fi network any time the sensor data gets sent to the collection web server.&lt;/span&gt;&lt;/div&gt;
&lt;div style="direction: ltr; margin-bottom: 0pt; margin-left: 0.25in; margin-top: 0pt; text-indent: -0.25in; unicode-bidi: embed; word-break: normal;"&gt;
&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="direction: ltr; margin-bottom: 0pt; margin-left: 0.25in; margin-top: 0pt; text-indent: -0.25in; unicode-bidi: embed; word-break: normal;"&gt;
&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://1.bp.blogspot.com/-Ok-csKOY9t8/USekPnjAjSI/AAAAAAAABAg/wvl1ivkoHRo/s1600/wificfg2.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="298" src="http://1.bp.blogspot.com/-Ok-csKOY9t8/USekPnjAjSI/AAAAAAAABAg/wvl1ivkoHRo/s400/wificfg2.jpg" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Steps:&lt;br /&gt;
&lt;span style="font-size: 12pt;"&gt;1.&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt;"&gt;Data
is&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt; read from the sensor.&lt;/span&gt;&lt;br /&gt;
&lt;div style="direction: ltr; margin-bottom: 0pt; margin-left: 0.25in; margin-top: 0pt; text-indent: -0.25in; unicode-bidi: embed; word-break: normal;"&gt;
&lt;span style="font-size: 12.0pt;"&gt;2.&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;Sensor data is sent as an http POST
request through the Wi-Fi module.&lt;/span&gt;&lt;/div&gt;
&lt;div style="direction: ltr; margin-bottom: 0pt; margin-left: 0.25in; margin-top: 0pt; text-indent: -0.25in; unicode-bidi: embed; word-break: normal;"&gt;
&lt;span style="font-size: 12.0pt;"&gt;3.&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;Wi-Fi module posts the sensor data to the
web server.&lt;/span&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
A nice feature for a network-connected device is that it can get program upgrades remotely, "over the air" in the case of Wi-Fi. This requires a bootloader that can connect to the internet and checks if a new version of the program is available for download on a given web server. The &lt;a href="http://readiymate.com/"&gt;Readiymate&lt;/a&gt; team wrote such a bootloader for &lt;a href="http://www.atmel.com/images/doc2549.pdf"&gt;ATmega1280/2560&lt;/a&gt; (the processor(s) found on &lt;a href="http://arduino.cc/en/Main/ArduinoBoardMega2560"&gt;Arduino Mega&lt;/a&gt;).&lt;br /&gt;
&lt;br /&gt;
The next diagram shows how the remote program upgrade would work.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://4.bp.blogspot.com/-64qw_7fhSiM/USemkWV1U5I/AAAAAAAABAo/il74n1ftalk/s1600/wificfg1.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="293" src="http://4.bp.blogspot.com/-64qw_7fhSiM/USemkWV1U5I/AAAAAAAABAo/il74n1ftalk/s400/wificfg1.jpg" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The steps are:&lt;br /&gt;
&lt;span style="font-size: 12pt;"&gt;1.&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;Bootloader&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;
makes an http GET request through the Wi-Fi module.&lt;/span&gt;&lt;br /&gt;
&lt;div style="direction: ltr; margin-bottom: 0pt; margin-left: 0.25in; margin-top: 0pt; text-indent: -0.25in; unicode-bidi: embed; word-break: normal;"&gt;
&lt;span style="font-size: 12.0pt;"&gt;2.&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;Wi-Fi module passes the request the web
server used for “program updates”.&lt;/span&gt;&lt;/div&gt;
&lt;div style="direction: ltr; margin-bottom: 0pt; margin-left: 0.25in; margin-top: 0pt; text-indent: -0.25in; unicode-bidi: embed; word-break: normal;"&gt;
&lt;span style="font-size: 12.0pt;"&gt;3.&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;Web server starts streaming the latest
program file (sketch).&lt;/span&gt;&lt;/div&gt;
&lt;div style="direction: ltr; margin-bottom: 0pt; margin-left: 0.25in; margin-top: 0pt; text-indent: -0.25in; unicode-bidi: embed; word-break: normal;"&gt;
&lt;span style="font-size: 12.0pt;"&gt;4.&lt;/span&gt;&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;The sketch is uploaded into the program
memory.&lt;/span&gt;&lt;/div&gt;
&lt;div style="direction: ltr; margin-bottom: 0pt; margin-left: 0.25in; margin-top: 0pt; text-indent: -0.25in; unicode-bidi: embed; word-break: normal;"&gt;
&lt;span style="font-family: Calibri; font-size: 12pt; vertical-align: baseline;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/q5n0N15J8Fw" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/909823886774351858/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2013/02/user-friendly-configuration-of-wi-fi.html#comment-form" title="3 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/909823886774351858?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/909823886774351858?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/q5n0N15J8Fw/user-friendly-configuration-of-wi-fi.html" title="User-friendly configuration of a Wi-Fi device" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-q78aclMVKuo/USekGh6HqWI/AAAAAAAABAY/LXoCHCxsZNo/s72-c/wificfg3.jpg" height="72" width="72" /><thr:total>3</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2013/02/user-friendly-configuration-of-wi-fi.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkQNRXs8fCp7ImA9WhBSFUs.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-8741091745419497791</id><published>2012-12-31T16:55:00.001-05:00</published><updated>2013-02-22T15:19:54.574-05:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-02-22T15:19:54.574-05:00</app:edited><title>User interaction when connecting WiFi devices to network</title><content type="html">&lt;span style="font-family: inherit;"&gt;&lt;span style="font-size: 11pt;"&gt;I spent some time recently analyzing methods for passing the WiFi&amp;nbsp;&lt;/span&gt;&lt;span style="font-size: 15px;"&gt;parameters&lt;/span&gt;&lt;span style="font-size: 15px;"&gt;&amp;nbsp;(network name and password) to a device, in user-friendly manner and on the cheap (that is, by using minimum extra hardware).&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class="MsoNormal"&gt;
&lt;span style="font-family: inherit; font-size: 11.0pt;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;span style="font-family: inherit; font-size: 15px;"&gt;This challenge (of selecting the WiFi and entering the network password) was already solved in many different ways, from using the remote control to select characters displayed on the TV screen (as done by Apple TV, XBox etc), to creating an &lt;a href="http://en.wikipedia.org/wiki/Wireless_ad-hoc_network"&gt;ad-hoc WiFi network&lt;/a&gt; (as done by &lt;a href="http://yourhome.honeywell.com/home/Products/Thermostats/7-Day-Programmable/RTH8580WF.htm"&gt;WiFi thermostats&lt;/a&gt;, &lt;a href="http://www.kickstarter.com/projects/supermechanical/twine-listen-to-your-world-talk-to-the-internet"&gt;Twine&lt;/a&gt; and others).&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 15px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;span style="font-family: inherit;"&gt;The bottom line is that every WiFi device must somehow present the users with an interface that allows them to type in the network password. How this is solved determines the user-friendliness&amp;nbsp;of the device and influences the final cost of the product as well.&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;span style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;span style="font-family: inherit; font-size: 15px;"&gt;Here are the methods I found so far. I am sure this list will be extended and improved with details, hopefully also based on the readers' comments and feedback.&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;1.&lt;/b&gt; &lt;b&gt;SD card that includes a text file with network name and password&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;The user edits the text file on any computer. The SD
card is then transferred onto the device. After the device is powered, the settings are
stored internally and the SD card can be permanently removed.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Pros:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- user-friendly and almost fool-proof;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- easy to implement in software;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- SD card may be also used for storing other data (backup in case of network disconnect, power outage etc);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Cons:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- need access to a PC (any text editor would work);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- a&lt;/span&gt;&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;dds
about $6 to the total cost of the device (SD socket, SD card);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- device may need to be shipped with a an SD
card USB adapter (adds another $2).&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;2. Bluetooth&lt;/b&gt; – The user interface is provided by a smart phones that communicates with the device through Bluetooth.&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Pros:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- very user-friendly user interface through the smart phone app (e.g. Android), that uses a full keyboard and a complete feedback (similar to text editor);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;-&amp;nbsp;&lt;/span&gt;&lt;span style="font-size: 15px; text-indent: -24px;"&gt;easy to develop&lt;/span&gt;&lt;span style="font-size: 15px; text-indent: -24px;"&gt;&amp;nbsp;the&amp;nbsp;&lt;/span&gt;&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;software for Bluetooth communication for the device;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Cons:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- adds $5 to the cost of the device (BT
module);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- a simple application (e.g. BlueTerminal) needs to be downloaded by the user on the smart phone;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- may not work with iPhone, which requires Apple-licensed BT
modules.&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit;"&gt;&lt;span style="font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;3. Using QR code that ships with the device&lt;/b&gt; - patented,&amp;nbsp;&lt;/span&gt;&lt;span style="font-size: 15px; text-indent: -0.25in;"&gt;licence-able technology&lt;/span&gt;&lt;span style="font-size: 11pt; text-indent: -0.25in;"&gt;; to investigate further (price, complexity etc.);&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Pros:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- (maybe) user friendly, with minimal user interaction: smart phone app leads to a web site that requires the user to input the password;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Cons:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- pay royalties;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- need smart phone with camera and software app for QR codes.&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;4. Creating a temporary ad-hoc Wifi network&lt;/b&gt; (as used by some smart WiFi enabled
thermostats)&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Pros:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- easy to use web interface;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Cons:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- need a computer that can connect to the existing WiFi;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- requires development of the web site (for&amp;nbsp;&lt;/span&gt;&lt;span style="font-size: 15px;"&gt;inputting the password);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- requires a way to switch the device between the setup mode and regular operation (when already connected to the WiFi). (Note: The above mentioned Twine uses an accelerometer chip for this purpose.)&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;5. Include an LCD screen with touch sensor or buttons&lt;/b&gt; (as in &lt;a href="http://www.nest.com/"&gt;Nest&lt;/a&gt;).&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Pros:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- all inclusive solution, no other equipment required to interface with the user;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Cons:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- adds to the final cost (at least $4);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- may be cumbersome to use, since the display is quite limited in space;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- makes the device bigger;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- software to handle the user interaction can be quite complicated (for such a simple task);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- waste of resources, since the LCD screen and buttons/touch may be used only for this purpose (user input).&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;6. Use a wired (custom, non-PC) input terminal, with screen and keyboard&lt;/b&gt;, that communicates on serial (RS232, RS485, TTL) interface with the device.&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Pros:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- simpler software (processing the commands received on the serial interface);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- does not require extra hardware on the device itself;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Cons:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- need to provide the terminal hardware as well (OK solution when the device installation is done by a trained person).&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;7. Use an infrared (TV, VCR&lt;/b&gt;&lt;/span&gt;&lt;b style="font-size: 15px; text-indent: -24px;"&gt;, stereo&lt;/b&gt;&lt;b style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&amp;nbsp;etc) remote control&lt;/b&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Pros:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;-&amp;nbsp;&lt;/span&gt;&lt;span style="font-size: 15px;"&gt;ubiquitous, everybody is guaranteed to have one around;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-size: 15px;"&gt;- software is relatively easy to develop;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Cons:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- user interface not friendly; it would require some&amp;nbsp;&lt;/span&gt;&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;user feedback (display);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal" style="text-indent: 0px;"&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;8. &lt;a href="http://developer.android.com/guide/topics/connectivity/nfc/index.html"&gt;NFC&lt;/a&gt; (Near Field Communication)&lt;/b&gt; - to be researched&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Pros:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- friendly user interface through the smart phone;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Cons:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- requires a smart phone;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- need to develop app for smart phone.&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;9. Direct connection to PC through USB/FTDI cable&lt;/b&gt; - as done by the&lt;a href="http://readiymate.com/"&gt; readiymate&lt;/a&gt; board&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Pros:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- the simplest to implement method: the board's microcontroller listens to and interprets the serial commands from PC;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- change the network name and password through either the serial monitor (command mode style) or through a GUI app that translates button clicks into serial commands;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;b&gt;Cons:&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- requires on board FTDI chip (adds about $5 to the board's cost);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- requires development of the PC (GUI) app that talks to the board;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;- also requires the user to download and install the app on the PC.&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
&lt;span style="font-family: inherit; font-size: 11pt; text-indent: -0.25in;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/TbgXqTowef8" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/8741091745419497791/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/12/user-interaction-when-connecting-wifi.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/8741091745419497791?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/8741091745419497791?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/TbgXqTowef8/user-interaction-when-connecting-wifi.html" title="User interaction when connecting WiFi devices to network" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>0</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/12/user-interaction-when-connecting-wifi.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkQCQHg9fSp7ImA9WhNTFE4.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-4417328460555154446</id><published>2012-10-16T20:39:00.001-04:00</published><updated>2012-10-16T20:39:21.665-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-10-16T20:39:21.665-04:00</app:edited><title>Raspberry Pi AlaMode</title><content type="html">The great team of &lt;a href="http://wyolum.com/"&gt;Wyolum&lt;/a&gt; announced that their &lt;b&gt;Raspberry Pi AlaMode&lt;/b&gt; is &lt;a href="http://wyolum.com/shop/25-alamode.html"&gt;available for pre-order&lt;/a&gt;.&lt;br /&gt;
This board, shown in the photo below, is Wyolum's answer to&amp;nbsp;interfacing any number of hardware shields, sensors and servos to the &lt;a href="http://www.raspberrypi.org/"&gt;&lt;b&gt;Raspberry Pi&lt;/b&gt;&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://wyolum.com/shop/25-106-thickbox/alamode.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em; text-align: center;"&gt;&lt;img border="0" height="400" src="http://wyolum.com/shop/25-106-thickbox/alamode.jpg" width="400" /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;b&gt;AlaMode&lt;/b&gt; is an Arduino compatible board that plugs right on top of the Raspberry Pi 
computer. It also gives you:&lt;br /&gt;

&lt;div&gt;
&lt;ul&gt;
&lt;li&gt;extremely accurate real time clock DS3231 with backup battery&lt;/li&gt;
&lt;li&gt;micro SD slot
&lt;/li&gt;
&lt;li&gt;direct headers for plugging in servos
&lt;/li&gt;
&lt;li&gt;safe voltage translation between the Raspberry Pi and Arduino.&lt;/li&gt;
&lt;/ul&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/8Qv9k8gQ-6E" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/4417328460555154446/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/10/raspberry-pi-alamode.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/4417328460555154446?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/4417328460555154446?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/8Qv9k8gQ-6E/raspberry-pi-alamode.html" title="Raspberry Pi AlaMode" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>2</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/10/raspberry-pi-alamode.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D08GRn85cCp7ImA9WhJaGE4.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-8259326480776320145</id><published>2012-10-09T22:20:00.000-04:00</published><updated>2012-10-09T22:23:47.128-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-10-09T22:23:47.128-04:00</app:edited><title>Stock ticker with Wise Clock 4 and WiFly</title><content type="html">I should have titled this "Adventures in WiFly land - Part 2", a continuation of &lt;a href="http://timewitharduino.blogspot.ca/2012/01/adventures-in-wifly-land-part-1.html"&gt;this post&lt;/a&gt;, but really there was no adventure. Things worked smoothly from the start. The main "challenge" was parsing the http response on the fly, since the (truncated) response string itself is about 1500 bytes (3/4 of the RAM in a 328), which is the size of WiFly's receiving buffer.&lt;br /&gt;
&lt;br /&gt;
&lt;iframe allowfullscreen="allowfullscreen" frameborder="0" height="315" src="http://www.youtube.com/embed/1_lNkdUSz3U" width="420"&gt;&lt;/iframe&gt;

&lt;br /&gt;
&lt;br /&gt;
The code (&lt;a href="http://code.google.com/p/wiseclock2/downloads/detail?name=StockTicker1632.zip&amp;amp;can=2&amp;amp;q=#makechanges"&gt;download from here&lt;/a&gt;) performs these steps:&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;send http request to &lt;a href="http://pipes.yahoo.com/pipes/pipe.run?_id=ZKJobpaj3BGZOew9G8evXg&amp;amp;_render=rss&amp;amp;ticker=INTC"&gt;yahoo site&lt;/a&gt;, specifying the stock symbol;&lt;/li&gt;
&lt;li&gt;read the http response and find the token that identifies the stock price, in this case "&lt;i&gt;last:&lt;/i&gt;";&lt;/li&gt;
&lt;li&gt;read the next few characters that represent the stock price;&lt;/li&gt;
&lt;li&gt;display the symbol and the price on the 3216 display.&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
This crude version is based on the WiFly_WebClient &lt;a href="https://github.com/sparkfun/WiFly-Shield"&gt;sample code from sparkfun&lt;/a&gt;. For display, it&amp;nbsp;uses the HT1632 (header and c) files that are part of &lt;b&gt;Wise Clock 4&lt;/b&gt; library (but also supplied in the zip file). The software should work with any Arduino connected to a &lt;a href="https://www.sparkfun.com/products/10822"&gt;serial WiFly&lt;/a&gt; and a 3216 display from Sure Electronics.&lt;br /&gt;
&lt;br /&gt;
The plan is to integrate this code as&amp;nbsp;a new application in the &lt;b&gt;Wise Clock 4&lt;/b&gt; software. Stock symbols should be user-configurable and read from the SD card (as opposed to being hardcoded as they are now).&lt;br /&gt;
Also, the direction of the stock move, read from the http response as well (after the token "&lt;i&gt;change&lt;/i&gt;"), could be shown in red for "down" and in green for "up".&lt;br /&gt;
&lt;br /&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/Vc5Nf7kwQwQ" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/8259326480776320145/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/10/stock-ticker-with-wise-clock-4-and-wifly.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/8259326480776320145?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/8259326480776320145?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/Vc5Nf7kwQwQ/stock-ticker-with-wise-clock-4-and-wifly.html" title="Stock ticker with Wise Clock 4 and WiFly" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://img.youtube.com/vi/1_lNkdUSz3U/default.jpg" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/10/stock-ticker-with-wise-clock-4-and-wifly.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkEDRn8yfip7ImA9WhJUEUw.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-1440926889271658167</id><published>2012-09-06T10:53:00.001-04:00</published><updated>2012-09-08T09:24:37.196-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-09-08T09:24:37.196-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><category scheme="http://www.blogger.com/atom/ns#" term="WiFi" /><title>Post data to cosm.com with WiseClock4 + WiFly</title><content type="html">Last weekend I re-discovered cosm.com, formerly known as pachube.com.&lt;br /&gt;
After spending a lot less time than I had planned (since things went so smoothly), I was about to post details about the experience; then I saw &lt;a href="http://www.sparkfun.com/news/948"&gt;this fresh post&lt;/a&gt; on sparkfun, which pretty much explains everything one needs to know about creating an account and sending data.&lt;br /&gt;
&lt;br /&gt;
The main difference between sparkfun's setup and mine is the connection to internet: I used the &lt;a href="http://www.sparkfun.com/news/948"&gt;WiFly module&lt;/a&gt; plugged into the &lt;a href="http://timewitharduino.blogspot.ca/2011/11/wise-clock-4.html"&gt;&lt;b&gt;WiseClock4&lt;/b&gt;&lt;/a&gt; board. Therefore, the code is a little bit different too: I used the great &lt;a href="https://github.com/jmr13031/WiFly-Shield"&gt;WiFly library&lt;/a&gt;, which even comes with a (little dated) "pachube client" example. All one needs to do is provide the right parameters (app key, network ssid, password etc) in credentials.h, then change all references from "pachube" to "cosm".&lt;br /&gt;
&lt;br /&gt;
As a quick experiment, I read the value from (disconnected) A0&amp;nbsp;every 25 seconds, and this is how the &lt;a href="https://cosm.com/feeds/71094"&gt;cosm graph&lt;/a&gt; looks like:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="https://api.cosm.com/v2/feeds/71094/datastreams/sensor1.png?width=730&amp;amp;height=250&amp;amp;colour=%23f15a24&amp;amp;duration=1day&amp;amp;show_axis_labels=true&amp;amp;detailed_grid=true&amp;amp;scale=auto" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="109" src="https://api.cosm.com/v2/feeds/71094/datastreams/sensor1.png?width=730&amp;amp;height=250&amp;amp;colour=%23f15a24&amp;amp;duration=1day&amp;amp;show_axis_labels=true&amp;amp;detailed_grid=true&amp;amp;scale=auto" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
A user-friendly cosm-client device based on &lt;b&gt;WiseClock4&lt;/b&gt; with WiFly (which, by the way, seems to be the cheapest way to connect to a WiFi network) would read the configuration parameters from a file on SD card (then,&amp;nbsp;for security reasons,&amp;nbsp;delete the file and store those parameters in eeprom) or provide a way to receive these parameters (ssid, password, app key etc) from a smart phone through bluetooth.&lt;br /&gt;
&lt;br /&gt;
(To be continued)&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/UYwO_u-HGp4" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/1440926889271658167/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/09/post-data-to-cosmcom-with-wiseclock4.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/1440926889271658167?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/1440926889271658167?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/UYwO_u-HGp4/post-data-to-cosmcom-with-wiseclock4.html" title="Post data to cosm.com with WiseClock4 + WiFly" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>2</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/09/post-data-to-cosmcom-with-wiseclock4.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CEEDQXw8fip7ImA9WhJWGUQ.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-2118478921158643921</id><published>2012-08-26T10:47:00.000-04:00</published><updated>2012-08-26T10:51:10.276-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-08-26T10:51:10.276-04:00</app:edited><title>From customer email</title><content type="html">&lt;br /&gt;
&lt;div class="MsoNormal"&gt;
&lt;i&gt;&lt;span style="color: #1f497d; font-family: Calibri, sans-serif; font-size: 11pt;"&gt;Just 
wanted to let you know I finished putting together my Wise Clock 4 and it looks 
and works great!&amp;nbsp; Only took me about 6 months to get started it &lt;/span&gt;&lt;span style="color: #1f497d; font-family: Wingdings; font-size: 11pt;"&gt;J&lt;/span&gt;&lt;span style="color: #1f497d; font-family: Calibri, sans-serif; font-size: 11pt;"&gt;.&amp;nbsp; 
Thanks for putting together such a nice kit.&amp;nbsp; I didn’t install an xbee on it yet 
but hope to experiment with that sometime this year.&amp;nbsp; &amp;nbsp;I really like all the 
different modes – and have to read up on what they all do.&amp;nbsp; Is there a good link 
you can point me to that describes them?&amp;nbsp; Hope you are still working on new 
clock ideas.&amp;nbsp; Think I saw your name as a supporter of the word clock out on 
kickstarter?&lt;/span&gt;&lt;/i&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;span style="color: #1f497d; font-family: 'Calibri','sans-serif'; font-size: 11pt;"&gt;&lt;i&gt;Bill&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;span style="color: #1f497d; font-family: 'Calibri','sans-serif'; font-size: 11pt;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;span style="font-family: 'Calibri','sans-serif'; font-size: 11pt;"&gt;On the 3216 LED display from Sure Electronics:&lt;/span&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;i&gt;I did look at the clocking relationships on the scope.&lt;br /&gt;The clock to data hold 
timing on the HC164 was marginal, 2ns, versus -2ns typical and 4ns 
minimum.&amp;nbsp;Meaning it will probably work, but it's not certain.&amp;nbsp;CLK, DATA 
and WR are buffered through 2 sections of an HC04, with a delay of 11ns,&amp;nbsp;but 
CS_OUT is not, so with every successive board in a chain this timing 
degrades.&amp;nbsp;They ran out of HC04 gates.&amp;nbsp;Installing the 10pf capacitor at C1 
might help, but it's not ideal.&lt;/i&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;i&gt;Don&lt;/i&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://3.bp.blogspot.com/-JFREY5D2H-0/UDo2N74xUNI/AAAAAAAAA-k/F5cVQP4xDNg/s1600/Clock_2display1.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="http://3.bp.blogspot.com/-JFREY5D2H-0/UDo2N74xUNI/AAAAAAAAA-k/F5cVQP4xDNg/s1600/Clock_2display1.jpg" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://4.bp.blogspot.com/-KKvONpJBDXE/UDo2OdcoU3I/AAAAAAAAA-s/_5j3NjpROME/s1600/Clock_2display2.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="http://4.bp.blogspot.com/-KKvONpJBDXE/UDo2OdcoU3I/AAAAAAAAA-s/_5j3NjpROME/s1600/Clock_2display2.jpg" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class="MsoNormal"&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;i&gt;The zip file did the trick. I now have them both up and running.&amp;nbsp;&lt;/i&gt;&lt;/div&gt;
&lt;div&gt;
&lt;i&gt;I've attached a pic for your viewing.&lt;/i&gt;&lt;/div&gt;
&lt;div&gt;
&lt;i&gt;Brian&lt;/i&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://3.bp.blogspot.com/-Z6xXK2wg6oE/UDo2al6qblI/AAAAAAAAA-0/5tpQyhnBdb0/s1600/2clocks.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="239" src="http://3.bp.blogspot.com/-Z6xXK2wg6oE/UDo2al6qblI/AAAAAAAAA-0/5tpQyhnBdb0/s320/2clocks.jpg" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/div&gt;
&lt;div&gt;
&lt;i&gt;Just wanted to let you know that I received my kit yesterday and have already put it together. &amp;nbsp;I was surprised, having not done any soldering in a long time, that it went together easily and worked on the first try!&lt;/i&gt;&lt;/div&gt;
&lt;div&gt;
&lt;i&gt;Michael&lt;/i&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Big Thank YOU guys!&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;br /&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/IqZsWqCI80A" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/2118478921158643921/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/08/from-customer-email.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/2118478921158643921?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/2118478921158643921?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/IqZsWqCI80A/from-customer-email.html" title="From customer email" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/-JFREY5D2H-0/UDo2N74xUNI/AAAAAAAAA-k/F5cVQP4xDNg/s72-c/Clock_2display1.jpg" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/08/from-customer-email.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A0UFQnc-eCp7ImA9WhJXFUQ.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-3238567557772402853</id><published>2012-08-09T22:00:00.002-04:00</published><updated>2012-08-10T07:46:53.950-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-08-10T07:46:53.950-04:00</app:edited><title>Wise Clock 4 - Status update</title><content type="html">It's been a slow (and hot, temperature-wise) summer, spent mostly answering customer (and other arduino fellows asking for help) emails, with almost no notable achievements.&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;Improved the design of the &lt;b&gt;Wise Clock 4&lt;/b&gt; board by adding support for the &lt;a href="http://www.dealextreme.com/p/bluetooth-board-module-4-pin-121326?item=3"&gt;JY-MCU bluetooth module&lt;/a&gt;&amp;nbsp;(didn't receive the boards yet).&lt;/li&gt;
&lt;li&gt;Created the software framework for a Scheduler (subject of a future post); this should support features like multiple alarms, job activation at given times etc.&lt;/li&gt;
&lt;li&gt;Beside his great contribution to the code, MikeM found a fix for the &lt;a href="http://arduino.cc/hu/Reference/SoftwareSerial"&gt;SoftwareSerial&lt;/a&gt; bug on ATmega1284P (D20 and D21 did not work because JTAG is enabled); he also sent this photo of his stack of &lt;b&gt;Wise Clock 4s&lt;/b&gt; with dual 5mm LED displays.&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://2.bp.blogspot.com/-4namTCDdDMM/UCRpNJjbAyI/AAAAAAAAA-A/JGsaWHKeZ1g/s1600/Mike_5clocks.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://2.bp.blogspot.com/-4namTCDdDMM/UCRpNJjbAyI/AAAAAAAAA-A/JGsaWHKeZ1g/s320/Mike_5clocks.jpg" width="240" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Added to my to-do list:&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;Android app to remote-control &lt;b&gt;Wise Clock 4;&lt;/b&gt;&lt;/li&gt;
&lt;li&gt;remote sensors to start and stop the chronometer function of the clock (request from Javier);&lt;/li&gt;
&lt;li&gt;join a WiFi network in a user-friendly, easy-to-configure, manner;&lt;/li&gt;
&lt;li&gt;automatic adjustment of the display brightness with an LDR, as suggested by Adam, who already hacked his &lt;b&gt;Wise Clock 4&lt;/b&gt;, as shown below.&lt;/li&gt;
&lt;/ul&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://4.bp.blogspot.com/-VhJ3OHkrtTM/UCRnT1D-sQI/AAAAAAAAA94/sFREw0sZqMA/s1600/backOfCase.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://4.bp.blogspot.com/-VhJ3OHkrtTM/UCRnT1D-sQI/AAAAAAAAA94/sFREw0sZqMA/s320/backOfCase.jpg" width="240" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
I also got a bit angry with Sure Electronics for the (mechanical) change on their latest revision of the 3216 LED display: the vertical distance between the holes is about 3mm greater. I thought I would have to give away the small stock of laser-cut plates I had, since they would not fit anymore. Turns out that there is a non-wasteful solution though: enlarge the holes with a small file (which I do myself to all displays, until I finish the old stock of plexiglass plates).&lt;br /&gt;
&lt;br /&gt;
As always, any comments, suggestions and contributions are appreciated.&lt;br /&gt;
&lt;br /&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/embAiIQVxLA" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/3238567557772402853/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/08/status-update.html#comment-form" title="18 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/3238567557772402853?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/3238567557772402853?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/embAiIQVxLA/status-update.html" title="Wise Clock 4 - Status update" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-4namTCDdDMM/UCRpNJjbAyI/AAAAAAAAA-A/JGsaWHKeZ1g/s72-c/Mike_5clocks.jpg" height="72" width="72" /><thr:total>18</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/08/status-update.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkAESHYyeip7ImA9WhJUEUw.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-3912490131347393007</id><published>2012-07-07T10:03:00.003-04:00</published><updated>2012-09-08T09:25:09.892-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-09-08T09:25:09.892-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="tips and tricks" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Wise Clock 4 with the 5mm 3216 LED display</title><content type="html">The &lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2011/11/wise-clock-4.html"&gt;Wise Clock 4&lt;/a&gt;&lt;/b&gt; board was designed to be plugged directly into the &lt;a href="https://docs.google.com/file/d/0B01cjIbSk11NOGNlNTBjYWQtNzFhYi00YTA0LWIzZmMtYmFiOTVhYjM2ZTAy/edit"&gt;3mm 32x16 LED display&lt;/a&gt; from Sure Electronics. I am often asked how it would connect to the 5mm 32x16 LED display.&lt;br /&gt;
The photos below will give the answer to this question.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://4.bp.blogspot.com/-LwQFvFy9q-w/T_g6VjAsr8I/AAAAAAAAA9c/evx9uRHwEN8/s1600/WC4_header5mm.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://4.bp.blogspot.com/-LwQFvFy9q-w/T_g6VjAsr8I/AAAAAAAAA9c/evx9uRHwEN8/s320/WC4_header5mm.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First, the 2x8-pin female header&amp;nbsp;&lt;span style="background-color: white;"&gt;provided&lt;/span&gt;&lt;span style="background-color: white;"&gt;&amp;nbsp;with the kit&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: white;"&gt;needs to be replaced with a 2x8-pin&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: white;"&gt;male header&lt;/span&gt;&lt;span style="background-color: white;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: white;"&gt;(or two 8-pin male headers side-by-side). Place the header on the top side, as shown in the picture above.&lt;/span&gt;&lt;br /&gt;
&lt;span style="background-color: white;"&gt;Ideally, a "shrouded 2x8-pin header" (like &lt;a href="http://www.pololu.com/catalog/product/898"&gt;this&lt;/a&gt;) should be used here, since that will also force the ribbon cable connector to be inserted with the right orientation (notice that the peg is closer the FTDI connector).&lt;/span&gt;&lt;br /&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="background-color: white;"&gt;Then connect the board to the display using the ribbon cable (coming with the display), as shown in the next photo, and &lt;b&gt;very importantly&lt;/b&gt;, paying attention to the orientation of the connector.&lt;/span&gt;&lt;br /&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://4.bp.blogspot.com/-vfUk0bU2xq4/T_g8qkSj11I/AAAAAAAAA9o/Zpih4Et-U1A/s1600/WC4_to5mm.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://4.bp.blogspot.com/-vfUk0bU2xq4/T_g8qkSj11I/AAAAAAAAA9o/Zpih4Et-U1A/s320/WC4_to5mm.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;br /&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style="background-color: white;"&gt;In case you wanted to chain a second display, just connect, with a second ribbon cable, the OUT connector of the first with the IN connector of the second.&lt;/span&gt;&lt;br /&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;
The &lt;b&gt;Wise Clock 4&lt;/b&gt; software is able to correctly handle the second display if you modify this line in file HT1632.h, from&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;#define NUM_DISPLAYS&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;1&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
to&lt;/div&gt;
&lt;div&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;#define NUM_DISPLAYS&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;2&lt;/span&gt;&lt;/div&gt;
&lt;br /&gt;
When fully lit, the current consumption of the displays are around 500mA. The best way to power them, especially when chained, would be through the terminal block, with the the red and black wires (as shown). In this case, the &lt;b&gt;Wise Clock 4&lt;/b&gt; board is powered from the display (through the ribbon cable), so you don't need to use an USB cable.&lt;br /&gt;
&lt;br /&gt;
The easier alternative is to use the USB cable. This will provide power to the display(s) as well, but the voltage to the second display may drop below 5V, thus making it less bright, or even behaving erratically. Also, keep in mind that the USB port on a PC may not be able to supply the current for two displays (1A or so). If you notice problems with the second display, first step is to check the voltage to be around 5V.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;NOTE: Make sure you use a 5V regulated power source. Anything above 6V will fry the board, and probably the display too. Also, make sure your power source is adequate for the power consumption. Use at least a 2A (10W) power source.&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/nQLaqbi7GxY" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/3912490131347393007/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/07/wise-clock-4-with-5mm-display.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/3912490131347393007?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/3912490131347393007?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/nQLaqbi7GxY/wise-clock-4-with-5mm-display.html" title="Wise Clock 4 with the 5mm 3216 LED display" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://4.bp.blogspot.com/-LwQFvFy9q-w/T_g6VjAsr8I/AAAAAAAAA9c/evx9uRHwEN8/s72-c/WC4_header5mm.JPG" height="72" width="72" /><thr:total>2</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/07/wise-clock-4-with-5mm-display.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0QNQ345eip7ImA9WhJREkw.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-682679305088713787</id><published>2012-06-29T17:56:00.000-04:00</published><updated>2012-07-13T16:29:52.022-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-07-13T16:29:52.022-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="software" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Animation on Wise Clock 3/4</title><content type="html">Mr Ruud did it again :) &amp;nbsp;He took this video showing a few more features he added.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;object class="BLOGGER-youtube-video" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" data-thumbnail-src="http://i.ytimg.com/vi/ZOHyuxAqdLU/0.jpg" height="266" width="320"&gt;&lt;param name="movie" value="http://www.youtube.com/v/ZOHyuxAqdLU?version=3&amp;f=user_uploads&amp;c=google-webdrive-0&amp;app=youtube_gdata" /&gt;


&lt;param name="bgcolor" value="#FFFFFF" /&gt;


&lt;param name="allowFullScreen" value="true" /&gt;


&lt;embed width="320" height="266"  src="http://www.youtube.com/v/ZOHyuxAqdLU?version=3&amp;f=user_uploads&amp;c=google-webdrive-0&amp;app=youtube_gdata" type="application/x-shockwave-flash" allowfullscreen="true"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;/div&gt;
&lt;span style="background-color: white;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;b&gt;1. ANIMATIONS&lt;/b&gt;&lt;br /&gt;
&lt;div&gt;
&lt;div&gt;
It is now possible to create your own animations which are stored on the SD card.&lt;/div&gt;
&lt;div&gt;
The APPS menu entry ANIM allows for continously showing one or all animations files.&lt;/div&gt;
&lt;div&gt;
Animation files are named: &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;anim0.wc3&lt;/span&gt; - &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;anim9.wc3&lt;/span&gt;.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
There are also 4 special animation files named: &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;time00.wc3&lt;/span&gt;, &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;time15.wc3&lt;/span&gt;, &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;time30.wc3&lt;/span&gt; and &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;time45.wc3&lt;/span&gt;.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
If ANIM+ is selected in the SETUP menu and the BIG mode is active then every quarter the correponding animation is&amp;nbsp;&lt;span style="background-color: white;"&gt;shown once with a random speed.&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
Besides the four &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;time*.wc3&lt;/span&gt; animation file, there are currently 4 sample animations: &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;anim1.wc3&lt;/span&gt; - &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;anim4.wc3&lt;/span&gt;.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
You may create your own animations (there is NO programming involved) by creating individual screens in Excel and&amp;nbsp;&lt;span style="background-color: white;"&gt;then use a small conversion program to create the &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;*.wc3&lt;/span&gt; file.&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
As the animations are stored on the SD card you can make them as big as you like.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;b&gt;2. LOGGING&lt;/b&gt;&lt;/div&gt;
&lt;div&gt;
If the LOG+ menu is selected in the SETUP menu then the following items will be logged in the &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;wc3log.csv&lt;/span&gt; file:&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;span style="background-color: white;"&gt;every hour the current temperature is logged both in Celsius and Fahrenheit (32.5 degrees is stored as 325)&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;span style="background-color: white;"&gt;all entries created in the time clock (TCLOK) app are now stored in the log file&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
The &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;wc3log.csv&lt;/span&gt; file is an ASCII Comma Separated Values file, which can be opened in Excel for further analysis (&lt;span style="background-color: white;"&gt;or for creating graphs etc).&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
The average log record is about 25 bytes long. The temperature logging will take 24 x 25 bytes = &amp;nbsp;600 per day.&amp;nbsp;&lt;span style="background-color: white;"&gt;(So the 2 Megabyte log file will be full after about 9 years.)&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
A warning message ("log= @ End") will be shown when the log file is almost full, an error message ("log= FULL!") will&amp;nbsp;&lt;span style="background-color: white;"&gt;appear if no more records can be written to the log file.&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
The SETUP menu entry CLRLG allows for clearing the complete log file, it will take about 10 minutes to clear a&amp;nbsp;&lt;span style="background-color: white;"&gt;2 megabyte log file.&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Mike M. integrated all of the above changes with a previous version that works with FAT32. This code is available &lt;a href="http://code.google.com/p/wiseclock2/downloads/detail?name=WiseClock_120707.zip&amp;amp;can=2&amp;amp;q=#makechanges"&gt;here&lt;/a&gt;.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/kixLjo1WjF0" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/682679305088713787/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/06/animation-on-wise-clock-34.html#comment-form" title="6 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/682679305088713787?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/682679305088713787?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/kixLjo1WjF0/animation-on-wise-clock-34.html" title="Animation on Wise Clock 3/4" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>6</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/06/animation-on-wise-clock-34.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A0MGR3s-cSp7ImA9WhNQE0o.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-7834217773961747101</id><published>2012-06-01T18:23:00.001-04:00</published><updated>2012-11-19T21:43:46.559-05:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-11-19T21:43:46.559-05:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="bluetooth" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Wise Clock 4 with integrated Bluetooth</title><content type="html">&lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2011/11/wise-clock-4.html"&gt;Wise Clock 4&lt;/a&gt;&lt;/b&gt;&amp;nbsp;can now hold&amp;nbsp;a &lt;a href="http://www.dealextreme.com/p/wireless-bluetooth-rs232-ttl-transceiver-module-80711"&gt;Bluetooth module&lt;/a&gt; outside of the XBee socket, as shown in the pictures below.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://2.bp.blogspot.com/-TViQPlFyb6Y/T8k29nEsvvI/AAAAAAAAA8Q/CqJuvoiIyys/s1600/BT_back.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://2.bp.blogspot.com/-TViQPlFyb6Y/T8k29nEsvvI/AAAAAAAAA8Q/CqJuvoiIyys/s320/BT_back.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://2.bp.blogspot.com/-ViWaFuVejkk/T8k437xeAbI/AAAAAAAAA8Y/yw1Y2ghuQRk/s1600/BT_top.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://2.bp.blogspot.com/-ViWaFuVejkk/T8k437xeAbI/AAAAAAAAA8Y/yw1Y2ghuQRk/s320/BT_top.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The communication with the BT module uses SoftwareSerial on pins D20/PC4 (Tx) and D21/PC5 (Rx).&lt;br /&gt;
The module is powered with 3V3 and the Rx line is level-shifted.&lt;br /&gt;
&lt;br /&gt;
I bought a few of these Bluetooth modules from different sources, mostly ebay. Some of them did not work: my PC's Bluetooth could not "discover" them. Once SMD-soldered to the board, it is very difficult to figure out what's wrong and even de-solder and remove them. &lt;b&gt;My advice for anyone using these modules is to check them before soldering them to any board/breakout&lt;/b&gt;.&amp;nbsp;An&amp;nbsp;easy way to do this is to solder wires on pins 12 (Vcc) and pin 13 (ground), as shown in the photo below (left), power with 3.3V, then try to pair it with a Bluetooth host (PC, Android; iPhone won't work since it requires an Apple-approved chip).&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://3.bp.blogspot.com/-DhNYx-JHco4/T8k_KTrjJfI/AAAAAAAAA8k/LEW38icMEWU/s1600/BT_modules.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://3.bp.blogspot.com/-DhNYx-JHco4/T8k_KTrjJfI/AAAAAAAAA8k/LEW38icMEWU/s320/BT_modules.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The module's relevant pins are shown in the diagram below (photo from ebay seller):&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://2.bp.blogspot.com/-g1tq8CTT4uQ/UKrt04BWSLI/AAAAAAAAA_w/Ah1GeJtvIRc/s1600/BTmodule.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="174" src="http://2.bp.blogspot.com/-g1tq8CTT4uQ/UKrt04BWSLI/AAAAAAAAA_w/Ah1GeJtvIRc/s320/BTmodule.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
I did not test this myself (the experiment may cost about $7), but it&amp;nbsp;seems that these Bluetooth modules only tolerate approx 3.3V and powering with 5V will fry them.&lt;br /&gt;
&lt;br /&gt;
If you already have an &lt;b&gt;Wise Clock 3/4&lt;/b&gt; and want to add Bluetooth functionality (simultaneous to WiFi or XBee), you can add &lt;a href="http://www.dealextreme.com/p/jy-mcu-arduino-bluetooth-wireless-serial-port-module-104299?item=12"&gt;this module&lt;/a&gt; to the clock. Connections are through 4 wires: Rx/Tx go to D20/D21 (pins 26 and 27 of the processor), VCC to 5V, GND to ground. Note that this module has on-board power adapter for 3.3V and level-shifter for the logic lines.&lt;br /&gt;
&lt;br /&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/amM3E21inTc" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/7834217773961747101/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/06/wise-clock-4-with-integrated-bluetooth.html#comment-form" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/7834217773961747101?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/7834217773961747101?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/amM3E21inTc/wise-clock-4-with-integrated-bluetooth.html" title="Wise Clock 4 with integrated Bluetooth" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-TViQPlFyb6Y/T8k29nEsvvI/AAAAAAAAA8Q/CqJuvoiIyys/s72-c/BT_back.JPG" height="72" width="72" /><thr:total>1</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/06/wise-clock-4-with-integrated-bluetooth.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D0ADRXwzcSp7ImA9WhVbFkk.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-7494577152475729749</id><published>2012-05-30T11:18:00.001-04:00</published><updated>2012-06-02T10:02:54.289-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-06-02T10:02:54.289-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="DWex" /><category scheme="http://www.blogger.com/atom/ns#" term="software" /><title>DWex mod</title><content type="html">From Gerard:&lt;br /&gt;
&lt;br /&gt;
&lt;i&gt;Hi Florin,&lt;br /&gt;I had some spare time and moved on with the software mods on 
the &lt;a href="http://timewitharduino.blogspot.ca/2010/06/introducing-arduino-analog-watch.html"&gt;&lt;b&gt;DWex&lt;/b&gt;&lt;/a&gt;. &lt;br /&gt;The mods are:&lt;br /&gt;- display is always on (means 
you need to power by NiMH or wall supply)&lt;br /&gt;- small animation after reset (test 
all the LED's)&lt;br /&gt;- small animation at full 5' (solid) minutes&lt;br /&gt;Feel free 
to distribute/publish the mods if you feel appropriate.&lt;br /&gt;Best 
Regards&lt;br /&gt;gerard, DL8SEL&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
The sketch is available for download &lt;a href="http://code.google.com/p/wiseclock2/downloads/detail?name=DWex_1.pde&amp;amp;can=2&amp;amp;q="&gt;here&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
Thank you Gerard. Keep up the great work!&lt;br /&gt;
&lt;br /&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/5moZ9BXUnmk" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/7494577152475729749/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/05/dwex-mod.html#comment-form" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/7494577152475729749?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/7494577152475729749?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/5moZ9BXUnmk/dwex-mod.html" title="DWex mod" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>1</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/05/dwex-mod.html</feedburner:origLink></entry><entry gd:etag="W/&quot;Dk4BRnY8cSp7ImA9WhVWGE4.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-6301733299413748984</id><published>2012-04-19T18:55:00.002-04:00</published><updated>2012-04-30T21:15:57.879-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-04-30T21:15:57.879-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="bluetooth" /><category scheme="http://www.blogger.com/atom/ns#" term="serial communication" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><category scheme="http://www.blogger.com/atom/ns#" term="hacking" /><title>Wise Clock 4 with remote "Alarm stop" button</title><content type="html">The &lt;a href="http://www.kickstarter.com/projects/search?utf8=&amp;amp;term=ramos"&gt;Ramos project&lt;/a&gt; brought the novel idea of a wireless alarm-stop button: instead of just reaching out to &amp;nbsp;press on the top of your nightstand alarm clock, you now have to actually get out of the bed and walk to a remote corner of your dwelling to click on a&amp;nbsp;keypad. No chance you will return to sleep afterward :)&lt;br /&gt;
&lt;br /&gt;
This remote alarm-stop feature for&amp;nbsp;&lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2011/12/buy-complete-wise-clock-4-kit-includes.html"&gt;Wise Clock 4&lt;/a&gt;&amp;nbsp;&lt;/b&gt;can be implemented in several different ways, all of them using of the on-board XBee socket:&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;through a Bluetooth module;&lt;/li&gt;
&lt;li&gt;through WiFi, using the Roving Networks WiFly module;&lt;/li&gt;
&lt;li&gt;through XBee radios.&lt;/li&gt;
&lt;/ul&gt;
&lt;div&gt;
The cheapest and easiest would be the Bluetooth solution, providing that you already have a BT device (e.g. Android phone/tablet) to communicate with. In pseudo-code, it should look like this:&lt;br /&gt;
&lt;br /&gt;
if (alarm is ON)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; &amp;nbsp; while (Serial1.available())&lt;br /&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; {&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;read characters received;&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;if (it is the expected string)&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;{&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; set alarm OFF;&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp; }&lt;/div&gt;
&lt;div&gt;
}&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
The WiFi solution would require a second WiFi device (phone/tablet) to access a web site, or maybe they could talk directly (sockets), using their IP addresses.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
The solution based on XBee relies on direct communication between two XBee radios. One would have to build the remote device, probably around an Arduino, with a keypad and an XBee.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/LbNZVyFoAwo" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/6301733299413748984/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/04/wise-clock-4-with-remote-alarm-stop.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/6301733299413748984?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/6301733299413748984?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/LbNZVyFoAwo/wise-clock-4-with-remote-alarm-stop.html" title="Wise Clock 4 with remote &quot;Alarm stop&quot; button" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>2</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/04/wise-clock-4-with-remote-alarm-stop.html</feedburner:origLink></entry><entry gd:etag="W/&quot;Ak8GSXs8fSp7ImA9WhVXGUs.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-1852924080218925674</id><published>2012-04-19T17:36:00.004-04:00</published><updated>2012-04-20T20:40:28.575-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-04-20T20:40:28.575-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="software" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Guest post: Wise Clock 3/4 Apr-2012 software release</title><content type="html">&lt;span style="color: red;"&gt;Updated Apr 20/2012&lt;/span&gt;&lt;br /&gt;
David M. mentioned an important detail: if you try to compile with Arduino 1.0 on Mac OSX &amp;nbsp;you will get the error "You can't have a cpp file with the same name as the sketch". The quick fix is to change the name of the file&amp;nbsp;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;WiseClock4.ino&lt;/span&gt;&amp;nbsp;(to&amp;nbsp;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;TheClock.ino&lt;/span&gt;, for example). Interestingly, although it makes sense, this error does not show in Windows.&lt;br /&gt;
-------------------------------------------------------------------&lt;br /&gt;
&lt;br class="Apple-interchange-newline" /&gt;Here is the email I received from Mike, who took on the challenge to fix and improve the code for &lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2009/07/shoppe.html"&gt;Wise Clock 3/4&lt;/a&gt;&lt;/b&gt;, available &lt;a href="http://code.google.com/p/wiseclock2/downloads/detail?name=WiseClock_Apr2012.zip&amp;amp;can=2&amp;amp;q="&gt;here&lt;/a&gt;. Thanks Mike, keep up the great work!&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;My note: If you don't feel very confident about upgrading the software on Wise Clock 3/4, please do not do it.&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;i&gt;I combined WiseClock3/WiseClock4 into one distribution, creating a  WiseClockVer.h file with a&lt;br /&gt;
&amp;nbsp;&amp;nbsp; #define _WISE_CLOCK_VER 3&lt;br /&gt;
line.&amp;nbsp; HT1632.cpp  and Buttons.h include WiseClockVer.h, and use lines like&lt;br /&gt;
&amp;nbsp; #if  _WISE_CLOCK_VER &amp;gt; 3&lt;br /&gt;
&amp;nbsp; #define HT1632_CLK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 15&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // clock pin (pin 2  of display connector)&lt;br /&gt;
&amp;nbsp; #else&lt;br /&gt;
&amp;nbsp; #define HT1632_CLK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 11&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // clock  pin (pin 2 of display connector)&lt;br /&gt;
&amp;nbsp; #endif&lt;br /&gt;
That way the same distribution  can be used for Wise Clock 3 or Wise Clock 4, and only one line has to be  changed.&lt;br /&gt;
&lt;br /&gt;
I found some places where over 100 bytes of data are copied into  msgLine, overflowing the buffer.&amp;nbsp; Rather than just increasing the size of  QUO_MSG_LEN, I changed all references to QUO_MSG_LEN to use MAX_MSG_LEN  instead.&lt;br /&gt;
&lt;br /&gt;
When reading a quote line a prefix character of Control-R (^R)  will display the quote in red.&amp;nbsp; A prefix character of Control-O (^O) will  display the quote in orange.&lt;br /&gt;
&lt;br /&gt;
I removed all floating-point operations in  favor of scaled integers.&amp;nbsp; For AppPong I scaled by 256, for temperature I scaled  by 4 as the DS3231 is only accurate to 0.25 degrees.&amp;nbsp; I found that when the high  and low temperatures were scaled by 10 and displaying farenheit that today's  high could be 0.1 degree lower than the current temperature due to round-off  errors.&amp;nbsp; These errors are avoided by saving the temperature scaled by 4 instead  of 10.&lt;br /&gt;
&lt;br /&gt;
I added a DST flag to indicate Daylight Savings Time is in  affect.&amp;nbsp; DST+ sets the flag and advances the hour by one, DST- clears the flag  and retards the hour by one.&amp;nbsp; The DST settings in the message file are still  honored, setting the flag and incrementing the hour (if the DST flag is clear)  or clearing the flag and decrementing the hour (if the DST flag is set) at the  appropriate time.&lt;br /&gt;
The DST flag is used in the UTC code so the UTC offset is  set once.&amp;nbsp; There is no need to change the UTC offset when Daylight Savings Time  starts or ends.&lt;br /&gt;
&lt;br /&gt;
I changed the sign of the UTC offset, so '-5' is now  correct for Eastern Standard Time.&amp;nbsp; UTC + offset = current time.&lt;br /&gt;
Negative UTC  offsets could not be restored properly, as -5 when retrieved would come back  unsigned as 250.&amp;nbsp; I worked around the problem by adding 24 when saving to EEPROM  and subtracting 24 when reading the EEPROM.&lt;br /&gt;
&lt;br /&gt;
I changed the resolution of  AppTimeLived's makeTime() from seconds to minutes.&amp;nbsp; The displayed seconds are  calculated by taking the delta of the current second specified birth second, so  makeTime() does not need the extra accuracy.&amp;nbsp; This change allows the offset to  be calculated from 1900 instead of 1950.&amp;nbsp; With a second resolution and base of  1950 makeTime() would wrap in 2018.&amp;nbsp; With a minute resolution and a base of 1900  makeTime() won't wrap for another ~4000 years.&lt;br /&gt;
&lt;br /&gt;
I changed the DEMO mode so  it cycles through several display modes.&amp;nbsp; The number of minutes to display each  mode is selected on the first screen after DEMO is selected, going from 0  minutes to 9 minutes.&amp;nbsp; Ten seconds is added to the cycle time, so selecting "0"  goes to a new display every ten seconds.&lt;br /&gt;
The original lines Demo is only  displayed for ten seconds, regardless of the selected cycle time.&amp;nbsp; The LIFE demo  is displayed for fifteen seconds.&lt;br /&gt;
I was going to have AppWords as one of the  demos, but I'd have to in-line most of AppWords' initialization code in the demo  code, so I didn't bother.&lt;br /&gt;
&lt;br /&gt;
I changed AppLife so it now wraps over the  edges of the display.&lt;br /&gt;
&lt;br /&gt;
I went through AppPong so all display offsets are  relative to X_MAX and Y_MAX. As mentioned earlier, floating point math was  replaced by scaled integers.&amp;nbsp; The height of the bat is now a #define and set to  5 instead of the previous version's hard-coded 6.&amp;nbsp; I settled on a color scheme  -- ball and pitch are green, score is red, bats are orange.&amp;nbsp; I fixed some bugs  in the ball prediction code and the 'flip' code (used to put 'english' on the  ball).&amp;nbsp; I changed the 'miss' code to only miss by a few pixels.&lt;br /&gt;
&lt;/i&gt;&lt;br /&gt;
&lt;i&gt;The removal of the floating point freed up a lot of space.&lt;br /&gt;
It's [the whole sketch] less than 58K  bytes.&lt;br /&gt;
&lt;br /&gt;
I'm running the clock now.&amp;nbsp; The only issue is the year's high  temperature needs to be re-initialized.&amp;nbsp; It was scaled by 10, now we expect it  to be scaled by 4.&amp;nbsp; The nightly comparison won't save a new high temperature  because the old one now is 2.5 times higher than it should be.&amp;nbsp; New clocks won't  have the problem, but upgrading an existing one will.&amp;nbsp; The yearly low  temperature isn't a problem because the scaled-by-four temp will be lower than  the scaled-by-ten temp (unless your low is less than 0 C).&amp;nbsp; The work-around is  easy, just set the year back by one overnight.&amp;nbsp; In the morning the yearly  high/low temp will be reset.&amp;nbsp; The yearly high/low is only displayed in the  "STATS" app anyway.&lt;/i&gt;&lt;br /&gt;
&lt;i&gt;&lt;br /&gt;
&lt;/i&gt;&lt;br /&gt;
&lt;i&gt;I corrected the life neighbor calculations.&amp;nbsp; The neighbor calculation used to  be the sum of the colors for the eight neighbors.&amp;nbsp; This works when only green  (1) is used, but when the colors are randomized the neighbor calculations are  wrong, as some neighbors could be red (2) or orange (3).&amp;nbsp; I changed the color  selection&amp;nbsp;to use green for birth, orange for steady-state, red for dead.&amp;nbsp; The  neighbor calculation now looks at the least significant bit of the color.&amp;nbsp; Green  and Orange both have the lsb set, so this works well.&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;i&gt;A quote-line can now be any length.&amp;nbsp; The quote buffer is replenished when  processing is within 24 characters from the end of the buffer and the line was  truncated.&amp;nbsp; Additional characters are tacked on to the end of the remaining 24,  with no interruption.&amp;nbsp; This will repeat until the entire line has been  processed, no matter how long the line is.&amp;nbsp; Reminders and Messages are still  limited to 100 characters, and the lines in the Words files&amp;nbsp;are still limited to  175 characters.&lt;/i&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/eoapVqlWekk" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/1852924080218925674/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/04/guest-post-wise-clock-34-apr-2012.html#comment-form" title="5 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/1852924080218925674?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/1852924080218925674?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/eoapVqlWekk/guest-post-wise-clock-34-apr-2012.html" title="Guest post: Wise Clock 3/4 Apr-2012 software release" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>5</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/04/guest-post-wise-clock-34-apr-2012.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DE4EQ306cSp7ImA9WhVQGEQ.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-5444895748303164475</id><published>2012-04-08T10:41:00.004-04:00</published><updated>2012-04-08T10:55:02.319-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-04-08T10:55:02.319-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="bluetooth" /><category scheme="http://www.blogger.com/atom/ns#" term="software" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Scrolling message sign with Bluetooth</title><content type="html">A simple application for Bluetooth was suggested a while back by fellow arduinoer evanrich (who also created a home for &lt;a href="https://github.com/evanrich/Bluetooth-LED-Sign"&gt;his project on github&lt;/a&gt;): a scrolling sign using several cascaded 3216 displays and controlled through Bluetooth from an Android phone. His intention was to use it as a wireless sign that can be put in the back of the car to tell drivers to get off his tail.&lt;br /&gt;
&lt;br /&gt;
I gave it a try myself, using &lt;a href="http://timewitharduino.blogspot.ca/2012/04/wise-clock-4-with-bluetooth.html"&gt;&lt;b&gt;Wise Clock 4&lt;/b&gt; with Bluetooth&lt;/a&gt; and two 3216 displays, as shown in this photo (the blue LED on the BTBee is power, the orange one is communication status).&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/-LNd2gIm9ML8/T4Glpx9IfTI/AAAAAAAAA8A/LTPD76skBBs/s1600/BlueSign.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="300" src="http://1.bp.blogspot.com/-LNd2gIm9ML8/T4Glpx9IfTI/AAAAAAAAA8A/LTPD76skBBs/s400/BlueSign.JPG" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &lt;a href="http://code.google.com/p/wiseclock2/downloads/detail?name=BlueSign.pde&amp;amp;can=2&amp;amp;q="&gt;code&lt;/a&gt; is a modified version of the one &lt;a href="http://timewitharduino.blogspot.ca/2012/01/scrolling-message-sign-display-with.html"&gt;posted here&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
This message sign, especially if it is made with the larger (5mm) 3216 displays, can be also used in waiting rooms, call centers, stores etc, to show dynamic and easily-changeable messages.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Related posts:&lt;br /&gt;
&lt;ul&gt;&lt;li&gt;&lt;a href="http://timewitharduino.blogspot.ca/2011/04/scrolling-message-sign-display-with.html"&gt;Scrolling message sign display with &lt;b&gt;Wise Clock 3/4&lt;/b&gt;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://timewitharduino.blogspot.ca/2012/01/scrolling-message-sign-display-with.html"&gt;Scrolling large-font message sign display with &lt;b&gt;Wise Clock 3/4&lt;/b&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/V8eKgJzepFs" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/5444895748303164475/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/04/scrolling-message-sign-with-bluetooth.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/5444895748303164475?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/5444895748303164475?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/V8eKgJzepFs/scrolling-message-sign-with-bluetooth.html" title="Scrolling message sign with Bluetooth" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/-LNd2gIm9ML8/T4Glpx9IfTI/AAAAAAAAA8A/LTPD76skBBs/s72-c/BlueSign.JPG" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/04/scrolling-message-sign-with-bluetooth.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DUYFQn87eip7ImA9WhVQGEQ.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-5403483629691198818</id><published>2012-04-05T23:47:00.010-04:00</published><updated>2012-04-08T10:58:33.102-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-04-08T10:58:33.102-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="bluetooth" /><category scheme="http://www.blogger.com/atom/ns#" term="tips and tricks" /><category scheme="http://www.blogger.com/atom/ns#" term="software" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Wise Clock 4 with Bluetooth</title><content type="html">Another thing that was supposed to be easy, but it wasn't: Arduino communicating with Windows XP through Bluetooth.&lt;br /&gt;
&lt;br /&gt;
Like everybody, I purchased the cheap and&amp;nbsp;ubiquitous &lt;a href="http://www.dealextreme.com/p/wireless-bluetooth-rs232-ttl-transceiver-module-80711"&gt;Bluetooth module&lt;/a&gt; from dealextreme.&lt;br /&gt;
I soldered it myself on the XBee-footprinted PCB (&lt;a href="http://iteadstudio.com/store/index.php?main_page=product_info&amp;amp;cPath=19_21&amp;amp;products_id=395"&gt;bare BTBee&lt;/a&gt; from IteadStudio), for a total price of about $8 (compare that to at least $15 as these Bluetooth XBees go for).&lt;br /&gt;
&lt;br /&gt;
Without knowing much about Bluetooth, I plugged this new "BTBee" module in &lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2011/11/wise-clock-4.html"&gt;Wise Clock 4&lt;/a&gt;&lt;/b&gt; expecting it to be "discovered" by XP (which has an USB Bluetooth dongle).&amp;nbsp;Discovered it was: the name "linvor" appeared in the list of BT devices, with two serial ports attached to it.&lt;br /&gt;
&lt;br /&gt;
Communication between XP and BT module is performed through the serial ports, I figured. Tried CoolTermWin, HyperTerminal, Putty, on both ports, nothing seemed to work. Time to read the documentation (which always reminds me of &lt;a href="http://thinkexist.com/quotation/documentation_is_like_sex-when_it_is_good-it_is/157008.html"&gt;that joke&lt;/a&gt;). I learned that others had &lt;a href="http://arduino.cc/forum/index.php?topic=97971.0"&gt;similar problems&lt;/a&gt;, and &lt;a href="http://arduino.cc/forum/index.php?topic=64338.0"&gt;some have solved&lt;/a&gt; them by installing new BT drivers. The best advice came from &lt;a href="http://jondontdoit.blogspot.ca/2011/11/bluetooth-mate-tutorial.html"&gt;this post&lt;/a&gt;. Putty did not work for me, so I stuck with what I had, namely HyperTerminal.&lt;br /&gt;
&lt;br /&gt;
So here is my own step-by-step tutorial on how to make an Arduino&amp;nbsp;communicate&amp;nbsp;with Windows XP via a Bluetooth module.&lt;br /&gt;
&lt;i&gt;Note: From the Bluetooth perspective, &lt;b&gt;Wise Clock 4&lt;/b&gt; I used for my testing is similar to Arduino.&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
1. Upload this simple sketch that "echos" what it reads from Bluetooth and also broadcasts a message periodically. The communication between Arduino and the BT module is serial, with a baud rate of 9600, according to the documentation.&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;#if ARDUINO &amp;lt; 100&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; #include &lt;wprogram.h&gt;&lt;/wprogram.h&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;#else&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; #include &lt;arduino.h&gt;&lt;/arduino.h&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;#endif&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;void setup()&lt;/span&gt;&lt;/div&gt;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; Serial.begin(9600);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;void loop()&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; while (Serial.available())&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; // get char from bluetooth;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; char inChar = (char) Serial.read();&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; // output it back, between brackets;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; Serial.print('[');&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; Serial.print(inChar);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; Serial.print(']');&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; // broadcast message;&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; Serial.print("millis() from Arduino: ");&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; Serial.println(millis());&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; delay(2000);&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
2. Power Arduino, with the BT module connected, and let it run the sketch.&lt;br /&gt;
&lt;br /&gt;
3. Make the BT module (on the Arduino) visible to XP, by adding it to the list of Bluetooth devices. For this, click on the "Bluetooth Devices" icon in the tray (bottom right corner of the XP's desktop). You will see this box.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/-C58ZVjTMWH0/T35cvHrPM7I/AAAAAAAAA5o/X6mPbahGIAg/s1600/s1.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="250" src="http://1.bp.blogspot.com/-C58ZVjTMWH0/T35cvHrPM7I/AAAAAAAAA5o/X6mPbahGIAg/s320/s1.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, you will see the BT device added to the list, under the name "linvor".&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/-ugIvbezaoQk/T35eqHILNqI/AAAAAAAAA5w/iD9W97dOkTs/s1600/s2.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="250" src="http://1.bp.blogspot.com/-ugIvbezaoQk/T35eqHILNqI/AAAAAAAAA5w/iD9W97dOkTs/s320/s2.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Then select the last option, "Don't use a passkey". Although it makes little sense at this point (since you know that the passkey is 1234, according to the documentation), it is very important to not use a passkey here.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/-I1ZyS14lECM/T35e8RNcZgI/AAAAAAAAA54/Wm8ayifxFe0/s1600/s3.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="250" src="http://4.bp.blogspot.com/-I1ZyS14lECM/T35e8RNcZgI/AAAAAAAAA54/Wm8ayifxFe0/s320/s3.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The last step of the wizard shows the two ports that have been added. Write down the "Outgoing COM port", since this is the one we will be using for communication (step 4).&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-WFoVcYnNxKA/T35ftnzj2pI/AAAAAAAAA6A/6mqsLX3azXI/s1600/s4.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="250" src="http://2.bp.blogspot.com/-WFoVcYnNxKA/T35ftnzj2pI/AAAAAAAAA6A/6mqsLX3azXI/s320/s4.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4. Open HyperTerminal to establish the 2-way communication between XP and Arduino, via Bluetooth.&lt;br /&gt;
Select, from the list, the COM port specified as "outgoing" for the BT device.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/-b_zjqIhdZQo/T35g8pG6hoI/AAAAAAAAA6I/MxqJw_bBLFY/s1600/h1.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="http://4.bp.blogspot.com/-b_zjqIhdZQo/T35g8pG6hoI/AAAAAAAAA6I/MxqJw_bBLFY/s1600/h1.JPG" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, you will be shown this pop-up.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/-SoEwzenfdok/T35iHfvRK7I/AAAAAAAAA6Q/PANgZltRxn4/s1600/h2.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="65" src="http://4.bp.blogspot.com/-SoEwzenfdok/T35iHfvRK7I/AAAAAAAAA6Q/PANgZltRxn4/s320/h2.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you click on it, you are prompted to enter the passkey, the one you (reluctantly) skipped in the process of setting up the BT device. Type "1234", as specified in the BT module documentation.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://3.bp.blogspot.com/-V8wEtAZPLMo/T35iXj7HajI/AAAAAAAAA6Y/3TM-dXLf8cY/s1600/h3.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="250" src="http://3.bp.blogspot.com/-V8wEtAZPLMo/T35iXj7HajI/AAAAAAAAA6Y/3TM-dXLf8cY/s320/h3.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After hitting "Next", you are shown this last confirmation box.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/-Uoz0lmFrP1Y/T35jPhtItNI/AAAAAAAAA6o/kOR63AJRXY8/s1600/h4.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="250" src="http://1.bp.blogspot.com/-Uoz0lmFrP1Y/T35jPhtItNI/AAAAAAAAA6o/kOR63AJRXY8/s320/h4.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In the same time, the HyperTerminal starts displaying the message coming from Arduino.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/-gAB4oNO6R60/T35jGsWXZ2I/AAAAAAAAA6g/7W0jt81OcNo/s1600/h5.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="214" src="http://1.bp.blogspot.com/-gAB4oNO6R60/T35jGsWXZ2I/AAAAAAAAA6g/7W0jt81OcNo/s320/h5.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Note that, when the COM port was opened in Auto mode, no parameters (baud rate etc) being specified.&lt;br /&gt;
Interestingly, after the communication is established, the baud rate is reported as 2400 for some unexplained reason.&lt;br /&gt;
You can also type characters in HyperTerminal and they will be echoed back, between brackets,&amp;nbsp;by Arduino.&lt;br /&gt;
&lt;br /&gt;
Optionally, if you want to see what you typed (before the echoing from Arduino takes place), you can enable local echo, by selecting "Properties", then "ASCII Setup".&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-0NAyonSj2ng/T35ko-djAAI/AAAAAAAAA6w/ArDKjx0h0Z8/s1600/h6.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="320" src="http://2.bp.blogspot.com/-0NAyonSj2ng/T35ko-djAAI/AAAAAAAAA6w/ArDKjx0h0Z8/s320/h6.JPG" width="260" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/-OBgUXacwkpQ/T35lck47PPI/AAAAAAAAA64/91eFdkMGfKY/s1600/h7.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="http://4.bp.blogspot.com/-OBgUXacwkpQ/T35lck47PPI/AAAAAAAAA64/91eFdkMGfKY/s1600/h7.JPG" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Once the communication between XP (HyperTerminal) and Arduino is established via Bluetooth, the "Status" LED (if you have it soldered) is on&amp;nbsp;continuously. When the BT module is not communicating, the "Status" LED is blinking at a frequency of&amp;nbsp;about&amp;nbsp;2Hz.&lt;br /&gt;
&lt;br /&gt;
The next time a HyperTerminal session is opened,&amp;nbsp;XP remembers the BT device and the communication params (ports, passkey) and does not ask to set it up again. (I guess that's why it is called "pairing", although this word does not appear anywhere in the process.)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Time to write some serious applications using Bluetooth:)&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/gobDxZhNCDg" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/5403483629691198818/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/04/wise-clock-4-with-bluetooth.html#comment-form" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/5403483629691198818?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/5403483629691198818?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/gobDxZhNCDg/wise-clock-4-with-bluetooth.html" title="Wise Clock 4 with Bluetooth" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/-C58ZVjTMWH0/T35cvHrPM7I/AAAAAAAAA5o/X6mPbahGIAg/s72-c/s1.JPG" height="72" width="72" /><thr:total>1</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/04/wise-clock-4-with-bluetooth.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkINR3Yzeyp7ImA9WhVQFUQ.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-9062868074280212426</id><published>2012-04-04T21:47:00.002-04:00</published><updated>2012-04-04T21:49:56.883-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-04-04T21:49:56.883-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="BookClock" /><category scheme="http://www.blogger.com/atom/ns#" term="software" /><title>BookClock revisited (time setting from buttons)</title><content type="html">By popular demand, I added time setting capabilities to &lt;a href="http://timewitharduino.blogspot.ca/2010/03/dont-throw-away-that-carboard-box-your.html"&gt;&lt;b&gt;BookClock&lt;/b&gt;&lt;/a&gt;. Time and date can now be set from two buttons, called "Menu" ("H/M" in the photo) and "Plus" ("+").&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/--CCzRaahcq0/T3z32hzNp4I/AAAAAAAAA5g/yNCrJVbnkdE/s1600/BookClockTimeSetting.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://1.bp.blogspot.com/--CCzRaahcq0/T3z32hzNp4I/AAAAAAAAA5g/yNCrJVbnkdE/s320/BookClockTimeSetting.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Press "Menu" to select between hours and minutes. Press "Plus" to increment the blinking selection. When done, just let it time out (about 4 seconds) and the time will be saved in the RTC.&lt;br /&gt;
Hold down "Menu" until the date, formatted as yy/mm/dd, is displayed. Press "Menu" again to select either year, month or day, then press "Plus" to increment the blinking value.&lt;br /&gt;
&lt;br /&gt;
The time-setting code is copied and adapted from &lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2010/02/introducing-illyclock.html"&gt;IllyClock&lt;/a&gt;&lt;/b&gt; and uses the same state-machine mechanism.&lt;br /&gt;
I connected the two buttons to D16 ("Plus") and D17 ("Menu").&lt;br /&gt;
&lt;br /&gt;
The code, compilable on both Arduino 23 and 1.0, can be downloaded from &lt;a href="http://code.google.com/p/wiseclock2/downloads/detail?name=BookClockTimeSet.zip&amp;amp;can=2&amp;amp;q="&gt;here&lt;/a&gt;.&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/-IiEt2G6U0o" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/9062868074280212426/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/04/bookclock-software-update-set-time-from.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/9062868074280212426?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/9062868074280212426?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/-IiEt2G6U0o/bookclock-software-update-set-time-from.html" title="BookClock revisited (time setting from buttons)" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/--CCzRaahcq0/T3z32hzNp4I/AAAAAAAAA5g/yNCrJVbnkdE/s72-c/BookClockTimeSetting.JPG" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/04/bookclock-software-update-set-time-from.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkQCQn85eyp7ImA9WhVQEkg.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-4532201594439755167</id><published>2012-03-26T09:11:00.001-04:00</published><updated>2012-04-01T00:26:03.123-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-04-01T00:26:03.123-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="software" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Wise Clock 4 with ATmega1284</title><content type="html">I thought that replacing the &lt;a href="http://www.atmel.com/Images/doc8011.pdf"&gt;ATmega644P&lt;/a&gt; with its bigger brother &lt;a href="http://www.atmel.com/Images/doc8059.pdf"&gt;ATmega1284P&lt;/a&gt; in &lt;b&gt;Wise Clock 4&lt;/b&gt; would be trivial. How&amp;nbsp;wrong I was.&lt;br /&gt;
&lt;br /&gt;
The first step was to burn the bootloader.&amp;nbsp;After a bit of research, here is what I found out:&lt;br /&gt;
&lt;ul&gt;&lt;li&gt;&lt;a href="http://www.adafruit.com/products/46"&gt;USBtinyISP&lt;/a&gt; from adafruit cannot program chips with more than 64K of flash (see &lt;a href="http://forums.adafruit.com/viewtopic.php?f=20&amp;amp;t=24409"&gt;this thread&lt;/a&gt;);&lt;/li&gt;
&lt;li&gt;if you don't want to start from scratch (that is, compile the source code and figuring the fuses) there are at least 3 sources: &lt;a href="http://ryanmsutton.com/2011/11/updated-dev-enviroment/"&gt;ryanmsutton&lt;/a&gt;, &lt;a href="https://github.com/maniacbug/mighty-1284p"&gt;maniacbug&lt;/a&gt; and &lt;a href="https://github.com/stevemarple/Calunium"&gt;calunium&lt;/a&gt;;&lt;/li&gt;
&lt;li&gt;USBtinyISP half-works: it writes to the flash, but reading back for verification purpose fails because of a bug in the firmware; I ignored the verification error;&lt;/li&gt;
&lt;li&gt;although burning the bootloader&amp;nbsp;(any of the three mentioned above)&amp;nbsp;seemed successful, uploading any sketch afterwards always failed;&lt;/li&gt;
&lt;li&gt;the setup from ryanmsutton did not work for me (I guess the fuses are wrong; then the core files also point to the arduino folder, instead of the sanguino, as it should be);&lt;/li&gt;
&lt;li&gt;with the bootloader from calunium (atmega1284p_16MHz.hex)&amp;nbsp;I was able to upload sketches; these are the settings in &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;boards.txt&lt;/span&gt; I used:&lt;/li&gt;
&lt;/ul&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.name=Sanguino W/ ATmega1284p 16mhz&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.upload.protocol=stk500v1&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.upload.maximum_size=129024&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.upload.speed=57600&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.bootloader.low_fuses=0xFF&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.bootloader.high_fuses=0x98&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.bootloader.extended_fuses=0xFD&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.bootloader.path=atmega&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.bootloader.file=atmega1284p_16MHz.hex&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.bootloader.unlock_bits=0x3F&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.bootloader.lock_bits=0x0F&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.build.mcu=atmega1284p&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.build.f_cpu=16000000L&lt;/span&gt;&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;atmega1284.build.core=sanguino&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;Note the upload protocol (stk500v1), note the fuses and note the core folder (last line).&lt;/div&gt;&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;To compile the code for Sanguino with ATmega1284P, some macros must be updated as well, by adding&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;defined(__AVR_ATmega1284P__)&lt;/span&gt;&amp;nbsp;&amp;nbsp;to any&amp;nbsp;&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;defined(__ATmega644P__)&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
like this:&lt;br /&gt;
&lt;br /&gt;
&lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;#if defined(__AVR_ATmega644P__) || defined(__AVR_ATmega644__) || defined(__AVR_ATmega1284P__) // sanguino&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;In the end, the program space is about 126K (compared to 62K in ATmega644P) and the available RAM is 16K (compared to only 4K in Atmega644P). Not a bad upgrade for only a few bucks more.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;i&gt;Note: ATmega1284 is not defined in &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;avrdude.conf&lt;/span&gt; shipped with Arduino 22 or 23 (folder &lt;span style="font-family: 'Courier New', Courier, monospace;"&gt;\arduino-22\hardware\tools\avr&lt;/span&gt;), but it is defined in Arduino 1.0.&lt;/i&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/YFKHjiQhgIA" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/4532201594439755167/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/03/wise-clock-4-with-atmega1284.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/4532201594439755167?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/4532201594439755167?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/YFKHjiQhgIA/wise-clock-4-with-atmega1284.html" title="Wise Clock 4 with ATmega1284" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>2</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/03/wise-clock-4-with-atmega1284.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DEEFRHg9eip7ImA9WhNTF0s.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-6603411074874731065</id><published>2012-03-25T10:46:00.004-04:00</published><updated>2012-10-20T16:56:55.662-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-10-20T16:56:55.662-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 3" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Troubleshooting guide for Wise Clock 3/4</title><content type="html">This should really be a chapter of the &lt;a href="http://timewitharduino.blogspot.ca/2011/02/assembling-wise-clock-3-kit.html"&gt;assembling instructions&lt;/a&gt; for &lt;b&gt;Wise Clock 3/4&lt;/b&gt;. Until I integrate everything into a single document, it is just another post that begged to be written (long ago, as a matter of fact).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;1. Right after power up, the clock should make a beeping sound. If that does not happen, here are possible causes:&lt;/b&gt;&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;missing input 5V power; the optional power LED may be useful in this case, turned on when the power is present;&lt;/li&gt;
&lt;li&gt;reset pin may be shorted to ground (the processor won't execute any code);&lt;/li&gt;
&lt;li&gt;processor may not be powered: check that pin 10 has 5V and pin 11 is connected to ground;&lt;/li&gt;
&lt;li&gt;faulty or missing the 16MHz clock for the processor; check crystal connections to the pins; if everything looks good electrically, try to upload a sketch; it that still doesn't work, test by replacing the processor or replacing the crystal;&lt;/li&gt;
&lt;li&gt;buzzer may be disconnected; check connections between processor's pins and buzzer, shorts to the ground, terminal soldering.&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;2. The display does not light up at all (assuming the display is not defective):&lt;/b&gt;&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;faults in the connections to the display (right-hand header):&amp;nbsp;look for shorts between neighbor pins in the display header;&amp;nbsp;look for shorts between any signal pins in the display connector and ground;&lt;/li&gt;
&lt;li&gt;output header (left-hand) display header may have shorts between neighbor pins or pins shorted to the ground;&lt;/li&gt;
&lt;li&gt;the board's female connectors may be misaligned (shifted by one)&amp;nbsp;when plugged in the display's male headers.&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;3. Getting SD card error in "Quote" mode:&lt;/b&gt;&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;faulty SD card; check the SD card itself by reading it in a PC; must be formatted FAT16 (therefore 2GB or smaller);&lt;/li&gt;
&lt;li&gt;the required text files may be missing; check for their presence in the root directory;&lt;/li&gt;
&lt;li&gt;SD card may not be powered; check 3V3 power on the third pin from the left (second pin from the left is connected to the ground);&lt;/li&gt;
&lt;li&gt;check voltage divider resistors R5, R6, R7 (under the processor) and make sure they are 4K7.&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;4. Pressing a buttons (Set, Menu or Plus) does not trigger the expected action:&lt;/b&gt;&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;button itself may be defective, either always open (there is no contact between button's terminals when button is pressed) or always closed (short between terminals); verify with a multimeter that the button works correctly;&lt;/li&gt;
&lt;li&gt;look for potential shorts between the "active" terminal (connected to the processor pins D0, D1 and D2/D3, &lt;a href="http://timewitharduino.blogspot.ca/2011/11/wise-clock-4.html"&gt;see schematic&lt;/a&gt;) and ground.&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;5. Communication error when trying to upload a sketch:&lt;/b&gt;&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;make sure you plugged the FTDI cable/breakout the correct way/orientation, with the Ground/Black terminal to the right;&lt;/li&gt;
&lt;li&gt;check the Rx/Tx connections to the processor (pins 14 and 15); make sure that they are not cut or shorted to the ground;&lt;/li&gt;
&lt;li&gt;"&lt;i&gt;stk500_getsync(): not in sync: resp=0x00 error&lt;/i&gt;" usually indicates that the upload speed is incorrect; for the ATmega644P processor, the upload speed must be 38400 (defined as&amp;nbsp;&lt;span style="font-family: Arial;"&gt;atmega644.upload.speed=38400&amp;nbsp;&lt;/span&gt;in boards.txt); for the ATmega1284P processor, the upload speed is 57600;&lt;/li&gt;
&lt;li&gt;if you get "&lt;i&gt;avrdude: Yikes! &amp;nbsp;Invalid device signature.&amp;nbsp;Double check connections and try again, or use -F to 
override&amp;nbsp;this check&lt;/i&gt;", temporarily modify the signature in file &lt;span style="font-family: Courier New, Courier, monospace;"&gt;hardware/tools/avr/avr/etc/avrdude.conf&lt;/span&gt; with one of these (depending on your processor):&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;signature = 0x1e 0x96 0x0a; &amp;nbsp; //&amp;nbsp;
for ATmega644P&lt;/li&gt;
&lt;li&gt;signature = 0x1e 0x97 0x05; &amp;nbsp; //&amp;nbsp;
for ATmega1284P&lt;/li&gt;
&lt;/ul&gt;
&lt;/ul&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/ZbULAgdynLI" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/6603411074874731065/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/03/troubleshooting-guide-for-wise-clock-34.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/6603411074874731065?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/6603411074874731065?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/ZbULAgdynLI/troubleshooting-guide-for-wise-clock-34.html" title="Troubleshooting guide for Wise Clock 3/4" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><thr:total>2</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/03/troubleshooting-guide-for-wise-clock-34.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CEIBR3w4fSp7ImA9WhVREUs.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-7225478232504914874</id><published>2012-03-19T09:09:00.000-04:00</published><updated>2012-03-19T09:09:16.235-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-03-19T09:09:16.235-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Stand for ClockTHREE</title><content type="html">Some time ago I received, as a gift, this smart and very useful stand from fellow clock enthusiast Nicholas in San Diego. He designed it and made it specifically for &lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2011/05/clockthree-completed.html"&gt;ClockTHREE&lt;/a&gt;&lt;/b&gt;. Simple yet elegant, this is essential if you want your &lt;b&gt;C3&lt;/b&gt; on the desk or table.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-ywO6ONg4qH0/T2aFOmygbbI/AAAAAAAAA5M/6m6BCTGgZdE/s1600/c3_stand.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="240" src="http://2.bp.blogspot.com/-ywO6ONg4qH0/T2aFOmygbbI/AAAAAAAAA5M/6m6BCTGgZdE/s320/c3_stand.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
I did not have the chance to appreciate it until now, with&amp;nbsp;an older&amp;nbsp;&lt;b&gt;ClockTHREE&lt;/b&gt;&amp;nbsp;borrowed from a friend (I gave it to him as a gift).&amp;nbsp;Here is the &lt;b&gt;C3&lt;/b&gt; on the stand, a perfect fit!&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/-EKNJQK5tAck/T2aGX_Sc8sI/AAAAAAAAA5U/6coqrM-k-n0/s1600/c3.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="298" src="http://1.bp.blogspot.com/-EKNJQK5tAck/T2aGX_Sc8sI/AAAAAAAAA5U/6coqrM-k-n0/s320/c3.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Thank you Nicholas! Keep up the great work!&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/y9nm-y5ryCI" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/7225478232504914874/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/03/stand-for-clockthree.html#comment-form" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/7225478232504914874?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/7225478232504914874?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/y9nm-y5ryCI/stand-for-clockthree.html" title="Stand for ClockTHREE" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-ywO6ONg4qH0/T2aFOmygbbI/AAAAAAAAA5M/6m6BCTGgZdE/s72-c/c3_stand.JPG" height="72" width="72" /><thr:total>1</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/03/stand-for-clockthree.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DUUASXY_eyp7ImA9WhVREEQ.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-5880261842225616404</id><published>2012-03-18T15:00:00.000-04:00</published><updated>2012-03-18T15:00:48.843-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-03-18T15:00:48.843-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="software" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Wise Clock 4 - "Time Lived" menu option</title><content type="html">At the request of AlexT, I implemented a new feature in &lt;b&gt;&lt;a href="http://timewitharduino.blogspot.ca/2011/11/wise-clock-4.html"&gt;Wise Clock 4&lt;/a&gt;&lt;/b&gt;, which allows the display of time lived (since birth) in different formats (years/months/days/hours/minutes/seconds, days only, hours only, minutes only).&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-W8DKWBpdjps/T2YoBqW6X5I/AAAAAAAAA48/ePeU0Qtz_aA/s1600/timeLived.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="300" src="http://2.bp.blogspot.com/-W8DKWBpdjps/T2YoBqW6X5I/AAAAAAAAA48/ePeU0Qtz_aA/s400/timeLived.JPG" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The above photo shows the year/month/day on the top row and the hours/minutes/seconds on the bottom row.&lt;br /&gt;
&lt;br /&gt;
&lt;iframe allowfullscreen="" frameborder="0" height="300" mozallowfullscreen="" src="http://player.vimeo.com/video/38733509?title=0&amp;amp;byline=0&amp;amp;portrait=0" webkitallowfullscreen="" width="400"&gt;&lt;/iframe&gt;&lt;br /&gt;
&lt;a href="http://vimeo.com/38733509"&gt;Lifetime in Wise Clock 4&lt;/a&gt; from &lt;a href="http://vimeo.com/user10905638"&gt;florinc&lt;/a&gt; on &lt;a href="http://vimeo.com/"&gt;Vimeo&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
The birth date and time are read from the file message.txt on the SD card.&lt;br /&gt;
&lt;br /&gt;
I was inclined to use the Time library, but I found it a little bulky for my needs and also unsuitable for dates before 1970. Then, I copied and modified the function makeTime() to convert a datetime to seconds, and I wrote my own diffTime() function to calculate the difference (in years, months, days etc) between two dates.&lt;br /&gt;
&lt;br /&gt;
Alternating between display modes is done by pressing the SET (middle) button.&lt;br /&gt;
&lt;br /&gt;
This code will be included in the next release of &lt;b&gt;Wise Clock 4&lt;/b&gt; software.&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/9nQMmL9TJT8" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/5880261842225616404/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/03/wise-clock-4-time-lived-menu-option.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/5880261842225616404?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/5880261842225616404?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/9nQMmL9TJT8/wise-clock-4-time-lived-menu-option.html" title="Wise Clock 4 - &quot;Time Lived&quot; menu option" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-W8DKWBpdjps/T2YoBqW6X5I/AAAAAAAAA48/ePeU0Qtz_aA/s72-c/timeLived.JPG" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/03/wise-clock-4-time-lived-menu-option.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkEGQn06fSp7ImA9WhJUEUw.&quot;"><id>tag:blogger.com,1999:blog-1523577297508817869.post-983533492118571612</id><published>2012-03-13T22:50:00.003-04:00</published><updated>2012-09-08T09:23:43.315-04:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-09-08T09:23:43.315-04:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="software" /><category scheme="http://www.blogger.com/atom/ns#" term="Wide Clock" /><category scheme="http://www.blogger.com/atom/ns#" term="Wise Clock 4" /><title>Wise Clock 4 Dual screen chronometer</title><content type="html">This chronometer, inspired by the &lt;a href="http://www.youtube.com/watch?v=JFdLDLuAO3w"&gt;Doomsday clock&lt;/a&gt; by &lt;a href="http://wyolum.com/"&gt;Wyolum&lt;/a&gt;, is made with a &lt;b&gt;&lt;a href="http://timewitharduino.blogspot.com/2011/11/wise-clock-4.html"&gt;Wise Clock 4&lt;/a&gt;&lt;/b&gt; board (available &lt;a href="http://timewitharduino.blogspot.com/2011/11/buy-wise-clock-4-kit.html"&gt;for sale here&lt;/a&gt;) and two 3216 displays from Sure Electronics.&lt;br /&gt;
&lt;br /&gt;
&lt;iframe allowfullscreen="" frameborder="0" height="315" src="http://www.youtube.com/embed/bPllLW55fsQ" width="420"&gt;&lt;/iframe&gt;&lt;br /&gt;
&lt;br /&gt;
Its main feature is the odometer-style&amp;nbsp;rolling of the digits when they change.&lt;br /&gt;
The time is updated once a second, based on the 1Hz interrupt signal from DS3231, &lt;a href="http://timewitharduino.blogspot.com/2011/12/wise-clock-4-using-rtc-1hz-heartbeat.html"&gt;as described here&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://2.bp.blogspot.com/-77LbLBGaq3M/T2AGGGHjY8I/AAAAAAAAA4s/zfox4sefeDU/s1600/dualWC4.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="300" src="http://2.bp.blogspot.com/-77LbLBGaq3M/T2AGGGHjY8I/AAAAAAAAA4s/zfox4sefeDU/s400/dualWC4.JPG" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://2.bp.blogspot.com/-_siF4f4Dbok/T2AGN-Y-tdI/AAAAAAAAA40/1Yiq_dx1_z0/s1600/dualWC4back.JPG" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="300" src="http://2.bp.blogspot.com/-_siF4f4Dbok/T2AGN-Y-tdI/AAAAAAAAA40/1Yiq_dx1_z0/s400/dualWC4back.JPG" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As shown in the video, one button is used to change the display brightness, another button is used for changing the font, and the third is used for switching between rolling style and static style.&lt;br /&gt;
&lt;br /&gt;
By using the bigger (5mm) 3216 displays with the same setup and software, this clock can be easily read from a distance of at least 100 feet (30 meters).&lt;br /&gt;
&lt;br /&gt;
Source code is available &lt;a href="http://code.google.com/p/wiseclock2/downloads/detail?name=WideClock.pde&amp;amp;can=2&amp;amp;q="&gt;here&lt;/a&gt;. The current version does not allow setting up the time and date from buttons.&lt;img src="http://feeds.feedburner.com/~r/blogspot/MsTK/~4/qaP5pzsmhkY" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://timewitharduino.blogspot.com/feeds/983533492118571612/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://timewitharduino.blogspot.com/2012/03/wise-clock-4-dual-screen-chronometer.html#comment-form" title="12 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/983533492118571612?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1523577297508817869/posts/default/983533492118571612?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/blogspot/MsTK/~3/qaP5pzsmhkY/wise-clock-4-dual-screen-chronometer.html" title="Wise Clock 4 Dual screen chronometer" /><author><name>FlorinC</name><uri>http://www.blogger.com/profile/04330573900125042405</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="16" height="16" src="http://img2.blogblog.com/img/b16-rounded.gif" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://img.youtube.com/vi/bPllLW55fsQ/default.jpg" height="72" width="72" /><thr:total>12</thr:total><feedburner:origLink>http://timewitharduino.blogspot.com/2012/03/wise-clock-4-dual-screen-chronometer.html</feedburner:origLink></entry></feed>
