News! スマイルデコーダ シリーズを2016年4月よりリリースしました。
News! ぬっきぃさんのワンコインデコーダはさらに安いです!(300円~!)\\Nucky's one coin decoder is very cheap! check web nucky!
このページでは、DCCデコーダ「スマイルデコーダ」について回路から使用方法、ソフト、販売までが書かれています。 このデコーダはArduinoをベースとしており、完全なオープンソース・オープンハードになっており、様々な方がサウンドデコーダを実装したり、メロディを奏でたり、VVVF音をモーターから出したり、ポイントを動かしたりなどしています。1個あたり材料費で1000円弱でZゲージにも(ギリギリ)入るDCCデコーダを作成できます。
This page describes our original DCC decoder “Smile Decoder”. This decoder has a compatibility with Arduino. You can easily customize this decoder. This decoder supports turnouts and locomotive, specialized feature.
Parts No | Parts | Package | url | Parts ID | Price |
---|---|---|---|---|---|
D1-D5 | Rohm RB160M-30TR, 1A Panjit SS2040FL | SOD-123 | url url | I-01398 I-02073 | @15JPY |
C1,C2,C3 | 1uF 25V or 50V MLCC, | 2012size | url | P-07525 | @10JPY |
C4,C5 | Option, 1uF 25V or 50V MLCC, | 2012size | url | P-07525 | @10JPY |
R1,R2 | 100kOhm, | 1608size | url | R-06104 | @0.05JPY |
IC1 | ATMEL ATMEGA328P-AU, | QFP32 | url | I-04386 | @280JPY |
IC2 | Rohm BD6231F-E2 | SOP8 | url | I-05088 | @180JPY |
IC3 | Toshiba TA78L05F, | SOT-89 | url | I-00494 | @25JPY |
X1 | Murata Ceralock 16MHz,CSTCE16M0V53 | 3 pins, SMD | url | P-09679 | @40JPY |
- | SmiTube 10mm | url | P-08986 | - |
Pin No. | Function | Notes |
---|---|---|
D3 | Sound, PWM, generic use | We often use for sound option. |
A5, A4 | I2C, Analog input pins | |
D9, D10 | Motor PWM pins | If not soldered Motor Driver, you can use this pin freely. |
IN | DCC input pins. | Connect to rail side wire. |
OUT | Motor output pins. | Connect to motor side wire. |
CAP | Keep alive capacitor pins. | DO NOT MISUNDERSTAND plus(+) pin. See + mark. |
以下は、Arduino IDE用のポイントと機関車デコーダ等のソースコード(スケッチ)例や、DCCデコーダ機能のベースとなるNMRA DCCライブラリの転載(ミラー)です。
This decoder sketches are based on NMRA DCC library. Please install the library before use.
File | Version | url | Notes |
---|---|---|---|
Locomotive decoder sketch (車両用デコーダスケッチ) | R4 | download | Improve maximum speed stop problem. |
Locomotive decoder VVVF sketch (VVVF音対応車両用デコーダスケッチ) | K7(2015/6/15) | download | Improved by Fujigaya-san. Required TimerOne Library. Detail description is here (written in Japanse) |
Locomotive decoder with VVVF and melody sketch | K9(2015/8/1) | download | produced by Fujigaya-san. Required TimerOne Library and PWMDAC_Synth. Detail description is here (written in Japanse) |
Turnout decoder sketch (ポイント用スケッチ) | R1 | download | first version |
Headlight decoder sketch (ヘッドライト用スケッチ) | R1 | download | first version |
NMRA DCC Library 2014-10-15 (共通ライブラリ) | R1 | download | このライブラリは必ずArduino IDEのlibrariesフォルダにインストールしてください。Mirror from mrrwa.org |
サウンド関連スケッチはSound Optionを参照ください。
Sound related sketches are described in Sound Option
If first time setup(Smile Writer / スマイルライター) is finished, please see the following instruction.
スマイルライタの作成作業(Smile Writer / スマイルライター)を完了した後に、以下の手順でスケッチをスマイルデコーダに書き込みます。
This chapter describes how to implement the decoder to turnouts and locomotive.
ここでは、ポイントと車両にデコーダを組み込んだ例をお見せします。
I use Kato 2-301 HO turnout with solenoid. This turnout doesn't support DCC. Then I implement smile decoder to this turnout internal.
以下に、主なスケッチの初期設定(主にCV)の方法を記載しています。
CV1(LSB)とCV9(MSB)がアドレス設定用です。
CV1(LSB) and CV9(MSB) means turnout address value.
CV9は0、CV1を1とすると、初期値(アクセサリアドレス1)となります。CV1に10と書き込むと、アクセサリアドレスは10になります。CV9は上位ビットをあらわすので、255超の場合はCV9に上位ビット分を書き込んでください。
If CV9 sets 0 and CV1 sets 1, turnout address means 1. If you want to set the address 255 or more, you need to write CV9 the upper bit value.
不定期に頒布中。以下の価格は参考価格で、部品調達状況により常に変動します。 また、デコーダキットについては頒布価格を下げるため秋月電子で購入出来る部品は頒布しませんので、ご了承下さい。お手数ですが、各自で入手下さい。
お問い合せ・購入は、公式オンラインショップの注文フォームの備考欄か、メールでどうぞ。
※完成品はありません。全て自分でハンダ付け&ソフト書き込み願います。