Discussion in "PIC Microcontroller Discussion" started by    PrabakarDeva    Oct 24, 2013.
Thu Oct 24 2013, 11:08 am
#1
Can u tell me the major diff between uart and spi
Thu Oct 24 2013, 03:21 pm
#2
They both are different hardware peripherals thats the biggest difference. If you are looking for list of differences then here are some:
1. UART is one to one communication where as SPI is a bus protocol with multi-device Master-slave configuration
2. UART is two wire SPI is 4/3 wire
3. UART is asynchronous, SPI is synchronous
4. UART is slower than SPI
5. UART Data transfer is limited to 9bits at a time where as SPI can go for higher word size per transmission
6. UART communication can be initiated by either connected device, SPI can only be initiated by Master device.

If you have doubts, feel free to post again
 PrabakarDeva like this.
Mon Oct 28 2013, 03:41 pm
#3
Thank u so much...i had started to learn spi....i had finished that now...i had written a program to check the spi transmission was completed or not...i was connected the led at the spi output pin(SDO)...I don't know that am i doing right or not?can u tell me?
Tue Oct 29 2013, 01:05 pm
#4
Which controller are you working on. You can connect Led on data pin, but due to fast data transfer you will barely see the LED glowing.
Wed Oct 30 2013, 09:40 am
#5
I am using Pic 16F877A controller.I didn't connect the led directly to the data pin.i connected led through shift register to the data pin.Is that way correct?
Wed Oct 30 2013, 09:47 am
#6
Better attach your schematic here.
Thu Dec 12 2013, 10:01 am
#7
this is the schematic which i tried spi code using proteus....

Sat Dec 14 2013, 03:34 am
#8
I'm not 100% sure what you are doing, but in Proteus use the oscilloscope.
Connect the scope to the SPI output, it can capture trains of pulses to see exactly what is happening.
Add a 1k pullup just in case the pin is floating part of the time.

Get Social

Information

Powered by e107 Forum System

Downloads

Comments

Robertgurse
Wed Apr 24 2024, 02:43 pm
Richardedils
Wed Apr 24 2024, 04:07 am
ChrisLub
Tue Apr 23 2024, 05:21 pm
Davidbab
Tue Apr 23 2024, 10:41 am
Richardrit
Tue Apr 23 2024, 09:54 am
HenryLaf
Mon Apr 22 2024, 03:50 pm
bleradrar
Mon Apr 22 2024, 06:38 am
ppu-pro_ka
Sun Apr 21 2024, 07:39 pm