From fbb87d2772d3e3c904eabf09c1b0b8dbfe7127f1 Mon Sep 17 00:00:00 2001 From: test Date: Mon, 16 Jul 2018 17:04:58 +0200 Subject: [PATCH] added LCD Lib --- Libs/LCD4/.cproject | 1710 +++++++++++++++++ Libs/LCD4/.dep/avrmb2313_lcd.o.d | 23 + Libs/LCD4/.dep/lcd_wait.o.d | 23 + Libs/LCD4/.dep/lcdtest.o.d | 23 + Libs/LCD4/.project | 82 + .../.settings/de.innot.avreclipse.core.prefs | 24 + Libs/LCD4/Debug/LCD4.elf | Bin 0 -> 9971 bytes Libs/LCD4/Debug/LCD4.lss | 673 +++++++ Libs/LCD4/Debug/LCD4.map | 370 ++++ Libs/LCD4/Debug/lcd4.d | 3 + Libs/LCD4/Debug/lcd4.o | Bin 0 -> 6252 bytes Libs/LCD4/Debug/lcd_wait.d | 3 + Libs/LCD4/Debug/lcd_wait.o | Bin 0 -> 3640 bytes Libs/LCD4/Debug/lcdtest.d | 3 + Libs/LCD4/Debug/lcdtest.o | Bin 0 -> 3908 bytes Libs/LCD4/Debug/makefile | 72 + Libs/LCD4/Debug/objects.mk | 7 + Libs/LCD4/Debug/sources.mk | 23 + Libs/LCD4/Debug/subdir.mk | 30 + Libs/LCD4/Makefile | 429 +++++ .../LCD4/avrmb2313_notkermobil/LCD4.eep | 0 Libs/LCD4/avrmb2313_notkermobil/LCD4.elf | Bin 0 -> 9987 bytes Libs/LCD4/avrmb2313_notkermobil/LCD4.hex | 65 + Libs/LCD4/avrmb2313_notkermobil/LCD4.lss | 727 +++++++ Libs/LCD4/avrmb2313_notkermobil/LCD4.map | 368 ++++ Libs/LCD4/avrmb2313_notkermobil/lcd4.d | 3 + Libs/LCD4/avrmb2313_notkermobil/lcd4.o | Bin 0 -> 6208 bytes Libs/LCD4/avrmb2313_notkermobil/lcd_wait.d | 3 + Libs/LCD4/avrmb2313_notkermobil/lcd_wait.o | Bin 0 -> 3676 bytes Libs/LCD4/avrmb2313_notkermobil/lcdtest.d | 3 + Libs/LCD4/avrmb2313_notkermobil/lcdtest.o | Bin 0 -> 4128 bytes Libs/LCD4/avrmb2313_notkermobil/makefile | 90 + Libs/LCD4/avrmb2313_notkermobil/objects.mk | 7 + Libs/LCD4/avrmb2313_notkermobil/sources.mk | 25 + Libs/LCD4/avrmb2313_notkermobil/subdir.mk | 30 + Libs/LCD4/lcd4.c | 132 ++ Libs/LCD4/lcd4.c2 | 135 ++ Libs/LCD4/lcd4.h | 95 + Libs/LCD4/lcd_wait.c | 9 + Libs/LCD4/lcdtest.c | 34 + 40 files changed, 5224 insertions(+) create mode 100644 Libs/LCD4/.cproject create mode 100644 Libs/LCD4/.dep/avrmb2313_lcd.o.d create mode 100644 Libs/LCD4/.dep/lcd_wait.o.d create mode 100644 Libs/LCD4/.dep/lcdtest.o.d create mode 100644 Libs/LCD4/.project create mode 100644 Libs/LCD4/.settings/de.innot.avreclipse.core.prefs create mode 100644 Libs/LCD4/Debug/LCD4.elf create mode 100644 Libs/LCD4/Debug/LCD4.lss create mode 100644 Libs/LCD4/Debug/LCD4.map create mode 100644 Libs/LCD4/Debug/lcd4.d create mode 100644 Libs/LCD4/Debug/lcd4.o create mode 100644 Libs/LCD4/Debug/lcd_wait.d create mode 100644 Libs/LCD4/Debug/lcd_wait.o create mode 100644 Libs/LCD4/Debug/lcdtest.d create mode 100644 Libs/LCD4/Debug/lcdtest.o create mode 100644 Libs/LCD4/Debug/makefile create mode 100644 Libs/LCD4/Debug/objects.mk create mode 100644 Libs/LCD4/Debug/sources.mk create mode 100644 Libs/LCD4/Debug/subdir.mk create mode 100644 Libs/LCD4/Makefile rename Debug/AtTiny_alarm_clock.eep => Libs/LCD4/avrmb2313_notkermobil/LCD4.eep (100%) create mode 100644 Libs/LCD4/avrmb2313_notkermobil/LCD4.elf create mode 100644 Libs/LCD4/avrmb2313_notkermobil/LCD4.hex create mode 100644 Libs/LCD4/avrmb2313_notkermobil/LCD4.lss create mode 100644 Libs/LCD4/avrmb2313_notkermobil/LCD4.map create mode 100644 Libs/LCD4/avrmb2313_notkermobil/lcd4.d create mode 100644 Libs/LCD4/avrmb2313_notkermobil/lcd4.o create mode 100644 Libs/LCD4/avrmb2313_notkermobil/lcd_wait.d create mode 100644 Libs/LCD4/avrmb2313_notkermobil/lcd_wait.o create mode 100644 Libs/LCD4/avrmb2313_notkermobil/lcdtest.d create mode 100644 Libs/LCD4/avrmb2313_notkermobil/lcdtest.o create mode 100644 Libs/LCD4/avrmb2313_notkermobil/makefile create mode 100644 Libs/LCD4/avrmb2313_notkermobil/objects.mk create mode 100644 Libs/LCD4/avrmb2313_notkermobil/sources.mk create mode 100644 Libs/LCD4/avrmb2313_notkermobil/subdir.mk create mode 100644 Libs/LCD4/lcd4.c create mode 100644 Libs/LCD4/lcd4.c2 create mode 100644 Libs/LCD4/lcd4.h create mode 100644 Libs/LCD4/lcd_wait.c create mode 100644 Libs/LCD4/lcdtest.c diff --git a/Libs/LCD4/.cproject b/Libs/LCD4/.cproject new file mode 100644 index 0000000..93ab055 --- /dev/null +++ b/Libs/LCD4/.cproject @@ -0,0 +1,1710 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Libs/LCD4/.dep/avrmb2313_lcd.o.d b/Libs/LCD4/.dep/avrmb2313_lcd.o.d new file mode 100644 index 0000000..1cb0373 --- /dev/null +++ b/Libs/LCD4/.dep/avrmb2313_lcd.o.d @@ -0,0 +1,23 @@ +avrmb2313_lcd.o: avrmb2313_lcd.c c:/winavr/bin/../avr/include/inttypes.h \ + c:/winavr/bin/../avr/include/stdint.h \ + c:/winavr/bin/../avr/include/avr/io.h \ + c:/winavr/bin/../avr/include/avr/sfr_defs.h \ + c:/winavr/bin/../avr/include/avr/io2313.h \ + c:/winavr/bin/../avr/include/avr/portpins.h \ + c:/winavr/bin/../avr/include/avr/version.h avrmb2313_lcd.h + +c:/winavr/bin/../avr/include/inttypes.h: + +c:/winavr/bin/../avr/include/stdint.h: + +c:/winavr/bin/../avr/include/avr/io.h: + +c:/winavr/bin/../avr/include/avr/sfr_defs.h: + +c:/winavr/bin/../avr/include/avr/io2313.h: + +c:/winavr/bin/../avr/include/avr/portpins.h: + +c:/winavr/bin/../avr/include/avr/version.h: + +avrmb2313_lcd.h: diff --git a/Libs/LCD4/.dep/lcd_wait.o.d b/Libs/LCD4/.dep/lcd_wait.o.d new file mode 100644 index 0000000..f440554 --- /dev/null +++ b/Libs/LCD4/.dep/lcd_wait.o.d @@ -0,0 +1,23 @@ +lcd_wait.o: lcd_wait.c c:/winavr/bin/../avr/include/inttypes.h \ + c:/winavr/bin/../avr/include/stdint.h \ + c:/winavr/bin/../avr/include/avr/io.h \ + c:/winavr/bin/../avr/include/avr/sfr_defs.h \ + c:/winavr/bin/../avr/include/avr/io2313.h \ + c:/winavr/bin/../avr/include/avr/portpins.h \ + c:/winavr/bin/../avr/include/avr/version.h avrmb2313_lcd.h + +c:/winavr/bin/../avr/include/inttypes.h: + +c:/winavr/bin/../avr/include/stdint.h: + +c:/winavr/bin/../avr/include/avr/io.h: + +c:/winavr/bin/../avr/include/avr/sfr_defs.h: + +c:/winavr/bin/../avr/include/avr/io2313.h: + +c:/winavr/bin/../avr/include/avr/portpins.h: + +c:/winavr/bin/../avr/include/avr/version.h: + +avrmb2313_lcd.h: diff --git a/Libs/LCD4/.dep/lcdtest.o.d b/Libs/LCD4/.dep/lcdtest.o.d new file mode 100644 index 0000000..83797fc --- /dev/null +++ b/Libs/LCD4/.dep/lcdtest.o.d @@ -0,0 +1,23 @@ +lcdtest.o: lcdtest.c c:/winavr/bin/../avr/include/inttypes.h \ + c:/winavr/bin/../avr/include/stdint.h \ + c:/winavr/bin/../avr/include/avr/io.h \ + c:/winavr/bin/../avr/include/avr/sfr_defs.h \ + c:/winavr/bin/../avr/include/avr/io2313.h \ + c:/winavr/bin/../avr/include/avr/portpins.h \ + c:/winavr/bin/../avr/include/avr/version.h avrmb2313_lcd.h + +c:/winavr/bin/../avr/include/inttypes.h: + +c:/winavr/bin/../avr/include/stdint.h: + +c:/winavr/bin/../avr/include/avr/io.h: + +c:/winavr/bin/../avr/include/avr/sfr_defs.h: + +c:/winavr/bin/../avr/include/avr/io2313.h: + +c:/winavr/bin/../avr/include/avr/portpins.h: + +c:/winavr/bin/../avr/include/avr/version.h: + +avrmb2313_lcd.h: diff --git a/Libs/LCD4/.project b/Libs/LCD4/.project new file mode 100644 index 0000000..f32778d --- /dev/null +++ b/Libs/LCD4/.project @@ -0,0 +1,82 @@ + + + LCD4 + + + + + + org.eclipse.cdt.managedbuilder.core.genmakebuilder + clean,full,incremental, + + + ?name? + + + + org.eclipse.cdt.make.core.append_environment + true + + + org.eclipse.cdt.make.core.autoBuildTarget + all + + + org.eclipse.cdt.make.core.buildArguments + + + + org.eclipse.cdt.make.core.buildCommand + make + + + org.eclipse.cdt.make.core.buildLocation + ${workspace_loc:/LCD4/Debug} + + + org.eclipse.cdt.make.core.cleanBuildTarget + clean + + + org.eclipse.cdt.make.core.contents + org.eclipse.cdt.make.core.activeConfigSettings + + + org.eclipse.cdt.make.core.enableAutoBuild + false + + + org.eclipse.cdt.make.core.enableCleanBuild + true + + + org.eclipse.cdt.make.core.enableFullBuild + true + + + org.eclipse.cdt.make.core.fullBuildTarget + all + + + org.eclipse.cdt.make.core.stopOnError + true + + + org.eclipse.cdt.make.core.useDefaultBuildCmd + true + + + + + org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder + + + + + + org.eclipse.cdt.core.cnature + org.eclipse.cdt.managedbuilder.core.managedBuildNature + org.eclipse.cdt.managedbuilder.core.ScannerConfigNature + de.innot.avreclipse.core.avrnature + + diff --git a/Libs/LCD4/.settings/de.innot.avreclipse.core.prefs b/Libs/LCD4/.settings/de.innot.avreclipse.core.prefs new file mode 100644 index 0000000..5e2ff13 --- /dev/null +++ b/Libs/LCD4/.settings/de.innot.avreclipse.core.prefs @@ -0,0 +1,24 @@ +#Sat Mar 06 14:56:52 CET 2010 +avrtarget/ClockFrequency=10000000 +avrtarget/ExtRAMSize=0 +avrtarget/ExtendedRAM=false +avrtarget/MCUType=attiny2313 +avrtarget/UseEEPROM=false +avrtarget/UseExtendedRAMforHeap=true +avrtarget/avrdude/BitBangDelay= +avrtarget/avrdude/Bitclock= +avrtarget/avrdude/EEPROMFile= +avrtarget/avrdude/EEPROMFromConfig=true +avrtarget/avrdude/FlashFile= +avrtarget/avrdude/FlashFromConfig=true +avrtarget/avrdude/NoChipErase=false +avrtarget/avrdude/NoSigCheck=false +avrtarget/avrdude/NoVerify=false +avrtarget/avrdude/NoWrite=false +avrtarget/avrdude/OtherOptions= +avrtarget/avrdude/ProgrammerID=programmerconfig.1 +avrtarget/avrdude/UseCounter=false +avrtarget/avrdude/WriteEEPROM=false +avrtarget/avrdude/WriteFlash=true +avrtarget/perConfig=false +eclipse.preferences.version=1 diff --git a/Libs/LCD4/Debug/LCD4.elf b/Libs/LCD4/Debug/LCD4.el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y#13$-z2Sv_0lolUssI20 literal 0 HcmV?d00001 diff --git a/Libs/LCD4/Debug/LCD4.lss b/Libs/LCD4/Debug/LCD4.lss new file mode 100644 index 0000000..d3c34b8 --- /dev/null +++ b/Libs/LCD4/Debug/LCD4.lss @@ -0,0 +1,673 @@ + +LCD4.elf: file format elf32-avr + +Sections: +Idx Name Size VMA LMA File off Algn + 0 .text 0000040a 00000000 00000000 00000054 2**1 + CONTENTS, ALLOC, LOAD, READONLY, CODE + 1 .stab 0000111c 00000000 00000000 00000460 2**2 + CONTENTS, READONLY, DEBUGGING + 2 .stabstr 000007cb 00000000 00000000 0000157c 2**0 + CONTENTS, READONLY, DEBUGGING +Disassembly of section .text: + +00000000 <__vectors>: + 0: 0c 94 2a 00 jmp 0x54 ; 0x54 <__ctors_end> + 4: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 8: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + c: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 10: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 14: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 18: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 1c: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 20: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 24: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 28: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 2c: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 30: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 34: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 38: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 3c: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 40: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 44: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 48: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 4c: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + 50: 0c 94 47 00 jmp 0x8e ; 0x8e <__bad_interrupt> + +00000054 <__ctors_end>: + 54: 11 24 eor r1, r1 + 56: 1f be out 0x3f, r1 ; 63 + 58: cf e5 ldi r28, 0x5F ; 95 + 5a: d4 e0 ldi r29, 0x04 ; 4 + 5c: de bf out 0x3e, r29 ; 62 + 5e: cd bf out 0x3d, r28 ; 61 + +00000060 <__do_copy_data>: + 60: 10 e0 ldi r17, 0x00 ; 0 + 62: a0 e6 ldi r26, 0x60 ; 96 + 64: b0 e0 ldi r27, 0x00 ; 0 + 66: ea e0 ldi r30, 0x0A ; 10 + 68: f4 e0 ldi r31, 0x04 ; 4 + 6a: 02 c0 rjmp .+4 ; 0x70 <.do_copy_data_start> + +0000006c <.do_copy_data_loop>: + 6c: 05 90 lpm r0, Z+ + 6e: 0d 92 st X+, r0 + +00000070 <.do_copy_data_start>: + 70: a0 36 cpi r26, 0x60 ; 96 + 72: b1 07 cpc r27, r17 + 74: d9 f7 brne .-10 ; 0x6c <.do_copy_data_loop> + +00000076 <__do_clear_bss>: + 76: 10 e0 ldi r17, 0x00 ; 0 + 78: a0 e6 ldi r26, 0x60 ; 96 + 7a: b0 e0 ldi r27, 0x00 ; 0 + 7c: 01 c0 rjmp .+2 ; 0x80 <.do_clear_bss_start> + +0000007e <.do_clear_bss_loop>: + 7e: 1d 92 st X+, r1 + +00000080 <.do_clear_bss_start>: + 80: a0 36 cpi r26, 0x60 ; 96 + 82: b1 07 cpc r27, r17 + 84: e1 f7 brne .-8 ; 0x7e <.do_clear_bss_loop> + 86: 0e 94 cc 01 call 0x398 ; 0x398
+ 8a: 0c 94 03 02 jmp 0x406 ; 0x406 <_exit> + +0000008e <__bad_interrupt>: + 8e: 0c 94 00 00 jmp 0 ; 0x0 <__heap_end> + +00000092 : +/* end Prototypes */ + +#define lcd_mask_Write_Adress(position) ((position & 0x7F)| lcd_SET_DD_RAM) +// 4-Bit to be added, no indent +// enum whichtype{instruct, data}; +void lcd_init(void){ + 92: df 93 push r29 + 94: cf 93 push r28 + 96: cd b7 in r28, 0x3d ; 61 + 98: de b7 in r29, 0x3e ; 62 + /* setting up ports first */ + lcd_dataport_DDR|=lcd_dataport_mask; + 9a: a7 e3 ldi r26, 0x37 ; 55 + 9c: b0 e0 ldi r27, 0x00 ; 0 + 9e: e7 e3 ldi r30, 0x37 ; 55 + a0: f0 e0 ldi r31, 0x00 ; 0 + a2: 80 81 ld r24, Z + a4: 80 6f ori r24, 0xF0 ; 240 + a6: 8c 93 st X, r24 + set_lcd_RS_DDR; + a8: a1 e3 ldi r26, 0x31 ; 49 + aa: b0 e0 ldi r27, 0x00 ; 0 + ac: e1 e3 ldi r30, 0x31 ; 49 + ae: f0 e0 ldi r31, 0x00 ; 0 + b0: 80 81 ld r24, Z + b2: 88 60 ori r24, 0x08 ; 8 + b4: 8c 93 st X, r24 + set_lcd_E_DDR; + b6: a1 e3 ldi r26, 0x31 ; 49 + b8: b0 e0 ldi r27, 0x00 ; 0 + ba: e1 e3 ldi r30, 0x31 ; 49 + bc: f0 e0 ldi r31, 0x00 ; 0 + be: 80 81 ld r24, Z + c0: 84 60 ori r24, 0x04 ; 4 + c2: 8c 93 st X, r24 + /* end setting up ports */ + //lcd_dataport=0xff; + set_lcd_RS; + c4: a2 e3 ldi r26, 0x32 ; 50 + c6: b0 e0 ldi r27, 0x00 ; 0 + c8: e2 e3 ldi r30, 0x32 ; 50 + ca: f0 e0 ldi r31, 0x00 ; 0 + cc: 80 81 ld r24, Z + ce: 88 60 ori r24, 0x08 ; 8 + d0: 8c 93 st X, r24 + set_lcd_E; + d2: a2 e3 ldi r26, 0x32 ; 50 + d4: b0 e0 ldi r27, 0x00 ; 0 + d6: e2 e3 ldi r30, 0x32 ; 50 + d8: f0 e0 ldi r31, 0x00 ; 0 + da: 80 81 ld r24, Z + dc: 84 60 ori r24, 0x04 ; 4 + de: 8c 93 st X, r24 + lcd_5ms(); + e0: 0e 94 ab 00 call 0x156 ; 0x156 + lcd_5ms(); + e4: 0e 94 ab 00 call 0x156 ; 0x156 + lcd_5ms(); + e8: 0e 94 ab 00 call 0x156 ; 0x156 + lcd_instruct(lcd_SET_FUNCTION_8BIT); + lcd_instruct(lcd_SET_FUNCTION_8BIT); + lcd_instruct(lcd_SET_FUNCTION_8BIT|lcd_SET_FUNCTION_2LINE|lcd_SET_FUNCTION_7X5); + #endif + #ifdef lcd_bus4 + lcd_instruct(lcd_SET_FUNCTION_8BIT); + ec: 80 e3 ldi r24, 0x30 ; 48 + ee: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + lcd_5ms(); + f2: 0e 94 ab 00 call 0x156 ; 0x156 + lcd_instruct(lcd_SET_FUNCTION_8BIT); + f6: 80 e3 ldi r24, 0x30 ; 48 + f8: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + wait_100us(); + fc: 0e 94 a9 01 call 0x352 ; 0x352 + lcd_instruct(lcd_SET_FUNCTION_8BIT); + 100: 80 e3 ldi r24, 0x30 ; 48 + 102: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + wait_100us(); + 106: 0e 94 a9 01 call 0x352 ; 0x352 + lcd_instruct(lcd_SET_FUNCTION_4BIT); + 10a: 80 e2 ldi r24, 0x20 ; 32 + 10c: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + wait_100us(); + 110: 0e 94 a9 01 call 0x352 ; 0x352 + lcd_instruct(lcd_SET_FUNCTION_2LINE|lcd_SET_FUNCTION_7X5); + 114: 88 e2 ldi r24, 0x28 ; 40 + 116: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + #endif + + wait_100us(); + 11a: 0e 94 a9 01 call 0x352 ; 0x352 + lcd_instruct(lcd_DISPLAY_OO_OFF); + 11e: 88 e0 ldi r24, 0x08 ; 8 + 120: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + wait_100us(); + 124: 0e 94 a9 01 call 0x352 ; 0x352 + lcd_instruct(lcd_DISPLAY_CLEAR); + 128: 81 e0 ldi r24, 0x01 ; 1 + 12a: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + lcd_5ms(); + 12e: 0e 94 ab 00 call 0x156 ; 0x156 + lcd_instruct(lcd_DISPLAY_OO_ON|lcd_DISPLAY_OO_CURSOR_OFF); + 132: 8c e0 ldi r24, 0x0C ; 12 + 134: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + wait_100us(); + 138: 0e 94 a9 01 call 0x352 ; 0x352 + lcd_instruct(lcd_ENTRY_MODE_SET|lcd_ENTRY_MODE_SET_INCREASE | lcd_ENTRY_MS_DISPLAY_NOT_S); + 13c: 86 e0 ldi r24, 0x06 ; 6 + 13e: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + wait_100us(); + 142: 0e 94 a9 01 call 0x352 ; 0x352 + lcd_instruct(lcd_RETURN_HOME); + 146: 82 e0 ldi r24, 0x02 ; 2 + 148: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + lcd_5ms(); + 14c: 0e 94 ab 00 call 0x156 ; 0x156 +} + 150: cf 91 pop r28 + 152: df 91 pop r29 + 154: 08 95 ret + +00000156 : + +void lcd_5ms(void){ + 156: df 93 push r29 + 158: cf 93 push r28 + 15a: 0f 92 push r0 + 15c: cd b7 in r28, 0x3d ; 61 + 15e: de b7 in r29, 0x3e ; 62 + for(uint8_t i=50;i>0;i--){ + 160: 82 e3 ldi r24, 0x32 ; 50 + 162: 89 83 std Y+1, r24 ; 0x01 + 164: 05 c0 rjmp .+10 ; 0x170 + wait_100us(); + 166: 0e 94 a9 01 call 0x352 ; 0x352 + lcd_instruct(lcd_RETURN_HOME); + lcd_5ms(); +} + +void lcd_5ms(void){ + for(uint8_t i=50;i>0;i--){ + 16a: 89 81 ldd r24, Y+1 ; 0x01 + 16c: 81 50 subi r24, 0x01 ; 1 + 16e: 89 83 std Y+1, r24 ; 0x01 + 170: 89 81 ldd r24, Y+1 ; 0x01 + 172: 88 23 and r24, r24 + 174: c1 f7 brne .-16 ; 0x166 + wait_100us(); + } + } + 176: 0f 90 pop r0 + 178: cf 91 pop r28 + 17a: df 91 pop r29 + 17c: 08 95 ret + +0000017e : + +void lcd_1s(void){ + 17e: df 93 push r29 + 180: cf 93 push r28 + 182: 0f 92 push r0 + 184: cd b7 in r28, 0x3d ; 61 + 186: de b7 in r29, 0x3e ; 62 + for(uint8_t i=200;i>0;i--){ + 188: 88 ec ldi r24, 0xC8 ; 200 + 18a: 89 83 std Y+1, r24 ; 0x01 + 18c: 05 c0 rjmp .+10 ; 0x198 + lcd_5ms(); + 18e: 0e 94 ab 00 call 0x156 ; 0x156 + wait_100us(); + } + } + +void lcd_1s(void){ + for(uint8_t i=200;i>0;i--){ + 192: 89 81 ldd r24, Y+1 ; 0x01 + 194: 81 50 subi r24, 0x01 ; 1 + 196: 89 83 std Y+1, r24 ; 0x01 + 198: 89 81 ldd r24, Y+1 ; 0x01 + 19a: 88 23 and r24, r24 + 19c: c1 f7 brne .-16 ; 0x18e + lcd_5ms(); + } + } + 19e: 0f 90 pop r0 + 1a0: cf 91 pop r28 + 1a2: df 91 pop r29 + 1a4: 08 95 ret + +000001a6 : + +void lcd_instruct(uint8_t zeichen){ + 1a6: df 93 push r29 + 1a8: cf 93 push r28 + 1aa: 0f 92 push r0 + 1ac: cd b7 in r28, 0x3d ; 61 + 1ae: de b7 in r29, 0x3e ; 62 + 1b0: 89 83 std Y+1, r24 ; 0x01 + lcd_write(instruct,zeichen,0); + 1b2: 84 e0 ldi r24, 0x04 ; 4 + 1b4: 69 81 ldd r22, Y+1 ; 0x01 + 1b6: 40 e0 ldi r20, 0x00 ; 0 + 1b8: 0e 94 e2 00 call 0x1c4 ; 0x1c4 + } + 1bc: 0f 90 pop r0 + 1be: cf 91 pop r28 + 1c0: df 91 pop r29 + 1c2: 08 95 ret + +000001c4 : + +void lcd_write(uint8_t lcd_whichwrite, uint8_t zeichen, uint8_t position){ + 1c4: df 93 push r29 + 1c6: cf 93 push r28 + 1c8: 00 d0 rcall .+0 ; 0x1ca + 1ca: 00 d0 rcall .+0 ; 0x1cc + 1cc: 0f 92 push r0 + 1ce: cd b7 in r28, 0x3d ; 61 + 1d0: de b7 in r29, 0x3e ; 62 + 1d2: 89 83 std Y+1, r24 ; 0x01 + 1d4: 6a 83 std Y+2, r22 ; 0x02 + 1d6: 4b 83 std Y+3, r20 ; 0x03 + switch (lcd_whichwrite){ + 1d8: 89 81 ldd r24, Y+1 ; 0x01 + 1da: 28 2f mov r18, r24 + 1dc: 30 e0 ldi r19, 0x00 ; 0 + 1de: 3d 83 std Y+5, r19 ; 0x05 + 1e0: 2c 83 std Y+4, r18 ; 0x04 + 1e2: 8c 81 ldd r24, Y+4 ; 0x04 + 1e4: 9d 81 ldd r25, Y+5 ; 0x05 + 1e6: 84 30 cpi r24, 0x04 ; 4 + 1e8: 91 05 cpc r25, r1 + 1ea: 7c f4 brge .+30 ; 0x20a + 1ec: 2c 81 ldd r18, Y+4 ; 0x04 + 1ee: 3d 81 ldd r19, Y+5 ; 0x05 + 1f0: 22 30 cpi r18, 0x02 ; 2 + 1f2: 31 05 cpc r19, r1 + 1f4: bc f4 brge .+46 ; 0x224 + 1f6: 8c 81 ldd r24, Y+4 ; 0x04 + 1f8: 9d 81 ldd r25, Y+5 ; 0x05 + 1fa: 00 97 sbiw r24, 0x00 ; 0 + 1fc: 01 f1 breq .+64 ; 0x23e + 1fe: 2c 81 ldd r18, Y+4 ; 0x04 + 200: 3d 81 ldd r19, Y+5 ; 0x05 + 202: 21 30 cpi r18, 0x01 ; 1 + 204: 31 05 cpc r19, r1 + 206: b9 f0 breq .+46 ; 0x236 + 208: 21 c0 rjmp .+66 ; 0x24c + 20a: 8c 81 ldd r24, Y+4 ; 0x04 + 20c: 9d 81 ldd r25, Y+5 ; 0x05 + 20e: 84 30 cpi r24, 0x04 ; 4 + 210: 91 05 cpc r25, r1 + 212: e1 f4 brne .+56 ; 0x24c + case instruct : + unset_lcd_RS; + 214: a2 e3 ldi r26, 0x32 ; 50 + 216: b0 e0 ldi r27, 0x00 ; 0 + 218: e2 e3 ldi r30, 0x32 ; 50 + 21a: f0 e0 ldi r31, 0x00 ; 0 + 21c: 80 81 ld r24, Z + 21e: 87 7f andi r24, 0xF7 ; 247 + 220: 8c 93 st X, r24 + 222: 14 c0 rjmp .+40 ; 0x24c + break; + case line2: + case line1: + position = position & 0x3f; + 224: 8b 81 ldd r24, Y+3 ; 0x03 + 226: 8f 73 andi r24, 0x3F ; 63 + 228: 8b 83 std Y+3, r24 ; 0x03 + if (lcd_whichwrite == line2){ position=position + 0x40; }; + 22a: 89 81 ldd r24, Y+1 ; 0x01 + 22c: 83 30 cpi r24, 0x03 ; 3 + 22e: 19 f4 brne .+6 ; 0x236 + 230: 8b 81 ldd r24, Y+3 ; 0x03 + 232: 80 5c subi r24, 0xC0 ; 192 + 234: 8b 83 std Y+3, r24 ; 0x03 + case therepos: + lcd_instruct(lcd_mask_Write_Adress(position)); + 236: 8b 81 ldd r24, Y+3 ; 0x03 + 238: 80 68 ori r24, 0x80 ; 128 + 23a: 0e 94 d3 00 call 0x1a6 ; 0x1a6 + case here: + set_lcd_RS; + 23e: a2 e3 ldi r26, 0x32 ; 50 + 240: b0 e0 ldi r27, 0x00 ; 0 + 242: e2 e3 ldi r30, 0x32 ; 50 + 244: f0 e0 ldi r31, 0x00 ; 0 + 246: 80 81 ld r24, Z + 248: 88 60 ori r24, 0x08 ; 8 + 24a: 8c 93 st X, r24 + lcd_dataport=(lcd_dataport & ~lcd_dataport_mask) | (zeichen & lcd_dataport_mask); + lcd_dataport=(lcd_dataport & ~lcd_dataport_mask) | (zeichen & lcd_dataport_mask); + #endif + + #ifdef lcd_bus4 + zeichen = zeichen << 4; + 24c: 8a 81 ldd r24, Y+2 ; 0x02 + 24e: 82 95 swap r24 + 250: 80 7f andi r24, 0xF0 ; 240 + 252: 8a 83 std Y+2, r24 ; 0x02 + unset_lcd_E; + 254: a2 e3 ldi r26, 0x32 ; 50 + 256: b0 e0 ldi r27, 0x00 ; 0 + 258: e2 e3 ldi r30, 0x32 ; 50 + 25a: f0 e0 ldi r31, 0x00 ; 0 + 25c: 80 81 ld r24, Z + 25e: 8b 7f andi r24, 0xFB ; 251 + 260: 8c 93 st X, r24 + wait_100us(); + 262: 0e 94 a9 01 call 0x352 ; 0x352 + set_lcd_E; + 266: a2 e3 ldi r26, 0x32 ; 50 + 268: b0 e0 ldi r27, 0x00 ; 0 + 26a: e2 e3 ldi r30, 0x32 ; 50 + 26c: f0 e0 ldi r31, 0x00 ; 0 + 26e: 80 81 ld r24, Z + 270: 84 60 ori r24, 0x04 ; 4 + 272: 8c 93 st X, r24 + set_lcd_E; + 274: a2 e3 ldi r26, 0x32 ; 50 + 276: b0 e0 ldi r27, 0x00 ; 0 + 278: e2 e3 ldi r30, 0x32 ; 50 + 27a: f0 e0 ldi r31, 0x00 ; 0 + 27c: 80 81 ld r24, Z + 27e: 84 60 ori r24, 0x04 ; 4 + 280: 8c 93 st X, r24 + lcd_dataport=(lcd_dataport & ~lcd_dataport_mask) | (zeichen & lcd_dataport_mask); + 282: a8 e3 ldi r26, 0x38 ; 56 + 284: b0 e0 ldi r27, 0x00 ; 0 + 286: e8 e3 ldi r30, 0x38 ; 56 + 288: f0 e0 ldi r31, 0x00 ; 0 + 28a: 80 81 ld r24, Z + 28c: 98 2f mov r25, r24 + 28e: 9f 70 andi r25, 0x0F ; 15 + 290: 8a 81 ldd r24, Y+2 ; 0x02 + 292: 80 7f andi r24, 0xF0 ; 240 + 294: 89 2b or r24, r25 + 296: 8c 93 st X, r24 + lcd_dataport=(lcd_dataport & ~lcd_dataport_mask) | (zeichen & lcd_dataport_mask); + 298: a8 e3 ldi r26, 0x38 ; 56 + 29a: b0 e0 ldi r27, 0x00 ; 0 + 29c: e8 e3 ldi r30, 0x38 ; 56 + 29e: f0 e0 ldi r31, 0x00 ; 0 + 2a0: 80 81 ld r24, Z + 2a2: 98 2f mov r25, r24 + 2a4: 9f 70 andi r25, 0x0F ; 15 + 2a6: 8a 81 ldd r24, Y+2 ; 0x02 + 2a8: 80 7f andi r24, 0xF0 ; 240 + 2aa: 89 2b or r24, r25 + 2ac: 8c 93 st X, r24 + #endif + + unset_lcd_E; + 2ae: a2 e3 ldi r26, 0x32 ; 50 + 2b0: b0 e0 ldi r27, 0x00 ; 0 + 2b2: e2 e3 ldi r30, 0x32 ; 50 + 2b4: f0 e0 ldi r31, 0x00 ; 0 + 2b6: 80 81 ld r24, Z + 2b8: 8b 7f andi r24, 0xFB ; 251 + 2ba: 8c 93 st X, r24 + wait_100us(); + 2bc: 0e 94 a9 01 call 0x352 ; 0x352 + +} + 2c0: 0f 90 pop r0 + 2c2: 0f 90 pop r0 + 2c4: 0f 90 pop r0 + 2c6: 0f 90 pop r0 + 2c8: 0f 90 pop r0 + 2ca: cf 91 pop r28 + 2cc: df 91 pop r29 + 2ce: 08 95 ret + +000002d0 : + +void lcd_blank_line(uint8_t lcd_whichwrite) + { + 2d0: df 93 push r29 + 2d2: cf 93 push r28 + 2d4: 00 d0 rcall .+0 ; 0x2d6 + 2d6: 00 d0 rcall .+0 ; 0x2d8 + 2d8: 0f 92 push r0 + 2da: cd b7 in r28, 0x3d ; 61 + 2dc: de b7 in r29, 0x3e ; 62 + 2de: 8b 83 std Y+3, r24 ; 0x03 + uint8_t count; + uint8_t countin; + + switch (lcd_whichwrite){ + 2e0: 8b 81 ldd r24, Y+3 ; 0x03 + 2e2: 28 2f mov r18, r24 + 2e4: 30 e0 ldi r19, 0x00 ; 0 + 2e6: 3d 83 std Y+5, r19 ; 0x05 + 2e8: 2c 83 std Y+4, r18 ; 0x04 + 2ea: 8c 81 ldd r24, Y+4 ; 0x04 + 2ec: 9d 81 ldd r25, Y+5 ; 0x05 + 2ee: 83 30 cpi r24, 0x03 ; 3 + 2f0: 91 05 cpc r25, r1 + 2f2: 71 f0 breq .+28 ; 0x310 + 2f4: 2c 81 ldd r18, Y+4 ; 0x04 + 2f6: 3d 81 ldd r19, Y+5 ; 0x05 + 2f8: 24 30 cpi r18, 0x04 ; 4 + 2fa: 31 05 cpc r19, r1 + 2fc: 31 f0 breq .+12 ; 0x30a + 2fe: 8c 81 ldd r24, Y+4 ; 0x04 + 300: 9d 81 ldd r25, Y+5 ; 0x05 + 302: 82 30 cpi r24, 0x02 ; 2 + 304: 91 05 cpc r25, r1 + 306: 39 f0 breq .+14 ; 0x316 + 308: 07 c0 rjmp .+14 ; 0x318 + case instruct: + lcd_blank_line(line1); + 30a: 82 e0 ldi r24, 0x02 ; 2 + 30c: 0e 94 68 01 call 0x2d0 ; 0x2d0 + case line2: + count=0x40; + 310: 80 e4 ldi r24, 0x40 ; 64 + 312: 8a 83 std Y+2, r24 ; 0x02 + 314: 01 c0 rjmp .+2 ; 0x318 + break; + case line1: + count=0; + 316: 1a 82 std Y+2, r1 ; 0x02 + break; + } + + for (countin=count; countin < count+15; countin++){ + 318: 8a 81 ldd r24, Y+2 ; 0x02 + 31a: 89 83 std Y+1, r24 ; 0x01 + 31c: 08 c0 rjmp .+16 ; 0x32e + lcd_write(therepos, 32, countin); + 31e: 81 e0 ldi r24, 0x01 ; 1 + 320: 60 e2 ldi r22, 0x20 ; 32 + 322: 49 81 ldd r20, Y+1 ; 0x01 + 324: 0e 94 e2 00 call 0x1c4 ; 0x1c4 + case line1: + count=0; + break; + } + + for (countin=count; countin < count+15; countin++){ + 328: 89 81 ldd r24, Y+1 ; 0x01 + 32a: 8f 5f subi r24, 0xFF ; 255 + 32c: 89 83 std Y+1, r24 ; 0x01 + 32e: 89 81 ldd r24, Y+1 ; 0x01 + 330: 28 2f mov r18, r24 + 332: 30 e0 ldi r19, 0x00 ; 0 + 334: 8a 81 ldd r24, Y+2 ; 0x02 + 336: 88 2f mov r24, r24 + 338: 90 e0 ldi r25, 0x00 ; 0 + 33a: 0f 96 adiw r24, 0x0f ; 15 + 33c: 28 17 cp r18, r24 + 33e: 39 07 cpc r19, r25 + 340: 74 f3 brlt .-36 ; 0x31e + lcd_write(therepos, 32, countin); + } +} + 342: 0f 90 pop r0 + 344: 0f 90 pop r0 + 346: 0f 90 pop r0 + 348: 0f 90 pop r0 + 34a: 0f 90 pop r0 + 34c: cf 91 pop r28 + 34e: df 91 pop r29 + 350: 08 95 ret + +00000352 : +#include +#include +#include "lcd4.h" + +void wait_100us(void){ + 352: df 93 push r29 + 354: cf 93 push r28 + 356: 00 d0 rcall .+0 ; 0x358 + 358: 00 d0 rcall .+0 ; 0x35a + 35a: 0f 92 push r0 + 35c: cd b7 in r28, 0x3d ; 61 + 35e: de b7 in r29, 0x3e ; 62 + for (volatile uint8_t i=68;i--;i>0){ + 360: 84 e4 ldi r24, 0x44 ; 68 + 362: 89 83 std Y+1, r24 ; 0x01 + 364: 02 c0 rjmp .+4 ; 0x36a + i; + 366: 89 81 ldd r24, Y+1 ; 0x01 +#include +#include +#include "lcd4.h" + +void wait_100us(void){ + for (volatile uint8_t i=68;i--;i>0){ + 368: 89 81 ldd r24, Y+1 ; 0x01 + 36a: 89 81 ldd r24, Y+1 ; 0x01 + 36c: 8a 83 std Y+2, r24 ; 0x02 + 36e: 8a 81 ldd r24, Y+2 ; 0x02 + 370: 8d 83 std Y+5, r24 ; 0x05 + 372: 8d 81 ldd r24, Y+5 ; 0x05 + 374: 88 23 and r24, r24 + 376: 11 f0 breq .+4 ; 0x37c + 378: 81 e0 ldi r24, 0x01 ; 1 + 37a: 8d 83 std Y+5, r24 ; 0x05 + 37c: 9d 81 ldd r25, Y+5 ; 0x05 + 37e: 8a 81 ldd r24, Y+2 ; 0x02 + 380: 81 50 subi r24, 0x01 ; 1 + 382: 89 83 std Y+1, r24 ; 0x01 + 384: 99 23 and r25, r25 + 386: 79 f7 brne .-34 ; 0x366 + i; + } +} + 388: 0f 90 pop r0 + 38a: 0f 90 pop r0 + 38c: 0f 90 pop r0 + 38e: 0f 90 pop r0 + 390: 0f 90 pop r0 + 392: cf 91 pop r28 + 394: df 91 pop r29 + 396: 08 95 ret + +00000398
: +#include +#include +#include "lcd4.h" + +int main(void){ + 398: df 93 push r29 + 39a: cf 93 push r28 + 39c: cd b7 in r28, 0x3d ; 61 + 39e: de b7 in r29, 0x3e ; 62 + lcd_1s(); + 3a0: 0e 94 bf 00 call 0x17e ; 0x17e + lcd_init(); + 3a4: 0e 94 49 00 call 0x92 ; 0x92 + lcd_write(therepos,0x41,0x08); + 3a8: 81 e0 ldi r24, 0x01 ; 1 + 3aa: 61 e4 ldi r22, 0x41 ; 65 + 3ac: 48 e0 ldi r20, 0x08 ; 8 + 3ae: 0e 94 e2 00 call 0x1c4 ; 0x1c4 + lcd_write(here,0x42,0); + 3b2: 80 e0 ldi r24, 0x00 ; 0 + 3b4: 62 e4 ldi r22, 0x42 ; 66 + 3b6: 40 e0 ldi r20, 0x00 ; 0 + 3b8: 0e 94 e2 00 call 0x1c4 ; 0x1c4 + lcd_write(here,0x43,0); + 3bc: 80 e0 ldi r24, 0x00 ; 0 + 3be: 63 e4 ldi r22, 0x43 ; 67 + 3c0: 40 e0 ldi r20, 0x00 ; 0 + 3c2: 0e 94 e2 00 call 0x1c4 ; 0x1c4 + lcd_write(here,0x44,0); + 3c6: 80 e0 ldi r24, 0x00 ; 0 + 3c8: 64 e4 ldi r22, 0x44 ; 68 + 3ca: 40 e0 ldi r20, 0x00 ; 0 + 3cc: 0e 94 e2 00 call 0x1c4 ; 0x1c4 + lcd_1s(); + 3d0: 0e 94 bf 00 call 0x17e ; 0x17e + lcd_1s(); + 3d4: 0e 94 bf 00 call 0x17e ; 0x17e + DDRB = 0x0f; + 3d8: e7 e3 ldi r30, 0x37 ; 55 + 3da: f0 e0 ldi r31, 0x00 ; 0 + 3dc: 8f e0 ldi r24, 0x0F ; 15 + 3de: 80 83 st Z, r24 + while(1==1){ + PORTB = 0x0f; + 3e0: e8 e3 ldi r30, 0x38 ; 56 + 3e2: f0 e0 ldi r31, 0x00 ; 0 + 3e4: 8f e0 ldi r24, 0x0F ; 15 + 3e6: 80 83 st Z, r24 + lcd_1s(); + 3e8: 0e 94 bf 00 call 0x17e ; 0x17e + PORTB = 0x05; + 3ec: e8 e3 ldi r30, 0x38 ; 56 + 3ee: f0 e0 ldi r31, 0x00 ; 0 + 3f0: 85 e0 ldi r24, 0x05 ; 5 + 3f2: 80 83 st Z, r24 + lcd_1s(); + 3f4: 0e 94 bf 00 call 0x17e ; 0x17e + PORTB = 0x0A; + 3f8: e8 e3 ldi r30, 0x38 ; 56 + 3fa: f0 e0 ldi r31, 0x00 ; 0 + 3fc: 8a e0 ldi r24, 0x0A ; 10 + 3fe: 80 83 st Z, r24 + lcd_1s(); + 400: 0e 94 bf 00 call 0x17e ; 0x17e + 404: ed cf rjmp .-38 ; 0x3e0 + +00000406 <_exit>: + 406: f8 94 cli + +00000408 <__stop_program>: + 408: ff cf rjmp .-2 ; 0x408 <__stop_program> diff --git a/Libs/LCD4/Debug/LCD4.map b/Libs/LCD4/Debug/LCD4.map new file mode 100644 index 0000000..80aaf3f --- /dev/null +++ b/Libs/LCD4/Debug/LCD4.map @@ -0,0 +1,370 @@ +Archive member included because of file (symbol) + +/usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_exit.o) + /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o (exit) +/usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_copy_data.o) + ./lcd4.o (__do_copy_data) +/usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_clear_bss.o) + ./lcd4.o (__do_clear_bss) + +Memory Configuration + +Name Origin Length Attributes +text 0x00000000 0x00020000 xr +data 0x00800060 0x0000ffa0 rw !x +eeprom 0x00810000 0x00010000 rw !x +fuse 0x00820000 0x00000400 rw !x +lock 0x00830000 0x00000400 rw !x +signature 0x00840000 0x00000400 rw !x +*default* 0x00000000 0xffffffff + +Linker script and memory map + +LOAD /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o +LOAD ./lcd4.o +LOAD ./lcd_wait.o +LOAD ./lcdtest.o +LOAD /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a +LOAD /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/libc.a +LOAD /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a + +.hash + *(.hash) + +.dynsym + *(.dynsym) + +.dynstr + *(.dynstr) + +.gnu.version + *(.gnu.version) + +.gnu.version_d + *(.gnu.version_d) + +.gnu.version_r + *(.gnu.version_r) + +.rel.init + *(.rel.init) + +.rela.init + *(.rela.init) + +.rel.text + *(.rel.text) + *(.rel.text.*) + *(.rel.gnu.linkonce.t*) + +.rela.text + *(.rela.text) + *(.rela.text.*) + *(.rela.gnu.linkonce.t*) + +.rel.fini + *(.rel.fini) + +.rela.fini + *(.rela.fini) + +.rel.rodata + *(.rel.rodata) + *(.rel.rodata.*) + *(.rel.gnu.linkonce.r*) + +.rela.rodata + *(.rela.rodata) + *(.rela.rodata.*) + *(.rela.gnu.linkonce.r*) + +.rel.data + *(.rel.data) + *(.rel.data.*) + *(.rel.gnu.linkonce.d*) + +.rela.data + *(.rela.data) + *(.rela.data.*) + *(.rela.gnu.linkonce.d*) + +.rel.ctors + *(.rel.ctors) + +.rela.ctors + *(.rela.ctors) + +.rel.dtors + *(.rel.dtors) + +.rela.dtors + *(.rela.dtors) + +.rel.got + *(.rel.got) + +.rela.got + *(.rela.got) + +.rel.bss + *(.rel.bss) + +.rela.bss + *(.rela.bss) + +.rel.plt + *(.rel.plt) + +.rela.plt + *(.rela.plt) + +.text 0x00000000 0x40a + *(.vectors) + .vectors 0x00000000 0x54 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o + 0x00000000 __vectors + 0x00000000 __vector_default + *(.vectors) + *(.progmem.gcc*) + *(.progmem*) + 0x00000054 . = ALIGN (0x2) + 0x00000054 __trampolines_start = . + *(.trampolines) + .trampolines 0x00000054 0x0 linker stubs + *(.trampolines*) + 0x00000054 __trampolines_end = . + *(.jumptables) + *(.jumptables*) + *(.lowtext) + *(.lowtext*) + 0x00000054 __ctors_start = . + *(.ctors) + 0x00000054 __ctors_end = . + 0x00000054 __dtors_start = . + *(.dtors) + 0x00000054 __dtors_end = . + SORT(*)(.ctors) + SORT(*)(.dtors) + *(.init0) + .init0 0x00000054 0x0 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o + 0x00000054 __init + *(.init0) + *(.init1) + *(.init1) + *(.init2) + .init2 0x00000054 0xc /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o + *(.init2) + *(.init3) + *(.init3) + *(.init4) + .init4 0x00000060 0x16 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_copy_data.o) + 0x00000060 __do_copy_data + .init4 0x00000076 0x10 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_clear_bss.o) + 0x00000076 __do_clear_bss + *(.init4) + *(.init5) + *(.init5) + *(.init6) + *(.init6) + *(.init7) + *(.init7) + *(.init8) + *(.init8) + *(.init9) + .init9 0x00000086 0x8 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o + *(.init9) + *(.text) + .text 0x0000008e 0x4 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o + 0x0000008e __vector_1 + 0x0000008e __vector_12 + 0x0000008e __bad_interrupt + 0x0000008e __vector_6 + 0x0000008e __vector_3 + 0x0000008e __vector_11 + 0x0000008e __vector_13 + 0x0000008e __vector_17 + 0x0000008e __vector_19 + 0x0000008e __vector_7 + 0x0000008e __vector_5 + 0x0000008e __vector_4 + 0x0000008e __vector_9 + 0x0000008e __vector_2 + 0x0000008e __vector_15 + 0x0000008e __vector_8 + 0x0000008e __vector_14 + 0x0000008e __vector_10 + 0x0000008e __vector_16 + 0x0000008e __vector_18 + 0x0000008e __vector_20 + .text 0x00000092 0x2c0 ./lcd4.o + 0x000001c4 lcd_write + 0x0000017e lcd_1s + 0x000002d0 lcd_blank_line + 0x00000156 lcd_5ms + 0x000001a6 lcd_instruct + 0x00000092 lcd_init + .text 0x00000352 0x46 ./lcd_wait.o + 0x00000352 wait_100us + .text 0x00000398 0x6e ./lcdtest.o + 0x00000398 main + .text 0x00000406 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_exit.o) + .text 0x00000406 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_copy_data.o) + .text 0x00000406 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_clear_bss.o) + 0x00000406 . = ALIGN (0x2) + *(.text.*) + .text.libgcc 0x00000406 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_exit.o) + .text.libgcc 0x00000406 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_copy_data.o) + .text.libgcc 0x00000406 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_clear_bss.o) + 0x00000406 . = ALIGN (0x2) + *(.fini9) + .fini9 0x00000406 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_exit.o) + 0x00000406 exit + 0x00000406 _exit + *(.fini9) + *(.fini8) + *(.fini8) + *(.fini7) + *(.fini7) + *(.fini6) + *(.fini6) + *(.fini5) + *(.fini5) + *(.fini4) + *(.fini4) + *(.fini3) + *(.fini3) + *(.fini2) + *(.fini2) + *(.fini1) + *(.fini1) + *(.fini0) + .fini0 0x00000406 0x4 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_exit.o) + *(.fini0) + 0x0000040a _etext = . + +.data 0x00800060 0x0 load address 0x0000040a + 0x00800060 PROVIDE (__data_start, .) + *(.data) + .data 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o + .data 0x00800060 0x0 ./lcd4.o + .data 0x00800060 0x0 ./lcd_wait.o + .data 0x00800060 0x0 ./lcdtest.o + .data 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_exit.o) + .data 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_copy_data.o) + .data 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_clear_bss.o) + *(.data*) + *(.rodata) + *(.rodata*) + *(.gnu.linkonce.d*) + 0x00800060 . = ALIGN (0x2) + 0x00800060 _edata = . + 0x00800060 PROVIDE (__data_end, .) + +.bss 0x00800060 0x0 load address 0x0000040a + 0x00800060 PROVIDE (__bss_start, .) + *(.bss) + .bss 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o + .bss 0x00800060 0x0 ./lcd4.o + .bss 0x00800060 0x0 ./lcd_wait.o + .bss 0x00800060 0x0 ./lcdtest.o + .bss 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_exit.o) + .bss 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_copy_data.o) + .bss 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr5/libgcc.a(_clear_bss.o) + *(.bss*) + *(COMMON) + 0x00800060 PROVIDE (__bss_end, .) + 0x0000040a __data_load_start = LOADADDR (.data) + 0x0000040a __data_load_end = (__data_load_start + SIZEOF (.data)) + +.noinit 0x00800060 0x0 + 0x00800060 PROVIDE (__noinit_start, .) + *(.noinit*) + 0x00800060 PROVIDE (__noinit_end, .) + 0x00800060 _end = . + 0x00800060 PROVIDE (__heap_start, .) + +.eeprom 0x00810000 0x0 + *(.eeprom*) + 0x00810000 __eeprom_end = . + +.fuse + *(.fuse) + *(.lfuse) + *(.hfuse) + *(.efuse) + +.lock + *(.lock*) + +.signature + *(.signature*) + +.stab 0x00000000 0x111c + *(.stab) + .stab 0x00000000 0x6b4 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o + .stab 0x000006b4 0x708 ./lcd4.o + 0x714 (size before relaxing) + .stab 0x00000dbc 0x180 ./lcd_wait.o + 0x348 (size before relaxing) + .stab 0x00000f3c 0x1e0 ./lcdtest.o + 0x3a8 (size before relaxing) + +.stabstr 0x00000000 0x7cb + *(.stabstr) + .stabstr 0x00000000 0x7cb /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr5/crtm16.o + +.stab.excl + *(.stab.excl) + +.stab.exclstr + *(.stab.exclstr) + +.stab.index + *(.stab.index) + +.stab.indexstr + *(.stab.indexstr) + +.comment + *(.comment) + +.debug + *(.debug) + +.line + *(.line) + +.debug_srcinfo + *(.debug_srcinfo) + +.debug_sfnames + *(.debug_sfnames) + +.debug_aranges + *(.debug_aranges) + +.debug_pubnames + *(.debug_pubnames) + +.debug_info + *(.debug_info) + *(.gnu.linkonce.wi.*) + +.debug_abbrev + *(.debug_abbrev) + +.debug_line + *(.debug_line) + +.debug_frame + *(.debug_frame) + +.debug_str + *(.debug_str) + +.debug_loc + *(.debug_loc) + +.debug_macinfo + *(.debug_macinfo) +OUTPUT(LCD4.elf elf32-avr) +LOAD linker stubs diff --git a/Libs/LCD4/Debug/lcd4.d b/Libs/LCD4/Debug/lcd4.d new file mode 100644 index 0000000..134a475 --- /dev/null +++ b/Libs/LCD4/Debug/lcd4.d @@ -0,0 +1,3 @@ +lcd4.d lcd4.o: ../lcd4.c ../lcd4.h + +../lcd4.h: diff --git a/Libs/LCD4/Debug/lcd4.o b/Libs/LCD4/Debug/lcd4.o new file mode 100644 index 0000000000000000000000000000000000000000..fe5e51341d722c23f776145041e5263b19e7bc88 GIT binary patch literal 6252 zcmb7IZH$!F6+SDgQl&*H{Rp-O1a-Fz^YQNN?l9vb!thZG4FO|mOFKKeJM0b&GwaN| zu+T(iX1BOs>H-!0fmTUFZEFlanrewL`=fswX+s;6Cb|U^o5mlI5N#R~`kedqp4rtZ zm%VeI``mNSJ?Gqe-}k;8-L!3UQ&SV!(nPx`Xc5iaP4shg#+5<~-AN1S{gdyU{PP>{ zz47bI=Vm{=d}X#;tCprtzJk_2RcowUwnou9gT70yFKBV!SAIccYxVN~M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Wp3JWFvj6E*zD-<8yR5Xw7-g-}jFoy=ZqwAsf z8bJl;-9H2{qe&<=k7Pg7-@_v0QHgXof)DLWcOZ&``y0agy@NVEv_C!9lIsUyYg_9{ z4wxvUcA#emvJZ;?Jzh48wziKUeu>SWMLfmk^!}&^n)t zCHlWc530kfdV-SXftpj#jiTo_)SLv_FYlON-7#nPH_uymW#+u+;jvzr_hvPi6X5LG zc_EYK6)y^w1il(X9W!Zk@Vd9M?um2dc{Ih(ROHbKqvI(~x*ZD literal 0 HcmV?d00001 diff --git a/Libs/LCD4/Debug/makefile b/Libs/LCD4/Debug/makefile new file mode 100644 index 0000000..53ee29e --- /dev/null +++ b/Libs/LCD4/Debug/makefile @@ -0,0 +1,72 @@ +################################################################################ +# Automatically-generated file. Do not edit! +################################################################################ + +-include ../makefile.init + +RM := rm -rf + +# All of the sources participating in the build are defined here +-include sources.mk +-include subdir.mk +-include objects.mk + +ifneq ($(MAKECMDGOALS),clean) +ifneq ($(strip $(C_DEPS)),) +-include $(C_DEPS) +endif +ifneq ($(strip $(ASM_DEPS)),) +-include $(ASM_DEPS) +endif +ifneq ($(strip $(S_DEPS)),) +-include $(S_DEPS) +endif +ifneq ($(strip $(S_UPPER_DEPS)),) +-include $(S_UPPER_DEPS) +endif +endif + +-include ../makefile.defs + +# Add inputs and outputs from these tool invocations to the build variables +LSS += \ +LCD4.lss \ + +SIZEDUMMY += \ +sizedummy \ + + +# All Target +all: LCD4.elf secondary-outputs + +# Tool invocations +LCD4.elf: $(OBJS) $(USER_OBJS) + @echo 'Building target: $@' + @echo 'Invoking: AVR C Linker' + avr-gcc -Wl,-Map,LCD4.map -mmcu=atmega16 -o"LCD4.elf" $(OBJS) $(USER_OBJS) $(LIBS) + @echo 'Finished building target: $@' + @echo ' ' + +LCD4.lss: LCD4.elf + @echo 'Invoking: AVR Create Extended Listing' + -avr-objdump -h -S LCD4.elf >"LCD4.lss" + @echo 'Finished building: $@' + @echo ' ' + +sizedummy: LCD4.elf + @echo 'Invoking: Print Size' + -avr-size --format=avr --mcu=atmega16 LCD4.elf + @echo 'Finished building: $@' + @echo ' ' + +# Other Targets +clean: + -$(RM) $(OBJS)$(C_DEPS)$(ASM_DEPS)$(ELFS)$(LSS)$(S_DEPS)$(SIZEDUMMY)$(S_UPPER_DEPS) LCD4.elf + -@echo ' ' + +secondary-outputs: $(LSS) $(SIZEDUMMY) + +.PHONY: all clean dependents +.SECONDARY: + +-include ../makefile.targets diff --git a/Libs/LCD4/Debug/objects.mk b/Libs/LCD4/Debug/objects.mk new file mode 100644 index 0000000..224ef68 --- /dev/null +++ b/Libs/LCD4/Debug/objects.mk @@ -0,0 +1,7 @@ +################################################################################ +# Automatically-generated file. Do not edit! +################################################################################ + +USER_OBJS := + +LIBS := diff --git a/Libs/LCD4/Debug/sources.mk b/Libs/LCD4/Debug/sources.mk new file mode 100644 index 0000000..c5a8b0c --- /dev/null +++ b/Libs/LCD4/Debug/sources.mk @@ -0,0 +1,23 @@ +################################################################################ +# Automatically-generated file. Do not edit! +################################################################################ + +O_SRCS := +C_SRCS := +S_UPPER_SRCS := +S_SRCS := +OBJ_SRCS := +ASM_SRCS := +OBJS := +C_DEPS := +ASM_DEPS := +ELFS := +LSS := +S_DEPS := +SIZEDUMMY := +S_UPPER_DEPS := + +# Every subdirectory with source files must be described here +SUBDIRS := \ +. \ + diff --git a/Libs/LCD4/Debug/subdir.mk b/Libs/LCD4/Debug/subdir.mk new file mode 100644 index 0000000..1f664fd --- /dev/null +++ b/Libs/LCD4/Debug/subdir.mk @@ -0,0 +1,30 @@ +################################################################################ +# Automatically-generated file. Do not edit! +################################################################################ + +# Add inputs and outputs from these tool invocations to the build variables +C_SRCS += \ +../lcd4.c \ +../lcd_wait.c \ +../lcdtest.c + +OBJS += \ +./lcd4.o \ +./lcd_wait.o \ +./lcdtest.o + +C_DEPS += \ +./lcd4.d \ +./lcd_wait.d \ +./lcdtest.d + + +# Each subdirectory must supply rules for building sources it contributes +%.o: ../%.c + @echo 'Building file: $<' + @echo 'Invoking: AVR Compiler' + avr-gcc -Wall -g2 -gstabs -O0 -fpack-struct -fshort-enums -std=gnu99 -funsigned-char -funsigned-bitfields -mmcu=atmega16 -DF_CPU=1000000UL -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@:%.o=%.d)" -c -o"$@" "$<" + @echo 'Finished building: $<' + @echo ' ' + + diff --git a/Libs/LCD4/Makefile b/Libs/LCD4/Makefile new file mode 100644 index 0000000..dcac8f3 --- /dev/null +++ b/Libs/LCD4/Makefile @@ -0,0 +1,429 @@ +# Hey Emacs, this is a -*- makefile -*- +# +# WinAVR Sample makefile written by Eric B. Weddington, Jörg Wunsch, et al. +# Released to the Public Domain +# Please read the make user manual! +# +# Additional material for this makefile was submitted by: +# Tim Henigan +# Peter Fleury +# Reiner Patommel +# Sander Pool +# Frederik Rouleau +# Markus Pfaff +# +# On command line: +# +# make all = Make software. +# +# make clean = Clean out built project files. +# +# make coff = Convert ELF to AVR COFF (for use with AVR Studio 3.x or VMLAB). +# +# make extcoff = Convert ELF to AVR Extended COFF (for use with AVR Studio +# 4.07 or greater). +# +# make program = Download the hex file to the device, using avrdude. Please +# customize the avrdude settings below first! +# +# make filename.s = Just compile filename.c into the assembler code only +# +# To rebuild project do "make clean" then "make all". +# + + +# MCU name +MCU = at90s2313 + +# Output format. (can be srec, ihex, binary) +FORMAT = ihex + +# Target file name (without extension). +TARGET = lcdtest + + +# List C source files here. (C dependencies are automatically generated.) +SRC = avrmb2313_lcd.c lcd_wait.c $(TARGET).c +# lcd.c +# avrmb2313.c + + +# List Assembler source files here. +# Make them always end in a capital .S. Files ending in a lowercase .s +# will not be considered source files but generated files (assembler +# output from the compiler), and will be deleted upon "make clean"! +# Even though the DOS/Win* filesystem matches both .s and .S the same, +# it will preserve the spelling of the filenames, and gcc itself does +# care about how the name is spelled on its command-line. +ASRC = + + + +# Optimization level, can be [0, 1, 2, 3, s]. +# 0 = turn off optimization. s = optimize for size. +# (Note: 3 is not always the best optimization level. See avr-libc FAQ.) +OPT = s + +# Debugging format. +# Native formats for AVR-GCC's -g are stabs [default], or dwarf-2. +# AVR (extended) COFF requires stabs, plus an avr-objcopy run. +DEBUG = stabs + +# List any extra directories to look for include files here. +# Each directory must be seperated by a space. +EXTRAINCDIRS = + + +# Compiler flag to set the C Standard level. +# c89 - "ANSI" C +# gnu89 - c89 plus GCC extensions +# c99 - ISO C99 standard (not yet fully implemented) +# gnu99 - c99 plus GCC extensions +CSTANDARD = -std=gnu99 + +# Place -D or -U options here +CDEFS = + +# Place -I options here +CINCS = + + +# Compiler flags. +# -g*: generate debugging information +# -O*: optimization level +# -f...: tuning, see GCC manual and avr-libc documentation +# -Wall...: warning level +# -Wa,...: tell GCC to pass this to the assembler. +# -adhlns...: create assembler listing +CFLAGS = -g$(DEBUG) +CFLAGS += $(CDEFS) $(CINCS) +CFLAGS += -O$(OPT) +CFLAGS += -funsigned-char -funsigned-bitfields -fpack-struct -fshort-enums +CFLAGS += -Wall -Wstrict-prototypes +CFLAGS += -Wa,-adhlns=$(<:.c=.lst) +CFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS)) +CFLAGS += $(CSTANDARD) + + + +# Assembler flags. +# -Wa,...: tell GCC to pass this to the assembler. +# -ahlms: create listing +# -gstabs: have the assembler create line number information; note that +# for use in COFF files, additional information about filenames +# and function names needs to be present in the assembler source +# files -- see avr-libc docs [FIXME: not yet described there] +ASFLAGS = -Wa,-adhlns=$(<:.S=.lst),-gstabs + + + +#Additional libraries. + +# Minimalistic printf version +PRINTF_LIB_MIN = -Wl,-u,vfprintf -lprintf_min + +# Floating point printf version (requires MATH_LIB = -lm below) +PRINTF_LIB_FLOAT = -Wl,-u,vfprintf -lprintf_flt + +PRINTF_LIB = + +# Minimalistic scanf version +SCANF_LIB_MIN = -Wl,-u,vfscanf -lscanf_min + +# Floating point + %[ scanf version (requires MATH_LIB = -lm below) +SCANF_LIB_FLOAT = -Wl,-u,vfscanf -lscanf_flt + +SCANF_LIB = + +MATH_LIB = -lm + +# External memory options + +# 64 KB of external RAM, starting after internal RAM (ATmega128!), +# used for variables (.data/.bss) and heap (malloc()). +#EXTMEMOPTS = -Wl,-Tdata=0x801100,--defsym=__heap_end=0x80ffff + +# 64 KB of external RAM, starting after internal RAM (ATmega128!), +# only used for heap (malloc()). +#EXTMEMOPTS = -Wl,--defsym=__heap_start=0x801100,--defsym=__heap_end=0x80ffff + +EXTMEMOPTS = + +# Linker flags. +# -Wl,...: tell GCC to pass this to linker. +# -Map: create map file +# --cref: add cross reference to map file +LDFLAGS = -Wl,-Map=$(TARGET).map,--cref +LDFLAGS += $(EXTMEMOPTS) +LDFLAGS += $(PRINTF_LIB) $(SCANF_LIB) $(MATH_LIB) + + + + +# Programming support using avrdude. Settings and variables. + +# Programming hardware: alf avr910 avrisp bascom bsd +# dt006 pavr picoweb pony-stk200 sp12 stk200 stk500 +# +# Type: avrdude -c ? +# to get a full listing. +# +AVRDUDE_PROGRAMMER = stk500 + +# com1 = serial port. Use lpt1 to connect to parallel port. +AVRDUDE_PORT = com1 # programmer connected to serial device + +AVRDUDE_WRITE_FLASH = -U flash:w:$(TARGET).hex +#AVRDUDE_WRITE_EEPROM = -U eeprom:w:$(TARGET).eep + + +# Uncomment the following if you want avrdude's erase cycle counter. +# Note that this counter needs to be initialized first using -Yn, +# see avrdude manual. +#AVRDUDE_ERASE_COUNTER = -y + +# Uncomment the following if you do /not/ wish a verification to be +# performed after programming the device. +#AVRDUDE_NO_VERIFY = -V + +# Increase verbosity level. Please use this when submitting bug +# reports about avrdude. See +# to submit bug reports. +#AVRDUDE_VERBOSE = -v -v + +AVRDUDE_FLAGS = -p $(MCU) -P $(AVRDUDE_PORT) -c $(AVRDUDE_PROGRAMMER) +AVRDUDE_FLAGS += $(AVRDUDE_NO_VERIFY) +AVRDUDE_FLAGS += $(AVRDUDE_VERBOSE) +AVRDUDE_FLAGS += $(AVRDUDE_ERASE_COUNTER) + + + +# --------------------------------------------------------------------------- + +# Define directories, if needed. +DIRAVR = c:/winavr +DIRAVRBIN = $(DIRAVR)/bin +DIRAVRUTILS = $(DIRAVR)/utils/bin +DIRINC = . +DIRLIB = $(DIRAVR)/avr/lib + + +# Define programs and commands. +SHELL = sh +CC = avr-gcc +OBJCOPY = avr-objcopy +OBJDUMP = avr-objdump +SIZE = avr-size +NM = avr-nm +AVRDUDE = avrdude +REMOVE = rm -f +COPY = cp + + + + +# Define Messages +# English +MSG_ERRORS_NONE = Errors: none +MSG_BEGIN = -------- begin -------- +MSG_END = -------- end -------- +MSG_SIZE_BEFORE = Size before: +MSG_SIZE_AFTER = Size after: +MSG_COFF = Converting to AVR COFF: +MSG_EXTENDED_COFF = Converting to AVR Extended COFF: +MSG_FLASH = Creating load file for Flash: +MSG_EEPROM = Creating load file for EEPROM: +MSG_EXTENDED_LISTING = Creating Extended Listing: +MSG_SYMBOL_TABLE = Creating Symbol Table: +MSG_LINKING = Linking: +MSG_COMPILING = Compiling: +MSG_ASSEMBLING = Assembling: +MSG_CLEANING = Cleaning project: + + + + +# Define all object files. +OBJ = $(SRC:.c=.o) $(ASRC:.S=.o) + +# Define all listing files. +LST = $(ASRC:.S=.lst) $(SRC:.c=.lst) + + +# Compiler flags to generate dependency files. +GENDEPFLAGS = -Wp,-M,-MP,-MT,$(*F).o,-MF,.dep/$(@F).d + + +# Combine all necessary flags and optional flags. +# Add target processor to flags. +ALL_CFLAGS = -mmcu=$(MCU) -I. $(CFLAGS) $(GENDEPFLAGS) +ALL_ASFLAGS = -mmcu=$(MCU) -I. -x assembler-with-cpp $(ASFLAGS) + + + + + +# Default target. +all: begin gccversion sizebefore build sizeafter finished end + +build: elf hex eep lss sym extcoff + +elf: $(TARGET).elf +hex: $(TARGET).hex +eep: $(TARGET).eep +lss: $(TARGET).lss +sym: $(TARGET).sym + + + +# Eye candy. +# AVR Studio 3.x does not check make's exit code but relies on +# the following magic strings to be generated by the compile job. +begin: + @echo + @echo $(MSG_BEGIN) + +finished: + @echo $(MSG_ERRORS_NONE) + +end: + @echo $(MSG_END) + @echo + + +# Display size of file. +HEXSIZE = $(SIZE) --target=$(FORMAT) $(TARGET).hex +ELFSIZE = $(SIZE) -A $(TARGET).elf +sizebefore: + @if [ -f $(TARGET).elf ]; then echo; echo $(MSG_SIZE_BEFORE); $(ELFSIZE); echo; fi + +sizeafter: + @if [ -f $(TARGET).elf ]; then echo; echo $(MSG_SIZE_AFTER); $(ELFSIZE); echo; fi + + + +# Display compiler version information. +gccversion : + @$(CC) --version + + + +# Program the device. +program: $(TARGET).hex $(TARGET).eep + $(AVRDUDE) $(AVRDUDE_FLAGS) $(AVRDUDE_WRITE_FLASH) $(AVRDUDE_WRITE_EEPROM) + + + + +# Convert ELF to COFF for use in debugging / simulating in AVR Studio or VMLAB. +COFFCONVERT=$(OBJCOPY) --debugging \ +--change-section-address .data-0x800000 \ +--change-section-address .bss-0x800000 \ +--change-section-address .noinit-0x800000 \ +--change-section-address .eeprom-0x810000 + + +coff: $(TARGET).elf + @echo + @echo $(MSG_COFF) $(TARGET).cof + $(COFFCONVERT) -O coff-avr $< $(TARGET).cof + + +extcoff: $(TARGET).elf + @echo + @echo $(MSG_EXTENDED_COFF) $(TARGET).cof + $(COFFCONVERT) -O coff-ext-avr $< $(TARGET).cof + + + +# Create final output files (.hex, .eep) from ELF output file. +%.hex: %.elf + @echo + @echo $(MSG_FLASH) $@ + $(OBJCOPY) -O $(FORMAT) -R .eeprom $< $@ + +%.eep: %.elf + @echo + @echo $(MSG_EEPROM) $@ + -$(OBJCOPY) -j .eeprom --set-section-flags=.eeprom="alloc,load" \ + --change-section-lma .eeprom=0 -O $(FORMAT) $< $@ + +# Create extended listing file from ELF output file. +%.lss: %.elf + @echo + @echo $(MSG_EXTENDED_LISTING) $@ + $(OBJDUMP) -h -S $< > $@ + +# Create a symbol table from ELF output file. +%.sym: %.elf + @echo + @echo $(MSG_SYMBOL_TABLE) $@ + $(NM) -n $< > $@ + + + +# Link: create ELF output file from object files. +.SECONDARY : $(TARGET).elf +.PRECIOUS : $(OBJ) +%.elf: $(OBJ) + @echo + @echo $(MSG_LINKING) $@ + $(CC) $(ALL_CFLAGS) $(OBJ) --output $@ $(LDFLAGS) + + +# Compile: create object files from C source files. +%.o : %.c + @echo + @echo $(MSG_COMPILING) $< + $(CC) -c $(ALL_CFLAGS) $< -o $@ + + +# Compile: create assembler files from C source files. +%.s : %.c + $(CC) -S $(ALL_CFLAGS) $< -o $@ + + +# Assemble: create object files from assembler source files. +%.o : %.S + @echo + @echo $(MSG_ASSEMBLING) $< + $(CC) -c $(ALL_ASFLAGS) $< -o $@ + + + +# Target: clean project. +clean: begin clean_list finished end + +clean_list : + @echo + @echo $(MSG_CLEANING) + $(REMOVE) $(TARGET).hex + $(REMOVE) $(TARGET).eep + $(REMOVE) $(TARGET).obj + $(REMOVE) $(TARGET).cof + $(REMOVE) $(TARGET).elf + $(REMOVE) $(TARGET).map + $(REMOVE) $(TARGET).obj + $(REMOVE) $(TARGET).a90 + $(REMOVE) $(TARGET).sym + $(REMOVE) $(TARGET).lnk + $(REMOVE) $(TARGET).lss + $(REMOVE) $(OBJ) + $(REMOVE) $(LST) + $(REMOVE) $(SRC:.c=.s) + $(REMOVE) $(SRC:.c=.d) + $(REMOVE) .dep/* + + + +# Include the dependency files. +-include $(shell mkdir .dep 2>/dev/null) $(wildcard .dep/*) + + +# Listing of phony targets. +.PHONY : all begin finish end sizebefore sizeafter gccversion \ +build elf hex eep lss sym coff extcoff \ +clean clean_list program + + + diff --git a/Debug/AtTiny_alarm_clock.eep b/Libs/LCD4/avrmb2313_notkermobil/LCD4.eep similarity index 100% rename from Debug/AtTiny_alarm_clock.eep rename to Libs/LCD4/avrmb2313_notkermobil/LCD4.eep diff --git a/Libs/LCD4/avrmb2313_notkermobil/LCD4.elf b/Libs/LCD4/avrmb2313_notkermobil/LCD4.elf new file mode 100644 index 0000000000000000000000000000000000000000..f38336dd9d5c52667fa8a71dc665a29475fb0271 GIT binary patch literal 9987 zcmd^^dvH|M8Nk2r5K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E|;=u!QnPXk|8qJ`NIiZW9epk%FEl`-b#an6{q}GKNb`{ zDh4QxZ)i>U8}Xiq$$Lmq0tbZjGS}aTdfF&_%|w5Dp)-Tpb|CXg{lwDzB2XItxA)=IW1HD(qg)) zET7I*?kTzeuGM+e_mijTo5>8VJ9*kfcI!WRI)riq%cqm2kI5S}6P!GK3;w#ko;TxcBCsAJJ^q~+V@d7e^^GM(|9Oai#p6KKcMfoVQn(rjPi!yyD zARDs(5bwOcFPKdBgV5G3fAaJQl(~J8Qx_J)d0GHfdHGl5m0yx)Z=$>sl2lxj59gI{ zXZGZ82g>wK;%2m`{%_5*zcWw1KTm!PWka+k+oSK(6cZJX-=YkV5*9=8`FIUw`W}Tx zY0=(MkuS1Ef8R%$_x}{jr~dZGzVdhtMVZ>7MDZGna;X%BJQZbLUoFb?t#KP(o?|k_<2QNsNAl!9=gIG(?6y|`r}FXvV>J`6IoKY>3rd3#Jo!a8 zm_dKSZ{o5N!__56*Aj_Dr3!blF|#oq=Vn?b%y1>8^Q37mS$ySO(MmzYL&&DLYgEH_W$: + 0: 12 c0 rjmp .+36 ; 0x26 <__ctors_end> + 2: 2a c0 rjmp .+84 ; 0x58 <__bad_interrupt> + 4: 29 c0 rjmp .+82 ; 0x58 <__bad_interrupt> + 6: 28 c0 rjmp .+80 ; 0x58 <__bad_interrupt> + 8: 27 c0 rjmp .+78 ; 0x58 <__bad_interrupt> + a: 26 c0 rjmp .+76 ; 0x58 <__bad_interrupt> + c: 25 c0 rjmp .+74 ; 0x58 <__bad_interrupt> + e: 24 c0 rjmp .+72 ; 0x58 <__bad_interrupt> + 10: 23 c0 rjmp .+70 ; 0x58 <__bad_interrupt> + 12: 22 c0 rjmp .+68 ; 0x58 <__bad_interrupt> + 14: 21 c0 rjmp .+66 ; 0x58 <__bad_interrupt> + 16: 20 c0 rjmp .+64 ; 0x58 <__bad_interrupt> + 18: 1f c0 rjmp .+62 ; 0x58 <__bad_interrupt> + 1a: 1e c0 rjmp .+60 ; 0x58 <__bad_interrupt> + 1c: 1d c0 rjmp .+58 ; 0x58 <__bad_interrupt> + 1e: 1c c0 rjmp .+56 ; 0x58 <__bad_interrupt> + 20: 1b c0 rjmp .+54 ; 0x58 <__bad_interrupt> + 22: 1a c0 rjmp .+52 ; 0x58 <__bad_interrupt> + 24: 19 c0 rjmp .+50 ; 0x58 <__bad_interrupt> + +00000026 <__ctors_end>: + 26: 11 24 eor r1, r1 + 28: 1f be out 0x3f, r1 ; 63 + 2a: cf ed ldi r28, 0xDF ; 223 + 2c: cd bf out 0x3d, r28 ; 61 + +0000002e <__do_copy_data>: + 2e: 10 e0 ldi r17, 0x00 ; 0 + 30: a0 e6 ldi r26, 0x60 ; 96 + 32: b0 e0 ldi r27, 0x00 ; 0 + 34: e2 ef ldi r30, 0xF2 ; 242 + 36: f3 e0 ldi r31, 0x03 ; 3 + 38: 02 c0 rjmp .+4 ; 0x3e <__SP_H__> + +0000003a <.do_copy_data_loop>: + 3a: 05 90 lpm r0, Z+ + 3c: 0d 92 st X+, r0 + +0000003e <.do_copy_data_start>: + 3e: a0 36 cpi r26, 0x60 ; 96 + 40: b1 07 cpc r27, r17 + 42: d9 f7 brne .-10 ; 0x3a <.do_copy_data_loop> + +00000044 <__do_clear_bss>: + 44: 10 e0 ldi r17, 0x00 ; 0 + 46: a0 e6 ldi r26, 0x60 ; 96 + 48: b0 e0 ldi r27, 0x00 ; 0 + 4a: 01 c0 rjmp .+2 ; 0x4e <.do_clear_bss_start> + +0000004c <.do_clear_bss_loop>: + 4c: 1d 92 st X+, r1 + +0000004e <.do_clear_bss_start>: + 4e: a0 36 cpi r26, 0x60 ; 96 + 50: b1 07 cpc r27, r17 + 52: e1 f7 brne .-8 ; 0x4c <.do_clear_bss_loop> + 54: 98 d1 rcall .+816 ; 0x386
+ 56: cb c1 rjmp .+918 ; 0x3ee <_exit> + +00000058 <__bad_interrupt>: + 58: d3 cf rjmp .-90 ; 0x0 <__heap_end> + +0000005a : + +#define lcd_mask_Write_Adress(position) ((position & 0x7F)| lcd_SET_DD_RAM) + + + +void lcd_init(void){ + 5a: df 93 push r29 + 5c: cf 93 push r28 + 5e: cd b7 in r28, 0x3d ; 61 + 60: de b7 in r29, 0x3e ; 62 + /* setting up ports first */ + lcd_dataport_DDR=0xff; + 62: e7 e3 ldi r30, 0x37 ; 55 + 64: f0 e0 ldi r31, 0x00 ; 0 + 66: 8f ef ldi r24, 0xFF ; 255 + 68: 80 83 st Z, r24 + set_lcd_RS_DDR; + 6a: a1 e3 ldi r26, 0x31 ; 49 + 6c: b0 e0 ldi r27, 0x00 ; 0 + 6e: e1 e3 ldi r30, 0x31 ; 49 + 70: f0 e0 ldi r31, 0x00 ; 0 + 72: 80 81 ld r24, Z + 74: 88 60 ori r24, 0x08 ; 8 + 76: 8c 93 st X, r24 + set_lcd_E_DDR; + 78: a1 e3 ldi r26, 0x31 ; 49 + 7a: b0 e0 ldi r27, 0x00 ; 0 + 7c: e1 e3 ldi r30, 0x31 ; 49 + 7e: f0 e0 ldi r31, 0x00 ; 0 + 80: 80 81 ld r24, Z + 82: 84 60 ori r24, 0x04 ; 4 + 84: 8c 93 st X, r24 + /* end setting up ports */ + lcd_dataport=0xff; + 86: e8 e3 ldi r30, 0x38 ; 56 + 88: f0 e0 ldi r31, 0x00 ; 0 + 8a: 8f ef ldi r24, 0xFF ; 255 + 8c: 80 83 st Z, r24 + set_lcd_RS; + 8e: a2 e3 ldi r26, 0x32 ; 50 + 90: b0 e0 ldi r27, 0x00 ; 0 + 92: e2 e3 ldi r30, 0x32 ; 50 + 94: f0 e0 ldi r31, 0x00 ; 0 + 96: 80 81 ld r24, Z + 98: 88 60 ori r24, 0x08 ; 8 + 9a: 8c 93 st X, r24 + set_lcd_E; + 9c: a2 e3 ldi r26, 0x32 ; 50 + 9e: b0 e0 ldi r27, 0x00 ; 0 + a0: e2 e3 ldi r30, 0x32 ; 50 + a2: f0 e0 ldi r31, 0x00 ; 0 + a4: 80 81 ld r24, Z + a6: 84 60 ori r24, 0x04 ; 4 + a8: 8c 93 st X, r24 + lcd_5ms(); + aa: 1d d0 rcall .+58 ; 0xe6 + lcd_5ms(); + ac: 1c d0 rcall .+56 ; 0xe6 + lcd_5ms(); + ae: 1b d0 rcall .+54 ; 0xe6 + lcd_instruct(lcd_SET_FUNCTION_8BIT); + b0: 80 e3 ldi r24, 0x30 ; 48 + b2: 3f d0 rcall .+126 ; 0x132 + lcd_5ms(); + b4: 18 d0 rcall .+48 ; 0xe6 + lcd_instruct(lcd_SET_FUNCTION_8BIT); + b6: 80 e3 ldi r24, 0x30 ; 48 + b8: 3c d0 rcall .+120 ; 0x132 + wait_100us(); + ba: 42 d1 rcall .+644 ; 0x340 + lcd_instruct(lcd_SET_FUNCTION_8BIT); + bc: 80 e3 ldi r24, 0x30 ; 48 + be: 39 d0 rcall .+114 ; 0x132 + if (lcd_dataport_mask==0xf0){ + lcd_instruct(lcd_SET_FUNCTION_4BIT|lcd_SET_FUNCTION_2LINE|lcd_SET_FUNCTION_7X5); + c0: 88 e2 ldi r24, 0x28 ; 40 + c2: 37 d0 rcall .+110 ; 0x132 + }else{ + lcd_instruct(lcd_SET_FUNCTION_8BIT|lcd_SET_FUNCTION_2LINE|lcd_SET_FUNCTION_7X5); + } + lcd_dataport_DDR&=lcd_dataport_mask; + c4: a7 e3 ldi r26, 0x37 ; 55 + c6: b0 e0 ldi r27, 0x00 ; 0 + c8: e7 e3 ldi r30, 0x37 ; 55 + ca: f0 e0 ldi r31, 0x00 ; 0 + cc: 80 81 ld r24, Z + ce: 80 7f andi r24, 0xF0 ; 240 + d0: 8c 93 st X, r24 + lcd_instruct(lcd_DISPLAY_OO_ON|lcd_DISPLAY_OO_CURSOR_OFF); + d2: 8c e0 ldi r24, 0x0C ; 12 + d4: 2e d0 rcall .+92 ; 0x132 + lcd_instruct(lcd_ENTRY_MODE_SET|lcd_ENTRY_MODE_SET_INCREASE | lcd_ENTRY_MS_DISPLAY_NOT_S); + d6: 86 e0 ldi r24, 0x06 ; 6 + d8: 2c d0 rcall .+88 ; 0x132 + lcd_instruct(lcd_RETURN_HOME); + da: 82 e0 ldi r24, 0x02 ; 2 + dc: 2a d0 rcall .+84 ; 0x132 + lcd_5ms(); + de: 03 d0 rcall .+6 ; 0xe6 +} + e0: cf 91 pop r28 + e2: df 91 pop r29 + e4: 08 95 ret + +000000e6 : + +void lcd_5ms(void){ + e6: df 93 push r29 + e8: cf 93 push r28 + ea: 0f 92 push r0 + ec: cd b7 in r28, 0x3d ; 61 + ee: de b7 in r29, 0x3e ; 62 + for(uint8_t i=50;i>0;i--){ + f0: 82 e3 ldi r24, 0x32 ; 50 + f2: 89 83 std Y+1, r24 ; 0x01 + f4: 04 c0 rjmp .+8 ; 0xfe + wait_100us(); + f6: 24 d1 rcall .+584 ; 0x340 + lcd_instruct(lcd_RETURN_HOME); + lcd_5ms(); +} + +void lcd_5ms(void){ + for(uint8_t i=50;i>0;i--){ + f8: 89 81 ldd r24, Y+1 ; 0x01 + fa: 81 50 subi r24, 0x01 ; 1 + fc: 89 83 std Y+1, r24 ; 0x01 + fe: 89 81 ldd r24, Y+1 ; 0x01 + 100: 88 23 and r24, r24 + 102: c9 f7 brne .-14 ; 0xf6 + wait_100us(); + } + } + 104: 0f 90 pop r0 + 106: cf 91 pop r28 + 108: df 91 pop r29 + 10a: 08 95 ret + +0000010c : + +void lcd_1s(void){ + 10c: df 93 push r29 + 10e: cf 93 push r28 + 110: 0f 92 push r0 + 112: cd b7 in r28, 0x3d ; 61 + 114: de b7 in r29, 0x3e ; 62 + for(uint8_t i=200;i>0;i--){ + 116: 88 ec ldi r24, 0xC8 ; 200 + 118: 89 83 std Y+1, r24 ; 0x01 + 11a: 04 c0 rjmp .+8 ; 0x124 + lcd_5ms(); + 11c: e4 df rcall .-56 ; 0xe6 + wait_100us(); + } + } + +void lcd_1s(void){ + for(uint8_t i=200;i>0;i--){ + 11e: 89 81 ldd r24, Y+1 ; 0x01 + 120: 81 50 subi r24, 0x01 ; 1 + 122: 89 83 std Y+1, r24 ; 0x01 + 124: 89 81 ldd r24, Y+1 ; 0x01 + 126: 88 23 and r24, r24 + 128: c9 f7 brne .-14 ; 0x11c + lcd_5ms(); + } + } + 12a: 0f 90 pop r0 + 12c: cf 91 pop r28 + 12e: df 91 pop r29 + 130: 08 95 ret + +00000132 : + +void lcd_instruct(uint8_t zeichen){ + 132: df 93 push r29 + 134: cf 93 push r28 + 136: 0f 92 push r0 + 138: cd b7 in r28, 0x3d ; 61 + 13a: de b7 in r29, 0x3e ; 62 + 13c: 89 83 std Y+1, r24 ; 0x01 + lcd_write(instruct,zeichen,0); + 13e: 84 e0 ldi r24, 0x04 ; 4 + 140: 69 81 ldd r22, Y+1 ; 0x01 + 142: 40 e0 ldi r20, 0x00 ; 0 + 144: 04 d0 rcall .+8 ; 0x14e + } + 146: 0f 90 pop r0 + 148: cf 91 pop r28 + 14a: df 91 pop r29 + 14c: 08 95 ret + +0000014e : + +void lcd_write(uint8_t lcd_whichwrite, uint8_t zeichen, uint8_t position){ + 14e: df 93 push r29 + 150: cf 93 push r28 + 152: 00 d0 rcall .+0 ; 0x154 + 154: 00 d0 rcall .+0 ; 0x156 + 156: 0f 92 push r0 + 158: cd b7 in r28, 0x3d ; 61 + 15a: de b7 in r29, 0x3e ; 62 + 15c: 89 83 std Y+1, r24 ; 0x01 + 15e: 6a 83 std Y+2, r22 ; 0x02 + 160: 4b 83 std Y+3, r20 ; 0x03 + switch (lcd_whichwrite){ + 162: 89 81 ldd r24, Y+1 ; 0x01 + 164: 28 2f mov r18, r24 + 166: 30 e0 ldi r19, 0x00 ; 0 + 168: 3d 83 std Y+5, r19 ; 0x05 + 16a: 2c 83 std Y+4, r18 ; 0x04 + 16c: 8c 81 ldd r24, Y+4 ; 0x04 + 16e: 9d 81 ldd r25, Y+5 ; 0x05 + 170: 84 30 cpi r24, 0x04 ; 4 + 172: 91 05 cpc r25, r1 + 174: 7c f4 brge .+30 ; 0x194 + 176: 2c 81 ldd r18, Y+4 ; 0x04 + 178: 3d 81 ldd r19, Y+5 ; 0x05 + 17a: 22 30 cpi r18, 0x02 ; 2 + 17c: 31 05 cpc r19, r1 + 17e: bc f4 brge .+46 ; 0x1ae + 180: 8c 81 ldd r24, Y+4 ; 0x04 + 182: 9d 81 ldd r25, Y+5 ; 0x05 + 184: 00 97 sbiw r24, 0x00 ; 0 + 186: f9 f0 breq .+62 ; 0x1c6 + 188: 2c 81 ldd r18, Y+4 ; 0x04 + 18a: 3d 81 ldd r19, Y+5 ; 0x05 + 18c: 21 30 cpi r18, 0x01 ; 1 + 18e: 31 05 cpc r19, r1 + 190: b9 f0 breq .+46 ; 0x1c0 + 192: 20 c0 rjmp .+64 ; 0x1d4 + 194: 8c 81 ldd r24, Y+4 ; 0x04 + 196: 9d 81 ldd r25, Y+5 ; 0x05 + 198: 84 30 cpi r24, 0x04 ; 4 + 19a: 91 05 cpc r25, r1 + 19c: d9 f4 brne .+54 ; 0x1d4 + case instruct : + unset_lcd_RS; + 19e: a2 e3 ldi r26, 0x32 ; 50 + 1a0: b0 e0 ldi r27, 0x00 ; 0 + 1a2: e2 e3 ldi r30, 0x32 ; 50 + 1a4: f0 e0 ldi r31, 0x00 ; 0 + 1a6: 80 81 ld r24, Z + 1a8: 87 7f andi r24, 0xF7 ; 247 + 1aa: 8c 93 st X, r24 + 1ac: 13 c0 rjmp .+38 ; 0x1d4 + break; + case line2: + case line1: + position = position & 0x3f; + 1ae: 8b 81 ldd r24, Y+3 ; 0x03 + 1b0: 8f 73 andi r24, 0x3F ; 63 + 1b2: 8b 83 std Y+3, r24 ; 0x03 + if (lcd_whichwrite == line2){ position=position + 0x40; }; + 1b4: 89 81 ldd r24, Y+1 ; 0x01 + 1b6: 83 30 cpi r24, 0x03 ; 3 + 1b8: 19 f4 brne .+6 ; 0x1c0 + 1ba: 8b 81 ldd r24, Y+3 ; 0x03 + 1bc: 80 5c subi r24, 0xC0 ; 192 + 1be: 8b 83 std Y+3, r24 ; 0x03 + case therepos: + lcd_instruct(lcd_mask_Write_Adress(position)); + 1c0: 8b 81 ldd r24, Y+3 ; 0x03 + 1c2: 80 68 ori r24, 0x80 ; 128 + 1c4: b6 df rcall .-148 ; 0x132 + case here: + set_lcd_RS; + 1c6: a2 e3 ldi r26, 0x32 ; 50 + 1c8: b0 e0 ldi r27, 0x00 ; 0 + 1ca: e2 e3 ldi r30, 0x32 ; 50 + 1cc: f0 e0 ldi r31, 0x00 ; 0 + 1ce: 80 81 ld r24, Z + 1d0: 88 60 ori r24, 0x08 ; 8 + 1d2: 8c 93 st X, r24 + break; + + + } + set_lcd_E; + 1d4: a2 e3 ldi r26, 0x32 ; 50 + 1d6: b0 e0 ldi r27, 0x00 ; 0 + 1d8: e2 e3 ldi r30, 0x32 ; 50 + 1da: f0 e0 ldi r31, 0x00 ; 0 + 1dc: 80 81 ld r24, Z + 1de: 84 60 ori r24, 0x04 ; 4 + 1e0: 8c 93 st X, r24 + set_lcd_E; + 1e2: a2 e3 ldi r26, 0x32 ; 50 + 1e4: b0 e0 ldi r27, 0x00 ; 0 + 1e6: e2 e3 ldi r30, 0x32 ; 50 + 1e8: f0 e0 ldi r31, 0x00 ; 0 + 1ea: 80 81 ld r24, Z + 1ec: 84 60 ori r24, 0x04 ; 4 + 1ee: 8c 93 st X, r24 + lcd_dataport=lcd_dataport&~lcd_dataport_mask|zeichen&lcd_dataport_mask; + 1f0: a8 e3 ldi r26, 0x38 ; 56 + 1f2: b0 e0 ldi r27, 0x00 ; 0 + 1f4: e8 e3 ldi r30, 0x38 ; 56 + 1f6: f0 e0 ldi r31, 0x00 ; 0 + 1f8: 80 81 ld r24, Z + 1fa: 98 2f mov r25, r24 + 1fc: 9f 70 andi r25, 0x0F ; 15 + 1fe: 8a 81 ldd r24, Y+2 ; 0x02 + 200: 80 7f andi r24, 0xF0 ; 240 + 202: 89 2b or r24, r25 + 204: 8c 93 st X, r24 + lcd_dataport=lcd_dataport&~lcd_dataport_mask|zeichen&lcd_dataport_mask; + 206: a8 e3 ldi r26, 0x38 ; 56 + 208: b0 e0 ldi r27, 0x00 ; 0 + 20a: e8 e3 ldi r30, 0x38 ; 56 + 20c: f0 e0 ldi r31, 0x00 ; 0 + 20e: 80 81 ld r24, Z + 210: 98 2f mov r25, r24 + 212: 9f 70 andi r25, 0x0F ; 15 + 214: 8a 81 ldd r24, Y+2 ; 0x02 + 216: 80 7f andi r24, 0xF0 ; 240 + 218: 89 2b or r24, r25 + 21a: 8c 93 st X, r24 + unset_lcd_E; + 21c: a2 e3 ldi r26, 0x32 ; 50 + 21e: b0 e0 ldi r27, 0x00 ; 0 + 220: e2 e3 ldi r30, 0x32 ; 50 + 222: f0 e0 ldi r31, 0x00 ; 0 + 224: 80 81 ld r24, Z + 226: 8b 7f andi r24, 0xFB ; 251 + 228: 8c 93 st X, r24 + unset_lcd_E; + 22a: a2 e3 ldi r26, 0x32 ; 50 + 22c: b0 e0 ldi r27, 0x00 ; 0 + 22e: e2 e3 ldi r30, 0x32 ; 50 + 230: f0 e0 ldi r31, 0x00 ; 0 + 232: 80 81 ld r24, Z + 234: 8b 7f andi r24, 0xFB ; 251 + 236: 8c 93 st X, r24 + wait_100us(); + 238: 83 d0 rcall .+262 ; 0x340 + if (lcd_dataport_DDR==0xf0){ + 23a: e7 e3 ldi r30, 0x37 ; 55 + 23c: f0 e0 ldi r31, 0x00 ; 0 + 23e: 80 81 ld r24, Z + 240: 80 3f cpi r24, 0xF0 ; 240 + 242: b9 f5 brne .+110 ; 0x2b2 + zeichen=zeichen << 4; + 244: 8a 81 ldd r24, Y+2 ; 0x02 + 246: 82 95 swap r24 + 248: 80 7f andi r24, 0xF0 ; 240 + 24a: 8a 83 std Y+2, r24 ; 0x02 + set_lcd_E; + 24c: a2 e3 ldi r26, 0x32 ; 50 + 24e: b0 e0 ldi r27, 0x00 ; 0 + 250: e2 e3 ldi r30, 0x32 ; 50 + 252: f0 e0 ldi r31, 0x00 ; 0 + 254: 80 81 ld r24, Z + 256: 84 60 ori r24, 0x04 ; 4 + 258: 8c 93 st X, r24 + set_lcd_E; + 25a: a2 e3 ldi r26, 0x32 ; 50 + 25c: b0 e0 ldi r27, 0x00 ; 0 + 25e: e2 e3 ldi r30, 0x32 ; 50 + 260: f0 e0 ldi r31, 0x00 ; 0 + 262: 80 81 ld r24, Z + 264: 84 60 ori r24, 0x04 ; 4 + 266: 8c 93 st X, r24 + lcd_dataport=lcd_dataport&~lcd_dataport_mask|zeichen&lcd_dataport_mask; + 268: a8 e3 ldi r26, 0x38 ; 56 + 26a: b0 e0 ldi r27, 0x00 ; 0 + 26c: e8 e3 ldi r30, 0x38 ; 56 + 26e: f0 e0 ldi r31, 0x00 ; 0 + 270: 80 81 ld r24, Z + 272: 98 2f mov r25, r24 + 274: 9f 70 andi r25, 0x0F ; 15 + 276: 8a 81 ldd r24, Y+2 ; 0x02 + 278: 80 7f andi r24, 0xF0 ; 240 + 27a: 89 2b or r24, r25 + 27c: 8c 93 st X, r24 + lcd_dataport=lcd_dataport&~lcd_dataport_mask|zeichen&lcd_dataport_mask; + 27e: a8 e3 ldi r26, 0x38 ; 56 + 280: b0 e0 ldi r27, 0x00 ; 0 + 282: e8 e3 ldi r30, 0x38 ; 56 + 284: f0 e0 ldi r31, 0x00 ; 0 + 286: 80 81 ld r24, Z + 288: 98 2f mov r25, r24 + 28a: 9f 70 andi r25, 0x0F ; 15 + 28c: 8a 81 ldd r24, Y+2 ; 0x02 + 28e: 80 7f andi r24, 0xF0 ; 240 + 290: 89 2b or r24, r25 + 292: 8c 93 st X, r24 + unset_lcd_E; + 294: a2 e3 ldi r26, 0x32 ; 50 + 296: b0 e0 ldi r27, 0x00 ; 0 + 298: e2 e3 ldi r30, 0x32 ; 50 + 29a: f0 e0 ldi r31, 0x00 ; 0 + 29c: 80 81 ld r24, Z + 29e: 8b 7f andi r24, 0xFB ; 251 + 2a0: 8c 93 st X, r24 + unset_lcd_E; + 2a2: a2 e3 ldi r26, 0x32 ; 50 + 2a4: b0 e0 ldi r27, 0x00 ; 0 + 2a6: e2 e3 ldi r30, 0x32 ; 50 + 2a8: f0 e0 ldi r31, 0x00 ; 0 + 2aa: 80 81 ld r24, Z + 2ac: 8b 7f andi r24, 0xFB ; 251 + 2ae: 8c 93 st X, r24 + wait_100us(); + 2b0: 47 d0 rcall .+142 ; 0x340 + } +} + 2b2: 0f 90 pop r0 + 2b4: 0f 90 pop r0 + 2b6: 0f 90 pop r0 + 2b8: 0f 90 pop r0 + 2ba: 0f 90 pop r0 + 2bc: cf 91 pop r28 + 2be: df 91 pop r29 + 2c0: 08 95 ret + +000002c2 : + +void lcd_blank_line(uint8_t lcd_whichwrite) + { + 2c2: df 93 push r29 + 2c4: cf 93 push r28 + 2c6: 00 d0 rcall .+0 ; 0x2c8 + 2c8: 00 d0 rcall .+0 ; 0x2ca + 2ca: 0f 92 push r0 + 2cc: cd b7 in r28, 0x3d ; 61 + 2ce: de b7 in r29, 0x3e ; 62 + 2d0: 8b 83 std Y+3, r24 ; 0x03 + uint8_t count; + uint8_t countin; + + switch (lcd_whichwrite){ + 2d2: 8b 81 ldd r24, Y+3 ; 0x03 + 2d4: 28 2f mov r18, r24 + 2d6: 30 e0 ldi r19, 0x00 ; 0 + 2d8: 3d 83 std Y+5, r19 ; 0x05 + 2da: 2c 83 std Y+4, r18 ; 0x04 + 2dc: 8c 81 ldd r24, Y+4 ; 0x04 + 2de: 9d 81 ldd r25, Y+5 ; 0x05 + 2e0: 83 30 cpi r24, 0x03 ; 3 + 2e2: 91 05 cpc r25, r1 + 2e4: 69 f0 breq .+26 ; 0x300 + 2e6: 2c 81 ldd r18, Y+4 ; 0x04 + 2e8: 3d 81 ldd r19, Y+5 ; 0x05 + 2ea: 24 30 cpi r18, 0x04 ; 4 + 2ec: 31 05 cpc r19, r1 + 2ee: 31 f0 breq .+12 ; 0x2fc + 2f0: 8c 81 ldd r24, Y+4 ; 0x04 + 2f2: 9d 81 ldd r25, Y+5 ; 0x05 + 2f4: 82 30 cpi r24, 0x02 ; 2 + 2f6: 91 05 cpc r25, r1 + 2f8: 31 f0 breq .+12 ; 0x306 + 2fa: 06 c0 rjmp .+12 ; 0x308 + case instruct: + lcd_blank_line(line1); + 2fc: 82 e0 ldi r24, 0x02 ; 2 + 2fe: e1 df rcall .-62 ; 0x2c2 + case line2: + count=0x40; + 300: 80 e4 ldi r24, 0x40 ; 64 + 302: 8a 83 std Y+2, r24 ; 0x02 + 304: 01 c0 rjmp .+2 ; 0x308 + break; + case line1: + count=0; + 306: 1a 82 std Y+2, r1 ; 0x02 + } + + for (countin=count; countin < count+15; countin++){ + 308: 8a 81 ldd r24, Y+2 ; 0x02 + 30a: 89 83 std Y+1, r24 ; 0x01 + 30c: 07 c0 rjmp .+14 ; 0x31c + lcd_write(therepos, 32, countin); + 30e: 81 e0 ldi r24, 0x01 ; 1 + 310: 60 e2 ldi r22, 0x20 ; 32 + 312: 49 81 ldd r20, Y+1 ; 0x01 + 314: 1c df rcall .-456 ; 0x14e + break; + case line1: + count=0; + } + + for (countin=count; countin < count+15; countin++){ + 316: 89 81 ldd r24, Y+1 ; 0x01 + 318: 8f 5f subi r24, 0xFF ; 255 + 31a: 89 83 std Y+1, r24 ; 0x01 + 31c: 89 81 ldd r24, Y+1 ; 0x01 + 31e: 28 2f mov r18, r24 + 320: 30 e0 ldi r19, 0x00 ; 0 + 322: 8a 81 ldd r24, Y+2 ; 0x02 + 324: 88 2f mov r24, r24 + 326: 90 e0 ldi r25, 0x00 ; 0 + 328: 0f 96 adiw r24, 0x0f ; 15 + 32a: 28 17 cp r18, r24 + 32c: 39 07 cpc r19, r25 + 32e: 7c f3 brlt .-34 ; 0x30e + lcd_write(therepos, 32, countin); + } +} + 330: 0f 90 pop r0 + 332: 0f 90 pop r0 + 334: 0f 90 pop r0 + 336: 0f 90 pop r0 + 338: 0f 90 pop r0 + 33a: cf 91 pop r28 + 33c: df 91 pop r29 + 33e: 08 95 ret + +00000340 : +#include +#include +#include "lcd4.h" + +void wait_100us(void){ + 340: df 93 push r29 + 342: cf 93 push r28 + 344: 00 d0 rcall .+0 ; 0x346 + 346: 00 d0 rcall .+0 ; 0x348 + 348: 0f 92 push r0 + 34a: cd b7 in r28, 0x3d ; 61 + 34c: de b7 in r29, 0x3e ; 62 + for (volatile uint8_t i=68;i--;i>0){ + 34e: 84 e4 ldi r24, 0x44 ; 68 + 350: 89 83 std Y+1, r24 ; 0x01 + 352: 02 c0 rjmp .+4 ; 0x358 + i; + 354: 89 81 ldd r24, Y+1 ; 0x01 +#include +#include +#include "lcd4.h" + +void wait_100us(void){ + for (volatile uint8_t i=68;i--;i>0){ + 356: 89 81 ldd r24, Y+1 ; 0x01 + 358: 89 81 ldd r24, Y+1 ; 0x01 + 35a: 8a 83 std Y+2, r24 ; 0x02 + 35c: 8a 81 ldd r24, Y+2 ; 0x02 + 35e: 8d 83 std Y+5, r24 ; 0x05 + 360: 8d 81 ldd r24, Y+5 ; 0x05 + 362: 88 23 and r24, r24 + 364: 11 f0 breq .+4 ; 0x36a + 366: 81 e0 ldi r24, 0x01 ; 1 + 368: 8d 83 std Y+5, r24 ; 0x05 + 36a: 9d 81 ldd r25, Y+5 ; 0x05 + 36c: 8a 81 ldd r24, Y+2 ; 0x02 + 36e: 81 50 subi r24, 0x01 ; 1 + 370: 89 83 std Y+1, r24 ; 0x01 + 372: 99 23 and r25, r25 + 374: 79 f7 brne .-34 ; 0x354 + i; + } +} + 376: 0f 90 pop r0 + 378: 0f 90 pop r0 + 37a: 0f 90 pop r0 + 37c: 0f 90 pop r0 + 37e: 0f 90 pop r0 + 380: cf 91 pop r28 + 382: df 91 pop r29 + 384: 08 95 ret + +00000386
: +#include +#include +#define lcd_bus8 +#include "lcd4.h" + +int main(void){ + 386: df 93 push r29 + 388: cf 93 push r28 + 38a: cd b7 in r28, 0x3d ; 61 + 38c: de b7 in r29, 0x3e ; 62 + lcd_1s(); + 38e: be de rcall .-644 ; 0x10c + lcd_init(); + 390: 64 de rcall .-824 ; 0x5a + lcd_1s(); + 392: bc de rcall .-648 ; 0x10c + lcd_1s(); + 394: bb de rcall .-650 ; 0x10c + lcd_write(therepos,0x41,0x08); + 396: 81 e0 ldi r24, 0x01 ; 1 + 398: 61 e4 ldi r22, 0x41 ; 65 + 39a: 48 e0 ldi r20, 0x08 ; 8 + 39c: d8 de rcall .-592 ; 0x14e + lcd_1s(); + 39e: b6 de rcall .-660 ; 0x10c + lcd_1s(); + 3a0: b5 de rcall .-662 ; 0x10c + lcd_write(here,0x42,0); + 3a2: 80 e0 ldi r24, 0x00 ; 0 + 3a4: 62 e4 ldi r22, 0x42 ; 66 + 3a6: 40 e0 ldi r20, 0x00 ; 0 + 3a8: d2 de rcall .-604 ; 0x14e + lcd_1s(); + 3aa: b0 de rcall .-672 ; 0x10c + lcd_1s(); + 3ac: af de rcall .-674 ; 0x10c + lcd_write(here,0x43,0); + 3ae: 80 e0 ldi r24, 0x00 ; 0 + 3b0: 63 e4 ldi r22, 0x43 ; 67 + 3b2: 40 e0 ldi r20, 0x00 ; 0 + 3b4: cc de rcall .-616 ; 0x14e + lcd_1s(); + 3b6: aa de rcall .-684 ; 0x10c + lcd_1s(); + 3b8: a9 de rcall .-686 ; 0x10c + lcd_write(here,0x44,0); + 3ba: 80 e0 ldi r24, 0x00 ; 0 + 3bc: 64 e4 ldi r22, 0x44 ; 68 + 3be: 40 e0 ldi r20, 0x00 ; 0 + 3c0: c6 de rcall .-628 ; 0x14e + lcd_1s(); + 3c2: a4 de rcall .-696 ; 0x10c + lcd_1s(); + 3c4: a3 de rcall .-698 ; 0x10c + DDRB = 0x0f; + 3c6: e7 e3 ldi r30, 0x37 ; 55 + 3c8: f0 e0 ldi r31, 0x00 ; 0 + 3ca: 8f e0 ldi r24, 0x0F ; 15 + 3cc: 80 83 st Z, r24 + while(1==1){ + PORTB = 0x0f; + 3ce: e8 e3 ldi r30, 0x38 ; 56 + 3d0: f0 e0 ldi r31, 0x00 ; 0 + 3d2: 8f e0 ldi r24, 0x0F ; 15 + 3d4: 80 83 st Z, r24 + lcd_1s(); + 3d6: 9a de rcall .-716 ; 0x10c + PORTB = 0x05; + 3d8: e8 e3 ldi r30, 0x38 ; 56 + 3da: f0 e0 ldi r31, 0x00 ; 0 + 3dc: 85 e0 ldi r24, 0x05 ; 5 + 3de: 80 83 st Z, r24 + lcd_1s(); + 3e0: 95 de rcall .-726 ; 0x10c + PORTB = 0x0A; + 3e2: e8 e3 ldi r30, 0x38 ; 56 + 3e4: f0 e0 ldi r31, 0x00 ; 0 + 3e6: 8a e0 ldi r24, 0x0A ; 10 + 3e8: 80 83 st Z, r24 + lcd_1s(); + 3ea: 90 de rcall .-736 ; 0x10c + 3ec: f0 cf rjmp .-32 ; 0x3ce + +000003ee <_exit>: + 3ee: f8 94 cli + +000003f0 <__stop_program>: + 3f0: ff cf rjmp .-2 ; 0x3f0 <__stop_program> diff --git a/Libs/LCD4/avrmb2313_notkermobil/LCD4.map b/Libs/LCD4/avrmb2313_notkermobil/LCD4.map new file mode 100644 index 0000000..8f1bfe8 --- /dev/null +++ b/Libs/LCD4/avrmb2313_notkermobil/LCD4.map @@ -0,0 +1,368 @@ +Archive member included because of file (symbol) + +/usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_exit.o) + /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o (exit) +/usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_copy_data.o) + ./lcd4.o (__do_copy_data) +/usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_clear_bss.o) + ./lcd4.o (__do_clear_bss) + +Memory Configuration + +Name Origin Length Attributes +text 0x00000000 0x00002000 xr +data 0x00800060 0x0000ffa0 rw !x +eeprom 0x00810000 0x00010000 rw !x +fuse 0x00820000 0x00000400 rw !x +lock 0x00830000 0x00000400 rw !x +signature 0x00840000 0x00000400 rw !x +*default* 0x00000000 0xffffffff + +Linker script and memory map + +LOAD /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o +LOAD ./lcd4.o +LOAD ./lcd_wait.o +LOAD ./lcdtest.o +LOAD /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a +LOAD /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/libc.a +LOAD /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a + +.hash + *(.hash) + +.dynsym + *(.dynsym) + +.dynstr + *(.dynstr) + +.gnu.version + *(.gnu.version) + +.gnu.version_d + *(.gnu.version_d) + +.gnu.version_r + *(.gnu.version_r) + +.rel.init + *(.rel.init) + +.rela.init + *(.rela.init) + +.rel.text + *(.rel.text) + *(.rel.text.*) + *(.rel.gnu.linkonce.t*) + +.rela.text + *(.rela.text) + *(.rela.text.*) + *(.rela.gnu.linkonce.t*) + +.rel.fini + *(.rel.fini) + +.rela.fini + *(.rela.fini) + +.rel.rodata + *(.rel.rodata) + *(.rel.rodata.*) + *(.rel.gnu.linkonce.r*) + +.rela.rodata + *(.rela.rodata) + *(.rela.rodata.*) + *(.rela.gnu.linkonce.r*) + +.rel.data + *(.rel.data) + *(.rel.data.*) + *(.rel.gnu.linkonce.d*) + +.rela.data + *(.rela.data) + *(.rela.data.*) + *(.rela.gnu.linkonce.d*) + +.rel.ctors + *(.rel.ctors) + +.rela.ctors + *(.rela.ctors) + +.rel.dtors + *(.rel.dtors) + +.rela.dtors + *(.rela.dtors) + +.rel.got + *(.rel.got) + +.rela.got + *(.rela.got) + +.rel.bss + *(.rel.bss) + +.rela.bss + *(.rela.bss) + +.rel.plt + *(.rel.plt) + +.rela.plt + *(.rela.plt) + +.text 0x00000000 0x3f2 + *(.vectors) + .vectors 0x00000000 0x26 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o + 0x00000000 __vectors + 0x00000000 __vector_default + *(.vectors) + *(.progmem.gcc*) + *(.progmem*) + 0x00000026 . = ALIGN (0x2) + 0x00000026 __trampolines_start = . + *(.trampolines) + .trampolines 0x00000026 0x0 linker stubs + *(.trampolines*) + 0x00000026 __trampolines_end = . + *(.jumptables) + *(.jumptables*) + *(.lowtext) + *(.lowtext*) + 0x00000026 __ctors_start = . + *(.ctors) + 0x00000026 __ctors_end = . + 0x00000026 __dtors_start = . + *(.dtors) + 0x00000026 __dtors_end = . + SORT(*)(.ctors) + SORT(*)(.dtors) + *(.init0) + .init0 0x00000026 0x0 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o + 0x00000026 __init + *(.init0) + *(.init1) + *(.init1) + *(.init2) + .init2 0x00000026 0x8 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o + *(.init2) + *(.init3) + *(.init3) + *(.init4) + .init4 0x0000002e 0x16 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_copy_data.o) + 0x0000002e __do_copy_data + .init4 0x00000044 0x10 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_clear_bss.o) + 0x00000044 __do_clear_bss + *(.init4) + *(.init5) + *(.init5) + *(.init6) + *(.init6) + *(.init7) + *(.init7) + *(.init8) + *(.init8) + *(.init9) + .init9 0x00000054 0x4 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o + *(.init9) + *(.text) + .text 0x00000058 0x2 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o + 0x00000058 __vector_1 + 0x00000058 __vector_12 + 0x00000058 __bad_interrupt + 0x00000058 __vector_6 + 0x00000058 __vector_3 + 0x00000058 __vector_11 + 0x00000058 __vector_13 + 0x00000058 __vector_17 + 0x00000058 __vector_7 + 0x00000058 __vector_5 + 0x00000058 __vector_4 + 0x00000058 __vector_9 + 0x00000058 __vector_2 + 0x00000058 __vector_15 + 0x00000058 __vector_8 + 0x00000058 __vector_14 + 0x00000058 __vector_10 + 0x00000058 __vector_16 + 0x00000058 __vector_18 + .text 0x0000005a 0x2e6 ./lcd4.o + 0x0000014e lcd_write + 0x0000010c lcd_1s + 0x000002c2 lcd_blank_line + 0x000000e6 lcd_5ms + 0x00000132 lcd_instruct + 0x0000005a lcd_init + .text 0x00000340 0x46 ./lcd_wait.o + 0x00000340 wait_100us + .text 0x00000386 0x68 ./lcdtest.o + 0x00000386 main + .text 0x000003ee 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_exit.o) + .text 0x000003ee 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_copy_data.o) + .text 0x000003ee 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_clear_bss.o) + 0x000003ee . = ALIGN (0x2) + *(.text.*) + .text.libgcc 0x000003ee 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_exit.o) + .text.libgcc 0x000003ee 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_copy_data.o) + .text.libgcc 0x000003ee 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_clear_bss.o) + 0x000003ee . = ALIGN (0x2) + *(.fini9) + .fini9 0x000003ee 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_exit.o) + 0x000003ee exit + 0x000003ee _exit + *(.fini9) + *(.fini8) + *(.fini8) + *(.fini7) + *(.fini7) + *(.fini6) + *(.fini6) + *(.fini5) + *(.fini5) + *(.fini4) + *(.fini4) + *(.fini3) + *(.fini3) + *(.fini2) + *(.fini2) + *(.fini1) + *(.fini1) + *(.fini0) + .fini0 0x000003ee 0x4 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_exit.o) + *(.fini0) + 0x000003f2 _etext = . + +.data 0x00800060 0x0 load address 0x000003f2 + 0x00800060 PROVIDE (__data_start, .) + *(.data) + .data 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o + .data 0x00800060 0x0 ./lcd4.o + .data 0x00800060 0x0 ./lcd_wait.o + .data 0x00800060 0x0 ./lcdtest.o + .data 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_exit.o) + .data 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_copy_data.o) + .data 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_clear_bss.o) + *(.data*) + *(.rodata) + *(.rodata*) + *(.gnu.linkonce.d*) + 0x00800060 . = ALIGN (0x2) + 0x00800060 _edata = . + 0x00800060 PROVIDE (__data_end, .) + +.bss 0x00800060 0x0 load address 0x000003f2 + 0x00800060 PROVIDE (__bss_start, .) + *(.bss) + .bss 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o + .bss 0x00800060 0x0 ./lcd4.o + .bss 0x00800060 0x0 ./lcd_wait.o + .bss 0x00800060 0x0 ./lcdtest.o + .bss 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_exit.o) + .bss 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_copy_data.o) + .bss 0x00800060 0x0 /usr/lib/gcc/avr/4.3.2/avr25/libgcc.a(_clear_bss.o) + *(.bss*) + *(COMMON) + 0x00800060 PROVIDE (__bss_end, .) + 0x000003f2 __data_load_start = LOADADDR (.data) + 0x000003f2 __data_load_end = (__data_load_start + SIZEOF (.data)) + +.noinit 0x00800060 0x0 + 0x00800060 PROVIDE (__noinit_start, .) + *(.noinit*) + 0x00800060 PROVIDE (__noinit_end, .) + 0x00800060 _end = . + 0x00800060 PROVIDE (__heap_start, .) + +.eeprom 0x00810000 0x0 + *(.eeprom*) + 0x00810000 __eeprom_end = . + +.fuse + *(.fuse) + *(.lfuse) + *(.hfuse) + *(.efuse) + +.lock + *(.lock*) + +.signature + *(.signature*) + +.stab 0x00000000 0x1158 + *(.stab) + .stab 0x00000000 0x69c /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o + .stab 0x0000069c 0x6fc ./lcd4.o + 0x708 (size before relaxing) + .stab 0x00000d98 0x180 ./lcd_wait.o + 0x348 (size before relaxing) + .stab 0x00000f18 0x240 ./lcdtest.o + 0x408 (size before relaxing) + +.stabstr 0x00000000 0x7ee + *(.stabstr) + .stabstr 0x00000000 0x7ee /usr/lib/gcc/avr/4.3.2/../../../avr/lib/avr25/crttn2313.o + +.stab.excl + *(.stab.excl) + +.stab.exclstr + *(.stab.exclstr) + +.stab.index + *(.stab.index) + +.stab.indexstr + *(.stab.indexstr) + +.comment + *(.comment) + +.debug + *(.debug) + +.line + *(.line) + +.debug_srcinfo + *(.debug_srcinfo) + +.debug_sfnames + *(.debug_sfnames) + +.debug_aranges + *(.debug_aranges) + +.debug_pubnames + *(.debug_pubnames) + +.debug_info + *(.debug_info) + *(.gnu.linkonce.wi.*) + +.debug_abbrev + *(.debug_abbrev) + +.debug_line + *(.debug_line) + +.debug_frame + *(.debug_frame) + +.debug_str + *(.debug_str) + +.debug_loc + *(.debug_loc) + +.debug_macinfo + *(.debug_macinfo) +OUTPUT(LCD4.elf elf32-avr) +LOAD linker stubs diff --git a/Libs/LCD4/avrmb2313_notkermobil/lcd4.d b/Libs/LCD4/avrmb2313_notkermobil/lcd4.d new file mode 100644 index 0000000..134a475 --- /dev/null +++ b/Libs/LCD4/avrmb2313_notkermobil/lcd4.d @@ -0,0 +1,3 @@ +lcd4.d lcd4.o: ../lcd4.c ../lcd4.h + +../lcd4.h: diff --git a/Libs/LCD4/avrmb2313_notkermobil/lcd4.o b/Libs/LCD4/avrmb2313_notkermobil/lcd4.o new file mode 100644 index 0000000000000000000000000000000000000000..1473b4d0d9cb06b23fb7176db6bc5160c258032a GIT binary patch literal 6208 zcmcJTe~eUD701uOwxF${MNAcmmO{&}4D;jd%S(c8MSLdOp}^+1!EgSA|xBzm`41b`|I7= zr3w7uUG6)dd+xdSo^$SfZ{FkRrY)NTfdJ_epzY+hpj}Ed0ud7i-E;>nruR<2b^4F5 zzWeI?m#@y8_*b+2)62h^`5U;|8r?g2+HW00>jPzT4mOvJjo)G$n&!Xe<<9HqC7S*P zM)4}mR`clO>B$+IK8`wqO4DzhdhgWYGwjQfXW5&P%VTYtqUo_#YwK8htTnnSFuUaB z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^Wg-Oa^RpHpv;L5(C%_%T2y@8W5RP}T2v;poqaMbDx2J8{C8wl zba0)0GASxH?lRsxGABB;&OVtE8QFo{A+^&^M>Z_|oJ7?1DTs=r>?eLOXLZSl;M%R+ zW#W#j-r_yRg9e8iE{0{Z3?iPGa4v?U*5BwYR}ZFewsCg_Bf(_4SQ;wob`ov(kmptk zZb9p!2`JO%$D>I24apuXmh#1e^^)hNc67&icDLx(-Bcv#v8+`asc5iVs<_dVBczk+ z4VEemuRfgjQn6sI?wVFSh{rkRELBQgYBPI={bfb`K*O|4DI7nXB-Tf7tTq$sIgYq+ z(ygRw{!r<%HkcEMvYRsuv6Q@0wPTura;~yJ%kdcpZ#-ANI*i{|xxV01MYSl@IDEj% z4M2KzDT|uwZaEk7un`n0AP%-q5!j2%kY^pZJ}h{jlfzJo5J|=ycKZ>9&@(zKgD1*Ls!C;331zdEV6}`8@c7Vvdm?h-|}i RZoOSH`_P5wAnW=0|36pt0(JlZ literal 0 HcmV?d00001 diff --git a/Libs/LCD4/avrmb2313_notkermobil/lcd_wait.d b/Libs/LCD4/avrmb2313_notkermobil/lcd_wait.d new file mode 100644 index 0000000..680a7db --- /dev/null +++ b/Libs/LCD4/avrmb2313_notkermobil/lcd_wait.d @@ -0,0 +1,3 @@ +lcd_wait.d lcd_wait.o: ../lcd_wait.c ../lcd4.h + +../lcd4.h: diff --git a/Libs/LCD4/avrmb2313_notkermobil/lcd_wait.o b/Libs/LCD4/avrmb2313_notkermobil/lcd_wait.o new file mode 100644 index 0000000000000000000000000000000000000000..5d8cb96baaf8254edbe4e52f12caaec2094ed0d8 GIT binary patch literal 3676 zcmb7HU1%It6u#TUwDqrAf6yvYXwj~0c6VlHH`^Vn4{c(Eip3~>5F9o;lkCD~cb%DS zlOmXHd`JQj+u}nXL=b#Y@X@|Wg;IQx_EDj<1%20m4+>)Z&i$D=n;@k(-8tVq=R4=# zbM6`D_M^#@Q<+Rgn2`}PBAp3w^Fblb!{|uD5%G}NBko+faY@`1H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@0S1atDuh_Lvzr4t8lTE)WN3LwG|5`e%!_Q_M)Wt@EKPAIh>$rVih(t3a*D(M}DDAuL-7RABmyMhn0*HNdNo=^9+ zc64Y3vX6=HKhK&$ckXXN)^9Js`F3OfAhXl{$?t5WymQ|&HrcPC z$YNR=4^=vAqqs}--AXsA!;89ulKP?Q)0x|hGrz3*B*=blN&nK4K6~SN-t@^M$2Tk}@p&G>5!#H3(LyQNV-sg0NM%1DI5vArayi3Him;V4Ee$q4m literal 0 HcmV?d00001 diff --git a/Libs/LCD4/avrmb2313_notkermobil/makefile b/Libs/LCD4/avrmb2313_notkermobil/makefile new file mode 100644 index 0000000..3eb47a8 --- /dev/null +++ b/Libs/LCD4/avrmb2313_notkermobil/makefile @@ -0,0 +1,90 @@ +################################################################################ +# Automatically-generated file. Do not edit! +################################################################################ + +-include ../makefile.init + +RM := rm -rf + +# All of the sources participating in the build are defined here +-include sources.mk +-include subdir.mk +-include objects.mk + +ifneq ($(MAKECMDGOALS),clean) +ifneq ($(strip $(C_DEPS)),) +-include $(C_DEPS) +endif +ifneq ($(strip $(ASM_DEPS)),) +-include $(ASM_DEPS) +endif +ifneq ($(strip $(S_DEPS)),) +-include $(S_DEPS) +endif +ifneq ($(strip $(S_UPPER_DEPS)),) +-include $(S_UPPER_DEPS) +endif +endif + +-include ../makefile.defs + +# Add inputs and outputs from these tool invocations to the build variables +LSS += \ +LCD4.lss \ + +FLASH_IMAGE += \ +LCD4.hex \ + +EEPROM_IMAGE += \ +LCD4.eep \ + +SIZEDUMMY += \ +sizedummy \ + + +# All Target +all: LCD4.elf secondary-outputs + +# Tool invocations +LCD4.elf: $(OBJS) $(USER_OBJS) + @echo 'Building target: $@' + @echo 'Invoking: AVR C Linker' + avr-gcc -Wl,-Map,LCD4.map -mmcu=attiny2313 -o"LCD4.elf" $(OBJS) $(USER_OBJS) $(LIBS) + @echo 'Finished building target: $@' + @echo ' ' + +LCD4.lss: LCD4.elf + @echo 'Invoking: AVR Create Extended Listing' + -avr-objdump -h -S LCD4.elf >"LCD4.lss" + @echo 'Finished building: $@' + @echo ' ' + +LCD4.hex: LCD4.elf + @echo 'Create Flash image (ihex format)' + -avr-objcopy -R .eeprom -O ihex LCD4.elf "LCD4.hex" + @echo 'Finished building: $@' + @echo ' ' + +LCD4.eep: LCD4.elf + @echo 'Create eeprom image (ihex format)' + -avr-objcopy -j .eeprom --no-change-warnings --change-section-lma .eeprom=0 -O ihex LCD4.elf "LCD4.eep" + @echo 'Finished building: $@' + @echo ' ' + +sizedummy: LCD4.elf + @echo 'Invoking: Print Size' + -avr-size --format=avr --mcu=attiny2313 LCD4.elf + @echo 'Finished building: $@' + @echo ' ' + +# Other Targets +clean: + -$(RM) $(OBJS)$(C_DEPS)$(ASM_DEPS)$(EEPROM_IMAGE)$(FLASH_IMAGE)$(ELFS)$(LSS)$(S_DEPS)$(SIZEDUMMY)$(S_UPPER_DEPS) LCD4.elf + -@echo ' ' + +secondary-outputs: $(LSS) $(FLASH_IMAGE) $(EEPROM_IMAGE) $(SIZEDUMMY) + +.PHONY: all clean dependents +.SECONDARY: + +-include ../makefile.targets diff --git a/Libs/LCD4/avrmb2313_notkermobil/objects.mk b/Libs/LCD4/avrmb2313_notkermobil/objects.mk new file mode 100644 index 0000000..224ef68 --- /dev/null +++ b/Libs/LCD4/avrmb2313_notkermobil/objects.mk @@ -0,0 +1,7 @@ +################################################################################ +# Automatically-generated file. Do not edit! +################################################################################ + +USER_OBJS := + +LIBS := diff --git a/Libs/LCD4/avrmb2313_notkermobil/sources.mk b/Libs/LCD4/avrmb2313_notkermobil/sources.mk new file mode 100644 index 0000000..875f836 --- /dev/null +++ b/Libs/LCD4/avrmb2313_notkermobil/sources.mk @@ -0,0 +1,25 @@ +################################################################################ +# Automatically-generated file. Do not edit! +################################################################################ + +O_SRCS := +C_SRCS := +S_UPPER_SRCS := +S_SRCS := +OBJ_SRCS := +ASM_SRCS := +OBJS := +C_DEPS := +ASM_DEPS := +EEPROM_IMAGE := +FLASH_IMAGE := +ELFS := +LSS := +S_DEPS := +SIZEDUMMY := +S_UPPER_DEPS := + +# Every subdirectory with source files must be described here +SUBDIRS := \ +. \ + diff --git a/Libs/LCD4/avrmb2313_notkermobil/subdir.mk b/Libs/LCD4/avrmb2313_notkermobil/subdir.mk new file mode 100644 index 0000000..d06f565 --- /dev/null +++ b/Libs/LCD4/avrmb2313_notkermobil/subdir.mk @@ -0,0 +1,30 @@ +################################################################################ +# Automatically-generated file. Do not edit! +################################################################################ + +# Add inputs and outputs from these tool invocations to the build variables +C_SRCS += \ +../lcd4.c \ +../lcd_wait.c \ +../lcdtest.c + +OBJS += \ +./lcd4.o \ +./lcd_wait.o \ +./lcdtest.o + +C_DEPS += \ +./lcd4.d \ +./lcd_wait.d \ +./lcdtest.d + + +# Each subdirectory must supply rules for building sources it contributes +%.o: ../%.c + @echo 'Building file: $<' + @echo 'Invoking: AVR Compiler' + avr-gcc -Wall -g2 -gstabs -O0 -fpack-struct -fshort-enums -std=gnu99 -funsigned-char -funsigned-bitfields -mmcu=attiny2313 -DF_CPU=10000000UL -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@:%.o=%.d)" -c -o"$@" "$<" + @echo 'Finished building: $<' + @echo ' ' + + diff --git a/Libs/LCD4/lcd4.c b/Libs/LCD4/lcd4.c new file mode 100644 index 0000000..415c5e8 --- /dev/null +++ b/Libs/LCD4/lcd4.c @@ -0,0 +1,132 @@ +/************************************ +* lcd-Treiber-Bibliothek für Hitachi 44780 und kompatible +* z.B. KS0070B +* +*/ +#include +#include +#include "lcd4.h" + +/* Prototypes */ +extern void wait_100us(void); +//void lcd_init(void); +//void lcd_write(uint8_t whichwrite, uint8_t zeichen, uint8_t position); +void lcd_instruct(uint8_t zeichen); //Optimzation of Code length (costs one fuction call) + // expands to lcd_write(instruct, zeichen, 0); +// void lcd_blank_line(uint8_t lcd_whichwrite); +void lcd_preinstruct(uint8_t zeichen); //Optimzation of Code length (costs one fuction call) + // expands to lcd_write(preinstruct, zeichen, 0); +// void lcd_blank_line(uint8_t lcd_whichwrite); + +// Implementation +void lcd_5ms(void); +void lcd_1s(void); +/* end Prototypes */ + + +#define lcd_mask_Write_Adress(position) ((position & 0x7F)| lcd_SET_DD_RAM) + + + +void lcd_init(void){ + /* setting up ports first */ + lcd_dataport_DDR=0xff; + set_lcd_RS_DDR; + set_lcd_E_DDR; + /* end setting up ports */ + lcd_dataport=0xff; + set_lcd_RS; + set_lcd_E; + lcd_5ms(); + lcd_5ms(); + lcd_5ms(); + lcd_instruct(lcd_SET_FUNCTION_8BIT); + lcd_5ms(); + lcd_instruct(lcd_SET_FUNCTION_8BIT); + wait_100us(); + lcd_instruct(lcd_SET_FUNCTION_8BIT); + if (lcd_dataport_mask==0xf0){ + lcd_instruct(lcd_SET_FUNCTION_4BIT|lcd_SET_FUNCTION_2LINE|lcd_SET_FUNCTION_7X5); + }else{ + lcd_instruct(lcd_SET_FUNCTION_8BIT|lcd_SET_FUNCTION_2LINE|lcd_SET_FUNCTION_7X5); + } + lcd_dataport_DDR&=lcd_dataport_mask; + lcd_instruct(lcd_DISPLAY_OO_ON|lcd_DISPLAY_OO_CURSOR_OFF); + lcd_instruct(lcd_ENTRY_MODE_SET|lcd_ENTRY_MODE_SET_INCREASE | lcd_ENTRY_MS_DISPLAY_NOT_S); + lcd_instruct(lcd_RETURN_HOME); + lcd_5ms(); +} + +void lcd_5ms(void){ + for(uint8_t i=50;i>0;i--){ + wait_100us(); + } + } + +void lcd_1s(void){ + for(uint8_t i=200;i>0;i--){ + lcd_5ms(); + } + } + +void lcd_instruct(uint8_t zeichen){ + lcd_write(instruct,zeichen,0); + } + +void lcd_write(uint8_t lcd_whichwrite, uint8_t zeichen, uint8_t position){ + switch (lcd_whichwrite){ + case instruct : + unset_lcd_RS; + break; + case line2: + case line1: + position = position & 0x3f; + if (lcd_whichwrite == line2){ position=position + 0x40; }; + case therepos: + lcd_instruct(lcd_mask_Write_Adress(position)); + case here: + set_lcd_RS; + break; + + + } + set_lcd_E; + set_lcd_E; + lcd_dataport=lcd_dataport&~lcd_dataport_mask|zeichen&lcd_dataport_mask; + lcd_dataport=lcd_dataport&~lcd_dataport_mask|zeichen&lcd_dataport_mask; + unset_lcd_E; + unset_lcd_E; + wait_100us(); + if (lcd_dataport_DDR==0xf0){ + zeichen=zeichen << 4; + set_lcd_E; + set_lcd_E; + lcd_dataport=lcd_dataport&~lcd_dataport_mask|zeichen&lcd_dataport_mask; + lcd_dataport=lcd_dataport&~lcd_dataport_mask|zeichen&lcd_dataport_mask; + unset_lcd_E; + unset_lcd_E; + wait_100us(); + } +} + +void lcd_blank_line(uint8_t lcd_whichwrite) + { + uint8_t count; + uint8_t countin; + + switch (lcd_whichwrite){ + case instruct: + lcd_blank_line(line1); + case line2: + count=0x40; + break; + case line1: + count=0; + } + + for (countin=count; countin < count+15; countin++){ + lcd_write(therepos, 32, countin); + } +} + + diff --git a/Libs/LCD4/lcd4.c2 b/Libs/LCD4/lcd4.c2 new file mode 100644 index 0000000..6bab342 --- /dev/null +++ b/Libs/LCD4/lcd4.c2 @@ -0,0 +1,135 @@ +/************************************ +* lcd-Treiber-Bibliothek für Hitachi 44780 und kompatible +* z.B. KS0070B +* +*/ +#include +#include +#include "lcd4.h" + +/* Prototypes */ +extern void wait_100us(void); +//void lcd_init(void); +//void lcd_write(uint8_t whichwrite, uint8_t zeichen, uint8_t position); +void lcd_instruct(uint8_t zeichen); //Optimzation of Code length (costs one fuction call) + // expands to lcd_write(instruct, zeichen, 0); +// void lcd_blank_line(uint8_t lcd_whichwrite); +void lcd_preinstruct(uint8_t zeichen); //Optimzation of Code length (costs one fuction call) + // expands to lcd_write(preinstruct, zeichen, 0); +// void lcd_blank_line(uint8_t lcd_whichwrite); + +// Implementation +void lcd_5ms(void); +void lcd_1s(void); +/* end Prototypes */ + +#define lcd_mask_Write_Adress(position) ((position & 0x7F)| lcd_SET_DD_RAM) +// 4-Bit to be added, no indent +// enum whichtype{instruct, data}; +void lcd_init(void){ + /* setting up ports first */ + lcd_dataport_DDR=0xff; + lcd_dataport=0xff; + set_lcd_RS_DDR; + set_lcd_E_DDR; + /* end setting up ports */ + set_lcd_RS; + set_lcd_E; + lcd_5ms(); + lcd_5ms(); + lcd_5ms(); + lcd_instruct(lcd_SET_FUNCTION_8BIT); + lcd_5ms(); + lcd_instruct(lcd_SET_FUNCTION_8BIT); + lcd_instruct(lcd_SET_FUNCTION_8BIT); + #ifdef lcd_bus8 + lcd_preinstruct(lcd_SET_FUNCTION_8BIT|lcd_SET_FUNCTION_2LINE|lcd_SET_FUNCTION_7X5); + #endif + lcd_dataport_DDR|=lcd_dataport_mask; + #ifdef lcd_bus4 + lcd_instruct(lcd_SET_FUNCTION_4BIT|lcd_SET_FUNCTION_2LINE|lcd_SET_FUNCTION_7X5); + #endif + lcd_5ms(); + lcd_instruct(lcd_DISPLAY_OO_ON|lcd_DISPLAY_OO_CURSOR_OFF); + lcd_instruct(lcd_ENTRY_MODE_SET|lcd_ENTRY_MODE_SET_INCREASE | lcd_ENTRY_MS_DISPLAY_NOT_S); + lcd_instruct(lcd_RETURN_HOME); + lcd_5ms(); +} + +void lcd_5ms(void){ + for(uint8_t i=50;i>0;i--){ + wait_100us(); + } + } + +void lcd_1s(void){ + for(uint8_t i=200;i>0;i--){ + lcd_5ms(); + } + } + +void lcd_instruct(uint8_t zeichen){ + lcd_write(instruct,zeichen,0); + } +void lcd_preinstruct(uint8_t zeichen){ + lcd_write(preinstruct,zeichen,0); + } + +void lcd_write(uint8_t lcd_whichwrite, uint8_t zeichen, uint8_t position){ + switch (lcd_whichwrite){ + case instruct : + case preinstruct : + unset_lcd_RS; + break; + case line2: + case line1: + position = position & 0x3f; + if (lcd_whichwrite == line2){ position=position + 0x40; }; + case therepos: + lcd_instruct(lcd_mask_Write_Adress(position)); + case here: + set_lcd_RS; + break; + + + } + set_lcd_E; + asm volatile ("nop"); + lcd_dataport=( zeichen & lcd_dataport_mask); + asm volatile ("nop"); + #ifdef lcd_bus4 + if (!(lcd_whichwrite==preinstruct)){ + unset_lcd_E; + zeichen = zeichen << 4; + wait_100us(); + set_lcd_E; + asm volatile ("nop"); + lcd_dataport|=( zeichen & lcd_dataport_mask); + asm volatile ("nop"); + } + #endif + unset_lcd_E; + wait_100us(); + +} + +void lcd_blank_line(uint8_t lcd_whichwrite) + { + uint8_t count; + uint8_t countin; + + switch (lcd_whichwrite){ + case instruct: + lcd_blank_line(line1); + case line2: + count=0x40; + break; + case line1: + count=0; + break; + } + + for (countin=count; countin < count+15; countin++){ + lcd_write(therepos, 32, countin); + } +} diff --git a/Libs/LCD4/lcd4.h b/Libs/LCD4/lcd4.h new file mode 100644 index 0000000..63a0121 --- /dev/null +++ b/Libs/LCD4/lcd4.h @@ -0,0 +1,95 @@ +/* avrmb2313_lcd.h +* V 1.0 by (Hr & RJH-Systems) @ (FLG) +* 30.03.07 +* Zum Ansteuern eines zweizeiligen LCD-Displays +* Hitachi 44780 od. KS0070B +* auf dem AVR-evaluationsboard von Matze Brenner +* > www.flg-informatik.de +* 8-bit Mode +* 4-bit Mode +*/ +#ifndef avrmb2313_lcd + #define avrmb2313_lcd + #include + /* Some ports must be definded first, dont touch these for avrmb2313-project + * but set for other Designs using other out-Ports + */ + + + #ifndef lcd_bus4 + #ifndef lcd_bus8 + #define lcd_bus4 //defaults to 4-Bit + #endif + #endif + + #ifndef lcd_dataports_defined + #define lcd_dataports_defined + #include + #define lcd_dataport PORTB + #define lcd_dataport_DDR DDRB // DataDirectionRegister für lcd_datatport + //#ifdef lcd_bus8 + #define lcd_dataport_mask 0xf0 // which bits in that port (8-bit = 0xff for 8-bit operation) + //#else + // #define lcd_dataport_mask 0xf0 // which bits in that port (4-bit = 0xf0 for 4-bit operation) + // #endif + #define set_lcd_RS_DDR DDRD=(DDRD | ((uint8_t) 0x08)) // Dir-Out für lcd _RS setzen) + #define set_lcd_E_DDR DDRD=(DDRD | ((uint8_t) 0x04)) // Dir-Out für lcd _E setzen) + #define set_lcd_RS PORTD=(PORTD | ((uint8_t) 0x08)) // Bit für lcd _RS setzen) + #define unset_lcd_RS PORTD=(PORTD & ~((uint8_t) 0x08)) // Bit für lcd _RS löschen) + #define set_lcd_E PORTD=(PORTD | ((uint8_t) 0x04)) // Bit für lcd _E setzen) + #define unset_lcd_E PORTD=(PORTD & ~((uint8_t) 0x04)) // Bit für lcd _E löschen) + # + #endif + + + extern void wait_100us(void); // This function must be implemented + // Bitte eine Funktion "void wait_100us()" implementieren, die 100us wartet + // Please implement function "void wait_100us()": just waiting 100*10^(-6) s + extern void lcd_init(void); + extern void lcd_write(uint8_t lcd_whichwrite, uint8_t zeichen, uint8_t position); + enum lcd_whichwrite{here, therepos, line1, line2, instruct, preinstruct}; + extern void lcd_blank_line(uint8_t lcd_whichwrite); // line1, line2, instruct=all + extern void lcd_instruct(uint8_t zeichen); + /* possible "zeichen": + lcd_DISPLAY_CLEAR + lcd_RETURN_HOME + lcd_ENTRY_MODE_SET_INCREASE + lcd_ENTRY_MODE_SET_DECREASE + lcd_ENTRY_MODE_SET_DISPLAY_SHIFTED + lcd_ENTRY_MS_DISPLAY_NOT_S hifted + */ + extern void lcd_5ms(); //based on wait_100us + extern void lcd_1s(); //based on wait_100us + // Die Konstanten des lcd-Kontrollers local + #define lcd_DISPLAY_CLEAR 0b00000001 + #define lcd_RETURN_HOME 0b00000010 + #define lcd_ENTRY_MODE_SET 0b00000100 + #define lcd_ENTRY_MODE_SET_INCREASE 0b00000110 + #define lcd_ENTRY_MODE_SET_DECREASE 0b00000100 + #define lcd_ENTRY_MODE_SET_DISPLAY_SHIFTED 0b00000101 + #define lcd_ENTRY_MS_DISPLAY_NOT_S 0b00000100 + #define lcd_DISPLAY_OO 0b00001000 + #define lcd_DISPLAY_OO_ON 0b00001100 + #define lcd_DISPLAY_OO_OFF 0b00001000 + #define lcd_DISPLAY_OO_CURSOR_ON 0b00001010 + #define lcd_DISPLAY_OO_CURSOR_OFF 0b00001000 + #define lcd_DISPLAY_OO_BLINKING_ON 0b00001001 + #define lcd_DISPLAY_OO_BLINKING_OFF 0b00001000 + #define lcd_SHIFT 0b00010000 + #define lcd_SHIFT_DISPLAY_SHIFT 0b00011000 + #define lcd_SHIFT_CURSOR_MOVE 0b00010000 + #define lcd_SHIFT_RIGHT_SHIFT 0b00010100 + #define lcd_SHIFT_LEFT_SHIFT 0b00010000 + #define lcd_SET_FUNCTION 0b00100000 + #define lcd_SET_FUNCTION_8BIT 0b00110000 + #define lcd_SET_FUNCTION_4BIT 0b00100000 + #define lcd_SET_FUNCTION_2LINE 0b00101000 + #define lcd_SET_FUNCTION_1LINE 0b00100000 + #define lcd_SET_FUNCTION_5X10 0b00100100 + #define lcd_SET_FUNCTION_7X5 0b00100000 + #define lcd_SET_CG_RAM 0b01000000 + #define lcd_SET_DD_RAM 0b10000000 + + +#endif + diff --git a/Libs/LCD4/lcd_wait.c b/Libs/LCD4/lcd_wait.c new file mode 100644 index 0000000..3959a34 --- /dev/null +++ b/Libs/LCD4/lcd_wait.c @@ -0,0 +1,9 @@ +#include +#include +#include "lcd4.h" + +void wait_100us(void){ + for (volatile uint8_t i=68;i--;i>0){ + i; + } +} diff --git a/Libs/LCD4/lcdtest.c b/Libs/LCD4/lcdtest.c new file mode 100644 index 0000000..de2979e --- /dev/null +++ b/Libs/LCD4/lcdtest.c @@ -0,0 +1,34 @@ +#include +#include +#define lcd_bus8 +#include "lcd4.h" + +int main(void){ + lcd_1s(); + lcd_init(); + lcd_1s(); + lcd_1s(); + lcd_write(therepos,0x41,0x08); + lcd_1s(); + lcd_1s(); + lcd_write(here,0x42,0); + lcd_1s(); + lcd_1s(); + lcd_write(here,0x43,0); + lcd_1s(); + lcd_1s(); + lcd_write(here,0x44,0); + lcd_1s(); + lcd_1s(); + DDRB = 0x0f; + while(1==1){ + PORTB = 0x0f; + lcd_1s(); + PORTB = 0x05; + lcd_1s(); + PORTB = 0x0A; + lcd_1s(); + } +} + +