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には、 申し訳なかったかな 〜。

閉じる コメント(0)

コメント投稿
名前パスワードブログ
投稿

閉じる トラックバック(0)

トラックバックされた記事

トラックバックされている記事がありません。

トラックバック先の記事

  • トラックバック先の記事がありません。

芸能人・有名人の新着記事

Yahoo Image
カイ
はてなブックマークMaciPhone...
05月29日 13:20

.

nag*sa_*ei
人気度

ヘルプ

Yahoo Image

  今日 全体
訪問者 11 57850
ブログリンク 0 29
コメント 0 354
トラックバック 0 11

開設日: 2006/7/2(日)


プライバシーポリシー -  利用規約 -  ガイドライン -  順守事項 -  ヘルプ・お問い合わせ

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