attiny 85 bootloader (edited title)

Hello all
Just a quickie here
I am just branching out into the smaller Atmels and after some faffing around, managed to get "blink" onto an Attiny 85-20. Running with all the defaults including 8MHz internal clock, all in IDE 1.6.12.
All I'm really after is how to find out if I managed to get a bootloader onto it.
Using Arduino as ISP.
Does the upload verbose output give any information?
What is causing the confusion is by following HighLow Tech method, they say "burn bootloader" them follow that up with "doesn't actually burn the bootloader"
Finally, does the reset pin need a series capacitor? Seems to upload OK without.
Thanks

First, please edit the title to no scream please.

Then, I have no idea what the HighLow Tech method is. Don't think we know everything from the top of our head, just post a link to it. But if you can upload a sketch to it just via serial (so NO ISP) then it has a bootloader.

And yes, you need the cap. For two reasons

  1. If the DTR pin is kept low it will leace the uC in reset. With a cap it does not
  2. Without it you can't add a reset switch because that would just short out the serial adapter.

Hello
No intentional "scream" here - just cap lock on, my apologies

HighLow Tech is an MIT site and is well recommended for Attiny85 programming and probably known to Attiny dabblers - not accusing you of not knowing it.
But thanks for the other advice

tigger:
No intentional "scream" here - just cap lock on, my apologies

Still not to late to save your good name and edit your post / the title back to normal :wink:

tigger:
High-Low Tech – Programming an ATtiny w/ Arduino 1.6 (or 1.0)
HighLow Tech is an MIT site and is well recommended for Attiny85 programming and probably known to Attiny dabblers - not accusing you of not knowing it.

Thanks for that. Problem is, there are many good and many bad sites. And if you want a good and quick answer it's always best to give all the details. Including links to mentioned website/methods, products, libraries etc :slight_smile:

Old dog, new tricks, I'm afraid.

septillion:
if you can upload a sketch to it just via serial (so NO ISP) then it has a bootloader.

Tigger is using Arduino as ISP - so there won't be a bootloader, right?

When you use the "burn bootloader" function on a bootloaderless ATtiny like this, you're really just setting the chip's fuses.

It's important, you need to do it, but as they say, it "doesn't actually burn a bootloader".

Yes it is confusing!

Ahh, yes, via that method there is indeed no bootloader.

But ATtiny bootloaders do exist, even with USB build in.

Thank you both
@septillon - do you know of any references to attiny bootloaders? I found this one today
Bootload Your ATtiny85 - Hackster.io.
Is this the sort of thing you mean?

At first look that seems like one. I only have experience with Digisparks which has a ATtiny85 and connects straight to USB. Get mine from China but I believe all the code (and bootloader) is all online.

Just a follow up on this.
I've got the uploading working OK, but with 0.1uF in series with the reset pin, I get the "yikes - invalid signature, check connections" error.
Put the reset line directly onto the Attiny reset pin and no problems. 10k pullup on the Attiny reset pin in both cases.
Nick Gammon's site with the 328P-PU bare board programming uses the 0.1uF and the pullup. The HighLowTech method uses no series cap for the 85, but does use a 10uF between GND and RESET on the programming Uno.
I know this contrary behaviour to expected, but any thoughts?

The 10uF cap is so the Arduino as ArduinoISP will not reset during the programming. But I believe in later versions of the IDE it's not really necessary anymore.

And if you program it via the ArduinoISP you can go without the cap (but indeed use a pull up because you need that also after the programming is done / ArdunoISP is removed) but with cap should just work fine.... As long as you do it without the cap, be sure not the press any reset switch for the ATtiny (if you have one).

Thanks septillion for that.
I had been working with bare 328p's, but this was the first go at getting the 85 to work.
There's a lot of groundwork to do even with something as seemingly simple as the 85, from getting the pinouts to programming.
I had been struggling with CMOS retriggerable monostables to eliminate short digital inputs, but mastering the 85 will make the job a lot easier, I hope. I was using a 7555 in retriggerable mode, but it was very susceptible to noise and false triggering.
Cheers

Yeah, that's because out of the box Arduino IDE has no support for a ATtiny. So you have to do some groundwork like you have to do installing a "real" toolchain. Setting up the Arduino (to program a Uno) is just soooooooooo damn simple everything else just feels complicated :smiley:

But just to be clear, what are you driving with those (555 or ATtiny85 controlled) pins? Some existing/factory made circuit?

I'm monitoring water levels in a container by shining IR light through and onto a TSL262 infrared photodiode/amp
It involves some quite long cable runs.
At the end of the 10-m cable is a comparator MCP6542. This feeds into the retriggering pin of the 7555. - I need the 7555 to take care of noise that the comparator hysteresis won't. Now and again, the 7555 fires of it's own accord - I've tried every trick in the book from heavily decoupled power lines, RC filters, Schmitts etc. to no avail. In my book, one glitch is one too many, so bit the AtTiny bullet and am running what is essentially a missing pulse detector. I'm hoping that the 85 is going to be less noise prone than the 7555. So far, looking good. So the answer to what is being driven in both cases is either an LED or the probe of a scope.
Just to be clear, I have no classical MCU or electronics training and have to pick it up along the way.
Even the Arduino platform was daunting to start with, but in the few years that I have been doing all this, I've got a reasonably complex Zigbee network going with Arduino support. Most of the effort goes into energy monitoring and the application that this was all about was to monitor the operation of a gas boiler. The boiler is a condensing type and now and again has to operate a siphon to discharge the water (condensate). The IR setup gets a nice signal difference depending whether there is air or water in the path.
Funny enough, I was looking for a nice LED display to show when the boiler was running and opted for some ultra bright blue and red LEDs shining edgewise through some perspex - the fading simulates the flickering gas flame. I used an exponential fading function calcuated in Excel then copied as a 52 element array in the Uno - it's very smooth and takes care of the human eye response to changing light levels. I might take a look at your library.
I also want to get into CNC machining, so UGS and g-codes etc. are the next challenge.
So there it is.
Thanks for your interest and good luck.

It wasn't to criticize your design nor knowledge. But the whole "ATtiny to filter" sounded a bit like you wanted to put a ATtiny in front of an Arduino/another micro. And that would have been a bit wasteful :slight_smile:

But one question, why is the comperator 10m away from the IR?

And about my library, in the Branch GammaCorrect there is a version that uses a table to gamma correct the brightness of the led. I did not release it yet because in the past I made some changes so people can use it on a ESP8266 but now I use some PROGMEM stuff and that breaks the ESP8266 part... My knowledge about the ESP is still not even halve of that of AVR or PIC so I have to do some research for it but I'm lacking some time :confused:

Hi there.
This project is at the cobbling together stage. It started life as as a rats nest of CMOS chips and is gradually working towards a single board answer.
Years ago, I worked in an essential public utility as a back-stop telemetry/monitoring/automation bod.
When problems in a 24-hr, 7-day essential service developed, there was no-one else to ask for a solution and time was against you.
My approach was to throw solutions at it until something stuck, then with the pressure off, work backwards until you found the cause, and refined the solution. This is how I do most things.
Weeks ago, I had no idea how to get a Tiny running, but now it's almost routine. They are cheap enough to front end any project and splitting things up does help initially. I particularly like the AtTiny841's with built-in I2C etc., but the SOIC package is a challenge.
I also used to design control panels etc., with lots of relays and timers because this is what plant electricians understood at the time. Whenever a project involved more than a couple of relays and timers, I would use a PLC (Programmable Logic Controller) as they are bog-standard production line gear. Now...., you could do the lot on a Uno. That's why my little tag says "wish I had found it etc."
Arduino has opened up MCU's to all - before, you had to have a strong background in C before you could even start. A guy I worked with who did the processor stuff, had to use an interpreter/programming suite that came from Russia. Oh, and not to mention, no PC's.
I think that this is one of the most exciting times to be involved in any technology, but you need the tools like Arduino IDE to make it accessible.
Why the 10-metres of cable? Because the gas boiler I'm monitoring is in the kitchen and the scope etc. is upstairs in the back bedroom, so 10-metres of CAT5 cable. The only logic is that the IR amp will happily drive the distance. Eventually, it will all be in a single package as part of the Zigbee network, time permitting....
Again, good luck