Sun SPOT Feeds
Author: tveilleux
Posted: Tue Jul 08, 2008 3:58 pm (GMT -7)
Topic Replies: 4

JeffS wrote:
Cool! That's exactly what I needed to know Smile

It turns out, at least one "artifact" was my own stupidity... I didn't realize that the Hirose pins were laid out on a metric grid, and was going crazy trying to figure out why I couldn't get the traces centered on the pads, even with a 1-mil grid. Then I finally looked at the footprints and instantly realized why... Embarassed


Well, whenever you have off-center pins, either metric or imperial, I suggest you never make the grid smaller to accomodate it. Rather, you should get close to the pin, and then start from the pin with a bend style that stays centered orthogonaly to the pin and join to the trace you just stopped. The software will do an off-grid completion for you. In those instances, it helps to have an alternate grid of exactly HALF the main grid to help with preventing large angles.

I also suggest you keep an 8 mil grid and 8 mil trace, or similar (6 mil or 10 mil work also), it helps with routing. When going with board houses, they should accept 12 mil holes with 5 mils annular ring thickness or better, or else it's quite hard to do small pitch. The 2 layers eBones follows the industry's lowest common denominator of tolerances: Alberta Printed Circuits. Min drills are then 20 mil and the eBones looks pretty packed already.

JeffS wrote:

Is the parts library with the Hirose headers, board outline, etc somewhere in a Subversion repository?


Yes. You can find it at:

https://spot-edaq.dev.java.net/source/browse/*checkout*/spot-edaq/trunk/eDAQ/Design%20Files/SunSPOT.lbr?rev=HEAD

JeffS wrote:

When you made the boards, did you solder the Hirose connectors on by hand? If so, were they relatively straightforward to do (presumably with hot air rework tool and a syringe of solder paste?), or were they a major pain? Did they behave the same way a .5mm IC would -- automagically floating into the correct position thanks to surface tension and the soldermask once the solder melted? Actually, that reminds me... after you soldered the top or bottom one in place, how did you keep it from falling off (or moving) while you were soldering the SECOND Hirose connector in place on the other side of the board?


They were soldered using a standard soldering iron tip, albeit a very thin one. I used 20mil leaded solder and flux. I never use hot air for anything but QFP removal. You hold the connectors by hand with tweezers and everything is OK.

JeffS wrote:

How did you manage to get the boardhouse to leave the Hirose connector's alignment holes non-plated? Or did you just let them be plated, and use slightly larger diameter holes to make up for it?


By default a hole that has no annular ring around it will not be plated. The "HOLE" command in Eagle makes Unplatted hole. I also draw drill legends to make sure it is obvious at fabrication time which holes are plated and which are not.

Hope this helps.

Best regards,

Tennessee Carmel-Veilleux
Technical Director, Project SONIA AUV/ASV, ETS (http://sonia.etsmtl.ca)

Hello again. In my last post I briefly introduced myself, now I'd like to take the time to explain in more detail what I'll be doing during my internship. Amongst other things, I'll be working with the SPOT team on the Yggdrasil Data Collection Framework. This framework is an effort within the SPOT team to create a programming framework that enables people with various levels of programming experience to easily create end-to-end applications i.e. all the code from visualising and storing the data on to the code that runs on the SPOTs. I'll be working on the SPOT side tools i.e. the code that runs on the SPOTs. This code will hopefully be used in SPOT deployments at the Cocobolo Nature Reserve in Panama and at Ravenswood in Menlo Park, CA as part of the salt marsh reclamation project. I'll be posting more about my work as its completed.

As some (many? both?) of you know, we have been running a special program for Education with Sun SPOTs. We have been accepting proposals, and granting Sun SPOT kits, for course development in Wireless Sensor Networks, Robotics, and a wide range of other topics. The courses developed through this program are required to be open source, and we're starting to get results!


RTI has submitted an interesting website with some of their course development activities and results. Check it out!


I'll post more as they roll in. If you're working on one of these projects, and you want to see your project listed here, just send me the link (again, if you already did and I ignored it) and I'll get it posted here!


[ The Kennedy Constant:


Don't get mad -- get even. ]

I think we (Sun) 'get it' and get it right, most of the time. Not on everything, for certain, but when it comes to communication, openness and transparency, we have that down. As a counter example ...


I use a nifty piece of software from BareBones Software called Yojimbo (I know, the name sort of blows, but it's a great 'digital junk drawer' for my Mac and helps me save, organize and keep track of lots of stuff in one place. But I digress). Don't get me wrong here, I love the product, and use it almost every day. But their communication strategy seems to be modeled on Apple's. Tight-lipped and reticent. The users on the Yjimbo users' alias are clamoring for answers, for insight into what may, or may not, be going to happen with the product, and where things are headed. the response from BareBones?


Yep, pretty much. Well, other than to point to their FAQ, which says:



We'd like to offer an iPhone version of Yojimbo, but can't currently say if/when this may happen nor what its feature set might be. As soon as we're able to provide more info about our plans, we will do so.



The equivalent of "we can neither confirm nor deny ..." and a non-answer. Don't get me wrong, I understand that at times it can be advantageous to carefully control the release of information so as to not over-promise, under-deliver, or to make a big splash with your announcements. But there is a lot to be said for involving your users, for making them feel involved, a part of the process, and invested in your products. A user that has a mere affinity for a product is not nearly as good as a user that has an investment in, and a commitment to, a product or company. Involving your users gives them the investment and commitment to make them useful assets, not just the other end of the payment stream.


And what has all this to do with Sun? Well, I really think that this little experiment we call blogs.sun.com is a shining example of what can come of a company that values open communication with its customers -- and potential customers. Very few of our customers, I would venture, are unclear about what we are working on, where we are investing, and what they can expect from us. Yes, we all want to see more from the stock price, etc. but it's pretty clear that we have a real commitment to open communication with our customers.


I wish more companies would show the same.


[ "Now is the time for all good men to come to."


-- Walt Kelly ]

Left is a Bend SPOT. Right is a Serbo SPOT. I use a trimmer potentiometer as a bend sensor. Bend SPOT operate on serbo by twisting a screw.

Author: karihei129
Keywords: SunSPOT JavaOne spaughts
Added: June 26, 2008

Hello all! My name is Robert Taylor and I've recently returned to Sun as an International Student Intern on the Sun SPOT team. Over the next few months I'll be posting what myself and other interns on the SPOT team are doing.

Sun SPOT in Great Sand Dune

Author: javapda
Keywords: Sun SPOT Great Sand Dune spaughts
Added: June 20, 2008

SPOT in Mesa Verde

Author: javapda
Keywords: SPOT in Mesa Verde spaughts
Added: June 19, 2008


Sun SPOT Great Sand Dune






Taken at Royal Gorge in Colorado



















US Air Force Academy





























In Colorado
Near the Garden of the Gods
I learned today that there is a new Dev Preview of the BLUE SDK for the Sun SPOT available (blue-080609). I had been using blue-080502.

Can be accessed via the Sun SPOTManager tool. The download is about 27587K (before installation).

Two years of hair comes almost full circle. When I moved to North Carolina in 2006, I did this:


DSCN0340.png


Yep, cue-balled it. It was easier than having to wash it.


But as soon as I moved here, my then-9 year-old son began a project to grow his hair and donate it to Locks of Love. It was his own idea, and something I'm proud of him for coming up with. And he asked me to do it with him, so I did. Well, last week was cutting time, and I went from this:





IMG_0049.png


to this:





IMG_0053.png


in 10 minutes.


I feel much better now.


[ The only thing to do with good advice is pass it on. It is never any use to oneself.


-- Oscar Wilde ]

Best watched in High Quality mode to avoid skewing of aspect ratio. Sun SPOT Road Trip

Author: javapda
Keywords: Sun SPOT Road Trip spaughts
Added: June 15, 2008






Recommend you watch this in high-quality mode (the standard mode skews the aspect ratio)

SPOT and Insect - Moab, UT



Indiana SPOT in Monument Valley

The SPOT Files is a place to blog specifically about Sun SPOT related things.

[ English version is here ]

ここからは servocar-spots のソースコードをざっくりとみていきましょう。まずはじめに、リリース 1.0.0 のコードを以下↓のようにリポジトリからチェックアウトしてください(ただしコンピュータに subversion のクライアントがインストールされていることを前提にしています。また java.net のアカウントも必要ですので両方お持ちでない場合は準備ください)。

$ mkdir work; cd work
$ svn co https://servocar-spots.dev.java.net/svn/servocar-spots/tags/REL-1.0.0 servocar-spots --username <username> 
もちろん trunk から最新のコードをチェックアウトしても結構ですが、以後の説明はこのリリース(1.00)を前提としています。

チェックアウトしたら、servocar-spots ディレクトリにある2つの Sun SPOT アプリをそれぞれビルド、デプロイします。1つめはリモコン用のアプリ("ServoCar-Controller")でもうひとつはサーボ駆動用のアプリです("ServoCar-OnCar")。
$ cd servocar-spots/ServoCar-Controller
$ ant deploy
$ cd ../ServoCar-OnCar
$ ant deploy
次回は ServoCar-Controller のソースコード、特に Sun SPOT ネットワークと EDemoBoard の加速度センサを中心に見ていく予定です。

Let's glance over servocar-spots codes from here. First of all, check out source codes for release 1.0.0 as the following (For this, you need to have a subversion client installed on your computer and an account for java.net, so please prepare both of them if you don't have).
$ mkdir work; cd work
$ svn co https://servocar-spots.dev.java.net/svn/servocar-spots/tags/REL-1.0.0 servocar-spots --username <username>
You can, of course, check out sources from trunk, but I'm explaining the details based on this release (1.0.0).

Then, build & deploy two Sun SPOT applications - one is for a remote controller named "ServoCar-Controller" and the other is for an actuator of servos named "ServoCar-OnCar".
$ cd servocar-spots/ServoCar-Controller
$ ant deploy
$ cd ../ServoCar-OnCar
$ ant deploy
Next, let's look at the ServoCar-Controller codes, especially related to Sun SPOT networking & accelerometer on EDemoBoard.

So the ratings for the JavaOne Hands On Labs came out, and we (Sun SPOTs) did pretty well. Above average, to be exact.



The following scores are generated using the Overall Quality values.

Overall Conference Average (all sessions) 4.12

BOF Average 4.01

Panel Average 3.92

Hands-On Lab Average 4.30

Technical Session Average 4.13


The Sun SPOT Hands On Lab rated a 4.57, the Birds of a Feather (BOF) rated a 4.2, and the Technical Session rated 4.38. All respectable, and well above average.


Thanks to all of you that attended, and gave us such nice feedback!!


[ Mother told me to be good, but she's been wrong before. ]

[ English version is here

Sun SPOT アプリケーション (MIDlet) のクラスは "javax.microedition.midlet.MIDlet" を拡張して作成し、ライフサイクルは startApp() メソッドから始まります。

import javax.microedition.midlet.MIDlet;
import javax.microedition.midlet.MIDletStateChangeException;
// ...
public class SunSpotApplication extends MIDlet {
// ...

protected void startApp() throws MIDletStateChangeException {
System.out.println("Hello, world");
// ...
Sun SPOT を使ってサーボをまわすために必要なコードは以下の2行だけです。
Servo serv0 = new Servo(EDemoBoard.getInstance().getOutputPins()[EDemoBoard.H0]);
serv0.setValue(2000);

サーボモータの動かしかたや動作原理の詳細については Servomechanism などを参照ください。Google で検索してもたくさんヒットすると思います。ここでは定期的に方形波・パルス(一定周期で "High" or "Low" を瞬間的に繰り返す波形)をサーボに送り続けるとサーボが回転し、方形波の周期中の "High" の長さによって回転角度(または continuous rotation の場合は速度)が変化するということが分かれば十分です。一般のサーボの場合は、このパルスの周期が 20 ミリ秒で 1500 マイクロ秒(つまり 1.5 ミリ秒) "High" が続くパルスを送った場合に 90 度回転します(この位置を "Neutral" position といいます)。他のパルスではこの 1500 を中心として、

  • 1500 - value マイクロ秒: 0 度
  • 1500 + value マイクロ秒: 180 度

回転します。上の "value" というパラメータはサーボによって異なりますが、一般的には 250 から 500 の間になっているようです(使用前に確認する必要があるかもしれません)。上の "Servo#setValue(2000)" はパルス中の "High" の長さを 2000 マイクロ秒にセットし、そのパルスをサーボに送り続けるコードになります。Sun SPOT においてサーボを動作させるコードはこれですべてです!

組み込みのプログラミングを組んだ方なら、同じことを C で書くのがこれほど簡単ではないことにお気づきかもしれません。もちろん使用しているマイコンの種類とか、どれだけライブラリが整備されているかによりますが、基本的には多くの include ファイルを取り込んだ後、使用するレジスタやシリアル通信用のコマンドシンタックス(フォーマット)を調べる必要があります。それからパルスを手動で発生させる場合はデジタルポートに対して "high" の送出 → 1.5 ms 待つ → "low" の送出を繰り返すコードを書く必要があります。またたとえ ATmega88 "8-bit Timer/Counter2 with PWM and Asynchronous Operation" などのような少し高レベルなオペレーションを使って PWM (pulse-width modulation) を発生させたとしても組み込み C における根本的な複雑さを解決できたとはいえません。

どうでしょうか?少しでもいいかも?と感じていただければ Sun SPOT への乗り換えを試してみる時期かもしれません!!