AtTiny85 SoftwareSerial and TinyDebugSerial Not working properly

I've been trying to get either library to work with the AtTiny85 and had no luck. Everything uploads just fine and the attiny works but when I hook up to a serial monitor I just get gibberish. I tried every possible thing I could already. I burnt the bootloader with trying both 8mhz and 1mhz to change clock, tried changing the baud rate, tried different AtTiny85. Nothing seems to work. I just keep getting junk. Im using my mac book mostly but tried on my latitude and same problem.

AtTiny works just fine otherwise.

Im not sure what I'm doing wrong. Any help appreciated.

Pin 3(Literal pin2) of attiny goes to Rx of my serial monitor.
My example code:
#include <TinyDebugSerial.h>
void setup()
{
Serial.begin(9600);
}
void loop()
{
Serial.println("Why isn't this crap working?!");
delay(100);
}

Im not sure what I'm doing wrong.

Failing to describe the hardware comes to mind.

Arduino UNO R3 as ISP. AtTiny85.

Pin 3(Literal pin2) of attiny goes to Rx of my serial monitor

How do you make this connection? Which hardware ?

First thing, make sure you burnt the 8mhz bootloader... or you're not going to get anything happening.

Secondly, I'd switch to SoftSerial, which is native and comes with Arduino's IDE (I know, I use SoftSerial myself on Attiny85's no problem, but you have to burn the bootlader of 8mhz)

I did burn 8mhz boot loader. That's what I was saying in the original post. Tried it a few times. I have a pin on AtTiny connected to the Rx pin on arduino UNO(with capacitor over reset and gnd). I also have a USB to serial adapter that I tried and I get the same trash with it. I tried changing baud rate around too. Every combination I could.

Also I tried Software serial too and I get the same stuff. It seems to be working but I get junk on the monitor. I feel like I'm doing something wrong on the software side.

junk on the monitor usually means wrong baud rate

(which could also be wrong clock speed on the Tiny85)

fungus:
junk on the monitor usually means wrong baud rate

(which could also be wrong clock speed on the Tiny85)

Thats what I figured but I tried different baud rates. I even tried different baud rates on the monitor then in the program. I still get junk, just different characters.

I don't see why the clock speed wouldn't be right at 8mhz. I selected AtTiny85 8mhz from the cores and then burnt the boot loader(obviously doesn't burn anything, but should change the clock speed to 8mhz).

Also I checked with my oscilloscope a blinking led set at 1 sec. Its shows perfectly one second on the oscilloscope.

I have a pin on AtTiny connected to the Rx pin on arduino UNO

And the ground pins ?

with capacitor over reset and gnd

No it should be either

  1. A jumper wire between reset and ground (and a small resistorr on the tx/rx lines for safety)
    or
  2. remove the processor from your UNO board

Erni:

I have a pin on AtTiny connected to the Rx pin on arduino UNO

And the ground pins ?

with capacitor over reset and gnd

No it should be either

  1. A jumper wire between reset and ground (and a small resistorr on the tx/rx lines for safety)
    or
  2. remove the processor from your UNO board

Got it working. Thanks! Can't believe it was just a wire instead of a capacitor.

Good to hear you got it working.

BTW this line is not needed:

#include <TinyDebugSerial.h>

The TinyDebugSerial is part of the core

PavelK:
I have a pin on AtTiny connected to the Rx pin on arduino UNO(with capacitor over reset and gnd).

'A' pin... or the pin?

Having another chip connected to the serial line might cause interference, yes.

Has anyone accomplished powering an attiny85 using softwareSerial with a battery?
I don't get output when i use a battery. Yet, serial output works fine when powered from an arduino connected to USB (500mA).
The Circuit: 9volt battery regulated by a 7805 to 5v, attiny85 decoupled with a .1uF ceramic.
I thought maybe the battery didn't supply enough amps so i tried dropping a 9volt power supply (650mA) in its place, but no luck there either.
I realize this is not an arduino problem so much as a power supply problem, but thought maybe someone out there must have something like this working. I'm a total beginner when it comes to electronics.. thanks for any help. Ric

ricg:
I realize this is not an arduino problem so much as a power supply problem, but thought maybe someone out there must have something like this working. I'm a total beginner when it comes to electronics.. thanks for any help. Ric

No, it's an AVR chip problem. The internal clock varies with voltage. A different power supply will run the chip at a different clock speed. To fix it you need an external crystal.

Thanks for your reply. I searched the forum and found this Arduino Forum which discusses the crystal you suggest. any other links you know about are appreciated.
I'm definitely jumping into the deep end of the electronics pool with this, but how better to learn.
thanks again, Ric

fungus:
No, it's an AVR chip problem.

Not necessarily.

The internal clock varies with voltage.

Yup. By a very very tiny amount.

A different power supply will run the chip at a different clock speed.

Yup. By a very very very tiny amount.

To fix it you need an external crystal.

If that's the case, the power supply is irrelevant; the target just needs to be tuned.

ricg:
Has anyone accomplished powering an attiny85 using softwareSerial with a battery?

I have.

I don't get output when i use a battery.

Grounds connected?

I've had the same issue if the voltage is below 3.8v(ish) you need a regulated 5v supply..... lower voltage less synchronized it becomes

You might be able to use NewSoftSerial...I ran into some flaws while trying to use softserial on my ATTiny 85's but after burning the 8MHz bootloader and using the new library, everything ran pretty well (even off of wall warts and batteries)

Cheers!
Mr_E