diff --git a/Debug/AtTiny_alarm_clock.elf b/Debug/AtTiny_alarm_clock.elf index 40ee67a..511f0f0 100644 Binary files a/Debug/AtTiny_alarm_clock.elf and b/Debug/AtTiny_alarm_clock.elf differ diff --git a/Debug/AtTiny_alarm_clock.hex b/Debug/AtTiny_alarm_clock.hex index f146f7c..3ba6a68 100644 --- a/Debug/AtTiny_alarm_clock.hex +++ b/Debug/AtTiny_alarm_clock.hex @@ -1,5 +1,6 @@ :1000000014C019C018C017C016C015C014C013C042 :1000100012C011C010C00FC00EC00DC00CC00BC06C :100020000AC009C008C007C006C011241FBECFED1A -:0E003000CDBF02D002C0E4CFFFCFF894FFCFC7 +:10003000CDBF02D006C0E4CF8FEF87BB8AEA88BB72 +:06004000FECFF894FFCF93 :00000001FF diff --git a/Debug/AtTiny_alarm_clock.lss b/Debug/AtTiny_alarm_clock.lss index 29bd845..ef0f137 100644 --- a/Debug/AtTiny_alarm_clock.lss +++ b/Debug/AtTiny_alarm_clock.lss @@ -3,27 +3,27 @@ AtTiny_alarm_clock.elf: file format elf32-avr Sections: Idx Name Size VMA LMA File off Algn - 0 .text 0000003e 00000000 00000000 00000054 2**1 + 0 .text 00000046 00000000 00000000 00000054 2**1 CONTENTS, ALLOC, LOAD, READONLY, CODE - 1 .data 00000000 00800060 00800060 00000092 2**0 + 1 .data 00000000 00800060 00800060 0000009a 2**0 CONTENTS, ALLOC, LOAD, DATA - 2 .comment 00000030 00000000 00000000 00000092 2**0 + 2 .comment 00000030 00000000 00000000 0000009a 2**0 CONTENTS, READONLY - 3 .note.gnu.avr.deviceinfo 00000040 00000000 00000000 000000c4 2**2 + 3 .note.gnu.avr.deviceinfo 00000040 00000000 00000000 000000cc 2**2 CONTENTS, READONLY - 4 .debug_aranges 00000020 00000000 00000000 00000104 2**0 + 4 .debug_aranges 00000020 00000000 00000000 0000010c 2**0 CONTENTS, READONLY, DEBUGGING - 5 .debug_info 000004d3 00000000 00000000 00000124 2**0 + 5 .debug_info 000004de 00000000 00000000 0000012c 2**0 CONTENTS, READONLY, DEBUGGING - 6 .debug_abbrev 00000464 00000000 00000000 000005f7 2**0 + 6 .debug_abbrev 00000471 00000000 00000000 0000060a 2**0 CONTENTS, READONLY, DEBUGGING - 7 .debug_line 00000145 00000000 00000000 00000a5b 2**0 + 7 .debug_line 000001be 00000000 00000000 00000a7b 2**0 CONTENTS, READONLY, DEBUGGING - 8 .debug_frame 00000024 00000000 00000000 00000ba0 2**2 + 8 .debug_frame 00000024 00000000 00000000 00000c3c 2**2 CONTENTS, READONLY, DEBUGGING - 9 .debug_str 0000029b 00000000 00000000 00000bc4 2**0 + 9 .debug_str 000002a3 00000000 00000000 00000c60 2**0 CONTENTS, READONLY, DEBUGGING - 10 .debug_ranges 00000010 00000000 00000000 00000e5f 2**0 + 10 .debug_ranges 00000010 00000000 00000000 00000f03 2**0 CONTENTS, READONLY, DEBUGGING Disassembly of section .text: @@ -57,22 +57,30 @@ Disassembly of section .text: 2e: cf ed ldi r28, 0xDF ; 223 30: cd bf out 0x3d, r28 ; 61 32: 02 d0 rcall .+4 ; 0x38
- 34: 02 c0 rjmp .+4 ; 0x3a <_exit> + 34: 06 c0 rjmp .+12 ; 0x42 <_exit> 00000036 <__bad_interrupt>: 36: e4 cf rjmp .-56 ; 0x0 <__vectors> 00000038
: - #include int main(void) { - 38: ff cf rjmp .-2 ; 0x38
+ DDRB = 0xff; + 38: 8f ef ldi r24, 0xFF ; 255 + 3a: 87 bb out 0x17, r24 ; 23 + /* Replace with your application code */ + while (1) + { + PORTB = 0xAA; + 3c: 8a ea ldi r24, 0xAA ; 170 + 3e: 88 bb out 0x18, r24 ; 24 + 40: fe cf rjmp .-4 ; 0x3e <__SP_L__+0x1> -0000003a <_exit>: - 3a: f8 94 cli +00000042 <_exit>: + 42: f8 94 cli -0000003c <__stop_program>: - 3c: ff cf rjmp .-2 ; 0x3c <__stop_program> +00000044 <__stop_program>: + 44: ff cf rjmp .-2 ; 0x44 <__stop_program> diff --git a/Debug/AtTiny_alarm_clock.map b/Debug/AtTiny_alarm_clock.map index 52861a1..2916c96 100644 --- a/Debug/AtTiny_alarm_clock.map +++ b/Debug/AtTiny_alarm_clock.map @@ -150,7 +150,7 @@ END GROUP .rela.plt *(.rela.plt) -.text 0x00000000 0x3e +.text 0x00000000 0x46 *(.vectors) .vectors 0x00000000 0x2a C:/Program Files (x86)/Atmel/Studio/7.0/Packs/atmel/ATtiny_DFP/1.3.172/gcc/dev/attiny2313a/avr25/tiny-stack/crtattiny2313a.o 0x00000000 __vector_default @@ -228,13 +228,13 @@ END GROUP 0x00000036 __vector_20 0x00000038 . = ALIGN (0x2) *(.text.*) - .text.main 0x00000038 0x2 main.o + .text.main 0x00000038 0xa main.o 0x00000038 main - 0x0000003a . = ALIGN (0x2) + 0x00000042 . = ALIGN (0x2) *(.fini9) - .fini9 0x0000003a 0x0 c:/program files (x86)/atmel/studio/7.0/toolchain/avr8/avr8-gnu-toolchain/bin/../lib/gcc/avr/5.4.0/avr25/tiny-stack\libgcc.a(_exit.o) - 0x0000003a _exit - 0x0000003a exit + .fini9 0x00000042 0x0 c:/program files (x86)/atmel/studio/7.0/toolchain/avr8/avr8-gnu-toolchain/bin/../lib/gcc/avr/5.4.0/avr25/tiny-stack\libgcc.a(_exit.o) + 0x00000042 _exit + 0x00000042 exit *(.fini9) *(.fini8) *(.fini8) @@ -253,11 +253,11 @@ END GROUP *(.fini1) *(.fini1) *(.fini0) - .fini0 0x0000003a 0x4 c:/program files (x86)/atmel/studio/7.0/toolchain/avr8/avr8-gnu-toolchain/bin/../lib/gcc/avr/5.4.0/avr25/tiny-stack\libgcc.a(_exit.o) + .fini0 0x00000042 0x4 c:/program files (x86)/atmel/studio/7.0/toolchain/avr8/avr8-gnu-toolchain/bin/../lib/gcc/avr/5.4.0/avr25/tiny-stack\libgcc.a(_exit.o) *(.fini0) - 0x0000003e _etext = . + 0x00000046 _etext = . -.data 0x00800060 0x0 load address 0x0000003e +.data 0x00800060 0x0 load address 0x00000046 [!provide] PROVIDE (__data_start, .) *(.data) *(.data*) @@ -275,8 +275,8 @@ END GROUP *(.bss*) *(COMMON) [!provide] PROVIDE (__bss_end, .) - 0x0000003e __data_load_start = LOADADDR (.data) - 0x0000003e __data_load_end = (__data_load_start + SIZEOF (.data)) + 0x00000046 __data_load_start = LOADADDR (.data) + 0x00000046 __data_load_end = (__data_load_start + SIZEOF (.data)) .noinit 0x00800060 0x0 [!provide] PROVIDE (__noinit_start, .) @@ -355,30 +355,30 @@ END GROUP .debug_pubnames *(.debug_pubnames) -.debug_info 0x00000000 0x4d3 +.debug_info 0x00000000 0x4de *(.debug_info .gnu.linkonce.wi.*) .debug_info 0x00000000 0x456 C:/Program Files (x86)/Atmel/Studio/7.0/Packs/atmel/ATtiny_DFP/1.3.172/gcc/dev/attiny2313a/avr25/tiny-stack/crtattiny2313a.o - .debug_info 0x00000456 0x7d main.o + .debug_info 0x00000456 0x88 main.o -.debug_abbrev 0x00000000 0x464 +.debug_abbrev 0x00000000 0x471 *(.debug_abbrev) .debug_abbrev 0x00000000 0x41b C:/Program Files (x86)/Atmel/Studio/7.0/Packs/atmel/ATtiny_DFP/1.3.172/gcc/dev/attiny2313a/avr25/tiny-stack/crtattiny2313a.o - .debug_abbrev 0x0000041b 0x49 main.o + .debug_abbrev 0x0000041b 0x56 main.o -.debug_line 0x00000000 0x145 +.debug_line 0x00000000 0x1be *(.debug_line .debug_line.* .debug_line_end) .debug_line 0x00000000 0x10c C:/Program Files (x86)/Atmel/Studio/7.0/Packs/atmel/ATtiny_DFP/1.3.172/gcc/dev/attiny2313a/avr25/tiny-stack/crtattiny2313a.o - .debug_line 0x0000010c 0x39 main.o + .debug_line 0x0000010c 0xb2 main.o .debug_frame 0x00000000 0x24 *(.debug_frame) .debug_frame 0x00000000 0x24 main.o -.debug_str 0x00000000 0x29b +.debug_str 0x00000000 0x2a3 *(.debug_str) .debug_str 0x00000000 0x17b C:/Program Files (x86)/Atmel/Studio/7.0/Packs/atmel/ATtiny_DFP/1.3.172/gcc/dev/attiny2313a/avr25/tiny-stack/crtattiny2313a.o - .debug_str 0x0000017b 0x120 main.o - 0x154 (size before relaxing) + .debug_str 0x0000017b 0x128 main.o + 0x15c (size before relaxing) .debug_loc *(.debug_loc) diff --git a/Debug/AtTiny_alarm_clock.srec b/Debug/AtTiny_alarm_clock.srec index 2a55309..bef45b7 100644 --- a/Debug/AtTiny_alarm_clock.srec +++ b/Debug/AtTiny_alarm_clock.srec @@ -2,5 +2,6 @@ S01A0000417454696E795F616C61726D5F636C6F636B2E73726563DA S113000014C019C018C017C016C015C014C013C03E S113001012C011C010C00FC00EC00DC00CC00BC068 S11300200AC009C008C007C006C011241FBECFED16 -S1110030CDBF02D002C0E4CFFFCFF894FFCFC3 +S1130030CDBF02D006C0E4CF8FEF87BB8AEA88BB6E +S1090040FECFF894FFCF8F S9030000FC diff --git a/Debug/main.o b/Debug/main.o index 42d9345..7604c6e 100644 Binary files a/Debug/main.o and b/Debug/main.o differ diff --git a/main.c b/main.c index 293a00f..adef3d7 100644 --- a/main.c +++ b/main.c @@ -10,9 +10,11 @@ int main(void) { + DDRB = 0xff; /* Replace with your application code */ while (1) { + PORTB = 0xAA; } }