ローム
スマートコミュニティ構築に最適な「Wi-SUN」対応の汎用無線通信モジュールを開発
アンテナ内蔵で電波法認証取得済み、ファームウェア搭載でらくらく導入
http://www.rohm.co.jp/web/japan/news-detail?news-title=2014-04-04_news&defaultGroupId=false
http://micro.rohm.com/jp/download_support/wi-sun/
++++++ 子機側 ++++++
アナログpin A0からの情報をゲットし、コーディネータに送るサンプルスクリプト
void setup() {
// Open serial communications and wait for port to open:
Serial.begin(115200);
Serial.println("SKSREG S1 12345678abcdef02");//ID02を選択
delay(100);
Serial.println("SKSREG S2 21"); //Ch33(922.5MHz)を選択
delay(100);
Serial.println("SKSREG S3 8888"); //PAN ID 0x8888を選択
delay(100);
}
// the loop routine runs over and over again forever:
void loop() {
// read the input on analog pin 0:
int sensorValue = analogRead(A0);//A0pinがアナログ入力でsensorValue変数に読んだデータが格納
// print out the value you read:
delay(888); // delay in between reads for stability
Serial.print("SKSENDTO 1 FE80:0000:0000:0000:1034:5678:ABCD:EF01 0E1A 0 0005 ");//アドレス01親機にデータ送信
Serial.println(sensorValue);//A0pinのアナログ入力sensorValue変数に読んだデータを送信
delay(111);
//以下コメントで参考情報
//sensorValue = 0; //A0pinのアナログ入力sensorValue変数に読んだデータをクリアしている
//Serial.print("SKSENDTO 1 FE80:0000:0000:0000:1034:5678:ABCD:EF01 0E1A 0 0005 ");
//Serial.println(sensorValue);
}
サポートページ
http://micro.rohm.com/jp/download_support/wi-sun/
ショップサイト
ROMさまの基板もありますので、品名の確認を再度お願いします
DT101EACV101 ウイングレット・システムズ
Arduino用変換基板
Arduino fioに搭載した場合
ゲタ基板 回路図
ゲタ基板 外形図
参考スケッチ
++++++ コーディネータ側 ++++++
SKSREG S1 12345678abcdef01 //コーディネータとして、アドレス01で設定
//SKSREG S1 12345678abcdef02 //子機の例としてアドレスを02で設定
SKSREG S2 21 //Ch33(922.5MHz)を選択
SKSREG S3 8888 //PAN ID 0x8888を選択
SKSREG S15 1 //コーディネータとして起動
//SKINFO //パラメータの確認:参考コマンド
//SKSCAN 0 FFFFFF 4 //スキャン:参考コマンド
++++++ コーディネータ側 ++++++
++++++ 子機側 ++++++
アナログpin A0からの情報をゲットし、コーディネータに送るサンプルスクリプト
void setup() {
// Open serial communications and wait for port to open:
Serial.begin(115200);
Serial.println("SKSREG S1 12345678abcdef02");//ID02を選択
delay(100);
Serial.println("SKSREG S2 21"); //Ch33(922.5MHz)を選択
delay(100);
Serial.println("SKSREG S3 8888"); //PAN ID 0x8888を選択
delay(100);
}
// the loop routine runs over and over again forever:
void loop() {
// read the input on analog pin 0:
int sensorValue = analogRead(A0);//A0pinがアナログ入力でsensorValue変数に読んだデータが格納
// print out the value you read:
delay(888); // delay in between reads for stability
Serial.print("SKSENDTO 1 FE80:0000:0000:0000:1034:5678:ABCD:EF01 0E1A 0 0005 ");//アドレス01親機にデータ送信
Serial.println(sensorValue);//A0pinのアナログ入力sensorValue変数に読んだデータを送信
delay(111);
//以下コメントで参考情報
//sensorValue = 0; //A0pinのアナログ入力sensorValue変数に読んだデータをクリアしている
//Serial.print("SKSENDTO 1 FE80:0000:0000:0000:1034:5678:ABCD:EF01 0E1A 0 0005 ");
//Serial.println(sensorValue);
}
++++++ 子機側 ++++++