MiniProg4 Question

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

cross mob
OmAb_4672891
Level 2
Level 2
10 replies posted 5 replies posted 10 questions asked

Hello and thank you for all your swift responses. This community forum has been very helpful thus far.


We have gotten hold of Cy8c4147AZI-s465 semi conductors and have successfully soldered them on to our PCBs. We tested CAN connection from a previous post I asked and that is working fine! Now we are having another issue regarding UART. We are trying to transmit uart data FROM microcontroller TO PC through miniprog4_Rx pin.

We are using the MiniProg4 and I noticed that when using the Software_Transmit Uart code, it establishes a connection with the USB port the minprog4 is connected to but but no output is shown on the terminal. To remedy this, we connected the UART_TX pin in our code to the receive pin on the miniprog4 and we are receiving garbage characters on putty. Is there a way to send UART data strictly from the minprog4?

This method works automatically if we had a Kitprog on our pcb but we do not. It is merely 5 pins that are connected to the miniprog4. Does data travel through the SWDIO and SWDCLK on the minprog4?

Thank you so much for all your help!

0 Likes
1 Solution

Hi OmAb_4672891​,

MiniProg4 can be used as UART - USB Bridge. It is working at my end. Make sure you have the following connections:

1. Gnd of MiniProg4 - Ground of PSoC

2. 6x2 Connector (RX Pin) to Tx Pin of PSoC

3. Vtarg to PSoC VDD (Optional - If there is no dedicated external supply to PSoC)

Both the software UART component and SCB UART component works with MiniProg4.

If you are using SCB UART, please be aware of the actual data rate displayed in the component. Because Miniprog4 can handle only till 115200. If the actual data rate is more than 115200, adjust oversampling number to achieve the correct baud rate.

You can use printf in PSoC Creator by adding the following code in main.c based on your compiler. Refer PSoC 4 SCB component datasheet​, section Printf() function Usage Model. Remember to include <stdio.h>. Also, make sure you have sufficient heap memory to use printf. Increase heap using the systems tab in PSoC Creator.

Both the software UART component and SCB UART component works with printf.

Useful Reference: CE224431 PSoC 4 UART printf

Regards,

Bragadeesh

Regards,
Bragadeesh

View solution in original post

0 Likes
3 Replies
VenkataD_41
Moderator
Moderator
Moderator
750 replies posted 500 replies posted 250 solutions authored

Hi,

>>"To remedy this, we connected the UART_TX pin in our code to the receive pin on the miniprog4 and we are receiving garbage characters on putty."

--> Please check the BAUD rate in your terminal software. Set it according to your project settings.

>>"Does data travel through the SWDIO and SWDCLK on the minprog4?"

--> The I2C/SPI/UART communication happens only through 12 pin port of the Miniprog 3. Please refer page number 12 of the Miniprog 4 user guide from the link below:

https://www.cypress.com/file/452836/download

>>"Is there a way to send UART data strictly from the minprog4?"

--> Could you please elaborate this? Miniprog 4 can only be used as a USB bridge between devices. And the procedure that you mentioned as remedy is correct and it should work.

Thanks

Ganesh

0 Likes

Hi Ganesh,

We've tried this and my output is still garbage characters on putty despite making sure baudrates are equal. I'm curious, is there a way to just printf data to the console on Psoc Creator or output it to a file to read somewhere? That would solve my issue

0 Likes

Hi OmAb_4672891​,

MiniProg4 can be used as UART - USB Bridge. It is working at my end. Make sure you have the following connections:

1. Gnd of MiniProg4 - Ground of PSoC

2. 6x2 Connector (RX Pin) to Tx Pin of PSoC

3. Vtarg to PSoC VDD (Optional - If there is no dedicated external supply to PSoC)

Both the software UART component and SCB UART component works with MiniProg4.

If you are using SCB UART, please be aware of the actual data rate displayed in the component. Because Miniprog4 can handle only till 115200. If the actual data rate is more than 115200, adjust oversampling number to achieve the correct baud rate.

You can use printf in PSoC Creator by adding the following code in main.c based on your compiler. Refer PSoC 4 SCB component datasheet​, section Printf() function Usage Model. Remember to include <stdio.h>. Also, make sure you have sufficient heap memory to use printf. Increase heap using the systems tab in PSoC Creator.

Both the software UART component and SCB UART component works with printf.

Useful Reference: CE224431 PSoC 4 UART printf

Regards,

Bragadeesh

Regards,
Bragadeesh
0 Likes