小菜单

This commit is contained in:
iridiumR 2022-05-19 21:07:52 +08:00
parent 1ef1a4c62f
commit ded1a91ff3
12 changed files with 1790 additions and 0 deletions

View file

@ -0,0 +1,549 @@
BL51 BANKED LINKER/LOCATER V6.22.2.0 05/19/2022 21:06:37 PAGE 1
BL51 BANKED LINKER/LOCATER V6.22.2.0, INVOKED BY:
C:\KEIL_V5\C51\BIN\BL51.EXE .\Objects\main.obj, .\Objects\menu.obj, .\Objects\delay.obj, .\Objects\display.obj TO .\Obje
>> cts\MCU_1 PRINT (.\Listings\MCU_1.m51)
MEMORY MODEL: LARGE
INPUT MODULES INCLUDED:
.\Objects\main.obj (MAIN)
.\Objects\menu.obj (MENU)
.\Objects\delay.obj (DELAY)
.\Objects\display.obj (DISPLAY)
C:\KEIL_V5\C51\LIB\C51L.LIB (?C_STARTUP)
C:\KEIL_V5\C51\LIB\C51L.LIB (?C?PLDPTR)
C:\KEIL_V5\C51\LIB\C51L.LIB (?C?PLDOPTR)
C:\KEIL_V5\C51\LIB\C51L.LIB (?C?ICALL)
C:\KEIL_V5\C51\LIB\C51L.LIB (?C_INIT)
C:\KEIL_V5\C51\LIB\C51L.LIB (?C?PLDIDATA)
C:\KEIL_V5\C51\LIB\C51L.LIB (?C?PLDXDATA)
C:\KEIL_V5\C51\LIB\C51L.LIB (?C?PLDPDATA)
C:\KEIL_V5\C51\LIB\C51L.LIB (?C?PLDCODE)
LINK MAP OF MODULE: .\Objects\MCU_1 (MAIN)
TYPE BASE LENGTH RELOCATION SEGMENT NAME
-----------------------------------------------------
* * * * * * * D A T A M E M O R Y * * * * * * *
REG 0000H 0008H ABSOLUTE "REG BANK 0"
IDATA 0008H 0001H UNIT ?STACK
* * * * * * * X D A T A M E M O R Y * * * * * * *
XDATA 0000H 000FH UNIT ?XD?MENU
XDATA 000FH 0007H UNIT _XDATA_GROUP_
XDATA 0016H 0004H UNIT ?XD?MINICLEAR?DISPLAY
XDATA 001AH 0004H UNIT ?XD?TEST?DISPLAY
* * * * * * * C O D E M E M O R Y * * * * * * *
CODE 0000H 0003H ABSOLUTE
CODE 0003H 01A0H UNIT ?CO?DISPLAY
CODE 01A3H 013BH UNIT ?PR?DRAWNUMBER?DISPLAY
CODE 02DEH 00C5H UNIT ?PR?CLEAR?DISPLAY
CODE 03A3H 00C5H UNIT ?PR?MINICLEAR?DISPLAY
CODE 0468H 00C5H UNIT ?PR?TEST?DISPLAY
CODE 052DH 008EH UNIT ?PR?DRAWNAME?DISPLAY
CODE 05BBH 008CH UNIT ?C_C51STARTUP
CODE 0647H 007DH UNIT ?C?LIB_CODE
CODE 06C4H 0042H UNIT ?PR?_M_STARTUP?MENU
CODE 0706H 002FH UNIT ?PR?MAIN?MAIN
CODE 0735H 0020H UNIT ?PR?_DELAY?DELAY
CODE 0755H 001CH UNIT ?PR?DISPLAYINIT?DISPLAY
CODE 0771H 0019H UNIT ?PR?WRITE?DISPLAY
CODE 078AH 000FH UNIT ?PR?MENUINIT?MENU
CODE 0799H 000BH UNIT ?PR?DELAY100US?DELAY
CODE 07A4H 000AH UNIT ?C_INITSEG
BL51 BANKED LINKER/LOCATER V6.22.2.0 05/19/2022 21:06:37 PAGE 2
OVERLAY MAP OF MODULE: .\Objects\MCU_1 (MAIN)
SEGMENT XDATA_GROUP
+--> CALLED SEGMENT START LENGTH
-----------------------------------------------
?C_C51STARTUP ----- -----
+--> ?PR?MAIN?MAIN
+--> ?C_INITSEG
?PR?MAIN?MAIN ----- -----
+--> ?PR?MENUINIT?MENU
?C_INITSEG ----- -----
+--> ?PR?_M_STARTUP?MENU
?PR?_M_STARTUP?MENU 000FH 0003H
+--> ?PR?DISPLAYINIT?DISPLAY
+--> ?PR?CLEAR?DISPLAY
+--> ?PR?DRAWNAME?DISPLAY
+--> ?PR?_DELAY?DELAY
+--> ?PR?DRAWNUMBER?DISPLAY
?PR?DISPLAYINIT?DISPLAY ----- -----
+--> ?PR?WRITE?DISPLAY
?PR?WRITE?DISPLAY ----- -----
+--> ?PR?_DELAY?DELAY
?PR?CLEAR?DISPLAY 0012H 0004H
+--> ?PR?WRITE?DISPLAY
?PR?DRAWNAME?DISPLAY 0012H 0002H
+--> ?PR?WRITE?DISPLAY
+--> ?CO?DISPLAY
?PR?DRAWNUMBER?DISPLAY 0012H 0002H
+--> ?PR?WRITE?DISPLAY
+--> ?CO?DISPLAY
SYMBOL TABLE OF MODULE: .\Objects\MCU_1 (MAIN)
VALUE TYPE NAME
----------------------------------
------- MODULE MAIN
C:0000H SYMBOL _ICE_DUMMY_
D:0090H PUBLIC P1
D:00B0H PUBLIC P3
D:00A8H PUBLIC IE
D:00B8H PUBLIC IP
C:0706H PUBLIC main
BL51 BANKED LINKER/LOCATER V6.22.2.0 05/19/2022 21:06:37 PAGE 3
D:0098H PUBLIC SCON
D:0088H PUBLIC TCON
D:00C8H PUBLIC T2CON
D:00D0H PUBLIC PSW
------- PROC MAIN
C:0706H LINE# 15
C:0706H LINE# 16
C:0706H LINE# 17
C:0709H LINE# 18
C:0733H LINE# 19
C:0733H LINE# 20
C:0733H LINE# 24
------- ENDPROC MAIN
------- ENDMOD MAIN
------- MODULE MENU
C:0000H SYMBOL _ICE_DUMMY_
X:0000H PUBLIC M_MAINMANU
C:078AH PUBLIC menuInit
X:0006H PUBLIC M_STARTUP
C:06C4H PUBLIC _m_startup
X:000CH PUBLIC NOW
------- PROC _M_STARTUP
X:000FH SYMBOL this
C:06C4H LINE# 10
C:06CFH LINE# 11
C:06CFH LINE# 12
C:06D2H LINE# 13
C:06D5H LINE# 14
C:06D8H LINE# 15
C:06DFH LINE# 16
C:06E2H LINE# 17
C:06E9H LINE# 18
C:06ECH LINE# 19
C:0705H LINE# 20
------- ENDPROC _M_STARTUP
------- PROC MENUINIT
C:078AH LINE# 24
C:078AH LINE# 25
C:078AH LINE# 26
C:0798H LINE# 27
------- ENDPROC MENUINIT
------- ENDMOD MENU
------- MODULE DELAY
C:0000H SYMBOL _ICE_DUMMY_
C:0799H PUBLIC delay100us
C:0735H PUBLIC _delay
------- PROC DELAY100US
------- DO
D:0007H SYMBOL i
D:0006H SYMBOL j
------- ENDDO
C:0799H LINE# 3
C:0799H LINE# 4
C:0799H LINE# 7
C:079AH LINE# 8
BL51 BANKED LINKER/LOCATER V6.22.2.0 05/19/2022 21:06:37 PAGE 4
C:079BH LINE# 9
C:079DH LINE# 10
C:079FH LINE# 12
C:079FH LINE# 13
C:07A1H LINE# 14
C:07A3H LINE# 15
------- ENDPROC DELAY100US
------- PROC _DELAY
D:0006H SYMBOL n
------- DO
D:0006H SYMBOL i
D:0004H SYMBOL j
------- ENDDO
C:0735H LINE# 24
C:0735H LINE# 26
C:0735H LINE# 27
C:0740H LINE# 28
C:0754H LINE# 29
------- ENDPROC _DELAY
------- ENDMOD DELAY
------- MODULE DISPLAY
C:0000H SYMBOL _ICE_DUMMY_
D:0090H PUBLIC P1
D:00B0H PUBLIC P3
C:02DEH PUBLIC clear
D:00A8H PUBLIC IE
C:0755H PUBLIC displayInit
D:00B8H PUBLIC IP
B:00B0H.0 PUBLIC RS
B:00B0H.1 PUBLIC RW
C:077AH PUBLIC write
D:0098H PUBLIC SCON
D:0088H PUBLIC TCON
C:03A3H PUBLIC miniclear
C:0468H PUBLIC test
B:00B0H.2 PUBLIC E
C:0163H PUBLIC NUMBER_RPAGE0
C:0183H PUBLIC NUMBER_RPAGE1
C:0003H PUBLIC NAME_PAGE0
C:0033H PUBLIC NAME_PAGE1
C:052DH PUBLIC drawNAME
B:00B0H.4 PUBLIC CSA
B:00B0H.5 PUBLIC CSB
D:00C8H PUBLIC T2CON
C:0063H PUBLIC NUMBER_PAGE0
D:00D0H PUBLIC PSW
C:00E3H PUBLIC NUMBER_PAGE1
C:01A3H PUBLIC drawNUMBER
C:0771H SYMBOL L?0069
------- PROC L?0068
------- ENDPROC L?0068
C:0771H SYMBOL L?0069
------- PROC WRITE
C:077AH LINE# 18
C:077AH LINE# 19
C:077AH LINE# 20
BL51 BANKED LINKER/LOCATER V6.22.2.0 05/19/2022 21:06:37 PAGE 5
C:077CH LINE# 21
C:077EH LINE# 22
C:0780H LINE# 23
C:0787H LINE# 24
C:0789H LINE# 25
------- ENDPROC WRITE
------- PROC DRAWNUMBER
------- DO
X:0012H SYMBOL j
------- ENDDO
C:01A3H LINE# 27
C:01A3H LINE# 28
C:01A3H LINE# 30
C:01AAH LINE# 31
C:01AAH LINE# 34
C:01ACH LINE# 35
C:01AEH LINE# 36
C:01B0H LINE# 37
C:01B2H LINE# 38
C:01B5H LINE# 39
C:01B8H LINE# 40
C:01C1H LINE# 41
C:01C4H LINE# 43
C:01C6H LINE# 44
C:01C8H LINE# 45
C:01E4H LINE# 46
C:01E7H LINE# 48
C:01E9H LINE# 49
C:01EBH LINE# 50
C:01EEH LINE# 51
C:01F1H LINE# 52
C:01FAH LINE# 53
C:01FDH LINE# 55
C:01FFH LINE# 56
C:0201H LINE# 57
C:021DH LINE# 58
C:0220H LINE# 61
C:0240H LINE# 62
C:0247H LINE# 63
C:0247H LINE# 66
C:0249H LINE# 67
C:024BH LINE# 68
C:024DH LINE# 69
C:024FH LINE# 70
C:0252H LINE# 71
C:0255H LINE# 72
C:025EH LINE# 73
C:0261H LINE# 75
C:0263H LINE# 76
C:0265H LINE# 77
C:0281H LINE# 78
C:0284H LINE# 80
C:0286H LINE# 81
C:0288H LINE# 82
C:028BH LINE# 83
C:028EH LINE# 84
C:0297H LINE# 85
BL51 BANKED LINKER/LOCATER V6.22.2.0 05/19/2022 21:06:37 PAGE 6
C:029AH LINE# 87
C:029CH LINE# 88
C:029EH LINE# 89
C:02BAH LINE# 90
C:02BDH LINE# 93
C:02DDH LINE# 94
------- ENDPROC DRAWNUMBER
------- PROC DRAWNAME
------- DO
X:0012H SYMBOL j
------- ENDDO
C:052DH LINE# 96
C:052DH LINE# 97
C:052DH LINE# 100
C:0534H LINE# 101
C:0534H LINE# 104
C:0536H LINE# 105
C:0538H LINE# 106
C:053AH LINE# 107
C:053CH LINE# 108
C:053FH LINE# 109
C:0542H LINE# 110
C:054BH LINE# 111
C:054EH LINE# 113
C:0550H LINE# 114
C:0552H LINE# 115
C:0566H LINE# 116
C:0569H LINE# 118
C:056BH LINE# 119
C:056DH LINE# 120
C:0570H LINE# 121
C:0573H LINE# 122
C:057CH LINE# 123
C:057FH LINE# 125
C:0581H LINE# 126
C:0583H LINE# 127
C:0597H LINE# 128
C:059AH LINE# 131
C:05BAH LINE# 132
------- ENDPROC DRAWNAME
------- PROC CLEAR
------- DO
X:0012H SYMBOL i
X:0014H SYMBOL j
------- ENDDO
C:02DEH LINE# 134
C:02DEH LINE# 135
C:02DEH LINE# 137
C:02E0H LINE# 138
C:02E2H LINE# 139
C:02F9H LINE# 140
C:02F9H LINE# 141
C:02F9H LINE# 142
C:02F9H LINE# 143
C:02F9H LINE# 144
C:02FCH LINE# 145
C:02FFH LINE# 146
BL51 BANKED LINKER/LOCATER V6.22.2.0 05/19/2022 21:06:37 PAGE 7
C:0302H LINE# 148
C:0309H LINE# 149
C:0309H LINE# 150
C:030BH LINE# 151
C:030DH LINE# 152
C:0310H LINE# 153
C:0313H LINE# 154
C:0330H LINE# 155
C:0340H LINE# 156
C:0342H LINE# 157
C:0344H LINE# 158
C:035BH LINE# 159
C:035BH LINE# 160
C:035BH LINE# 161
C:035BH LINE# 162
C:035BH LINE# 163
C:035EH LINE# 164
C:0361H LINE# 165
C:0364H LINE# 167
C:036BH LINE# 168
C:036BH LINE# 169
C:036DH LINE# 170
C:036FH LINE# 171
C:0372H LINE# 172
C:0375H LINE# 173
C:0392H LINE# 174
C:03A2H LINE# 175
------- ENDPROC CLEAR
------- PROC MINICLEAR
------- DO
X:0016H SYMBOL i
X:0018H SYMBOL j
------- ENDDO
C:03A3H LINE# 178
C:03A3H LINE# 179
C:03A3H LINE# 181
C:03A5H LINE# 182
C:03A7H LINE# 183
C:03BEH LINE# 184
C:03BEH LINE# 185
C:03BEH LINE# 186
C:03BEH LINE# 187
C:03BEH LINE# 188
C:03C1H LINE# 189
C:03C4H LINE# 190
C:03C7H LINE# 192
C:03CEH LINE# 193
C:03CEH LINE# 194
C:03D0H LINE# 195
C:03D2H LINE# 196
C:03D5H LINE# 197
C:03D8H LINE# 198
C:03F5H LINE# 199
C:0405H LINE# 200
C:0407H LINE# 201
C:0409H LINE# 202
C:0420H LINE# 203
BL51 BANKED LINKER/LOCATER V6.22.2.0 05/19/2022 21:06:37 PAGE 8
C:0420H LINE# 204
C:0420H LINE# 205
C:0420H LINE# 206
C:0420H LINE# 207
C:0423H LINE# 208
C:0426H LINE# 209
C:0429H LINE# 211
C:0430H LINE# 212
C:0430H LINE# 213
C:0432H LINE# 214
C:0434H LINE# 215
C:0437H LINE# 216
C:043AH LINE# 217
C:0457H LINE# 218
C:0467H LINE# 219
------- ENDPROC MINICLEAR
------- PROC DISPLAYINIT
C:0755H LINE# 220
C:0755H LINE# 221
C:0755H LINE# 222
C:0757H LINE# 223
C:0759H LINE# 224
C:075BH LINE# 225
C:075DH LINE# 226
C:075FH LINE# 227
C:0762H LINE# 228
C:0765H LINE# 230
C:0767H LINE# 231
C:0769H LINE# 232
C:076BH LINE# 233
C:076EH LINE# 234
------- ENDPROC DISPLAYINIT
------- PROC TEST
------- DO
X:001AH SYMBOL i
X:001CH SYMBOL j
------- ENDDO
C:0468H LINE# 237
C:0468H LINE# 238
C:0468H LINE# 240
C:046AH LINE# 241
C:046CH LINE# 242
C:0483H LINE# 243
C:0483H LINE# 244
C:0483H LINE# 245
C:0483H LINE# 246
C:0483H LINE# 247
C:0486H LINE# 248
C:0489H LINE# 249
C:048CH LINE# 251
C:0493H LINE# 252
C:0493H LINE# 253
C:0495H LINE# 254
C:0497H LINE# 255
C:049AH LINE# 256
C:049DH LINE# 257
C:04BAH LINE# 258
BL51 BANKED LINKER/LOCATER V6.22.2.0 05/19/2022 21:06:37 PAGE 9
C:04CAH LINE# 259
C:04CCH LINE# 260
C:04CEH LINE# 261
C:04E5H LINE# 262
C:04E5H LINE# 263
C:04E5H LINE# 264
C:04E5H LINE# 265
C:04E5H LINE# 266
C:04E8H LINE# 267
C:04EBH LINE# 268
C:04EEH LINE# 270
C:04F5H LINE# 271
C:04F5H LINE# 272
C:04F7H LINE# 273
C:04F9H LINE# 274
C:04FCH LINE# 275
C:04FFH LINE# 276
C:051CH LINE# 277
C:052CH LINE# 278
------- ENDPROC TEST
------- ENDMOD DISPLAY
------- MODULE ?C?PLDPTR
C:0647H PUBLIC ?C?PLDPTR
------- ENDMOD ?C?PLDPTR
------- MODULE ?C?PLDOPTR
C:0667H PUBLIC ?C?PLDOPTR
------- ENDMOD ?C?PLDOPTR
------- MODULE ?C?ICALL
C:0697H PUBLIC ?C?ICALL
C:069BH PUBLIC ?C?ICALL2
------- ENDMOD ?C?ICALL
------- MODULE ?C?PLDIDATA
C:069DH PUBLIC ?C?PLDIDATA
------- ENDMOD ?C?PLDIDATA
------- MODULE ?C?PLDXDATA
C:06A6H PUBLIC ?C?PLDXDATA
------- ENDMOD ?C?PLDXDATA
------- MODULE ?C?PLDPDATA
C:06AFH PUBLIC ?C?PLDPDATA
------- ENDMOD ?C?PLDPDATA
------- MODULE ?C?PLDCODE
C:06B8H PUBLIC ?C?PLDCODE
------- ENDMOD ?C?PLDCODE
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?DELAY100US?DELAY
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?MINICLEAR?DISPLAY
BL51 BANKED LINKER/LOCATER V6.22.2.0 05/19/2022 21:06:37 PAGE 10
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?TEST?DISPLAY
Program Size: data=9.0 xdata=30 code=1966
LINK/LOCATE RUN COMPLETE. 3 WARNING(S), 0 ERROR(S)

View file

@ -0,0 +1,318 @@
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<ProjectOpt xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="project_opt.xsd">
<SchemaVersion>1.0</SchemaVersion>
<Header>### uVision Project, (C) Keil Software</Header>
<Extensions>
<cExt>*.c</cExt>
<aExt>*.s*; *.src; *.a*</aExt>
<oExt>*.obj; *.o</oExt>
<lExt>*.lib</lExt>
<tExt>*.txt; *.h; *.inc; *.md</tExt>
<pExt>*.plm</pExt>
<CppX>*.cpp</CppX>
<nMigrate>0</nMigrate>
</Extensions>
<DaveTm>
<dwLowDateTime>0</dwLowDateTime>
<dwHighDateTime>0</dwHighDateTime>
</DaveTm>
<Target>
<TargetName>MCU_1</TargetName>
<ToolsetNumber>0x0</ToolsetNumber>
<ToolsetName>MCS-51</ToolsetName>
<TargetOption>
<CLK51>24000000</CLK51>
<OPTTT>
<gFlags>1</gFlags>
<BeepAtEnd>1</BeepAtEnd>
<RunSim>1</RunSim>
<RunTarget>0</RunTarget>
<RunAbUc>0</RunAbUc>
</OPTTT>
<OPTHX>
<HexSelection>0</HexSelection>
<FlashByte>65535</FlashByte>
<HexRangeLowAddress>0</HexRangeLowAddress>
<HexRangeHighAddress>0</HexRangeHighAddress>
<HexOffset>0</HexOffset>
</OPTHX>
<OPTLEX>
<PageWidth>120</PageWidth>
<PageLength>65</PageLength>
<TabStop>8</TabStop>
<ListingPath>.\Listings\</ListingPath>
</OPTLEX>
<ListingPage>
<CreateCListing>1</CreateCListing>
<CreateAListing>1</CreateAListing>
<CreateLListing>1</CreateLListing>
<CreateIListing>0</CreateIListing>
<AsmCond>1</AsmCond>
<AsmSymb>1</AsmSymb>
<AsmXref>0</AsmXref>
<CCond>1</CCond>
<CCode>0</CCode>
<CListInc>0</CListInc>
<CSymb>0</CSymb>
<LinkerCodeListing>0</LinkerCodeListing>
</ListingPage>
<OPTXL>
<LMap>1</LMap>
<LComments>1</LComments>
<LGenerateSymbols>1</LGenerateSymbols>
<LLibSym>1</LLibSym>
<LLines>1</LLines>
<LLocSym>1</LLocSym>
<LPubSym>1</LPubSym>
<LXref>0</LXref>
<LExpSel>0</LExpSel>
</OPTXL>
<OPTFL>
<tvExp>1</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<IsCurrentTarget>1</IsCurrentTarget>
</OPTFL>
<CpuCode>255</CpuCode>
<Books>
<Book>
<Number>0</Number>
<Title>Data Sheet</Title>
<Path>DATASHTS\ATMEL\AT89C51_DS.PDF</Path>
</Book>
<Book>
<Number>1</Number>
<Title>Instruction Set Manual</Title>
<Path>DATASHTS\ATMEL\AT_C51ISM.PDF</Path>
</Book>
</Books>
<DebugOpt>
<uSim>0</uSim>
<uTrg>1</uTrg>
<sLdApp>1</sLdApp>
<sGomain>1</sGomain>
<sRbreak>1</sRbreak>
<sRwatch>1</sRwatch>
<sRmem>1</sRmem>
<sRfunc>1</sRfunc>
<sRbox>1</sRbox>
<tLdApp>1</tLdApp>
<tGomain>1</tGomain>
<tRbreak>1</tRbreak>
<tRwatch>1</tRwatch>
<tRmem>1</tRmem>
<tRfunc>0</tRfunc>
<tRbox>1</tRbox>
<tRtrace>1</tRtrace>
<sRSysVw>1</sRSysVw>
<tRSysVw>1</tRSysVw>
<sRunDeb>0</sRunDeb>
<sLrtime>0</sLrtime>
<bEvRecOn>1</bEvRecOn>
<bSchkAxf>0</bSchkAxf>
<bTchkAxf>0</bTchkAxf>
<nTsel>0</nTsel>
<sDll></sDll>
<sDllPa></sDllPa>
<sDlgDll></sDlgDll>
<sDlgPa></sDlgPa>
<sIfile></sIfile>
<tDll></tDll>
<tDllPa></tDllPa>
<tDlgDll></tDlgDll>
<tDlgPa></tDlgPa>
<tIfile></tIfile>
<pMon>BIN\MON51.DLL</pMon>
</DebugOpt>
<TargetDriverDllRegistry>
<SetRegEntry>
<Number>0</Number>
<Key>DLGTP51</Key>
<Name>(98=-1,-1,-1,-1,0)(82=-1,-1,-1,-1,0)(83=-1,-1,-1,-1,0)(84=-1,-1,-1,-1,0)(85=-1,-1,-1,-1,0)(80=-1,-1,-1,-1,0)(91=-1,-1,-1,-1,0)(92=-1,-1,-1,-1,0)</Name>
</SetRegEntry>
<SetRegEntry>
<Number>0</Number>
<Key>MON51</Key>
<Name>-S2 -B115200 -O15</Name>
</SetRegEntry>
</TargetDriverDllRegistry>
<Breakpoint/>
<WatchWindow1>
<Ww>
<count>0</count>
<WinNumber>1</WinNumber>
<ItemText>Z[j]</ItemText>
</Ww>
<Ww>
<count>1</count>
<WinNumber>1</WinNumber>
<ItemText>line</ItemText>
</Ww>
<Ww>
<count>2</count>
<WinNumber>1</WinNumber>
<ItemText>l</ItemText>
</Ww>
</WatchWindow1>
<Tracepoint>
<THDelay>0</THDelay>
</Tracepoint>
<DebugFlag>
<trace>0</trace>
<periodic>1</periodic>
<aLwin>0</aLwin>
<aCover>0</aCover>
<aSer1>0</aSer1>
<aSer2>0</aSer2>
<aPa>0</aPa>
<viewmode>1</viewmode>
<vrSel>0</vrSel>
<aSym>0</aSym>
<aTbox>0</aTbox>
<AscS1>0</AscS1>
<AscS2>0</AscS2>
<AscS3>0</AscS3>
<aSer3>0</aSer3>
<eProf>0</eProf>
<aLa>0</aLa>
<aPa1>0</aPa1>
<AscS4>0</AscS4>
<aSer4>0</aSer4>
<StkLoc>0</StkLoc>
<TrcWin>0</TrcWin>
<newCpu>0</newCpu>
<uProt>0</uProt>
</DebugFlag>
<LintExecutable></LintExecutable>
<LintConfigFile></LintConfigFile>
<bLintAuto>0</bLintAuto>
<bAutoGenD>0</bAutoGenD>
<LntExFlags>0</LntExFlags>
<pMisraName></pMisraName>
<pszMrule></pszMrule>
<pSingCmds></pSingCmds>
<pMultCmds></pMultCmds>
<pMisraNamep></pMisraNamep>
<pszMrulep></pszMrulep>
<pSingCmdsp></pSingCmdsp>
<pMultCmdsp></pMultCmdsp>
</TargetOption>
</Target>
<Group>
<GroupName>SRC</GroupName>
<tvExp>1</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<cbSel>0</cbSel>
<RteFlg>0</RteFlg>
<File>
<GroupNumber>1</GroupNumber>
<FileNumber>1</FileNumber>
<FileType>1</FileType>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<bDave2>0</bDave2>
<PathWithFileName>.\main.c</PathWithFileName>
<FilenameWithoutPath>main.c</FilenameWithoutPath>
<RteFlg>0</RteFlg>
<bShared>0</bShared>
</File>
<File>
<GroupNumber>1</GroupNumber>
<FileNumber>2</FileNumber>
<FileType>1</FileType>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<bDave2>0</bDave2>
<PathWithFileName>.\menu.c</PathWithFileName>
<FilenameWithoutPath>menu.c</FilenameWithoutPath>
<RteFlg>0</RteFlg>
<bShared>0</bShared>
</File>
<File>
<GroupNumber>1</GroupNumber>
<FileNumber>3</FileNumber>
<FileType>1</FileType>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<bDave2>0</bDave2>
<PathWithFileName>.\delay.c</PathWithFileName>
<FilenameWithoutPath>delay.c</FilenameWithoutPath>
<RteFlg>0</RteFlg>
<bShared>0</bShared>
</File>
<File>
<GroupNumber>1</GroupNumber>
<FileNumber>4</FileNumber>
<FileType>1</FileType>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<bDave2>0</bDave2>
<PathWithFileName>.\display.c</PathWithFileName>
<FilenameWithoutPath>display.c</FilenameWithoutPath>
<RteFlg>0</RteFlg>
<bShared>0</bShared>
</File>
</Group>
<Group>
<GroupName>INC</GroupName>
<tvExp>1</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<cbSel>0</cbSel>
<RteFlg>0</RteFlg>
<File>
<GroupNumber>2</GroupNumber>
<FileNumber>5</FileNumber>
<FileType>5</FileType>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<bDave2>0</bDave2>
<PathWithFileName>.\main.h</PathWithFileName>
<FilenameWithoutPath>main.h</FilenameWithoutPath>
<RteFlg>0</RteFlg>
<bShared>0</bShared>
</File>
<File>
<GroupNumber>2</GroupNumber>
<FileNumber>6</FileNumber>
<FileType>5</FileType>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<bDave2>0</bDave2>
<PathWithFileName>.\display.h</PathWithFileName>
<FilenameWithoutPath>display.h</FilenameWithoutPath>
<RteFlg>0</RteFlg>
<bShared>0</bShared>
</File>
<File>
<GroupNumber>2</GroupNumber>
<FileNumber>7</FileNumber>
<FileType>5</FileType>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<bDave2>0</bDave2>
<PathWithFileName>.\img.h</PathWithFileName>
<FilenameWithoutPath>img.h</FilenameWithoutPath>
<RteFlg>0</RteFlg>
<bShared>0</bShared>
</File>
<File>
<GroupNumber>2</GroupNumber>
<FileNumber>8</FileNumber>
<FileType>5</FileType>
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<bDave2>0</bDave2>
<PathWithFileName>.\menu.h</PathWithFileName>
<FilenameWithoutPath>menu.h</FilenameWithoutPath>
<RteFlg>0</RteFlg>
<bShared>0</bShared>
</File>
</Group>
</ProjectOpt>

View file

@ -0,0 +1,430 @@
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<Project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="project_proj.xsd">
<SchemaVersion>1.1</SchemaVersion>
<Header>### uVision Project, (C) Keil Software</Header>
<Targets>
<Target>
<TargetName>MCU_1</TargetName>
<ToolsetNumber>0x0</ToolsetNumber>
<ToolsetName>MCS-51</ToolsetName>
<uAC6>0</uAC6>
<TargetOption>
<TargetCommonOption>
<Device>AT89C51</Device>
<Vendor>Microchip</Vendor>
<Cpu>IRAM(0-0x7F) IROM(0-0xFFF) CLOCK(24000000)</Cpu>
<FlashUtilSpec></FlashUtilSpec>
<StartupFile>"LIB\STARTUP.A51" ("Standard 8051 Startup Code")</StartupFile>
<FlashDriverDll></FlashDriverDll>
<DeviceId>2976</DeviceId>
<RegisterFile>REGX51.H</RegisterFile>
<MemoryEnv></MemoryEnv>
<Cmp></Cmp>
<Asm></Asm>
<Linker></Linker>
<OHString></OHString>
<InfinionOptionDll></InfinionOptionDll>
<SLE66CMisc></SLE66CMisc>
<SLE66AMisc></SLE66AMisc>
<SLE66LinkerMisc></SLE66LinkerMisc>
<SFDFile></SFDFile>
<bCustSvd>0</bCustSvd>
<UseEnv>0</UseEnv>
<BinPath></BinPath>
<IncludePath></IncludePath>
<LibPath></LibPath>
<RegisterFilePath>Atmel\</RegisterFilePath>
<DBRegisterFilePath>Atmel\</DBRegisterFilePath>
<TargetStatus>
<Error>0</Error>
<ExitCodeStop>0</ExitCodeStop>
<ButtonStop>0</ButtonStop>
<NotGenerated>0</NotGenerated>
<InvalidFlash>1</InvalidFlash>
</TargetStatus>
<OutputDirectory>.\Objects\</OutputDirectory>
<OutputName>MCU_1</OutputName>
<CreateExecutable>1</CreateExecutable>
<CreateLib>0</CreateLib>
<CreateHexFile>1</CreateHexFile>
<DebugInformation>1</DebugInformation>
<BrowseInformation>1</BrowseInformation>
<ListingPath>.\Listings\</ListingPath>
<HexFormatSelection>0</HexFormatSelection>
<Merge32K>0</Merge32K>
<CreateBatchFile>0</CreateBatchFile>
<BeforeCompile>
<RunUserProg1>0</RunUserProg1>
<RunUserProg2>0</RunUserProg2>
<UserProg1Name></UserProg1Name>
<UserProg2Name></UserProg2Name>
<UserProg1Dos16Mode>0</UserProg1Dos16Mode>
<UserProg2Dos16Mode>0</UserProg2Dos16Mode>
<nStopU1X>0</nStopU1X>
<nStopU2X>0</nStopU2X>
</BeforeCompile>
<BeforeMake>
<RunUserProg1>0</RunUserProg1>
<RunUserProg2>0</RunUserProg2>
<UserProg1Name></UserProg1Name>
<UserProg2Name></UserProg2Name>
<UserProg1Dos16Mode>0</UserProg1Dos16Mode>
<UserProg2Dos16Mode>0</UserProg2Dos16Mode>
<nStopB1X>0</nStopB1X>
<nStopB2X>0</nStopB2X>
</BeforeMake>
<AfterMake>
<RunUserProg1>0</RunUserProg1>
<RunUserProg2>0</RunUserProg2>
<UserProg1Name></UserProg1Name>
<UserProg2Name></UserProg2Name>
<UserProg1Dos16Mode>0</UserProg1Dos16Mode>
<UserProg2Dos16Mode>0</UserProg2Dos16Mode>
<nStopA1X>0</nStopA1X>
<nStopA2X>0</nStopA2X>
</AfterMake>
<SelectedForBatchBuild>0</SelectedForBatchBuild>
<SVCSIdString></SVCSIdString>
</TargetCommonOption>
<CommonProperty>
<UseCPPCompiler>0</UseCPPCompiler>
<RVCTCodeConst>0</RVCTCodeConst>
<RVCTZI>0</RVCTZI>
<RVCTOtherData>0</RVCTOtherData>
<ModuleSelection>0</ModuleSelection>
<IncludeInBuild>1</IncludeInBuild>
<AlwaysBuild>0</AlwaysBuild>
<GenerateAssemblyFile>0</GenerateAssemblyFile>
<AssembleAssemblyFile>0</AssembleAssemblyFile>
<PublicsOnly>0</PublicsOnly>
<StopOnExitCode>3</StopOnExitCode>
<CustomArgument></CustomArgument>
<IncludeLibraryModules></IncludeLibraryModules>
<ComprImg>1</ComprImg>
<BankNo>65535</BankNo>
</CommonProperty>
<DllOption>
<SimDllName>S8051.DLL</SimDllName>
<SimDllArguments></SimDllArguments>
<SimDlgDll>DP51.DLL</SimDlgDll>
<SimDlgDllArguments>-p51</SimDlgDllArguments>
<TargetDllName>S8051.DLL</TargetDllName>
<TargetDllArguments></TargetDllArguments>
<TargetDlgDll>TP51.DLL</TargetDlgDll>
<TargetDlgDllArguments>-p51</TargetDlgDllArguments>
</DllOption>
<DebugOption>
<OPTHX>
<HexSelection>0</HexSelection>
<HexRangeLowAddress>0</HexRangeLowAddress>
<HexRangeHighAddress>0</HexRangeHighAddress>
<HexOffset>0</HexOffset>
<Oh166RecLen>16</Oh166RecLen>
</OPTHX>
<Simulator>
<UseSimulator>0</UseSimulator>
<LoadApplicationAtStartup>1</LoadApplicationAtStartup>
<RunToMain>1</RunToMain>
<RestoreBreakpoints>1</RestoreBreakpoints>
<RestoreWatchpoints>1</RestoreWatchpoints>
<RestoreMemoryDisplay>1</RestoreMemoryDisplay>
<RestoreFunctions>1</RestoreFunctions>
<RestoreToolbox>1</RestoreToolbox>
<LimitSpeedToRealTime>0</LimitSpeedToRealTime>
<RestoreSysVw>1</RestoreSysVw>
</Simulator>
<Target>
<UseTarget>1</UseTarget>
<LoadApplicationAtStartup>1</LoadApplicationAtStartup>
<RunToMain>1</RunToMain>
<RestoreBreakpoints>1</RestoreBreakpoints>
<RestoreWatchpoints>1</RestoreWatchpoints>
<RestoreMemoryDisplay>1</RestoreMemoryDisplay>
<RestoreFunctions>0</RestoreFunctions>
<RestoreToolbox>1</RestoreToolbox>
<RestoreTracepoints>1</RestoreTracepoints>
<RestoreSysVw>1</RestoreSysVw>
</Target>
<RunDebugAfterBuild>0</RunDebugAfterBuild>
<TargetSelection>0</TargetSelection>
<SimDlls>
<CpuDll></CpuDll>
<CpuDllArguments></CpuDllArguments>
<PeripheralDll></PeripheralDll>
<PeripheralDllArguments></PeripheralDllArguments>
<InitializationFile></InitializationFile>
</SimDlls>
<TargetDlls>
<CpuDll></CpuDll>
<CpuDllArguments></CpuDllArguments>
<PeripheralDll></PeripheralDll>
<PeripheralDllArguments></PeripheralDllArguments>
<InitializationFile></InitializationFile>
<Driver>BIN\MON51.DLL</Driver>
</TargetDlls>
</DebugOption>
<Utilities>
<Flash1>
<UseTargetDll>0</UseTargetDll>
<UseExternalTool>0</UseExternalTool>
<RunIndependent>0</RunIndependent>
<UpdateFlashBeforeDebugging>0</UpdateFlashBeforeDebugging>
<Capability>0</Capability>
<DriverSelection>-1</DriverSelection>
</Flash1>
<bUseTDR>0</bUseTDR>
<Flash2></Flash2>
<Flash3>"" ()</Flash3>
<Flash4></Flash4>
<pFcarmOut></pFcarmOut>
<pFcarmGrp></pFcarmGrp>
<pFcArmRoot></pFcArmRoot>
<FcArmLst>0</FcArmLst>
</Utilities>
<Target51>
<Target51Misc>
<MemoryModel>2</MemoryModel>
<RTOS>0</RTOS>
<RomSize>2</RomSize>
<DataHold>0</DataHold>
<XDataHold>0</XDataHold>
<UseOnchipRom>0</UseOnchipRom>
<UseOnchipArithmetic>0</UseOnchipArithmetic>
<UseMultipleDPTR>0</UseMultipleDPTR>
<UseOnchipXram>0</UseOnchipXram>
<HadIRAM>1</HadIRAM>
<HadXRAM>0</HadXRAM>
<HadIROM>1</HadIROM>
<Moda2>0</Moda2>
<Moddp2>0</Moddp2>
<Modp2>0</Modp2>
<Mod517dp>0</Mod517dp>
<Mod517au>0</Mod517au>
<Mode2>0</Mode2>
<useCB>0</useCB>
<useXB>0</useXB>
<useL251>0</useL251>
<useA251>0</useA251>
<Mx51>0</Mx51>
<ModC812>0</ModC812>
<ModCont>0</ModCont>
<Lp51>0</Lp51>
<useXBS>0</useXBS>
<ModDA>0</ModDA>
<ModAB2>0</ModAB2>
<Mx51P>0</Mx51P>
<hadXRAM2>0</hadXRAM2>
<uocXram2>0</uocXram2>
<hadXRAM3>0</hadXRAM3>
<ModC2>0</ModC2>
<ModH2>0</ModH2>
<Mdu_R515>0</Mdu_R515>
<Mdu_F120>0</Mdu_F120>
<Psoc>0</Psoc>
<hadIROM2>0</hadIROM2>
<hadIROM3>0</hadIROM3>
<ModSmx2>0</ModSmx2>
<cBanks>0</cBanks>
<xBanks>0</xBanks>
<OnChipMemories>
<RCB>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0xffff</Size>
</RCB>
<RXB>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</RXB>
<Ocm1>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</Ocm1>
<Ocm2>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</Ocm2>
<Ocm3>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</Ocm3>
<Ocr1>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</Ocr1>
<Ocr2>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</Ocr2>
<Ocr3>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</Ocr3>
<IRO>
<Type>1</Type>
<StartAddress>0x0</StartAddress>
<Size>0x1000</Size>
</IRO>
<IRA>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x80</Size>
</IRA>
<XRA>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</XRA>
<XRA512>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</XRA512>
<IROM512>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</IROM512>
<XRA513>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</XRA513>
<IROM513>
<Type>0</Type>
<StartAddress>0x0</StartAddress>
<Size>0x0</Size>
</IROM513>
</OnChipMemories>
</Target51Misc>
<C51>
<RegisterColoring>0</RegisterColoring>
<VariablesInOrder>0</VariablesInOrder>
<IntegerPromotion>1</IntegerPromotion>
<uAregs>0</uAregs>
<UseInterruptVector>1</UseInterruptVector>
<Fuzzy>3</Fuzzy>
<Optimize>8</Optimize>
<WarningLevel>2</WarningLevel>
<SizeSpeed>1</SizeSpeed>
<ObjectExtend>1</ObjectExtend>
<ACallAJmp>0</ACallAJmp>
<InterruptVectorAddress>0</InterruptVectorAddress>
<VariousControls>
<MiscControls></MiscControls>
<Define></Define>
<Undefine></Undefine>
<IncludePath>..\MCU</IncludePath>
</VariousControls>
</C51>
<Ax51>
<UseMpl>0</UseMpl>
<UseStandard>1</UseStandard>
<UseCase>0</UseCase>
<UseMod51>0</UseMod51>
<VariousControls>
<MiscControls></MiscControls>
<Define></Define>
<Undefine></Undefine>
<IncludePath></IncludePath>
</VariousControls>
</Ax51>
<Lx51>
<useFile>0</useFile>
<linkonly>0</linkonly>
<UseMemoryFromTarget>1</UseMemoryFromTarget>
<CaseSensitiveSymbols>0</CaseSensitiveSymbols>
<WarningLevel>2</WarningLevel>
<DataOverlaying>1</DataOverlaying>
<OverlayString></OverlayString>
<MiscControls></MiscControls>
<DisableWarningNumbers></DisableWarningNumbers>
<LinkerCmdFile></LinkerCmdFile>
<Assign></Assign>
<ReserveString></ReserveString>
<CClasses></CClasses>
<UserClasses></UserClasses>
<CSection></CSection>
<UserSection></UserSection>
<CodeBaseAddress></CodeBaseAddress>
<XDataBaseAddress></XDataBaseAddress>
<PDataBaseAddress></PDataBaseAddress>
<BitBaseAddress></BitBaseAddress>
<DataBaseAddress></DataBaseAddress>
<IDataBaseAddress></IDataBaseAddress>
<Precede></Precede>
<Stack></Stack>
<CodeSegmentName></CodeSegmentName>
<XDataSegmentName></XDataSegmentName>
<BitSegmentName></BitSegmentName>
<DataSegmentName></DataSegmentName>
<IDataSegmentName></IDataSegmentName>
</Lx51>
</Target51>
</TargetOption>
<Groups>
<Group>
<GroupName>SRC</GroupName>
<Files>
<File>
<FileName>main.c</FileName>
<FileType>1</FileType>
<FilePath>.\main.c</FilePath>
</File>
<File>
<FileName>menu.c</FileName>
<FileType>1</FileType>
<FilePath>.\menu.c</FilePath>
</File>
<File>
<FileName>delay.c</FileName>
<FileType>1</FileType>
<FilePath>.\delay.c</FilePath>
</File>
<File>
<FileName>display.c</FileName>
<FileType>1</FileType>
<FilePath>.\display.c</FilePath>
</File>
</Files>
</Group>
<Group>
<GroupName>INC</GroupName>
<Files>
<File>
<FileName>main.h</FileName>
<FileType>5</FileType>
<FilePath>.\main.h</FilePath>
</File>
<File>
<FileName>display.h</FileName>
<FileType>5</FileType>
<FilePath>.\display.h</FilePath>
</File>
<File>
<FileName>img.h</FileName>
<FileType>5</FileType>
<FilePath>.\img.h</FilePath>
</File>
<File>
<FileName>menu.h</FileName>
<FileType>5</FileType>
<FilePath>.\menu.h</FilePath>
</File>
</Files>
</Group>
</Groups>
</Target>
</Targets>
</Project>

View file

@ -0,0 +1,29 @@
#include "delay.h"
#include <intrins.h>
void delay100us()
{
unsigned char i, j;
_nop_();
_nop_();
i = 2;
j = 15;
do
{
while (--j);
} while (--i);
}
//void delay(int i)
//{
// int j = i;
// for(;j>0;j--)
// delay100us();
//}
void delay(int n)
{int i, j;
for(i=n;i>0;i--)
for(j = 28; j > 0; j--);
}

View file

@ -0,0 +1,7 @@
#ifndef _DELAY_H_
#define _DELAY_H_
void delay(int i);
void delay100us();
#endif

View file

@ -0,0 +1,278 @@
#include <reg52.h>
#include "display.h"
#include "delay.h"
#include "img.h"
// DB P1
// CTL P3
sbit RS = P3 ^ 0;
sbit RW = P3 ^ 1;
sbit E = P3 ^ 2;
sbit CSA = P3 ^ 4;
sbit CSB = P3 ^ 5;
void write()
{
RW = 0;
E = 0;
E = 1;
delay(2);
E = 0;
}
void drawNUMBER()
{
unsigned int j;
for(j =0 ; j < 64; j++)
{
CSA = 1;
CSB = 0;
RS = 0;
RW = 0;
P1 = 0xb8 + 2;
write();
P1 = 0X40 + j;
write(); //Ò³2ÁÐjÆÁA
RS = 1;
RW = 0;
P1 = NUMBER_PAGE0[j - 1];
write();
RS = 0;
RW = 0;
P1 = 0xb8 + 3;
write();
P1 = 0X40 + j;
write(); //Ò³3ÁÐjÆÁA
RS = 1;
RW = 0;
P1 = NUMBER_PAGE1[j - 1];
write();
}
for(j =0 ; j < 16; j++)
{
CSA = 0;
CSB = 1;
RS = 0;
RW = 0;
P1 = 0xb8 + 2;
write();
P1 = 0X40 + j;
write(); //Ò³2ÁÐjÆÁA
RS = 1;
RW = 0;
P1 = NUMBER_RPAGE0[j - 1];
write();
RS = 0;
RW = 0;
P1 = 0xb8 + 3;
write();
P1 = 0X40 + j;
write(); //Ò³3ÁÐjÆÁA
RS = 1;
RW = 0;
P1 = NUMBER_RPAGE1[j - 1];
write();
}
}
void drawNAME()
{
unsigned int j;
for(j = 0; j < 48; j++)
{
CSA = 1;
CSB = 0;
RS = 0;
RW = 0;
P1 = 0xb8 + 0;
write();
P1 = 0X40 + j;
write(); //Ò³0ÁÐjÆÁA
RS = 1;
RW = 0;
P1 = NAME_PAGE0[j - 1];
write();
RS = 0;
RW = 0;
P1 = 0xb8 + 1;
write();
P1 = 0X40 + j;
write(); //Ò³1ÁÐjÆÁA
RS = 1;
RW = 0;
P1 = NAME_PAGE1[j - 1];
write();
}
}
void clear()
{
unsigned int i, j;
CSA = 1;
CSB = 0;
for(i = 0; i < 8; i++)
{
RS = 0;
RW = 0;
P1 = 0xb8 + i;
write();
P1 = 0X40;
write();
for(j = 0; j < 64; j++)
{
RS = 1;
RW = 0;
P1 = 0x00;;
write();
}
}
CSA = 0;
CSB = 1;
for(i = 0; i < 8; i++)
{
RS = 0;
RW = 0;
P1 = 0xb8 + i;
write();
P1 = 0X40;
write();
for(j = 0; j < 64; j++)
{
RS = 1;
RW = 0;
P1 = 0x00;
write();
}
}
}
void miniclear()
{
unsigned int i, j;
CSA = 1;
CSB = 0;
for(i = 0; i < 2; i++)
{
RS = 0;
RW = 0;
P1 = 0xb8 + i;
write();
P1 = 0X40;
write();
for(j = 0; j < 64; j++)
{
RS = 1;
RW = 0;
P1 = 0x00;;
write();
}
}
CSA = 0;
CSB = 1;
for(i = 0; i < 2; i++)
{
RS = 0;
RW = 0;
P1 = 0xb8 + i;
write();
P1 = 0X40;
write();
for(j = 0; j < 64; j++)
{
RS = 1;
RW = 0;
P1 = 0x00;
write();
}
}
}
void displayInit()
{
E = 0;
RS = 1;
CSA = 1;
CSB = 0;
RS = 0;
P1 = 0X3F;
write();
CSA = 0;
CSB = 1;
RS = 0;
P1 = 0X3F;
write();
}
void test()
{
unsigned int i, j;
CSA = 1;
CSB = 0;
for(i = 0; i < 8; i++)
{
RS = 0;
RW = 0;
P1 = 0xb8 + i;
write();
P1 = 0X40;
write();
for(j = 0; j < 64; j++)
{
RS = 1;
RW = 0;
P1 = 0x55;
write();
}
}
CSA = 0;
CSB = 1;
for(i = 0; i < 8; i++)
{
RS = 0;
RW = 0;
P1 = 0xb8 + i;
write();
P1 = 0X40;
write();
for(j = 0; j < 64; j++)
{
RS = 1;
RW = 0;
P1 = 0x55;;
write();
}
}
}

View file

@ -0,0 +1,18 @@
#ifndef _DISPLAY_H_
#define _DISPLAY_H_
void setData(unsigned char d);
void setCommand(unsigned char d);
void lcdInit();
void setPage(unsigned char p);
void setPage(unsigned char p);
void setLine(unsigned char p);
void setY(unsigned char p);
void test();
void displayInit();
void clear();
void miniclear();
void drawNAME();
void drawNUMBER();
void write();
#endif

91
MCU/MCU_REAL _FINAL/img.h Normal file
View file

@ -0,0 +1,91 @@
code unsigned char NAME_PAGE0[] =
{
0x10, 0x60, 0x02, 0x0C, 0xC0, 0x04, 0x04, 0x04, 0x04, 0xFC, 0x04, 0x04, 0x04, 0x04, 0x00, 0x00,
0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00,
0x20, 0x24, 0x24, 0xA4, 0xFE, 0x23, 0x22, 0x20, 0x00, 0xF8, 0x08, 0x08, 0x08, 0xF8, 0x00, 0x00,
};
code unsigned char NAME_PAGE1[] =
{
0x04, 0x04, 0x7C, 0x03, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3F, 0x20, 0x20, 0x20, 0x20, 0x20, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x10, 0x08, 0x06, 0x01, 0xFF, 0x01, 0x06, 0x00, 0x00, 0x3F, 0x10, 0x10, 0x10, 0x3F, 0x00, 0x00
};
code unsigned NUMBER_PAGE0[]={
/*-- 文字: 2 --*/
0x00,0x70,0x08,0x08,0x08,0x08,0xF0,0x00,
/*-- 文字: 0 --*/
0x00,0xE0,0x10,0x08,0x08,0x10,0xE0,0x00,
/*-- 文字: 2 --*/
0x00,0x70,0x08,0x08,0x08,0x08,0xF0,0x00,
/*-- 文字: 0 --*/
0x00,0xE0,0x10,0x08,0x08,0x10,0xE0,0x00,
/*-- 文字: 1 --*/
0x00,0x00,0x10,0x10,0xF8,0x00,0x00,0x00,
/*-- 文字: 1 --*/
0x00,0x00,0x10,0x10,0xF8,0x00,0x00,0x00,
/*-- 文字: 4 --*/
0x00,0x00,0x80,0x40,0x30,0xF8,0x00,0x00,
/*-- 文字: 4 --*/
0x00,0x00,0x80,0x40,0x30,0xF8,0x00,0x00,
};
code unsigned NUMBER_PAGE1[]={
0x00,0x30,0x28,0x24,0x22,0x21,0x30,0x00,
0x00,0x0F,0x10,0x20,0x20,0x10,0x0F,0x00,
0x00,0x30,0x28,0x24,0x22,0x21,0x30,0x00,
0x00,0x0F,0x10,0x20,0x20,0x10,0x0F,0x00,
0x00,0x00,0x20,0x20,0x3F,0x20,0x20,0x00,
0x00,0x00,0x20,0x20,0x3F,0x20,0x20,0x00,
0x00,0x06,0x05,0x24,0x24,0x3F,0x24,0x24,
0x00,0x06,0x05,0x24,0x24,0x3F,0x24,0x24,
};
code unsigned NUMBER_RPAGE0[]=
{
0x00,0xF0,0x08,0x08,0x08,0x10,0xE0,0x00,
0x00,0xE0,0x10,0x08,0x08,0x10,0xE0,0x00,
};
code unsigned NUMBER_RPAGE1[]=
{
0x00,0x01,0x12,0x22,0x22,0x11,0x0F,0x00,
0x00,0x0F,0x10,0x20,0x20,0x10,0x0F,0x00,
};
//void writeData(unsigned char d)
//{
// RS = 1;
// RW = 0;
// P1 = d;
//}
//void setCommand(unsigned char d)
//{
// RS = 0;
// RW = 0;
// P1 = d;
//}
//void setPage(unsigned char p)
//{
// setCommand(0xb8 + p);
//}
//void setLine(unsigned char p)
//{
// setCommand(0xc0 + p);
//}
//void setY(unsigned char p)
//{
// setCommand(0x40 + p);
//}

View file

@ -0,0 +1,25 @@
#include "delay.h"
#include "main.h"
#include "display.h"
#include "menu.h"
extern Menu *NOW;
sbit RS = P3 ^ 0;
sbit RW = P3 ^ 1;
sbit E = P3 ^ 2;
sbit CSA = P3 ^ 4;
sbit CSB = P3 ^ 5;
int main()
{
menuInit();
NOW->f(NOW);
while(1)
{
}
}

View file

@ -0,0 +1,11 @@
#ifndef _MAIN_H_
#define _MAIN_H_
#include <reg52.h>
#include <intrins.h>
#include <absacc.h>
#include "display.h"
#endif

View file

@ -0,0 +1,27 @@
#include "menu.h"
#include "display.h"
#include "delay.h"
Menu M_MAINMANU;
Menu* NOW;
void m_startup(struct _menu* this)
{
displayInit();
clear();
drawNAME();
delay(1000);
drawNUMBER();
delay(3000);
clear();
NOW=this->n;
}
Menu M_STARTUP={&M_MAINMANU,m_startup};
void menuInit()
{
NOW=&M_STARTUP;
}

View file

@ -0,0 +1,7 @@
typedef struct _menu
{
struct _menu* n;
void(*f)(struct _menu* this);
}Menu;
void menuInit();