Unable to connect to capsense tuner, CY8C4045

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
JT42
Level 1
Level 1
First solution authored First reply posted First question asked

I have two setups. One is a complete CY8CKIT-041 PSoC 4 S-Series Pioneer kit. I am able to program the CE210489 Proximity Sensing example to it and communicate with it using the Capsense Tuner via I2C. It works perfectly. When I do this, I see I2C activity on pins 6 and 10 of J8 on the CY8CKIT-041 board.

My second setup uses a CY8CKIT-041 board connected to my own board via J13. My board contains a CY8C4045LQI-S411. I have connected Pins 9 (P4[0]) and 10 (P4[1]) of the CY8C4045 (I2C Clock and Data) to pins 6 and 10 of the J8 on the CY8CKIT-041 board.

I am using code from one of the example projects, modified for my setup:

CyGlobalIntEnable;

EZI2C_Start();

EZI2C_EzI2CSetBuffer1( sizeof( CapSense_dsRam ), sizeof( CapSense_dsRam ), (uint8 *)&CapSense_dsRam );

CapSense_Start();

CapSense_ScanAllWidgets();

I then have code that calls CapSense_RunTuner(), CapSense_CSDScanExt(), and CapSense_ProcessWidget( CapSense_PROXIMITY0_WDGT_ID ) periodically using a state machine based on the example code.

The problem is the tuner will not connect. There is no I2C activity on pins 6 and 10 of J8. One thing I observe is that P5LP15_0 (the gates of U16 on the CY8CKIT-041 board is not being driven low, meaning the pull-up resistors aren't connected to the I2C lines. In the first setup (the one that works) it is being driven low, connecting the pull-up resistors. When I launch the tuner, it sees the CY8CKIT-041 which identifies as a KitProg3. I have confirmed the port settings -- address 8, sub-address 2-bytes, 3.3 V power is on, speed 100 kHz. (That's the same configuration I use in the one that works.) In addition to no I2C bus activity, when I click "Connect" in the tuner, after a long delay it comes back with the error message "There was an error reading data from the device."  After that, if I attempt to connect a second time it gives me the error "Can't Open SMSIS-DAP port" and the only way to recover from that is to close both the Tuner and PSoC Creator, and cycle power to the CY8CKIT-041 board.

0 Likes
1 Solution
JT42
Level 1
Level 1
First solution authored First reply posted First question asked

At first the Bridge Control Panel showed no devices.  I added pull-up resistors to both SCL and SDA, and then it showed one device with address 0x08, and now the tuner will connect.  (I thought I tried this the other day, but apparently didn't have something connected properly.)  Thanks for the help.

View solution in original post

0 Likes
2 Replies
Hari
Moderator
Moderator
Moderator
750 replies posted 500 replies posted 250 solutions authored

Hi @JT42 

 

In the second state, can you please confirm that the program in the CY8CKIT-041 was erased? The 041 kit should not be holding the I2C bus with the same address, so it is necessary that the program flashed in the 041 kit does not use pins 6 and 10 of J8. 

 

Instead of using Tuner, can you check if the I2C bridge is active by using the Bridge Control Panel software? This is a tool that is pre-installed with PSoC Creator and helps in checking if the I2C bus is active. 

Hari_0-1643777217301.png

Clicking on the List option here will show you the devices that are currently connected in the bus. 

 

Another approach is to connect the custom board directly to the Kitprog's I2C pins instead of going through the 041 device's pins. You can connect the SDA and SCL line to J8 pin 10 and 6 respectively. 

Please note that we do not recommend this approach where you use the Kitprog attached to one microcontroller for communication with another board. The right approach would be to use a separate USB-I2C bridge, such as MiniProg.

 

Best regards,

Hari

0 Likes
JT42
Level 1
Level 1
First solution authored First reply posted First question asked

At first the Bridge Control Panel showed no devices.  I added pull-up resistors to both SCL and SDA, and then it showed one device with address 0x08, and now the tuner will connect.  (I thought I tried this the other day, but apparently didn't have something connected properly.)  Thanks for the help.

0 Likes