Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

SPI on a perfboard.

Status
Not open for further replies.
Hello and thanks always.

I am building a system using SPI. I have implemented several configurations on a breadboard and they work great. I use the following boards (sorry in japanese) that are basically fancy versions of the PIC 18F4553 and 18F2553.

https://akizukidenshi.com/catalog/g/gK-06720/

https://akizukidenshi.com/catalog/g/gK-08010/

I also use a simple PIC 18F2550

The problem is when I tried to put this configuration on a perfboard, they fail. In one case they transmit correct characters sometimes and incorrect other times. In the other case the slave only transmits 0xFF.

I have checked and double checked. The connections are ok. The programs work (on the breadboard that is) correctly. I have run out of ideas of what could be wrong.

cap3.jpg
I know it is a mess of cables but I ve originally neat thin lead cables on the back but they didn't work so I ve tried these cables...

Any, and I mean any ideas that can give me some light are welcomed. Need some help here.
 
hi KR,
Do you have a circuit diagram that you could post.?

This is a diagram of the 18F2550, SPI project that I use, works OK.

E
 

Attachments

  • AAesp01.gif
    AAesp01.gif
    16.9 KB · Views: 231
Thanks for the post
Here you are
View attachment 93958
This schematic works perfect on a breadboard btw.
Wait, you said it does not work on a breadboard as in your picture with long wires, so which is it, it works or not? Do you mean it works if you run a simulation? I am having trouble viewing your schematic.
 
I don't see much in the way of power supply decoupling there, maybe try adding a few 10uF and 100nF caps across the supply pins to your modules?
 
Wait, you said it does not work on a breadboard as in your picture with long wires, so which is it, it works or not? Do you mean it works if you run a simulation? I am having trouble viewing your schematic.
Thank you fro the reply

It works without problems on a breadboard.

It does not work on a perfboard (as in the picture)

No simulation performed.
ummmm I see the pic gets too small... how about this?
SPI2cotro.jpg
 
Could you explain this to me please?... you dont mean caps between 5V and ground, do you?

That's exactly what I mean. Now that I have looked again at a close up of the photo you posted, I can see that you have fitted 100nF caps across the supply pins, try adding say a 10uF cap right beside each of them. Also, keep your inter-connect wiring short.
 
On any of your pic's I would not let the PGM pin float , check the data sheet .... did you have to cut any tracks on this board or is it just pads ?
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top