SPI: The serial peripheral interface

  Переглядів 657,330

Ben Eater

Ben Eater

2 роки тому

More 6502 computer info: eater.net/6502
Here's the temperature sensor module used in this video: www.amazon.com/gp/product/B07...
More info on the sensor: tiny.cc/bme280
Support these videos on Patreon: / beneater or eater.net/support for other ways to support.
------------------
Social media:
Website: www.eater.net
Twitter: / ben_eater
Patreon: / beneater
Reddit: / beneater
Special thanks to these supporters for making this video possible:
Aleksey Smolenchuk, Anders Carlsson, Andrew C. Young, Anson VanDoren, Anthanasius, anula, Armin Brauns, Ben, Ben Cochran, Ben Kamens, Ben Williams, Benny Olsson, Bill Cooksey, Binh Tran, Bouke Groenescheij, Bradley Pirtle, Bradley Stach, Brian T Hoover, Bryan Brickman, Burt Humburg, Carlos Ambrozak, Chris, Christian Carter, Christopher Blackmon, Dale Andrew Darling, Daniel Jeppsson, Daniel Tang, Dave Burley, Dave Walter, David Brown, David Clark, David Cox, David Dawkins, David House, David Sastre Medina, David Turner, David Worsham, Dean Bevan, Dean Winger, Dilip Gowda, Dissy, dko, Dmitry Guyvoronsky, Dušan Dželebdžić, Dzevad Trumic, Emilio Mendoza, Eric Dynowski, Erik Broeders, Eugene Bulkin, Evan Thayer, Eveli László, George Miroshnykov, Gonzalo Diaz, Harry McDow, hotwire33, Ingo Eble, Ivan Sorokin, James Capuder, james schaefer, Jared Dziedzic, Jason DeStefano, Jason Specland, JavaXP, Jaxon Ketterman, Jay Binks, Jayne Gabriele, Jeremy, Jeremy Cole, Jesse Miller, Jim Kelly, Jim Knowler, Jim Van Meggelen, Joe Beda, Joe OConnor, Joe Pregracke, Joel Miller, John Fenwick, John Hamberger jn., John Meade, Jon Dugan, Joseph Portaro, Joshua King, Jurģis Brigmanis, Kai Wells, Kefen, Kenneth Christensen, Kitick, Koreo, Lambda GPU Workstations, Larry, László Bácsi, Lucky Resistor, Lukasz Pacholik, Marcos Fujisawa, Marcus Classon, Mark Day, Marko Clemente, Martin Noble, Martin Roth, Mats Fredriksson, Matt Krueger, Matthäus Pawelczyk, Matthew Duphily, Max Gawletta, Maxim Hansen, melvin2001, Michael Tedder, Michael Timbrook, Michael Weitman, Miguel Ríos, mikebad, Mikel Lindsaar, Miles Macchiaroli, Muqeet Mujahid, My Yiddishe Mama, Nicholas Counts, Nicholas Moresco, Not Yet Wise, Örn Arnarson, Paul Pluzhnikov, Paul Randal, Pete Dietl, Phil Dennis, Philip Hofstetter, Phillip Glau, PixelSergey, Porus, ProgrammerDor, Randal Masutani, Randy True, raoulvp, Renaldas Zioma, Ric King, Richard Ertel, Rick Hennigan, Robert Comyn, Robert Diaz, Robey Pointer, Roland Bobek,§çīŤøşHï ŇåĶąýŐbŕÔ, Scott Holmes, Sean Patrick O’Brien, Sergey Kruk, Shelton, SonOfSofaman, Stefan Nesinger, Stefanus Du Toit, Stephen, Stephen Kovalcik, Stephen Riley, Stephen Smithstone, Steve Jones, Tayler Porter, TheWebMachine, Thomas Bruggink, Thomas Eriksen, Tim Walkowski, Tom, Tom Yedwab, Tommaso Palmieri, Tyler Latham, Vincent Bernat, Walter Montalvo, Warren Miller, William, Wim Coekaerts, Wraithan McCarroll, xisente, Yee Lam Wan

КОМЕНТАРІ: 725
@ovalwingnut
@ovalwingnut 2 роки тому
"More valuable than a thousand days of diligent study is one day with a great teacher." --Japanese Proverb
@stoatrepublic
@stoatrepublic 2 роки тому
"Your not wrong." - Norfolk saying...
@ovalwingnut
@ovalwingnut 2 роки тому
@@stoatrepublic Very COoL.. :O) "The Norfolk dialect, also known as Broad Norfolk, is a dialect spoken in the county of Norfolk in England which sits within the broader East Anglian English. While less widely and purely spoken than in its heyday, the dialect and vocabulary can still be heard across the county, with some variations?. Wikipedia
@stoatrepublic
@stoatrepublic 2 роки тому
​@@ovalwingnut I'm Norfolk through'n'through, broadcast across the Norfolk Broads everyday and drive a tractor/lawn mower.
@ovalwingnut
@ovalwingnut 2 роки тому
​@J Hemphill Very COoL.. :O) "You're not wrong" --Sweet Brown -- "Ain't Nobody Got time For That" -- "I got bronchitis ain’t nobody got time for that. Ain’t nobody got time for that Ain’t nobody got time for that Ain’t nobody got time, ain’t nobody got time Ain’t nobody got time for that Well, I woke up to get me a cold pop Then I thought somebody was BBQing (BBQing) (BBQing) I said, “Oh, lord Jesus it’s a fire!” Then I ran out, I didn’t grab no shoes or nothing Jesus I ran for my life Ain’t nobody got time for that Ain’t nobody got time for that Ain’t nobody got time, ain’t nobody got time Ain’t nobody got time for that Ain’t nobody got time for that Ain’t nobody got time for that Ain’t nobody got time, ain’t nobody got time Ain’t nobody got time for that I said, “Oh, lord Jesus it’s a fire.” I said, “Oh, lord Jesus it’s a fire.” I said, “Oh, lord Jesus it’s a fire.” Jesus, Jesus, Jesus, it’s a fire. Ain’t nobody got time for that Ain’t nobody got time for that Ain’t nobody got time, ain’t nobody got time Ain’t nobody got time for that Ain’t nobody got time for that Ain’t nobody got time, ain’t nobody got time Ain’t nobody got time for that" Cheers JH (good one BTW, which is more than I can say for them' lyrics:)
@goyonman9655
@goyonman9655 2 роки тому
I disagree with this saying
@vatterger
@vatterger 2 роки тому
I would just like to point out how god damn clean and user friendly the datasheet of the BME280 is. Timing diagrams annotated with the bit-indices, comprehensible english, a clickable table of contents, using vector graphics for every graphical element. I wish every datasheet was this well made.
@tommyboy1504
@tommyboy1504 2 роки тому
"Comprehensible English" had to chuckle at that one!
@AlexYeryomin
@AlexYeryomin 2 роки тому
I used this little sensor (via I2C though) in my projects, it is quite reliable and precise. I agree, the manual is just beautiful from the software developer's point of view (hopefully, from electronic engineer's one too). They describe whatever you need and you want to know about this sensor in details. A perfect example how it should be done properly.
@josesousa4056
@josesousa4056 2 роки тому
I am working with the AD7771 ADC from analog devices, using the SPI interface. I wish the datasheet was 10% as friendly as the BME280 datasheet is.... Not only regarding the SPI protocol but explaining properly what certain registers do.
@sashimanu
@sashimanu 2 роки тому
The pdf’s all fine and readable, but the damn BME thing heats itself up quite significantly, unlike the el cheapo chinesium DHT sensors.
@vatterger
@vatterger 2 роки тому
@@sashimanu How??? The average current-consumption while measuring at 1Hz is less than 4uA. Max consumption is ~1mA, so it should be literally impossible to heat this thing up if used right. It is a temperature sensor too after all, it isn't allowed to heat itself up by DESIGN. You either got a fake, your wiring is wrong or your GPIOs are set up wrong. Are you disconnecting VDD, but keep the SPI/CS lines powered? (could cause backfeeding through the ESD-diodes) Are you using it at above 3.6 volt?
@soumilparanjpay2731
@soumilparanjpay2731 2 роки тому
I'm an electrical engineering student and I've gotta say you've single-handedly reminded me why I chose my major and revitalized my love for electronics.
@Thirsty_Fox
@Thirsty_Fox 2 роки тому
I'm also a student and feel the same way. School can be rather demotivating, while content like this is inspiring and motivating.
@tommyboy1504
@tommyboy1504 2 роки тому
When I was at school I had no interest in grades or classes whatsoever. It was only until my friend taught me how to solder which was when my interest took off
@omniyambot9876
@omniyambot9876 2 роки тому
Can i ask, is he doing more of electrical/electronics or computer engineering?
@rubiconcrossing4480
@rubiconcrossing4480 2 роки тому
These are genuinely my sentiments as well
@franciscovarela7127
@franciscovarela7127 2 роки тому
I'm just a hobbyist but agree, Ben's videos are always like that.
@nathanrice3890
@nathanrice3890 2 роки тому
This dude is better than a college education and he's free.
@chrisj2848
@chrisj2848 2 роки тому
Sounds like a good reason to join his Patreon!
@rymaples
@rymaples 2 роки тому
I learned 100 times more during his computer build THAN I did getting my BS in Electrical Engineering Technology. His free video explained why in just a few minutes where school just said what. Had to edit my reply because Mr. English Professor called out a misspelling. My misspellings are proportional to how much I've had to drink....
@jamesbromley5820
@jamesbromley5820 2 роки тому
Certainly more practical
@nathanrice3890
@nathanrice3890 2 роки тому
@@rymaples Need to work on your English though... *than
@heh2393
@heh2393 2 роки тому
@@nathanrice3890 My dude this is a UKposts comment, NOT YOUR THESIS!
@bjmarsh09
@bjmarsh09 2 роки тому
I am 80, but your explanation was clear, concise and intellectually satisfying. Congatulations on a superb piece of teaching that I will remember as a classic explanation.
@anonymousarmadillo6589
@anonymousarmadillo6589 2 роки тому
May I ask you what your career was in, Sir?
@marioghioneto1275
@marioghioneto1275 2 роки тому
Gosh I needed an SPI class soooo bad, it came in the best timing ever
@smooooth_
@smooooth_ 2 роки тому
No pun intended
@renakunisaki
@renakunisaki 2 роки тому
That's because Ben controls the clock.
@khatharrmalkavian3306
@khatharrmalkavian3306 2 роки тому
@@renakunisaki Click... Click... Click...
@thomasbonse
@thomasbonse 2 роки тому
@@smooooth_ All puns should be intended. 😉
@TheMixedupstuff
@TheMixedupstuff 2 роки тому
It's rare to see a Ben Eater video where I am very familiar with what he is showcasing. I've written multiple drivers using different HALs for the shown sensor.
@sookmaideek
@sookmaideek 2 роки тому
Good job bro
@Inf1e
@Inf1e 2 роки тому
Plus there. Working with SPI-like interfaces at work.
@sdspivey
@sdspivey 2 роки тому
The HAL9000 is the best, but sometimes a little bit homicidal.
@edinfific2576
@edinfific2576 2 роки тому
@@sdspivey 😁
@EvilSapphireR
@EvilSapphireR 6 місяців тому
Hi. In your HAL were this SPI sensor's temp/pressure registers memory mapped or IO mapped somehow (possibly via an SPI controller) that you could simple read/write to obtain the temp/pressure data? I'm trying to understand how a 'modern' processor on a motherboard talks to SPI chip (like SPI flash memory containing the BIOS). Surely you didn't 'bit bang' like Ben did here inside your driver code?
@johnkaplun9619
@johnkaplun9619 2 роки тому
Just remember this is exactly how engineering really goes. You just follow the datasheet it works the first time perfectly, and you feel rewarded at the end.
@harryjohnson615
@harryjohnson615 2 роки тому
Yeah only it doesn't work first time
@dijkstra4678
@dijkstra4678 Рік тому
STEM students felt that one
@topilinkala1594
@topilinkala1594 10 місяців тому
@@harryjohnson615 Actually sometimes it does and when it does it feels so good. I remeber once we had four day weekend (Easter) to set up a new facility. New system & computers, user accounts etc. We got it running on monday morning and the first test was success. We had 5 men team where I was the one controlling the workflow and checking on the server side that each computer on the network was responding properly. Last thing was to fire the script that made those user accounts and check that they were set up correctly. They were and we were off to celebrate. Had private sauna with food and drink courtesy by the company management. Actually I think I slept four hours during those four days. We postponed the celebration to tuesday and got both tuesday and wednesday off. We also got mighty hefty one time compensation for that work. Felt pretty good.
@chrislawson1233
@chrislawson1233 12 годин тому
Electronics/computer engineering is definitely a career for people who like to read the manual.
@debarjo
@debarjo Рік тому
The biggest plus with Ben Eater's videos is that he has given free access to the murkiest and deeply obfuscated engineering procedures and workflows for the common people. Even if we don't fully grasp them, we know that these notoriously complex workings happening right before our eyes can be tamed with time and effort. No other contributor I have experienced has gone this far, this easily.
@jasperbarnett6819
@jasperbarnett6819 2 роки тому
If only Bosch were as good at keeping their sensors in stock as they are at writing data sheets for their products...
@otheraccount5252
@otheraccount5252 2 роки тому
To be very fair, it has been a pretty hard year for everyone. But yeah, we want hardware!
@lmello009
@lmello009 2 роки тому
brings back EE undergrad memories. the toughest ones, microcontroller lab, assembly, LDA-ing and STA-ing bit by bit just like that. Protocols I forgot, addresses I still remember, funny failure stories... 🤓😅
@Vanders456
@Vanders456 2 роки тому
Literally the only firmware programming I ever did was to write an I2C implementation that could control the LEDs and read the temperature sensor on a network (interconnect) card. We had the prototype cards without the ASIC on them and I ended up bit-banging a parallel port on a desktop PC to implement a (very slow) I2C. The company (Quadrics) went bust a few months later and I never actually got to see my code running from the ASIC, and that was the end of my glorious firmware programming career.
@nikhilwardrobe
@nikhilwardrobe 2 роки тому
what are you doing now? have you left the firmware programinng?
@Vanders456
@Vanders456 2 роки тому
@@nikhilwardrobe Oh yeah, that was an aberration. These days am an SRE, which suits me fine.
@nikhilwardrobe
@nikhilwardrobe 2 роки тому
@@Vanders456 I'm working as intern with designation as embedded firmware developer. I have heard the pay isn't that good. Why did you shifted from firmware to sre and how did you do that?
@wearwolf2500
@wearwolf2500 2 роки тому
I used SPI in my final project for university. We had a microcontroller controlling a series of LED displays. The controller sent the display a byte of data using SPI which the display read as an ASCII character and displayed. The interesting thing is we had the display setup so that whenever they received data they would output their old data and then we daisy-chained displays so each one sent the last character it received onto the next. That way we could control a whole bunch of LED displays with just the one chip select line. The end display would wrap around back to the controller. We used that to allow the controller to figure out how many displays were connected. it would send out zeros for a while to clear out whatever data was in the displays and then send all ones and count how many sends it took to get the ones back. However sends it took was the number of displays attached. While implementing that counting logic I made a mistake in my looping bounds. The counter variable was only a single byte and I told it to loop until that byte was 256 which of course never happened. Made a very interesting strobe effect though. As the displays were constantly being interrupted to transmit and receive data.
@spacejunky4380
@spacejunky4380 2 роки тому
That's super cool! Thanks for the break-down. I'm going to order some bread boards to run some projects a friend told me about
@nathanmiddleton1478
@nathanmiddleton1478 2 роки тому
I was just telling my wife how the USB interface videos were fascinating and fun, this just adds to it. Thanks!
@SystemsPlanet
@SystemsPlanet Рік тому
Your wife? Did she understand? 😆
@Avaryes
@Avaryes 2 роки тому
After only 6 minutes, I feel like I already learned so much
@RaptorTeak
@RaptorTeak 2 роки тому
This was great! Would love follow-up videos on I²C and maybe UART
@liveen
@liveen 2 роки тому
the production value that goes into these videos is pretty insane tbh, it must take a shitton of effort to line up the voice overs, the edits and the script to work how you're doing it. It's all very minimal but ohhhhh so precise and delicate, which kinda fits who you are as a figure on youtube. Kudos to you, Ben, for the work you're putting into the production of these videos
@hygri
@hygri 2 роки тому
Ben you are an absolute institution. I'm a chemist, and closet electrical engineer / low level software engineer and your content is so precisely the right level for my brain it's ridiculous. I mean, I'm a complete amateur and such but your pace, tone and rigour with which you go through the detail is sublime. Hats off to you sir. Not that I wear a hat
@NaTHGamin
@NaTHGamin 2 роки тому
Was just re-studying the breadboard computer, then suddenly this pops up.
@erg0centric
@erg0centric 2 роки тому
Google is watching watch UKposts.
@ykr786
@ykr786 2 роки тому
Ben you're an incredible engineer. You're inspiring an entire generation towards EE or CE
@axelcodr
@axelcodr 2 роки тому
I love the way you explain things, I feel now so confident at school and really feel the hunger to see all old vids too, they are just amazing!
@NickiRusin
@NickiRusin 2 роки тому
This feels like arcane knowledge. Crazy to think how much I don't know or understand about devices that are essential to my well-being. Amazing video, as always!
@omniyambot9876
@omniyambot9876 2 роки тому
You got an absolutely gorgeous and powerful Oscilloscope there!!
@stamasd8500
@stamasd8500 2 роки тому
Yes, I'm drooling for that one also. :)
@byronwatkins2565
@byronwatkins2565 2 роки тому
We might also mention that devices vary about whether MSb or LSb is sent/received first. If all 8 outputs of the decoder is used, you will also need to devote one more pin to selecting/deselecting the decoder; otherwise, one of the eight devices will always be selected. If output 7 is not used, then writing 111 to the decoder will deselect all used devices, however.
@modmen.
@modmen. 2 роки тому
I'm falling to find a reason that it's a bad thing that one will always be selected. If the device needs the clock to start a conversation anyway?
@byronwatkins2565
@byronwatkins2565 2 роки тому
@@modmen. The chip knows the byte is complete only after it is de-selected... You could still select another chip without transferring any data, but some chips don't respond well to that.
@webinno
@webinno 2 роки тому
Please keep making videos like this. You are the reason why I understand this computer thing more deeply if not I don't know what I'm learning. Thank you! Ben.
@OneAndOnlyMe
@OneAndOnlyMe 2 роки тому
Love these explanations! Pretty amazing how responsive that little sensor is.
@tijhevella-verney3609
@tijhevella-verney3609 2 роки тому
I’m not quite sure why, but just seeing this video pop up bought a welcome wave of happiness. Thankyou!
@songworks17
@songworks17 2 роки тому
I don't know why, this seems like an extremely dry topic and yet you manage to explain it well and simple enough and interesting at the same time. Fascinating. Kudos!
@dtech9039
@dtech9039 2 роки тому
Was having some issues with SPI on a sensor for a project I'm currently working on. This video is perfect timing. 👍
@sennabullet
@sennabullet 2 роки тому
I can't thank you enough for this incredibly informative and well produced video. You did a great job to help decrypt the datasheet for me.
@r1273m
@r1273m 2 роки тому
That brought back memories. i used to lecture on 6502, 68xx, 68HC11 etc. I retired 21 years ago last week. I now play with ESP8266/32 to stay out of trouble!
@tinori1838
@tinori1838 2 роки тому
Thank you for this video. I really like the way you are showing stuff, in such a depth that is very good to understand and includes all necessary details to fully understand it.
@elwafi2001
@elwafi2001 2 роки тому
This video summarize 100 hours of lectures, this is really what I’m looking for! very good job. Thumbs up 👍
@yaidontknowwhattoput
@yaidontknowwhattoput 2 роки тому
These protocol videos are fantastic. It is all very visual and the lack of jargon makes it super accessible.
@kaxbyrita9279
@kaxbyrita9279 2 роки тому
These videos of yours, and not only this, are such information gold 💪🏻 Thanks for sharing your knowledge on difficult and complicated things with the world!
@hippynurd
@hippynurd 2 роки тому
I just wanted to say thank you, I have enjoyed your videos about computer basics in the past, and I want you to know that I have really liked them
@gregorymccoy6797
@gregorymccoy6797 2 роки тому
Great video. I use SPI all the time but via libraries. Nice to see it broken out. I appreciate the time and effort it takes to make a video like this.
@ewncilo
@ewncilo 2 роки тому
Thank you for creating more content and sharing more knowledge.
@_emanmodnar
@_emanmodnar 9 місяців тому
It is really educational that you go through how to interpret the data sheets/manuals! I’ve learned a lot about how computers work and coding watching your videos and it makes me interested in learning more ☺️
@thejking
@thejking 2 роки тому
Ben explains everything so incredibly well. Excellent!
@berkehanercan6336
@berkehanercan6336 2 роки тому
Thanks for taking the advice from the Reddit post. There are a lot of people that will appreciate these communication protocol video series.
@erg0centric
@erg0centric 2 роки тому
RS485 next
@rick_er2481
@rick_er2481 2 роки тому
agree, rs485 would be nice!
@Sekhar_Home
@Sekhar_Home 2 роки тому
Never missed a single lecture from ben.. he has immense indepth knowledge.. thanx fr giving
@bveina
@bveina 2 роки тому
Such a great visualization of polarity and phase. And it's wonderful to see the 6502 back in action!
@mikemercury3656
@mikemercury3656 2 роки тому
Very clear presentation covering all the key points.
@MakeDataUseful
@MakeDataUseful 2 роки тому
very clear and well explained as always Ben. Much appreciated.
@WistrelChianti
@WistrelChianti 2 роки тому
Man that scope helped so much with my understanding of the 2 way aspect. Cheers again!
@geekbrah6021
@geekbrah6021 2 роки тому
wow.. every explanation video i watch, there are always these little questions pops in my head and sadly almost everyone leave behind those questions and leaves me clueless about what i have learn... sir you go into every single detail and the same time adding more knowledge and that to me is impressive. i wish i can learn from you someday.. sir you are an exceptional teacher i never had...thank you
@RaphaelBrandaoS
@RaphaelBrandaoS 2 роки тому
What a delightful video. Nothing like a plain simple SPI masterclass from Ben to chill out.
@saumitpradhan6754
@saumitpradhan6754 2 роки тому
I am currently in high school but can easily understand each and every bit of your video, amazing to see how clear are your concepts!!!!
@bozimmerman
@bozimmerman 2 роки тому
Sitting here with the parts to make a USB Host interface to a 6502 computer using a component with an SPI interface. Then I stumble on this channel, and find a video on the SPI interface on a 6502 computer, and the same channel has a video on the USB protocol. Convenient.
@ahmadb.e.k4629
@ahmadb.e.k4629 Місяць тому
Bro ,your explanation is so really clear to understand. Thanks a lot.
@-aaa-aaa
@-aaa-aaa 2 роки тому
23:40 Hello, my name is 6502 Microprocessor, and I like to spiin!
@Thirsty_Fox
@Thirsty_Fox 2 роки тому
Top notch content -- very well done. Thanks!
@therealelizafox
@therealelizafox Рік тому
This has been the best hands-on explanation I’ve seen of SPI, period. Please do one on I2C and UART!
@tooba6290
@tooba6290 2 роки тому
Love these videos.. please don't ever stop uploading
@tinem67
@tinem67 2 місяці тому
Thank you. I was lost with the spi bus but I now have a better understanding.
@Leon-zi2pi
@Leon-zi2pi 2 роки тому
Pretty neat, ive been working on a spi device for the past few weeks. And its nice to get some of the background about it.
@jacobhoward7579
@jacobhoward7579 2 роки тому
Thank you Ben! Putting it in my EE playlist...
@InfiniteBrain
@InfiniteBrain 2 роки тому
Been wanting to try out the new Thanks feature and this seemed like a great video to do just that. Great content. Thanks!
@hypt0ny
@hypt0ny 2 роки тому
Thank you very much for uploading this. All of your series has teached me so much. Again, thank you.
@tamannasharma2435
@tamannasharma2435 2 роки тому
Yeah I needed this now and you just posted . Thanks 😊
@dillbaggins3291
@dillbaggins3291 2 роки тому
Was literally just doing some reading on SPI for uni. Amazing timing
@carriersignal
@carriersignal 2 роки тому
Great explanation! Thank you so much!
@macfeilmeier3230
@macfeilmeier3230 2 роки тому
I spent the last month trying to get a handle on SPI, and a week later this video comes out explaining it better than any other resource I've found....
@CurtWelch
@CurtWelch 2 роки тому
Just yesterday I decided to learn the details of SPI and did some research, and then today, my computer tells me you have the video I want to see! Perfect timing. :)
@erosnemesis
@erosnemesis 2 роки тому
Working as an embedded engineer I absolutely love your videos. I always get ideas from them. Also I'm always reminded to read the freaked manual! Happy coding 😁
@TCraats
@TCraats 2 роки тому
Thanks for the interesting and helpful video! Love it. Your explainations are clear and accurate
@giacomolontra3707
@giacomolontra3707 2 роки тому
Thank you for all your videos. I thought that the world of integrated circuits and boards was dead and gone. You take me back to the early 1980's when I started programming on a 8088 and my VIC 20's 6502 and then the late 80's when I taught the Z80 family to high schoolers. You are doing a brilliant job.
@adumont
@adumont 2 роки тому
Thanks you Ben, another amazing video! I had no idea of how SPI worked, now I feel I understand it!
@stevedonkers9087
@stevedonkers9087 2 роки тому
I've spent the last couple weeks working on getting an SPI SD card reader working.. this is perfect! Thanks! In my research and attempts to get an SD card reader working, I've found that SPI not being completely standard has some issues. As you said in your video the clock, DI and DO lines are common bus lines and CS is individual to the device. Some types of devices do things that are kind of odd. For example when you initialize an SD card reader you send at least 74 clock pulses with CS held high to get it into SPI mode. I'm no expert but I don't think that's a good idea when you want to have multiple devices on the same bus, devices should only respond to anything when their select line is low. It's low risk in this case (if the card reader is on the SPI bus you want it to be in SPI mode) but it just doesn't seem right that an SPI device can be influenced when their CS line is high.
@renakunisaki
@renakunisaki 2 роки тому
SD cards are insane.
@edgeeffect
@edgeeffect 2 роки тому
I had trouble with an SPI chip once.... I never considered that I was maybe using the wrong clock mode.... thanks for the tip! I always do SPI on microcontrollers with a built in SPI port.... very interesting seeing you "go old school" and implementing the interface with bit-banging.... showing us how it REALLY WORKS.
@HectorUch123
@HectorUch123 2 роки тому
Great Video! Thanks for the information !
@AlexYeryomin
@AlexYeryomin 2 роки тому
What a slick advertising of EEV Blog multimeter! :-) Thank you for the video, Ben.
@karlm9584
@karlm9584 2 роки тому
I own this multimeter and Ben needs to update his firmware!
@JeffreySJonas
@JeffreySJonas 5 місяців тому
Most awesome, you correlate a lot there with the scope to prove it.
@louisguy5726
@louisguy5726 2 роки тому
These videos are really great. Im currently studying wjec A-level electronics in UK, you'd be suprised by how little resources are available to revise from. Some of these videos have been super helpful!
@electronic7979
@electronic7979 2 роки тому
Helpful information. Thank you
@JLCPCB
@JLCPCB 2 роки тому
Very deeply explained, and highly informative video! Great job Ben! 😄
@Meal-632
@Meal-632 Рік тому
Thanks dude for your amazing work. 🤩
@AccordionMusicAndMore
@AccordionMusicAndMore 3 місяці тому
Thanks for the nice videos - educational, clear and concise!
@rigov7451
@rigov7451 2 роки тому
I'm just a laymann and I've gotta say you've single-handedly reinforced me why I love (and study) electronics/computer science myself.
@reyrank2846
@reyrank2846 2 місяці тому
This is really awesome! @42 years old, i learned a lot with this man... you're really good...
@quyduong7513
@quyduong7513 8 місяців тому
You are amazing, as an electrical engineering student myself I can't thank you enough for what you have done for the community. Keep up the good work, I learned a lot from this video alone!
@ameristanbouli5063
@ameristanbouli5063 2 роки тому
thanks for the clear explanation
@andr27
@andr27 2 роки тому
Ben has tought me over several videos way more than me tried get this knowledge over years
@fathert
@fathert 2 роки тому
Your videos really are fantastic, thank you!
@lilyjames8948
@lilyjames8948 2 роки тому
Always brilliant
@jumadhaheri
@jumadhaheri 2 роки тому
This is really good, thank you
@msmolovic
@msmolovic 11 місяців тому
Have seen a few of your videos so far and they are precise and highly educational without the usual smalltalk and infomercial "noise". Also, I'm not into posting comments but, I must commend you for your effort and clarity. Not only are you an excellent engineer, but you are also an excellent teacher, which is very rare. Thanks and keep up the good work.
@tripiecz
@tripiecz 2 роки тому
Thank you for all these amazing videos. Please consider covering I2C and RS-232 to TTL converters as well!
@karlm9584
@karlm9584 2 роки тому
Which is faster/more efficient for large amounts of data? SPI or I2C? If im using SPI can i just increase clock speed to increase performance (to a point)?
@darer13
@darer13 2 роки тому
@@karlm9584 SPI is inherently faster. I2C uses pullup resistors while SPI has push/pull drivers using transistors, not resistors.
@karlm9584
@karlm9584 2 роки тому
@@darer13 thanks!
@teknikal_domain
@teknikal_domain 2 роки тому
@@karlm9584 to add a little more info: I2C can technically run at a few different speeds. Generally, it runs at 100 or 400 kbit/sec, 100 is the base spec but most things I know of support 400, though a few modifications and support can clock it up to 1.7 or 3.4 Mbit/sec with the master device actively driving the clock line, but those two also include some slight protocol changes to make sure you don't get into a situation where a slave is pulling SCL low as a master is driving it high. SPI can technically clock as fast as whatever device you're addressing can take (or whatever the capacitance on your line dictates). If you're using SPI, you can increase SCL to whatever the datasheet for the peripheral device says it can respond to. If you're transferring large amounts of data, I2C also has acknowledgements as part of the protocol, where every byte needs to be acknowledged as received and/or correctly interpreted. I2C is also *always* a two-wire bus, regardless of the peripheral count, whereas SPI is 3+n, where n is the count. SPI, lacking any protocol, can technically just be used as a stripped down serial connection, and just blurt out a bunch of bits, at whatever speed, and it's up to you to write the protocol to make sure the data was read correctly.
@patlollasrujan8493
@patlollasrujan8493 Рік тому
You are doing a great job ben .Thanks!
@timetrap
@timetrap Рік тому
Great Presentation. For newbie, this gave clear insight about SPI protocol to understand the physical connections of the SPI interface. Thank you.
@bensmith3304
@bensmith3304 2 роки тому
I've also used the BME280 - it is a great chip. I was really impressed that the pressure sensor could tell the difference in altitude between my desk and the floor.
@NateCrownwell
@NateCrownwell 2 роки тому
This was super cool, thank you Ben :)
@felixp.6653
@felixp.6653 2 роки тому
I have waited for this video for such a long time. - Thank You
@cleverson_sa_
@cleverson_sa_ 9 місяців тому
Amazing content video! It helps me to understand what SPI in fact is.
@lelandclayton5462
@lelandclayton5462 2 роки тому
That explained SPI very well, when I was trying to learn it a few years back it took a month.
@SANGKAYEBOY
@SANGKAYEBOY Рік тому
well explained sir. thanks for sharing your knowledge
@OctoLumn
@OctoLumn 2 роки тому
Absolutely LOVE your videos! You have a gift in teaching, i tell ya!
@cokeforever
@cokeforever 2 роки тому
Great vid, as usual
@bryandowdey1779
@bryandowdey1779 Рік тому
Ben, thanks for a very clear and informative video on the SPI protocol. I was interested to see you working with the Motorola 6502. This reminded me of an upgrade project at Cutler Hammer, Fenton ,Michigan in 1978 when I had to convert a static CRT display of machine tool data to a dynamic one, updating the various events and parameters on the screen as and when they occurred, No SPI in those days just RS232c! The programming of the machine code was handled by a cross assembler on a DEC pdp11! Computers and microcontrollers have come a long way since then. Never-the-less, it is good to see the Motorola machine code again and see it being used with modern devices and protocols. Much appreciated!
How do hardware timers work?
31:17
Ben Eater
Переглядів 957 тис.
The RS-232 protocol
26:10
Ben Eater
Переглядів 810 тис.
BRAWLER MUTATIONS WILL BREAK THE GAME! - Brawl Talk
09:34
Brawl Stars
Переглядів 25 млн
Extracting Firmware from Embedded Devices (SPI NOR Flash) ⚡
18:41
Flashback Team
Переглядів 482 тис.
A simple BIOS for my breadboard computer
21:53
Ben Eater
Переглядів 316 тис.
PROTOCOLS: UART - I2C - SPI - Serial communications #001
11:58
Electronoobs
Переглядів 1,3 млн
How does a USB keyboard work?
34:15
Ben Eater
Переглядів 3,1 млн
How Wozniak’s code for the Apple 1 works
37:18
Ben Eater
Переглядів 321 тис.
Installing the world’s worst video card
25:12
Ben Eater
Переглядів 944 тис.
Something Strange Happens When You Follow Einstein's Math
37:03
Veritasium
Переглядів 4,8 млн