AVRライタがある場合はそれを使えば良いが、Arduinoから入門した人はあまり持っていないことが多いだろう。 FT232RLのBitBangモードによって書き込めるツールが開発されている(FT245R/FT232R で avrdude (2)/ avrdue-GUI)ので、 それを使うのが比較的お手頃だろう。ボードだと、Uncompatinoであれば、2X4ピンつなげばこのモードで書き込める。
MISO-CTS MOSI-DCD SCK-DSR RESET-RIをそれぞれ接続した状態でFT232RL対応版avrdueを使用する。avrdue-GUIでavrdue.exeの場所を指定し、DeviceはATmega328Pに、 uncompatinoのタイプの接続の場合、ProgrammerはFT232R diecimilaを指定。
バージン(買ってきてすぐ)のICは、内蔵RC発振モードになっているので、高速書き込みモードは使用出来ない。ビットを書き換えてリセットした場合、 水晶発振モードになっていると、水晶が接続されていないと動作しなくなるので注意する。Arduino互換ボードであれば、水晶は基本接続されているので、あまり心配はいらないと思われる。
1) Portは空欄で良い、コマンドラインオプションで-P ft0 -B 76800を追加して低速モードでFuseを読み込み・書き込みできる。ファームウエアは容量が大きいととても遅いので、水晶発振モードにしてから リセットして高速モードで書き込む方が良い。hFuse=D9 lFuse=62 eFuse=07が初期値。これをhFuse=DE lFuse=FF eFuse=05にして書き込み、いったん電源を落とすかリセット。
2) コマンドラインオプションを-P ft0 -B 115200に変更し高速モードにする。Flashにoptibootのhexファイルを指定し、Erase-Write-Verifyで書き込む。
FTDI driver CDM v2.08.30 WHQL Certified.zip
Mind! I don't mean to say that I know, of my own knowledge, what there is
particularly dead about a door-nail. I might have been inclined, myself,
to regard a coffin-nail as the deadest piece of ironmongery in the trade.
But the wisdom of our ancestors is in the simile; and my unhallowed hands
shall not disturb it, or the Country's done for. You will therefore permit
me to repeat, emphatically, that Marley was as dead as a door-nail.
-- Charles Dickens, "A Christmas Carol"
Rule of Open-Source Programming #1:
Don't whine unless you are going to implement it yourself.
-- Shlomi Fish
-- "Rules of Open Source Programming"