Youngar
游客
游客
阅读:2409回复:8

I2C-Bus Protocol With C/C++ Language

楼主#
更多 发布于:2001-06-11 09:10
Dear Sir:
 I am now using the I2C-Bus protocol.Do you have any
examples written by C/C++ language? Would you please
give me some advice?
Thanks in advance!
rayyang2000
管理员
管理员
  • 注册日期2001-03-23
  • 最后登录2012-09-13
  • 粉丝3
  • 关注0
  • 积分1036分
  • 威望925点
  • 贡献值3点
  • 好评度823点
  • 原创分0分
  • 专家分0分
沙发#
发布于:2001-06-11 10:05
You can get it from Philips' website. Or go to some MCU websites such as http://www.c51bbs.com and get a C51 I2C sample - you can translate it to any language you want.
天天coding-debugging中----超稀饭memory dump file ======================================================== [b]Windows Device Driver Development and Consulting Service[/b] [color=blue][url]http://www.ybwork.com[/url][/color] ========================================================
Youngar
游客
游客
板凳#
发布于:2001-06-11 12:06
Dear rayyang2000:
 Thank you for your Help! I will logon the website to get the data!
 Thanks again!
jeosph
驱动中牛
驱动中牛
  • 注册日期2001-04-19
  • 最后登录2006-08-08
  • 粉丝0
  • 关注0
  • 积分96分
  • 威望11点
  • 贡献值0点
  • 好评度9点
  • 原创分0分
  • 专家分0分
地板#
发布于:2001-06-11 18:12
用的着这么费事吗?
去找一个ATMEL93C56,之类的芯片,时序不都有了吗?
rayyang2000
管理员
管理员
  • 注册日期2001-03-23
  • 最后登录2012-09-13
  • 粉丝3
  • 关注0
  • 积分1036分
  • 威望925点
  • 贡献值3点
  • 好评度823点
  • 原创分0分
  • 专家分0分
地下室#
发布于:2001-06-11 20:48
[QUOTE]原本由 jeosph 发表
[B]用的着这么费事吗?
去找一个ATMEL93C56,之类的芯片,时序不都有了吗? [/B][/QUOTE]
93Cxx不是I2C接口的
天天coding-debugging中----超稀饭memory dump file ======================================================== [b]Windows Device Driver Development and Consulting Service[/b] [color=blue][url]http://www.ybwork.com[/url][/color] ========================================================
Youngar
游客
游客
5楼#
发布于:2001-06-13 08:56
Dear rayyang2000:
 Would you please give me some advice? I only use the 25Pin-9Pin cable to do this.
Thaks a lot!
rayyang2000
管理员
管理员
  • 注册日期2001-03-23
  • 最后登录2012-09-13
  • 粉丝3
  • 关注0
  • 积分1036分
  • 威望925点
  • 贡献值3点
  • 好评度823点
  • 原创分0分
  • 专家分0分
6楼#
发布于:2001-06-13 09:24
[QUOTE]原本由 Youngar 发表
[B]Dear rayyang2000:
 Would you please give me some advice? I only use the 25Pin-9Pin cable to do this.
Thaks a lot! [/B][/QUOTE]
Why do you use 25pin-9pin? Do you want to use I2C bus of DDC? If yes, it's very simple for hardware but a little complicated for software.
DDC has I2C bus. So you can connect DDC's I2C bus to E2P's. But you have to do more work for reading/writing video card's registers to access I2C.
天天coding-debugging中----超稀饭memory dump file ======================================================== [b]Windows Device Driver Development and Consulting Service[/b] [color=blue][url]http://www.ybwork.com[/url][/color] ========================================================
Youngar
游客
游客
7楼#
发布于:2001-06-13 09:43
Dear Rayyang2000:
 Thanks for your kind.The situation is:
Our Device has a 9Pin connector.We have a DOS program to read/Edit the 24C08 (EEPROM)through Parallel Port.(25Pin)But there is no source code.I want to write a Win32 application with VC++6.0.
 If using the Parallel Port,How can I use the DDC?
 Thanks in advance!
rayyang2000
管理员
管理员
  • 注册日期2001-03-23
  • 最后登录2012-09-13
  • 粉丝3
  • 关注0
  • 积分1036分
  • 威望925点
  • 贡献值3点
  • 好评度823点
  • 原创分0分
  • 专家分0分
8楼#
发布于:2001-06-13 15:00
[QUOTE]原本由 Youngar 发表
[B]Dear Rayyang2000:
 Thanks for your kind.The situation is:
Our Device has a 9Pin connector.We have a DOS program to read/Edit the 24C08 (EEPROM)through Parallel Port.(25Pin)But there is no source code.I want to write a Win32 application with VC++6.0.
 If using the Parallel Port,How can I use the DDC?
 Thanks in advance!  [/B][/QUOTE]
DDC is used for video adaptor and display monitor. It's not implemented on LPT.
I don't know details about the way to programming LPT. But on this BBS, some threads are on this topic. You can search for them. I think you can write/read data to/from the LPT. Just AND or OR some bits to simulate the I2C timing.
Another thing you should consider is the difference between Win2K and Win98. If you do this on Win98, you are lucky. If not, ....... Someone has told me that on Win2K there are some difficulties with accessing LPT. I don't know if it's true.
Hope this can help you.
天天coding-debugging中----超稀饭memory dump file ======================================================== [b]Windows Device Driver Development and Consulting Service[/b] [color=blue][url]http://www.ybwork.com[/url][/color] ========================================================
游客

返回顶部