iMx-25 Setting i2c speed

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

iMx-25 Setting i2c speed

ソリューションへジャンプ
2,163件の閲覧回数
raghavendraning
Contributor I

Hi,

   Currently my i2c communication is happening at 100k speed.I wanted to change it.I tried it by changing

in drivers/i2c/busses/i2c-imx.c file(IMX_I2C_BIT_RATE),but no use.Can anybody guide me..? 

ラベル(1)
0 件の賞賛
返信
1 解決策
1,771件の閲覧回数
weidong_sun
NXP TechSupport
NXP TechSupport

Hello,raghavendra,

     Open linux/arch/arm/mach-mx25/mx25_3stack.c, and adjust the following code, then Try :

static struct imxi2c_platform_data mxci2c_data = {
.bitrate = 100000, /* if you want 10K , .biitrate = 10000;*/
};

/*!
* Board specific initialization.
*/
static void __init mxc_board_init(void)
{
.....
#ifdef CONFIG_I2C
mxc_register_device(&mxc_i2c_device0, &mxci2c_data);
i2c_register_board_info(0, mxc_i2c_board_info,
    ARRAY_SIZE(mxc_i2c_board_info));
#endif
....
}

Recompile linux kernel , then check if i2c bit rate is right.

Regards,

Weidong

元の投稿で解決策を見る

0 件の賞賛
返信
1 返信
1,772件の閲覧回数
weidong_sun
NXP TechSupport
NXP TechSupport

Hello,raghavendra,

     Open linux/arch/arm/mach-mx25/mx25_3stack.c, and adjust the following code, then Try :

static struct imxi2c_platform_data mxci2c_data = {
.bitrate = 100000, /* if you want 10K , .biitrate = 10000;*/
};

/*!
* Board specific initialization.
*/
static void __init mxc_board_init(void)
{
.....
#ifdef CONFIG_I2C
mxc_register_device(&mxc_i2c_device0, &mxci2c_data);
i2c_register_board_info(0, mxc_i2c_board_info,
    ARRAY_SIZE(mxc_i2c_board_info));
#endif
....
}

Recompile linux kernel , then check if i2c bit rate is right.

Regards,

Weidong

0 件の賞賛
返信