PSoC™ 4 Forum Discussions
I am using CY8C4025AZI-S413 with PSoC4 and PSoC 4000S series microcontroller.
I have chosen SCB mode as UART , enabled receive interrupt in ISR routine
Please refer following program :
/* ========================================
*
* Copyright YOUR COMPANY, THE YEAR
* All Rights Reserved
* UNPUBLISHED, LICENSED SOFTWARE.
*
* CONFIDENTIAL AND PROPRIETARY INFORMATION
* WHICH IS THE PROPERTY OF your company.
*
* ========================================
*/
#include "project.h"
volatile uint8 gb_char = 0;
volatile char flag = 0 ;
CY_ISR(Uart_Rx_Interrupt)
{
gb_char = UART_UartGetChar();
if(gb_char == 0x23)
{
flag = 1;
UART_SpiUartWriteTxData(gb_char);
}
}
void Uart_Initialize (void)
{
UART_Start();
Uart_isr_StartEx(Uart_Rx_Interrupt);
}
int main(void)
{
CyGlobalIntEnable; /* Enable global interrupts. */
/* Place your initialization/startup code here (e.g. MyInst_Start()) */
Uart_Initialize();
for(;;)
{
/* Place your application code here. */
if(flag == 1)
{
led17_Write(1);
}
if(flag == 0)
{
led17_Write(0);
}
}
}
/* [] END OF FILE */
Output:
Flag is not checked and led on off is not functioning , what should I do?
Show LessAll,
How can I enable/disable an input pin in software? I am using a scb configured as a UART component with the TX pin connected through a 1K resistor to the RX pin and then connected to a bidirectional one wire device. The problem I have is I want to disable the RX pin while transmitting data. How can I do this in software? The device I am using is CY8C4025LQI-S411. Any help would be greatly appreciated!!!
Thanks,
Eric
Show LessWe would like to use Random static address and tried to use below code:
char_t buffer[DEVICE_ADV_NAME] = {0};
CYBLE_GAP_BD_ADDR_T localAddr;
// Generate a random static address
CyBle_GapGenerateDeviceAddress(&localAddr, CYBLE_GAP_RANDOM_STATIC_ADDR, NULL);
// Set the device address
CyBle_SetDeviceAddress(&localAddr);
CyBle_GapSetIdAddress(&localAddr);
// Change the address type in the discovery parameters
cyBle_discoveryParam.ownAddrType = CYBLE_GAP_ADDR_TYPE_RANDOM;
We now see that the address change from the public static address to random static address but when we try it on two different devices we get the
same address C0:49:29:19:95:80
is the BLE random generator not random? is done init of the BLE random generator needed with a seed to generate pseudo random addresses?
We use BLE 4100 chipset. tested with BLE 3.10 and 3.54 components.
Show LessI am using the PSoc 4M -Series Prototyping Kit. CY8CKIT-043
I am creating a solution which involves the generation of a waveform (GPIO output) that can be used to trigger older hardware light controllers.
I have decoded the old signal and discovered that there are 2 unique Periods with 3 different duty cycles.
I have discovered that the CyDelayUs() is not providing me with the microsecond resolution that is required. An associate mentioned that I should make use of the PWM components in the library. Brought in the PWM component and setup the period and the CMP value 1. Loaded the application and the PWM component generated a repeatable and very accurate pulse.
My goal was then to expand the design so that control when the signal generation occurred. There is an option on the PWM component to use the "one shot with multi trigger mode". I added in a control register block that would send a direct pulse to the PWM block.
I have been unable to get the one shot trigger working. The PWM_Start() block has been called in main.c, the control register block is called with a value of 255 (all the bits) and the interrupt that I have attached in the PWM component never hits.
Does anyone else have any ideas for a solution.
Thanks in advance.
Show LessHello,
I'm trying to follow "Pairing and Bonding with a Fixed Passkey" in document "EZ-Serial BLE Firmware Platform User Guide".
I'm stuck when I get error response for command SSBP:
TX-> SFPK,P=1E240
RX-> @E,000B,ERR,E=0203
I tried setting this on peripheral and central side and I tried calling it when connected to a remote peer device and when CYSPP is not running.
Is there any specific configuration I should set before calling this command?
Is there any description of error codes available?
Show Less
For Those of You About to Make – We Salute You
MAKEMIT is an engineering makeathon that brings together over 250 students who are passionate about designing and building. Across 18+ hours, groups of makers work together to develop an idea and materialize it through the engineering design process. The event begins at 7 AM on Saturday Feb. 22 and ends at 12:30 PM On Sunday Feb. 23.
Cypress is sponsoring this event by donating PSoC 4 BLE and PSoC 5 development kits. We are sharing resources in the community to help attendees prepare and to engage our other community members. Participation in the event is open to all undergraduate students. Complete details are available on the MAKEMIT website .
We have created a thread on the Cypress community “Event: MakeMIT 2020 Q and A” This thread will be monitored by Cypress technical volunteers 8:30 AM to 11:59 PM Feb. 22 and 7:00 AM until 10:00 AM Feb. 23 2020 (EST). All members of the greater Cypress community who wish to ask questions or help with technical support are welcome to participate.
Schedule:
Saturday February 22
7:00 AM Venue opens
8:30 AM Hacking begins
11:59 AM Hacking Pauses
Sunday February 23
7:00 AM Hacking begins
10:00 AM Hacking ends
10:00 until 11:30 AM Judging
11:30 AM Top teams present
12:00 PM Winners Announced!
We will post some of the top hacks on Cypress social media and in this blog.
C. U. A. round
Patrick
Show LessHi i want to interface the 2.4" TFT display interface with psoc 4 Microcontroller . Display driver is ST7789V. please share some reference code or any basic code to start with.
thanks in advance .
regards
Rajakumar
Show Less