PSOC 4 UART

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

cross mob
Anonymous
Not applicable

Im very new to PSOC. Please advice.. Thanks.

   

May i know how to configure UART Parity bit  in the software during runtime? 

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

Welcome in the forum.

   

Datasheet for UART v2.50 states in configure dialog

   

API control enabled
This check box is used to change parity by using the control register and the UART_WriteControlRegister() function. The parity type can be dynamically changed between bytes without disrupting UART operation if this option selected, but the component uses more resources.

   

The UART_WriteControlRegister() API is used to change the parity.

   

The SCB based UART v3.20 uses a different approach: here you need to re-initialize the component using SCB_UartInit(). See datasheet.

   

 

   

Bob

0 Likes
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

Hi Bob,

   

I am using SCB based UART:

   

include code file.

   

baud rate is working but parity giving error.. check and provide your input on this

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

Can you please post your complete project, so that we all can have a look at all of your settings. To do so, use
Creator->File->Create Workspace Bundle (minimal)
and attach the resulting file.

   

 

   

Bob

0 Likes
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

Hi bob, 

   

Your previous input helped me to understand how to change baudrate, parity and stop bits. Please find function to change these parameters, It may help others. please review it. sorry bob since it is company product. I cant upload complete project.

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

Isolate your UART into a new project and show the error. This demo you can upload.

   

 

   

Bob

0 Likes