USB communications on PSoC 3 & 5

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

cross mob
Anonymous
Not applicable

I have been able to communicate via RS232 and I2C very well. How ever I am confused how to pass data to and from the PSoC 3 & 5. I used paremeters for the RS232 communications. I not sure how to pass data from the analog section to the PC. Any snippets of code would be very helpful.

   

Thanks

   

 

   

Philip

0 Likes
10 Replies
Anonymous
Not applicable

Hi Philip, from your comment what I understand is, you want to transfer information about analog signals to PC. If this is the case the simplest method to do this would be,

   
   
        
        
  • Sample the analog signal and digitise the same using an ADC.
  •     
  • The digitised information could be transported in to a PC via UART or USB.
  •    
   
   

I have attached a project that achieves the above mentioned implementation using UART. It digitises an anlog channel using ADC and puts out the same on UART. You can view the output information using any hyperterminal program on the PC.

   
   

It is also possible to transport data to PC via Miniprog3 or USB-I2C bridge. When you use Miniprog3, it acts as a USB-I2C bridge. Data from PSoC goes in to the bridge via I2C and from the bridge it goes in to the PC via USB. You can refer to the following App note to use USB-I2C bridge.

   
   

http://www.cypress.com/?rID=38725

   
0 Likes
Anonymous
Not applicable

In the example project attached, UART is used to communicate with HyperTerminal. UART is configured in 8-bit, full-duplex mode with a baud rate of 9600 bps. This project demonstrates the usage of UART Rx interrupts. In the project, the ADC data is sent to the HyperTerminal if the key ‘s’ is pressed. If some other key is pressed, the data stored in UART_writeBuffer is sent to the UART HyperTerminal.

0 Likes
Anonymous
Not applicable

Thanks for the link. I have the PSoC 3 and PSoC 5. They have USB ports for programming and comunications. I was going to use the USB communications port for transfer of data. However I need to look over your link very carefully.

   

 

   

Thank You,

   

 

   

Philip

0 Likes
Anonymous
Not applicable

The following links will help you if you are looking for a quick start on USB in PSoC3/PSoC5.

   
   

USB Interrupt Transfer Example - PSoC® 3 / PSoC 5 

   
   

CE60246 - USBUART in PSoC® 3 / PSoC 5 

0 Likes
Anonymous
Not applicable

The application note USB Interrupt Transfer Example is being updated at the moment. Could you give me any information about the aim of this update?

   

I am newbie in the development of PSoC. I developed my own application which is using an USB Interrupt Transfer based on this application note. However, I would like to upgrade my application from Win XP to Win 7 platform.  But, I am afraid I will not be able to accomplish it by using the PSoCFirstTouchUSBNetLib.dll. Since, this dll is written for WinXP.

   

So, now I am thinking to move to CyUSB.dll. However, I have not found any simple USB interrupt transfer example for this dll. Is there any chace, that the new version of the USB Interrupt Transfer Example application note will work under Win 7?

   

 

   

Thanks.

0 Likes
Anonymous
Not applicable

Currently the USB interupt transfer Example is being updated to incorporate changes, one of them is to upgrade it upgrade the C# GUI to use CyUSB.dll. Whether the C# GUI provided uses the PSoCFirstTouchUSBNetLib.dll or CyUSB.dll as long as the device is uses HID class it will bind to HID driver and you should be able to get it working without any issues. 

   

In order to use CyUSB.dll refer to the following App Note, http://www.cypress.com/?rID=12974.

   

Inorder to get access to the CyUSB.dll and corresponding CyUSB.sys(for Windows XP and Windows 7) install USB Suite from the following location, http://www.cypress.com/?rID=34870 . 

   

The USB Suite installation provides the .Net library and the C++ library for USB communication. It comes along with reference guides and Example codes. Irrespective of which Cypress USB device is being used(FX2,FX3, PSoC), the program structure for the C# or C++ GUI is the same.

0 Likes
Anonymous
Not applicable

 Hi, 

   

I would like to read some ADC values in real-time without having to use the debugger and so I believe I'd want to try exactly what "U2" has posted in the 2nd post of this thread. I have a custom PCB using a PSoC 5LP chip, which does not have an LCD to simply read off, or USB interface. It does have a 10-pin header for the MiniProg3. The link in U2's post is dead; is there any remaining documentation and code for setting up the USB-I2C bridge using the MiniProg3?

   

Thanks for your help 🙂

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked
        Just enter "i2c-bridge" at top of this page into the field "Keyword Search" and you will get plenty of docs to read.   
   
Bob   
0 Likes
Anonymous
Not applicable

Appreciate the speedy reply, Bob. I just did as you said and found documents mainly for the CY3240 and projects using PSoC Designer. Is there anything for PSoC Creator using the MiniProg3, or will I have to make do with these? I don't want to waste my time reading up on something if it will get me nowhere; hope you understand 🙂

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked
        Look here : http://www.cypress.com/?rID=38050 and especially at the COM-guide to program your interface.   
   
Bob   
0 Likes