Electronic Basics #36: SPI and how to use it

332,114
0
Published 2018-09-02
$2 for 10 PCBs (10cm*10cm): jlcpcb.com/
Previous video:    • DIY Adjustable Constant Load (Current...  
Electronic Basics #19: I2C and how to use it:    • Electronic Basics #19: I2C and how to...  
Facebook: www.facebook.com/greatscottlab
Twitter: twitter.com/GreatScottLab
Support me for more videos: www.patreon.com/GreatScott?ty=h

Websites which were shown in the video:
www.maximintegrated.com/en/products/digital/real-t…
datasheets.maximintegrated.com/en/ds/DS3234.pdf
arduino.stackexchange.com/questions/16348/how-do-y…
github.com/sparkfun/DeadOn_RTC/blob/v1.1/Libraries…
learn.sparkfun.com/tutorials/deadon-rtc-breakout-h…

In this Electronic Basics episode I will present you the most important facts about the communication protocol SPI and how we can use it with an Arduino and an RTC IC.

Thanks to JLCPCB for sponsoring this video
Visit jlcpcb.com/ to get professional PCBs for low prices

Music:
2011 Lookalike by Bartlebeats
Ecstatic Wave, Jens Kiilstofte
machinimasound.com/music

All Comments (21)
  • @northshorepx
    Fantastic. It was very good to see just enough detail so that it wasn't overloading my brain. The timing wave diagrams made everything so clear especially the modes. Thank you.
  • @thomaslsr6847
    That's incredible, everytime I discover a new thing needed for my project, you got a video about the subject :)
  • @davewreski6900
    You have made the things I did not understand much clearer and I now do understand more than I ever have before. You are GREAT ! Thank you so much. I am looking forward to seeing more of your hard work. Also, I will be ordering some PCB's from your link.
  • @digitART30
    Nicely done Scott, thank you again for your dedication and time spent to share your knowledges, best wishes from Spain 🇪🇸
  • @nagarajnagu
    Really you are doing very good job. You are inspiring many minds to be creative. As always stay creative. Thank you Scott
  • @tpendletonYT
    Thank you for another great video. I learn something new every time I watch one of your videos.
  • @minotodorov4144
    Super high quality explanation. Clear and concise. I loved the way you presented.
  • Thanks GreatScott! This video helps me a lot to understand how spi works. As always your videos are awesome...
  • Nice Demo of the programming side. A few notes though: 1.) The AVR hardware SPI "SS" pin is used to turn the AVR into a slave device on a bus. Use any other available I/O pin for Selecting peripheral hardware on the SPI bus. 2.) While I haven't played with the DS3234, I have been goofing around with the DS3231 as I have found them for a good bit cheaper. These RTC's are the best because they are temperature compensated. IIRC There is a small heating element inside the IC that keeps the temperature a few degrees above ambient. The cool part about this is that there is a temperature sensor built into the chip. This temperature sensor reading is available too! There are several different libraries available on the Arduino IDE Lib-Manager that make the temp reading available. I forget which one I used to get the temperature reading working, and I'm not in my main comp ATM, but it does work using one of them. 3.) Temperature compensation makes these RTC's much better than the cheaper DS1302 (which was only designed for charging NiCd batteries with a cheap timer), or the DS1307. These other chips are extremely common with Ardy1 tutorials, but they are really bad at keeping time long term. 4.) Anyone found a better deal on DS3231's or similar than $0.90 each (AliEx) for breakout boards in single/low quantities? I'm more interested in the chip itself instead of BO's but ATM it's cheaper for me to use a BO. -Jake PS On the off chance that Jeremy actually reads this. If you recall from your English classes, "Read" is one of the unusual words in English. Read in the present tense is pronounced like reed, but in the past tense is pronounced "red." It really doesn't matter. I couldn't care less if you change, but if I were on the other side of this, I would want to know ;)
  • @terrymaker4781
    Great. Description on SPI! I have a number of projects that need SPI but I have been putting off. With this amount of detail I can finally try my hand at this useful protocol. Thanks for another great video! I always look forward to your next. ☑️😋
  • Excellent video. You just came right in time, as I started playing with SPI devices recently. Thanks to you, all is much clearer now :)
  • Love the detail you when into!! More videos like this please!!! Love your videos !!
  • @Mat2095
    "the datasheet spoiled the surprise" I just love your humor!
  • Gosh I love these videos but it's always the programming that holds me up. More videos on programming please!!
  • @bobharrison9620
    And I don't know though Arduino was difficult already. I should have studied more in High school 45 years ago. You are scary smart. Thanks Bob
  • @henryswan1374
    scott, you're one of my heros, i learned so much from your videos.
  • @ukesharyal
    Finally got it on sunday . Waited for your video every week .