Cypress USB to I2C bridge DIY using PSOC5? - Page 1
Forum section: electronics / general

author: Boscoe
author_rank: Frequent Contributor
timestamp: February 10, 2016, 09:14:43 pm
content: I'm currently working with a Cypress part that handles my capacitive touch sensing on a project. It doesn't work at the moment so would like to make use of Cypress's interactive program that can be used to fine tune the settings but it requires a USB to I2C bridge for communication. I don't want to spend £100 for Cypress's bridge so I wonder if anyone has hacked one together?ThanksBoscoe

author: dferyance
author_rank: Regular Contributor
timestamp: February 10, 2016, 10:47:15 pm
content: If this is just a one-off, how about getting thehttp://www.cypress.com/documentation/development-kitsboards/psoc-4-cy8ckit-049-4xxx-prototyping-kitsfor $4.The USB-to-serial chip can be snapped off and supports I2C.

author: Boscoe
author_rank: Frequent Contributor
timestamp: February 10, 2016, 11:44:53 pm
content: Awesome thanks! I've ordered a couple. I'll report back in a couple of days whether it works.

author: miguelvp
author_rank: Super Contributor
timestamp: February 11, 2016, 12:59:55 am
content: Since you are already going that route I did a little example on how to use that break-off part to talk to an I2C RTC from windows using Cypress USB-Serial Software Development Kit that supports Windows, Linux/MAC & Android:https://www.eevblog.com/forum/microcontrollers/cheap-easy-i2c-dev-kit/msg618200/#msg618200But so you know the PSoC 5LP prototyping kit might allow you to make a USB-I2C bridge, since the kitprog does implement that functionality, I would have to dig for information on how to do that, but I'm travelling soon and might take a couple of weeks.But maybe I can find out today.In any event that link above should help you to use the CY7C65211 chip on that prototyping board with links on what you'll need as well.

author: miguelvp
author_rank: Super Contributor
timestamp: February 11, 2016, 02:14:03 am
content: The kitprog source code available here implements a USB-I2C and USB-UART bridge on a PSoC 5LPhttps://www.element14.com/community/thread/27067?start=0&tstart=0But it is non trivial to take that part out of the kitprog project to make it standalone. So I think the approach to use the PSoC4xxxx prototyping board snap off with the CY7C65211 USB-UART chip is the best way to go.It not only can do I2C, but SPI and UART as well:Also I did post other links a couple of posts before that post I linked beforehttps://www.eevblog.com/forum/microcontrollers/cheap-easy-i2c-dev-kit/msg617096/#msg617096Hope this helps.

author: Boscoe
author_rank: Frequent Contributor
timestamp: February 11, 2016, 10:44:02 am
content: That's amazing information. Thank you very much. As I say I'll report back in a couple of days. My only worry is that the EZ click software for the cap sense configuration will not detect it as a valid I2C bridge because they want you to buy the expensive one.

author: miguelvp
author_rank: Super Contributor
timestamp: February 11, 2016, 03:15:45 pm
content: Make sure you have pull up resistors that match your I2C speed it works fine.If in doubt look for PSoC I2C examples. on the top schematic usually they add the external components for documentation purposes.google "100 projects in 100 days elementf14" They have at least one I2C example. Granted is for a PSoC 4 Pioneer kit but it should be portable to the PSoC 5LP.

author: Boscoe
author_rank: Frequent Contributor
timestamp: February 12, 2016, 09:03:32 pm
content: Quote from: miguelvp on February 11, 2016, 03:15:45 pmI have programmed the bridge with the configuration facility however it doesn't show up as a device in EZ click. Any advice to fool it into thinking it's the right device? Could be as simple as VID PID? Or description?

author: miguelvp
author_rank: Super Contributor
timestamp: February 12, 2016, 09:09:01 pm
content: Quote from: Boscoe on February 12, 2016, 09:03:32 pmI never used the EZ click. Can you use the "USB Serial Test Utility" provided by Cypress using the VID and PID that you used in the "Cypress USB-Serial Configuration Utility"?If you used the defaults, it should be VID 0x04B4 and the PID 0x0004

author: Dielectric
author_rank: Regular Contributor
timestamp: February 12, 2016, 09:51:46 pm
content: I tried it yesterday, but didn't have any luck. First, EZ-Click won't let you use Cypress' VID with anything other than 0x0004 for the PID, so you'd have to do some weird stuff with the INI files to get it to bind. Second, on a cursory glance at the API, I don't think the Bridge software uses the same set of commands as the USB driver for the USB-Serial parts use so that's kind of a showstopper. However, if you grab the $10 PSoC4M kit instead of the older one, you get a full Kitprog on the snap-away part so that would work with EZ-Click:http://www.cypress.com/documentation/development-kitsboards/cy8ckit-043-psoc-4-m-series-prototyping-kitIf you wanted something with an M3 for later, you could grab the equivalent PSoC5LP stick instead:http://www.cypress.com/documentation/development-kitsboards/cy8ckit-059-psoc-5lp-prototyping-kit-onboard-programmer-and

author: true
author_rank: Frequent Contributor
timestamp: February 13, 2016, 07:06:36 am
content: I don't know what EZ Click is, but I can say that I have used the CY8CKIT-059 KitProg to tune CapSense on PSoC4 and PSoC5 targets with the CapSense_CSD Tuner in PSoC Creator (Tools->Component Tuners->Name of CSD Component).I haven't tested if the CY8CKIT-049 works. I have used the USB converter it as an I2C master but not for CapSense tuning with Cypress software.

author: kripton2035
author_rank: Super Contributor
timestamp: February 13, 2016, 08:10:59 am
content: another way to do it ? :https://datasheets.maximintegrated.com/en/ds/DS3900P2EVKIT.pdf

author: Boscoe
author_rank: Frequent Contributor
timestamp: February 17, 2016, 11:58:35 am
content: Quote from: Dielectric on February 12, 2016, 09:51:46 pmThanks, this worked for me. It does annoy me Cypress does no mention anywhere this is possible. They only talk about two options, both of which cost over £100 which is ridiculous.

author: Docara
author_rank: Regular Contributor
timestamp: February 24, 2021, 04:12:59 pm
content: Hi Boscoe,I know this is an old post but I'm in the same position as you were in - what little programmer/debugger worked for you in the end and what if any mods did it need ?I'm looking to use the ez-click, Capsense and CY8CMBR3116.Thanks

author: NiHaoMike
author_rank: Super Contributor
timestamp: February 25, 2021, 02:34:48 pm
content: Take a look at the MCP2221A if you just want USB to I2C. There's even a Python library for it.https://github.com/nonNoise/PyMCP2221A

author: Docara
author_rank: Regular Contributor
timestamp: February 27, 2021, 04:36:48 pm
content: Hi NiHaoMike,The reason for my post is I intend to use Cypress 'ez-click' software. Cypress wants over £100 for programmer. I don't know if it needs to auto-detect a specific Cypress I2C bridge to operate. I was looking for confirmation that a CY8CKIT-059 (£10) does indeed work with said SW.Have you used ez-click and the MCP2221A, are your suggesting it from hands-on.thanks