Help - Search - Members - Calendar
Full Version: CodeSys ST test
Forums.MrPLC.com > PLCs and Supporting Devices > CoDeSys
chaca
smile.gif
Alright guys/gals, here is a challange for all of you CoDeSys Guru's out there. Write an I2C Bus Protocol Driver using CoDeSys in ST using standard I/O's of a PLC. For example, you can tag the SCL signal to one of the PLC outputs and the SDL to one of the PLC inputs/outputs (share the same signal). All you have to do is write one byte of data to the I2C EEPROM and read one byte of data out of the EEPROM. I have attached a PDF file that contains the specs on this module and the pinouts for clarification. I just bumped into this interesting protocol. I haven't written anything for it yet. Let me know what your thoughts are. I will start writing hopfully later on this evening.

Have fun and let me know what you come up with! dancered.gif


PS: Just remember, there is a Read or Write Initialization byte that has to be transmitted before the actual data byte is written or read.
tonymonty
Hey Chaca,
Yow, that's alot of work. I write all my I2C stuff on a 16-bit micro.
To each his own though.
Peace
chaca
QUOTE(tonymonty @ Nov 2 2007, 12:06 PM) [snapback]61152[/snapback]

Hey Chaca,
Yow, that's alot of work. I write all my I2C stuff on a 16-bit micro.
To each his own though.
Peace


Hey Tony,

I just finished coding it in SLC500, now I am going to work on it to write in CoDeSys. Will post it when ready...just curious to see how many people are comfortable with St.

Cheers!

chaca
Here is the SLC Code. Did anyone resolve this in CoDeSys yet?
chaca
Here is the Omron CX-1 Code. I still didn't have a chance to do that in CoDeSys.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2010 Invision Power Services, Inc.