42 #include <avr/eeprom.h>
43 #include <util/delay.h>
55 uint8_t ping_response;
78 *(str+1) = (val % 10) +
'0';
79 *str = (val / 10) +
'0';
106 if(temp_mode == TEMP_UNIT_CELCIUS){
145 if(0xFF == eeprom_read_byte(EEPROM_DEBUG_ADDR)){
171 PRR |= (1 << PRTIM1) | (1 << PRSPI);
178 while(!(UCSR0A & (1 << TXC0)));
192 PRR &= ~((1 << PRTIM1) | (1 << PRSPI));
225 while (ENTER_PORT & (1<<ENTER_PIN)) {
234 while(!(UCSR0A & (1 << TXC0)));
334 eeprom_write_byte(EEPROM_DEBUG_ADDR, 0xFF);
338 MCUCR &= ~(1 << JTD);
339 MCUCR &= ~(1 << JTD);
341 eeprom_write_byte(EEPROM_DEBUG_ADDR, 0x01);
357 temp_mode = TEMP_UNIT_CELCIUS;
360 temp_mode = TEMP_UNIT_FAHRENHEIT;
376 int16_t result =
temp_get(temp_mode);
379 if(temp_mode == TEMP_UNIT_CELCIUS){
479 str[9]=
'm';str[10]=
'V';str[11]=0;