cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 5, 3 & 1 MCU

New Contributor

Hi,

   

I'm trying to send I2C command to the microcontroller on the CY8CKIT-059 through "Bridge Control Panel" and the KitProg, as seen on "PSOC 101: Lesson 12 I2C Transmit" video tutorial for CY8CKIT-042, but I receive only NACKs. 

   

Is that possible to do this operation for the CY8CKIT-059 kit?

   

However I've noticed that the SCL line is always on low state (voltage nearly 0V) instead of the high state (voltage nearly 4.8V) which means "Idle State" for I2C protocol. The SDA line is on high state. Observing the schematic of the CY8CKIT-059 kit, I found that between the pull-up resistors of the I2C lines and the lines there are two MOSFET (on the single chip identified as U3) that are driven by 2 of the microcontroller pins of the KitProg. Measuring the voltage, I see that the transistor between the pull-up resistor and the SDA line is ON, but the one between the SCL line and the resistor is OFF. Unfortunately I cannot measure the voltage for the pin driving these MOSFET, so I cannot determine their state and I cannot determine if the transistors' chip could be the problem.

   


Could this be the problem? How could I eventually fix it?

   

The KitProg firmware is updated with the PSoC Programmer.

   

Thank you,

   

Simone.

0 Likes
Reply
1 Solution
Esteemed Contributor II

I get minus signs in response as well, didn't care for that, but my LED changes its state.

   

EDIT:

   

Just checked: Reply is W 08+ 55- p

   

The NAK is correct, last byte of a transmission is always NAKed 🙂

   

 

   

Bob

View solution in original post

0 Likes
Reply
8 Replies
Esteemed Contributor II

Can you please post your complete project, so that we all can have a look at all of your settings. To do so, use
Creator->File->Create Workspace Bundle (minimal)
and attach the resulting file.

   

 

   

Bob

0 Likes
Reply
New Contributor

Here's the project.

0 Likes
Reply
Esteemed Contributor II

I just changed your "if"

   

        if(buff[0])

   

to

   

        if(I2C_GetActivity() & I2C_STATUS_WRITE1)

   

 

   

The Control line I used was

   

W 8 55 p

   

And with every send the LED changes.

   

 

   

Bob

0 Likes
Reply
New Contributor
        I've tried to substitute the code line as you did, and used the command "W 8 55 p" but I still get NACKs (the minus) after every command byte that I send on "Bridge Control Panel" (and of course no LED state changes). If on your kit it's working I'm afraid that's an hardware issue (in fact I still got SCL line on low state). I'll try to manage that using another KitProg "snappable" chip and I will see what will happen. Thank you, Simone   
0 Likes
Reply
Esteemed Contributor II

I get minus signs in response as well, didn't care for that, but my LED changes its state.

   

EDIT:

   

Just checked: Reply is W 08+ 55- p

   

The NAK is correct, last byte of a transmission is always NAKed 🙂

   

 

   

Bob

View solution in original post

0 Likes
Reply
Esteemed Contributor II

When the Kitprog has been snapped off once, you will need to wire SDA and SCL manually from Header J9.

   

 

   

Bob

0 Likes
Reply
New Contributor

That's ok, I will keep that on mind, thanks! I have NACKs for both bytes (w 08- 55- p). Have you got the possibility to check the voltage on SCL Pin? Is that high or low when you don't use the bridge?

   

Simone

0 Likes
Reply
Esteemed Contributor II

No chance to measure in the moment, voltage should be high.

   

 

   

Bob

0 Likes
Reply