⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pelikon.lss

📁 pelikon 公司PSEL驱动程序
💻 LSS
字号:

pelikon.elf:     file format elf32-avr

Sections:
Idx Name          Size      VMA       LMA       File off  Algn
  0 .text         000002ec  00000000  00000000  00000094  2**0
                  CONTENTS, ALLOC, LOAD, READONLY, CODE
  1 .data         00000002  00800060  000002ec  00000380  2**0
                  CONTENTS, ALLOC, LOAD, DATA
  2 .bss          0000000b  00800062  00800062  00000382  2**0
                  ALLOC
  3 .noinit       00000000  0080006d  0080006d  00000382  2**0
                  CONTENTS
  4 .eeprom       00000000  00810000  00810000  00000382  2**0
                  CONTENTS
  5 .debug_aranges 00000014  00000000  00000000  00000382  2**0
                  CONTENTS, READONLY, DEBUGGING
  6 .debug_pubnames 00000111  00000000  00000000  00000396  2**0
                  CONTENTS, READONLY, DEBUGGING
  7 .debug_info   0000030e  00000000  00000000  000004a7  2**0
                  CONTENTS, READONLY, DEBUGGING
  8 .debug_abbrev 0000014f  00000000  00000000  000007b5  2**0
                  CONTENTS, READONLY, DEBUGGING
  9 .debug_line   0000029a  00000000  00000000  00000904  2**0
                  CONTENTS, READONLY, DEBUGGING
 10 .debug_str    0000018c  00000000  00000000  00000b9e  2**0
                  CONTENTS, READONLY, DEBUGGING
Disassembly of section .text:

00000000 <__vectors>:
   0:	0c 94 62 00 	jmp	0xc4
   4:	0c 94 7d 00 	jmp	0xfa
   8:	0c 94 7d 00 	jmp	0xfa
   c:	0c 94 7d 00 	jmp	0xfa
  10:	0c 94 7d 00 	jmp	0xfa
  14:	0c 94 7d 00 	jmp	0xfa
  18:	0c 94 7d 00 	jmp	0xfa
  1c:	0c 94 7d 00 	jmp	0xfa
  20:	0c 94 7d 00 	jmp	0xfa
  24:	0c 94 0e 01 	jmp	0x21c
  28:	0c 94 7d 00 	jmp	0xfa
  2c:	0c 94 7d 00 	jmp	0xfa
  30:	0c 94 7d 00 	jmp	0xfa
  34:	0c 94 7d 00 	jmp	0xfa
  38:	0c 94 7d 00 	jmp	0xfa
  3c:	0c 94 7d 00 	jmp	0xfa
  40:	0c 94 7d 00 	jmp	0xfa
  44:	0c 94 7d 00 	jmp	0xfa
  48:	0c 94 7d 00 	jmp	0xfa
  4c:	0c 94 7d 00 	jmp	0xfa
  50:	0c 94 7d 00 	jmp	0xfa

00000054 <__ctors_end>:
	...
  64:	01 01       	movw	r0, r2
  66:	01 01       	movw	r0, r2
  68:	01 01       	movw	r0, r2
  6a:	01 01       	movw	r0, r2
  6c:	01 01       	movw	r0, r2
  6e:	01 01       	movw	r0, r2
  70:	01 01       	movw	r0, r2
  72:	01 01       	movw	r0, r2
  74:	01 00       	.word	0x0001	; ????
	...
  82:	00 00       	nop
  84:	00 01       	movw	r0, r0
	...
  96:	01 00       	.word	0x0001	; ????
	...
  a4:	00 00       	nop
  a6:	00 01       	movw	r0, r0
	...
  b8:	01 00       	.word	0x0001	; ????
	...

000000c4 <__init>:
  c4:	11 24       	eor	r1, r1
  c6:	1f be       	out	0x3f, r1	; 63
  c8:	cf e5       	ldi	r28, 0x5F	; 95
  ca:	d4 e0       	ldi	r29, 0x04	; 4
  cc:	de bf       	out	0x3e, r29	; 62
  ce:	cd bf       	out	0x3d, r28	; 61

000000d0 <__do_copy_data>:
  d0:	10 e0       	ldi	r17, 0x00	; 0
  d2:	a0 e6       	ldi	r26, 0x60	; 96
  d4:	b0 e0       	ldi	r27, 0x00	; 0
  d6:	ec ee       	ldi	r30, 0xEC	; 236
  d8:	f2 e0       	ldi	r31, 0x02	; 2
  da:	02 c0       	rjmp	.+4      	; 0xe0

000000dc <.do_copy_data_loop>:
  dc:	05 90       	lpm	r0, Z+
  de:	0d 92       	st	X+, r0

000000e0 <.do_copy_data_start>:
  e0:	a2 36       	cpi	r26, 0x62	; 98
  e2:	b1 07       	cpc	r27, r17
  e4:	d9 f7       	brne	.-10     	; 0xdc

000000e6 <__do_clear_bss>:
  e6:	10 e0       	ldi	r17, 0x00	; 0
  e8:	a2 e6       	ldi	r26, 0x62	; 98
  ea:	b0 e0       	ldi	r27, 0x00	; 0
  ec:	01 c0       	rjmp	.+2      	; 0xf0

000000ee <.do_clear_bss_loop>:
  ee:	1d 92       	st	X+, r1

000000f0 <.do_clear_bss_start>:
  f0:	ad 36       	cpi	r26, 0x6D	; 109
  f2:	b1 07       	cpc	r27, r17
  f4:	e1 f7       	brne	.-8      	; 0xee
  f6:	0c 94 db 00 	jmp	0x1b6

000000fa <__bad_interrupt>:
  fa:	0c 94 00 00 	jmp	0x0

000000fe <keyscan>:

unsigned char keyscan(void)
{
	unsigned char temp;
	temp = PINB;
  fe:	86 b3       	in	r24, 0x16	; 22
	if ((temp & 0x01) == 0)
 100:	48 2f       	mov	r20, r24
 102:	55 27       	eor	r21, r21
 104:	21 e0       	ldi	r18, 0x01	; 1
 106:	30 e0       	ldi	r19, 0x00	; 0
 108:	ca 01       	movw	r24, r20
 10a:	82 23       	and	r24, r18
 10c:	93 23       	and	r25, r19
 10e:	82 17       	cp	r24, r18
 110:	93 07       	cpc	r25, r19
 112:	11 f0       	breq	.+4      	; 0x118
	{
		return VKEY1;
 114:	c9 01       	movw	r24, r18
 116:	08 95       	ret
	} 
	else if ((temp & 0x02) == 0)
 118:	ca 01       	movw	r24, r20
 11a:	96 95       	lsr	r25
 11c:	87 95       	ror	r24
 11e:	82 27       	eor	r24, r18
 120:	93 27       	eor	r25, r19
 122:	9c 01       	movw	r18, r24
 124:	21 70       	andi	r18, 0x01	; 1
 126:	30 70       	andi	r19, 0x00	; 0
 128:	80 ff       	sbrs	r24, 0
 12a:	03 c0       	rjmp	.+6      	; 0x132
	{
		return VKEY2;
 12c:	82 e0       	ldi	r24, 0x02	; 2
 12e:	90 e0       	ldi	r25, 0x00	; 0
 130:	08 95       	ret
	} 
	return 0;
 132:	c9 01       	movw	r24, r18
}
 134:	08 95       	ret
 136:	08 95       	ret

00000138 <disbouncing>:
void disbouncing(void)
{
	while(key_value != 0)
	{
	    if(key < 10)
		{
		    key = 0;
	    }
	    else
		{
		    key = 0;
 138:	80 91 69 00 	lds	r24, 0x0069
 13c:	88 23       	and	r24, r24
 13e:	29 f0       	breq	.+10     	; 0x14a
 140:	80 91 67 00 	lds	r24, 0x0067
 144:	10 92 67 00 	sts	0x0067, r1
 148:	f7 cf       	rjmp	.-18     	; 0x138
 14a:	08 95       	ret

0000014c <write_segments>:
	    }
	}
}
void write_segments(unsigned char index)
{
 14c:	e8 2f       	mov	r30, r24
 14e:	ff 27       	eor	r31, r31
 150:	54 e0       	ldi	r21, 0x04	; 4
 152:	ee 0f       	add	r30, r30
 154:	ff 1f       	adc	r31, r31
 156:	5a 95       	dec	r21
 158:	e1 f7       	brne	.-8      	; 0x152
 15a:	ec 5a       	subi	r30, 0xAC	; 172
 15c:	ff 4f       	sbci	r31, 0xFF	; 255
 15e:	9f e0       	ldi	r25, 0x0F	; 15
	unsigned char i;
	for (i = 0;i < 16;i++)
	{
		if (pgm_read_byte(&rcBuffer[index][i]))
 160:	84 91       	lpm	r24, Z
 162:	88 23       	and	r24, r24
 164:	11 f0       	breq	.+4      	; 0x16a
		{
			set_DATA_IN();
 166:	d9 9a       	sbi	0x1b, 1	; 27
 168:	01 c0       	rjmp	.+2      	; 0x16c
	    }
		else
		{ 
			reset_DATA_IN();
 16a:	d9 98       	cbi	0x1b, 1	; 27
		}
		reset_CLK();
 16c:	da 98       	cbi	0x1b, 2	; 27
    can be achieved.
*/
static __inline__ void
_delay_loop_1(uint8_t __count)
{
 16e:	84 e0       	ldi	r24, 0x04	; 4
	__asm__ volatile (
 170:	8a 95       	dec	r24
 172:	f1 f7       	brne	.-4      	; 0x170
        _delay_loop_1(4);
        set_CLK();
 174:	da 9a       	sbi	0x1b, 2	; 27
 176:	91 50       	subi	r25, 0x01	; 1
 178:	31 96       	adiw	r30, 0x01	; 1
 17a:	97 ff       	sbrs	r25, 7
 17c:	f1 cf       	rjmp	.-30     	; 0x160
	}
	reset_DATA_IN(); 
 17e:	d9 98       	cbi	0x1b, 1	; 27
	reset_CLK();
 180:	da 98       	cbi	0x1b, 2	; 27
    can be achieved.
*/
static __inline__ void
_delay_loop_1(uint8_t __count)
{
 182:	84 e0       	ldi	r24, 0x04	; 4
	__asm__ volatile (
 184:	8a 95       	dec	r24
 186:	f1 f7       	brne	.-4      	; 0x184
	_delay_loop_1(4);
	reset_LE();
 188:	d8 98       	cbi	0x1b, 0	; 27
    milliseconds can be achieved.
 */
static __inline__ void
_delay_loop_2(uint16_t __count)
{
 18a:	84 e0       	ldi	r24, 0x04	; 4
 18c:	90 e1       	ldi	r25, 0x10	; 16
	__asm__ volatile (
 18e:	01 97       	sbiw	r24, 0x01	; 1
 190:	f1 f7       	brne	.-4      	; 0x18e
	_delay_loop_2(4100);
	set_LE();
 192:	d8 9a       	sbi	0x1b, 0	; 27
 194:	08 95       	ret

00000196 <init_pelikon>:
}

void init_pelikon (void)
{
 196:	1f 93       	push	r17
    DDRA = 0xff;	
 198:	8f ef       	ldi	r24, 0xFF	; 255
 19a:	8a bb       	out	0x1a, r24	; 26
    PORTA = 0x01;
 19c:	11 e0       	ldi	r17, 0x01	; 1
 19e:	1b bb       	out	0x1b, r17	; 27
	write_segments(0);//17,there is no gray level segment.
 1a0:	80 e0       	ldi	r24, 0x00	; 0
 1a2:	0e 94 a6 00 	call	0x14c
	TCCR0=0x01;
 1a6:	13 bf       	out	0x33, r17	; 51
	TCNT0=0x00;
 1a8:	12 be       	out	0x32, r1	; 50
	TIMSK=TIMSK|0x01;
 1aa:	89 b7       	in	r24, 0x39	; 57
 1ac:	81 2b       	or	r24, r17
 1ae:	89 bf       	out	0x39, r24	; 57

	sei();
 1b0:	78 94       	sei
 1b2:	1f 91       	pop	r17
 1b4:	08 95       	ret

000001b6 <main>:
}

int main(void)
{
 1b6:	cf e5       	ldi	r28, 0x5F	; 95
 1b8:	d4 e0       	ldi	r29, 0x04	; 4
 1ba:	de bf       	out	0x3e, r29	; 62
 1bc:	cd bf       	out	0x3d, r28	; 61
    unsigned char i;
    init_pelikon();
 1be:	0e 94 cb 00 	call	0x196
	for(;;) 
	{
	    write_segments(screen_flag);
 1c2:	80 91 60 00 	lds	r24, 0x0060
 1c6:	0e 94 a6 00 	call	0x14c
	    while (key_value == 0);	
 1ca:	80 91 69 00 	lds	r24, 0x0069
 1ce:	88 23       	and	r24, r24
 1d0:	e1 f3       	breq	.-8      	; 0x1ca
        if (key_value == 1)
 1d2:	c0 91 69 00 	lds	r28, 0x0069
 1d6:	c1 30       	cpi	r28, 0x01	; 1
 1d8:	71 f4       	brne	.+28     	; 0x1f6
	    {
	        disbouncing ();
 1da:	0e 94 9c 00 	call	0x138
	        screen_flag ++;
 1de:	80 91 60 00 	lds	r24, 0x0060
 1e2:	8f 5f       	subi	r24, 0xFF	; 255
 1e4:	80 93 60 00 	sts	0x0060, r24
	        if (screen_flag == 7)
 1e8:	80 91 60 00 	lds	r24, 0x0060
 1ec:	87 30       	cpi	r24, 0x07	; 7
 1ee:	49 f7       	brne	.-46     	; 0x1c2
		    {
		        screen_flag = 1;
 1f0:	c0 93 60 00 	sts	0x0060, r28
 1f4:	e6 cf       	rjmp	.-52     	; 0x1c2
		    }
	    }
	    else if (key_value == 2)
 1f6:	80 91 69 00 	lds	r24, 0x0069
 1fa:	82 30       	cpi	r24, 0x02	; 2
 1fc:	11 f7       	brne	.-60     	; 0x1c2
	    {
	        disbouncing ();
 1fe:	0e 94 9c 00 	call	0x138
		    screen_flag --;
 202:	80 91 60 00 	lds	r24, 0x0060
 206:	81 50       	subi	r24, 0x01	; 1
 208:	80 93 60 00 	sts	0x0060, r24
		    if (screen_flag == 0)
 20c:	80 91 60 00 	lds	r24, 0x0060
 210:	88 23       	and	r24, r24
 212:	b9 f6       	brne	.-82     	; 0x1c2
	    	{
		    screen_flag = 6;
 214:	86 e0       	ldi	r24, 0x06	; 6
 216:	80 93 60 00 	sts	0x0060, r24
 21a:	d3 cf       	rjmp	.-90     	; 0x1c2

0000021c <__vector_9>:
	    	}
	    }
	}
	
}

SIGNAL(SIG_OVERFLOW0)
{
 21c:	1f 92       	push	r1
 21e:	0f 92       	push	r0
 220:	0f b6       	in	r0, 0x3f	; 63
 222:	0f 92       	push	r0
 224:	11 24       	eor	r1, r1
 226:	2f 93       	push	r18
 228:	3f 93       	push	r19
 22a:	4f 93       	push	r20
 22c:	5f 93       	push	r21
 22e:	6f 93       	push	r22
 230:	7f 93       	push	r23
 232:	8f 93       	push	r24
 234:	9f 93       	push	r25
 236:	af 93       	push	r26
 238:	bf 93       	push	r27
 23a:	ef 93       	push	r30
 23c:	ff 93       	push	r31
	timer_ov_num1++;
 23e:	80 91 6c 00 	lds	r24, 0x006C
 242:	8f 5f       	subi	r24, 0xFF	; 255
 244:	80 93 6c 00 	sts	0x006C, r24
	if(timer_ov_num1 == 20)
 248:	80 91 6c 00 	lds	r24, 0x006C
 24c:	84 31       	cpi	r24, 0x14	; 20
 24e:	e9 f5       	brne	.+122    	; 0x2ca
	{
	    timer_ov_num1 = 0;        
 250:	10 92 6c 00 	sts	0x006C, r1
		timer_ov_num2++;
 254:	80 91 6b 00 	lds	r24, 0x006B
 258:	8f 5f       	subi	r24, 0xFF	; 255
 25a:	80 93 6b 00 	sts	0x006B, r24
	    if(timer_ov_num2 == 157)//157
 25e:	80 91 6b 00 	lds	r24, 0x006B
 262:	8d 39       	cpi	r24, 0x9D	; 157
 264:	91 f5       	brne	.+100    	; 0x2ca
		{
		    timer_ov_num2 = 0;
 266:	10 92 6b 00 	sts	0x006B, r1
			if(first_keyscan == 0)
 26a:	90 91 6a 00 	lds	r25, 0x006A
 26e:	99 23       	and	r25, r25
 270:	29 f4       	brne	.+10     	; 0x27c
			{
			    first_keyscan = 1;
 272:	81 e0       	ldi	r24, 0x01	; 1
 274:	80 93 6a 00 	sts	0x006A, r24
			    key_valueold = 0;
 278:	90 93 68 00 	sts	0x0068, r25
			}
			if(key_value != 0)
 27c:	80 91 69 00 	lds	r24, 0x0069
 280:	88 23       	and	r24, r24
 282:	21 f0       	breq	.+8      	; 0x28c
			{
			    key_valueold = key_value;
 284:	80 91 69 00 	lds	r24, 0x0069
 288:	80 93 68 00 	sts	0x0068, r24
			}
		    key_value = keyscan();
 28c:	0e 94 7f 00 	call	0xfe
 290:	80 93 69 00 	sts	0x0069, r24
	        if((key_value == key_valueold) && (key_value != 0))
 294:	90 91 69 00 	lds	r25, 0x0069
 298:	80 91 68 00 	lds	r24, 0x0068
 29c:	98 17       	cp	r25, r24
 29e:	49 f4       	brne	.+18     	; 0x2b2
 2a0:	80 91 69 00 	lds	r24, 0x0069
 2a4:	88 23       	and	r24, r24
 2a6:	29 f0       	breq	.+10     	; 0x2b2
			{
		        key++;
 2a8:	80 91 67 00 	lds	r24, 0x0067
 2ac:	8f 5f       	subi	r24, 0xFF	; 255
 2ae:	80 93 67 00 	sts	0x0067, r24
	        }
			if((key_valueold != key_value) && (key < 10))
 2b2:	90 91 68 00 	lds	r25, 0x0068
 2b6:	80 91 69 00 	lds	r24, 0x0069
 2ba:	98 17       	cp	r25, r24
 2bc:	31 f0       	breq	.+12     	; 0x2ca
 2be:	80 91 67 00 	lds	r24, 0x0067
 2c2:	8a 30       	cpi	r24, 0x0A	; 10
 2c4:	10 f4       	brcc	.+4      	; 0x2ca
			{
				key = 0;
 2c6:	10 92 67 00 	sts	0x0067, r1
 2ca:	ff 91       	pop	r31
 2cc:	ef 91       	pop	r30
 2ce:	bf 91       	pop	r27
 2d0:	af 91       	pop	r26
 2d2:	9f 91       	pop	r25
 2d4:	8f 91       	pop	r24
 2d6:	7f 91       	pop	r23
 2d8:	6f 91       	pop	r22
 2da:	5f 91       	pop	r21
 2dc:	4f 91       	pop	r20
 2de:	3f 91       	pop	r19
 2e0:	2f 91       	pop	r18
 2e2:	0f 90       	pop	r0
 2e4:	0f be       	out	0x3f, r0	; 63
 2e6:	0f 90       	pop	r0
 2e8:	1f 90       	pop	r1
 2ea:	18 95       	reti

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -