UART between PSOC3 and PSOC1

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

cross mob
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

Helo,

   

I'm trying to configure UART between PSOC3 and PSOC1. I'm new and I don't know where I make misteake. I would make fullduplex communication (in my example I want to send data from PSOc3 to PSOC1). Have you got some examples of this kind of UART?  I atach my files.

0 Likes
9 Replies
ETRO_SSN583
Level 9
Level 9
250 likes received 100 sign-ins 5 likes given

Both PSOC 1 and PSOC 3 have example UART programs you can use.

   

 

   

In Creator, "File", "Example Project"

   

 

   

In Designer, "Design Catalog" on opening page, then "Launch Example Project" link.

   

 

   

Regards, Dana.

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Most common mistakes are

   

- Baud rate setting / required clock

   

- interrupts not enabled and using functions that requires ints

   

- connection

   

- not or wrong status checking before read / write

   

When you have got a logic analyzer or a skope you could check out everything for yourself.

   

 

   

Bob

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Looks like baud rates do not match: PSoC1 600bd PSoC3 9600Bd

   

24MHz / 8 / 16 / 39 / 8 = ~ 600

   

Bob

0 Likes
Anonymous
Not applicable

VC3 Source is VC1 and this 24MHz/8/39 = ~9600

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Ooops, overlooked.

   

 

   

Bob

0 Likes
ETRO_SSN583
Level 9
Level 9
250 likes received 100 sign-ins 5 likes given

You have Rx and Tx swapped between the two PSOCs ?

   

Both at TTL or RS232 levels, not one at TTL, the other

   

at RS232 level ?

   

 

   

Regards, Dana.

0 Likes
Anonymous
Not applicable

Yes, I swapped TX and RX and both are TTL levels,

   

Luke

0 Likes
HeLi_263931
Level 8
Level 8
100 solutions authored 50 solutions authored 25 solutions authored

Are you able to get both (PSoC3 and PSoC1) to talk properly with your PC stand-alone? That way you can find out whether one of the boards is at fault, or if its the connection.

   

Also, look at the signals with a scope or logic analyzer, to check that everything is as expected.

0 Likes
ETRO_SSN583
Level 9
Level 9
250 likes received 100 sign-ins 5 likes given

I am sure you have though of these -

   

 

   

1) With scope look at bit time on each Tx side to see it is what you expected.

   

Same for drive levels.

   

2) Tx configed as strong drive output, initial state "1".

   

3) Rx configed as input, Hi Z digital.

   

4) 3 wire cable, grounds connected, Tx to Rx, Rx to Tx.

   

5) Clocks auto started in clocks tab of cydwr workspace view

   

6) Vdd both sides of link same. eg. output levels both at 5V or 3.3 V

   

7) Components and ISRs on each side started.

   

😎 Boot.tpl in root directory PSOC 1 modified ISR vector table for

   

digital block UART is in, if using interrupts.

   

 

   

    

   

          

   

http://www.cypress.com/?id=4&rID=36720

   

http://www.planetpsoc.com/psoc1-articles-digital/13-basics-of-psoc-gpio.html?start=6

   

http://www.planetpsoc.com/psoc1-articles-analog/57-psoc-1-adcs--the-five-golden-rules.html

   

http://www.planetpsoc.com/component/content/article/43-writing-a-c-isr.html

   

 

   

 

   

9) Global interrupts enabled both sides.

   

 

   

Regards, Dana.

0 Likes