RUN At power-on Sint the phone will be checked, if it does not respond an idle time of 1h will be execuded blinking 5 times every 10sec. You can terminate idle time by grounding the DEBUG switch.
SETUP: cell.h: On/off port and PIN. Makefile: F_CPU if different from 1Mhz CPU clock. init.c: All PORT setup. adc.c: Choose which ADC for wind direction. adc.h: ADC ratio if not 0 - 4V. sht11.h: Port and PIN used by SHT11 synth.h: Port and PIN used by Synth.
How to set LFUSE bit for external Ceramic OSC at 4Mhz: avrdude -p atmega1284p -c stk500v2 -P /dev/ttyUSB0 -t -u goes into command line mode, then issue: dump lfuse and change for atmega16 to 0xee with: write lfuse 0 0xee
on atmega16 disable JTAG and free PORTC with: dump hfuse write hfuse 0 0xd9
Remember 1 means UNPROGRAMMED From datasheet pag.260 HFUSE d = 1101 = OCDEN + JTAGEN + CKOPT are UNPROGRAMMED (default 9 = 1001) 9 = 1001 = EESAVE + BOOTRST are UNPROGRAMMED (default) only JTAGEN has been changed.
pag. 261 LFUSE e = 1110 = BODLEVEL + BODEN + SUT1 are UNPROGRAMMED (default) e = 1110 = CLKSEL3 + CLKSEL2 + CLKSEL1 are UNPROGRAMMED (default 1 = 0001) only CLKSEL3, 2, 1, 0 has been changed.
ATMEGA1284p LFUSE: default 0x62, -> HFUSE: default 0x99 -> 0xd9