// Copyright 2021 KoroLion (https://github.com/KoroLion)

#include "avr_asm_lib.h"

const unsigned char LED_TEMP = 30;

int main() {
  lm35_init(17);
  led_init();
  Serial.begin(9600);

  while (true) {
    unsigned char t = lm35_read();
    Serial.println((short)t);
    if (t >= LED_TEMP) {
      led_enable();
    } else {
      led_disable();
    }
  }

  return 0;
}
