PSoC™ 5, 3 & 1 Forum Discussions
Hi!
I have a custom board that uses USB and an external oscillator and I'm trying to get it working with the USB clock set up. When I debug it I see that it gets stuck in the CyClockStartupError function. I know the oscillator works because I scoped it and saw a good signal and I tried a blank project that just had the clock enabled and it initalized fine. From that I think it must be the way I'm adding the USB clock. Attached is my project. Any suggestion will be appreciated!
Thanks!
Show LessHi there,
Below is the code that I have got from sample example and modified as I require, but I am not able to get current time. Every time I read time after current time and some delay, it still reads the value that I have set to. So, what should I do to read current time and date ?
int main()
{
int second,minute,hour = 0;
int day,month,year = 0;
RTC_TIME_DATE Start;
/* Fill struct with date and time */
Start.Sec = 55u;
Start.Min = 55u;
Start.Hour = 13u;
Start.DayOfMonth = 7u;
Start.Month = 7u;
Start.Year = 2015u;
CyGlobalIntEnable;
RTC_WriteTime(&Start);
RTC_Start();
CyDelay(10000);
second = RTC_ReadSecond();
minute = RTC_ReadMinute();
hour = RTC_ReadHour();
day = RTC_ReadDayOfMonth();
month = RTC_ReadMonth();
year = RTC_ReadYear();
UART_PutString("Time: ");
UART_PutString(itoa(hour,10));
UART_PutString(":");
UART_PutString(itoa(minute,10));
UART_PutString(":");
UART_PutString(itoa(second,10));
UART_PutString("\nDate: ");
UART_PutString(itoa(day,10));
UART_PutString("-");
UART_PutString(itoa(month,10));
UART_PutString("-");
UART_PutString(itoa(year,10));
}
Show LessI would like to use DMA to send data to a simple 32-bit SPI DataPath but the problem is that F0 FIFO of my DataPath is not detecting when DMA sends data to it when Datapath width is 32 bits. It worked fine with 8-bit and 16-bit DataPath.
Can you please advise?
Following is what I got so far.
I started with project DMASPI_8bit which worked as expected as shown on image below. The important signals are Ch5 (isFifoEmpty), and Ch6-7 (when DMA completes). They show when data is loaded into FIFO and when DMA completes.
Made a copy of 8bit project to 16bit project and just updated number of bits in DataPath and also the data to send 2 bytes per burst and all worked great as well as shown on following image.
Made a copy of 16-bit project and set DataPath to 32 bits and also updated variables to send 4 bytes per burst but no luck this time.
The following image shows Ch6-7 going high which means DMA completed but Ch5 (isFifoEmpty) signal remains high.
The 32-bit project has additional debug code that I tried. The debug code also does a direct register write to FIFO F0 PTR to verify that FIFO empty signal changes state at that point, but for some reason it just doesn't work the same with DMA.
Show LessHi,
I have a problem with noise. Can check the image that the blue is a sign almost no noise (https://www.dropbox.com/s/ijswxkjcemlxt0m/High%20frequency%20noise%21%21.jpg?dl=0)
The purple is a signal just outside Two Opamp Topology (equal to figure 3 of this article http://www.cypress.com/?docID=41827) with gain = 2.
As you can see the signal have some strange peaks.
They know how I can fix this?
Best regards.
Show LessDoes PSoC 4 BLE wireless module support PSoC 5? if not, is there any wireless module suitable for PSoC5? I would like to realize the function of remote control.
Show LessHi there,
I have gott switch connected to Psoc5 and would like to turn on LED, whenever button is pressed, looking for project how to actually do it. I also would like to implement with debouncing circuit, so not sure how could I do that in cypress.
I tried something like this but doesn't work
#include <device.h>
volatile uint8 switchFlag = 0u;
CY_ISR_PROTO(SW_ISR_Handler);
int main()
{
CyGlobalIntEnable;
Isr_SW2_StartEx(SW_ISR_Handler);
for(;;)
{
if(switchFlag)
{
LED_Write(1);
switchFlag = 0u;
CyDelay(5000);
}
}
}
CY_ISR(SW_ISR_Handler)
{
switchFlag = 1u;
}
Top Design is attached.. If any mistake then let me know.
Any help woud be great .
Thanaks
AK
Show Less