This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

XC161CJ and I2C

Hi Everybody,

I'm experimenting with Infineon's XC161CJ-controller on an Infineon SK-XC16x starter kit. Most of my routines work now, except the I2C-routines. Sending of data works OK, but the errors occur when I want to receive data.

Has anybody on this forum written I2C-routines for this controller? And if so, are you willing to share them?

Thanks in advance. :)

Kind Regards,
Dennis Ebben

Parents
  • Hi Rolf and Stefan,

    Last week, I haven't been able to read this forum anymore, so I saw your threads today and think it's very interesting. Thanks for the information you've shared.

    I wrote code for Infineon's C161RI/PI two years ago and that code works OK. At that time, I also had problems with my read-routine at that time, because I didn't notice that a dummy read was necessary to re-activate the bus (after sending the slave address to the bus).

    A few weeks ago, I've found an Application Note (AP1631), called:

    "Migration from C161/C164 Microconrollers to the XC161/XC164"
    (version 1.0, April 2000)

    Paragraph 3.9 describes the IIC-bus. It describes the registers that have to be renamed and also other actions that have to be token, because of the things that are new in the XC161. I used this Application Note to write my XC161 I2C-routines and the send-routines worked immediately. But something goes wrong in the read-routines, as I mentioned before. The dummy read is in the read-routine, so that isn't the problem.

    Stefan, do you want to share the code you received from Infineon with me? That probably would be very helpfull to me, because I think it's a little thing that causes my not-working read-routine. You can reach me at: info@frankort.com

    If you would like to, I'm also wanting to share my routines.

    What DAvE concerns: I also used DAvE two years ago and the first thing I noticed, was that the I2C-routines weren't usefull. They were just macro's to set a register value and not more than that. That was the reason I decided to write my own routines with a little help from information I've found on Hitex' site (they have very interesting documentation about the C167V1-family of Infineon).

    Kind regards,
    Dennis Ebben

Reply
  • Hi Rolf and Stefan,

    Last week, I haven't been able to read this forum anymore, so I saw your threads today and think it's very interesting. Thanks for the information you've shared.

    I wrote code for Infineon's C161RI/PI two years ago and that code works OK. At that time, I also had problems with my read-routine at that time, because I didn't notice that a dummy read was necessary to re-activate the bus (after sending the slave address to the bus).

    A few weeks ago, I've found an Application Note (AP1631), called:

    "Migration from C161/C164 Microconrollers to the XC161/XC164"
    (version 1.0, April 2000)

    Paragraph 3.9 describes the IIC-bus. It describes the registers that have to be renamed and also other actions that have to be token, because of the things that are new in the XC161. I used this Application Note to write my XC161 I2C-routines and the send-routines worked immediately. But something goes wrong in the read-routines, as I mentioned before. The dummy read is in the read-routine, so that isn't the problem.

    Stefan, do you want to share the code you received from Infineon with me? That probably would be very helpfull to me, because I think it's a little thing that causes my not-working read-routine. You can reach me at: info@frankort.com

    If you would like to, I'm also wanting to share my routines.

    What DAvE concerns: I also used DAvE two years ago and the first thing I noticed, was that the I2C-routines weren't usefull. They were just macro's to set a register value and not more than that. That was the reason I decided to write my own routines with a little help from information I've found on Hitex' site (they have very interesting documentation about the C167V1-family of Infineon).

    Kind regards,
    Dennis Ebben

Children