capsense, uart not opearble together

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

cross mob
saurabh
Level 3
Level 3
50 sign-ins 25 sign-ins 10 replies posted

Hello,

I have been trying to integrate uart and capsense touch functionalities in CY8C 4245 AXI 483 MCU. Everything worked fine until working on individual function but as I merged the UART and CapSense in single project, an issue popped up such as UART stopped receiving data. I am unable to find the issue. Can anyone helpe me/ suggest me a solution..?

0 Likes
1 Solution
ncbs
Moderator
Moderator
Moderator
500 replies posted 50 likes received 250 sign-ins

Hi @saurabh,

UART component is working perfectly --> whenever there is any character/string sent, the same gets communicated back.

However, I observe that there are no CapSense widgets defined in the CapSense CSD widget:

ncbs_0-1620281516234.png

To define a widget, click the required widget in the left pane (buttons, linear sliders, radial sliders, etc) and then click on the "Add <widget>" button at the top.

Example: to define a linear slider: click on "linear sliders" in the left pane, and then "add linear slider"

ncbs_1-1620281845836.png

Regards,
Nikhil

 

View solution in original post

4 Replies
ncbs
Moderator
Moderator
Moderator
500 replies posted 50 likes received 250 sign-ins

Hi @saurabh,

Could you share your project or the section of code that has the UART and CapSense functions being used?

If both are working individually, then I suspect the usage of functions may be the problem in the combined project.

You may use the below as a reference:

int main(void)
{
CyGlobalIntEnable;
UART_Start();
CapSense_Start();
UART_UartPutString("\rStart of the application\n");

for(;;)
{
/* Place your application code here. */
if( !CapSense_IsBusy())
{
CapSense_ProcessAllWidgets();


UART_UartPutString("can send information");
//can receive data from uart too

//other implementations

CapSense_ScanAllWidgets();
}
}
}

 

Regards,
Nikhil

0 Likes
lock attach
Attachments are accessible only for community members.
saurabh
Level 3
Level 3
50 sign-ins 25 sign-ins 10 replies posted

Hello @ncbs 

Thanks for sharing the reference code. PFA the project in which I have implemented the capsense and uart altogether. Still facing the similar issue.

0 Likes
ncbs
Moderator
Moderator
Moderator
500 replies posted 50 likes received 250 sign-ins

Hi @saurabh,

UART component is working perfectly --> whenever there is any character/string sent, the same gets communicated back.

However, I observe that there are no CapSense widgets defined in the CapSense CSD widget:

ncbs_0-1620281516234.png

To define a widget, click the required widget in the left pane (buttons, linear sliders, radial sliders, etc) and then click on the "Add <widget>" button at the top.

Example: to define a linear slider: click on "linear sliders" in the left pane, and then "add linear slider"

ncbs_1-1620281845836.png

Regards,
Nikhil

 

saurabh
Level 3
Level 3
50 sign-ins 25 sign-ins 10 replies posted

Hello @ncbs  (Nikihl), 

Thanks a lot for the suggestion, the problem was with the terminal which I had been using to transmit string. It caused garbage data transmission and hence the same was getting echoed. Both the functionalities are working fine. 

0 Likes