Bare-Metal MCU #9 - Review; ATTiny85 from scratch

Поделиться
HTML-код
  • Опубликовано: 22 ноя 2024

Комментарии •

  • @r3jjs
    @r3jjs 4 года назад +112

    I've almost finished your whole series (so far.)
    I am an experienced developer in working with low level systems (long live the 6502!) but I watched your videos out of curiosity on what approach you would take to explaining things.
    You have, I believe, some of the absolute best descriptions that I have heard.
    To address specific points.
    1) You stay on-focus and do not ramble. You've got a goal and you get to that point.
    2) You have a solid speaking voice without hemming or hawing. (You /may/ speak a little fast for ESL viewers, however.)
    3) Your approach of "deconstructing" the Arduino blink sketch and then rebuilding it was incredibly clear. I've not been able to explain it that well to people. Start with what they understand and go from there.
    4) Your bit-shifting (to use the pun) bang on! So many videos on bit shifting spend forever with animated charts and you did it with a single slide of coloured graphics.
    I will be referring people to your videos as well as using some of your techniques when talking in the future.

    • @DashkaMilashka015
      @DashkaMilashka015 2 года назад

      you've just nailed it. couldn't say any better!

    • @micnolmadtube
      @micnolmadtube 4 месяца назад

      I read this comment before watching the video and I could not agree more.

  • @1080pixel
    @1080pixel 7 месяцев назад +14

    Sidenote: The ATtiny85 has an internal pull-up resistor for the reset pin - there is no need for an external one. Reference: Page 39 in the datasheet, 8.1 Resetting the AVR

  • @sternowl2345
    @sternowl2345 2 месяца назад +1

    that tiny chip following your instructions and blinking the led... so simple yet so satisfying.

  • @JeSuisNerd
    @JeSuisNerd 4 года назад +37

    Just finished watching the whole series up to this point! Even as a CS major and developer by trade, this has been educational and fun to watch, just the perfect amount of succinct. You teach very well!

  • @donlion157
    @donlion157 5 месяцев назад +4

    Stumbled onto yr channel was hooked right away. You have a talent being able to make things clear and simple without being boring. Thank you, Damn good job
    Don D Lion

  • @archadious
    @archadious 2 года назад +1

    Great video. Amazing how satisfying it is see that green LED start to blink on your breadboard.

  • @gurubhaktmudit1997
    @gurubhaktmudit1997 2 месяца назад +1

    Awesome. Just what I was looking for. Thank you

  • @francoisbasquin6974
    @francoisbasquin6974 3 месяца назад +1

    Hey Mitch, great video. I'm currently writing a small project on ATTiny4313; having watched your video before would have saved me weeks of head scratching, wrong paths and disappointments. Anyway, we mostly learn by falling. Precision here: my project is in assembler, the reason is to get rid of the standard C library that keeps one timer for it (I need the two timers).

  • @malevinso
    @malevinso Год назад +2

    Mitch, I have recently found myself addicted to MCU's and all things related. I can't seem to get enough of them! Your videos are by far my favorite! They all still work great and I just love to follow along! I can only hope someday you come back to the channel and share your knowledge.
    All good things, Mark

  • @waqaswani2994
    @waqaswani2994 2 года назад +1

    Finished the series today glad I got to learn all of this

  • @PlasticBonesy
    @PlasticBonesy 4 года назад +6

    I've been following your series since the first episode while doing my own project for school and it's been a godsend. I did a project last semester coding an ATMega32 and kind of understood what I was doing (with lots of hand holding), but you were really able to break it all down and bridge the knowledge from what I learned then and what I already knew about programming arduinos. It's given me the confidence to actually ditch the arduino and use a barebones microcontroller for my own project.
    I can't wait for you to continue onto STM, as I have an STM32 development board I impulse bought which has been gathering dust as I have no idea what I'm doing with it.

  • @Electromakerio
    @Electromakerio 4 года назад +2

    Fantastic series Mitchel. We loved this video so much we featured it in this weeks episode of the Electromaker Show!

  • @luzten
    @luzten Год назад

    This is easily the best playlist of "bare metal" embedded devices programming I watched. Thanks a lot Mitch

  • @ianwalsh3868
    @ianwalsh3868 10 месяцев назад

    Just watched the whole series. It’s fantastic. It’s a great intro to bare metal microcontroller programming, as well as C programming in general. Thank you!

  • @Factory400
    @Factory400 Год назад +1

    This is pure gold. I was stuck learning this stuff with cryptic books. It took a loooong time to get some skills. Then, I find this..... which nails it.

  • @andreialexander405
    @andreialexander405 3 года назад +1

    Mitch, this series is phenomenal work on making it so clear and simple. Thanks so much!!

  • @sylvainboyer2310
    @sylvainboyer2310 Год назад

    Very helpful video, many thanks,
    I was confused by the change of 0x17 to 0x37 and after reading a bit more on the topic I have a better understanding.
    From the ATTiny85 datasheet p20: "When addressing I/O Registers as data space using LD and ST instruc-tions, 0x20 must be added to these addresses."
    And from, the Atmega328p datasheet p19: "When addressing I/O registers as data space using LD and ST instructions, 0x20 must be added to these addresses"

    • @RFDarter
      @RFDarter Год назад

      Ok at least they specified that. But why wouldn't they provide us with the correct memory address in the first place?

  • @AlvaroAlcaideSoler
    @AlvaroAlcaideSoler 10 месяцев назад

    Thank you for this series , it really helped me getting into embedded development. Your way of explaining the subjects really makes a difference. Keep up the fantastic work!

  • @harris9624
    @harris9624 3 года назад +4

    Just finished watching the series, awesome tutorial!
    I did a little digging and found out that the avr-gcc compiler has a built-in delay library in the avr-libc package called This lets you use a _delay_ms function in your C code (no more nasty for loops).

  • @josephotieno898
    @josephotieno898 3 года назад +1

    Excellent series. I have learnt a lot, filling gaps i had with AVR microcontrollers...

  • @mugishadavid5938
    @mugishadavid5938 2 года назад

    Thank you very much @Mitch Davis for important lessons about avr. Where i live its not easy to get knowledge like this. I really appreciate.

  • @human890209yang
    @human890209yang 5 месяцев назад

    Thanks! I watched all the videos in this playlist. You explained what Arduino is doing behind the scenes. I made some projects with Arduinos just following the “habits” from the examples and other's codes. Now I know the things behind those magic words of the codes and IDE's buttons.

  • @benedekfauszt9351
    @benedekfauszt9351 3 года назад +1

    I have never seen such clear explanation. Very well done! Thank you!

  • @celem1
    @celem1 3 года назад +3

    Mitch, I am enjoying your STM32 videos but saw this ATtiny85 video and also watched it. I know, from comments in other videos of yours, that you spend a lot of time producing each video and I feel the results reflect that extra effort. I like that you cover what is needed with a succinct but complete delivery. I never fail to learn something in every video. That includes this video despite the fact that, over the years, I have flashed many bare metal ATtiny85 chips for various projects. Keep it up!!
    BTW I second what Jeremy Starcher's said in his much earlier (a year earlier) comment.

  • @hkl9854
    @hkl9854 4 года назад +1

    Thank-you for make this.
    This video series is the most crystal clear explanation of Bare-Metal microcontroller for me I have seen on RUclips. I would love to learn a lot from you if you are going to do a STM8 series video. :-)

  • @donythomas7
    @donythomas7 2 года назад +1

    Thank you very much for your Bare-Metal MCU tutorials !!! Can you please add some videos on programming AVR MCUs using Rust programming language?

  • @robjordan63
    @robjordan63 4 года назад +2

    I really enjoyed this series, thanks. I have a stop/start project to master the new(ish) ATTINY '1' series, and this is incredibly helpful for getting some context on that task.

  • @didiergasser-morlay2417
    @didiergasser-morlay2417 3 года назад +1

    Hats off! Excellent series, clear & concise, to the point with just enough details to push people to dig & learn more. I bought a few attinys (in case I fry some during my experiments :) ) thanks a lot

  • @onuryorutken5540
    @onuryorutken5540 3 года назад +1

    Your series are great, briefly really really great! That is not just a "oo i like that video" comment, your videos are nailing it without boring and explaining it detailed. They way you start for example PORTB=32 for bit banging is perfect i think. Thank you, i will be waiting your other videos.

    • @MitchDavis2
      @MitchDavis2  3 года назад +1

      Glad it was helpful. These videos keep taking longer and longer to make. Sometimes I find myself knowing WHAT to do, but not WHY, so I have to do a fair bit of homework before covering it in my videos.
      It’s also incredibly difficult to decide what NOT to talk about. It’s too easy to go off on a tangent with things that are loosely related.
      Thanks again!

    • @onuryorutken5540
      @onuryorutken5540 3 года назад

      ​@@MitchDavis2 Exactly! I think it must be so hard to decide what NOT to talk about, it is like sampling without loosing quality, taking derivative without loosing function. You spend time for helping people saving time. Thanks again !

  • @patrickcpe
    @patrickcpe 3 года назад +2

    Extremely well made, thank you a ton for this. I've been looking for good resources to help friends out and this series is a godsend :)

  • @Bubby9767
    @Bubby9767 Год назад

    Great content. Awesome explanation. Very easy to follow. Something that I think would be interesting is actually a nice project with a little more than just a led blinking. From start to finish

  • @madphoenix1
    @madphoenix1 4 года назад +3

    Great series, I hope you do more!

  • @leifclaesson2470
    @leifclaesson2470 4 года назад +1

    Fantastic series, Mitch! Thank you so much. Reddit u/stm8 brought me here as well. I've watched your entire series, looking forward to your forthcoming STM8 videos but I'm not waiting, with what I've learned already I'm ready to dive in!

  • @draufunddran
    @draufunddran 4 года назад +3

    I always wanted a good introduction to stm32 micros... maybe your next series could be on one of those. And just once again... awesome series... keep the vids coming!

    • @draufunddran
      @draufunddran 4 года назад +2

      @@MitchDavis2 This is so funny... I had the exact same problem with the IDE beeing to overwhelming and all i wanted was a blank programm. But i never had the time to dig into the part where i could do it from scratch. Thats why i would love to see a series on this from you. I realy learn a lot from your style of videos and so i hope i can save some time and don't have to dig too much into the datasheets myself.

    • @DanEllis
      @DanEllis 4 года назад

      @@MitchDavis2 Honestly, the amount of code you need to blink an LED on a Cortex-M device isn't _much_ more than for an AVR. You just have to actually turn the peripheral on and enable its clock, which is just two extra lines.

  • @ihhazmi
    @ihhazmi 2 месяца назад

    Super awesomely helpful video series, thank you so much! I need to watch the rest of the videos!

  • @topherchung8910
    @topherchung8910 Год назад

    Hi Mitch, wanted to say thank you for this series. I learned lots, and opened up my understanding of arduino's and avr chips. I was looking for how to setup an internal clock and you showed much more. Again thanks!

  • @andriilogoshko8881
    @andriilogoshko8881 4 года назад

    Very clear and concise explanations. Looking forward for new episodes.

  • @gapguy9564
    @gapguy9564 3 года назад

    Just finished watching whole series. And happy feeling

  • @tilipitappi7762
    @tilipitappi7762 2 года назад +1

    i absolutely love these videos! You're top teacher. I hope you continue to do these lessons some day :)

  • @ZuNunchaku
    @ZuNunchaku Месяц назад

    its is funny when i start programming microcontroller from bare-metal (asm and C) now migrate to arduino eco systems, now people going back. great video btw, remind me old back when i in university

  • @michaelmounts1269
    @michaelmounts1269 Год назад

    outstanding series---Thank you! I know it takes a lot of time and commitment to do these RUclips videos. you work is much appreciated. FWIW--I thought including the memory maps of the chips really helped to keep the instructions clear...Kudos...well done!

  • @patlollasrujan8493
    @patlollasrujan8493 2 года назад

    finished watching the entire playlist, great work.

    • @MitchDavis2
      @MitchDavis2  2 года назад

      I had a lot of fun making that first series. I wish I had better recording equipment at the time though. Oh well

  • @faxanidu3070
    @faxanidu3070 4 года назад +5

    Ooo you did a attiny video like I wanted! Your the best!

  • @vivekvenkatsubramaniam437
    @vivekvenkatsubramaniam437 4 года назад +1

    Saved your playlist....thanks for making these videos! Hope you do other MCUs also...

  • @squeaky_honda
    @squeaky_honda Год назад

    Thanks for the tutorial series!! The arduino attiny85/84 support is a mess. Bootloaders on 85 that hog most of the pins, leaving you with little, damaged support on 84 due to versioning-shenanigans on IDE 2.x. Various "boards/HALs" hogging the timers and interrupts just in case you need delay(). Without those, I can't build anything productive. I managed to program things with a cheap "usbasp" programmer by following your instructions.

  • @microtongue
    @microtongue 2 года назад

    This series was awesome, thank you!
    The cherry on top would've been 1 video of automating it all with a makefile

  • @NunoRVOliveira
    @NunoRVOliveira 3 года назад

    Excellent series! Learned more in a couple of hours than in a couple of weeks. Thanks!

  • @davidesp11
    @davidesp11 4 года назад

    I loved this series. Looking forward to see the STM8 one.
    Thanks.

  • @tomgoff8670
    @tomgoff8670 Год назад

    Thanks for posting this series, you obviously know what you’re doing and have put a lot of effort into these videos. Great job!

  • @tusharshiralkar7483
    @tusharshiralkar7483 4 года назад

    Great video series, really loved it, looking forward to see your series on STM microcontrollers

  • @kenanusta3242
    @kenanusta3242 Год назад

    perfect series Mitch.Thank You and your effort.

  • @meemuboi
    @meemuboi 3 года назад

    I have finished watching the entire series and i gotta say, you are probably the best youtuber out there that can explain this stuff in great detail and its so easy to understand, especially for a beginner like myself. Thank you so much, you deserve a lot more views and subs (subbed btw :DD).

  • @ck-li6yr
    @ck-li6yr 4 года назад

    Great job. I've been looking for a series exactly like this. Can't wait for other MCUs.

  • @donamills
    @donamills 3 года назад

    Dont know what took me so long to find your channel. But here I am.

  • @lm7415
    @lm7415 4 года назад

    excellent complete series. very detailed. your video presentation is professional and most competent.

  • @chiraggoyal7637
    @chiraggoyal7637 4 года назад

    Great videos. Will love to see how you explain STM.
    Thank you for making such great videos.

  • @FreddyBNL
    @FreddyBNL 3 года назад +1

    Exeptionally well done. Did some binge-viewing and learned a lot, even though I already write programs for program the ATtiny s myself.

  • @KH-zt3vs
    @KH-zt3vs 2 года назад

    Thank you so much! Love this series!

  • @mr.tweety
    @mr.tweety 2 года назад

    Simply the greatest. Thank you.

  • @naveenkakada
    @naveenkakada 3 года назад

    Really enjoyed your video series. Thank you.

  • @makingwithsteve
    @makingwithsteve 4 года назад

    This is a great series! Learned so much! Thank you for doing these Mitch, can't wait to see what you do next. Would be interesting to see you try doing this with something even smaller like the attiny4, pushing optimization even harder to fit code onto such a small chip. Keep up the good work!

  • @user-vs7cw2rg7r
    @user-vs7cw2rg7r 2 года назад

    Good job man, excellent intro to AVR.

  • @parsamomemi
    @parsamomemi 8 месяцев назад

    I really like your video content and I wish to see more. I'm particularly interested in your journey and overview of working with ARM and ESP, including bare metal coding on both platforms.

  • @VerticalTurkey
    @VerticalTurkey 4 года назад +2

    Great series. I found your videos incredibly helpful. My only recommendation going forward is to normalize your audio levels to what normal videos play at. Your videos are quiet AF.

  • @rohitkumarsambaria9811
    @rohitkumarsambaria9811 4 года назад

    What a wonderful series! I would love to see you with a series on STM8, especially stm8s103f3 and stm8s003f3.

  • @SauvikRoy
    @SauvikRoy 2 года назад +1

    For a simple combinational logic circuit, would it be a nice solution?
    Actually, I was trying to put together a blinker unit using this which would also have a hazard function which could get overridden upon triggering indicators and then back to the blinker function again.
    PS: Consider a 3input 2output logic circuit.

  • @vyuniverse9490
    @vyuniverse9490 4 года назад +2

    This entire series was great; thanks for creating them. (I'm planning on following through your series with a Raspberry Pi and an Arduino Uno and see how far I get.)

  • @weirdboyjim
    @weirdboyjim 4 года назад +1

    Nice video thanks Mitchel.

  • @nict2618
    @nict2618 3 года назад

    Such a fantastic set of videos. Thank you so much.

  • @a.inaciomorais9859
    @a.inaciomorais9859 4 года назад +1

    I have a lot of old AVR MCU here. ATMEGA8535 and AT90S8535. ATMEGA8535 worked fine with AVRDUDE 6.3 and ARDUINOISP. But with AT90S8535 I have experienced the strangest outcomes so far. It is necessary to use an external clock (I'm using a 8MHz crystal) and there aren't quite evident fuses that work with AVRDUDE (the online calculator states that there is an AVRDUDE lfuse argument but the AVRDUDE returns "lfuse" memory type not defined for part "AT90S8535"). Without fuses I was able to perform a first programming (avrdude -u -C /etc/avrdude.conf -p 8535 -P /dev/ttyACM0 -c stk500v1 -b 19200 -U flash:w:"avr2.hex":i) and it works fine, but for every AT90S8535 that I try to program a second time it is impossible ("Yikes! Invalid device signature") but it works well if I disconnect the GND line from ARDUINOISP when programming it again (I'm not kidding). I'm using decoupling caps and everything. Maybe it's better to let go of things from the past.

    • @a.inaciomorais9859
      @a.inaciomorais9859 4 года назад

      @@MitchDavis2 They have discontinued it in 2004 I think. These ones that I have were produced in 2001. But don't bother... I was using these because I don't have others AVR MCUs (only the ATMEGA328P that comes with ARDUINO). I was able to apply your lessons with ATMEGA8535 MCUs and it was fine. Thank you very much. The way you explained it was amazing. I have never seen anyone with your ability to teach. Please, consider some STM32 content for the future and forgive my bad English.

  • @asddsfdsaasdf
    @asddsfdsaasdf 3 года назад

    Great content - new way of learnong things from arduino world. Thank you

  • @philippeclair4017
    @philippeclair4017 3 года назад

    Thank you Mitch, I watched the whole series with great interest, I learnt a lot of things, despite I already programmed dozens of T85s chips. This is the best tutorial I ever found for programming the AVR micro-controllers if you want to progress from arduino IDE to avr-gcc and avrdude. Now I hope to learn from you how to use Make and Makefiles. It is so tedious and error-prone to repeat over and over again the same cryptic commands from the console. Please explain us how to automatize this process.

  • @pbs570
    @pbs570 Год назад

    NICE! We want more!

  • @boblake2340
    @boblake2340 2 года назад

    Brilliant video! All the detais clear and to tne point.

  • @DashkaMilashka015
    @DashkaMilashka015 2 года назад

    well... thats the best led blink thing i have seen. all that.. hundred parts..? thanks for the time you've spent, thats the way to do it (teach).
    ps: big thanks

  • @brendanbarbour210
    @brendanbarbour210 3 года назад +1

    Hey Mitch...That was terrific..I just binged on all nine in the series and it filled in a great deal of detail about what was going on behind the scenes..The Arduino IDE is all very well, but it keeps a lot of secrets that ultimately can be crucial in debugging not just code but workflow as well. I'm now going to revisit a number of failed projects armed with the insights..Many thanks..One question...I don't have the specific programmer you used..I have a TL866II-Plus...can this work as a programmer under the Arduino IDE ?

    • @brendanbarbour8568
      @brendanbarbour8568 3 года назад

      @@MitchDavis2 You were looking for suggestions as to what to tackle next; Have you thought about a sortie into FPGAs..or delving into some specialised ICs/Modules, by taking the backwards engineering approach that works so well, to work from the datasheet and end up with a basic working system, for example the Farchild Smart Power IGBJT (FSBF5CH60B) and ending up with an Inverter....

  • @nict2618
    @nict2618 4 года назад

    These videos are so good.

  • @henkoegema6390
    @henkoegema6390 2 года назад

    Excellent work. 👏

  • @AmalMathewTech
    @AmalMathewTech 3 года назад

    Great Series, Thank you Mitchel

  • @albertroswell
    @albertroswell 2 года назад

    awesome!, thanks, just want I needed to program an attiny20!, thanks for making this!

  • @cuatropantalones
    @cuatropantalones 4 года назад +1

    this was excellent!

  • @abpccpba
    @abpccpba 3 года назад

    For this, your first go-round went well. : = ))

  • @floridasenior
    @floridasenior 4 года назад +1

    great job am subscribing now

  • @elliotth30
    @elliotth30 3 года назад

    Brilliant video

  • @nexpro6985
    @nexpro6985 10 месяцев назад

    Never connect the power and ground rails together on your breadboard. Make sure you connnect the ground rail on one side with a wire to the ground rail on the other side. Then do the same with the power rails ( as shown in the video ) 😁

  • @OJI3G
    @OJI3G 4 года назад +1

    Yo dude, nice video, thank you

  • @henninb
    @henninb 3 года назад

    Amazing video , inspires me to program without an ide.

    • @MitchDavis2
      @MitchDavis2  3 года назад

      By all means, if you don't want to use an IDE, go for it. This type of video is what inspires me to USE an IDE. I like to know what's going on behind the scenes so there's no "magic". But after that, I like to take advantage of all the cool tools out there.

  • @Amaralrosa1
    @Amaralrosa1 Год назад

    That's beautiful!

  • @louisferreira9055
    @louisferreira9055 Месяц назад

    "Welcome to the last video in this series...." NOOoooooooo! I just died a little!

  • @mdfaisal1415
    @mdfaisal1415 Год назад

    This best video tutorial. Thank you so much

  • @mr0insane
    @mr0insane 3 года назад

    Wow, just finished this serie of 9 vids.
    This might just be flagged as one of the best tutorial series I've ever encountered on YT, scratch that, on the net! Very interesting, very detailed, and very comprehensible indeed. "Take one step back, ... to leap a couple of miles ahead" !
    I must add, though, I am still wondering about the use, and the need, for those 'high fuse', 'extended fuse', and 'lock bits'. In addition, how to scribble EEPROM? (My guess is that it is done in a similar way as writing flash with avrdude?).
    Keep up with this amazing quality! Now I'm heading to the LCD vid :D
    //Best regards from The Netherlands

  • @shamailkawish6632
    @shamailkawish6632 Год назад

    Thanks for the video.

  • @testme2026
    @testme2026 4 года назад

    excellent as always!

  • @DavidTLutz
    @DavidTLutz Год назад

    Great series!!!

  • @engr.saqibsohail5277
    @engr.saqibsohail5277 Год назад

    Amazing series on microcontrollers. It deserves millions views. But alas people are more interested in flashing T**s videos instead of flashing LEDs videos ;)

  • @zetaconvex1987
    @zetaconvex1987 3 года назад

    STM8's are great little chips, BTW. Small, simple, cheap, with ample pins to play with. I have an stm8s103f3p6.

    • @zetaconvex1987
      @zetaconvex1987 3 года назад

      @@MitchDavis2 You might want to take a look here: github.com/blippy/rpi/tree/master/stm8s103f3p6/bare
      It's hastily-assembled bare metal files for the STM8S, including basic blinking, PWM, timer interrupts, uart, SPI and I2C. Expect bugs, particularly wrt I2C. But it might give you some inspiration. There's clearly a lot you can do with an STM8.

  • @ahmatrizki5154
    @ahmatrizki5154 3 года назад

    Thanks for sharing

  • @AleksandrIvin
    @AleksandrIvin Год назад

    Nice video. I used this chip in my toy as IR recivier :)

  • @andymouse
    @andymouse 2 года назад

    Great tutorials...cheers.

  • @RixtronixLAB
    @RixtronixLAB 2 года назад

    Vote up, nice clip, thanks for sharing :)