PSoC™ 4 Forum Discussions
I'm trying to use an SPI master interface on a project with a CYBLE-022001-00. Using PSoC Creator 4.1, the only SPI block available is V4.0.
The example provided uses V2.5, which apparently has a completely different API.
Because of pinout issues, I have to use firmware-driven slave selects, and I need to determine when the transfer is complete so I can release the slave select. I only need to send data out, no need for anything coming back.
The examples and all the discussions I can find here all refer to using SPI_ReadTxStatus(), but that's not available with the V4.0 API.
Basically, I need to do this (from other threads on this board):
SS_Write(0); //SS low --> Communication between Master and Slave starts
SPI_WriteTxData(value); /* Send data byte */
while (!(SPI_ReadTxStatus() & SPI_STS_SPI_DONE));
SS_Write(1); // Transfer to slave is done
The problem is that SPIM_ReadTxStatus() no longer exists.
How do you check the transmit status with the V4.0 API?
I've tried using the
SPI_SpiUartWriteTxData(value);
while (!SPI_SpiIsBusBusy()); // wait for transfer to start
while (SPI_SpiIsBusBusy()); // wait for transfer to end
SS_Write(1); // Transfer to slave is done
but it occasionally hangs on the first while - if the timer interrupt routine happens to fall while it's in that loop, then by the time it comes back from the ISR, the entire transfer is over so the SPI bus is not busy again - forever!
I don't want to disable interrupts for that period because it can be up to 2 SCLK clocks after you write data before the , according to the data sheet for the SCB:
"SPI Master does not assign slave select line immediately after the first word is written into TX FIFO. It takes up to 2 SCLK clocks to assign slave select. Until this happens the bus considered not busy."
Any insights would be greatly appreciated!
Show LessI have a sensor which has I2C interface. I want it to communicate with CY8CKIT-042-BLE. At the same time, I want to debug it through the UART interface (send data of sensor to a computer). As a greenhand, I appreciate that somebody provides similar example codes for learning .Thanks
Show LessI am new to PSoC. I have the Pioneer Kit (which has CY8C4247LQI-BL483), and PSoC creator 4.1. I want to use the DMA to transfer data to a peripheral. So I loaded the example CE97088 to test. I got error "Pin guidance unavailable: Resource limit: Maximum number of DMA Channels exceeded (max=0, needed=1)." when I tried to compile it. Can anyone let me know what this problem is and how I can fix it? Thanks
Show LessHello.
I want to know about CapSense Smart-Sense.
Question:
How is the threshold parameters define based on Smart-Sense?
For example, do threshold depends on Diffcounts in first scan?
Best regards,
Show LessI am trying to route SPI pins (2.2, 2.1, 2.0) to pins (2.7, 2.6, 2.5) through SmartIO.
After routing pins, I am getting signals both at (2.7, 2.6, 2.5) and (2.2, 2.1, 2.0). I want signals output only at (2.7, 2.6, 2.5) and I want to use 2.2,2.1,2.0 for other purposes. Is it possible in Cypress PSOC4-041XX kit?
I am using the configuration as shown below. I am getting spi clk both at 2.7 as well as 2.2, why is that so?
Show LessHello, I am using CY8CKIT-037 and I am trying to understand about Phase Current Detecting and Processing Circuit, in this I have found that the gain of the op amp mathly and simulating is 5, but in the code Sensorless FOC is 10000/2400 is meaning 4.166.... Why does this happen?. Are values wrong in the schematic presented in CY8CKIT-037 PSoC4 Motor Control Evaluation Kit Guide in the Figure 4-6 called Current Detecting and Processing Circuit? Thanks.
Show LessI just upgraded to the PSoc Creator 4.1. Now, every time I start Creator, I get the dialog "Keil PK51 Registration" (attached). I don't use the Keil compiler - I just want this message to go away.
I can dismiss the dialog, but it comes back on next start of Creator.
Any ideas?
Show Less
...or I can't find them anyway. I am using Creator 4.1 and installed the CY8CKIT-049-42xx Kit Only (Kit Design Files, Documentation, Examples) as I have been using Creator for awhile and did not need it re-installed. I was expecting to find the SCB_Bootloader.cywrk workspace somewhere but have not been able to find where it might be. It does not appear in the Start Page -> Kits where I would expect it per the kit user's guide and video on the PSoC 4 CY8CKIT-049 Prototyping Kits page.
There is a Bootloader and Bootloadable in the File->Code Examples dialog in Creator but there is no "Bootloadable Blinking LED" example anywhere to be found. I am starting a class in Embedded Systems at my workplace and would like to use the PSoC 4 based kit as an affordable and much more powerful alternative to the Arduino but this is a major stumbling block as I design my lectures. The documentation and video for this kit do not match Creator 4.1 and the examples can't be found.
Please help!
Show LessHello,
I am trying to read 2 analog sensors with ADC and send the information out via BLE. The BLE is detected, but cannot connect. Interesting enough, the moment I remove the ADC component from the design, the BLE is connected successfully. I have tried with 2 separate modules. I suspect that something in my project is not quite right, so I need help.
Attached is the project.
I have tried the Cypress CySmart app to connect to it - no connection. I have downloaded the heart rate example code and compiled it, run and try to connect with CySmart - no connection. In both cases the CySmart does detect the BLE module. I have tried Samsun tablet and phone (with CySmart app and my app), and Iphone with the CySmart app.
Any help will be much appreciated!
Thanks,
Stoyan
Show LessHello guys,
i would like to forward my debug out to a unencrypted unauthenticated Bluetooth serial port. I would like to know if it's possible and maybe there is some documentation about it?
Thank you very much,
Daniel
Show Less