- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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.
- Labels:
-
PSoC 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Looks like baud rates do not match: PSoC1 600bd PSoC3 9600Bd
24MHz / 8 / 16 / 39 / 8 = ~ 600
Bob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
VC3 Source is VC1 and this 24MHz/8/39 = ~9600
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ooops, overlooked.
Bob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, I swapped TX and RX and both are TTL levels,
Luke
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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.