ATtiny85 USB do not execute the codes after uploading and pluging for 2nd time

Hi every body
I have the problem with ATtiny85 USB
when I connet it to pc and upload the code, it execute the code(for example blink code) but after I unplug it and plug it for next time ot powering without pc It do not execute the codes. I wait for 5 minute but no response. Power led is on and there is no problem with powering.
again if I uplaod the code for second time it execute the code until unplug it. after unpluging and pluging again it do not execte codes like that it erase codes with unpluging or something else.
plz help me.

When you say ATTiny85 USB, which of the several vusb-attiny85 boards are you using?

How do you know whether it is executing the code? Does the code involve anything that outputs over a USB-serial (I don’t even know if this is possible on those usb-attiny85 boards - I have a very low opinion of them - but if it is, I’d be suspicious of that if the code that wasn’t working made use of it)

On my Digispark clone development board, the USB port is primarily used for 5v power and programming the ATTINY85 microcontroller. When powering up by USB, the Bluebie bootloader (micronucleus tiny85) briefly pauses for any programming code to load, before running the program previously loaded.

So, the bootup sequence is always delayed briefly, but that is rarely a problem.

DrAzzy:
When you say ATTiny85 USB, which of the several vusb-attiny85 boards are you using?

How do you know whether it is executing the code? Does the code involve anything that outputs over a USB-serial (I don't even know if this is possible on those usb-attiny85 boards - I have a very low opinion of them - but if it is, I'd be suspicious of that if the code that wasn't working made use of it)

You are right. I am using Digispark Attiny85 USB like below link:

I uploaded blink program. It works after uploading but after unplugging it does not work.

aghyool:
Hi every body
I have the problem with ATtiny85 USB
when I connet it to pc and upload the code, it execute the code(for example blink code) but after I unplug it and plug it for next time ot powering without pc It do not execute the codes. I wait for 5 minute but no response. Power led is on and there is no problem with powering.
again if I uplaod the code for second time it execute the code until unplug it. after unpluging and pluging again it do not execte codes like that it erase codes with unpluging or something else.
plz help me.

Hi everybody;
I Solved my Problem by uploading the Micronucleus Bootloader

How to Upload Micronucleus Bootloader on Digispark ATTiny85 USB?

I Used This Below Two YouTube Clips:

First: Upload the ArduinoISP application on Arduino UNO by Arduino IDE

Second: Connect the UNO Arduino to the ATTiny85 USB.

UNO --- ATTiny85 USB +++ ATTiny85 Microcontroller
GND --- GND +++ Pin4
5V --- 5V +++ Pin8
Pin_11 --- Pin_0 +++ Pin5
Pin_ 12 --- Pin_1 +++ Pin6
Pin_13 --- Pin_2 +++ Pin7
Pin_10 --- Pin_5 +++ Pin1

Connecting 10 microfarad capacitors to Reset Pin and Ground of Arduino UNO. I had forgotten to do it, but there was no problem. And If you want to burn ATTiny85 Microcontroller Chip use 100 nF capacitor between Vcc and Gnd(pin #4 and #8).

Third: Download and install AVRDUDE software from the following site,
https://www.ladyada.net/learn/avr/setup-win.html

Download link,
https: //netcologne.dl.sourceforge.ne...10-install.exe
I installed this on the C laptop drive. C: \ WinAVR-20100110

Fourth: Download the Github Micronucleus Boot Loader from the link below,

Download link:
https://github.com/micronucleus/micronucleus/archive/master.zip

Copy the t85_default.hex file to the C drive from the micronucleus-master \ firmware \ releases file inside this file.

Fifth: After Connecting Arduino UNO to laptop Now you need to run Windows Cmd software and change directory to C drive with "C:" Enter.

We supose you installed AVEDUDE in "C: \ WinAVR-20100110" and you put "t85_default.hex" in Drive "C"

You should now run the following code:
C: \ WinAVR-20100110 / bin / avrdude -CC: \ WinAVR-20100110 / bin / avrdude.conf -v -P COM11 -b 19200 -c avrisp -p attiny85 -Uflash: w: C: \ WinAVR-20100110 / t85_default .hex: i -U lfuse: w: 0xe1: m -U hfuse: w: 0xdd: m -U efuse: w: 0xfe: m

After you finish executing the code, you are uploaded Micronucleus Bootloader.

Good luck.

1 Like