MZ-80 パソコン開発物語

今だから話せる、パソコン開発記録を連載します。 感想をコメントに残して頂けたら 嬉しい・・。

全体表示

[ リスト ]

CCS PCH BUG(?)

UARTのキャラクタ化けに関し、解決しました。

CCS Support からのメールのポイントは・・

The PIC18F26J50 is a USB chip and it's oscillator configuration is different than the PIC18F2620.
The frequencies that can be used are 4, 8, 12, 16, 20, 24, 40 and 48 MHz.
For USB chips the input frequency to the PLL needs to be 4MHz,
When using the PLL , there is only 4 frequencies that can be used for the system clock,
they are 8, 16, 24 and 48MHz.

the PIC18F26J50 it requires that the PLL be enabled with the setup_oscillator(); function

For USB chips the input frequency to the PLL needs to be 4MHz,
so if your external clock frequency is 4MHz the fuse is PLL1,
if it is 8MHz the fuse is PLL2,
if it is 12MHz the fuses is PLL3, etc.
The NOCPUDIV fuse sets the system clock to use.
The fuse NOCPUDIV is used for a system clock of 48MHz,
CPUDIV2 is used for a system clock of 24MHz,
CPUDIV3 is used for a system clock of 16,
and CPUDIV6 is used for a system clock of 8MHz.

・・でした。

PICのUSBチップは、4MHzを基準に動作しているので、XTAL周波数は、決まっている。
(Microchipのマニュアルを読むと、詳しく書いている・・・)
PIC18F2620の様に、PLLは、単に4倍するとして動作させてしまった。・・お粗末・・

尚、PIC18F26J50チップは、UARTが ハードで2ポート持っているので、UART1,UART2としStreamを使うと、
各々の受信割り込みが使え、高速・快適・・・・まあ 良いチップかな・・

以上、USB chip(PIC18F26J50・・)のマニュアルを充分読まなかった原因。
CCS Supportには、 申し訳なかったかな 〜。

閉じる コメント(1)

顔アイコン

初めまして。MZ80懐かしいです。
私のPC人生の始まりがMZ80でした。
レプリカ製作楽しみにしております。

2012/8/20(月) 午前 4:38 [ Upjohn ]

[PR]お得情報

花王ニベアクリームをお得に購入
マツモトキヨシで使えるクーポンが
当たるチャンス!<Yahoo! JAPAN>
衛生対策製品クレベリンの姉妹ブランド
クレベ&アンドハンドジェルが新登場
今だけ。お試しキャンペーン実施中!
ふるさと納税サイト『さとふる』
最大10万円分旅行クーポンが当たる!
≪10月31日まで≫今すぐ応募!

その他のキャンペーン


プライバシー -  利用規約 -  メディアステートメント -  ガイドライン -  順守事項 -  ご意見・ご要望 -  ヘルプ・お問い合わせ

Copyright (C) 2019 Yahoo Japan Corporation. All Rights Reserved.

みんなの更新記事