Can u please tell us the exact code for the chip you are using? Are u using a ATMEGA328P-PU? I want to buy the exact chip u got and follow your videos and program it. Ty
@elewizard Жыл бұрын
I will use atmega8a, atmega32a and atmega128a. You can buy these parts to follow my works. I must say that atmega32a and atmega16a are almost the same and their main difference is their memory size. The same point is true for atmega64a and atmega128a
@dimitrioskalfakis Жыл бұрын
good work. there might be a problem though with beginners when examining the SPI interface connections between the ISP programmer and the MCU. it is true that MOSI connects to SDI and MISO to SDO (input of slave to output of master and the reverse), however, when using the same notation for both it is always shown as MOSI to MOSI and MISO to MISO.
@elewizard Жыл бұрын
Thank you for sharing
@zmarssojourner7435 Жыл бұрын
Thank you for the video. I am familiar with C++. I have a few questions for you. Thank you for your replies! @21:12, You were trying to define Pin PB0 as a digital output. To achieve this, you wrote DDRB = 1; 1) Where did you learn/ find out that you are supposed to write DDRB and not ABCD or XYZ? 2) How did you make the connection that PB0 is somehow connected to DDRB? Did u see that in a datasheet or ATMega manual? 3) Why did you set DDRB equal to 1? Obviously setting it to 1 defines the PB0 as a digital output, but who told you or where did you see that this is how you are supposed to set the pin? 4) Why is DDRB set to 1 and not to 0? Where did you see that it needs to be set to 1? Did u find it in the datasheet?
@elewizard Жыл бұрын
These are explained in datasheet. To answer such questions, I have to publish a Playlist to explain all basics and details. Goal of this video is to introduce AVR not programming AVR chips. I will give more detail about this subject
@prakashdutt152011 ай бұрын
@@elewizardSir, please make video how to program in c programming for microcontrollers...
@dmisi1 Жыл бұрын
You make a big Step , now on we can be on another level in electronics Thanks To You ! ,...
@elewizard Жыл бұрын
Awesome, keep learning
@eddiepires39989 ай бұрын
Well explained , very clear. Also clearly showed where further knowledge will be required. 👌
@elewizard9 ай бұрын
Wow, thank you for your kind words 😃
@zmarssojourner7435 Жыл бұрын
Hi. Ty for the vid. I just made my LED blink. I was thinking of purchasing a ATMega chip but I instead DIRECTLY programmed the chip that is already on my Arduino Nano. The Nano has an ICSP port and I connected the USBasp to it and downloaded the hex file onto the chip. I blinked the LED with 500 ms first. Later I changed the C code to 5000 ms. It works great. Ty and looking forward to build and learn more on this embedded topic.
@elewizard Жыл бұрын
Awesome, so glad to hear that. Keep watching. More videos are coming 👍
@zmarssojourner7435 Жыл бұрын
Thank you for the video. I am familiar with C++. I have a few questions for you. Thank you for your replies! @22:00, you used the library #include 1) Out of the hundreds of libraries out there, why did you choose this library? I am sure the final goal of blinking the LED told you to pick this library, but I want to know what was going on in your head and why you chose this library? If someone is stuck on an Island, I am sure you wont be there to tell them to pick this library right? LOL (Joking) 2) You also used the syntax _delay_ms().....how did you figure that out??? It is very hard to guess this exact syntax. You got it from some special book or place. Where did you get it from LOL?
@elewizard Жыл бұрын
You are right, explaining these concepts is not easy. Actually in this video my goal was not to educate programming. My goal was to introduce AVR to who have programming skills and is interested in learning AVR. I can't remember where exactly I have learned these syntaxes but I am sure it was a website or forum 🙃
@bayareapianist11 ай бұрын
You can open the header file and find the API and see you you have like any other c/c++ library. After over 40 years of programming, my answer to you these days is just Google it ;). Older days: you would look at the examples which came with the ide or read manuals, etc.
@abdulsami7042 Жыл бұрын
Thank you so very much. I am learning a lot.
@elewizard Жыл бұрын
You are so welcome
@zmarssojourner7435 Жыл бұрын
Thank you for the video. I am familiar with C++. I have a few questions for you. Thank you for your replies! @21:29, you were trying to control the ON /OFF states of the PB0 pin, you wrote PORTB = 1 etc. 1) Why did you switch from DDRB to PORTB? Why didn’t you use DDRB =1? 2) Where exactly did you find the info that you were supposed to write PORTB = 1 and not ABCD =1 or XYZ = 1? Did u find that in the datasheet also?
@elewizard Жыл бұрын
DDRB.0=1 makes pin 1 on port B output 😉 PORTB & DDRB are registered in AVR which are explained in datasheet
@tedbastwock38104 ай бұрын
Fantastic video, thank you. I would like to see 12vdc mcu applications. Specifically, how other discrete components like capacitors, resistors, diodes, transistors, etc come into play. This is a great intro, and I appreciate it very much. Love your channel, wishing you great channel success and growth.
@elewizard4 ай бұрын
Thank you for taking time to watch the video. By the way, thanks for the suggestion
@jboy6944 Жыл бұрын
Wizard, you've made my day again, Thank you!
@elewizard Жыл бұрын
Cheers 🥳🍻
@mmg.mousavi5613 Жыл бұрын
عالی مهندس👍 خیلی لذت بخش بود❤
@elewizard Жыл бұрын
Thank you so much ❤️
@dbme6 Жыл бұрын
Could the Arduino IDE be used to write and compile the code and then the generated file be sent to the microcontroller or is there a difference in how the Arduino IDE uses libraries and creates the code that is specific to the Arduino family of boards?
@elewizard Жыл бұрын
Arduino ide can be used to generate executable file for AVR, then you can use programmer device to flash the MCU.
@sumanyuswar4 ай бұрын
Shall I start with microcontroller or a microcontroller board?If microcontroller which is the best way to add code in atmega8a
@Embeded_Geek Жыл бұрын
Your Lab setup looks great 👍 keep it up.
@elewizard Жыл бұрын
Thanks, will do!
@scienceoftheuniverse9155 Жыл бұрын
We really appreciate your great effort. Thanks indeed can't wait to see more
@elewizard Жыл бұрын
It's my pleasure
@zmarssojourner7435 Жыл бұрын
@21:28, why did you write PORTB = 1; ? Aren't you supposed to write PORTB0 = 1; ? ( The port you used is officially PORTB0 on the datasheet). Why didn't you include the 'zero' at the end of the syntax? Were you trying to set ALL the ports in 'B' to a 1 and thats why you didnt write a 'zero'? Ty!
@elewizard Жыл бұрын
It doesn't matter in this example. The command PORTB=1 will set PB.0=1 and other pins of PORTB equal to 0.
@marcelkubanek6798 Жыл бұрын
Can't we use Microchip Studio build in programmer to flash the hex code to ic?
@elewizard Жыл бұрын
Yes you can
@howu810311 ай бұрын
excellent video!
@elewizard11 ай бұрын
Glad you liked it!😍
@agustinpanichini7630 Жыл бұрын
Hi Electronic Wizard greetings from La Plata Argentina, thank you!
@elewizard Жыл бұрын
Hi my friend from Argentina. Thank you so much for watching!
@frostysnowdog Жыл бұрын
I’d like info on your storage drawers. I like them because they are clear.
@elewizard Жыл бұрын
Happy to hear that 😃
@thomasmv59866 ай бұрын
can you send me the link to download PRG USB software
@elewizard6 ай бұрын
Google it
@zmarssojourner7435 Жыл бұрын
I found one on Amazon, that says ' ATMEL 51 AVR USB ISP ASP Microcontroller Programmer'. It doesn't have the 'S' in front of the 51. Will this work as a programmer? Also, I already have a ' A Set AVR ISP USBtinyISP Programmer for Arduino Bootloader'. Could I use it to program the Arduino? I ask this because, from its name, it seems like this programmer is for loading a bootloader only and not for loading regular programs like blinking an LED.
@elewizard Жыл бұрын
Yes, you can use first on. I am not sure about the second one
@fouadzerdoumi95249 ай бұрын
thank you good work
@elewizard9 ай бұрын
And you for watching 😊
@rameshwarshelke4633 Жыл бұрын
Thank you sir 🙏...
@elewizard Жыл бұрын
Most welcome
@millionaire_iraq4675 Жыл бұрын
Please,could you make a course about AVR
@elewizard Жыл бұрын
Certainly, I will
@ChandrashekarCN Жыл бұрын
💖💖💖💖
@elewizard Жыл бұрын
❤️❤️❤️❤️❤️ Thanks for the hearts
@RatonEEE-bp2my11 ай бұрын
can make more avr and stm32 video. It was excellent.
@elewizard11 ай бұрын
Will do!
@mediamisfits3805 Жыл бұрын
Ah... basically Arduino is just an expensive fancy microcontroller
@elewizard Жыл бұрын
Exactly
@mediamisfits3805 Жыл бұрын
Why did you not come into my life earlier 🤣 @@elewizard
@bayareapianist11 ай бұрын
So as Apple computers and iPhones. People pay for convenience. I never see smart people in Ssilicon Valley use iPhones.
@anonymouseniller66888 ай бұрын
Not really. Arduino is an application (hardware boards and software) that uses the AVR microcontroller. In a way it's a semi finished product that you reconfigure. The additional prices is your convenience fee.
@magicsmokeescapist40695 ай бұрын
Arduino UNO to say one utilise Atmega328P, you can buy these and program them in your Arduino board and move them to your project. You must install the bootloader before. Last I checked they cost 5-6EUR for one, in DIP package.
@JohnWinquist2 ай бұрын
I found this video very interesting. I've always just used development boards. I was under the misunderstanding that microcontrollers needed a crystal to keep time. Apparently, I was wrong bc there wasn't one included in the circuit and the led still blinked. I'm curious about the "bootloader". Does the microcontroller need to have one already with this process? Or is that just something so it'll work with the Arduino IDE?
@elewizard2 ай бұрын
Boot loader is an option. It is not necessary 👍 Boot loader is an irregular way to make an MCU based project
@ha131514 ай бұрын
+1
@elewizard4 ай бұрын
Thank you 😊
@DefaultFlame6 ай бұрын
FYI: The best microcontroller for a flashing LED project is not using a microcontroller, just a 555 timer IC, one capacitor, three resistors, and an LED, with two additional capacitors optional since they are more for using it as a CPU clock and not as an LED timer circuit. No programming required, only math you can do on a calculator.
@elewizard6 ай бұрын
Why you are not using two transistors instead? If the problem is only blinking an LED. here the problem is not to blink an LED. The problem is to setup and configure the MCU
@DefaultFlame6 ай бұрын
@@elewizard It was meant as a joke. It seems I am bad at jokes.