USB to SPI

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

cross mob
Anonymous
Not applicable

Hi All

   

My first post and I hope this is the right section.

   

I'm using a CY3209 Dev Board designing a USB to SPI interface bridge. I programmed CY8C24894 to be my SPIM and CY8C29666 as my SPIS.

   

After a few questions with the technical team, I had a project example from this link: http://www.cypress.com/?rID=34330. I cloned this project but selected the chipsets that I will be using accordingly. Additionally, I routed a few of the onboard LEDs to the MOSI/MISO,SS and SCLK signal bus so that I would be able to know that data is transferring between the master and slave.

   

However, as I'm not very strong in my C program, I'm not too sure of what modifications I had to make in order for it to work proper. As a result, using the software provided in the link, USB to SPI.exe, I am unable to get the results as indicated in the pdf that came with the link too.

   

Attached in the zip file is my screenshot and program.

   

Looking at the main.c file of the SPIM, i spotted this syntax which assigns the Slave Select to a register for CY8C24894. Under the comments, the slave select pin is P0[2]. However, on the schematic of the CY8C24894, Slave Select pin is P0[7] instead.

   

//Set the SlaveSelect pin P0[2] to high.
    //(Since SlaveSelect is Active Low)
    PRT0DR |= SLAVE_SELECT;

   

What needs to be changed for this?

   

Is there anything else that I need to take note or possibly a good reference that I can used?

   

Thank you!

0 Likes
1 Reply
MR_41
Employee
Employee
First like received

I dont see the attachments in your post.  Can you attach them?

   

 

   

Best Regards,

   

Ganesh

   

The PSoC Hacker

0 Likes