I2C for comunicate a MC9S08QE32CLD with a MCP23017

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

I2C for comunicate a MC9S08QE32CLD with a MCP23017

跳至解决方案
731 次查看
karguar
Contributor II

I'm new in the Freescale Universe, and I have a practice with a MC9S08QE32CLD for comunicate with a MCP23017, I have a problem with the set up for the I2C communication process.

 

thanks for the collaboration

 

karguar

标签 (1)
1 解答
525 次查看
Teckna
Contributor V

Hi karguar,

i don't know MC9S08QE32 cpu but i have read only its RM. Have you read RM??:smileywink:

The clock used by I2C is ICSOUT as shown in screenshot:

Immagine.png

In the clock block diagram you see that ICSOUT can be referred to the external clock source setting CLKS and BDIV.

Immagine.png

To configure external clock for I2c you must have:

ICSC1 = 0b10000000;

ICSC2 = 0b00101010;


I hope it helps.


Regards!

在原帖中查看解决方案

5 回复数
525 次查看
Teckna
Contributor V

Hi karguar,

MQX is not supported by HCS08 family sorry!

You can see in MC9S08QE32 reference manual at chapter 12 (IIC).

What is exactly your problem?

Regards!

0 项奖励
525 次查看
karguar
Contributor II

I want to  work with a external clock 10 MHz, I think that it's the issue, because i don't know how configure the external clock.

thanks

0 项奖励
526 次查看
Teckna
Contributor V

Hi karguar,

i don't know MC9S08QE32 cpu but i have read only its RM. Have you read RM??:smileywink:

The clock used by I2C is ICSOUT as shown in screenshot:

Immagine.png

In the clock block diagram you see that ICSOUT can be referred to the external clock source setting CLKS and BDIV.

Immagine.png

To configure external clock for I2c you must have:

ICSC1 = 0b10000000;

ICSC2 = 0b00101010;


I hope it helps.


Regards!

525 次查看
Teckna
Contributor V

Please indicate your compiler and MQX version.

0 项奖励
525 次查看
karguar
Contributor II

sorry but I don't understand what is the mean of MQX, I'm using codewarrior 10

thanks

0 项奖励