ATtiny85 Pin Doing the Opposite

Ok, this is weird I have a simple blink sketch that I uploaded to an ATtiny85 with the follow code but instead of the LED being on for 4 seconds and off for 1 second it does the opposite. I am using pin 0 in the code which is IC pin 5 on the tiny. I tried different pins and another chip and still the same results.

void loop() {
  digitalWrite(led, HIGH);   // turn the LED on (HIGH is the voltage level)
  delay(4000);               // wait for 4 seconds
  digitalWrite(led, LOW);    // turn the LED off by making the voltage LOW
  delay(1000);               // wait for a second

And in this code I get the opposite too. If the temp is below 69 the light should be on but it is off and when the temp goes above 69 it should be off but it goes on. This is driving me crazy anyone have any idea why this is?

if(temperatureF < 69)
  {
    digitalWrite(led, HIGH);
  }
  else
  {
    digitalWrite(led, LOW);
  }

How is the LED connected? Does it go (through a resistor of course) to GND or to Vcc?

Why ask him how it's wired?

We know how it's wired - the opposite of how he thinks it is.

The pin is connected to the negative side of the LED, and the positive side is connected to VCC through a resistor. Hence, when the pin goes high, the led turns off, and when the pin goes low, now there's a voltage on the LED, and it turns on. This is a perfectly normal way of wiring up LEDs (people often do this by default, since chips are generally better at driving to ground vs driving to Vcc) - just change your code to drive the pin low when you want the light on, and high when you want it off.

DrAzzy:
Why ask him how it's wired?
We know how it's wired - the opposite of how he thinks it is.

Perhaps, perhaps not - I've seen so many weird behaviors in circuits, I'm willing to believe almost anything ;D

Thanks DrAzzy that was the issue. After reversing the LED it now works according to the code.