📄 3310.s
字号:
.module _3310.c
.area lit(rom, con, rel)
_font6x8::
.byte 0,0
.byte 0,0
.byte 0,0
.byte 0,0
.byte 0,47
.byte 0,0
.byte 0,0
.byte 7,0
.byte 7,0
.byte 0,20
.byte 127,20
.byte 127,20
.byte 0,36
.byte 42,127
.byte 42,18
.byte 35,19
.byte 8,'d
.byte 'b,0
.byte 0,54
.byte 'I,'U
.byte 34,'P
.byte 0,0
.byte 5,3
.byte 0,0
.byte 0,0
.byte 28,34
.byte 'A,0
.byte 0,0
.byte 'A,34
.byte 28,0
.byte 0,20
.byte 8,62
.byte 8,20
.byte 0,8
.byte 8,62
.byte 8,8
.byte 0,0
.byte 0,160
.byte 96,0
.byte 0,8
.byte 8,8
.byte 8,8
.byte 0,0
.byte 96,96
.byte 0,0
.byte 0,32
.byte 16,8
.byte 4,2
.byte 0,62
.byte 'A,'A
.byte 'A,62
.byte 0,0
.byte 'B,127
.byte 64,0
.byte 0,'B
.byte 'a,'Q
.byte 'I,'F
.byte 0,33
.byte 'A,'E
.byte 'K,49
.byte 0,24
.byte 20,18
.byte 127,16
.byte 0,39
.byte 'E,'E
.byte 'E,57
.byte 0,60
.byte 'J,'I
.byte 'I,48
.byte 0,1
.byte 'q,9
.byte 5,3
.byte 0,54
.byte 'I,'I
.byte 'I,54
.byte 0,6
.byte 'I,'I
.byte 41,30
.byte 0,0
.byte 54,54
.byte 0,0
.byte 0,0
.byte 'V,54
.byte 0,0
.byte 0,8
.byte 20,34
.byte 'A,0
.byte 0,20
.byte 20,20
.byte 20,20
.byte 0,0
.byte 'A,34
.byte 20,8
.byte 0,2
.byte 1,'Q
.byte 9,6
.byte 0,50
.byte 'I,'Y
.byte 'Q,62
.byte 0,124
.byte 18,17
.byte 18,124
.byte 0,127
.byte 'I,'I
.byte 'I,54
.byte 0,62
.byte 'A,'A
.byte 'A,34
.byte 0,127
.byte 'A,'A
.byte 34,28
.byte 0,127
.byte 'I,'I
.byte 'I,'A
.byte 0,127
.byte 9,9
.byte 9,1
.byte 0,62
.byte 'A,'I
.byte 'I,'z
.byte 0,127
.byte 8,8
.byte 8,127
.byte 0,0
.byte 'A,127
.byte 'A,0
.byte 0,32
.byte 64,'A
.byte 63,1
.byte 0,127
.byte 8,20
.byte 34,'A
.byte 0,127
.byte 64,64
.byte 64,64
.byte 0,127
.byte 2,12
.byte 2,127
.byte 0,127
.byte 4,8
.byte 16,127
.byte 0,62
.byte 'A,'A
.byte 'A,62
.byte 0,127
.byte 9,9
.byte 9,6
.byte 0,62
.byte 'A,'Q
.byte 33,94
.byte 0,127
.byte 9,25
.byte 41,'F
.byte 0,'F
.byte 'I,'I
.byte 'I,49
.byte 0,1
.byte 1,127
.byte 1,1
.byte 0,63
.byte 64,64
.byte 64,63
.byte 0,31
.byte 32,64
.byte 32,31
.byte 0,63
.byte 64,56
.byte 64,63
.byte 0,'c
.byte 20,8
.byte 20,'c
.byte 0,7
.byte 8,'p
.byte 8,7
.byte 0,'a
.byte 'Q,'I
.byte 'E,'C
.byte 0,0
.byte 127,'A
.byte 'A,0
.byte 0,'U
.byte 42,'U
.byte 42,'U
.byte 0,0
.byte 'A,'A
.byte 127,0
.byte 0,4
.byte 2,1
.byte 2,4
.byte 0,64
.byte 64,64
.byte 64,64
.byte 0,0
.byte 1,2
.byte 4,0
.byte 0,32
.byte 'T,'T
.byte 'T,'x
.byte 0,127
.byte 'H,'D
.byte 'D,56
.byte 0,56
.byte 'D,'D
.byte 'D,32
.byte 0,56
.byte 'D,'D
.byte 'H,127
.byte 0,56
.byte 'T,'T
.byte 'T,24
.byte 0,8
.byte 126,9
.byte 1,2
.byte 0,24
.byte 164,164
.byte 164,124
.byte 0,127
.byte 8,4
.byte 4,'x
.byte 0,0
.byte 'D,125
.byte 64,0
.byte 0,64
.byte 128,132
.byte 125,0
.byte 0,127
.byte 16,40
.byte 'D,0
.byte 0,0
.byte 'A,127
.byte 64,0
.byte 0,124
.byte 4,24
.byte 4,'x
.byte 0,124
.byte 8,4
.byte 4,'x
.byte 0,56
.byte 'D,'D
.byte 'D,56
.byte 0,252
.byte 36,36
.byte 36,24
.byte 0,24
.byte 36,36
.byte 24,252
.byte 0,124
.byte 8,4
.byte 4,8
.byte 0,'H
.byte 'T,'T
.byte 'T,32
.byte 0,4
.byte 63,'D
.byte 64,32
.byte 0,60
.byte 64,64
.byte 32,124
.byte 0,28
.byte 32,64
.byte 32,28
.byte 0,60
.byte 64,48
.byte 64,60
.byte 0,'D
.byte 40,16
.byte 40,'D
.byte 0,28
.byte 160,160
.byte 160,124
.byte 0,'D
.byte 'd,'T
.byte 'L,'D
.dbfile D:\TDDownload\MP3BOA~1.8\3310.c
.dbsym e font6x8 _font6x8 A[546:91:6]kc
_Hzk3::
.byte 62,62
.byte 62,62
.byte 62,62
.byte 0,127
.byte 62,28
.byte 8,0
.byte 62,62
.byte 0,0
.byte 62,62
.dbsym e Hzk3 _Hzk3 A[18:3:6]kc
.area text(rom, con, rel)
.dbfile D:\TDDownload\MP3BOA~1.8\3310.c
.dbfunc e LCD_init _LCD_init fV
.even
_LCD_init::
.dbline -1
.dbline 227
; //ICC-AVR application builder : 2005-11-12 17:11:59
; // Target : M16
; // Crystal: 8.0000Mhz
; // copyright:鲁军波(endylu)
; // www.shop34612283.taobao.com
; // www.adembed.com
; #include <iom16v.h>
; #include <macros.h>
; #include "main.h"
;
;
;
; // 6 x 8 font
;
; // 1 pixel space at left and bottom
;
; // index = ASCII - 32
;
; const uint8 font6x8[][6] =
;
; {
;
; { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 },// sp
;
; { 0x00, 0x00, 0x00, 0x2f, 0x00, 0x00 },// !
;
; { 0x00, 0x00, 0x07, 0x00, 0x07, 0x00 },// "
;
; { 0x00, 0x14, 0x7f, 0x14, 0x7f, 0x14 },// #
;
; { 0x00, 0x24, 0x2a, 0x7f, 0x2a, 0x12 },// $
;
; { 0x23, 0x13, 0x08, 0x64, 0x62, 0x00 },// %
;
; { 0x00, 0x36, 0x49, 0x55, 0x22, 0x50 },// &
;
; { 0x00, 0x00, 0x05, 0x03, 0x00, 0x00 },// '
;
; { 0x00, 0x00, 0x1c, 0x22, 0x41, 0x00 },// (
;
; { 0x00, 0x00, 0x41, 0x22, 0x1c, 0x00 },// )
;
; { 0x00, 0x14, 0x08, 0x3E, 0x08, 0x14 },// *
;
; { 0x00, 0x08, 0x08, 0x3E, 0x08, 0x08 },// +
;
; { 0x00, 0x00, 0x00, 0xA0, 0x60, 0x00 },// ,
;
; { 0x00, 0x08, 0x08, 0x08, 0x08, 0x08 },// -
;
; { 0x00, 0x00, 0x60, 0x60, 0x00, 0x00 },// .
;
; { 0x00, 0x20, 0x10, 0x08, 0x04, 0x02 },// /
;
; { 0x00, 0x3E, 0x41, 0x41, 0x41, 0x3E },// 0
;
; { 0x00, 0x00, 0x42, 0x7F, 0x40, 0x00 },// 1
;
; { 0x00, 0x42, 0x61, 0x51, 0x49, 0x46 },// 2
;
; { 0x00, 0x21, 0x41, 0x45, 0x4B, 0x31 },// 3
;
; { 0x00, 0x18, 0x14, 0x12, 0x7F, 0x10 },// 4
;
; { 0x00, 0x27, 0x45, 0x45, 0x45, 0x39 },// 5
;
; { 0x00, 0x3C, 0x4A, 0x49, 0x49, 0x30 },// 6
;
; { 0x00, 0x01, 0x71, 0x09, 0x05, 0x03 },// 7
;
; { 0x00, 0x36, 0x49, 0x49, 0x49, 0x36 },// 8
;
; { 0x00, 0x06, 0x49, 0x49, 0x29, 0x1E },// 9
;
; { 0x00, 0x00, 0x36, 0x36, 0x00, 0x00 },// :
;
; { 0x00, 0x00, 0x56, 0x36, 0x00, 0x00 },// ;
;
; { 0x00, 0x08, 0x14, 0x22, 0x41, 0x00 },// <
;
; { 0x00, 0x14, 0x14, 0x14, 0x14, 0x14 },// =
;
; { 0x00, 0x00, 0x41, 0x22, 0x14, 0x08 },// >
;
; { 0x00, 0x02, 0x01, 0x51, 0x09, 0x06 },// ?
;
; { 0x00, 0x32, 0x49, 0x59, 0x51, 0x3E },// @
;
; { 0x00, 0x7C, 0x12, 0x11, 0x12, 0x7C },// A
;
; { 0x00, 0x7F, 0x49, 0x49, 0x49, 0x36 },// B
;
; { 0x00, 0x3E, 0x41, 0x41, 0x41, 0x22 },// C
;
; { 0x00, 0x7F, 0x41, 0x41, 0x22, 0x1C },// D
;
; { 0x00, 0x7F, 0x49, 0x49, 0x49, 0x41 },// E
;
; { 0x00, 0x7F, 0x09, 0x09, 0x09, 0x01 },// F
;
; { 0x00, 0x3E, 0x41, 0x49, 0x49, 0x7A },// G
;
; { 0x00, 0x7F, 0x08, 0x08, 0x08, 0x7F },// H
;
; { 0x00, 0x00, 0x41, 0x7F, 0x41, 0x00 },// I
;
; { 0x00, 0x20, 0x40, 0x41, 0x3F, 0x01 },// J
;
; { 0x00, 0x7F, 0x08, 0x14, 0x22, 0x41 },// K
;
; { 0x00, 0x7F, 0x40, 0x40, 0x40, 0x40 },// L
;
; { 0x00, 0x7F, 0x02, 0x0C, 0x02, 0x7F },// M
;
; { 0x00, 0x7F, 0x04, 0x08, 0x10, 0x7F },// N
;
; { 0x00, 0x3E, 0x41, 0x41, 0x41, 0x3E },// O
;
; { 0x00, 0x7F, 0x09, 0x09, 0x09, 0x06 },// P
;
; { 0x00, 0x3E, 0x41, 0x51, 0x21, 0x5E },// Q
;
; { 0x00, 0x7F, 0x09, 0x19, 0x29, 0x46 },// R
;
; { 0x00, 0x46, 0x49, 0x49, 0x49, 0x31 },// S
;
; { 0x00, 0x01, 0x01, 0x7F, 0x01, 0x01 },// T
;
; { 0x00, 0x3F, 0x40, 0x40, 0x40, 0x3F },// U
;
; { 0x00, 0x1F, 0x20, 0x40, 0x20, 0x1F },// V
;
; { 0x00, 0x3F, 0x40, 0x38, 0x40, 0x3F },// W
;
; { 0x00, 0x63, 0x14, 0x08, 0x14, 0x63 },// X
;
; { 0x00, 0x07, 0x08, 0x70, 0x08, 0x07 },// Y
;
; { 0x00, 0x61, 0x51, 0x49, 0x45, 0x43 },// Z
;
; { 0x00, 0x00, 0x7F, 0x41, 0x41, 0x00 },// [
;
; { 0x00, 0x55, 0x2A, 0x55, 0x2A, 0x55 },// 55
;
; { 0x00, 0x00, 0x41, 0x41, 0x7F, 0x00 },// ]
;
; { 0x00, 0x04, 0x02, 0x01, 0x02, 0x04 },// ^
;
; { 0x00, 0x40, 0x40, 0x40, 0x40, 0x40 },// _
;
; { 0x00, 0x00, 0x01, 0x02, 0x04, 0x00 },// '
;
; { 0x00, 0x20, 0x54, 0x54, 0x54, 0x78 },// a
;
; { 0x00, 0x7F, 0x48, 0x44, 0x44, 0x38 },// b
;
; { 0x00, 0x38, 0x44, 0x44, 0x44, 0x20 },// c
;
; { 0x00, 0x38, 0x44, 0x44, 0x48, 0x7F },// d
;
; { 0x00, 0x38, 0x54, 0x54, 0x54, 0x18 },// e
;
; { 0x00, 0x08, 0x7E, 0x09, 0x01, 0x02 },// f
;
; { 0x00, 0x18, 0xA4, 0xA4, 0xA4, 0x7C },// g
;
; { 0x00, 0x7F, 0x08, 0x04, 0x04, 0x78 },// h
;
; { 0x00, 0x00, 0x44, 0x7D, 0x40, 0x00 },// i
;
; { 0x00, 0x40, 0x80, 0x84, 0x7D, 0x00 },// j
;
; { 0x00, 0x7F, 0x10, 0x28, 0x44, 0x00 },// k
;
; { 0x00, 0x00, 0x41, 0x7F, 0x40, 0x00 },// l
;
; { 0x00, 0x7C, 0x04, 0x18, 0x04, 0x78 },// m
;
; { 0x00, 0x7C, 0x08, 0x04, 0x04, 0x78 },// n
;
; { 0x00, 0x38, 0x44, 0x44, 0x44, 0x38 },// o
;
; { 0x00, 0xFC, 0x24, 0x24, 0x24, 0x18 },// p
;
; { 0x00, 0x18, 0x24, 0x24, 0x18, 0xFC },// q
;
; { 0x00, 0x7C, 0x08, 0x04, 0x04, 0x08 },// r
;
; { 0x00, 0x48, 0x54, 0x54, 0x54, 0x20 },// s
;
; { 0x00, 0x04, 0x3F, 0x44, 0x40, 0x20 },// t
;
; { 0x00, 0x3C, 0x40, 0x40, 0x20, 0x7C },// u
;
; { 0x00, 0x1C, 0x20, 0x40, 0x20, 0x1C },// v
;
; { 0x00, 0x3C, 0x40, 0x30, 0x40, 0x3C },// w
;
; { 0x00, 0x44, 0x28, 0x10, 0x28, 0x44 },// x
;
; { 0x00, 0x1C, 0xA0, 0xA0, 0xA0, 0x7C },// y
;
; { 0x00, 0x44, 0x64, 0x54, 0x4C, 0x44 },// z
;
; //{ 0x14, 0x14, 0x14, 0x14, 0x14, 0x14 }// horiz lines
;
; };
;
;
; const uint8 Hzk3[][6]={
; //停止
; {0x3E,0x3E,0x3E,0x3E,0x3E,0x3E},
; //播放
; {0x00,0x7F,0x3E,0x1C,0x08,0x00},
; //暂停
; {0x3E,0x3E,0x00,0x00,0x3E,0x3E},
;
; };
;
;
;
; //=======================================================================
; //LCD_init: 3310LCD初始化
;
; void LCD_init(void)
;
; {
.dbline 228
; LCD_ddr|=LCD_RST|LCD_DC|LCD_CS;
in R24,0x1a
ori R24,224
out 0x1a,R24
.dbline 230
; //DDRB|=SPI_MOSI|SPI_CLK;
; LCD_port&=~LCD_RST; // 产生一个让LCD复位的低电平脉冲
cbi 0x1b,5
.dbline 231
; Delay_us(1);
ldi R16,1
ldi R17,0
xcall _Delay_us
.dbline 232
; LCD_port|=LCD_RST;
sbi 0x1b,5
.dbline 233
; LCD_port|=LCD_CS ; // 关闭LCD
sbi 0x1b,6
.dbline 234
; Delay_us(1);
ldi R16,1
ldi R17,0
xcall _Delay_us
.dbline 235
; LCD_port&=~LCD_CS; // 使能LCD
cbi 0x1b,6
.dbline 236
; Delay_us(1);
ldi R16,1
ldi R17,0
xcall _Delay_us
.dbline 237
; LCD_write_byte(0x21, 0);// 使用扩展命令设置LCD模式
clr R18
ldi R16,33
xcall _LCD_write_byte
.dbline 238
; LCD_write_byte(0xc8, 0);// 设置偏置电压 Vlcd=3.06+72*0.06=7.38<8.5
clr R18
ldi R16,200
xcall _LCD_write_byte
.dbline 239
; LCD_write_byte(0x06, 0);// 温度校正
clr R18
ldi R16,6
xcall _LCD_write_byte
.dbline 240
; LCD_write_byte(0x13, 0); // 1:48
clr R18
ldi R16,19
xcall _LCD_write_byte
.dbline 241
; LCD_write_byte(0x20, 0); // 使用基本命令
clr R18
ldi R16,32
xcall _LCD_write_byte
.dbline 242
; LCD_clear(); // 清屏
xcall _LCD_clear
.dbline 243
; LCD_write_byte(0x0c, 0);// 设定显示模式,正常显示
clr R18
ldi R16,12
xcall _LCD_write_byte
.dbline 244
; LCD_port|=LCD_CS ;// 关闭LCD
sbi 0x1b,6
.dbline -2
L1:
.dbline 0 ; func end
ret
.dbend
.dbfunc e LCD_clear _LCD_clear fV
.even
_LCD_clear::
sbiw R28,5
.dbline -1
.dbline 254
;
; }
;
; //=======================================================================
; //LCD_clear: LCD清屏函数
;
;
; void LCD_clear(void)
;
; {
.dbline 255
; LCD_write_String(0,0,14," ",0);
clr R2
std y+4,R2
ldi R24,<L3
ldi R25,>L3
std y+3,R25
std y+2,R24
ldi R24,14
std y+0,R24
clr R18
clr R16
xcall _LCD_write_String
.dbline 256
; LCD_write_String(0,1,14," ",0);
clr R2
std y+4,R2
ldi R24,<L3
ldi R25,>L3
std y+3,R25
std y+2,R24
ldi R24,14
std y+0,R24
ldi R18,1
clr R16
xcall _LCD_write_String
.dbline 257
; LCD_write_String(0,2,14," ",0);
clr R2
std y+4,R2
ldi R24,<L3
ldi R25,>L3
std y+3,R25
std y+2,R24
ldi R24,14
std y+0,R24
ldi R18,2
clr R16
xcall _LCD_write_String
.dbline 258
; LCD_write_String(0,3,14," ",0);
clr R2
std y+4,R2
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -