summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorNao Pross <naopross@thearcway.org>2018-02-27 10:38:17 +0100
committerNao Pross <naopross@thearcway.org>2018-02-27 10:38:17 +0100
commit0a9c19f83f6a08f18871c9728c8cc474a615a3be (patch)
tree1d04689355f9106f3082d060b0d4d7bc9cf87df4 /src
parentFinalize measurement code and implement midi output (diff)
downloadXilofono-0a9c19f83f6a08f18871c9728c8cc474a615a3be.tar.gz
Xilofono-0a9c19f83f6a08f18871c9728c8cc474a615a3be.zip
MPLab X garbage
Diffstat (limited to 'src')
-rw-r--r--src/disassembly/listing.disasm1598
-rw-r--r--src/dist/default/production/memoryfile.xml8
-rw-r--r--src/dist/default/production/src.production.cmf528
-rw-r--r--src/dist/default/production/src.production.elfbin19102 -> 21303 bytes
-rw-r--r--src/dist/default/production/src.production.hex168
-rw-r--r--src/dist/default/production/src.production.hxl15
-rw-r--r--src/dist/default/production/src.production.lst3601
-rw-r--r--src/dist/default/production/src.production.map446
-rw-r--r--src/dist/default/production/src.production.mum6
-rw-r--r--src/dist/default/production/src.production.objbin13299 -> 18183 bytes
-rw-r--r--src/dist/default/production/src.production.rlfbin116932 -> 149785 bytes
-rw-r--r--src/dist/default/production/src.production.sdb296
-rw-r--r--src/dist/default/production/src.production.sym450
-rw-r--r--src/nbproject/Makefile-genesis.properties2
14 files changed, 3961 insertions, 3157 deletions
diff --git a/src/disassembly/listing.disasm b/src/disassembly/listing.disasm
index e830f54..282aa13 100644
--- a/src/disassembly/listing.disasm
+++ b/src/disassembly/listing.disasm
@@ -1,7 +1,7 @@
Disassembly Listing for Xilofono
Generated From:
Z:/SAMB_4/projects/xilofono/src/dist/default/production/src.production.elf
-23-feb-2018 16:30:03
+27-feb-2018 09:19:21
--- Z:/SAMB_4/projects/xilofono/src/rs232.c -----------------------------------------------------------
1: #include "rs232.h"
@@ -11,35 +11,35 @@ Z:/SAMB_4/projects/xilofono/src/dist/default/production/src.production.elf
5: {
6: // set Async and 8 bits frame
7: TXSTA1bits.SYNC = 0;
-03FC 98AC BCF TXSTA1, 4, ACCESS
+0598 98AC BCF TXSTA1, 4, ACCESS
8: TXSTA1bits.TX9 = 0;
-03FE 9CAC BCF TXSTA1, 6, ACCESS
+059A 9CAC BCF TXSTA1, 6, ACCESS
9:
10: // baud prescaler
11: RCSTA1bits.SPEN = 1;
-0400 8EAB BSF RCSTA1, 7, ACCESS
+059C 8EAB BSF RCSTA1, 7, ACCESS
12: SPBRG1 = 31;
-0402 0E1F MOVLW 0x1F
-0404 6EAF MOVWF SPBRG1, ACCESS
+059E 0E1F MOVLW 0x1F
+05A0 6EAF MOVWF SPBRG1, ACCESS
13: SPBRGH1 = 0;
-0406 0E00 MOVLW 0x0
-0408 6EB0 MOVWF SPBRGH1, ACCESS
+05A2 0E00 MOVLW 0x0
+05A4 6EB0 MOVWF SPBRGH1, ACCESS
14: TXSTA1bits.BRGH = 0;
-040A 94AC BCF TXSTA1, 2, ACCESS
+05A6 94AC BCF TXSTA1, 2, ACCESS
15: BAUDCON1bits.BRG16 = 0;
-040C 96B8 BCF BAUDCON1, 3, ACCESS
+05A8 96B8 BCF BAUDCON1, 3, ACCESS
16:
17: // set up TX / RX pins
18: TRISCbits.TRISC7 = 1;
-040E 8E94 BSF TRISC, 7, ACCESS
+05AA 8E94 BSF TRISC, 7, ACCESS
19: TRISCbits.TRISC6 = 1;
-0410 8C94 BSF TRISC, 6, ACCESS
+05AC 8C94 BSF TRISC, 6, ACCESS
20: RCSTA1bits.CREN = 1; // enable continuous reception
-0412 88AB BSF RCSTA1, 4, ACCESS
+05AE 88AB BSF RCSTA1, 4, ACCESS
21: TXSTA1bits.TXEN = 1;
-0414 8AAC BSF TXSTA1, 5, ACCESS
+05B0 8AAC BSF TXSTA1, 5, ACCESS
22: }
-0416 0012 RETURN 0
+05B2 0012 RETURN 0
23:
24: void eusart2_init(void)
25: {
@@ -47,53 +47,54 @@ Z:/SAMB_4/projects/xilofono/src/dist/default/production/src.production.elf
27: }
28:
29: void putch(char c)
-0418 6E1A MOVWF p1, ACCESS
+05B4 0100 MOVLB 0x0
+05B6 6F60 MOVWF __pcstackBANK0, BANKED
30: {
31: while (!TX1IF);
-041A A89E BTFSS PIR1, 4, ACCESS
-041C D7FE BRA 0x41A
+05B8 A89E BTFSS PIR1, 4, ACCESS
+05BA D7FE BRA 0x5B8
32: TX1REG = c;
-041E C01A MOVFF p1, TXREG1
-0420 FFAD NOP
+05BC C060 MOVFF __pcstackBANK0, TXREG1
+05BE FFAD NOP
33: }
0008 8245 BSF btemp, 1, ACCESS
-000A CFFA MOVFF PCLATH, 0x5
-000C F005 NOP
-000E CFFB MOVFF PCLATU, 0x6
-0010 F006 NOP
-0012 CFE9 MOVFF FSR0, 0x7
-0014 F007 NOP
-0016 CFEA MOVFF FSR0H, 0x8
-0018 F008 NOP
-001A CFE1 MOVFF FSR1, 0x9
-001C F009 NOP
-001E CFE2 MOVFF FSR1H, 0xA
-0020 F00A NOP
-0022 CFD9 MOVFF FSR2, 0xB
-0024 F00B NOP
-0026 CFDA MOVFF FSR2H, 0xC
-0028 F00C NOP
-002A CFF3 MOVFF PROD, 0xD
-002C F00D NOP
-002E CFF4 MOVFF PRODH, 0xE
-0030 F00E NOP
-0032 CFF6 MOVFF TBLPTR, 0xF
-0034 F00F NOP
-0036 CFF7 MOVFF TBLPTRH, 0x10
-0038 F010 NOP
-003A CFF8 MOVFF TBLPTRU, 0x11
-003C F011 NOP
-003E CFF5 MOVFF TABLAT, 0x12
-0040 F012 NOP
-0042 C045 MOVFF btemp, 0x13
-0044 F013 NOP
-0046 C046 MOVFF 0x46, 0x14
-0048 F014 NOP
-004A C047 MOVFF 0x47, 0x15
-004C F015 NOP
-004E C048 MOVFF 0x48, 0x16
-0050 F016 NOP
-0422 0012 RETURN 0
+000A CFFA MOVFF PCLATH, 0x2B
+000C F02B NOP
+000E CFFB MOVFF PCLATU, 0x2C
+0010 F02C NOP
+0012 CFE9 MOVFF FSR0, 0x2D
+0014 F02D NOP
+0016 CFEA MOVFF FSR0H, 0x2E
+0018 F02E NOP
+001A CFE1 MOVFF FSR1, 0x2F
+001C F02F NOP
+001E CFE2 MOVFF FSR1H, 0x30
+0020 F030 NOP
+0022 CFD9 MOVFF FSR2, 0x31
+0024 F031 NOP
+0026 CFDA MOVFF FSR2H, 0x32
+0028 F032 NOP
+002A CFF3 MOVFF PROD, 0x33
+002C F033 NOP
+002E CFF4 MOVFF PRODH, 0x34
+0030 F034 NOP
+0032 CFF6 MOVFF TBLPTR, 0x35
+0034 F035 NOP
+0036 CFF7 MOVFF TBLPTRH, 0x36
+0038 F036 NOP
+003A CFF8 MOVFF TBLPTRU, 0x37
+003C F037 NOP
+003E CFF5 MOVFF TABLAT, 0x38
+0040 F038 NOP
+0042 C045 MOVFF btemp, 0x39
+0044 F039 NOP
+0046 C046 MOVFF 0x46, 0x3A
+0048 F03A NOP
+004A C047 MOVFF 0x47, 0x3B
+004C F03B NOP
+004E C048 MOVFF 0x48, 0x3C
+0050 F03C NOP
+05C0 0012 RETURN 0
34:
35: char getch(void)
36: {
@@ -151,28 +152,29 @@ Z:/SAMB_4/projects/xilofono/src/dist/default/production/src.production.elf
40: int midi_set_status(midi_message_t *pkt, midi_status_t status)
41: {
42: if (pkt == NULL) {
-03D8 501A MOVF p1, W, ACCESS
-03DA 101B IORWF pkt, W, ACCESS
-03DC B4D8 BTFSC STATUS, 2, ACCESS
-03DE 0012 RETURN 0
+0572 0100 MOVLB 0x0
+0574 5160 MOVF __pcstackBANK0, W, BANKED
+0576 1161 IORWF pkt, W, BANKED
+0578 B4D8 BTFSC STATUS, 2, ACCESS
+057A 0012 RETURN 0
43: return -1;
44: }
45:
46: pkt->status = status & 0x0F;
-03E0 C01C MOVFF c, 0x1D
-03E2 F01D NOP
-03E4 0E0F MOVLW 0xF
-03E6 161D ANDWF 0x1D, F, ACCESS
-03E8 C01A MOVFF p1, FSR2
-03EA FFD9 NOP
-03EC C01B MOVFF pkt, FSR2H
-03EE FFDA NOP
-03F0 50DF MOVF INDF2, W, ACCESS
-03F2 181D XORWF 0x1D, W, ACCESS
-03F4 0BF0 ANDLW 0xF0
-03F6 181D XORWF 0x1D, W, ACCESS
-03F8 6EDF MOVWF INDF2, ACCESS
-03FA 0012 RETURN 0
+057C C062 MOVFF c, 0x63
+057E F063 NOP
+0580 0E0F MOVLW 0xF
+0582 1763 ANDWF 0x63, F, BANKED
+0584 C060 MOVFF __pcstackBANK0, FSR2
+0586 FFD9 NOP
+0588 C061 MOVFF pkt, FSR2H
+058A FFDA NOP
+058C 50DF MOVF INDF2, W, ACCESS
+058E 1963 XORWF 0x63, W, BANKED
+0590 0BF0 ANDLW 0xF0
+0592 1963 XORWF 0x63, W, BANKED
+0594 6EDF MOVWF INDF2, ACCESS
+0596 0012 RETURN 0
47:
48: return 0;
49: }
@@ -180,29 +182,30 @@ Z:/SAMB_4/projects/xilofono/src/dist/default/production/src.production.elf
51: int midi_set_channel(midi_message_t *pkt, unsigned channel)
52: {
53: if (pkt == NULL) {
-03B2 501A MOVF p1, W, ACCESS
-03B4 101B IORWF pkt, W, ACCESS
-03B6 B4D8 BTFSC STATUS, 2, ACCESS
-03B8 0012 RETURN 0
+054A 0100 MOVLB 0x0
+054C 5160 MOVF __pcstackBANK0, W, BANKED
+054E 1161 IORWF pkt, W, BANKED
+0550 B4D8 BTFSC STATUS, 2, ACCESS
+0552 0012 RETURN 0
54: return -1;
55: }
56:
57: pkt->channel = channel & 0x0F;
-03BA C01C MOVFF c, n
-03BC F01E NOP
-03BE 0E0F MOVLW 0xF
-03C0 161E ANDWF n, F, ACCESS
-03C2 C01A MOVFF p1, FSR2
-03C4 FFD9 NOP
-03C6 C01B MOVFF pkt, FSR2H
-03C8 FFDA NOP
-03CA 3A1E SWAPF n, F, ACCESS
-03CC 50DF MOVF INDF2, W, ACCESS
-03CE 181E XORWF n, W, ACCESS
-03D0 0B0F ANDLW 0xF
-03D2 181E XORWF n, W, ACCESS
-03D4 6EDF MOVWF INDF2, ACCESS
-03D6 0012 RETURN 0
+0554 C062 MOVFF c, n
+0556 F064 NOP
+0558 0E0F MOVLW 0xF
+055A 1764 ANDWF n, F, BANKED
+055C C060 MOVFF __pcstackBANK0, FSR2
+055E FFD9 NOP
+0560 C061 MOVFF pkt, FSR2H
+0562 FFDA NOP
+0564 3B64 SWAPF n, F, BANKED
+0566 50DF MOVF INDF2, W, ACCESS
+0568 1964 XORWF n, W, BANKED
+056A 0B0F ANDLW 0xF
+056C 1964 XORWF n, W, BANKED
+056E 6EDF MOVWF INDF2, ACCESS
+0570 0012 RETURN 0
58:
59: return 0;
60: }
@@ -210,108 +213,103 @@ Z:/SAMB_4/projects/xilofono/src/dist/default/production/src.production.elf
62: int midi_note_on(midi_message_t *pkt, unsigned channel, midi_note_t note, uint8_t velocity)
63: {
64: if (pkt == NULL) {
-01BC 501F MOVF pkt, W, ACCESS
-01BE 1020 IORWF p, W, ACCESS
-01C0 B4D8 BTFSC STATUS, 2, ACCESS
-01C2 0012 RETURN 0
+0424 0100 MOVLB 0x0
+0426 5165 MOVF pkt, W, BANKED
+0428 1166 IORWF p, W, BANKED
+042A B4D8 BTFSC STATUS, 2, ACCESS
+042C 0012 RETURN 0
65: return -1;
66: }
-67:
-68: if (pkt->data == NULL) {
-01C4 0E03 MOVLW 0x3
-01C6 241F ADDWF pkt, W, ACCESS
-01C8 0100 MOVLB 0x0
-01CA 6F60 MOVWF __pcstackBANK0, BANKED
-01CC 0E00 MOVLW 0x0
-01CE 2020 ADDWFC p, W, ACCESS
-01D0 6F61 MOVWF 0x61, BANKED
-01D2 5160 MOVF __pcstackBANK0, W, BANKED
-01D4 1161 IORWF 0x61, W, BANKED
-01D6 B4D8 BTFSC STATUS, 2, ACCESS
-01D8 0012 RETURN 0
-69: return -2;
-70: }
-71:
-72: midi_set_status(pkt, NOTE_ON);
-01DA C01F MOVFF pkt, p1
-01DC F01A NOP
-01DE C020 MOVFF p, pkt
-01E0 F01B NOP
-01E2 0E08 MOVLW 0x8
-01E4 6E1C MOVWF c, ACCESS
-01E6 ECEC CALL 0x3D8, 0
-01E8 F001 NOP
-73: midi_set_channel(pkt, channel);
-01EA C01F MOVFF pkt, p1
-01EC F01A NOP
-01EE C020 MOVFF p, pkt
-01F0 F01B NOP
-01F2 C021 MOVFF channel, c
-01F4 F01C NOP
-01F6 C022 MOVFF 0x22, 0x1D
-01F8 F01D NOP
-01FA ECD9 CALL 0x3B2, 0
-01FC F001 NOP
-74:
-75: pkt->data[0] = note;
-01FE EE20 LFSR 2, 0x3
-0200 F003 NOP
-0202 501F MOVF pkt, W, ACCESS
-0204 26D9 ADDWF FSR2, F, ACCESS
-0206 5020 MOVF p, W, ACCESS
-0208 22DA ADDWFC FSR2H, F, ACCESS
-020A C023 MOVFF note, INDF2
-020C FFDF NOP
-76: pkt->data[1] = velocity;
-020E EE20 LFSR 2, 0x4
-0210 F004 NOP
-0212 501F MOVF pkt, W, ACCESS
-0214 26D9 ADDWF FSR2, F, ACCESS
-0216 5020 MOVF p, W, ACCESS
-0218 22DA ADDWFC FSR2H, F, ACCESS
-021A C024 MOVFF velocity, INDF2
-021C FFDF NOP
-77:
-78: #ifndef MIDI_DYNAMIC_MEMORY_ALLOC
-79: pkt->data_size = 2;
-021E EE20 LFSR 2, 0x1
-0220 F001 NOP
-0222 501F MOVF pkt, W, ACCESS
-0224 26D9 ADDWF FSR2, F, ACCESS
-0226 5020 MOVF p, W, ACCESS
-0228 22DA ADDWFC FSR2H, F, ACCESS
-022A 0E02 MOVLW 0x2
-022C 6EDE MOVWF POSTINC2, ACCESS
-022E 0E00 MOVLW 0x0
-0230 6EDD MOVWF POSTDEC2, ACCESS
-0232 0012 RETURN 0
-80: #endif
-81:
-82: return 0;
-83: }
-84:
-85: int midi_note_off(midi_message_t *pkt, unsigned channel, midi_note_t note, uint8_t velocity)
-86: {
-87: if (pkt == NULL) {
-88: return -1;
-89: }
-90:
-91: if (pkt->data == NULL) {
-92: return -2;
-93: }
-94:
-95: midi_set_status(pkt, NOTE_OFF);
-96: midi_set_channel(pkt, channel);
-97:
-98: pkt->data[0] = note;
-99: pkt->data[1] = velocity;
-100:
-101: #ifndef MIDI_DYNAMIC_MEMORY_ALLOC
-102: pkt->data_size = 2;
-103: #endif
+67:
+68: #ifdef MIDI_DYNAMIC_MEMORY_ALLOC
+69: if (pkt->data == NULL) {
+70: return -2;
+71: }
+72: #endif
+73:
+74: midi_set_status(pkt, NOTE_ON);
+042E C065 MOVFF pkt, __pcstackBANK0
+0430 F060 NOP
+0432 C066 MOVFF p, pkt
+0434 F061 NOP
+0436 0E08 MOVLW 0x8
+0438 6F62 MOVWF c, BANKED
+043A ECB9 CALL 0x572, 0
+043C F002 NOP
+75: midi_set_channel(pkt, channel);
+043E C065 MOVFF pkt, __pcstackBANK0
+0440 F060 NOP
+0442 C066 MOVFF p, pkt
+0444 F061 NOP
+0446 C067 MOVFF channel, c
+0448 F062 NOP
+044A C068 MOVFF 0x68, 0x63
+044C F063 NOP
+044E ECA5 CALL 0x54A, 0
+0450 F002 NOP
+76:
+77: pkt->data[0] = note;
+0452 0100 MOVLB 0x0
+0454 EE20 LFSR 2, 0x3
+0456 F003 NOP
+0458 5165 MOVF pkt, W, BANKED
+045A 26D9 ADDWF FSR2, F, ACCESS
+045C 5166 MOVF p, W, BANKED
+045E 22DA ADDWFC FSR2H, F, ACCESS
+0460 C069 MOVFF note, INDF2
+0462 FFDF NOP
+78: pkt->data[1] = velocity;
+0464 EE20 LFSR 2, 0x4
+0466 F004 NOP
+0468 5165 MOVF pkt, W, BANKED
+046A 26D9 ADDWF FSR2, F, ACCESS
+046C 5166 MOVF p, W, BANKED
+046E 22DA ADDWFC FSR2H, F, ACCESS
+0470 C06A MOVFF velocity, INDF2
+0472 FFDF NOP
+79:
+80: #ifndef MIDI_DYNAMIC_MEMORY_ALLOC
+81: pkt->data_size = 2;
+0474 EE20 LFSR 2, 0x1
+0476 F001 NOP
+0478 5165 MOVF pkt, W, BANKED
+047A 26D9 ADDWF FSR2, F, ACCESS
+047C 5166 MOVF p, W, BANKED
+047E 22DA ADDWFC FSR2H, F, ACCESS
+0480 0E02 MOVLW 0x2
+0482 6EDE MOVWF POSTINC2, ACCESS
+0484 0E00 MOVLW 0x0
+0486 6EDD MOVWF POSTDEC2, ACCESS
+0488 0012 RETURN 0
+82: #endif
+83:
+84: return 0;
+85: }
+86:
+87: int midi_note_off(midi_message_t *pkt, unsigned channel, midi_note_t note, uint8_t velocity)
+88: {
+89: if (pkt == NULL) {
+90: return -1;
+91: }
+92:
+93: #ifdef MIDI_DYNAMIC_MEMORY_ALLOC
+94: if (pkt->data == NULL) {
+95: return -2;
+96: }
+97: #endif
+98:
+99: midi_set_status(pkt, NOTE_OFF);
+100: midi_set_channel(pkt, channel);
+101:
+102: pkt->data[0] = note;
+103: pkt->data[1] = velocity;
104:
-105: return 0;
-106: }
+105: #ifndef MIDI_DYNAMIC_MEMORY_ALLOC
+106: pkt->data_size = 2;
+107: #endif
+108:
+109: return 0;
+110: }
--- Z:/SAMB_4/projects/xilofono/src/main.c ------------------------------------------------------------
1: /*
2: * File: main.c
@@ -402,487 +400,715 @@ Z:/SAMB_4/projects/xilofono/src/dist/default/production/src.production.elf
87: #include <stdint.h>
88: #include <string.h>
89:
-90: #define NOTES 15
+90: #define NOTES 16
91: #define NOTE_MASK 0xFF00
92:
-93:
-94: /* global variables */
-95: volatile uint16_t keypresses[NOTES];
-96:
-97: /* function prototypes */
-98: int eusart_write_midi(const midi_message_t *pkt);
+93: #define MIDI_CHANNEL 0x0
+94: #define MIDI_SCALE_START 0x3C
+95:
+96: /* global variables */
+97: volatile uint16_t keys_data[NOTES];
+98: volatile uint16_t keypresses = 0; // flags to notify the main program
99:
-100: /* interrupt service routine */
-101: interrupt void isr(void)
+100: /* function prototypes */
+101: int eusart_write_midi(const midi_message_t *pkt);
+102:
+103: /* interrupt service routine */
+104: interrupt void isr(void)
0008 8245 BSF btemp, 1, ACCESS
-102: {
-103: unsigned char i, data;
-104:
-105: PORTDbits.RD3 = 0;
+105: {
+106: unsigned char i, data_a, data_b;
+107:
+108: PORTDbits.RD3 = 0;
0052 9683 BCF PORTD, 3, ACCESS
-106:
-107: if (PIR1bits.TMR2IF) {
+109:
+110: if (PIR1bits.TMR2IF) {
0054 A29E BTFSS PIR1, 1, ACCESS
-0056 D089 BRA 0x16A
-108: // PORTA
-109: data = PORTA;
-0058 CF80 MOVFF PORTA, data
-005A F018 NOP
-110: i = 7;
-005C 0E07 MOVLW 0x7
-005E 6E19 MOVWF i, ACCESS
-111: do {
-112: keypresses[i] = (keypresses[i] << 1) | ((data >> i) & 0x01);
-0060 5019 MOVF i, W, ACCESS
-0062 0D02 MULLW 0x2
-0064 0E25 MOVLW 0x25
-0066 24F3 ADDWF PROD, W, ACCESS
-0068 6ED9 MOVWF FSR2, ACCESS
-006A 0E00 MOVLW 0x0
-006C 20F4 ADDWFC PRODH, W, ACCESS
-006E 6EDA MOVWF FSR2H, ACCESS
-0070 CFDE MOVFF POSTINC2, __pcstackCOMRAM
-0072 F001 NOP
-0074 CFDD MOVFF POSTDEC2, 0x2
-0076 F002 NOP
-0078 90D8 BCF STATUS, 0, ACCESS
-007A 3601 RLCF __pcstackCOMRAM, F, ACCESS
-007C 3602 RLCF 0x2, F, ACCESS
-007E C019 MOVFF i, 0x3
-0080 F003 NOP
-0082 C018 MOVFF data, 0x4
-0084 F004 NOP
-0086 2A03 INCF 0x3, F, ACCESS
-0088 D002 BRA 0x8E
-008A 90D8 BCF STATUS, 0, ACCESS
-008C 3204 RRCF 0x4, F, ACCESS
-008E 2E03 DECFSZ 0x3, F, ACCESS
-0090 D7FC BRA 0x8A
-0092 0E01 MOVLW 0x1
-0094 1604 ANDWF 0x4, F, ACCESS
-0096 5004 MOVF 0x4, W, ACCESS
-0098 1201 IORWF __pcstackCOMRAM, F, ACCESS
-009A 0E00 MOVLW 0x0
-009C 1202 IORWF 0x2, F, ACCESS
-009E 5019 MOVF i, W, ACCESS
-00A0 0D02 MULLW 0x2
-00A2 0E25 MOVLW 0x25
-00A4 24F3 ADDWF PROD, W, ACCESS
-00A6 6ED9 MOVWF FSR2, ACCESS
-00A8 0E00 MOVLW 0x0
-00AA 20F4 ADDWFC PRODH, W, ACCESS
-00AC 6EDA MOVWF FSR2H, ACCESS
-00AE C001 MOVFF __pcstackCOMRAM, POSTINC2
-00B0 FFDE NOP
-00B2 C002 MOVFF 0x2, POSTDEC2
-00B4 FFDD NOP
-113: } while (i--);
-00B6 0619 DECF i, F, ACCESS
-00B8 2819 INCF i, W, ACCESS
-00BA A4D8 BTFSS STATUS, 2, ACCESS
-00BC D7D1 BRA 0x60
-114:
-115: data = PORTB;
-00BE CF81 MOVFF PORTB, data
-00C0 F018 NOP
-116: i = 7;
-00C2 0E07 MOVLW 0x7
-00C4 6E19 MOVWF i, ACCESS
-117: do {
-118: keypresses[i] = (keypresses[i] << 1) | ((data >> i) & 0x01);
-00C6 5019 MOVF i, W, ACCESS
-00C8 0D02 MULLW 0x2
-00CA 0E25 MOVLW 0x25
-00CC 24F3 ADDWF PROD, W, ACCESS
-00CE 6ED9 MOVWF FSR2, ACCESS
-00D0 0E00 MOVLW 0x0
-00D2 20F4 ADDWFC PRODH, W, ACCESS
-00D4 6EDA MOVWF FSR2H, ACCESS
-00D6 CFDE MOVFF POSTINC2, __pcstackCOMRAM
-00D8 F001 NOP
-00DA CFDD MOVFF POSTDEC2, 0x2
-00DC F002 NOP
-00DE 90D8 BCF STATUS, 0, ACCESS
-00E0 3601 RLCF __pcstackCOMRAM, F, ACCESS
-00E2 3602 RLCF 0x2, F, ACCESS
-00E4 C019 MOVFF i, 0x3
-00E6 F003 NOP
-00E8 C018 MOVFF data, 0x4
-00EA F004 NOP
-00EC 2A03 INCF 0x3, F, ACCESS
-00EE D002 BRA 0xF4
-00F0 90D8 BCF STATUS, 0, ACCESS
-00F2 3204 RRCF 0x4, F, ACCESS
-00F4 2E03 DECFSZ 0x3, F, ACCESS
-00F6 D7FC BRA 0xF0
-00F8 0E01 MOVLW 0x1
-00FA 1604 ANDWF 0x4, F, ACCESS
-00FC 5004 MOVF 0x4, W, ACCESS
-00FE 1201 IORWF __pcstackCOMRAM, F, ACCESS
-0100 0E00 MOVLW 0x0
-0102 1202 IORWF 0x2, F, ACCESS
-0104 5019 MOVF i, W, ACCESS
-0106 0D02 MULLW 0x2
-0108 0E25 MOVLW 0x25
-010A 24F3 ADDWF PROD, W, ACCESS
-010C 6ED9 MOVWF FSR2, ACCESS
-010E 0E00 MOVLW 0x0
-0110 20F4 ADDWFC PRODH, W, ACCESS
-0112 6EDA MOVWF FSR2H, ACCESS
-0114 C001 MOVFF __pcstackCOMRAM, POSTINC2
-0116 FFDE NOP
-0118 C002 MOVFF 0x2, POSTDEC2
-011A FFDD NOP
-119: } while (i-- - 8);
-011C 0EF8 MOVLW 0xF8
-011E 6E01 MOVWF __pcstackCOMRAM, ACCESS
-0120 0EFF MOVLW 0xFF
-0122 6E02 MOVWF 0x2, ACCESS
-0124 0619 DECF i, F, ACCESS
-0126 2819 INCF i, W, ACCESS
-0128 6E03 MOVWF 0x3, ACCESS
-012A 6A04 CLRF 0x4, ACCESS
-012C 5001 MOVF __pcstackCOMRAM, W, ACCESS
-012E 2603 ADDWF 0x3, F, ACCESS
-0130 5002 MOVF 0x2, W, ACCESS
-0132 2204 ADDWFC 0x4, F, ACCESS
-0134 5003 MOVF 0x3, W, ACCESS
-0136 1004 IORWF 0x4, W, ACCESS
-0138 A4D8 BTFSS STATUS, 2, ACCESS
-013A D7C5 BRA 0xC6
-120:
-121: // PORTB
-122: // for (i = 8; i < NOTES; i++) {
-123: // keypresses[i] = (keypresses[i] << 1) | ((PORTB & (1 << i)) >> i);
-124: // }
-125:
-126: // TODO same for PORTD when the steps board is printed
-127:
-128: // debug stuff
-129: PORTDbits.RD4 = PORTAbits.RA0;
-013C A080 BTFSS PORTA, 0, ACCESS
-013E D002 BRA 0x144
-0140 8883 BSF PORTD, 4, ACCESS
-0142 D001 BRA 0x146
-0144 9883 BCF PORTD, 4, ACCESS
-130: PORTDbits.RD2 = (keypresses[0] && !(keypresses[0] & NOTE_MASK));
-0146 0E00 MOVLW 0x0
-0148 6E17 MOVWF 0x17, ACCESS
-014A 5025 MOVF keypresses, W, ACCESS
-014C 1026 IORWF 0x26, W, ACCESS
-014E B4D8 BTFSC STATUS, 2, ACCESS
-0150 D006 BRA 0x15E
-0152 0EFF MOVLW 0xFF
-0154 1426 ANDWF 0x26, W, ACCESS
+0056 D11F BRA 0x296
+111: data_a = PORTA;
+0058 CF80 MOVFF PORTA, data_a
+005A F03D NOP
+112: data_b = PORTB;
+005C CF81 MOVFF PORTB, data_b
+005E F03E NOP
+113: i = 7;
+0060 0E07 MOVLW 0x7
+0062 6E42 MOVWF i, ACCESS
+114: do {
+115: // read the data and append it at the end of keys_data[i]
+116: keys_data[i] = (keys_data[i] << 1) | ((data_a >> i) & 0x01);
+0064 5042 MOVF i, W, ACCESS
+0066 0D02 MULLW 0x2
+0068 0E03 MOVLW 0x3
+006A 24F3 ADDWF PROD, W, ACCESS
+006C 6ED9 MOVWF FSR2, ACCESS
+006E 0E00 MOVLW 0x0
+0070 20F4 ADDWFC PRODH, W, ACCESS
+0072 6EDA MOVWF FSR2H, ACCESS
+0074 CFDE MOVFF POSTINC2, __pcstackCOMRAM
+0076 F023 NOP
+0078 CFDD MOVFF POSTDEC2, 0x24
+007A F024 NOP
+007C 90D8 BCF STATUS, 0, ACCESS
+007E 3623 RLCF __pcstackCOMRAM, F, ACCESS
+0080 3624 RLCF 0x24, F, ACCESS
+0082 C042 MOVFF i, 0x25
+0084 F025 NOP
+0086 C03D MOVFF data_a, 0x26
+0088 F026 NOP
+008A 2A25 INCF 0x25, F, ACCESS
+008C D002 BRA 0x92
+008E 90D8 BCF STATUS, 0, ACCESS
+0090 3226 RRCF 0x26, F, ACCESS
+0092 2E25 DECFSZ 0x25, F, ACCESS
+0094 D7FC BRA 0x8E
+0096 0E01 MOVLW 0x1
+0098 1626 ANDWF 0x26, F, ACCESS
+009A 5026 MOVF 0x26, W, ACCESS
+009C 1223 IORWF __pcstackCOMRAM, F, ACCESS
+009E 0E00 MOVLW 0x0
+00A0 1224 IORWF 0x24, F, ACCESS
+00A2 5042 MOVF i, W, ACCESS
+00A4 0D02 MULLW 0x2
+00A6 0E03 MOVLW 0x3
+00A8 24F3 ADDWF PROD, W, ACCESS
+00AA 6ED9 MOVWF FSR2, ACCESS
+00AC 0E00 MOVLW 0x0
+00AE 20F4 ADDWFC PRODH, W, ACCESS
+00B0 6EDA MOVWF FSR2H, ACCESS
+00B2 C023 MOVFF __pcstackCOMRAM, POSTINC2
+00B4 FFDE NOP
+00B6 C024 MOVFF 0x24, POSTDEC2
+00B8 FFDD NOP
+117: keys_data[i + 8] = (keys_data[i + 8] << 1) | ((data_b >> i) & 0x01);
+00BA 5042 MOVF i, W, ACCESS
+00BC 6E23 MOVWF __pcstackCOMRAM, ACCESS
+00BE 6A24 CLRF 0x24, ACCESS
+00C0 90D8 BCF STATUS, 0, ACCESS
+00C2 3623 RLCF __pcstackCOMRAM, F, ACCESS
+00C4 3624 RLCF 0x24, F, ACCESS
+00C6 0E10 MOVLW 0x10
+00C8 2623 ADDWF __pcstackCOMRAM, F, ACCESS
+00CA 0E00 MOVLW 0x0
+00CC 2224 ADDWFC 0x24, F, ACCESS
+00CE 0E03 MOVLW 0x3
+00D0 2423 ADDWF __pcstackCOMRAM, W, ACCESS
+00D2 6ED9 MOVWF FSR2, ACCESS
+00D4 0E00 MOVLW 0x0
+00D6 2024 ADDWFC 0x24, W, ACCESS
+00D8 6EDA MOVWF FSR2H, ACCESS
+00DA CFDE MOVFF POSTINC2, 0x25
+00DC F025 NOP
+00DE CFDD MOVFF POSTDEC2, 0x26
+00E0 F026 NOP
+00E2 90D8 BCF STATUS, 0, ACCESS
+00E4 3625 RLCF 0x25, F, ACCESS
+00E6 3626 RLCF 0x26, F, ACCESS
+00E8 C042 MOVFF i, 0x27
+00EA F027 NOP
+00EC C03E MOVFF data_b, 0x28
+00EE F028 NOP
+00F0 2A27 INCF 0x27, F, ACCESS
+00F2 D002 BRA 0xF8
+00F4 90D8 BCF STATUS, 0, ACCESS
+00F6 3228 RRCF 0x28, F, ACCESS
+00F8 2E27 DECFSZ 0x27, F, ACCESS
+00FA D7FC BRA 0xF4
+00FC 0E01 MOVLW 0x1
+00FE 1628 ANDWF 0x28, F, ACCESS
+0100 5028 MOVF 0x28, W, ACCESS
+0102 1225 IORWF 0x25, F, ACCESS
+0104 0E00 MOVLW 0x0
+0106 1226 IORWF 0x26, F, ACCESS
+0108 5042 MOVF i, W, ACCESS
+010A 6E29 MOVWF 0x29, ACCESS
+010C 6A2A CLRF 0x2A, ACCESS
+010E 90D8 BCF STATUS, 0, ACCESS
+0110 3629 RLCF 0x29, F, ACCESS
+0112 362A RLCF 0x2A, F, ACCESS
+0114 0E10 MOVLW 0x10
+0116 2629 ADDWF 0x29, F, ACCESS
+0118 0E00 MOVLW 0x0
+011A 222A ADDWFC 0x2A, F, ACCESS
+011C 0E03 MOVLW 0x3
+011E 2429 ADDWF 0x29, W, ACCESS
+0120 6ED9 MOVWF FSR2, ACCESS
+0122 0E00 MOVLW 0x0
+0124 202A ADDWFC 0x2A, W, ACCESS
+0126 6EDA MOVWF FSR2H, ACCESS
+0128 C025 MOVFF 0x25, POSTINC2
+012A FFDE NOP
+012C C026 MOVFF 0x26, POSTDEC2
+012E FFDD NOP
+118:
+119: // TODO same for PORTD when the steps board is printed
+120:
+121: // if the keypress flag is set, the main hasn't sent the packet (yet)
+122: if (!(keypresses & (1<<i))) {
+0130 C042 MOVFF i, __pcstackCOMRAM
+0132 F023 NOP
+0134 0E01 MOVLW 0x1
+0136 6E24 MOVWF 0x24, ACCESS
+0138 0E00 MOVLW 0x0
+013A 6E25 MOVWF 0x25, ACCESS
+013C 2A23 INCF __pcstackCOMRAM, F, ACCESS
+013E D003 BRA 0x146
+0140 90D8 BCF STATUS, 0, ACCESS
+0142 3624 RLCF 0x24, F, ACCESS
+0144 3625 RLCF 0x25, F, ACCESS
+0146 2E23 DECFSZ __pcstackCOMRAM, F, ACCESS
+0148 D7FB BRA 0x140
+014A 5001 MOVF keypresses, W, ACCESS
+014C 1624 ANDWF 0x24, F, ACCESS
+014E 5002 MOVF 0x2, W, ACCESS
+0150 1625 ANDWF 0x25, F, ACCESS
+0152 5024 MOVF 0x24, W, ACCESS
+0154 1025 IORWF 0x25, W, ACCESS
0156 A4D8 BTFSS STATUS, 2, ACCESS
-0158 D002 BRA 0x15E
-015A 0E01 MOVLW 0x1
-015C 6E17 MOVWF 0x17, ACCESS
-015E B017 BTFSC 0x17, 0, ACCESS
-0160 D002 BRA 0x166
-0162 9483 BCF PORTD, 2, ACCESS
-0164 D001 BRA 0x168
-0166 8483 BSF PORTD, 2, ACCESS
-131:
-132: // reset interrupt flag
-133: PIR1bits.TMR2IF = 0;
-0168 929E BCF PIR1, 1, ACCESS
-134: }
-135:
-136: PORTDbits.RD3 = 1;
-016A 8683 BSF PORTD, 3, ACCESS
-137: }
-016C C016 MOVFF 0x16, 0x48
-016E F048 NOP
-0170 C015 MOVFF 0x15, 0x47
-0172 F047 NOP
-0174 C014 MOVFF 0x14, 0x46
-0176 F046 NOP
-0178 C013 MOVFF 0x13, btemp
-017A F045 NOP
-017C C012 MOVFF 0x12, TABLAT
-017E FFF5 NOP
-0180 C011 MOVFF 0x11, TBLPTRU
-0182 FFF8 NOP
-0184 C010 MOVFF 0x10, TBLPTRH
-0186 FFF7 NOP
-0188 C00F MOVFF 0xF, TBLPTR
-018A FFF6 NOP
-018C C00E MOVFF 0xE, PRODH
-018E FFF4 NOP
-0190 C00D MOVFF 0xD, PROD
-0192 FFF3 NOP
-0194 C00C MOVFF 0xC, FSR2H
-0196 FFDA NOP
-0198 C00B MOVFF 0xB, FSR2
-019A FFD9 NOP
-019C C00A MOVFF 0xA, FSR1H
-019E FFE2 NOP
-01A0 C009 MOVFF 0x9, FSR1
-01A2 FFE1 NOP
-01A4 C008 MOVFF 0x8, FSR0H
-01A6 FFEA NOP
-01A8 C007 MOVFF 0x7, FSR0
-01AA FFE9 NOP
-01AC C006 MOVFF 0x6, PCLATU
-01AE FFFB NOP
-01B0 C005 MOVFF 0x5, PCLATH
-01B2 FFFA NOP
-01B4 9245 BCF btemp, 1, ACCESS
-01B6 0011 RETFIE 1
-138:
-139: /* hardware configuration (inlined) */
-140: inline void init_hw(void)
-141: {
-142: di();
-02A8 9EF2 BCF INTCON, 7, ACCESS
-143:
-144: /* PLL / FOSC configuration */
-145: // enable PLL
-146: OSCTUNEbits.PLLEN = 1;
-02AA 8C9B BSF OSCTUNE, 6, ACCESS
-147: // set FOSC to HFINTOSC (max frequency)
-148: OSCTUNEbits.TUN = 0b011111;
-02AC 809B BSF OSCTUNE, 0, ACCESS
-02AE 829B BSF OSCTUNE, 1, ACCESS
-02B0 849B BSF OSCTUNE, 2, ACCESS
-02B2 869B BSF OSCTUNE, 3, ACCESS
-02B4 889B BSF OSCTUNE, 4, ACCESS
-02B6 9A9B BCF OSCTUNE, 5, ACCESS
-149: // set 16 MHz oscillator, datasheet p.30
-150: OSCCONbits.IRCF = 0b111;
-02B8 88D3 BSF OSCCON, 4, ACCESS
-02BA 8AD3 BSF OSCCON, 5, ACCESS
-02BC 8CD3 BSF OSCCON, 6, ACCESS
-151: // select primary clock (with PLL)
-152: OSCCONbits.SCS = 0b00;
-02BE 0EFC MOVLW 0xFC
-02C0 16D3 ANDWF OSCCON, F, ACCESS
-153:
-154: /* i/o initializazion */
-155: // disable all ADCs
-156: ANSELA = 0x00;
-02C2 0E00 MOVLW 0x0
-02C4 010F MOVLB 0xF
-02C6 6F38 MOVWF 0x38, BANKED
-157: ANSELB = 0x00;
-02C8 0E00 MOVLW 0x0
-02CA 6F39 MOVWF 0x39, BANKED
-158: ANSELC = 0x00;
-02CC 0E00 MOVLW 0x0
-02CE 6F3A MOVWF 0x3A, BANKED
-159: ANSELD = 0x00;
-02D0 0E00 MOVLW 0x0
-02D2 6F3B MOVWF 0x3B, BANKED
-160:
-161: // TODO: remove demo
-162: TRISA = 0xFF;
-02D4 6892 SETF TRISA, ACCESS
-163: TRISB = 0xFF;
-02D6 6893 SETF TRISB, ACCESS
-164:
-165: TRISDbits.TRISD1 = 0;
-02D8 9295 BCF TRISD, 1, ACCESS
-166: TRISDbits.TRISD2 = 0;
-02DA 9495 BCF TRISD, 2, ACCESS
-167: TRISDbits.TRISD3 = 0;
-02DC 9695 BCF TRISD, 3, ACCESS
-168: TRISDbits.TRISD4 = 0;
-02DE 9895 BCF TRISD, 4, ACCESS
+0158 D02D BRA 0x1B4
+123: // if the flag is not set, check if it should be
+124: keypresses |= (keys_data[i] && !(keys_data[i] & NOTE_MASK))<<i;
+015A 0E00 MOVLW 0x0
+015C 6E3F MOVWF 0x3F, ACCESS
+015E 5042 MOVF i, W, ACCESS
+0160 0D02 MULLW 0x2
+0162 0E03 MOVLW 0x3
+0164 24F3 ADDWF PROD, W, ACCESS
+0166 6ED9 MOVWF FSR2, ACCESS
+0168 0E00 MOVLW 0x0
+016A 20F4 ADDWFC PRODH, W, ACCESS
+016C 6EDA MOVWF FSR2H, ACCESS
+016E 50DE MOVF POSTINC2, W, ACCESS
+0170 10DE IORWF POSTINC2, W, ACCESS
+0172 B4D8 BTFSC STATUS, 2, ACCESS
+0174 D00F BRA 0x194
+0176 5042 MOVF i, W, ACCESS
+0178 0D02 MULLW 0x2
+017A 0E03 MOVLW 0x3
+017C 24F3 ADDWF PROD, W, ACCESS
+017E 6ED9 MOVWF FSR2, ACCESS
+0180 0E00 MOVLW 0x0
+0182 20F4 ADDWFC PRODH, W, ACCESS
+0184 6EDA MOVWF FSR2H, ACCESS
+0186 52DE MOVF POSTINC2, F, ACCESS
+0188 0EFF MOVLW 0xFF
+018A 14DD ANDWF POSTDEC2, W, ACCESS
+018C A4D8 BTFSS STATUS, 2, ACCESS
+018E D002 BRA 0x194
+0190 0E01 MOVLW 0x1
+0192 6E3F MOVWF 0x3F, ACCESS
+0194 C042 MOVFF i, __pcstackCOMRAM
+0196 F023 NOP
+0198 503F MOVF 0x3F, W, ACCESS
+019A 6E24 MOVWF 0x24, ACCESS
+019C 6A25 CLRF 0x25, ACCESS
+019E 2A23 INCF __pcstackCOMRAM, F, ACCESS
+01A0 D003 BRA 0x1A8
+01A2 90D8 BCF STATUS, 0, ACCESS
+01A4 3624 RLCF 0x24, F, ACCESS
+01A6 3625 RLCF 0x25, F, ACCESS
+01A8 2E23 DECFSZ __pcstackCOMRAM, F, ACCESS
+01AA D7FB BRA 0x1A2
+01AC 5024 MOVF 0x24, W, ACCESS
+01AE 1201 IORWF keypresses, F, ACCESS
+01B0 5025 MOVF 0x25, W, ACCESS
+01B2 1202 IORWF 0x2, F, ACCESS
+125: }
+126:
+127: if (!(keypresses & (1<<(i + 8)))) {
+01B4 C042 MOVFF i, __pcstackCOMRAM
+01B6 F023 NOP
+01B8 0E08 MOVLW 0x8
+01BA 2623 ADDWF __pcstackCOMRAM, F, ACCESS
+01BC 0E01 MOVLW 0x1
+01BE 6E24 MOVWF 0x24, ACCESS
+01C0 0E00 MOVLW 0x0
+01C2 6E25 MOVWF 0x25, ACCESS
+01C4 2A23 INCF __pcstackCOMRAM, F, ACCESS
+01C6 D003 BRA 0x1CE
+01C8 90D8 BCF STATUS, 0, ACCESS
+01CA 3624 RLCF 0x24, F, ACCESS
+01CC 3625 RLCF 0x25, F, ACCESS
+01CE 2E23 DECFSZ __pcstackCOMRAM, F, ACCESS
+01D0 D7FB BRA 0x1C8
+01D2 5001 MOVF keypresses, W, ACCESS
+01D4 1624 ANDWF 0x24, F, ACCESS
+01D6 5002 MOVF 0x2, W, ACCESS
+01D8 1625 ANDWF 0x25, F, ACCESS
+01DA 5024 MOVF 0x24, W, ACCESS
+01DC 1025 IORWF 0x25, W, ACCESS
+01DE A4D8 BTFSS STATUS, 2, ACCESS
+01E0 D03F BRA 0x260
+128: keypresses |= (keys_data[i + 8] && !(keys_data[i + 8] & NOTE_MASK))<<(i + 8);
+01E2 0E00 MOVLW 0x0
+01E4 6E40 MOVWF 0x40, ACCESS
+01E6 5042 MOVF i, W, ACCESS
+01E8 6E23 MOVWF __pcstackCOMRAM, ACCESS
+01EA 6A24 CLRF 0x24, ACCESS
+01EC 90D8 BCF STATUS, 0, ACCESS
+01EE 3623 RLCF __pcstackCOMRAM, F, ACCESS
+01F0 3624 RLCF 0x24, F, ACCESS
+01F2 0E10 MOVLW 0x10
+01F4 2623 ADDWF __pcstackCOMRAM, F, ACCESS
+01F6 0E00 MOVLW 0x0
+01F8 2224 ADDWFC 0x24, F, ACCESS
+01FA 0E03 MOVLW 0x3
+01FC 2423 ADDWF __pcstackCOMRAM, W, ACCESS
+01FE 6ED9 MOVWF FSR2, ACCESS
+0200 0E00 MOVLW 0x0
+0202 2024 ADDWFC 0x24, W, ACCESS
+0204 6EDA MOVWF FSR2H, ACCESS
+0206 50DE MOVF POSTINC2, W, ACCESS
+0208 10DE IORWF POSTINC2, W, ACCESS
+020A B4D8 BTFSC STATUS, 2, ACCESS
+020C D017 BRA 0x23C
+020E 5042 MOVF i, W, ACCESS
+0210 6E23 MOVWF __pcstackCOMRAM, ACCESS
+0212 6A24 CLRF 0x24, ACCESS
+0214 90D8 BCF STATUS, 0, ACCESS
+0216 3623 RLCF __pcstackCOMRAM, F, ACCESS
+0218 3624 RLCF 0x24, F, ACCESS
+021A 0E10 MOVLW 0x10
+021C 2623 ADDWF __pcstackCOMRAM, F, ACCESS
+021E 0E00 MOVLW 0x0
+0220 2224 ADDWFC 0x24, F, ACCESS
+0222 0E03 MOVLW 0x3
+0224 2423 ADDWF __pcstackCOMRAM, W, ACCESS
+0226 6ED9 MOVWF FSR2, ACCESS
+0228 0E00 MOVLW 0x0
+022A 2024 ADDWFC 0x24, W, ACCESS
+022C 6EDA MOVWF FSR2H, ACCESS
+022E 52DE MOVF POSTINC2, F, ACCESS
+0230 0EFF MOVLW 0xFF
+0232 14DD ANDWF POSTDEC2, W, ACCESS
+0234 A4D8 BTFSS STATUS, 2, ACCESS
+0236 D002 BRA 0x23C
+0238 0E01 MOVLW 0x1
+023A 6E40 MOVWF 0x40, ACCESS
+023C C042 MOVFF i, __pcstackCOMRAM
+023E F023 NOP
+0240 0E08 MOVLW 0x8
+0242 2623 ADDWF __pcstackCOMRAM, F, ACCESS
+0244 5040 MOVF 0x40, W, ACCESS
+0246 6E24 MOVWF 0x24, ACCESS
+0248 6A25 CLRF 0x25, ACCESS
+024A 2A23 INCF __pcstackCOMRAM, F, ACCESS
+024C D003 BRA 0x254
+024E 90D8 BCF STATUS, 0, ACCESS
+0250 3624 RLCF 0x24, F, ACCESS
+0252 3625 RLCF 0x25, F, ACCESS
+0254 2E23 DECFSZ __pcstackCOMRAM, F, ACCESS
+0256 D7FB BRA 0x24E
+0258 5024 MOVF 0x24, W, ACCESS
+025A 1201 IORWF keypresses, F, ACCESS
+025C 5025 MOVF 0x25, W, ACCESS
+025E 1202 IORWF 0x2, F, ACCESS
+129: }
+130: } while (i--);
+0260 0642 DECF i, F, ACCESS
+0262 2842 INCF i, W, ACCESS
+0264 A4D8 BTFSS STATUS, 2, ACCESS
+0266 D6FE BRA 0x64
+131:
+132:
+133: // debug stuff
+134: PORTDbits.RD4 = PORTAbits.RA0;
+0268 A080 BTFSS PORTA, 0, ACCESS
+026A D002 BRA 0x270
+026C 8883 BSF PORTD, 4, ACCESS
+026E D001 BRA 0x272
+0270 9883 BCF PORTD, 4, ACCESS
+135: PORTDbits.RD2 = (keys_data[0] && !(keys_data[0] & NOTE_MASK));
+0272 0E00 MOVLW 0x0
+0274 6E41 MOVWF 0x41, ACCESS
+0276 5003 MOVF keys_data, W, ACCESS
+0278 1004 IORWF 0x4, W, ACCESS
+027A B4D8 BTFSC STATUS, 2, ACCESS
+027C D006 BRA 0x28A
+027E 0EFF MOVLW 0xFF
+0280 1404 ANDWF 0x4, W, ACCESS
+0282 A4D8 BTFSS STATUS, 2, ACCESS
+0284 D002 BRA 0x28A
+0286 0E01 MOVLW 0x1
+0288 6E41 MOVWF 0x41, ACCESS
+028A B041 BTFSC 0x41, 0, ACCESS
+028C D002 BRA 0x292
+028E 9483 BCF PORTD, 2, ACCESS
+0290 D001 BRA 0x294
+0292 8483 BSF PORTD, 2, ACCESS
+136:
+137: // reset interrupt flag
+138: PIR1bits.TMR2IF = 0;
+0294 929E BCF PIR1, 1, ACCESS
+139: }
+140:
+141: PORTDbits.RD3 = 1;
+0296 8683 BSF PORTD, 3, ACCESS
+142: }
+0298 C03C MOVFF 0x3C, 0x48
+029A F048 NOP
+029C C03B MOVFF 0x3B, 0x47
+029E F047 NOP
+02A0 C03A MOVFF 0x3A, 0x46
+02A2 F046 NOP
+02A4 C039 MOVFF 0x39, btemp
+02A6 F045 NOP
+02A8 C038 MOVFF 0x38, TABLAT
+02AA FFF5 NOP
+02AC C037 MOVFF 0x37, TBLPTRU
+02AE FFF8 NOP
+02B0 C036 MOVFF 0x36, TBLPTRH
+02B2 FFF7 NOP
+02B4 C035 MOVFF 0x35, TBLPTR
+02B6 FFF6 NOP
+02B8 C034 MOVFF 0x34, PRODH
+02BA FFF4 NOP
+02BC C033 MOVFF 0x33, PROD
+02BE FFF3 NOP
+02C0 C032 MOVFF 0x32, FSR2H
+02C2 FFDA NOP
+02C4 C031 MOVFF 0x31, FSR2
+02C6 FFD9 NOP
+02C8 C030 MOVFF 0x30, FSR1H
+02CA FFE2 NOP
+02CC C02F MOVFF 0x2F, FSR1
+02CE FFE1 NOP
+02D0 C02E MOVFF 0x2E, FSR0H
+02D2 FFEA NOP
+02D4 C02D MOVFF 0x2D, FSR0
+02D6 FFE9 NOP
+02D8 C02C MOVFF 0x2C, PCLATU
+02DA FFFB NOP
+02DC C02B MOVFF 0x2B, PCLATH
+02DE FFFA NOP
+02E0 9245 BCF btemp, 1, ACCESS
+02E2 0011 RETFIE 1
+143:
+144: /* hardware configuration (inlined) */
+145: inline void init_hw(void)
+146: {
+147: di();
+048A 9EF2 BCF INTCON, 7, ACCESS
+148:
+149: /* PLL / FOSC configuration */
+150: // enable PLL
+151: OSCTUNEbits.PLLEN = 1;
+048C 8C9B BSF OSCTUNE, 6, ACCESS
+152: // set FOSC to HFINTOSC (max frequency)
+153: OSCTUNEbits.TUN = 0b011111;
+048E 809B BSF OSCTUNE, 0, ACCESS
+0490 829B BSF OSCTUNE, 1, ACCESS
+0492 849B BSF OSCTUNE, 2, ACCESS
+0494 869B BSF OSCTUNE, 3, ACCESS
+0496 889B BSF OSCTUNE, 4, ACCESS
+0498 9A9B BCF OSCTUNE, 5, ACCESS
+154: // set 16 MHz oscillator, datasheet p.30
+155: OSCCONbits.IRCF = 0b111;
+049A 88D3 BSF OSCCON, 4, ACCESS
+049C 8AD3 BSF OSCCON, 5, ACCESS
+049E 8CD3 BSF OSCCON, 6, ACCESS
+156: // select primary clock (with PLL)
+157: OSCCONbits.SCS = 0b00;
+04A0 0EFC MOVLW 0xFC
+04A2 16D3 ANDWF OSCCON, F, ACCESS
+158:
+159: /* i/o initializazion */
+160: // disable all ADCs
+161: ANSELA = 0x00;
+04A4 0E00 MOVLW 0x0
+04A6 010F MOVLB 0xF
+04A8 6F38 MOVWF 0x38, BANKED
+162: ANSELB = 0x00;
+04AA 0E00 MOVLW 0x0
+04AC 6F39 MOVWF 0x39, BANKED
+163: ANSELC = 0x00;
+04AE 0E00 MOVLW 0x0
+04B0 6F3A MOVWF 0x3A, BANKED
+164: ANSELD = 0x00;
+04B2 0E00 MOVLW 0x0
+04B4 6F3B MOVWF 0x3B, BANKED
+165:
+166: // TODO: remove demo
+167: TRISA = 0xFF;
+04B6 6892 SETF TRISA, ACCESS
+168: TRISB = 0xFF;
+04B8 6893 SETF TRISB, ACCESS
169:
-170: // LED
-171: PORTDbits.RD1 = 1;
-02E0 8283 BSF PORTD, 1, ACCESS
-172: // TEST OUTPUT 1
-173: PORTDbits.RD2 = 0;
-02E2 9483 BCF PORTD, 2, ACCESS
-174: // TEST OUTPUT 2
-175: PORTDbits.RD3 = 1;
-02E4 8683 BSF PORTD, 3, ACCESS
-176: // TEST OUTPUT 3
-177: PORTDbits.RD4 = 0;
-02E6 9883 BCF PORTD, 4, ACCESS
-178:
-179: /* timer configuration */
-180: // timer 2 comp value
-181: PR2 = 128;
-02E8 0E80 MOVLW 0x80
-02EA 6EBB MOVWF PR2, ACCESS
-182: // postscaler 1:4
-183: T2CONbits.T2OUTPS = 0b0011;
-02EC 50BA MOVF T2CON, W, ACCESS
-02EE 0B87 ANDLW 0x87
-02F0 0918 IORLW 0x18
-02F2 6EBA MOVWF T2CON, ACCESS
-184: // prescaler 1:16
-185: T2CONbits.T2CKPS = 0b11;
-02F4 0E03 MOVLW 0x3
-02F6 12BA IORWF T2CON, F, ACCESS
-186: // start timer
-187: T2CONbits.TMR2ON = 1;
-02F8 84BA BSF T2CON, 2, ACCESS
-188:
-189: // timer 2 interrupts
-190: PIE1bits.TMR2IE = 1;
-02FA 829D BSF PIE1, 1, ACCESS
-191: PIR1bits.TMR2IF = 0;
-02FC 929E BCF PIR1, 1, ACCESS
-192:
-193: // enable peripheral interrupts
-194: INTCONbits.PEIE = 1;
-02FE 8CF2 BSF INTCON, 6, ACCESS
-195:
-196: /* serial configuration */
-197: eusart1_init();
-0300 ECFE CALL 0x3FC, 0
-0302 F001 NOP
-198:
-199: ei();
-0304 8EF2 BSF INTCON, 7, ACCESS
-200: }
-0306 0012 RETURN 0
-201:
-202:
-203: /* main program */
-204: void main(void)
-205: {
-206: unsigned char i, data;
-207: midi_message_t sample_message;
-208:
-209: /* setup hardware */
-210: init_hw();
-0308 EC54 CALL 0x2A8, 0
-030A F001 NOP
-211:
-212: /* setup software */
-213: memset(keypresses, 0, sizeof(keypresses));
-030C 0E25 MOVLW 0x25
-030E 6E1A MOVWF p1, ACCESS
-0310 0E00 MOVLW 0x0
-0312 6E1B MOVWF pkt, ACCESS
+170: TRISDbits.TRISD1 = 0;
+04BA 9295 BCF TRISD, 1, ACCESS
+171: TRISDbits.TRISD2 = 0;
+04BC 9495 BCF TRISD, 2, ACCESS
+172: TRISDbits.TRISD3 = 0;
+04BE 9695 BCF TRISD, 3, ACCESS
+173: TRISDbits.TRISD4 = 0;
+04C0 9895 BCF TRISD, 4, ACCESS
+174:
+175: // LED
+176: PORTDbits.RD1 = 1;
+04C2 8283 BSF PORTD, 1, ACCESS
+177: // TEST OUTPUT 1
+178: PORTDbits.RD2 = 0;
+04C4 9483 BCF PORTD, 2, ACCESS
+179: // TEST OUTPUT 2
+180: PORTDbits.RD3 = 1;
+04C6 8683 BSF PORTD, 3, ACCESS
+181: // TEST OUTPUT 3
+182: PORTDbits.RD4 = 0;
+04C8 9883 BCF PORTD, 4, ACCESS
+183:
+184: /* timer configuration */
+185: // timer 2 comp value
+186: PR2 = 128;
+04CA 0E80 MOVLW 0x80
+04CC 6EBB MOVWF PR2, ACCESS
+187: // postscaler 1:4
+188: T2CONbits.T2OUTPS = 0b0011;
+04CE 50BA MOVF T2CON, W, ACCESS
+04D0 0B87 ANDLW 0x87
+04D2 0918 IORLW 0x18
+04D4 6EBA MOVWF T2CON, ACCESS
+189: // prescaler 1:16
+190: T2CONbits.T2CKPS = 0b11;
+04D6 0E03 MOVLW 0x3
+04D8 12BA IORWF T2CON, F, ACCESS
+191: // start timer
+192: T2CONbits.TMR2ON = 1;
+04DA 84BA BSF T2CON, 2, ACCESS
+193:
+194: // timer 2 interrupts
+195: PIE1bits.TMR2IE = 1;
+04DC 829D BSF PIE1, 1, ACCESS
+196: PIR1bits.TMR2IF = 0;
+04DE 929E BCF PIR1, 1, ACCESS
+197:
+198: // enable peripheral interrupts
+199: INTCONbits.PEIE = 1;
+04E0 8CF2 BSF INTCON, 6, ACCESS
+200:
+201: /* serial configuration */
+202: eusart1_init();
+04E2 ECCC CALL 0x598, 0
+04E4 F002 NOP
+203: }
+04E6 0012 RETURN 0
+204:
+205:
+206: /* main program */
+207: void main(void)
+208: {
+209: uint8_t i;
+210: midi_message_t message;
+211:
+212: /* setup hardware */
+213: init_hw();
+02E8 EC45 CALL 0x48A, 0
+02EA F002 NOP
+214:
+215: /* setup software */
+216: memset(keys_data, 0, sizeof(keys_data));
+02EC 0E03 MOVLW 0x3
+02EE 0100 MOVLB 0x0
+02F0 6F60 MOVWF __pcstackBANK0, BANKED
+02F2 0E00 MOVLW 0x0
+02F4 6F61 MOVWF pkt, BANKED
+02F6 0E00 MOVLW 0x0
+02F8 6F63 MOVWF 0x63, BANKED
+02FA 0E00 MOVLW 0x0
+02FC 6F62 MOVWF c, BANKED
+02FE 0E00 MOVLW 0x0
+0300 6F65 MOVWF pkt, BANKED
+0302 0E20 MOVLW 0x20
+0304 6F64 MOVWF n, BANKED
+0306 EC8D CALL 0x51A, 0
+0308 F002 NOP
+217:
+218: ei();
+030A 8EF2 BSF INTCON, 7, ACCESS
+219:
+220: /* TODO remove demo code */
+221: PORTDbits.RD1 = 0;
+030C 9283 BCF PORTD, 1, ACCESS
+222:
+223: midi_note_on(&message, MIDI_CHANNEL, MIDI_SCALE_START, 0x7F);
+030E 0E71 MOVLW 0x71
+0310 0100 MOVLB 0x0
+0312 6F65 MOVWF pkt, BANKED
0314 0E00 MOVLW 0x0
-0316 6E1D MOVWF 0x1D, ACCESS
+0316 6F66 MOVWF p, BANKED
0318 0E00 MOVLW 0x0
-031A 6E1C MOVWF c, ACCESS
+031A 6F68 MOVWF 0x68, BANKED
031C 0E00 MOVLW 0x0
-031E 6E1F MOVWF pkt, ACCESS
-0320 0E1E MOVLW 0x1E
-0322 6E1E MOVWF n, ACCESS
-0324 ECC3 CALL 0x386, 0
-0326 F001 NOP
-214:
-215: /* TODO remove demo code */
-216: midi_note_on(&sample_message, 0x0, 0x3C, 0x7F);
-0328 0E62 MOVLW 0x62
-032A 6E1F MOVWF pkt, ACCESS
+031E 6F67 MOVWF channel, BANKED
+0320 0E3C MOVLW 0x3C
+0322 6F69 MOVWF note, BANKED
+0324 0E7F MOVLW 0x7F
+0326 6F6A MOVWF velocity, BANKED
+0328 EC12 CALL 0x424, 0
+032A F002 NOP
+224:
+225: /* main loop */
+226: while (1) {
+227: // check flags
+228: for (i = 0; i < NOTES; i++) {
032C 0E00 MOVLW 0x0
-032E 6E20 MOVWF p, ACCESS
-0330 0E00 MOVLW 0x0
-0332 6E22 MOVWF 0x22, ACCESS
-0334 0E00 MOVLW 0x0
-0336 6E21 MOVWF channel, ACCESS
-0338 0E3C MOVLW 0x3C
-033A 6E23 MOVWF note, ACCESS
-033C 0E7F MOVLW 0x7F
-033E 6E24 MOVWF velocity, ACCESS
-0340 ECDE CALL 0x1BC, 0
-0342 F000 NOP
-217: PORTDbits.RD1 = 0;
-0344 9283 BCF PORTD, 1, ACCESS
-218:
-219: /* main loop */
-220: while (1) {
-0352 D7F9 BRA 0x346
-221: eusart_write_midi(&sample_message);
-0346 0E62 MOVLW 0x62
-0348 6E1B MOVWF pkt, ACCESS
-034A 0E00 MOVLW 0x0
-034C 6E1C MOVWF c, ACCESS
-034E EC1A CALL 0x234, 0
-0350 F001 NOP
-0352 D7F9 BRA 0x346
-222: }
-223: }
-224:
-225:
-226: int eusart_write_midi(const midi_message_t *pkt)
-227: {
-228: size_t length;
-229: uint8_t *data;
-230:
-231: if (pkt == NULL) {
-0234 501B MOVF pkt, W, ACCESS
-0236 101C IORWF c, W, ACCESS
-0238 B4D8 BTFSC STATUS, 2, ACCESS
-023A 0012 RETURN 0
-232: return -1;
-233: }
-234:
-235: length = pkt->data_size;
-023C EE20 LFSR 2, 0x1
-023E F001 NOP
-0240 501B MOVF pkt, W, ACCESS
-0242 26D9 ADDWF FSR2, F, ACCESS
-0244 501C MOVF c, W, ACCESS
-0246 22DA ADDWFC FSR2H, F, ACCESS
-0248 CFDE MOVFF POSTINC2, pkt
-024A F01F NOP
-024C CFDD MOVFF POSTDEC2, p
-024E F020 NOP
-236: data = (uint8_t *) pkt->data;
-0250 0E03 MOVLW 0x3
-0252 241B ADDWF pkt, W, ACCESS
-0254 6E21 MOVWF channel, ACCESS
-0256 0E00 MOVLW 0x0
-0258 201C ADDWFC c, W, ACCESS
-025A 6E22 MOVWF 0x22, ACCESS
-237:
-238: putch((char)((pkt->status << 4) | pkt->channel));
-025C C01B MOVFF pkt, FSR2
-025E FFD9 NOP
-0260 C01C MOVFF c, FSR2H
-0262 FFDA NOP
-0264 38DF SWAPF INDF2, W, ACCESS
-0266 0B0F ANDLW 0xF
-0268 6E1D MOVWF 0x1D, ACCESS
-026A C01B MOVFF pkt, FSR2
-026C FFD9 NOP
-026E C01C MOVFF c, FSR2H
-0270 FFDA NOP
-0272 50DF MOVF INDF2, W, ACCESS
-0274 0B0F ANDLW 0xF
-0276 6E1E MOVWF n, ACCESS
-0278 381E SWAPF n, W, ACCESS
-027A 0BF0 ANDLW 0xF0
-027C 101D IORWF 0x1D, W, ACCESS
-027E EC0C CALL 0x418, 0
-0280 F002 NOP
-239:
-240: while (length--) {
-0282 D009 BRA 0x296
-241: putch((char) *(data++));
-0284 C021 MOVFF channel, FSR2
-0286 FFD9 NOP
-0288 C022 MOVFF 0x22, FSR2H
-028A FFDA NOP
-028C 50DF MOVF INDF2, W, ACCESS
-028E EC0C CALL 0x418, 0
-0290 F002 NOP
-0292 4A21 INFSNZ channel, F, ACCESS
-0294 2A22 INCF 0x22, F, ACCESS
-242: }
-0296 061F DECF pkt, F, ACCESS
-0298 A0D8 BTFSS STATUS, 0, ACCESS
-029A 0620 DECF p, F, ACCESS
-029C 281F INCF pkt, W, ACCESS
-029E E1F2 BNZ 0x284
-02A0 2820 INCF p, W, ACCESS
-02A2 B4D8 BTFSC STATUS, 2, ACCESS
-02A4 0012 RETURN 0
-02A6 D7EE BRA 0x284
-243:
-244: return 0;
-245: }
+032E 0100 MOVLB 0x0
+0330 6F70 MOVWF i, BANKED
+0332 0E0F MOVLW 0xF
+0334 6570 CPFSGT i, BANKED
+0336 D001 BRA 0x33A
+0338 D7F9 BRA 0x32C
+229: if (keypresses & (1<<i)) {
+033A C070 MOVFF i, 0x6B
+033C F06B NOP
+033E 0E01 MOVLW 0x1
+0340 6F6C MOVWF 0x6C, BANKED
+0342 0E00 MOVLW 0x0
+0344 6F6D MOVWF 0x6D, BANKED
+0346 2B6B INCF 0x6B, F, BANKED
+0348 D003 BRA 0x350
+034A 90D8 BCF STATUS, 0, ACCESS
+034C 376C RLCF 0x6C, F, BANKED
+034E 376D RLCF 0x6D, F, BANKED
+0350 2F6B DECFSZ 0x6B, F, BANKED
+0352 D7FB BRA 0x34A
+0354 5001 MOVF keypresses, W, ACCESS
+0356 0100 MOVLB 0x0
+0358 176C ANDWF 0x6C, F, BANKED
+035A 5002 MOVF 0x2, W, ACCESS
+035C 176D ANDWF 0x6D, F, BANKED
+035E 516C MOVF 0x6C, W, BANKED
+0360 116D IORWF 0x6D, W, BANKED
+0362 B4D8 BTFSC STATUS, 2, ACCESS
+0364 D020 BRA 0x3A6
+230:
+231: message.data[0] = MIDI_SCALE_START + i;
+0366 5170 MOVF i, W, BANKED
+0368 0F3C ADDLW 0x3C
+036A 6F74 MOVWF 0x74, BANKED
+232: // midi_note_on(&message, MIDI_CHANNEL, MIDI_SCALE_START + i, 0x7F);
+233:
+234: eusart_write_midi(&message);
+036C 0E71 MOVLW 0x71
+036E 6F61 MOVWF pkt, BANKED
+0370 0E00 MOVLW 0x0
+0372 6F62 MOVWF c, BANKED
+0374 ECD5 CALL 0x3AA, 0
+0376 F001 NOP
+235:
+236: // unset flag
+237: keypresses &= ~(1<<i);
+0378 C070 MOVFF i, 0x6B
+037A F06B NOP
+037C 0E01 MOVLW 0x1
+037E 0100 MOVLB 0x0
+0380 6F6C MOVWF 0x6C, BANKED
+0382 0E00 MOVLW 0x0
+0384 6F6D MOVWF 0x6D, BANKED
+0386 2B6B INCF 0x6B, F, BANKED
+0388 D003 BRA 0x390
+038A 90D8 BCF STATUS, 0, ACCESS
+038C 376C RLCF 0x6C, F, BANKED
+038E 376D RLCF 0x6D, F, BANKED
+0390 2F6B DECFSZ 0x6B, F, BANKED
+0392 D7FB BRA 0x38A
+0394 0100 MOVLB 0x0
+0396 1D6C COMF 0x6C, W, BANKED
+0398 6F6E MOVWF 0x6E, BANKED
+039A 1D6D COMF 0x6D, W, BANKED
+039C 6F6F MOVWF 0x6F, BANKED
+039E 516E MOVF 0x6E, W, BANKED
+03A0 1601 ANDWF keypresses, F, ACCESS
+03A2 516F MOVF 0x6F, W, BANKED
+03A4 1602 ANDWF 0x2, F, ACCESS
+238: }
+03A6 2B70 INCF i, F, BANKED
+03A8 D7C4 BRA 0x332
+239: }
+240: }
+241: }
+242:
+243:
+244: int eusart_write_midi(const midi_message_t *pkt)
+245: {
+246: size_t length;
+247: uint8_t *data;
+248:
+249: if (pkt == NULL) {
+03AA 0100 MOVLB 0x0
+03AC 5161 MOVF pkt, W, BANKED
+03AE 1162 IORWF c, W, BANKED
+03B0 B4D8 BTFSC STATUS, 2, ACCESS
+03B2 0012 RETURN 0
+250: return -1;
+251: }
+252:
+253: length = pkt->data_size;
+03B4 EE20 LFSR 2, 0x1
+03B6 F001 NOP
+03B8 5161 MOVF pkt, W, BANKED
+03BA 26D9 ADDWF FSR2, F, ACCESS
+03BC 5162 MOVF c, W, BANKED
+03BE 22DA ADDWFC FSR2H, F, ACCESS
+03C0 CFDE MOVFF POSTINC2, pkt
+03C2 F065 NOP
+03C4 CFDD MOVFF POSTDEC2, p
+03C6 F066 NOP
+254: data = (uint8_t *) pkt->data;
+03C8 0E03 MOVLW 0x3
+03CA 2561 ADDWF pkt, W, BANKED
+03CC 6F67 MOVWF channel, BANKED
+03CE 0E00 MOVLW 0x0
+03D0 2162 ADDWFC c, W, BANKED
+03D2 6F68 MOVWF 0x68, BANKED
+255:
+256: putch((char)((pkt->status << 4) | pkt->channel));
+03D4 C061 MOVFF pkt, FSR2
+03D6 FFD9 NOP
+03D8 C062 MOVFF c, FSR2H
+03DA FFDA NOP
+03DC 38DF SWAPF INDF2, W, ACCESS
+03DE 0B0F ANDLW 0xF
+03E0 6F63 MOVWF 0x63, BANKED
+03E2 C061 MOVFF pkt, FSR2
+03E4 FFD9 NOP
+03E6 C062 MOVFF c, FSR2H
+03E8 FFDA NOP
+03EA 50DF MOVF INDF2, W, ACCESS
+03EC 0B0F ANDLW 0xF
+03EE 6F64 MOVWF n, BANKED
+03F0 3964 SWAPF n, W, BANKED
+03F2 0BF0 ANDLW 0xF0
+03F4 1163 IORWF 0x63, W, BANKED
+03F6 ECDA CALL 0x5B4, 0
+03F8 F002 NOP
+257:
+258: while (length--) {
+03FA D00A BRA 0x410
+259: putch((char) *(data++));
+03FC C067 MOVFF channel, FSR2
+03FE FFD9 NOP
+0400 C068 MOVFF 0x68, FSR2H
+0402 FFDA NOP
+0404 50DF MOVF INDF2, W, ACCESS
+0406 ECDA CALL 0x5B4, 0
+0408 F002 NOP
+040A 0100 MOVLB 0x0
+040C 4B67 INFSNZ channel, F, BANKED
+040E 2B68 INCF 0x68, F, BANKED
+260: }
+0410 0100 MOVLB 0x0
+0412 0765 DECF pkt, F, BANKED
+0414 A0D8 BTFSS STATUS, 0, ACCESS
+0416 0766 DECF p, F, BANKED
+0418 2965 INCF pkt, W, BANKED
+041A E1F0 BNZ 0x3FC
+041C 2966 INCF p, W, BANKED
+041E B4D8 BTFSC STATUS, 2, ACCESS
+0420 0012 RETURN 0
+0422 D7EC BRA 0x3FC
+261:
+262: return 0;
+263: }
--- C:/Program Files/Microchip/xc8/v1.44/sources/common/memset.c --------------------------------------
1: #include <string.h>
2:
@@ -902,30 +1128,32 @@ Z:/SAMB_4/projects/xilofono/src/dist/default/production/src.production.elf
16: #endif /* _PIC16 */
17:
18: p = p1;
-0386 C01A MOVFF p1, p
-0388 F020 NOP
-038A C01B MOVFF pkt, channel
-038C F021 NOP
+051A C060 MOVFF __pcstackBANK0, p
+051C F066 NOP
+051E C061 MOVFF pkt, channel
+0520 F067 NOP
19: while(n--)
-038E D008 BRA 0x3A0
-03A0 061E DECF n, F, ACCESS
+0522 D009 BRA 0x536
+0536 0100 MOVLB 0x0
20: *p++ = c;
-0390 C020 MOVFF p, FSR2
-0392 FFD9 NOP
-0394 C021 MOVFF channel, FSR2H
-0396 FFDA NOP
-0398 C01C MOVFF c, INDF2
-039A FFDF NOP
-039C 4A20 INFSNZ p, F, ACCESS
-039E 2A21 INCF channel, F, ACCESS
-03A0 061E DECF n, F, ACCESS
-03A2 A0D8 BTFSS STATUS, 0, ACCESS
-03A4 061F DECF pkt, F, ACCESS
-03A6 281E INCF n, W, ACCESS
-03A8 E1F3 BNZ 0x390
-03AA 281F INCF pkt, W, ACCESS
-03AC B4D8 BTFSC STATUS, 2, ACCESS
-03AE 0012 RETURN 0
-03B0 D7EF BRA 0x390
+0524 C066 MOVFF p, FSR2
+0526 FFD9 NOP
+0528 C067 MOVFF channel, FSR2H
+052A FFDA NOP
+052C C062 MOVFF c, INDF2
+052E FFDF NOP
+0530 0100 MOVLB 0x0
+0532 4B66 INFSNZ p, F, BANKED
+0534 2B67 INCF channel, F, BANKED
+0536 0100 MOVLB 0x0
+0538 0764 DECF n, F, BANKED
+053A A0D8 BTFSS STATUS, 0, ACCESS
+053C 0765 DECF pkt, F, BANKED
+053E 2964 INCF n, W, BANKED
+0540 E1F1 BNZ 0x524
+0542 2965 INCF pkt, W, BANKED
+0544 B4D8 BTFSC STATUS, 2, ACCESS
+0546 0012 RETURN 0
+0548 D7ED BRA 0x524
21: return p1;
22: }
diff --git a/src/dist/default/production/memoryfile.xml b/src/dist/default/production/memoryfile.xml
index 6f5f082..afd74db 100644
--- a/src/dist/default/production/memoryfile.xml
+++ b/src/dist/default/production/memoryfile.xml
@@ -4,14 +4,14 @@
<memory name="program">
<units>bytes</units>
<length>32768</length>
- <used>1058</used>
- <free>31710</free>
+ <used>1598</used>
+ <free>31170</free>
</memory>
<memory name="data">
<units>bytes</units>
<length>1536</length>
- <used>78</used>
- <free>1458</free>
+ <used>138</used>
+ <free>1398</free>
</memory>
</executable>
</project>
diff --git a/src/dist/default/production/src.production.cmf b/src/dist/default/production/src.production.cmf
index 53d83bb..fd87445 100644
--- a/src/dist/default/production/src.production.cmf
+++ b/src/dist/default/production/src.production.cmf
@@ -11,54 +11,53 @@
# All addresses and the length are given in unqualified hexadecimal
# in delta units. Any other numeric values are decimal.
%PSECTS
-$C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
+$C:\Users\_prossn\AppData\Local\Temp\s514.obj
idloc IDLOC 0 200000 200000 8 1
-init CODE 0 1B8 1B8 4 1
+init CODE 0 352 352 4 1
reset_vec CODE 0 0 0 4 1
config CONFIG 0 300000 300000 E 1
$dist/default/production\src.production.obj
-cinit CODE 0 354 354 32 1
-text0 CODE 0 308 308 4C 1
-text1 CODE 0 1BC 1BC 78 1
-text2 CODE 0 3D8 3D8 24 1
-text3 CODE 0 3B2 3B2 26 1
-text4 CODE 0 386 386 2C 1
-text5 CODE 0 2A8 2A8 60 1
-text6 CODE 0 3FC 3FC 1C 1
-text7 CODE 0 234 234 74 1
-text8 CODE 0 418 418 C 1
-idataCOMRAM CODE 0 424 424 2 1
-cstackCOMRAM COMRAM 1 1 1 24 1
-cstackBANK0 BANK0 1 60 60 9 1
-temp COMRAM 1 45 45 1 1
-intcode CODE 0 8 8 1B0 1
-dataCOMRAM COMRAM 1 43 43 2 1
-bssCOMRAM COMRAM 1 25 25 1E 1
+cinit CODE 0 61C 61C 1A 1
+text0 CODE 0 356 356 DC 1
+text1 CODE 0 4A6 4A6 66 1
+text2 CODE 0 5C0 5C0 24 1
+text3 CODE 0 59A 59A 26 1
+text4 CODE 0 56E 56E 2C 1
+text5 CODE 0 50C 50C 62 1
+text6 CODE 0 5E4 5E4 1C 1
+text7 CODE 0 600 600 1C 1
+text8 CODE 0 432 432 74 1
+text9 CODE 0 636 636 C 1
+cstackCOMRAM COMRAM 1 1 1 33 1
+cstackBANK0 BANK0 1 A2 A2 14 1
+temp COMRAM 1 34 34 1 1
+bssBANK0 BANK0 1 60 60 42 1
+intcode CODE 0 8 8 34A 1
# %UNUSED Section
# This section enumerates the unused ranges of each CLASS. Each entry
# is described on a single line as follows:
# <class name> <range> <delta>
# Addresses given in the range are in hexadecimal and units of delta.
%UNUSED
-RAM 69-5FF 1
+RAM B6-5FF 1
SFR F38-FFF 1
-BANK0 69-FF 1
+BANK0 B6-FF 1
BANK1 100-1FF 1
BANK2 200-2FF 1
BANK3 300-3FF 1
BANK4 400-4FF 1
BANK5 500-5FF 1
CONST 4-7 1
-CONST 426-7FFF 1
-STACK 69-5FF 1
-SMALLCONST 600-7FFF 1
+CONST 642-7FFF 1
+STACK B6-5FF 1
+SMALLCONST 642-7FFF 1
CODE 4-7 1
-CODE 426-7FFF 1
-BIGRAM 46-5F 1
-BIGRAM 69-5FF 1
-COMRAM 46-5F 1
+CODE 642-7FFF 1
+BIGRAM 35-5F 1
+BIGRAM B6-5FF 1
+COMRAM 35-5F 1
EEDATA F00000-F000FF 1
-MEDIUMCONST 600-7FFF 1
+MEDIUMCONST 642-7FFF 1
# %LINETAB Section
# This section enumerates the file/line to address mappings.
# The beginning of the section is indicated by %LINETAB.
@@ -73,135 +72,143 @@ MEDIUMCONST 600-7FFF 1
# All other numeric values are in decimal.
%LINETAB
$dist/default/production\src.production.obj
-8 intcode CODE >101:Z:\SAMB_4\projects\xilofono\src\main.c
-8 intcode CODE >33:Z:\SAMB_4\projects\xilofono\src\rs232.c
-52 intcode CODE >105:Z:\SAMB_4\projects\xilofono\src\main.c
-54 intcode CODE >107:Z:\SAMB_4\projects\xilofono\src\main.c
-58 intcode CODE >109:Z:\SAMB_4\projects\xilofono\src\main.c
-5C intcode CODE >110:Z:\SAMB_4\projects\xilofono\src\main.c
-60 intcode CODE >111:Z:\SAMB_4\projects\xilofono\src\main.c
-60 intcode CODE >112:Z:\SAMB_4\projects\xilofono\src\main.c
-B6 intcode CODE >113:Z:\SAMB_4\projects\xilofono\src\main.c
-BE intcode CODE >115:Z:\SAMB_4\projects\xilofono\src\main.c
-C2 intcode CODE >116:Z:\SAMB_4\projects\xilofono\src\main.c
-C6 intcode CODE >117:Z:\SAMB_4\projects\xilofono\src\main.c
-C6 intcode CODE >118:Z:\SAMB_4\projects\xilofono\src\main.c
-11C intcode CODE >119:Z:\SAMB_4\projects\xilofono\src\main.c
-13C intcode CODE >129:Z:\SAMB_4\projects\xilofono\src\main.c
-146 intcode CODE >130:Z:\SAMB_4\projects\xilofono\src\main.c
-168 intcode CODE >133:Z:\SAMB_4\projects\xilofono\src\main.c
-16A intcode CODE >134:Z:\SAMB_4\projects\xilofono\src\main.c
-16A intcode CODE >136:Z:\SAMB_4\projects\xilofono\src\main.c
-16C intcode CODE >137:Z:\SAMB_4\projects\xilofono\src\main.c
-418 text8 CODE >29:Z:\SAMB_4\projects\xilofono\src\rs232.c
-41A text8 CODE >31:Z:\SAMB_4\projects\xilofono\src\rs232.c
-41E text8 CODE >32:Z:\SAMB_4\projects\xilofono\src\rs232.c
-422 text8 CODE >33:Z:\SAMB_4\projects\xilofono\src\rs232.c
-234 text7 CODE >226:Z:\SAMB_4\projects\xilofono\src\main.c
-234 text7 CODE >231:Z:\SAMB_4\projects\xilofono\src\main.c
-23C text7 CODE >235:Z:\SAMB_4\projects\xilofono\src\main.c
-250 text7 CODE >236:Z:\SAMB_4\projects\xilofono\src\main.c
-25C text7 CODE >238:Z:\SAMB_4\projects\xilofono\src\main.c
-282 text7 CODE >240:Z:\SAMB_4\projects\xilofono\src\main.c
-284 text7 CODE >241:Z:\SAMB_4\projects\xilofono\src\main.c
-296 text7 CODE >240:Z:\SAMB_4\projects\xilofono\src\main.c
-296 text7 CODE >242:Z:\SAMB_4\projects\xilofono\src\main.c
-3FC text6 CODE >4:Z:\SAMB_4\projects\xilofono\src\rs232.c
-3FC text6 CODE >7:Z:\SAMB_4\projects\xilofono\src\rs232.c
-3FE text6 CODE >8:Z:\SAMB_4\projects\xilofono\src\rs232.c
-400 text6 CODE >11:Z:\SAMB_4\projects\xilofono\src\rs232.c
-402 text6 CODE >12:Z:\SAMB_4\projects\xilofono\src\rs232.c
-406 text6 CODE >13:Z:\SAMB_4\projects\xilofono\src\rs232.c
-40A text6 CODE >14:Z:\SAMB_4\projects\xilofono\src\rs232.c
-40C text6 CODE >15:Z:\SAMB_4\projects\xilofono\src\rs232.c
-40E text6 CODE >18:Z:\SAMB_4\projects\xilofono\src\rs232.c
-410 text6 CODE >19:Z:\SAMB_4\projects\xilofono\src\rs232.c
-412 text6 CODE >20:Z:\SAMB_4\projects\xilofono\src\rs232.c
-414 text6 CODE >21:Z:\SAMB_4\projects\xilofono\src\rs232.c
-416 text6 CODE >22:Z:\SAMB_4\projects\xilofono\src\rs232.c
-2A8 text5 CODE >140:Z:\SAMB_4\projects\xilofono\src\main.c
-2A8 text5 CODE >142:Z:\SAMB_4\projects\xilofono\src\main.c
-2AA text5 CODE >146:Z:\SAMB_4\projects\xilofono\src\main.c
-2AC text5 CODE >148:Z:\SAMB_4\projects\xilofono\src\main.c
-2B8 text5 CODE >150:Z:\SAMB_4\projects\xilofono\src\main.c
-2BE text5 CODE >152:Z:\SAMB_4\projects\xilofono\src\main.c
-2C2 text5 CODE >156:Z:\SAMB_4\projects\xilofono\src\main.c
-2C8 text5 CODE >157:Z:\SAMB_4\projects\xilofono\src\main.c
-2CC text5 CODE >158:Z:\SAMB_4\projects\xilofono\src\main.c
-2D0 text5 CODE >159:Z:\SAMB_4\projects\xilofono\src\main.c
-2D4 text5 CODE >162:Z:\SAMB_4\projects\xilofono\src\main.c
-2D6 text5 CODE >163:Z:\SAMB_4\projects\xilofono\src\main.c
-2D8 text5 CODE >165:Z:\SAMB_4\projects\xilofono\src\main.c
-2DA text5 CODE >166:Z:\SAMB_4\projects\xilofono\src\main.c
-2DC text5 CODE >167:Z:\SAMB_4\projects\xilofono\src\main.c
-2DE text5 CODE >168:Z:\SAMB_4\projects\xilofono\src\main.c
-2E0 text5 CODE >171:Z:\SAMB_4\projects\xilofono\src\main.c
-2E2 text5 CODE >173:Z:\SAMB_4\projects\xilofono\src\main.c
-2E4 text5 CODE >175:Z:\SAMB_4\projects\xilofono\src\main.c
-2E6 text5 CODE >177:Z:\SAMB_4\projects\xilofono\src\main.c
-2E8 text5 CODE >181:Z:\SAMB_4\projects\xilofono\src\main.c
-2EC text5 CODE >183:Z:\SAMB_4\projects\xilofono\src\main.c
-2F4 text5 CODE >185:Z:\SAMB_4\projects\xilofono\src\main.c
-2F8 text5 CODE >187:Z:\SAMB_4\projects\xilofono\src\main.c
-2FA text5 CODE >190:Z:\SAMB_4\projects\xilofono\src\main.c
-2FC text5 CODE >191:Z:\SAMB_4\projects\xilofono\src\main.c
-2FE text5 CODE >194:Z:\SAMB_4\projects\xilofono\src\main.c
-300 text5 CODE >197:Z:\SAMB_4\projects\xilofono\src\main.c
-304 text5 CODE >199:Z:\SAMB_4\projects\xilofono\src\main.c
-306 text5 CODE >200:Z:\SAMB_4\projects\xilofono\src\main.c
-386 text4 CODE >8:C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
-386 text4 CODE >18:C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
-38E text4 CODE >19:C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
-390 text4 CODE >20:C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
-3A0 text4 CODE >19:C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
-3B2 text3 CODE >51:Z:\SAMB_4\projects\xilofono\src\midi.c
-3B2 text3 CODE >53:Z:\SAMB_4\projects\xilofono\src\midi.c
-3BA text3 CODE >57:Z:\SAMB_4\projects\xilofono\src\midi.c
-3D8 text2 CODE >40:Z:\SAMB_4\projects\xilofono\src\midi.c
-3D8 text2 CODE >42:Z:\SAMB_4\projects\xilofono\src\midi.c
-3E0 text2 CODE >46:Z:\SAMB_4\projects\xilofono\src\midi.c
-1BC text1 CODE >62:Z:\SAMB_4\projects\xilofono\src\midi.c
-1BC text1 CODE >64:Z:\SAMB_4\projects\xilofono\src\midi.c
-1C4 text1 CODE >68:Z:\SAMB_4\projects\xilofono\src\midi.c
-1DA text1 CODE >72:Z:\SAMB_4\projects\xilofono\src\midi.c
-1EA text1 CODE >73:Z:\SAMB_4\projects\xilofono\src\midi.c
-1FE text1 CODE >75:Z:\SAMB_4\projects\xilofono\src\midi.c
-20E text1 CODE >76:Z:\SAMB_4\projects\xilofono\src\midi.c
-21E text1 CODE >79:Z:\SAMB_4\projects\xilofono\src\midi.c
-308 text0 CODE >204:Z:\SAMB_4\projects\xilofono\src\main.c
-308 text0 CODE >210:Z:\SAMB_4\projects\xilofono\src\main.c
-30C text0 CODE >213:Z:\SAMB_4\projects\xilofono\src\main.c
-328 text0 CODE >216:Z:\SAMB_4\projects\xilofono\src\main.c
-344 text0 CODE >217:Z:\SAMB_4\projects\xilofono\src\main.c
-346 text0 CODE >220:Z:\SAMB_4\projects\xilofono\src\main.c
-346 text0 CODE >221:Z:\SAMB_4\projects\xilofono\src\main.c
-352 text0 CODE >220:Z:\SAMB_4\projects\xilofono\src\main.c
-354 cinit CODE >1211:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-354 cinit CODE >1213:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-354 cinit CODE >1216:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-354 cinit CODE >1238:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-356 cinit CODE >1239:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-358 cinit CODE >1240:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-35A cinit CODE >1241:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-35C cinit CODE >1242:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-35E cinit CODE >1243:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-360 cinit CODE >1244:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-362 cinit CODE >1245:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-366 cinit CODE >1246:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-368 cinit CODE >1247:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-36C cinit CODE >1251:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-370 cinit CODE >1252:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-372 cinit CODE >1253:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-372 cinit CODE >1254:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-374 cinit CODE >1255:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-376 cinit CODE >1256:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-378 cinit CODE >1262:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-378 cinit CODE >1264:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-37A cinit CODE >1265:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-37C cinit CODE >1267:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-37E cinit CODE >1268:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-380 cinit CODE >1269:C:\Users\_prossn\AppData\Local\Temp\s5hg.
-382 cinit CODE >1270:C:\Users\_prossn\AppData\Local\Temp\s5hg.
+8 intcode CODE >113:Z:\SAMB_4\projects\xilofono\src\main.c
+8 intcode CODE >56:Z:\SAMB_4\projects\xilofono\src\rs232.c
+52 intcode CODE >117:Z:\SAMB_4\projects\xilofono\src\main.c
+54 intcode CODE >119:Z:\SAMB_4\projects\xilofono\src\main.c
+58 intcode CODE >120:Z:\SAMB_4\projects\xilofono\src\main.c
+5C intcode CODE >121:Z:\SAMB_4\projects\xilofono\src\main.c
+60 intcode CODE >122:Z:\SAMB_4\projects\xilofono\src\main.c
+64 intcode CODE >123:Z:\SAMB_4\projects\xilofono\src\main.c
+64 intcode CODE >125:Z:\SAMB_4\projects\xilofono\src\main.c
+E0 intcode CODE >126:Z:\SAMB_4\projects\xilofono\src\main.c
+188 intcode CODE >131:Z:\SAMB_4\projects\xilofono\src\main.c
+202 intcode CODE >132:Z:\SAMB_4\projects\xilofono\src\main.c
+2AC intcode CODE >134:Z:\SAMB_4\projects\xilofono\src\main.c
+2B4 intcode CODE >138:Z:\SAMB_4\projects\xilofono\src\main.c
+2BE intcode CODE >139:Z:\SAMB_4\projects\xilofono\src\main.c
+302 intcode CODE >143:Z:\SAMB_4\projects\xilofono\src\main.c
+304 intcode CODE >144:Z:\SAMB_4\projects\xilofono\src\main.c
+304 intcode CODE >146:Z:\SAMB_4\projects\xilofono\src\main.c
+306 intcode CODE >147:Z:\SAMB_4\projects\xilofono\src\main.c
+636 text9 CODE >52:Z:\SAMB_4\projects\xilofono\src\rs232.c
+638 text9 CODE >54:Z:\SAMB_4\projects\xilofono\src\rs232.c
+63C text9 CODE >55:Z:\SAMB_4\projects\xilofono\src\rs232.c
+640 text9 CODE >56:Z:\SAMB_4\projects\xilofono\src\rs232.c
+432 text8 CODE >261:Z:\SAMB_4\projects\xilofono\src\main.c
+432 text8 CODE >266:Z:\SAMB_4\projects\xilofono\src\main.c
+43A text8 CODE >270:Z:\SAMB_4\projects\xilofono\src\main.c
+44E text8 CODE >271:Z:\SAMB_4\projects\xilofono\src\main.c
+45A text8 CODE >273:Z:\SAMB_4\projects\xilofono\src\main.c
+480 text8 CODE >275:Z:\SAMB_4\projects\xilofono\src\main.c
+482 text8 CODE >276:Z:\SAMB_4\projects\xilofono\src\main.c
+494 text8 CODE >275:Z:\SAMB_4\projects\xilofono\src\main.c
+494 text8 CODE >277:Z:\SAMB_4\projects\xilofono\src\main.c
+600 text7 CODE >4:Z:\SAMB_4\projects\xilofono\src\rs232.c
+600 text7 CODE >7:Z:\SAMB_4\projects\xilofono\src\rs232.c
+602 text7 CODE >8:Z:\SAMB_4\projects\xilofono\src\rs232.c
+604 text7 CODE >11:Z:\SAMB_4\projects\xilofono\src\rs232.c
+606 text7 CODE >12:Z:\SAMB_4\projects\xilofono\src\rs232.c
+60A text7 CODE >13:Z:\SAMB_4\projects\xilofono\src\rs232.c
+60E text7 CODE >14:Z:\SAMB_4\projects\xilofono\src\rs232.c
+610 text7 CODE >15:Z:\SAMB_4\projects\xilofono\src\rs232.c
+612 text7 CODE >18:Z:\SAMB_4\projects\xilofono\src\rs232.c
+614 text7 CODE >19:Z:\SAMB_4\projects\xilofono\src\rs232.c
+616 text7 CODE >21:Z:\SAMB_4\projects\xilofono\src\rs232.c
+618 text7 CODE >22:Z:\SAMB_4\projects\xilofono\src\rs232.c
+61A text7 CODE >23:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5E4 text6 CODE >25:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5E4 text6 CODE >28:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5E6 text6 CODE >29:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5E8 text6 CODE >32:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5EA text6 CODE >33:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5EE text6 CODE >34:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5F2 text6 CODE >35:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5F4 text6 CODE >36:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5F6 text6 CODE >39:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5F8 text6 CODE >40:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5FA text6 CODE >42:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5FC text6 CODE >43:Z:\SAMB_4\projects\xilofono\src\rs232.c
+5FE text6 CODE >44:Z:\SAMB_4\projects\xilofono\src\rs232.c
+50C text5 CODE >150:Z:\SAMB_4\projects\xilofono\src\main.c
+50C text5 CODE >152:Z:\SAMB_4\projects\xilofono\src\main.c
+50E text5 CODE >156:Z:\SAMB_4\projects\xilofono\src\main.c
+510 text5 CODE >158:Z:\SAMB_4\projects\xilofono\src\main.c
+51C text5 CODE >160:Z:\SAMB_4\projects\xilofono\src\main.c
+522 text5 CODE >162:Z:\SAMB_4\projects\xilofono\src\main.c
+526 text5 CODE >166:Z:\SAMB_4\projects\xilofono\src\main.c
+52C text5 CODE >167:Z:\SAMB_4\projects\xilofono\src\main.c
+530 text5 CODE >168:Z:\SAMB_4\projects\xilofono\src\main.c
+534 text5 CODE >169:Z:\SAMB_4\projects\xilofono\src\main.c
+538 text5 CODE >172:Z:\SAMB_4\projects\xilofono\src\main.c
+53A text5 CODE >173:Z:\SAMB_4\projects\xilofono\src\main.c
+53C text5 CODE >176:Z:\SAMB_4\projects\xilofono\src\main.c
+53E text5 CODE >177:Z:\SAMB_4\projects\xilofono\src\main.c
+540 text5 CODE >178:Z:\SAMB_4\projects\xilofono\src\main.c
+542 text5 CODE >179:Z:\SAMB_4\projects\xilofono\src\main.c
+544 text5 CODE >182:Z:\SAMB_4\projects\xilofono\src\main.c
+546 text5 CODE >184:Z:\SAMB_4\projects\xilofono\src\main.c
+548 text5 CODE >186:Z:\SAMB_4\projects\xilofono\src\main.c
+54A text5 CODE >188:Z:\SAMB_4\projects\xilofono\src\main.c
+54C text5 CODE >193:Z:\SAMB_4\projects\xilofono\src\main.c
+550 text5 CODE >195:Z:\SAMB_4\projects\xilofono\src\main.c
+558 text5 CODE >197:Z:\SAMB_4\projects\xilofono\src\main.c
+55C text5 CODE >199:Z:\SAMB_4\projects\xilofono\src\main.c
+55E text5 CODE >202:Z:\SAMB_4\projects\xilofono\src\main.c
+560 text5 CODE >203:Z:\SAMB_4\projects\xilofono\src\main.c
+562 text5 CODE >206:Z:\SAMB_4\projects\xilofono\src\main.c
+564 text5 CODE >209:Z:\SAMB_4\projects\xilofono\src\main.c
+568 text5 CODE >210:Z:\SAMB_4\projects\xilofono\src\main.c
+56C text5 CODE >211:Z:\SAMB_4\projects\xilofono\src\main.c
+56E text4 CODE >8:C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
+56E text4 CODE >18:C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
+576 text4 CODE >19:C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
+578 text4 CODE >20:C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
+588 text4 CODE >19:C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
+59A text3 CODE >51:Z:\SAMB_4\projects\xilofono\src\midi.c
+59A text3 CODE >53:Z:\SAMB_4\projects\xilofono\src\midi.c
+5A2 text3 CODE >57:Z:\SAMB_4\projects\xilofono\src\midi.c
+5C0 text2 CODE >40:Z:\SAMB_4\projects\xilofono\src\midi.c
+5C0 text2 CODE >42:Z:\SAMB_4\projects\xilofono\src\midi.c
+5C8 text2 CODE >46:Z:\SAMB_4\projects\xilofono\src\midi.c
+4A6 text1 CODE >62:Z:\SAMB_4\projects\xilofono\src\midi.c
+4A6 text1 CODE >64:Z:\SAMB_4\projects\xilofono\src\midi.c
+4B0 text1 CODE >74:Z:\SAMB_4\projects\xilofono\src\midi.c
+4C0 text1 CODE >75:Z:\SAMB_4\projects\xilofono\src\midi.c
+4D4 text1 CODE >77:Z:\SAMB_4\projects\xilofono\src\midi.c
+4E6 text1 CODE >78:Z:\SAMB_4\projects\xilofono\src\midi.c
+4F6 text1 CODE >81:Z:\SAMB_4\projects\xilofono\src\midi.c
+356 text0 CODE >215:Z:\SAMB_4\projects\xilofono\src\main.c
+356 text0 CODE >221:Z:\SAMB_4\projects\xilofono\src\main.c
+35A text0 CODE >224:Z:\SAMB_4\projects\xilofono\src\main.c
+376 text0 CODE >226:Z:\SAMB_4\projects\xilofono\src\main.c
+378 text0 CODE >229:Z:\SAMB_4\projects\xilofono\src\main.c
+37A text0 CODE >232:Z:\SAMB_4\projects\xilofono\src\main.c
+398 text0 CODE >235:Z:\SAMB_4\projects\xilofono\src\main.c
+398 text0 CODE >237:Z:\SAMB_4\projects\xilofono\src\main.c
+3AE text0 CODE >238:Z:\SAMB_4\projects\xilofono\src\main.c
+3DA text0 CODE >241:Z:\SAMB_4\projects\xilofono\src\main.c
+3E0 text0 CODE >244:Z:\SAMB_4\projects\xilofono\src\main.c
+3EC text0 CODE >251:Z:\SAMB_4\projects\xilofono\src\main.c
+3FE text0 CODE >254:Z:\SAMB_4\projects\xilofono\src\main.c
+42C text0 CODE >237:Z:\SAMB_4\projects\xilofono\src\main.c
+42C text0 CODE >255:Z:\SAMB_4\projects\xilofono\src\main.c
+61C cinit CODE >1219:C:\Users\_prossn\AppData\Local\Temp\s514.
+61C cinit CODE >1221:C:\Users\_prossn\AppData\Local\Temp\s514.
+61C cinit CODE >1224:C:\Users\_prossn\AppData\Local\Temp\s514.
+61C cinit CODE >1239:C:\Users\_prossn\AppData\Local\Temp\s514.
+620 cinit CODE >1240:C:\Users\_prossn\AppData\Local\Temp\s514.
+622 cinit CODE >1241:C:\Users\_prossn\AppData\Local\Temp\s514.
+622 cinit CODE >1242:C:\Users\_prossn\AppData\Local\Temp\s514.
+624 cinit CODE >1243:C:\Users\_prossn\AppData\Local\Temp\s514.
+626 cinit CODE >1244:C:\Users\_prossn\AppData\Local\Temp\s514.
+628 cinit CODE >1250:C:\Users\_prossn\AppData\Local\Temp\s514.
+628 cinit CODE >1252:C:\Users\_prossn\AppData\Local\Temp\s514.
+62A cinit CODE >1253:C:\Users\_prossn\AppData\Local\Temp\s514.
+62C cinit CODE >1255:C:\Users\_prossn\AppData\Local\Temp\s514.
+62E cinit CODE >1256:C:\Users\_prossn\AppData\Local\Temp\s514.
+630 cinit CODE >1257:C:\Users\_prossn\AppData\Local\Temp\s514.
+632 cinit CODE >1258:C:\Users\_prossn\AppData\Local\Temp\s514.
# %SYMTAB Section
# An enumeration of all symbols in the program.
# The beginning of the section is indicated by %SYMTAB.
@@ -216,72 +223,71 @@ C6 intcode CODE >118:Z:\SAMB_4\projects\xilofono\src\main.c
%SYMTAB
__Lmediumconst 0 0 MEDIUMCONST 0 mediumconst dist/default/production\src.production.obj
__Hspace_0 30000E 0 ABS 0 - dist/default/production\src.production.obj
-__Hspace_1 69 0 ABS 0 - dist/default/production\src.production.obj
+__Hspace_1 B6 0 ABS 0 - dist/default/production\src.production.obj
__Hspace_2 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_IESO$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
-isr@data 18 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
-__end_of_midi_set_status 3FC 0 CODE 0 text2 dist/default/production\src.production.obj
+_eusart2_putch 636 0 CODE 0 text9 dist/default/production\src.production.obj
+__end_of_midi_set_status 5E4 0 CODE 0 text2 dist/default/production\src.production.obj
__Hibigdata 0 0 CODE 0 ibigdata dist/default/production\src.production.obj
-__mediumconst 0 0 MEDIUMCONST 0 mediumconst C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
+__mediumconst 0 0 MEDIUMCONST 0 mediumconst C:\Users\_prossn\AppData\Local\Temp\s514.obj
__Heeprom_data 0 0 EEDATA 0 eeprom_data dist/default/production\src.production.obj
+main@i AD 0 BANK0 1 cstackBANK0 dist/default/production\src.production.obj
__Lsmallconst 0 0 SMALLCONST 0 smallconst dist/default/production\src.production.obj
-___sp 0 0 STACK 2 stack C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
-_main 308 0 CODE 0 text0 dist/default/production\src.production.obj
-btemp 45 0 COMRAM 1 temp dist/default/production\src.production.obj
-isr@i 19 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
-start 1B8 0 CODE 0 init C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
+___sp 0 0 STACK 2 stack C:\Users\_prossn\AppData\Local\Temp\s514.obj
+_main 356 0 CODE 0 text0 dist/default/production\src.production.obj
+btemp 34 0 COMRAM 1 temp dist/default/production\src.production.obj
+isr@i 2A 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+start 352 0 CODE 0 init C:\Users\_prossn\AppData\Local\Temp\s514.obj
+_keys_data 62 0 BANK0 1 bssBANK0 dist/default/production\src.production.obj
__size_of_main 0 0 ABS 0 - dist/default/production\src.production.obj
-__HbssCOMRAM 0 0 ABS 0 bssCOMRAM dist/default/production\src.production.obj
-eusart_write_midi@data 21 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+eusart_write_midi@data 32 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
__CFG_CCP2MX$PORTC1 0 0 ABS 0 - dist/default/production\src.production.obj
-midi_note_on@channel 21 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
-__Hpowerup 1B8 0 CODE 0 powerup dist/default/production\src.production.obj
+midi_note_on@channel A4 0 BANK0 1 cstackBANK0 dist/default/production\src.production.obj
+__Hpowerup 352 0 CODE 0 powerup dist/default/production\src.production.obj
__CFG_CCP3MX$PORTB5 0 0 ABS 0 - dist/default/production\src.production.obj
__size_of_eusart_write_midi 0 0 ABS 0 - dist/default/production\src.production.obj
-__HdataCOMRAM 0 0 ABS 0 dataCOMRAM dist/default/production\src.production.obj
-__accesstop 60 0 ABS 0 - C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
-intlevel0 0 0 CODE 0 text C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
-intlevel1 0 0 CODE 0 text C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
-intlevel2 0 0 CODE 0 text C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
-intlevel3 0 0 CODE 0 text C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
-__LbssCOMRAM 0 0 ABS 0 bssCOMRAM dist/default/production\src.production.obj
-_midi_set_status 3D8 0 CODE 0 text2 dist/default/production\src.production.obj
+__accesstop 60 0 ABS 0 - C:\Users\_prossn\AppData\Local\Temp\s514.obj
+intlevel0 0 0 CODE 0 text C:\Users\_prossn\AppData\Local\Temp\s514.obj
+intlevel1 0 0 CODE 0 text C:\Users\_prossn\AppData\Local\Temp\s514.obj
+intlevel2 0 0 CODE 0 text C:\Users\_prossn\AppData\Local\Temp\s514.obj
+intlevel3 0 0 CODE 0 text C:\Users\_prossn\AppData\Local\Temp\s514.obj
+_midi_set_status 5C0 0 CODE 0 text2 dist/default/production\src.production.obj
_OSCCONbits FD3 0 ABS 0 - dist/default/production\src.production.obj
__LnvFARRAM 0 0 FARRAM 0 nvFARRAM dist/default/production\src.production.obj
-wtemp6 46 0 COMRAM 1 temp dist/default/production\src.production.obj
+wtemp6 35 0 COMRAM 1 temp dist/default/production\src.production.obj
__CFG_EBTR0$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_EBTR1$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_EBTR2$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_EBTR3$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_EBTRB$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
-eusart_write_midi@pkt 1B 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+eusart_write_midi@pkt 2C 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
__CFG_P2BMX$PORTD2 0 0 ABS 0 - dist/default/production\src.production.obj
__Hifardata 0 0 CODE 0 ifardata dist/default/production\src.production.obj
__Hclrtext 0 0 ABS 0 clrtext dist/default/production\src.production.obj
-__pidataCOMRAM 424 0 CODE 0 idataCOMRAM dist/default/production\src.production.obj
__CFG_PRICLKEN$ON 0 0 ABS 0 - dist/default/production\src.production.obj
-midi_note_on@velocity 24 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+midi_note_on@velocity A7 0 BANK0 1 cstackBANK0 dist/default/production\src.production.obj
_ANSELA F38 0 ABS 0 - dist/default/production\src.production.obj
_ANSELB F39 0 ABS 0 - dist/default/production\src.production.obj
_ANSELC F3A 0 ABS 0 - dist/default/production\src.production.obj
_ANSELD F3B 0 ABS 0 - dist/default/production\src.production.obj
-___inthi_sp 0 0 STACK 2 stack C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
-___intlo_sp 0 0 STACK 2 stack C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
-__LdataCOMRAM 0 0 ABS 0 dataCOMRAM dist/default/production\src.production.obj
+___inthi_sp 0 0 STACK 2 stack C:\Users\_prossn\AppData\Local\Temp\s514.obj
+___intlo_sp 0 0 STACK 2 stack C:\Users\_prossn\AppData\Local\Temp\s514.obj
__size_of_init_hw 0 0 ABS 0 - dist/default/production\src.production.obj
-eusart_write_midi@length 1F 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+eusart_write_midi@length 30 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
__Hintcode_body 0 0 ABS 0 intcode_body dist/default/production\src.production.obj
+__size_of_eusart2_putch 0 0 ABS 0 - dist/default/production\src.production.obj
+main@message AF 0 BANK0 1 cstackBANK0 dist/default/production\src.production.obj
__Lintsave_regs 0 0 BIGRAM 1 intsave_regs dist/default/production\src.production.obj
_TXSTA1bits FAC 0 ABS 0 - dist/default/production\src.production.obj
+_TXSTA2bits F72 0 ABS 0 - dist/default/production\src.production.obj
__Hmediumconst 0 0 MEDIUMCONST 0 mediumconst dist/default/production\src.production.obj
-__Hintcodelo 1B8 0 CODE 0 intcodelo dist/default/production\src.production.obj
-midi_note_on@note 23 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+__Hintcodelo 352 0 CODE 0 intcodelo dist/default/production\src.production.obj
+midi_note_on@note A6 0 BANK0 1 cstackBANK0 dist/default/production\src.production.obj
_OSCTUNEbits F9B 0 ABS 0 - dist/default/production\src.production.obj
-__LidataCOMRAM 0 0 ABS 0 idataCOMRAM dist/default/production\src.production.obj
-__size_of_putch 0 0 ABS 0 - dist/default/production\src.production.obj
-__Lintcodelo 1B8 0 CODE 0 intcodelo dist/default/production\src.production.obj
+__end_of_eusart2_putch 642 0 CODE 0 text9 dist/default/production\src.production.obj
+__Lintcodelo 352 0 CODE 0 intcodelo dist/default/production\src.production.obj
__CFG_FCMEN$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
-start_initialization 354 0 CODE 0 cinit dist/default/production\src.production.obj
+start_initialization 61C 0 CODE 0 cinit dist/default/production\src.production.obj
__CFG_PBADEN$ON 0 0 ABS 0 - dist/default/production\src.production.obj
__HnvFARRAM 0 0 FARRAM 0 nvFARRAM dist/default/production\src.production.obj
__size_of_midi_set_status 0 0 ABS 0 - dist/default/production\src.production.obj
@@ -289,13 +295,15 @@ _TRISCbits F94 0 ABS 0 - dist/default/production\src.production.obj
_TRISDbits F95 0 ABS 0 - dist/default/production\src.production.obj
___rparam_used 1 0 ABS 0 - dist/default/production\src.production.obj
_RC1REG FAE 0 ABS 0 - dist/default/production\src.production.obj
-__end_of_memset 3B2 0 CODE 0 text4 dist/default/production\src.production.obj
-__end_of_eusart_write_midi 2A8 0 CODE 0 text7 dist/default/production\src.production.obj
+__end_of_memset 59A 0 CODE 0 text4 dist/default/production\src.production.obj
+__end_of_eusart_write_midi 4A6 0 CODE 0 text8 dist/default/production\src.production.obj
__CFG_WDTPS$32768 0 0 ABS 0 - dist/default/production\src.production.obj
_SPBRG1 FAF 0 ABS 0 - dist/default/production\src.production.obj
-__pcstackBANK0 60 0 BANK0 1 cstackBANK0 dist/default/production\src.production.obj
+_SPBRG2 F75 0 ABS 0 - dist/default/production\src.production.obj
+__pcstackBANK0 A2 0 BANK0 1 cstackBANK0 dist/default/production\src.production.obj
_TX1REG FAD 0 ABS 0 - dist/default/production\src.production.obj
-__end_of_init_hw 308 0 CODE 0 text5 dist/default/production\src.production.obj
+_TX2REG F73 0 ABS 0 - dist/default/production\src.production.obj
+__end_of_init_hw 56E 0 CODE 0 text5 dist/default/production\src.production.obj
__Hbank0 0 0 ABS 0 bank0 dist/default/production\src.production.obj
__Hbank1 0 0 ABS 0 bank1 dist/default/production\src.production.obj
__Hbank2 0 0 ABS 0 bank2 dist/default/production\src.production.obj
@@ -319,13 +327,14 @@ __Htext5 0 0 ABS 0 text5 dist/default/production\src.production.obj
__Htext6 0 0 ABS 0 text6 dist/default/production\src.production.obj
__Htext7 0 0 ABS 0 text7 dist/default/production\src.production.obj
__Htext8 0 0 ABS 0 text8 dist/default/production\src.production.obj
+__Htext9 0 0 ABS 0 text9 dist/default/production\src.production.obj
__Hbigbss 0 0 BIGRAM 1 bigbss dist/default/production\src.production.obj
__Hbigram 0 0 ABS 0 bigram dist/default/production\src.production.obj
-__smallconst 0 0 SMALLCONST 0 smallconst C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
+__smallconst 0 0 SMALLCONST 0 smallconst C:\Users\_prossn\AppData\Local\Temp\s514.obj
__CFG_FOSC$INTIO7 0 0 ABS 0 - dist/default/production\src.production.obj
__Hcomram 0 0 ABS 0 comram dist/default/production\src.production.obj
__Hconfig 30000E 0 CONFIG 0 config dist/default/production\src.production.obj
-midi_note_on@pkt 1F 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+midi_note_on@pkt A2 0 BANK0 1 cstackBANK0 dist/default/production\src.production.obj
__Lbank0 0 0 ABS 0 bank0 dist/default/production\src.production.obj
__Lbank1 0 0 ABS 0 bank1 dist/default/production\src.production.obj
__Lbank2 0 0 ABS 0 bank2 dist/default/production\src.production.obj
@@ -349,6 +358,7 @@ __Ltext5 0 0 ABS 0 text5 dist/default/production\src.production.obj
__Ltext6 0 0 ABS 0 text6 dist/default/production\src.production.obj
__Ltext7 0 0 ABS 0 text7 dist/default/production\src.production.obj
__Ltext8 0 0 ABS 0 text8 dist/default/production\src.production.obj
+__Ltext9 0 0 ABS 0 text9 dist/default/production\src.production.obj
__Hfarbss 0 0 FARRAM 0 farbss dist/default/production\src.production.obj
__Lintcode_body 0 0 ABS 0 intcode_body dist/default/production\src.production.obj
_PORTAbits F80 0 ABS 0 - dist/default/production\src.production.obj
@@ -357,110 +367,118 @@ __CFG_T3CMX$PORTC0 0 0 ABS 0 - dist/default/production\src.production.obj
_INTCONbits FF2 0 ABS 0 - dist/default/production\src.production.obj
__Habs1 0 0 ABS 0 abs1 dist/default/production\src.production.obj
__Hdata 0 0 ABS 0 data dist/default/production\src.production.obj
-__Hinit 1BC 0 CODE 0 init dist/default/production\src.production.obj
+__Hinit 356 0 CODE 0 init dist/default/production\src.production.obj
__Hrbit 0 0 COMRAM 1 rbit dist/default/production\src.production.obj
__Hrbss 0 0 COMRAM 1 rbss dist/default/production\src.production.obj
-__Htemp 46 0 COMRAM 1 temp dist/default/production\src.production.obj
+__Htemp 35 0 COMRAM 1 temp dist/default/production\src.production.obj
__Htext 0 0 ABS 0 text dist/default/production\src.production.obj
__Labs1 0 0 ABS 0 abs1 dist/default/production\src.production.obj
__Ldata 0 0 ABS 0 data dist/default/production\src.production.obj
-__Linit 1B8 0 CODE 0 init dist/default/production\src.production.obj
+__Linit 352 0 CODE 0 init dist/default/production\src.production.obj
__Lrbit 0 0 COMRAM 1 rbit dist/default/production\src.production.obj
__Lrbss 0 0 COMRAM 1 rbss dist/default/production\src.production.obj
-__Ltemp 45 0 COMRAM 1 temp dist/default/production\src.production.obj
+__Ltemp 34 0 COMRAM 1 temp dist/default/production\src.production.obj
__Ltext 0 0 ABS 0 text dist/default/production\src.production.obj
__CFG_XINST$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
-_keypresses 25 0 COMRAM 1 bssCOMRAM dist/default/production\src.production.obj
-memset@c 1C 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
-memset@n 1E 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
-memset@p 20 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+_keypresses 60 0 BANK0 1 bssBANK0 dist/default/production\src.production.obj
+memset@c 2D 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+memset@n 2F 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+memset@p 31 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
__LcstackBANK0 0 0 ABS 0 cstackBANK0 dist/default/production\src.production.obj
-int$flags 45 0 COMRAM 1 temp dist/default/production\src.production.obj
+int$flags 34 0 COMRAM 1 temp dist/default/production\src.production.obj
__HcstackCOMRAM 0 0 ABS 0 cstackCOMRAM dist/default/production\src.production.obj
__Hintret 0 0 ABS 0 intret dist/default/production\src.production.obj
__Hirdata 0 0 CODE 0 irdata dist/default/production\src.production.obj
_PR2 FBB 0 ABS 0 - dist/default/production\src.production.obj
__S0 30000E 0 ABS 0 - dist/default/production\src.production.obj
-__S1 69 0 ABS 0 - dist/default/production\src.production.obj
+__S1 B6 0 ABS 0 - dist/default/production\src.production.obj
__S2 0 0 ABS 0 - dist/default/production\src.production.obj
_isr 8 0 CODE 0 intcode dist/default/production\src.production.obj
-__HidataCOMRAM 0 0 ABS 0 idataCOMRAM dist/default/production\src.production.obj
__Lbigdata 0 0 BIGRAM 1 bigdata dist/default/production\src.production.obj
__Hnvrram 0 0 COMRAM 1 nvrram dist/default/production\src.production.obj
-_eusart_write_midi 234 0 CODE 0 text7 dist/default/production\src.production.obj
-__end_of_isr 1B8 0 CODE 0 intcode dist/default/production\src.production.obj
+_eusart_write_midi 432 0 CODE 0 text8 dist/default/production\src.production.obj
+__end_of_isr 352 0 CODE 0 intcode dist/default/production\src.production.obj
__CFG_BORV$190 0 0 ABS 0 - dist/default/production\src.production.obj
__Lintentry 0 0 ABS 0 intentry dist/default/production\src.production.obj
__Hramtop 600 0 RAM 0 ramtop dist/default/production\src.production.obj
__Hrparam 0 0 COMRAM 1 rparam dist/default/production\src.production.obj
-_midi_note_on 1BC 0 CODE 0 text1 dist/default/production\src.production.obj
+_midi_note_on 4A6 0 CODE 0 text1 dist/default/production\src.production.obj
__CFG_PWRTEN$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__activetblptr 2 0 ABS 0 - dist/default/production\src.production.obj
__Hstruct 0 0 COMRAM 1 struct dist/default/production\src.production.obj
+__LbssBANK0 0 0 ABS 0 bssBANK0 dist/default/production\src.production.obj
+isr@data_a 25 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+isr@data_b 26 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
_PIE1bits F9D 0 ABS 0 - dist/default/production\src.production.obj
__CFG_HFOFST$ON 0 0 ABS 0 - dist/default/production\src.production.obj
-_memset 386 0 CODE 0 text4 dist/default/production\src.production.obj
-memset@p1 1A 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+_memset 56E 0 CODE 0 text4 dist/default/production\src.production.obj
+memset@p1 2B 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
__Lbigbss 0 0 BIGRAM 1 bigbss dist/default/production\src.production.obj
__Lbigram 0 0 ABS 0 bigram dist/default/production\src.production.obj
-midi_set_channel@pkt 1A 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+midi_set_channel@pkt 2B 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
__Lcomram 0 0 ABS 0 comram dist/default/production\src.production.obj
__Lconfig 300000 0 CONFIG 0 config dist/default/production\src.production.obj
__CFG_WDTEN$ON 0 0 ABS 0 - dist/default/production\src.production.obj
_RCSTA1bits FAB 0 ABS 0 - dist/default/production\src.production.obj
+_RCSTA2bits F71 0 ABS 0 - dist/default/production\src.production.obj
__Lfarbss 0 0 FARRAM 0 farbss dist/default/production\src.production.obj
-_eusart1_init 3FC 0 CODE 0 text6 dist/default/production\src.production.obj
+_eusart1_init 600 0 CODE 0 text7 dist/default/production\src.production.obj
__Lfardata 0 0 FARRAM 0 fardata dist/default/production\src.production.obj
-midi_set_status@status 1C 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+midi_set_status@status 2D 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+_eusart2_init 5E4 0 CODE 0 text6 dist/default/production\src.production.obj
__size_of_midi_note_on 0 0 ABS 0 - dist/default/production\src.production.obj
-stackhi 5FF 0 ABS 0 - C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
-stacklo 69 0 ABS 0 - C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
+stackhi 5FF 0 ABS 0 - C:\Users\_prossn\AppData\Local\Temp\s514.obj
+stacklo B6 0 ABS 0 - C:\Users\_prossn\AppData\Local\Temp\s514.obj
__Lintcode 8 0 CODE 0 intcode dist/default/production\src.production.obj
__Lintret 0 0 ABS 0 intret dist/default/production\src.production.obj
__Lirdata 0 0 CODE 0 irdata dist/default/production\src.production.obj
-_midi_set_channel 3B2 0 CODE 0 text3 dist/default/production\src.production.obj
+_midi_set_channel 59A 0 CODE 0 text3 dist/default/production\src.production.obj
__Lspace_0 0 0 ABS 0 - dist/default/production\src.production.obj
__Lspace_1 0 0 ABS 0 - dist/default/production\src.production.obj
__Lspace_2 0 0 ABS 0 - dist/default/production\src.production.obj
-__pbssCOMRAM 25 0 COMRAM 1 bssCOMRAM dist/default/production\src.production.obj
__size_of_memset 0 0 ABS 0 - dist/default/production\src.production.obj
__HcstackBANK0 0 0 ABS 0 cstackBANK0 dist/default/production\src.production.obj
_PIR1bits F9E 0 ABS 0 - dist/default/production\src.production.obj
__CFG_LVP$ON 0 0 ABS 0 - dist/default/production\src.production.obj
+eusart2_putch@c 2B 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
__LcstackCOMRAM 0 0 ABS 0 cstackCOMRAM dist/default/production\src.production.obj
-end_of_initialization 378 0 CODE 0 cinit dist/default/production\src.production.obj
-__end_of_midi_note_on 234 0 CODE 0 text1 dist/default/production\src.production.obj
+end_of_initialization 628 0 CODE 0 cinit dist/default/production\src.production.obj
+__end_of_midi_note_on 50C 0 CODE 0 text1 dist/default/production\src.production.obj
__Lnvrram 0 0 COMRAM 1 nvrram dist/default/production\src.production.obj
__Hintentry 0 0 ABS 0 intentry dist/default/production\src.production.obj
__CFG_STVREN$ON 0 0 ABS 0 - dist/default/production\src.production.obj
-_midi_base_scale 43 0 COMRAM 1 dataCOMRAM dist/default/production\src.production.obj
__Hreset_vec 4 0 CODE 0 reset_vec dist/default/production\src.production.obj
__size_of_eusart1_init 0 0 ABS 0 - dist/default/production\src.production.obj
-_init_hw 2A8 0 CODE 0 text5 dist/default/production\src.production.obj
+__HbssBANK0 0 0 ABS 0 bssBANK0 dist/default/production\src.production.obj
+_init_hw 50C 0 CODE 0 text5 dist/default/production\src.production.obj
+__size_of_eusart2_init 0 0 ABS 0 - dist/default/production\src.production.obj
__Lramtop 600 0 RAM 0 ramtop dist/default/production\src.production.obj
__Lrparam 0 0 COMRAM 1 rparam dist/default/production\src.production.obj
-__pcinit 354 0 CODE 0 cinit dist/default/production\src.production.obj
-__ptext0 308 0 CODE 0 text0 dist/default/production\src.production.obj
-__ptext1 1BC 0 CODE 0 text1 dist/default/production\src.production.obj
-__ptext2 3D8 0 CODE 0 text2 dist/default/production\src.production.obj
-__ptext3 3B2 0 CODE 0 text3 dist/default/production\src.production.obj
-__ptext4 386 0 CODE 0 text4 dist/default/production\src.production.obj
-__ptext5 2A8 0 CODE 0 text5 dist/default/production\src.production.obj
-__ptext6 3FC 0 CODE 0 text6 dist/default/production\src.production.obj
-__ptext7 234 0 CODE 0 text7 dist/default/production\src.production.obj
-__ptext8 418 0 CODE 0 text8 dist/default/production\src.production.obj
+__pcinit 61C 0 CODE 0 cinit dist/default/production\src.production.obj
+__ptext0 356 0 CODE 0 text0 dist/default/production\src.production.obj
+__ptext1 4A6 0 CODE 0 text1 dist/default/production\src.production.obj
+__ptext2 5C0 0 CODE 0 text2 dist/default/production\src.production.obj
+__ptext3 59A 0 CODE 0 text3 dist/default/production\src.production.obj
+__ptext4 56E 0 CODE 0 text4 dist/default/production\src.production.obj
+__ptext5 50C 0 CODE 0 text5 dist/default/production\src.production.obj
+__ptext6 5E4 0 CODE 0 text6 dist/default/production\src.production.obj
+__ptext7 600 0 CODE 0 text7 dist/default/production\src.production.obj
+__ptext8 432 0 CODE 0 text8 dist/default/production\src.production.obj
+__ptext9 636 0 CODE 0 text9 dist/default/production\src.production.obj
__Lstruct 0 0 COMRAM 1 struct dist/default/production\src.production.obj
-__ramtop 600 0 RAM 0 ramtop C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
-putch@c 1A 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
-__Lpowerup 1B8 0 CODE 0 powerup dist/default/production\src.production.obj
+__ramtop 600 0 RAM 0 ramtop C:\Users\_prossn\AppData\Local\Temp\s514.obj
+__Lpowerup 352 0 CODE 0 powerup dist/default/production\src.production.obj
__Leeprom_data 0 0 EEDATA 0 eeprom_data dist/default/production\src.production.obj
-_isr$592 17 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
-midi_set_status@pkt 1A 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+_isr$595 27 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+_isr$596 28 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+_isr$605 29 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+midi_set_status@pkt 2B 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
__Lreset_vec 0 0 CODE 0 reset_vec dist/default/production\src.production.obj
-__end_of_eusart1_init 418 0 CODE 0 text6 dist/default/production\src.production.obj
+__end_of_eusart1_init 61C 0 CODE 0 text7 dist/default/production\src.production.obj
+__end_of_eusart2_init 600 0 CODE 0 text6 dist/default/production\src.production.obj
___param_bank 0 0 ABS 0 - dist/default/production\src.production.obj
__Hbigdata 0 0 BIGRAM 1 bigdata dist/default/production\src.production.obj
-__end_of__initialization 378 0 CODE 0 cinit dist/default/production\src.production.obj
+__end_of__initialization 628 0 CODE 0 cinit dist/default/production\src.production.obj
__CFG_WRT0$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_WRT1$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_WRT2$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
@@ -472,11 +490,12 @@ __CFG_WRTC$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_WRTD$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__Lclrtext 0 0 ABS 0 clrtext dist/default/production\src.production.obj
_SPBRGH1 FB0 0 ABS 0 - dist/default/production\src.production.obj
-__end_of_midi_set_channel 3D8 0 CODE 0 text3 dist/default/production\src.production.obj
+_SPBRGH2 F76 0 ABS 0 - dist/default/production\src.production.obj
+__end_of_midi_set_channel 5C0 0 CODE 0 text3 dist/default/production\src.production.obj
__pcstackCOMRAM 1 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
__size_of_midi_set_channel 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_BOREN$SBORDIS 0 0 ABS 0 - dist/default/production\src.production.obj
-__end_of_main 354 0 CODE 0 text0 dist/default/production\src.production.obj
+__end_of_main 432 0 CODE 0 text0 dist/default/production\src.production.obj
__pintcode 8 0 CODE 0 intcode dist/default/production\src.production.obj
_PORTA F80 0 ABS 0 - dist/default/production\src.production.obj
_PORTB F81 0 ABS 0 - dist/default/production\src.production.obj
@@ -484,7 +503,7 @@ _RC1IF 7CF5 0 ABS 0 - dist/default/production\src.production.obj
_TRISA F92 0 ABS 0 - dist/default/production\src.production.obj
_TRISB F93 0 ABS 0 - dist/default/production\src.production.obj
_TX1IF 7CF4 0 ABS 0 - dist/default/production\src.production.obj
-__end_of_putch 424 0 CODE 0 text8 dist/default/production\src.production.obj
+_TX2IF 7D24 0 ABS 0 - dist/default/production\src.production.obj
__CFG_CP0$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_CP1$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__HRAM 0 0 ABS 0 - dist/default/production\src.production.obj
@@ -498,21 +517,20 @@ __Lsfr 0 0 ABS 0 sfr dist/default/production\src.production.obj
__CFG_CP2$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_CP3$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__CFG_CPB$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
-_putch 418 0 CODE 0 text8 dist/default/production\src.production.obj
__CFG_CPD$OFF 0 0 ABS 0 - dist/default/production\src.production.obj
__size_of_isr 0 0 ABS 0 - dist/default/production\src.production.obj
-main@sample_message 62 0 BANK0 1 cstackBANK0 dist/default/production\src.production.obj
-__initialization 354 0 CODE 0 cinit dist/default/production\src.production.obj
+__initialization 61C 0 CODE 0 cinit dist/default/production\src.production.obj
_BAUDCON1bits FB8 0 ABS 0 - dist/default/production\src.production.obj
-__pdataCOMRAM 43 0 COMRAM 1 dataCOMRAM dist/default/production\src.production.obj
+_BAUDCON2bits F70 0 ABS 0 - dist/default/production\src.production.obj
+__pbssBANK0 60 0 BANK0 1 bssBANK0 dist/default/production\src.production.obj
_T2CONbits FBA 0 ABS 0 - dist/default/production\src.production.obj
__Hfardata 0 0 FARRAM 0 fardata dist/default/production\src.production.obj
__Hsmallconst 0 0 SMALLCONST 0 smallconst dist/default/production\src.production.obj
__Lifardata 0 0 CODE 0 ifardata dist/default/production\src.production.obj
__Hintsave_regs 0 0 BIGRAM 1 intsave_regs dist/default/production\src.production.obj
__CFG_MCLRE$EXTMCLR 0 0 ABS 0 - dist/default/production\src.production.obj
-midi_set_channel@channel 1C 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
-__Hintcode 1B8 0 CODE 0 intcode dist/default/production\src.production.obj
+midi_set_channel@channel 2D 0 COMRAM 1 cstackCOMRAM dist/default/production\src.production.obj
+__Hintcode 352 0 CODE 0 intcode dist/default/production\src.production.obj
# %SPLITSTAB Section
# This section enumerates all the psect splits performed by the assembler.
# The beginning of the section is indicated by %SPLITSTAB.
@@ -538,8 +556,8 @@ __Hintcode 1B8 0 CODE 0 intcode dist/default/production\src.production.obj
# All other numeric quantities are in decimal.
%SEGMENTS
idloc 0 200000 200000 8 1
-cstackCOMRAM 1 1 1 45 1
-cstackBANK0 1 60 60 9 1
+cstackCOMRAM 1 1 1 34 1
reset_vec 0 0 0 4 1
-intcode 0 8 8 41E 1
+bssBANK0 1 60 60 56 1
+intcode 0 8 8 63A 1
config 0 300000 300000 E 1
diff --git a/src/dist/default/production/src.production.elf b/src/dist/default/production/src.production.elf
index 8220677..261e62d 100644
--- a/src/dist/default/production/src.production.elf
+++ b/src/dist/default/production/src.production.elf
Binary files differ
diff --git a/src/dist/default/production/src.production.hex b/src/dist/default/production/src.production.hex
index 579dfa8..98c8eeb 100644
--- a/src/dist/default/production/src.production.hex
+++ b/src/dist/default/production/src.production.hex
@@ -1,70 +1,104 @@
-:04000000DCEF00F041
-:100008004582FACF05F0FBCF06F0E9CF07F0EACF3B
-:1000180008F0E1CF09F0E2CF0AF0D9CF0BF0DACF40
-:100028000CF0F3CF0DF0F4CF0EF0F6CF0FF0F7CFC2
-:1000380010F0F8CF11F0F5CF12F045C013F046C01C
-:1000480014F047C015F048C016F083969EA289D0D8
-:1000580080CF18F0070E196E1950020D250EF324E3
-:10006800D96E000EF420DA6EDECF01F0DDCF02F09B
-:10007800D8900136023619C003F018C004F0032ADC
-:1000880002D0D8900432032EFCD7010E0416045077
-:100098000112000E02121950020D250EF324D96E1A
-:1000A800000EF420DA6E01C0DEFF02C0DDFF190683
-:1000B8001928D8A4D1D781CF18F0070E196E195076
-:1000C800020D250EF324D96E000EF420DA6EDECF71
-:1000D80001F0DDCF02F0D8900136023619C003F0E6
-:1000E80018C004F0032A02D0D8900432032EFCD79B
-:1000F800010E041604500112000E02121950020DCE
-:10010800250EF324D96E000EF420DA6E01C0DEFF4E
-:1001180002C0DDFFF80E016EFF0E026E19061928E7
-:10012800036E046A0150032602500422035004108F
-:10013800D8A4C5D780A002D0838801D08398000EA8
-:10014800176E25502610D8B406D0FF0E2614D8A452
-:1001580002D0010E176E17B002D0839401D08384A9
-:100168009E92838616C048F015C047F014C046F02A
-:1001780013C045F012C0F5FF11C0F8FF10C0F7FF1B
-:100188000FC0F6FF0EC0F4FF0DC0F3FF0CC0DAFF7E
-:100198000BC0D9FF0AC0E2FF09C0E1FF08C0EAFFAF
-:1001A80007C0E9FF06C0FBFF05C0FAFF4592110032
-:1001B800AAEF01F01F502010D8B41200030E1F241C
-:1001C8000001606F000E2020616F60516111D8B48A
-:1001D80012001FC01AF020C01BF0080E1C6EECECB9
-:1001E80001F01FC01AF020C01BF021C01CF022C073
-:1001F8001DF0D9EC01F020EE03F01F50D926205055
-:10020800DA2223C0DFFF20EE04F01F50D926205049
-:10021800DA2224C0DFFF20EE01F01F50D92620503B
-:10022800DA22020EDE6E000EDD6E12001B501C106C
-:10023800D8B4120020EE01F01B50D9261C50DA2247
-:10024800DECF1FF0DDCF20F0030E1B24216E000E41
-:100258001C20226E1BC0D9FF1CC0DAFFDF380F0B31
-:100268001D6E1BC0D9FF1CC0DAFFDF500F0B1E6EBE
-:100278001E38F00B1D100CEC02F009D021C0D9FF7C
-:1002880022C0DAFFDF500CEC02F0214A222A1F06B6
-:10029800D8A020061F28F2E12028D8B41200EED7F3
-:1002A800F29E9B8C9B809B829B849B869B889B9ABF
-:1002B800D388D38AD38CFC0ED316000E0F01386F67
-:1002C800000E396F000E3A6F000E3B6F926893680C
-:1002D800959295949596959883828394838683982E
-:1002E800800EBB6EBA50870B1809BA6E030EBA128D
-:1002F800BA849D829E92F28CFEEC01F0F28E12007E
-:1003080054EC01F0250E1A6E000E1B6E000E1D6EC9
-:10031800000E1C6E000E1F6E1E0E1E6EC3EC01F04A
-:10032800620E1F6E000E206E000E226E000E216EF1
-:100338003C0E236E7F0E246EDEEC00F08392620E7C
-:100348001B6E000E1C6E1AEC01F0F9D7240EF66E27
-:10035800040EF76E000EF86E0900F5CF43F00900A1
-:10036800F5CF44F000EE25F01E0EEE6AE806FDE13A
-:1003780045904592000EF86E000184EF01F01AC016
-:1003880020F01BC021F008D020C0D9FF21C0DAFF1F
-:100398001CC0DFFF204A212A1E06D8A01F061E28DF
-:1003A800F3E11F28D8B41200EFD71A501B10D8B4A5
-:1003B80012001CC01EF00F0E1E161AC0D9FF1BC05B
-:1003C800DAFF1E3ADF501E180F0B1E18DF6E1200E0
-:1003D8001A501B10D8B412001CC01DF00F0E1D16A9
-:1003E8001AC0D9FF1BC0DAFFDF501D18F00B1D180B
-:1003F800DF6E1200AC98AC9CAB8E1F0EAF6E000E79
-:10040800B06EAC94B896948E948CAB88AC8A12007B
-:0E0418001A6E9EA8FED71AC0ADFF12003C005F
+:04000000A9EF01F073
+:100008003482FACF13F0FBCF14F0E9CF15F0EACF22
+:1000180016F0E1CF17F0E2CF18F0D9CF19F0DACF08
+:100028001AF0F3CF1BF0F4CF1CF0F6CF1DF0F7CF8A
+:100038001EF0F8CF1FF0F5CF20F034C021F035C006
+:1000480022F036C023F037C024F083969EA256D102
+:1000580080CF25F081CF26F0070E2A6E2A50040D96
+:10006800620EF324D96E000EF420DA6EDECF01F0B2
+:10007800DECF02F0DECF03F0DECF04F0D8900134FB
+:10008800056E0234066E0334076E0434086E2AC007
+:1000980009F025C00AF0092A02D0D8900A32092EA0
+:1000A800FCD7010E0A160A5005100B6E06500C6E8E
+:1000B80007500D6E08500E6E2A50040D620EF32480
+:1000C800D96E000EF420DA6E0BC0DEFF0CC0DEFF26
+:1000D8000DC0DEFF0EC0DEFF2A50016E026AD89006
+:1000E80001360236D89001360236200E0126000E5F
+:1000F8000222620E0124D96E000E0220DA6EDECFD3
+:1001080003F0DECF04F0DECF05F0DECF06F0D890A6
+:100118000334076E0434086E0534096E06340A6E1B
+:100128002AC00BF026C00CF00B2A02D0D8900C3253
+:100138000B2EFCD7010E0C160C5007100D6E085034
+:100148000E6E09500F6E0A50106E2A50116E126A08
+:10015800D89011361236D89011361236200E112644
+:10016800000E1222620E1124D96E000E1220DA6ED1
+:100178000DC0DEFF0EC0DEFF0FC0DEFF10C0DEFFC9
+:10018800000E276E2A50040D620EF324D96E000E5D
+:10019800F420DA6EDE50DE10DE10DE10D8B41CD08B
+:1001A8002A50040D620EF324D96E000EF420DA6E84
+:1001B800000EDE14016EFF0EDE14026EFF0EDE145A
+:1001C800036EFF0EDE14046E0150021003100410BB
+:1001D800D8A402D0010E276E2AC001F02750026E63
+:1001E800036A012A03D0D89002360336012EFBD7C2
+:1001F80002500001601303506113000E286E2A504C
+:10020800016E026AD89001360236D890013602365D
+:10021800200E0126000E0222620E0124D96E000E65
+:100228000220DA6EDE50DE10DE10DE10D8B427D0E1
+:100238002A50016E026AD89001360236D8900136EB
+:100248000236200E0126000E0222620E0124D96E0B
+:10025800000E0220DA6E000EDE14036EFF0EDE14AE
+:10026800046EFF0EDE14056EFF0EDE14066E0350DC
+:10027800041005100610D8A402D0010E286E2AC05A
+:1002880001F0080E01262850026E036A012A03D0E5
+:10029800D89002360336012EFBD7025000016013B6
+:1002A800035061132A062A28D8A4D8D680A002D0E1
+:1002B800838801D08398000E296E00016251631172
+:1002C80064116511D8B414D0000E6215016EFF0ECA
+:1002D8006315026EFF0E6415036EFF0E6515046E3E
+:1002E8000150021003100410D8A402D0010E296E88
+:1002F80029B002D0839401D083849E92838624C03F
+:1003080037F023C036F022C035F021C034F020C0C9
+:10031800F5FF1FC0F8FF1EC0F7FF1DC0F6FF1CC089
+:10032800F4FF1BC0F3FF1AC0DAFF19C0D9FF18C0C9
+:10033800E2FF17C0E1FF16C0EAFF15C0E9FF14C0CD
+:10034800FBFF13C0FAFF349211000EEF03F086ECA6
+:1003580002F0620E2B6E000E2C6E000E2E6E000E3A
+:100368002D6E000E306E400E2F6EB7EC02F0F28E3E
+:100378008392AF0E0001A26F000EA36F000EA56F4F
+:10038800000EA46F3C0EA66F7F0EA76F53EC02F011
+:10039800000E0001AE6F000EAD6FAE51F9E1100E08
+:1003A800AD5DD8B0F5D7ADC0A8F0010EA96F000EAD
+:1003B800AA6FA82B03D0D890A937AA37A82FFBD7A4
+:1003C80000016051A9176151AA17A951AA11D8B4FF
+:1003D80029D0AD513C0FB26FAF0E2C6E000E2D6EB2
+:1003E80019EC02F0D00E0001A86FC90EE82EFED756
+:1003F800A82FFCD700D0ADC0A8F0010E0001A96F4E
+:10040800000EAA6FA82B03D0D890A937AA37A82F17
+:10041800FBD70001A91DAB6FAA1DAC6FAB516017CC
+:10042800AC516117AD4BAE2BB8D72C502D10D8B4AA
+:10043800120020EE01F02C50D9262D50DA22DECF02
+:1004480030F0DDCF31F0030E2C24326E000E2D205B
+:10045800336E2CC0D9FF2DC0DAFFDF380F0B2E6E9C
+:100468002CC0D9FF2DC0DAFFDF500F0B2F6E2F38AD
+:10047800F00B2E101BEC03F009D032C0D9FF33C0AB
+:10048800DAFFDF501BEC03F0324A332A3006D8A0DB
+:1004980031063028F2E13128D8B41200EED7000135
+:1004A800A251A311D8B41200A2C02BF0A3C02CF003
+:1004B800080E2D6EE0EC02F0A2C02BF0A3C02CF0C9
+:1004C800A4C02DF0A5C02EF0CDEC02F0000120EE66
+:1004D80003F0A251D926A351DA22A6C0DFFF20EEED
+:1004E80004F0A251D926A351DA22A7C0DFFF20EEDB
+:1004F80001F0A251D926A351DA22020EDE6E000EB7
+:10050800DD6E1200F29E9B8C9B809B829B849B8657
+:100518009B889B9AD388D38AD38CFC0ED316000E63
+:100528000F01386F000E396F000E3A6F000E3B6FE7
+:1005380092689368959295949596959883828394FA
+:1005480083868398800EBB6EBA50870B0809BA6EF3
+:10055800030EBA12BA849D829E92F28C00EC03F0CC
+:10056800F2EC02F012002BC031F02CC032F008D0AF
+:1005780031C0D9FF32C0DAFF2DC0DFFF314A322A3D
+:100588002F06D8A030062F28F3E13028D8B412005F
+:10059800EFD72B502C10D8B412002DC02FF00F0E0F
+:1005A8002F162BC0D9FF2CC0DAFF2F3ADF502F1897
+:1005B8000F0B2F18DF6E12002B502C10D8B412001E
+:1005C8002DC02EF00F0E2E162BC0D9FF2CC0DAFF2F
+:1005D800DF502E18F00B2E18DF6E12007298729CE6
+:1005E800718E1F0E756E000E766E72947096958ED3
+:1005F800958C7188728A1200AC98AC9CAB8E1F0ED9
+:10060800AF6E000EB06EAC94B896948E948CAB8896
+:10061800AC8A120000EE60F0420EEE6AE806FDE1D8
+:1006280034903492000EF86E0001ABEF01F02B6E9F
+:0A063800A4A8FED72BC073FF120028
:020000040020DA
:08000000FFFFFFFFFFFFFFFF00
:020000040030CA
diff --git a/src/dist/default/production/src.production.hxl b/src/dist/default/production/src.production.hxl
index 848925e..f1c0046 100644
--- a/src/dist/default/production/src.production.hxl
+++ b/src/dist/default/production/src.production.hxl
@@ -2,13 +2,13 @@
### Memory Usage ###
Unused memory ranges:
4h - 7h
- 426h - 1FFFFFh
+ 642h - 1FFFFFh
200008h - 2FFFFFh
30000Eh - 30003Fh
dist/default/production\src.production.hex ranges:
0h - 3h
- 8h - 425h
+ 8h - 641h
200000h - 200007h
300000h - 30000Dh
@@ -40,6 +40,15 @@
00000340: 1111111111111111111111111111111111111111111111111111111111111111
00000380: 1111111111111111111111111111111111111111111111111111111111111111
000003C0: 1111111111111111111111111111111111111111111111111111111111111111
-00000400: 11111111111111111111111111111111111111--------------------------
+00000400: 1111111111111111111111111111111111111111111111111111111111111111
+00000440: 1111111111111111111111111111111111111111111111111111111111111111
+00000480: 1111111111111111111111111111111111111111111111111111111111111111
+000004C0: 1111111111111111111111111111111111111111111111111111111111111111
+00000500: 1111111111111111111111111111111111111111111111111111111111111111
+00000540: 1111111111111111111111111111111111111111111111111111111111111111
+00000580: 1111111111111111111111111111111111111111111111111111111111111111
+000005C0: 1111111111111111111111111111111111111111111111111111111111111111
+00000600: 1111111111111111111111111111111111111111111111111111111111111111
+00000640: 11--------------------------------------------------------------
00200000: 11111111--------------------------------------------------------
00300000: 11111111111111--------------------------------------------------
diff --git a/src/dist/default/production/src.production.lst b/src/dist/default/production/src.production.lst
index a97f5cc..95ed93a 100644
--- a/src/dist/default/production/src.production.lst
+++ b/src/dist/default/production/src.production.lst
@@ -1,1558 +1,1927 @@
Microchip Technology PIC18 LITE Macro Assembler V1.44 build -154322312
- Fri Feb 23 16:30:02 2018
+ Tue Feb 27 10:27:03 2018
Microchip Technology Omniscient Code Generator v1.44 (Free mode) build 201709140600
1 processor 18F45K22
2 fnconf rparam,??,?,0
3 opt pw 120
4 opt lm
- 5 psect idataCOMRAM,global,class=CODE,delta=1,noexec
- 6 psect cinit,global,reloc=2,class=CODE,delta=1
- 7 psect bssCOMRAM,global,class=COMRAM,space=1,delta=1,noexec
- 8 psect dataCOMRAM,global,class=COMRAM,space=1,delta=1,noexec
- 9 psect cstackBANK0,global,class=BANK0,space=1,delta=1,noexec
- 10 psect cstackCOMRAM,global,class=COMRAM,space=1,delta=1,noexec
- 11 psect text0,global,reloc=2,class=CODE,delta=1
- 12 psect text1,global,reloc=2,class=CODE,delta=1
- 13 psect text2,global,reloc=2,class=CODE,delta=1
- 14 psect text3,global,reloc=2,class=CODE,delta=1
- 15 psect text4,global,reloc=2,class=CODE,delta=1,group=1
- 16 psect text5,global,reloc=2,class=CODE,delta=1,inline
- 17 psect text6,global,reloc=2,class=CODE,delta=1
- 18 psect text7,global,reloc=2,class=CODE,delta=1
- 19 psect text8,global,reloc=2,class=CODE,delta=1
- 20 psect intcode,global,reloc=2,class=CODE,delta=1
- 21 psect intsave_regs,global,class=BIGRAM,space=1,delta=1,noexec
- 22 psect rparam,global,class=COMRAM,space=1,delta=1,noexec
- 23 psect temp,global,ovrld,common,class=COMRAM,space=1,delta=1
- 24 0000
- 25 ; Version 1.44
- 26 ; Generated 14/09/2017 GMT
- 27 ;
- 28 ; Copyright © 2017, Microchip Technology Inc. and its subsidiaries ("Microchip")
- 29 ; All rights reserved.
- 30 ;
- 31 ; This software is developed by Microchip Technology Inc. and its subsidiaries ("Microch
+ 5 psect cinit,global,reloc=2,class=CODE,delta=1
+ 6 psect bssBANK0,global,class=BANK0,space=1,delta=1,lowdata,noexec
+ 7 psect cstackBANK0,global,class=BANK0,space=1,delta=1,noexec
+ 8 psect cstackCOMRAM,global,class=COMRAM,space=1,delta=1,noexec
+ 9 psect text0,global,reloc=2,class=CODE,delta=1
+ 10 psect text1,global,reloc=2,class=CODE,delta=1
+ 11 psect text2,global,reloc=2,class=CODE,delta=1
+ 12 psect text3,global,reloc=2,class=CODE,delta=1
+ 13 psect text4,global,reloc=2,class=CODE,delta=1,group=1
+ 14 psect text5,global,reloc=2,class=CODE,delta=1,inline
+ 15 psect text6,global,reloc=2,class=CODE,delta=1
+ 16 psect text7,global,reloc=2,class=CODE,delta=1
+ 17 psect text8,global,reloc=2,class=CODE,delta=1
+ 18 psect text9,global,reloc=2,class=CODE,delta=1
+ 19 psect intcode,global,reloc=2,class=CODE,delta=1
+ 20 psect intsave_regs,global,class=BIGRAM,space=1,delta=1,noexec
+ 21 psect rparam,global,class=COMRAM,space=1,delta=1,noexec
+ 22 psect temp,global,ovrld,common,class=COMRAM,space=1,delta=1
+ 23 0000
+ 24 ; Version 1.44
+ 25 ; Generated 14/09/2017 GMT
+ 26 ;
+ 27 ; Copyright © 2017, Microchip Technology Inc. and its subsidiaries ("Microchip")
+ 28 ; All rights reserved.
+ 29 ;
+ 30 ; This software is developed by Microchip Technology Inc. and its subsidiaries ("Microch
+ ip").
- 32 ;
- 33 ; Redistribution and use in source and binary forms, with or without modification, are
- 34 ; permitted provided that the following conditions are met:
- 35 ;
- 36 ; 1. Redistributions of source code must retain the above copyright notice, this lis
+ 31 ;
+ 32 ; Redistribution and use in source and binary forms, with or without modification, are
+ 33 ; permitted provided that the following conditions are met:
+ 34 ;
+ 35 ; 1. Redistributions of source code must retain the above copyright notice, this lis
+ t of
- 37 ; conditions and the following disclaimer.
- 38 ;
- 39 ; 2. Redistributions in binary form must reproduce the above copyright notice, this
+ 36 ; conditions and the following disclaimer.
+ 37 ;
+ 38 ; 2. Redistributions in binary form must reproduce the above copyright notice, this
+ list
- 40 ; of conditions and the following disclaimer in the documentation and/or other
- 41 ; materials provided with the distribution.
- 42 ;
- 43 ; 3. Microchip's name may not be used to endorse or promote products derived from th
+ 39 ; of conditions and the following disclaimer in the documentation and/or other
+ 40 ; materials provided with the distribution.
+ 41 ;
+ 42 ; 3. Microchip's name may not be used to endorse or promote products derived from th
+ is
- 44 ; software without specific prior written permission.
- 45 ;
- 46 ; THIS SOFTWARE IS PROVIDED BY MICROCHIP "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
- 47 ; INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS F
+ 43 ; software without specific prior written permission.
+ 44 ;
+ 45 ; THIS SOFTWARE IS PROVIDED BY MICROCHIP "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
+ 46 ; INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS F
+ OR
- 48 ; PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL MICROCHIP BE LIABLE FOR ANY DIRECT, INDIREC
+ 47 ; PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL MICROCHIP BE LIABLE FOR ANY DIRECT, INDIREC
+ T,
- 49 ; INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING BUT NOT LIMITED TO
- 50 ; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA OR PROFITS; OR BUSINESS
- 51 ; INTERRUPTION) HOWSOEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, ST
+ 48 ; INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING BUT NOT LIMITED TO
+ 49 ; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA OR PROFITS; OR BUSINESS
+ 50 ; INTERRUPTION) HOWSOEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, ST
+ RICT
- 52 ; LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE U
+ 51 ; LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE U
+ SE OF
- 53 ; THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ 52 ; THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ 53 ;
54 ;
- 55 ;
- 56 ; Code-generator required, PIC18F45K22 Definitions
- 57 ;
- 58 ; SFR Addresses
- 59 0000
- 60 psect idataCOMRAM
- 61 000424 __pidataCOMRAM:
- 62 opt stack 0
- 63
- 64 ;initializer for _midi_base_scale
- 65 000424 003C dw 60
- 66 0000 _ANSELD set 3899
- 67 0000 _ANSELC set 3898
- 68 0000 _ANSELB set 3897
- 69 0000 _ANSELA set 3896
- 70 0000 _RC1REG set 4014
- 71 0000 _TX1REG set 4013
- 72 0000 _TRISCbits set 3988
- 73 0000 _BAUDCON1bits set 4024
- 74 0000 _SPBRGH1 set 4016
- 75 0000 _SPBRG1 set 4015
- 76 0000 _RCSTA1bits set 4011
- 77 0000 _TXSTA1bits set 4012
- 78 0000 _PIE1bits set 3997
- 79 0000 _T2CONbits set 4026
- 80 0000 _PR2 set 4027
- 81 0000 _TRISDbits set 3989
- 82 0000 _TRISB set 3987
- 83 0000 _TRISA set 3986
- 84 0000 _OSCCONbits set 4051
- 85 0000 _OSCTUNEbits set 3995
- 86 0000 _INTCONbits set 4082
- 87 0000 _PORTAbits set 3968
- 88 0000 _PORTB set 3969
- 89 0000 _PORTA set 3968
- 90 0000 _PIR1bits set 3998
- 91 0000 _PORTDbits set 3971
- 92 0000 _RC1IF set 31989
- 93 0000 _TX1IF set 31988
- 94
- 95 ; #config settings
- 96 0000
- 97 psect cinit
- 98 000354 __pcinit:
- 99 opt stack 0
- 100 000354 start_initialization:
- 101 opt stack 0
- 102 000354 __initialization:
- 103 opt stack 0
- 104
- 105 ; Initialize objects allocated to COMRAM (2 bytes)
- 106 ; load TBLPTR registers with __pidataCOMRAM
- 107 000354 0E24 movlw low __pidataCOMRAM
- 108 000356 6EF6 movwf tblptrl,c
- 109 000358 0E04 movlw high __pidataCOMRAM
- 110 00035A 6EF7 movwf tblptrh,c
- 111 00035C 0E00 movlw low (__pidataCOMRAM shr (0+16))
- 112 00035E 6EF8 movwf tblptru,c
- 113 000360 0009 tblrd *+ ;fetch initializer
- 114 000362 CFF5 F043 movff tablat,__pdataCOMRAM
- 115 000366 0009 tblrd *+ ;fetch initializer
- 116 000368 CFF5 F044 movff tablat,__pdataCOMRAM+1
- 117
- 118 ; Clear objects allocated to COMRAM (30 bytes)
- 119 00036C EE00 F025 lfsr 0,__pbssCOMRAM
- 120 000370 0E1E movlw 30
- 121 000372 clear_0:
- 122 000372 6AEE clrf postinc0,c
- 123 000374 06E8 decf wreg,f,c
- 124 000376 E1FD bnz clear_0
- 125 000378 end_of_initialization:
- 126 opt stack 0
- 127 000378 __end_of__initialization:
- 128 opt stack 0
- 129 000378 9045 bcf int$flags,0,c ;clear compiler interrupt flag (level 1)
- 130 00037A 9245 bcf int$flags,1,c ;clear compiler interrupt flag (level 2)
- 131 00037C 0E00 movlw low (__Lmediumconst shr (0+16))
- 132 00037E 6EF8 movwf tblptru,c
- 133 000380 0100 movlb 0
- 134 000382 EF84 F001 goto _main ;jump to C main() function
- 135 tblptru equ 0xFF8
- 136 tblptrh equ 0xFF7
- 137 tblptrl equ 0xFF6
- 138 tablat equ 0xFF5
- 139 postinc0 equ 0xFEE
- 140 wreg equ 0xFE8
- 141
- 142 psect bssCOMRAM
- 143 000025 __pbssCOMRAM:
- 144 opt stack 0
- 145 000025 _keypresses:
- 146 opt stack 0
- 147 000025 ds 30
- 148 tblptru equ 0xFF8
- 149 tblptrh equ 0xFF7
- 150 tblptrl equ 0xFF6
- 151 tablat equ 0xFF5
- 152 postinc0 equ 0xFEE
- 153 wreg equ 0xFE8
- 154
- 155 psect dataCOMRAM
- 156 000043 __pdataCOMRAM:
+ 55 ; Code-generator required, PIC18F45K22 Definitions
+ 56 ;
+ 57 ; SFR Addresses
+ 58 0000 _ANSELD set 3899
+ 59 0000 _ANSELC set 3898
+ 60 0000 _ANSELB set 3897
+ 61 0000 _ANSELA set 3896
+ 62 0000 _RC1REG set 4014
+ 63 0000 _TX2REG set 3955
+ 64 0000 _TX1REG set 4013
+ 65 0000 _BAUDCON2bits set 3952
+ 66 0000 _SPBRGH2 set 3958
+ 67 0000 _SPBRG2 set 3957
+ 68 0000 _RCSTA2bits set 3953
+ 69 0000 _TXSTA2bits set 3954
+ 70 0000 _TRISCbits set 3988
+ 71 0000 _BAUDCON1bits set 4024
+ 72 0000 _SPBRGH1 set 4016
+ 73 0000 _SPBRG1 set 4015
+ 74 0000 _RCSTA1bits set 4011
+ 75 0000 _TXSTA1bits set 4012
+ 76 0000 _PIE1bits set 3997
+ 77 0000 _T2CONbits set 4026
+ 78 0000 _PR2 set 4027
+ 79 0000 _TRISDbits set 3989
+ 80 0000 _TRISB set 3987
+ 81 0000 _TRISA set 3986
+ 82 0000 _OSCCONbits set 4051
+ 83 0000 _OSCTUNEbits set 3995
+ 84 0000 _INTCONbits set 4082
+ 85 0000 _PORTAbits set 3968
+ 86 0000 _PORTB set 3969
+ 87 0000 _PORTA set 3968
+ 88 0000 _PIR1bits set 3998
+ 89 0000 _PORTDbits set 3971
+ 90 0000 _RC1IF set 31989
+ 91 0000 _TX2IF set 32036
+ 92 0000 _TX1IF set 31988
+ 93
+ 94 ; #config settings
+ 95 0000
+ 96 psect cinit
+ 97 00061C __pcinit:
+ 98 opt stack 0
+ 99 00061C start_initialization:
+ 100 opt stack 0
+ 101 00061C __initialization:
+ 102 opt stack 0
+ 103
+ 104 ; Clear objects allocated to BANK0 (66 bytes)
+ 105 00061C EE00 F060 lfsr 0,__pbssBANK0
+ 106 000620 0E42 movlw 66
+ 107 000622 clear_0:
+ 108 000622 6AEE clrf postinc0,c
+ 109 000624 06E8 decf wreg,f,c
+ 110 000626 E1FD bnz clear_0
+ 111 000628 end_of_initialization:
+ 112 opt stack 0
+ 113 000628 __end_of__initialization:
+ 114 opt stack 0
+ 115 000628 9034 bcf int$flags,0,c ;clear compiler interrupt flag (level 1)
+ 116 00062A 9234 bcf int$flags,1,c ;clear compiler interrupt flag (level 2)
+ 117 00062C 0E00 movlw low (__Lmediumconst shr (0+16))
+ 118 00062E 6EF8 movwf tblptru,c
+ 119 000630 0100 movlb 0
+ 120 000632 EFAB F001 goto _main ;jump to C main() function
+ 121 tblptru equ 0xFF8
+ 122 postinc0 equ 0xFEE
+ 123 wreg equ 0xFE8
+ 124
+ 125 psect bssBANK0
+ 126 000060 __pbssBANK0:
+ 127 opt stack 0
+ 128 000060 _keypresses:
+ 129 opt stack 0
+ 130 000060 ds 2
+ 131 000062 _keys_data:
+ 132 opt stack 0
+ 133 000062 ds 64
+ 134 tblptru equ 0xFF8
+ 135 postinc0 equ 0xFEE
+ 136 wreg equ 0xFE8
+ 137
+ 138 psect cstackBANK0
+ 139 0000A2 __pcstackBANK0:
+ 140 opt stack 0
+ 141 0000A2 midi_note_on@pkt:
+ 142 opt stack 0
+ 143
+ 144 ; 2 bytes @ 0x0
+ 145 0000A2 ds 2
+ 146 0000A4 midi_note_on@channel:
+ 147 opt stack 0
+ 148
+ 149 ; 2 bytes @ 0x2
+ 150 0000A4 ds 2
+ 151 0000A6 midi_note_on@note:
+ 152 opt stack 0
+ 153
+ 154 ; 1 bytes @ 0x4
+ 155 0000A6 ds 1
+ 156 0000A7 midi_note_on@velocity:
157 opt stack 0
- 158 000043 _midi_base_scale:
- 159 opt stack 0
- 160 000043 ds 2
- 161 tblptru equ 0xFF8
- 162 tblptrh equ 0xFF7
- 163 tblptrl equ 0xFF6
- 164 tablat equ 0xFF5
- 165 postinc0 equ 0xFEE
- 166 wreg equ 0xFE8
+ 158
+ 159 ; 1 bytes @ 0x5
+ 160 0000A7 ds 1
+ 161 0000A8 ??_main:
+ 162
+ 163 ; 1 bytes @ 0x6
+ 164 0000A8 ds 5
+ 165 0000AD main@i:
+ 166 opt stack 0
167
- 168 psect cstackBANK0
- 169 000060 __pcstackBANK0:
- 170 opt stack 0
- 171 000060 ??_midi_note_on:
+ 168 ; 2 bytes @ 0xB
+ 169 0000AD ds 2
+ 170 0000AF main@message:
+ 171 opt stack 0
172
- 173 ; 1 bytes @ 0x0
- 174 000060 ds 2
- 175 000062 main@sample_message:
- 176 opt stack 0
- 177
- 178 ; 7 bytes @ 0x2
- 179 000062 ds 7
- 180 tblptru equ 0xFF8
- 181 tblptrh equ 0xFF7
- 182 tblptrl equ 0xFF6
- 183 tablat equ 0xFF5
- 184 postinc0 equ 0xFEE
- 185 wreg equ 0xFE8
- 186
- 187 psect cstackCOMRAM
- 188 000001 __pcstackCOMRAM:
- 189 opt stack 0
- 190 000001 ??_isr:
- 191 000001
- 192 ; 1 bytes @ 0x0
- 193 000001 ds 22
- 194 000017 _isr$592:
- 195 opt stack 0
- 196
- 197 ; 1 bytes @ 0x16
- 198 000017 ds 1
- 199 000018 isr@data:
- 200 opt stack 0
- 201
- 202 ; 1 bytes @ 0x17
- 203 000018 ds 1
- 204 000019 isr@i:
- 205 opt stack 0
- 206
- 207 ; 1 bytes @ 0x18
- 208 000019 ds 1
- 209 00001A putch@c:
- 210 opt stack 0
- 211 00001A midi_set_status@pkt:
+ 173 ; 7 bytes @ 0xD
+ 174 0000AF ds 7
+ 175 tblptru equ 0xFF8
+ 176 postinc0 equ 0xFEE
+ 177 wreg equ 0xFE8
+ 178
+ 179 psect cstackCOMRAM
+ 180 000001 __pcstackCOMRAM:
+ 181 opt stack 0
+ 182 000001 ??_isr:
+ 183 000001
+ 184 ; 1 bytes @ 0x0
+ 185 000001 ds 36
+ 186 000025 isr@data_a:
+ 187 opt stack 0
+ 188
+ 189 ; 1 bytes @ 0x24
+ 190 000025 ds 1
+ 191 000026 isr@data_b:
+ 192 opt stack 0
+ 193
+ 194 ; 1 bytes @ 0x25
+ 195 000026 ds 1
+ 196 000027 _isr$595:
+ 197 opt stack 0
+ 198
+ 199 ; 1 bytes @ 0x26
+ 200 000027 ds 1
+ 201 000028 _isr$596:
+ 202 opt stack 0
+ 203
+ 204 ; 1 bytes @ 0x27
+ 205 000028 ds 1
+ 206 000029 _isr$605:
+ 207 opt stack 0
+ 208
+ 209 ; 1 bytes @ 0x28
+ 210 000029 ds 1
+ 211 00002A isr@i:
212 opt stack 0
- 213 00001A midi_set_channel@pkt:
- 214 opt stack 0
- 215 00001A memset@p1:
- 216 opt stack 0
- 217
- 218 ; 2 bytes @ 0x19
- 219 00001A ds 1
- 220 00001B eusart_write_midi@pkt:
+ 213
+ 214 ; 1 bytes @ 0x29
+ 215 00002A ds 1
+ 216 00002B eusart2_putch@c:
+ 217 opt stack 0
+ 218 00002B midi_set_status@pkt:
+ 219 opt stack 0
+ 220 00002B midi_set_channel@pkt:
221 opt stack 0
- 222
- 223 ; 2 bytes @ 0x1A
- 224 00001B ds 1
- 225 00001C midi_set_status@status:
- 226 opt stack 0
- 227 00001C midi_set_channel@channel:
+ 222 00002B memset@p1:
+ 223 opt stack 0
+ 224
+ 225 ; 2 bytes @ 0x2A
+ 226 00002B ds 1
+ 227 00002C eusart_write_midi@pkt:
228 opt stack 0
- 229 00001C memset@c:
- 230 opt stack 0
- 231
- 232 ; 2 bytes @ 0x1B
- 233 00001C ds 1
- 234 00001D ??_eusart_write_midi:
- 235 00001D ??_midi_set_status:
- 236
- 237 ; 1 bytes @ 0x1C
- 238 00001D ds 1
- 239 00001E ??_midi_set_channel:
- 240 00001E memset@n:
- 241 opt stack 0
- 242
- 243 ; 2 bytes @ 0x1D
- 244 00001E ds 1
- 245 00001F eusart_write_midi@length:
- 246 opt stack 0
- 247 00001F midi_note_on@pkt:
+ 229
+ 230 ; 2 bytes @ 0x2B
+ 231 00002C ds 1
+ 232 00002D midi_set_status@status:
+ 233 opt stack 0
+ 234 00002D midi_set_channel@channel:
+ 235 opt stack 0
+ 236 00002D memset@c:
+ 237 opt stack 0
+ 238
+ 239 ; 2 bytes @ 0x2C
+ 240 00002D ds 1
+ 241 00002E ??_eusart_write_midi:
+ 242 00002E ??_midi_set_status:
+ 243
+ 244 ; 1 bytes @ 0x2D
+ 245 00002E ds 1
+ 246 00002F ??_midi_set_channel:
+ 247 00002F memset@n:
248 opt stack 0
249
- 250 ; 2 bytes @ 0x1E
- 251 00001F ds 1
- 252 000020 memset@p:
+ 250 ; 2 bytes @ 0x2E
+ 251 00002F ds 1
+ 252 000030 eusart_write_midi@length:
253 opt stack 0
254
- 255 ; 2 bytes @ 0x1F
- 256 000020 ds 1
- 257 000021 eusart_write_midi@data:
+ 255 ; 2 bytes @ 0x2F
+ 256 000030 ds 1
+ 257 000031 memset@p:
258 opt stack 0
- 259 000021 midi_note_on@channel:
- 260 opt stack 0
- 261
- 262 ; 2 bytes @ 0x20
- 263 000021 ds 2
- 264 000023 midi_note_on@note:
- 265 opt stack 0
- 266
- 267 ; 1 bytes @ 0x22
- 268 000023 ds 1
- 269 000024 midi_note_on@velocity:
- 270 opt stack 0
- 271
- 272 ; 1 bytes @ 0x23
- 273 000024 ds 1
- 274 000025 tblptru equ 0xFF8
- 275 tblptrh equ 0xFF7
- 276 tblptrl equ 0xFF6
- 277 tablat equ 0xFF5
- 278 postinc0 equ 0xFEE
- 279 wreg equ 0xFE8
- 280
- 281 ; 1 bytes @ 0x24
- 282 ;;
- 283 ;;Main: autosize = 0, tempsize = 0, incstack = 0, save=0
- 284 ;;
- 285 ;; *************** function _main *****************
- 286 ;; Defined at:
- 287 ;; line 204 in file "main.c"
- 288 ;; Parameters: Size Location Type
- 289 ;; None
- 290 ;; Auto vars: Size Location Type
- 291 ;; sample_messa 7 2[BANK0 ] struct .
- 292 ;; data 1 0 unsigned char
- 293 ;; i 1 0 unsigned char
- 294 ;; Return value: Size Location Type
- 295 ;; 1 wreg void
- 296 ;; Registers used:
- 297 ;; wreg, fsr2l, fsr2h, status,2, status,0, cstack
- 298 ;; Tracked objects:
- 299 ;; On entry : 0/0
- 300 ;; On exit : 0/0
- 301 ;; Unchanged: 0/0
- 302 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- 303 ;; Params: 0 0 0 0 0 0 0
- 304 ;; Locals: 0 7 0 0 0 0 0
- 305 ;; Temps: 0 0 0 0 0 0 0
- 306 ;; Totals: 0 7 0 0 0 0 0
- 307 ;;Total ram usage: 7 bytes
- 308 ;; Hardware stack levels required when called: 3
- 309 ;; This function calls:
- 310 ;; _eusart_write_midi
- 311 ;; _init_hw
- 312 ;; _memset
- 313 ;; _midi_note_on
- 314 ;; This function is called by:
- 315 ;; Startup code after reset
- 316 ;; This function uses a non-reentrant model
- 317 ;;
- 318
- 319 psect text0
- 320 000308 __ptext0:
- 321 opt stack 0
- 322 000308 _main:
- 323 opt stack 28
- 324
- 325 ;main.c: 206: unsigned char i, data;
- 326 ;main.c: 207: midi_message_t sample_message;
- 327 ;main.c: 210: init_hw();
- 328
- 329 ;incstack = 0
- 330 000308 EC54 F001 call _init_hw ;wreg free
- 331
- 332 ;main.c: 213: memset(keypresses, 0, sizeof(keypresses));
- 333 00030C 0E25 movlw low _keypresses
- 334 00030E 6E1A movwf memset@p1,c
- 335 000310 0E00 movlw high _keypresses
- 336 000312 6E1B movwf memset@p1+1,c
- 337 000314 0E00 movlw 0
- 338 000316 6E1D movwf memset@c+1,c
- 339 000318 0E00 movlw 0
- 340 00031A 6E1C movwf memset@c,c
- 341 00031C 0E00 movlw 0
- 342 00031E 6E1F movwf memset@n+1,c
- 343 000320 0E1E movlw 30
- 344 000322 6E1E movwf memset@n,c
- 345 000324 ECC3 F001 call _memset ;wreg free
- 346
- 347 ;main.c: 216: midi_note_on(&sample_message, 0x0, 0x3C, 0x7F);
- 348 000328 0E62 movlw low main@sample_message
- 349 00032A 6E1F movwf midi_note_on@pkt,c
- 350 00032C 0E00 movlw high main@sample_message
- 351 00032E 6E20 movwf midi_note_on@pkt+1,c
- 352 000330 0E00 movlw 0
- 353 000332 6E22 movwf midi_note_on@channel+1,c
- 354 000334 0E00 movlw 0
- 355 000336 6E21 movwf midi_note_on@channel,c
- 356 000338 0E3C movlw 60
- 357 00033A 6E23 movwf midi_note_on@note,c
- 358 00033C 0E7F movlw 127
- 359 00033E 6E24 movwf midi_note_on@velocity,c
- 360 000340 ECDE F000 call _midi_note_on ;wreg free
- 361
- 362 ;main.c: 217: PORTDbits.RD1 = 0;
- 363 000344 9283 bcf 3971,1,c ;volatile
- 364 000346
- 365 ;main.c: 221: eusart_write_midi(&sample_message);
- 366 000346 0E62 movlw low main@sample_message
- 367 000348 6E1B movwf eusart_write_midi@pkt,c
- 368 00034A 0E00 movlw high main@sample_message
- 369 00034C 6E1C movwf eusart_write_midi@pkt+1,c
- 370 00034E EC1A F001 call _eusart_write_midi ;wreg free
- 371 000352 D7F9 goto l70
- 372 000354 __end_of_main:
- 373 opt stack 0
- 374 tblptru equ 0xFF8
- 375 tblptrh equ 0xFF7
- 376 tblptrl equ 0xFF6
- 377 tablat equ 0xFF5
- 378 postinc0 equ 0xFEE
- 379 wreg equ 0xFE8
- 380
- 381 ;; *************** function _midi_note_on *****************
- 382 ;; Defined at:
- 383 ;; line 62 in file "midi.c"
- 384 ;; Parameters: Size Location Type
- 385 ;; pkt 2 30[COMRAM] PTR struct .
- 386 ;; -> main@sample_message(7),
- 387 ;; channel 2 32[COMRAM] unsigned int
- 388 ;; note 1 34[COMRAM] enum E31
- 389 ;; velocity 1 35[COMRAM] unsigned char
- 390 ;; Auto vars: Size Location Type
- 391 ;; None
- 392 ;; Return value: Size Location Type
- 393 ;; 2 30[COMRAM] int
- 394 ;; Registers used:
- 395 ;; wreg, fsr2l, fsr2h, status,2, status,0, cstack
- 396 ;; Tracked objects:
- 397 ;; On entry : 0/0
- 398 ;; On exit : 0/0
- 399 ;; Unchanged: 0/0
- 400 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- 401 ;; Params: 6 0 0 0 0 0 0
- 402 ;; Locals: 0 0 0 0 0 0 0
- 403 ;; Temps: 0 2 0 0 0 0 0
- 404 ;; Totals: 6 2 0 0 0 0 0
- 405 ;;Total ram usage: 8 bytes
- 406 ;; Hardware stack levels used: 1
- 407 ;; Hardware stack levels required when called: 2
- 408 ;; This function calls:
- 409 ;; _midi_set_channel
- 410 ;; _midi_set_status
- 411 ;; This function is called by:
- 412 ;; _main
- 413 ;; This function uses a non-reentrant model
- 414 ;;
- 415
- 416 psect text1
- 417 0001BC __ptext1:
- 418 opt stack 0
- 419 0001BC _midi_note_on:
- 420 opt stack 28
- 421
- 422 ;midi.c: 64: if (pkt == (0)) {
- 423
- 424 ;incstack = 0
- 425 0001BC 501F movf midi_note_on@pkt,w,c
- 426 0001BE 1020 iorwf midi_note_on@pkt+1,w,c
- 427 0001C0 B4D8 btfsc status,2,c
- 428 0001C2 0012 return
+ 259
+ 260 ; 2 bytes @ 0x30
+ 261 000031 ds 1
+ 262 000032 eusart_write_midi@data:
+ 263 opt stack 0
+ 264
+ 265 ; 2 bytes @ 0x31
+ 266 000032 ds 2
+ 267 tblptru equ 0xFF8
+ 268 postinc0 equ 0xFEE
+ 269 wreg equ 0xFE8
+ 270
+ 271 ;;
+ 272 ;;Main: autosize = 0, tempsize = 5, incstack = 0, save=0
+ 273 ;;
+ 274 ;; *************** function _main *****************
+ 275 ;; Defined at:
+ 276 ;; line 215 in file "main.c"
+ 277 ;; Parameters: Size Location Type
+ 278 ;; None
+ 279 ;; Auto vars: Size Location Type
+ 280 ;; message 7 13[BANK0 ] struct .
+ 281 ;; i 2 11[BANK0 ] unsigned int
+ 282 ;; Return value: Size Location Type
+ 283 ;; 1 wreg void
+ 284 ;; Registers used:
+ 285 ;; wreg, fsr2l, fsr2h, status,2, status,0, cstack
+ 286 ;; Tracked objects:
+ 287 ;; On entry : 0/0
+ 288 ;; On exit : 0/0
+ 289 ;; Unchanged: 0/0
+ 290 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 291 ;; Params: 0 0 0 0 0 0 0
+ 292 ;; Locals: 0 9 0 0 0 0 0
+ 293 ;; Temps: 0 5 0 0 0 0 0
+ 294 ;; Totals: 0 14 0 0 0 0 0
+ 295 ;;Total ram usage: 14 bytes
+ 296 ;; Hardware stack levels required when called: 3
+ 297 ;; This function calls:
+ 298 ;; _eusart_write_midi
+ 299 ;; _init_hw
+ 300 ;; _memset
+ 301 ;; _midi_note_on
+ 302 ;; This function is called by:
+ 303 ;; Startup code after reset
+ 304 ;; This function uses a non-reentrant model
+ 305 ;;
+ 306
+ 307 psect text0
+ 308 000356 __ptext0:
+ 309 opt stack 0
+ 310 000356 _main:
+ 311 opt stack 28
+ 312
+ 313 ;main.c: 217: unsigned i;
+ 314 ;main.c: 218: midi_message_t message;
+ 315 ;main.c: 221: init_hw();
+ 316
+ 317 ;incstack = 0
+ 318 000356 EC86 F002 call _init_hw ;wreg free
+ 319
+ 320 ;main.c: 224: memset(keys_data, 0, sizeof(keys_data));
+ 321 00035A 0E62 movlw low _keys_data
+ 322 00035C 6E2B movwf memset@p1,c
+ 323 00035E 0E00 movlw high _keys_data
+ 324 000360 6E2C movwf memset@p1+1,c
+ 325 000362 0E00 movlw 0
+ 326 000364 6E2E movwf memset@c+1,c
+ 327 000366 0E00 movlw 0
+ 328 000368 6E2D movwf memset@c,c
+ 329 00036A 0E00 movlw 0
+ 330 00036C 6E30 movwf memset@n+1,c
+ 331 00036E 0E40 movlw 64
+ 332 000370 6E2F movwf memset@n,c
+ 333 000372 ECB7 F002 call _memset ;wreg free
+ 334
+ 335 ;main.c: 226: (INTCONbits.GIE = 1);
+ 336 000376 8EF2 bsf intcon,7,c ;volatile
+ 337
+ 338 ;main.c: 229: PORTDbits.RD1 = 0;
+ 339 000378 9283 bcf 3971,1,c ;volatile
+ 340
+ 341 ;main.c: 232: midi_note_on(&message, 0x0, 0x3C, 0x7F);
+ 342 00037A 0EAF movlw low main@message
+ 343 00037C 0100 movlb 0 ; () banked
+ 344 00037E 6FA2 movwf midi_note_on@pkt& (0+255),b
+ 345 000380 0E00 movlw high main@message
+ 346 000382 6FA3 movwf (midi_note_on@pkt+1)& (0+255),b
+ 347 000384 0E00 movlw 0
+ 348 000386 6FA5 movwf (midi_note_on@channel+1)& (0+255),b
+ 349 000388 0E00 movlw 0
+ 350 00038A 6FA4 movwf midi_note_on@channel& (0+255),b
+ 351 00038C 0E3C movlw 60
+ 352 00038E 6FA6 movwf midi_note_on@note& (0+255),b
+ 353 000390 0E7F movlw 127
+ 354 000392 6FA7 movwf midi_note_on@velocity& (0+255),b
+ 355 000394 EC53 F002 call _midi_note_on ;wreg free
+ 356 000398 l1202:
+ 357
+ 358 ;main.c: 237: for (i = 0; i < 16; i++) {
+ 359 000398 0E00 movlw 0
+ 360 00039A 0100 movlb 0 ; () banked
+ 361 00039C 6FAE movwf (main@i+1)& (0+255),b
+ 362 00039E 0E00 movlw 0
+ 363 0003A0 6FAD movwf main@i& (0+255),b
+ 364 0003A2 l1204:
+ 365
+ 366 ; BSR set to: 0
+ 367 0003A2 51AE movf (main@i+1)& (0+255),w,b
+ 368 0003A4 E1F9 bnz l1202
+ 369 0003A6 0E10 movlw 16
+ 370 0003A8 5DAD subwf main@i& (0+255),w,b
+ 371 0003AA B0D8 btfsc status,0,c
+ 372 0003AC D7F5 goto l76
+ 373
+ 374 ; BSR set to: 0
+ 375 ;main.c: 238: if (keypresses & (1<<i)) {
+ 376
+ 377 ; BSR set to: 0
+ 378
+ 379 ; BSR set to: 0
+ 380 0003AE C0AD F0A8 movff main@i,??_main
+ 381 0003B2 0E01 movlw 1
+ 382 0003B4 6FA9 movwf (??_main+1)& (0+255),b
+ 383 0003B6 0E00 movlw 0
+ 384 0003B8 6FAA movwf (??_main+2)& (0+255),b
+ 385 0003BA 2BA8 incf ??_main& (0+255),f,b
+ 386 0003BC D003 goto u524
+ 387 0003BE u525:
+ 388 0003BE 90D8 bcf status,0,c
+ 389 0003C0 37A9 rlcf (??_main+1)& (0+255),f,b
+ 390 0003C2 37AA rlcf (??_main+2)& (0+255),f,b
+ 391 0003C4 u524:
+ 392 0003C4 2FA8 decfsz ??_main& (0+255),f,b
+ 393 0003C6 D7FB goto u525
+ 394 0003C8 0100 movlb 0 ; () banked
+ 395 0003CA 5160 movf _keypresses& (0+255),w,b ;volatile
+ 396 0003CC 17A9 andwf (??_main+1)& (0+255),f,b
+ 397 0003CE 5161 movf (_keypresses+1)& (0+255),w,b ;volatile
+ 398 0003D0 17AA andwf (??_main+2)& (0+255),f,b
+ 399 0003D2 51A9 movf (??_main+1)& (0+255),w,b
+ 400 0003D4 11AA iorwf (??_main+2)& (0+255),w,b
+ 401 0003D6 B4D8 btfsc status,2,c
+ 402 0003D8 D029 goto l79
+ 403
+ 404 ; BSR set to: 0
+ 405 ;main.c: 241: message.data[0] = 0x3C + i;
+ 406 0003DA 51AD movf main@i& (0+255),w,b
+ 407 0003DC 0F3C addlw 60
+ 408 0003DE 6FB2 movwf (main@message+3)& (0+255),b
+ 409
+ 410 ; BSR set to: 0
+ 411 ;main.c: 244: eusart_write_midi(&message);
+ 412 0003E0 0EAF movlw low main@message
+ 413 0003E2 6E2C movwf eusart_write_midi@pkt,c
+ 414 0003E4 0E00 movlw high main@message
+ 415 0003E6 6E2D movwf eusart_write_midi@pkt+1,c
+ 416 0003E8 EC19 F002 call _eusart_write_midi ;wreg free
+ 417
+ 418 ;main.c: 251: _delay((unsigned long)((10)*(64000000/4000.0)));
+ 419 0003EC 0ED0 movlw 208
+ 420 0003EE 0100 movlb 0 ; () banked
+ 421 0003F0 6FA8 movwf ??_main& (0+255),b
+ 422 0003F2 0EC9 movlw 201
+ 423 0003F4 u577:
+ 424 0003F4 2EE8 decfsz wreg,f,c
+ 425 0003F6 D7FE bra u577
+ 426 0003F8 2FA8 decfsz ??_main& (0+255),f,b
+ 427 0003FA D7FC bra u577
+ 428 0003FC D000 nop2
429
- 430 ;midi.c: 66: }
- 431 ;midi.c: 68: if (pkt->data == (0)) {
- 432
- 433 ;midi.c: 65: return -1;
- 434 ; Return value of _midi_note_on is never used
- 435 0001C4 0E03 movlw 3
- 436 0001C6 241F addwf midi_note_on@pkt,w,c
- 437 0001C8 0100 movlb 0 ; () banked
- 438 0001CA 6F60 movwf ??_midi_note_on& (0+255),b
- 439 0001CC 0E00 movlw 0
- 440 0001CE 2020 addwfc midi_note_on@pkt+1,w,c
- 441 0001D0 6F61 movwf (??_midi_note_on+1)& (0+255),b
- 442 0001D2 5160 movf ??_midi_note_on& (0+255),w,b
- 443 0001D4 1161 iorwf (??_midi_note_on+1)& (0+255),w,b
- 444 0001D6 B4D8 btfsc status,2,c
- 445 0001D8 0012 return
- 446
- 447 ; BSR set to: 0
- 448 ;midi.c: 70: }
- 449 ;midi.c: 72: midi_set_status(pkt, NOTE_ON);
- 450
- 451 ; BSR set to: 0
- 452
- 453 ; BSR set to: 0
- 454 ;midi.c: 69: return -2;
- 455 ; Return value of _midi_note_on is never used
- 456 0001DA C01F F01A movff midi_note_on@pkt,midi_set_status@pkt
- 457 0001DE C020 F01B movff midi_note_on@pkt+1,midi_set_status@pkt+1
- 458 0001E2 0E08 movlw 8
- 459 0001E4 6E1C movwf midi_set_status@status,c
- 460 0001E6 ECEC F001 call _midi_set_status ;wreg free
- 461
- 462 ;midi.c: 73: midi_set_channel(pkt, channel);
- 463 0001EA C01F F01A movff midi_note_on@pkt,midi_set_channel@pkt
- 464 0001EE C020 F01B movff midi_note_on@pkt+1,midi_set_channel@pkt+1
- 465 0001F2 C021 F01C movff midi_note_on@channel,midi_set_channel@channel
- 466 0001F6 C022 F01D movff midi_note_on@channel+1,midi_set_channel@channel+1
- 467 0001FA ECD9 F001 call _midi_set_channel ;wreg free
- 468
- 469 ;midi.c: 75: pkt->data[0] = note;
- 470 0001FE EE20 F003 lfsr 2,3
- 471 000202 501F movf midi_note_on@pkt,w,c
- 472 000204 26D9 addwf fsr2l,f,c
- 473 000206 5020 movf midi_note_on@pkt+1,w,c
- 474 000208 22DA addwfc fsr2h,f,c
- 475 00020A C023 FFDF movff midi_note_on@note,indf2
- 476
- 477 ;midi.c: 76: pkt->data[1] = velocity;
- 478 00020E EE20 F004 lfsr 2,4
- 479 000212 501F movf midi_note_on@pkt,w,c
- 480 000214 26D9 addwf fsr2l,f,c
- 481 000216 5020 movf midi_note_on@pkt+1,w,c
- 482 000218 22DA addwfc fsr2h,f,c
- 483 00021A C024 FFDF movff midi_note_on@velocity,indf2
- 484
- 485 ;midi.c: 79: pkt->data_size = 2;
- 486 00021E EE20 F001 lfsr 2,1
- 487 000222 501F movf midi_note_on@pkt,w,c
- 488 000224 26D9 addwf fsr2l,f,c
- 489 000226 5020 movf midi_note_on@pkt+1,w,c
- 490 000228 22DA addwfc fsr2h,f,c
- 491 00022A 0E02 movlw 2
- 492 00022C 6EDE movwf postinc2,c
- 493 00022E 0E00 movlw 0
- 494 000230 6EDD movwf postdec2,c
- 495 000232 0012 return
- 496 000234 __end_of_midi_note_on:
- 497 opt stack 0
- 498 tblptru equ 0xFF8
- 499 tblptrh equ 0xFF7
- 500 tblptrl equ 0xFF6
- 501 tablat equ 0xFF5
- 502 postinc0 equ 0xFEE
- 503 wreg equ 0xFE8
- 504 indf2 equ 0xFDF
- 505 postinc2 equ 0xFDE
- 506 postdec2 equ 0xFDD
- 507 fsr2h equ 0xFDA
- 508 fsr2l equ 0xFD9
- 509 status equ 0xFD8
- 510
- 511 ;; *************** function _midi_set_status *****************
- 512 ;; Defined at:
- 513 ;; line 40 in file "midi.c"
- 514 ;; Parameters: Size Location Type
- 515 ;; pkt 2 25[COMRAM] PTR struct .
- 516 ;; -> main@sample_message(7),
- 517 ;; status 1 27[COMRAM] enum E40
- 518 ;; Auto vars: Size Location Type
- 519 ;; None
- 520 ;; Return value: Size Location Type
- 521 ;; 2 25[COMRAM] int
- 522 ;; Registers used:
- 523 ;; wreg, fsr2l, fsr2h, status,2, status,0
- 524 ;; Tracked objects:
- 525 ;; On entry : 0/0
- 526 ;; On exit : 0/0
- 527 ;; Unchanged: 0/0
- 528 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- 529 ;; Params: 3 0 0 0 0 0 0
- 530 ;; Locals: 0 0 0 0 0 0 0
- 531 ;; Temps: 1 0 0 0 0 0 0
- 532 ;; Totals: 4 0 0 0 0 0 0
- 533 ;;Total ram usage: 4 bytes
- 534 ;; Hardware stack levels used: 1
- 535 ;; Hardware stack levels required when called: 1
- 536 ;; This function calls:
- 537 ;; Nothing
- 538 ;; This function is called by:
- 539 ;; _midi_note_on
- 540 ;; _midi_note_off
- 541 ;; This function uses a non-reentrant model
- 542 ;;
+ 430 ;main.c: 254: keypresses &= ~(1<<i);
+ 431 0003FE C0AD F0A8 movff main@i,??_main
+ 432 000402 0E01 movlw 1
+ 433 000404 0100 movlb 0 ; () banked
+ 434 000406 6FA9 movwf (??_main+1)& (0+255),b
+ 435 000408 0E00 movlw 0
+ 436 00040A 6FAA movwf (??_main+2)& (0+255),b
+ 437 00040C 2BA8 incf ??_main& (0+255),f,b
+ 438 00040E D003 goto u544
+ 439 000410 u545:
+ 440 000410 90D8 bcf status,0,c
+ 441 000412 37A9 rlcf (??_main+1)& (0+255),f,b
+ 442 000414 37AA rlcf (??_main+2)& (0+255),f,b
+ 443 000416 u544:
+ 444 000416 2FA8 decfsz ??_main& (0+255),f,b
+ 445 000418 D7FB goto u545
+ 446 00041A 0100 movlb 0 ; () banked
+ 447 00041C 1DA9 comf (??_main+1)& (0+255),w,b
+ 448 00041E 6FAB movwf (??_main+3)& (0+255),b
+ 449 000420 1DAA comf (??_main+2)& (0+255),w,b
+ 450 000422 6FAC movwf (??_main+4)& (0+255),b
+ 451 000424 51AB movf (??_main+3)& (0+255),w,b
+ 452 000426 1760 andwf _keypresses& (0+255),f,b ;volatile
+ 453 000428 51AC movf (??_main+4)& (0+255),w,b
+ 454 00042A 1761 andwf (_keypresses+1)& (0+255),f,b ;volatile
+ 455 00042C l79:
+ 456
+ 457 ; BSR set to: 0
+ 458
+ 459 ; BSR set to: 0
+ 460 00042C 4BAD infsnz main@i& (0+255),f,b
+ 461 00042E 2BAE incf (main@i+1)& (0+255),f,b
+ 462 000430 D7B8 goto l1204
+ 463 000432 __end_of_main:
+ 464 opt stack 0
+ 465 tblptru equ 0xFF8
+ 466 intcon equ 0xFF2
+ 467 postinc0 equ 0xFEE
+ 468 wreg equ 0xFE8
+ 469 status equ 0xFD8
+ 470
+ 471 ;; *************** function _midi_note_on *****************
+ 472 ;; Defined at:
+ 473 ;; line 62 in file "midi.c"
+ 474 ;; Parameters: Size Location Type
+ 475 ;; pkt 2 0[BANK0 ] PTR struct .
+ 476 ;; -> main@message(7),
+ 477 ;; channel 2 2[BANK0 ] unsigned int
+ 478 ;; note 1 4[BANK0 ] enum E31
+ 479 ;; velocity 1 5[BANK0 ] unsigned char
+ 480 ;; Auto vars: Size Location Type
+ 481 ;; None
+ 482 ;; Return value: Size Location Type
+ 483 ;; 2 0[BANK0 ] int
+ 484 ;; Registers used:
+ 485 ;; wreg, fsr2l, fsr2h, status,2, status,0, cstack
+ 486 ;; Tracked objects:
+ 487 ;; On entry : 0/0
+ 488 ;; On exit : 0/0
+ 489 ;; Unchanged: 0/0
+ 490 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 491 ;; Params: 0 6 0 0 0 0 0
+ 492 ;; Locals: 0 0 0 0 0 0 0
+ 493 ;; Temps: 0 0 0 0 0 0 0
+ 494 ;; Totals: 0 6 0 0 0 0 0
+ 495 ;;Total ram usage: 6 bytes
+ 496 ;; Hardware stack levels used: 1
+ 497 ;; Hardware stack levels required when called: 2
+ 498 ;; This function calls:
+ 499 ;; _midi_set_channel
+ 500 ;; _midi_set_status
+ 501 ;; This function is called by:
+ 502 ;; _main
+ 503 ;; This function uses a non-reentrant model
+ 504 ;;
+ 505
+ 506 psect text1
+ 507 0004A6 __ptext1:
+ 508 opt stack 0
+ 509 0004A6 _midi_note_on:
+ 510 opt stack 28
+ 511
+ 512 ;midi.c: 64: if (pkt == (0)) {
+ 513
+ 514 ; BSR set to: 0
+ 515 ;incstack = 0
+ 516 0004A6 0100 movlb 0 ; () banked
+ 517 0004A8 51A2 movf midi_note_on@pkt& (0+255),w,b
+ 518 0004AA 11A3 iorwf (midi_note_on@pkt+1)& (0+255),w,b
+ 519 0004AC B4D8 btfsc status,2,c
+ 520 0004AE 0012 return
+ 521
+ 522 ; BSR set to: 0
+ 523 ;midi.c: 66: }
+ 524 ;midi.c: 74: midi_set_status(pkt, NOTE_ON);
+ 525
+ 526 ; BSR set to: 0
+ 527
+ 528 ; BSR set to: 0
+ 529 ;midi.c: 65: return -1;
+ 530 ; Return value of _midi_note_on is never used
+ 531 0004B0 C0A2 F02B movff midi_note_on@pkt,midi_set_status@pkt
+ 532 0004B4 C0A3 F02C movff midi_note_on@pkt+1,midi_set_status@pkt+1
+ 533 0004B8 0E08 movlw 8
+ 534 0004BA 6E2D movwf midi_set_status@status,c
+ 535 0004BC ECE0 F002 call _midi_set_status ;wreg free
+ 536
+ 537 ;midi.c: 75: midi_set_channel(pkt, channel);
+ 538 0004C0 C0A2 F02B movff midi_note_on@pkt,midi_set_channel@pkt
+ 539 0004C4 C0A3 F02C movff midi_note_on@pkt+1,midi_set_channel@pkt+1
+ 540 0004C8 C0A4 F02D movff midi_note_on@channel,midi_set_channel@channel
+ 541 0004CC C0A5 F02E movff midi_note_on@channel+1,midi_set_channel@channel+1
+ 542 0004D0 ECCD F002 call _midi_set_channel ;wreg free
543
- 544 psect text2
- 545 0003D8 __ptext2:
- 546 opt stack 0
- 547 0003D8 _midi_set_status:
- 548 opt stack 28
- 549
- 550 ;midi.c: 42: if (pkt == (0)) {
- 551
- 552 ;incstack = 0
- 553 0003D8 501A movf midi_set_status@pkt,w,c
- 554 0003DA 101B iorwf midi_set_status@pkt+1,w,c
- 555 0003DC B4D8 btfsc status,2,c
- 556 0003DE 0012 return
- 557
- 558 ;midi.c: 44: }
- 559 ;midi.c: 46: pkt->status = status & 0x0F;
- 560
- 561 ;midi.c: 43: return -1;
- 562 ; Return value of _midi_set_status is never used
- 563 0003E0 C01C F01D movff midi_set_status@status,??_midi_set_status
- 564 0003E4 0E0F movlw 15
- 565 0003E6 161D andwf ??_midi_set_status,f,c
- 566 0003E8 C01A FFD9 movff midi_set_status@pkt,fsr2l
- 567 0003EC C01B FFDA movff midi_set_status@pkt+1,fsr2h
- 568 0003F0 50DF movf indf2,w,c
- 569 0003F2 181D xorwf ??_midi_set_status,w,c
- 570 0003F4 0BF0 andlw -16
- 571 0003F6 181D xorwf ??_midi_set_status,w,c
- 572 0003F8 6EDF movwf indf2,c
- 573 0003FA 0012 return
- 574 0003FC __end_of_midi_set_status:
+ 544 ;midi.c: 77: pkt->data[0] = note;
+ 545 0004D4 0100 movlb 0 ; () banked
+ 546 0004D6 EE20 F003 lfsr 2,3
+ 547 0004DA 51A2 movf midi_note_on@pkt& (0+255),w,b
+ 548 0004DC 26D9 addwf fsr2l,f,c
+ 549 0004DE 51A3 movf (midi_note_on@pkt+1)& (0+255),w,b
+ 550 0004E0 22DA addwfc fsr2h,f,c
+ 551 0004E2 C0A6 FFDF movff midi_note_on@note,indf2
+ 552
+ 553 ; BSR set to: 0
+ 554 ;midi.c: 78: pkt->data[1] = velocity;
+ 555 0004E6 EE20 F004 lfsr 2,4
+ 556 0004EA 51A2 movf midi_note_on@pkt& (0+255),w,b
+ 557 0004EC 26D9 addwf fsr2l,f,c
+ 558 0004EE 51A3 movf (midi_note_on@pkt+1)& (0+255),w,b
+ 559 0004F0 22DA addwfc fsr2h,f,c
+ 560 0004F2 C0A7 FFDF movff midi_note_on@velocity,indf2
+ 561
+ 562 ; BSR set to: 0
+ 563 ;midi.c: 81: pkt->data_size = 2;
+ 564 0004F6 EE20 F001 lfsr 2,1
+ 565 0004FA 51A2 movf midi_note_on@pkt& (0+255),w,b
+ 566 0004FC 26D9 addwf fsr2l,f,c
+ 567 0004FE 51A3 movf (midi_note_on@pkt+1)& (0+255),w,b
+ 568 000500 22DA addwfc fsr2h,f,c
+ 569 000502 0E02 movlw 2
+ 570 000504 6EDE movwf postinc2,c
+ 571 000506 0E00 movlw 0
+ 572 000508 6EDD movwf postdec2,c
+ 573 00050A 0012 return
+ 574 00050C __end_of_midi_note_on:
575 opt stack 0
576 tblptru equ 0xFF8
- 577 tblptrh equ 0xFF7
- 578 tblptrl equ 0xFF6
- 579 tablat equ 0xFF5
- 580 postinc0 equ 0xFEE
- 581 wreg equ 0xFE8
- 582 indf2 equ 0xFDF
- 583 postinc2 equ 0xFDE
- 584 postdec2 equ 0xFDD
- 585 fsr2h equ 0xFDA
- 586 fsr2l equ 0xFD9
- 587 status equ 0xFD8
- 588
- 589 ;; *************** function _midi_set_channel *****************
- 590 ;; Defined at:
- 591 ;; line 51 in file "midi.c"
- 592 ;; Parameters: Size Location Type
- 593 ;; pkt 2 25[COMRAM] PTR struct .
- 594 ;; -> main@sample_message(7),
- 595 ;; channel 2 27[COMRAM] unsigned int
- 596 ;; Auto vars: Size Location Type
- 597 ;; None
- 598 ;; Return value: Size Location Type
- 599 ;; 2 25[COMRAM] int
- 600 ;; Registers used:
- 601 ;; wreg, fsr2l, fsr2h, status,2, status,0
- 602 ;; Tracked objects:
- 603 ;; On entry : 0/0
- 604 ;; On exit : 0/0
- 605 ;; Unchanged: 0/0
- 606 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- 607 ;; Params: 4 0 0 0 0 0 0
- 608 ;; Locals: 0 0 0 0 0 0 0
- 609 ;; Temps: 1 0 0 0 0 0 0
- 610 ;; Totals: 5 0 0 0 0 0 0
- 611 ;;Total ram usage: 5 bytes
- 612 ;; Hardware stack levels used: 1
- 613 ;; Hardware stack levels required when called: 1
- 614 ;; This function calls:
- 615 ;; Nothing
- 616 ;; This function is called by:
- 617 ;; _midi_note_on
- 618 ;; _midi_note_off
- 619 ;; This function uses a non-reentrant model
- 620 ;;
- 621
- 622 psect text3
- 623 0003B2 __ptext3:
- 624 opt stack 0
- 625 0003B2 _midi_set_channel:
- 626 opt stack 28
+ 577 intcon equ 0xFF2
+ 578 postinc0 equ 0xFEE
+ 579 wreg equ 0xFE8
+ 580 indf2 equ 0xFDF
+ 581 postinc2 equ 0xFDE
+ 582 postdec2 equ 0xFDD
+ 583 fsr2h equ 0xFDA
+ 584 fsr2l equ 0xFD9
+ 585 status equ 0xFD8
+ 586
+ 587 ;; *************** function _midi_set_status *****************
+ 588 ;; Defined at:
+ 589 ;; line 40 in file "midi.c"
+ 590 ;; Parameters: Size Location Type
+ 591 ;; pkt 2 42[COMRAM] PTR struct .
+ 592 ;; -> main@message(7),
+ 593 ;; status 1 44[COMRAM] enum E40
+ 594 ;; Auto vars: Size Location Type
+ 595 ;; None
+ 596 ;; Return value: Size Location Type
+ 597 ;; 2 42[COMRAM] int
+ 598 ;; Registers used:
+ 599 ;; wreg, fsr2l, fsr2h, status,2, status,0
+ 600 ;; Tracked objects:
+ 601 ;; On entry : 0/0
+ 602 ;; On exit : 0/0
+ 603 ;; Unchanged: 0/0
+ 604 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 605 ;; Params: 3 0 0 0 0 0 0
+ 606 ;; Locals: 0 0 0 0 0 0 0
+ 607 ;; Temps: 1 0 0 0 0 0 0
+ 608 ;; Totals: 4 0 0 0 0 0 0
+ 609 ;;Total ram usage: 4 bytes
+ 610 ;; Hardware stack levels used: 1
+ 611 ;; Hardware stack levels required when called: 1
+ 612 ;; This function calls:
+ 613 ;; Nothing
+ 614 ;; This function is called by:
+ 615 ;; _midi_note_on
+ 616 ;; _midi_note_off
+ 617 ;; This function uses a non-reentrant model
+ 618 ;;
+ 619
+ 620 psect text2
+ 621 0005C0 __ptext2:
+ 622 opt stack 0
+ 623 0005C0 _midi_set_status:
+ 624 opt stack 28
+ 625
+ 626 ;midi.c: 42: if (pkt == (0)) {
627
- 628 ;midi.c: 53: if (pkt == (0)) {
- 629
- 630 ;incstack = 0
- 631 0003B2 501A movf midi_set_channel@pkt,w,c
- 632 0003B4 101B iorwf midi_set_channel@pkt+1,w,c
- 633 0003B6 B4D8 btfsc status,2,c
- 634 0003B8 0012 return
- 635
- 636 ;midi.c: 55: }
- 637 ;midi.c: 57: pkt->channel = channel & 0x0F;
- 638
- 639 ;midi.c: 54: return -1;
- 640 ; Return value of _midi_set_channel is never used
- 641 0003BA C01C F01E movff midi_set_channel@channel,??_midi_set_channel
- 642 0003BE 0E0F movlw 15
- 643 0003C0 161E andwf ??_midi_set_channel,f,c
- 644 0003C2 C01A FFD9 movff midi_set_channel@pkt,fsr2l
- 645 0003C6 C01B FFDA movff midi_set_channel@pkt+1,fsr2h
- 646 0003CA 3A1E swapf ??_midi_set_channel,f,c
- 647 0003CC 50DF movf indf2,w,c
- 648 0003CE 181E xorwf ??_midi_set_channel,w,c
- 649 0003D0 0B0F andlw -241
- 650 0003D2 181E xorwf ??_midi_set_channel,w,c
- 651 0003D4 6EDF movwf indf2,c
- 652 0003D6 0012 return
- 653 0003D8 __end_of_midi_set_channel:
- 654 opt stack 0
- 655 tblptru equ 0xFF8
- 656 tblptrh equ 0xFF7
- 657 tblptrl equ 0xFF6
- 658 tablat equ 0xFF5
- 659 postinc0 equ 0xFEE
- 660 wreg equ 0xFE8
- 661 indf2 equ 0xFDF
- 662 postinc2 equ 0xFDE
- 663 postdec2 equ 0xFDD
- 664 fsr2h equ 0xFDA
- 665 fsr2l equ 0xFD9
- 666 status equ 0xFD8
- 667
- 668 ;; *************** function _memset *****************
- 669 ;; Defined at:
- 670 ;; line 8 in file "C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c"
- 671 ;; Parameters: Size Location Type
- 672 ;; p1 2 25[COMRAM] PTR void
- 673 ;; -> keypresses(30),
- 674 ;; c 2 27[COMRAM] int
- 675 ;; n 2 29[COMRAM] unsigned int
- 676 ;; Auto vars: Size Location Type
- 677 ;; p 2 31[COMRAM] PTR unsigned char
- 678 ;; -> keypresses(30),
- 679 ;; Return value: Size Location Type
- 680 ;; 2 25[COMRAM] PTR void
- 681 ;; Registers used:
- 682 ;; wreg, fsr2l, fsr2h, status,2, status,0
- 683 ;; Tracked objects:
- 684 ;; On entry : 0/0
- 685 ;; On exit : 0/0
- 686 ;; Unchanged: 0/0
- 687 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- 688 ;; Params: 6 0 0 0 0 0 0
- 689 ;; Locals: 2 0 0 0 0 0 0
- 690 ;; Temps: 0 0 0 0 0 0 0
- 691 ;; Totals: 8 0 0 0 0 0 0
- 692 ;;Total ram usage: 8 bytes
- 693 ;; Hardware stack levels used: 1
- 694 ;; Hardware stack levels required when called: 1
- 695 ;; This function calls:
- 696 ;; Nothing
- 697 ;; This function is called by:
- 698 ;; _main
- 699 ;; This function uses a non-reentrant model
- 700 ;;
- 701
- 702 psect text4
- 703 000386 __ptext4:
- 704 opt stack 0
- 705 000386 _memset:
- 706 opt stack 29
- 707
- 708 ;incstack = 0
- 709 000386 C01A F020 movff memset@p1,memset@p
- 710 00038A C01B F021 movff memset@p1+1,memset@p+1
- 711 00038E D008 goto l569
- 712 000390 l1129:
- 713 000390 C020 FFD9 movff memset@p,fsr2l
- 714 000394 C021 FFDA movff memset@p+1,fsr2h
- 715 000398 C01C FFDF movff memset@c,indf2
- 716 00039C 4A20 infsnz memset@p,f,c
- 717 00039E 2A21 incf memset@p+1,f,c
- 718 0003A0 l569:
- 719 0003A0 061E decf memset@n,f,c
- 720 0003A2 A0D8 btfss status,0,c
- 721 0003A4 061F decf memset@n+1,f,c
- 722 0003A6 281E incf memset@n,w,c
- 723 0003A8 E1F3 bnz l1129
- 724 0003AA 281F incf memset@n+1,w,c
- 725 0003AC B4D8 btfsc status,2,c
- 726 0003AE 0012 return
- 727 0003B0 D7EF goto l570
- 728 0003B2 __end_of_memset:
+ 628 ; BSR set to: 0
+ 629 ;incstack = 0
+ 630 0005C0 502B movf midi_set_status@pkt,w,c
+ 631 0005C2 102C iorwf midi_set_status@pkt+1,w,c
+ 632 0005C4 B4D8 btfsc status,2,c
+ 633 0005C6 0012 return
+ 634
+ 635 ;midi.c: 44: }
+ 636 ;midi.c: 46: pkt->status = status & 0x0F;
+ 637
+ 638 ;midi.c: 43: return -1;
+ 639 ; Return value of _midi_set_status is never used
+ 640 0005C8 C02D F02E movff midi_set_status@status,??_midi_set_status
+ 641 0005CC 0E0F movlw 15
+ 642 0005CE 162E andwf ??_midi_set_status,f,c
+ 643 0005D0 C02B FFD9 movff midi_set_status@pkt,fsr2l
+ 644 0005D4 C02C FFDA movff midi_set_status@pkt+1,fsr2h
+ 645 0005D8 50DF movf indf2,w,c
+ 646 0005DA 182E xorwf ??_midi_set_status,w,c
+ 647 0005DC 0BF0 andlw -16
+ 648 0005DE 182E xorwf ??_midi_set_status,w,c
+ 649 0005E0 6EDF movwf indf2,c
+ 650 0005E2 0012 return
+ 651 0005E4 __end_of_midi_set_status:
+ 652 opt stack 0
+ 653 tblptru equ 0xFF8
+ 654 intcon equ 0xFF2
+ 655 postinc0 equ 0xFEE
+ 656 wreg equ 0xFE8
+ 657 indf2 equ 0xFDF
+ 658 postinc2 equ 0xFDE
+ 659 postdec2 equ 0xFDD
+ 660 fsr2h equ 0xFDA
+ 661 fsr2l equ 0xFD9
+ 662 status equ 0xFD8
+ 663
+ 664 ;; *************** function _midi_set_channel *****************
+ 665 ;; Defined at:
+ 666 ;; line 51 in file "midi.c"
+ 667 ;; Parameters: Size Location Type
+ 668 ;; pkt 2 42[COMRAM] PTR struct .
+ 669 ;; -> main@message(7),
+ 670 ;; channel 2 44[COMRAM] unsigned int
+ 671 ;; Auto vars: Size Location Type
+ 672 ;; None
+ 673 ;; Return value: Size Location Type
+ 674 ;; 2 42[COMRAM] int
+ 675 ;; Registers used:
+ 676 ;; wreg, fsr2l, fsr2h, status,2, status,0
+ 677 ;; Tracked objects:
+ 678 ;; On entry : 0/0
+ 679 ;; On exit : 0/0
+ 680 ;; Unchanged: 0/0
+ 681 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 682 ;; Params: 4 0 0 0 0 0 0
+ 683 ;; Locals: 0 0 0 0 0 0 0
+ 684 ;; Temps: 1 0 0 0 0 0 0
+ 685 ;; Totals: 5 0 0 0 0 0 0
+ 686 ;;Total ram usage: 5 bytes
+ 687 ;; Hardware stack levels used: 1
+ 688 ;; Hardware stack levels required when called: 1
+ 689 ;; This function calls:
+ 690 ;; Nothing
+ 691 ;; This function is called by:
+ 692 ;; _midi_note_on
+ 693 ;; _midi_note_off
+ 694 ;; This function uses a non-reentrant model
+ 695 ;;
+ 696
+ 697 psect text3
+ 698 00059A __ptext3:
+ 699 opt stack 0
+ 700 00059A _midi_set_channel:
+ 701 opt stack 28
+ 702
+ 703 ;midi.c: 53: if (pkt == (0)) {
+ 704
+ 705 ;incstack = 0
+ 706 00059A 502B movf midi_set_channel@pkt,w,c
+ 707 00059C 102C iorwf midi_set_channel@pkt+1,w,c
+ 708 00059E B4D8 btfsc status,2,c
+ 709 0005A0 0012 return
+ 710
+ 711 ;midi.c: 55: }
+ 712 ;midi.c: 57: pkt->channel = channel & 0x0F;
+ 713
+ 714 ;midi.c: 54: return -1;
+ 715 ; Return value of _midi_set_channel is never used
+ 716 0005A2 C02D F02F movff midi_set_channel@channel,??_midi_set_channel
+ 717 0005A6 0E0F movlw 15
+ 718 0005A8 162F andwf ??_midi_set_channel,f,c
+ 719 0005AA C02B FFD9 movff midi_set_channel@pkt,fsr2l
+ 720 0005AE C02C FFDA movff midi_set_channel@pkt+1,fsr2h
+ 721 0005B2 3A2F swapf ??_midi_set_channel,f,c
+ 722 0005B4 50DF movf indf2,w,c
+ 723 0005B6 182F xorwf ??_midi_set_channel,w,c
+ 724 0005B8 0B0F andlw -241
+ 725 0005BA 182F xorwf ??_midi_set_channel,w,c
+ 726 0005BC 6EDF movwf indf2,c
+ 727 0005BE 0012 return
+ 728 0005C0 __end_of_midi_set_channel:
729 opt stack 0
730 tblptru equ 0xFF8
- 731 tblptrh equ 0xFF7
- 732 tblptrl equ 0xFF6
- 733 tablat equ 0xFF5
- 734 postinc0 equ 0xFEE
- 735 wreg equ 0xFE8
- 736 indf2 equ 0xFDF
- 737 postinc2 equ 0xFDE
- 738 postdec2 equ 0xFDD
- 739 fsr2h equ 0xFDA
- 740 fsr2l equ 0xFD9
- 741 status equ 0xFD8
- 742
- 743 ;; *************** function _init_hw *****************
- 744 ;; Defined at:
- 745 ;; line 140 in file "main.c"
- 746 ;; Parameters: Size Location Type
- 747 ;; None
- 748 ;; Auto vars: Size Location Type
- 749 ;; None
- 750 ;; Return value: Size Location Type
- 751 ;; 1 wreg void
- 752 ;; Registers used:
- 753 ;; wreg, status,2, cstack
- 754 ;; Tracked objects:
- 755 ;; On entry : 0/0
- 756 ;; On exit : 0/0
- 757 ;; Unchanged: 0/0
- 758 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- 759 ;; Params: 0 0 0 0 0 0 0
- 760 ;; Locals: 0 0 0 0 0 0 0
- 761 ;; Temps: 0 0 0 0 0 0 0
- 762 ;; Totals: 0 0 0 0 0 0 0
- 763 ;;Total ram usage: 0 bytes
- 764 ;; Hardware stack levels used: 1
- 765 ;; Hardware stack levels required when called: 2
- 766 ;; This function calls:
- 767 ;; _eusart1_init
- 768 ;; This function is called by:
- 769 ;; _main
- 770 ;; This function uses a non-reentrant model
- 771 ;;
- 772
- 773 psect text5
- 774 0002A8 __ptext5:
- 775 opt stack 0
- 776 0002A8 _init_hw:
- 777 opt stack 28
- 778
- 779 ;main.c: 142: (INTCONbits.GIE = 0);
+ 731 intcon equ 0xFF2
+ 732 postinc0 equ 0xFEE
+ 733 wreg equ 0xFE8
+ 734 indf2 equ 0xFDF
+ 735 postinc2 equ 0xFDE
+ 736 postdec2 equ 0xFDD
+ 737 fsr2h equ 0xFDA
+ 738 fsr2l equ 0xFD9
+ 739 status equ 0xFD8
+ 740
+ 741 ;; *************** function _memset *****************
+ 742 ;; Defined at:
+ 743 ;; line 8 in file "C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c"
+ 744 ;; Parameters: Size Location Type
+ 745 ;; p1 2 42[COMRAM] PTR void
+ 746 ;; -> keys_data(64),
+ 747 ;; c 2 44[COMRAM] int
+ 748 ;; n 2 46[COMRAM] unsigned int
+ 749 ;; Auto vars: Size Location Type
+ 750 ;; p 2 48[COMRAM] PTR unsigned char
+ 751 ;; -> keys_data(64),
+ 752 ;; Return value: Size Location Type
+ 753 ;; 2 42[COMRAM] PTR void
+ 754 ;; Registers used:
+ 755 ;; wreg, fsr2l, fsr2h, status,2, status,0
+ 756 ;; Tracked objects:
+ 757 ;; On entry : 0/0
+ 758 ;; On exit : 0/0
+ 759 ;; Unchanged: 0/0
+ 760 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 761 ;; Params: 6 0 0 0 0 0 0
+ 762 ;; Locals: 2 0 0 0 0 0 0
+ 763 ;; Temps: 0 0 0 0 0 0 0
+ 764 ;; Totals: 8 0 0 0 0 0 0
+ 765 ;;Total ram usage: 8 bytes
+ 766 ;; Hardware stack levels used: 1
+ 767 ;; Hardware stack levels required when called: 1
+ 768 ;; This function calls:
+ 769 ;; Nothing
+ 770 ;; This function is called by:
+ 771 ;; _main
+ 772 ;; This function uses a non-reentrant model
+ 773 ;;
+ 774
+ 775 psect text4
+ 776 00056E __ptext4:
+ 777 opt stack 0
+ 778 00056E _memset:
+ 779 opt stack 29
780
781 ;incstack = 0
- 782 0002A8 9EF2 bcf intcon,7,c ;volatile
- 783
- 784 ;main.c: 146: OSCTUNEbits.PLLEN = 1;
- 785 0002AA 8C9B bsf 3995,6,c ;volatile
- 786
- 787 ;main.c: 148: OSCTUNEbits.TUN = 0b011111;
- 788 0002AC 809B bsf 3995,0,c ;volatile
- 789 0002AE 829B bsf 3995,1,c ;volatile
- 790 0002B0 849B bsf 3995,2,c ;volatile
- 791 0002B2 869B bsf 3995,3,c ;volatile
- 792 0002B4 889B bsf 3995,4,c ;volatile
- 793 0002B6 9A9B bcf 3995,5,c ;volatile
- 794
- 795 ;main.c: 150: OSCCONbits.IRCF = 0b111;
- 796 0002B8 88D3 bsf 4051,4,c ;volatile
- 797 0002BA 8AD3 bsf 4051,5,c ;volatile
- 798 0002BC 8CD3 bsf 4051,6,c ;volatile
- 799
- 800 ;main.c: 152: OSCCONbits.SCS = 0b00;
- 801 0002BE 0EFC movlw -4
- 802 0002C0 16D3 andwf 4051,f,c ;volatile
- 803
- 804 ;main.c: 156: ANSELA = 0x00;
- 805 0002C2 0E00 movlw 0
- 806 0002C4 010F movlb 15 ; () banked
- 807 0002C6 6F38 movwf 56,b ;volatile
- 808
- 809 ;main.c: 157: ANSELB = 0x00;
- 810 0002C8 0E00 movlw 0
- 811 0002CA 6F39 movwf 57,b ;volatile
- 812
- 813 ;main.c: 158: ANSELC = 0x00;
- 814 0002CC 0E00 movlw 0
- 815 0002CE 6F3A movwf 58,b ;volatile
- 816
- 817 ;main.c: 159: ANSELD = 0x00;
- 818 0002D0 0E00 movlw 0
- 819 0002D2 6F3B movwf 59,b ;volatile
- 820
- 821 ; BSR set to: 15
- 822 ;main.c: 162: TRISA = 0xFF;
- 823 0002D4 6892 setf 3986,c ;volatile
- 824
- 825 ; BSR set to: 15
- 826 ;main.c: 163: TRISB = 0xFF;
- 827 0002D6 6893 setf 3987,c ;volatile
- 828
- 829 ; BSR set to: 15
- 830 ;main.c: 165: TRISDbits.TRISD1 = 0;
- 831 0002D8 9295 bcf 3989,1,c ;volatile
- 832
- 833 ; BSR set to: 15
- 834 ;main.c: 166: TRISDbits.TRISD2 = 0;
- 835 0002DA 9495 bcf 3989,2,c ;volatile
- 836
- 837 ; BSR set to: 15
- 838 ;main.c: 167: TRISDbits.TRISD3 = 0;
- 839 0002DC 9695 bcf 3989,3,c ;volatile
- 840
- 841 ; BSR set to: 15
- 842 ;main.c: 168: TRISDbits.TRISD4 = 0;
- 843 0002DE 9895 bcf 3989,4,c ;volatile
+ 782 00056E C02B F031 movff memset@p1,memset@p
+ 783 000572 C02C F032 movff memset@p1+1,memset@p+1
+ 784 000576 D008 goto l596
+ 785 000578 l1110:
+ 786 000578 C031 FFD9 movff memset@p,fsr2l
+ 787 00057C C032 FFDA movff memset@p+1,fsr2h
+ 788 000580 C02D FFDF movff memset@c,indf2
+ 789 000584 4A31 infsnz memset@p,f,c
+ 790 000586 2A32 incf memset@p+1,f,c
+ 791 000588 l596:
+ 792 000588 062F decf memset@n,f,c
+ 793 00058A A0D8 btfss status,0,c
+ 794 00058C 0630 decf memset@n+1,f,c
+ 795 00058E 282F incf memset@n,w,c
+ 796 000590 E1F3 bnz l1110
+ 797 000592 2830 incf memset@n+1,w,c
+ 798 000594 B4D8 btfsc status,2,c
+ 799 000596 0012 return
+ 800 000598 D7EF goto l597
+ 801 00059A __end_of_memset:
+ 802 opt stack 0
+ 803 tblptru equ 0xFF8
+ 804 intcon equ 0xFF2
+ 805 postinc0 equ 0xFEE
+ 806 wreg equ 0xFE8
+ 807 indf2 equ 0xFDF
+ 808 postinc2 equ 0xFDE
+ 809 postdec2 equ 0xFDD
+ 810 fsr2h equ 0xFDA
+ 811 fsr2l equ 0xFD9
+ 812 status equ 0xFD8
+ 813
+ 814 ;; *************** function _init_hw *****************
+ 815 ;; Defined at:
+ 816 ;; line 150 in file "main.c"
+ 817 ;; Parameters: Size Location Type
+ 818 ;; None
+ 819 ;; Auto vars: Size Location Type
+ 820 ;; None
+ 821 ;; Return value: Size Location Type
+ 822 ;; 1 wreg void
+ 823 ;; Registers used:
+ 824 ;; wreg, status,2, cstack
+ 825 ;; Tracked objects:
+ 826 ;; On entry : 0/0
+ 827 ;; On exit : 0/0
+ 828 ;; Unchanged: 0/0
+ 829 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 830 ;; Params: 0 0 0 0 0 0 0
+ 831 ;; Locals: 0 0 0 0 0 0 0
+ 832 ;; Temps: 0 0 0 0 0 0 0
+ 833 ;; Totals: 0 0 0 0 0 0 0
+ 834 ;;Total ram usage: 0 bytes
+ 835 ;; Hardware stack levels used: 1
+ 836 ;; Hardware stack levels required when called: 2
+ 837 ;; This function calls:
+ 838 ;; _eusart1_init
+ 839 ;; _eusart2_init
+ 840 ;; This function is called by:
+ 841 ;; _main
+ 842 ;; This function uses a non-reentrant model
+ 843 ;;
844
- 845 ; BSR set to: 15
- 846 ;main.c: 171: PORTDbits.RD1 = 1;
- 847 0002E0 8283 bsf 3971,1,c ;volatile
- 848
- 849 ; BSR set to: 15
- 850 ;main.c: 173: PORTDbits.RD2 = 0;
- 851 0002E2 9483 bcf 3971,2,c ;volatile
+ 845 psect text5
+ 846 00050C __ptext5:
+ 847 opt stack 0
+ 848 00050C _init_hw:
+ 849 opt stack 28
+ 850
+ 851 ;main.c: 152: (INTCONbits.GIE = 0);
852
- 853 ; BSR set to: 15
- 854 ;main.c: 175: PORTDbits.RD3 = 1;
- 855 0002E4 8683 bsf 3971,3,c ;volatile
- 856
- 857 ; BSR set to: 15
- 858 ;main.c: 177: PORTDbits.RD4 = 0;
- 859 0002E6 9883 bcf 3971,4,c ;volatile
- 860
- 861 ;main.c: 181: PR2 = 128;
- 862 0002E8 0E80 movlw 128
- 863 0002EA 6EBB movwf 4027,c ;volatile
- 864
- 865 ;main.c: 183: T2CONbits.T2OUTPS = 0b0011;
- 866 0002EC 50BA movf 4026,w,c ;volatile
- 867 0002EE 0B87 andlw -121
- 868 0002F0 0918 iorlw 24
- 869 0002F2 6EBA movwf 4026,c ;volatile
- 870
- 871 ;main.c: 185: T2CONbits.T2CKPS = 0b11;
- 872 0002F4 0E03 movlw 3
- 873 0002F6 12BA iorwf 4026,f,c ;volatile
- 874
- 875 ; BSR set to: 15
- 876 ;main.c: 187: T2CONbits.TMR2ON = 1;
- 877 0002F8 84BA bsf 4026,2,c ;volatile
- 878
- 879 ; BSR set to: 15
- 880 ;main.c: 190: PIE1bits.TMR2IE = 1;
- 881 0002FA 829D bsf 3997,1,c ;volatile
- 882
- 883 ; BSR set to: 15
- 884 ;main.c: 191: PIR1bits.TMR2IF = 0;
- 885 0002FC 929E bcf 3998,1,c ;volatile
- 886
- 887 ; BSR set to: 15
- 888 ;main.c: 194: INTCONbits.PEIE = 1;
- 889 0002FE 8CF2 bsf intcon,6,c ;volatile
- 890
- 891 ; BSR set to: 15
- 892 ;main.c: 197: eusart1_init();
- 893 000300 ECFE F001 call _eusart1_init ;wreg free
- 894
- 895 ;main.c: 199: (INTCONbits.GIE = 1);
- 896 000304 8EF2 bsf intcon,7,c ;volatile
- 897 000306 0012 return ;funcret
- 898 000308 __end_of_init_hw:
- 899 opt stack 0
- 900 tblptru equ 0xFF8
- 901 tblptrh equ 0xFF7
- 902 tblptrl equ 0xFF6
- 903 tablat equ 0xFF5
- 904 intcon equ 0xFF2
- 905 postinc0 equ 0xFEE
- 906 wreg equ 0xFE8
- 907 indf2 equ 0xFDF
- 908 postinc2 equ 0xFDE
- 909 postdec2 equ 0xFDD
- 910 fsr2h equ 0xFDA
- 911 fsr2l equ 0xFD9
- 912 status equ 0xFD8
- 913
- 914 ;; *************** function _eusart1_init *****************
- 915 ;; Defined at:
- 916 ;; line 4 in file "rs232.c"
- 917 ;; Parameters: Size Location Type
- 918 ;; None
- 919 ;; Auto vars: Size Location Type
- 920 ;; None
- 921 ;; Return value: Size Location Type
- 922 ;; 1 wreg void
- 923 ;; Registers used:
- 924 ;; wreg, status,2
- 925 ;; Tracked objects:
- 926 ;; On entry : 0/0
- 927 ;; On exit : 0/0
- 928 ;; Unchanged: 0/0
- 929 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- 930 ;; Params: 0 0 0 0 0 0 0
- 931 ;; Locals: 0 0 0 0 0 0 0
- 932 ;; Temps: 0 0 0 0 0 0 0
- 933 ;; Totals: 0 0 0 0 0 0 0
- 934 ;;Total ram usage: 0 bytes
- 935 ;; Hardware stack levels used: 1
- 936 ;; Hardware stack levels required when called: 1
- 937 ;; This function calls:
- 938 ;; Nothing
- 939 ;; This function is called by:
- 940 ;; _init_hw
- 941 ;; This function uses a non-reentrant model
- 942 ;;
- 943
- 944 psect text6
- 945 0003FC __ptext6:
- 946 opt stack 0
- 947 0003FC _eusart1_init:
- 948 opt stack 28
- 949
- 950 ;rs232.c: 7: TXSTA1bits.SYNC = 0;
- 951
- 952 ;incstack = 0
- 953 0003FC 98AC bcf 4012,4,c ;volatile
+ 853 ;incstack = 0
+ 854 00050C 9EF2 bcf intcon,7,c ;volatile
+ 855
+ 856 ;main.c: 156: OSCTUNEbits.PLLEN = 1;
+ 857 00050E 8C9B bsf 3995,6,c ;volatile
+ 858
+ 859 ;main.c: 158: OSCTUNEbits.TUN = 0b011111;
+ 860 000510 809B bsf 3995,0,c ;volatile
+ 861 000512 829B bsf 3995,1,c ;volatile
+ 862 000514 849B bsf 3995,2,c ;volatile
+ 863 000516 869B bsf 3995,3,c ;volatile
+ 864 000518 889B bsf 3995,4,c ;volatile
+ 865 00051A 9A9B bcf 3995,5,c ;volatile
+ 866
+ 867 ;main.c: 160: OSCCONbits.IRCF = 0b111;
+ 868 00051C 88D3 bsf 4051,4,c ;volatile
+ 869 00051E 8AD3 bsf 4051,5,c ;volatile
+ 870 000520 8CD3 bsf 4051,6,c ;volatile
+ 871
+ 872 ;main.c: 162: OSCCONbits.SCS = 0b00;
+ 873 000522 0EFC movlw -4
+ 874 000524 16D3 andwf 4051,f,c ;volatile
+ 875
+ 876 ;main.c: 166: ANSELA = 0x00;
+ 877 000526 0E00 movlw 0
+ 878 000528 010F movlb 15 ; () banked
+ 879 00052A 6F38 movwf 56,b ;volatile
+ 880
+ 881 ;main.c: 167: ANSELB = 0x00;
+ 882 00052C 0E00 movlw 0
+ 883 00052E 6F39 movwf 57,b ;volatile
+ 884
+ 885 ;main.c: 168: ANSELC = 0x00;
+ 886 000530 0E00 movlw 0
+ 887 000532 6F3A movwf 58,b ;volatile
+ 888
+ 889 ;main.c: 169: ANSELD = 0x00;
+ 890 000534 0E00 movlw 0
+ 891 000536 6F3B movwf 59,b ;volatile
+ 892
+ 893 ; BSR set to: 15
+ 894 ;main.c: 172: TRISA = 0xFF;
+ 895 000538 6892 setf 3986,c ;volatile
+ 896
+ 897 ; BSR set to: 15
+ 898 ;main.c: 173: TRISB = 0xFF;
+ 899 00053A 6893 setf 3987,c ;volatile
+ 900
+ 901 ; BSR set to: 15
+ 902 ;main.c: 176: TRISDbits.TRISD1 = 0;
+ 903 00053C 9295 bcf 3989,1,c ;volatile
+ 904
+ 905 ; BSR set to: 15
+ 906 ;main.c: 177: TRISDbits.TRISD2 = 0;
+ 907 00053E 9495 bcf 3989,2,c ;volatile
+ 908
+ 909 ; BSR set to: 15
+ 910 ;main.c: 178: TRISDbits.TRISD3 = 0;
+ 911 000540 9695 bcf 3989,3,c ;volatile
+ 912
+ 913 ; BSR set to: 15
+ 914 ;main.c: 179: TRISDbits.TRISD4 = 0;
+ 915 000542 9895 bcf 3989,4,c ;volatile
+ 916
+ 917 ; BSR set to: 15
+ 918 ;main.c: 182: PORTDbits.RD1 = 1;
+ 919 000544 8283 bsf 3971,1,c ;volatile
+ 920
+ 921 ; BSR set to: 15
+ 922 ;main.c: 184: PORTDbits.RD2 = 0;
+ 923 000546 9483 bcf 3971,2,c ;volatile
+ 924
+ 925 ; BSR set to: 15
+ 926 ;main.c: 186: PORTDbits.RD3 = 1;
+ 927 000548 8683 bsf 3971,3,c ;volatile
+ 928
+ 929 ; BSR set to: 15
+ 930 ;main.c: 188: PORTDbits.RD4 = 0;
+ 931 00054A 9883 bcf 3971,4,c ;volatile
+ 932
+ 933 ;main.c: 193: PR2 = 128;
+ 934 00054C 0E80 movlw 128
+ 935 00054E 6EBB movwf 4027,c ;volatile
+ 936
+ 937 ;main.c: 195: T2CONbits.T2OUTPS = 0b0001;
+ 938 000550 50BA movf 4026,w,c ;volatile
+ 939 000552 0B87 andlw -121
+ 940 000554 0908 iorlw 8
+ 941 000556 6EBA movwf 4026,c ;volatile
+ 942
+ 943 ;main.c: 197: T2CONbits.T2CKPS = 0b11;
+ 944 000558 0E03 movlw 3
+ 945 00055A 12BA iorwf 4026,f,c ;volatile
+ 946
+ 947 ; BSR set to: 15
+ 948 ;main.c: 199: T2CONbits.TMR2ON = 1;
+ 949 00055C 84BA bsf 4026,2,c ;volatile
+ 950
+ 951 ; BSR set to: 15
+ 952 ;main.c: 202: PIE1bits.TMR2IE = 1;
+ 953 00055E 829D bsf 3997,1,c ;volatile
954
- 955 ;rs232.c: 8: TXSTA1bits.TX9 = 0;
- 956 0003FE 9CAC bcf 4012,6,c ;volatile
- 957
- 958 ;rs232.c: 11: RCSTA1bits.SPEN = 1;
- 959 000400 8EAB bsf 4011,7,c ;volatile
- 960
- 961 ;rs232.c: 12: SPBRG1 = 31;
- 962 000402 0E1F movlw 31
- 963 000404 6EAF movwf 4015,c ;volatile
- 964
- 965 ;rs232.c: 13: SPBRGH1 = 0;
- 966 000406 0E00 movlw 0
- 967 000408 6EB0 movwf 4016,c ;volatile
- 968
- 969 ;rs232.c: 14: TXSTA1bits.BRGH = 0;
- 970 00040A 94AC bcf 4012,2,c ;volatile
- 971
- 972 ;rs232.c: 15: BAUDCON1bits.BRG16 = 0;
- 973 00040C 96B8 bcf 4024,3,c ;volatile
- 974
- 975 ;rs232.c: 18: TRISCbits.TRISC7 = 1;
- 976 00040E 8E94 bsf 3988,7,c ;volatile
- 977
- 978 ;rs232.c: 19: TRISCbits.TRISC6 = 1;
- 979 000410 8C94 bsf 3988,6,c ;volatile
- 980
- 981 ;rs232.c: 20: RCSTA1bits.CREN = 1;
- 982 000412 88AB bsf 4011,4,c ;volatile
- 983
- 984 ;rs232.c: 21: TXSTA1bits.TXEN = 1;
- 985 000414 8AAC bsf 4012,5,c ;volatile
- 986 000416 0012 return ;funcret
- 987 000418 __end_of_eusart1_init:
- 988 opt stack 0
- 989 tblptru equ 0xFF8
- 990 tblptrh equ 0xFF7
- 991 tblptrl equ 0xFF6
- 992 tablat equ 0xFF5
- 993 intcon equ 0xFF2
- 994 postinc0 equ 0xFEE
- 995 wreg equ 0xFE8
- 996 indf2 equ 0xFDF
- 997 postinc2 equ 0xFDE
- 998 postdec2 equ 0xFDD
- 999 fsr2h equ 0xFDA
- 1000 fsr2l equ 0xFD9
- 1001 status equ 0xFD8
- 1002
- 1003 ;; *************** function _eusart_write_midi *****************
- 1004 ;; Defined at:
- 1005 ;; line 226 in file "main.c"
- 1006 ;; Parameters: Size Location Type
- 1007 ;; pkt 2 26[COMRAM] PTR const struct .
- 1008 ;; -> main@sample_message(7),
- 1009 ;; Auto vars: Size Location Type
- 1010 ;; data 2 32[COMRAM] PTR unsigned char
- 1011 ;; -> sample_message.data(4), main@sample_message(7),
- 1012 ;; length 2 30[COMRAM] unsigned int
- 1013 ;; Return value: Size Location Type
- 1014 ;; 2 26[COMRAM] int
- 1015 ;; Registers used:
- 1016 ;; wreg, fsr2l, fsr2h, status,2, status,0, cstack
- 1017 ;; Tracked objects:
- 1018 ;; On entry : 0/0
- 1019 ;; On exit : 0/0
- 1020 ;; Unchanged: 0/0
- 1021 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- 1022 ;; Params: 2 0 0 0 0 0 0
- 1023 ;; Locals: 4 0 0 0 0 0 0
- 1024 ;; Temps: 2 0 0 0 0 0 0
- 1025 ;; Totals: 8 0 0 0 0 0 0
- 1026 ;;Total ram usage: 8 bytes
- 1027 ;; Hardware stack levels used: 1
- 1028 ;; Hardware stack levels required when called: 2
- 1029 ;; This function calls:
- 1030 ;; _putch
- 1031 ;; This function is called by:
- 1032 ;; _main
- 1033 ;; This function uses a non-reentrant model
- 1034 ;;
- 1035
- 1036 psect text7
- 1037 000234 __ptext7:
- 1038 opt stack 0
- 1039 000234 _eusart_write_midi:
- 1040 opt stack 28
- 1041
- 1042 ;main.c: 228: size_t length;
- 1043 ;main.c: 229: uint8_t *data;
- 1044 ;main.c: 231: if (pkt == (0)) {
- 1045
- 1046 ;incstack = 0
- 1047 000234 501B movf eusart_write_midi@pkt,w,c
- 1048 000236 101C iorwf eusart_write_midi@pkt+1,w,c
- 1049 000238 B4D8 btfsc status,2,c
- 1050 00023A 0012 return
- 1051
- 1052 ;main.c: 233: }
- 1053 ;main.c: 235: length = pkt->data_size;
- 1054
- 1055 ;main.c: 232: return -1;
- 1056 ; Return value of _eusart_write_midi is never used
- 1057 00023C EE20 F001 lfsr 2,1
- 1058 000240 501B movf eusart_write_midi@pkt,w,c
- 1059 000242 26D9 addwf fsr2l,f,c
- 1060 000244 501C movf eusart_write_midi@pkt+1,w,c
- 1061 000246 22DA addwfc fsr2h,f,c
- 1062 000248 CFDE F01F movff postinc2,eusart_write_midi@length
- 1063 00024C CFDD F020 movff postdec2,eusart_write_midi@length+1
- 1064
- 1065 ;main.c: 236: data = (uint8_t *) pkt->data;
- 1066 000250 0E03 movlw 3
- 1067 000252 241B addwf eusart_write_midi@pkt,w,c
- 1068 000254 6E21 movwf eusart_write_midi@data,c
- 1069 000256 0E00 movlw 0
- 1070 000258 201C addwfc eusart_write_midi@pkt+1,w,c
- 1071 00025A 6E22 movwf eusart_write_midi@data+1,c
- 1072
- 1073 ;main.c: 238: putch((char)((pkt->status << 4) | pkt->channel));
- 1074 00025C C01B FFD9 movff eusart_write_midi@pkt,fsr2l
- 1075 000260 C01C FFDA movff eusart_write_midi@pkt+1,fsr2h
- 1076 000264 38DF swapf indf2,w,c
- 1077 000266 0B0F andlw 15
- 1078 000268 6E1D movwf ??_eusart_write_midi& (0+255),c
- 1079 00026A C01B FFD9 movff eusart_write_midi@pkt,fsr2l
- 1080 00026E C01C FFDA movff eusart_write_midi@pkt+1,fsr2h
- 1081 000272 50DF movf indf2,w,c
- 1082 000274 0B0F andlw 15
- 1083 000276 6E1E movwf (??_eusart_write_midi+1)& (0+255),c
- 1084 000278 381E swapf ??_eusart_write_midi+1,w,c
- 1085 00027A 0BF0 andlw 240
- 1086 00027C 101D iorwf ??_eusart_write_midi,w,c
- 1087 00027E EC0C F002 call _putch
- 1088
- 1089 ;main.c: 240: while (length--) {
- 1090 000282 D009 goto l78
- 1091 000284 l1163:
- 1092
- 1093 ;main.c: 241: putch((char) *(data++));
- 1094 000284 C021 FFD9 movff eusart_write_midi@data,fsr2l
- 1095 000288 C022 FFDA movff eusart_write_midi@data+1,fsr2h
- 1096 00028C 50DF movf indf2,w,c
- 1097 00028E EC0C F002 call _putch
- 1098 000292 4A21 infsnz eusart_write_midi@data,f,c
- 1099 000294 2A22 incf eusart_write_midi@data+1,f,c
- 1100 000296 l78:
- 1101 000296 061F decf eusart_write_midi@length,f,c
- 1102 000298 A0D8 btfss status,0,c
- 1103 00029A 0620 decf eusart_write_midi@length+1,f,c
- 1104 00029C 281F incf eusart_write_midi@length,w,c
- 1105 00029E E1F2 bnz l1163
- 1106 0002A0 2820 incf eusart_write_midi@length+1,w,c
- 1107 0002A2 B4D8 btfsc status,2,c
- 1108 0002A4 0012 return
- 1109 0002A6 D7EE goto l79
- 1110 0002A8 __end_of_eusart_write_midi:
- 1111 opt stack 0
- 1112 tblptru equ 0xFF8
- 1113 tblptrh equ 0xFF7
- 1114 tblptrl equ 0xFF6
- 1115 tablat equ 0xFF5
- 1116 intcon equ 0xFF2
- 1117 postinc0 equ 0xFEE
- 1118 wreg equ 0xFE8
- 1119 indf2 equ 0xFDF
- 1120 postinc2 equ 0xFDE
- 1121 postdec2 equ 0xFDD
- 1122 fsr2h equ 0xFDA
- 1123 fsr2l equ 0xFD9
- 1124 status equ 0xFD8
- 1125
- 1126 ;; *************** function _putch *****************
- 1127 ;; Defined at:
- 1128 ;; line 29 in file "rs232.c"
- 1129 ;; Parameters: Size Location Type
- 1130 ;; c 1 wreg unsigned char
- 1131 ;; Auto vars: Size Location Type
- 1132 ;; c 1 25[COMRAM] unsigned char
- 1133 ;; Return value: Size Location Type
- 1134 ;; 1 wreg void
- 1135 ;; Registers used:
- 1136 ;; wreg
- 1137 ;; Tracked objects:
- 1138 ;; On entry : 0/0
- 1139 ;; On exit : 0/0
- 1140 ;; Unchanged: 0/0
- 1141 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- 1142 ;; Params: 0 0 0 0 0 0 0
- 1143 ;; Locals: 1 0 0 0 0 0 0
- 1144 ;; Temps: 0 0 0 0 0 0 0
- 1145 ;; Totals: 1 0 0 0 0 0 0
- 1146 ;;Total ram usage: 1 bytes
- 1147 ;; Hardware stack levels used: 1
- 1148 ;; Hardware stack levels required when called: 1
- 1149 ;; This function calls:
- 1150 ;; Nothing
- 1151 ;; This function is called by:
- 1152 ;; _eusart_write_midi
- 1153 ;; _getche
- 1154 ;; This function uses a non-reentrant model
- 1155 ;;
- 1156
- 1157 psect text8
- 1158 000418 __ptext8:
- 1159 opt stack 0
- 1160 000418 _putch:
- 1161 opt stack 28
- 1162
- 1163 ;incstack = 0
- 1164 ;putch@c stored from wreg
- 1165 000418 6E1A movwf putch@c,c
- 1166 00041A
- 1167 ;rs232.c: 31: while (!TX1IF);
- 1168 00041A A89E btfss 3998,4,c ;volatile
- 1169 00041C D7FE goto l1071
- 1170
- 1171 ;rs232.c: 32: TX1REG = c;
- 1172 00041E C01A FFAD movff putch@c,4013 ;volatile
- 1173 000422 0012 return ;funcret
- 1174 000424 __end_of_putch:
- 1175 opt stack 0
- 1176 tblptru equ 0xFF8
- 1177 tblptrh equ 0xFF7
- 1178 tblptrl equ 0xFF6
- 1179 tablat equ 0xFF5
- 1180 intcon equ 0xFF2
- 1181 postinc0 equ 0xFEE
- 1182 wreg equ 0xFE8
- 1183 indf2 equ 0xFDF
- 1184 postinc2 equ 0xFDE
- 1185 postdec2 equ 0xFDD
- 1186 fsr2h equ 0xFDA
- 1187 fsr2l equ 0xFD9
- 1188 status equ 0xFD8
- 1189
- 1190 ;; *************** function _isr *****************
- 1191 ;; Defined at:
- 1192 ;; line 101 in file "main.c"
- 1193 ;; Parameters: Size Location Type
- 1194 ;; None
- 1195 ;; Auto vars: Size Location Type
- 1196 ;; i 1 24[COMRAM] unsigned char
- 1197 ;; data 1 23[COMRAM] unsigned char
- 1198 ;; Return value: Size Location Type
- 1199 ;; 1 wreg void
- 1200 ;; Registers used:
- 1201 ;; wreg, fsr2l, fsr2h, status,2, status,0, prodl, prodh
- 1202 ;; Tracked objects:
- 1203 ;; On entry : 0/0
- 1204 ;; On exit : 0/0
- 1205 ;; Unchanged: 0/0
- 1206 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- 1207 ;; Params: 0 0 0 0 0 0 0
- 1208 ;; Locals: 3 0 0 0 0 0 0
- 1209 ;; Temps: 22 0 0 0 0 0 0
- 1210 ;; Totals: 25 0 0 0 0 0 0
- 1211 ;;Total ram usage: 25 bytes
- 1212 ;; Hardware stack levels used: 1
- 1213 ;; This function calls:
- 1214 ;; Nothing
- 1215 ;; This function is called by:
- 1216 ;; Interrupt level 2
- 1217 ;; This function uses a non-reentrant model
- 1218 ;;
- 1219
- 1220 psect intcode
- 1221 000008 __pintcode:
- 1222 opt stack 0
- 1223 000008 _isr:
- 1224 opt stack 28
- 1225
- 1226 ;incstack = 0
- 1227 000008 8245 bsf btemp,1,c ;set compiler interrupt flag (level 2)
- 1228 00000A CFFA F005 movff pclath,??_isr+4
- 1229 00000E CFFB F006 movff pclatu,??_isr+5
- 1230 000012 CFE9 F007 movff fsr0l,??_isr+6
- 1231 000016 CFEA F008 movff fsr0h,??_isr+7
- 1232 00001A CFE1 F009 movff fsr1l,??_isr+8
- 1233 00001E CFE2 F00A movff fsr1h,??_isr+9
- 1234 000022 CFD9 F00B movff fsr2l,??_isr+10
- 1235 000026 CFDA F00C movff fsr2h,??_isr+11
- 1236 00002A CFF3 F00D movff prodl,??_isr+12
- 1237 00002E CFF4 F00E movff prodh,??_isr+13
- 1238 000032 CFF6 F00F movff tblptrl,??_isr+14
- 1239 000036 CFF7 F010 movff tblptrh,??_isr+15
- 1240 00003A CFF8 F011 movff tblptru,??_isr+16
- 1241 00003E CFF5 F012 movff tablat,??_isr+17
- 1242 000042 C045 F013 movff btemp,??_isr+18
- 1243 000046 C046 F014 movff btemp+1,??_isr+19
- 1244 00004A C047 F015 movff btemp+2,??_isr+20
- 1245 00004E C048 F016 movff btemp+3,??_isr+21
- 1246
- 1247 ;main.c: 103: unsigned char i, data;
- 1248 ;main.c: 105: PORTDbits.RD3 = 0;
- 1249 000052 9683 bcf 3971,3,c ;volatile
- 1250
- 1251 ;main.c: 107: if (PIR1bits.TMR2IF) {
- 1252 000054 A29E btfss 3998,1,c ;volatile
- 1253 000056 D089 goto i2l55
- 1254
- 1255 ;main.c: 109: data = PORTA;
- 1256 000058 CF80 F018 movff 3968,isr@data ;volatile
- 1257
- 1258 ;main.c: 110: i = 7;
- 1259 00005C 0E07 movlw 7
- 1260 00005E 6E19 movwf isr@i,c
- 1261 000060
- 1262 ;main.c: 112: keypresses[i] = (keypresses[i] << 1) | ((data >> i) & 0x01);
- 1263 000060 5019 movf isr@i,w,c
- 1264 000062 0D02 mullw 2
- 1265 000064 0E25 movlw low _keypresses
- 1266 000066 24F3 addwf prodl,w,c
- 1267 000068 6ED9 movwf fsr2l,c
- 1268 00006A 0E00 movlw high _keypresses
- 1269 00006C 20F4 addwfc prodh,w,c
- 1270 00006E 6EDA movwf fsr2h,c
- 1271 000070 CFDE F001 movff postinc2,??_isr
- 1272 000074 CFDD F002 movff postdec2,??_isr+1
- 1273 000078 90D8 bcf status,0,c
- 1274 00007A 3601 rlcf ??_isr,f,c
- 1275 00007C 3602 rlcf ??_isr+1,f,c
- 1276 00007E C019 F003 movff isr@i,??_isr+2
- 1277 000082 C018 F004 movff isr@data,??_isr+3
- 1278 000086 2A03 incf ??_isr+2,f,c
- 1279 000088 D002 goto i2u29_44
- 1280 00008A i2u29_45:
- 1281 00008A 90D8 bcf status,0,c
- 1282 00008C 3204 rrcf ??_isr+3,f,c
- 1283 00008E i2u29_44:
- 1284 00008E 2E03 decfsz ??_isr+2,f,c
- 1285 000090 D7FC goto i2u29_45
- 1286 000092 0E01 movlw 1
- 1287 000094 1604 andwf ??_isr+3,f,c
- 1288 000096 5004 movf ??_isr+3,w,c
- 1289 000098 1201 iorwf ??_isr,f,c
- 1290 00009A 0E00 movlw 0
- 1291 00009C 1202 iorwf ??_isr+1,f,c
- 1292 00009E 5019 movf isr@i,w,c
- 1293 0000A0 0D02 mullw 2
- 1294 0000A2 0E25 movlw low _keypresses
- 1295 0000A4 24F3 addwf prodl,w,c
- 1296 0000A6 6ED9 movwf fsr2l,c
- 1297 0000A8 0E00 movlw high _keypresses
- 1298 0000AA 20F4 addwfc prodh,w,c
- 1299 0000AC 6EDA movwf fsr2h,c
- 1300 0000AE C001 FFDE movff ??_isr,postinc2
- 1301 0000B2 C002 FFDD movff ??_isr+1,postdec2
- 1302
- 1303 ;main.c: 113: } while (i--);
- 1304 0000B6 0619 decf isr@i,f,c
- 1305 0000B8 2819 incf isr@i,w,c
- 1306 0000BA A4D8 btfss status,2,c
- 1307 0000BC D7D1 goto i2l56
- 1308
- 1309 ;main.c: 115: data = PORTB;
- 1310 0000BE CF81 F018 movff 3969,isr@data ;volatile
- 1311
- 1312 ;main.c: 116: i = 7;
- 1313 0000C2 0E07 movlw 7
- 1314 0000C4 6E19 movwf isr@i,c
- 1315 0000C6
- 1316 ;main.c: 118: keypresses[i] = (keypresses[i] << 1) | ((data >> i) & 0x01);
- 1317 0000C6 5019 movf isr@i,w,c
- 1318 0000C8 0D02 mullw 2
- 1319 0000CA 0E25 movlw low _keypresses
- 1320 0000CC 24F3 addwf prodl,w,c
- 1321 0000CE 6ED9 movwf fsr2l,c
- 1322 0000D0 0E00 movlw high _keypresses
- 1323 0000D2 20F4 addwfc prodh,w,c
- 1324 0000D4 6EDA movwf fsr2h,c
- 1325 0000D6 CFDE F001 movff postinc2,??_isr
- 1326 0000DA CFDD F002 movff postdec2,??_isr+1
- 1327 0000DE 90D8 bcf status,0,c
- 1328 0000E0 3601 rlcf ??_isr,f,c
- 1329 0000E2 3602 rlcf ??_isr+1,f,c
- 1330 0000E4 C019 F003 movff isr@i,??_isr+2
- 1331 0000E8 C018 F004 movff isr@data,??_isr+3
- 1332 0000EC 2A03 incf ??_isr+2,f,c
- 1333 0000EE D002 goto i2u31_44
- 1334 0000F0 i2u31_45:
- 1335 0000F0 90D8 bcf status,0,c
- 1336 0000F2 3204 rrcf ??_isr+3,f,c
- 1337 0000F4 i2u31_44:
- 1338 0000F4 2E03 decfsz ??_isr+2,f,c
- 1339 0000F6 D7FC goto i2u31_45
- 1340 0000F8 0E01 movlw 1
- 1341 0000FA 1604 andwf ??_isr+3,f,c
- 1342 0000FC 5004 movf ??_isr+3,w,c
- 1343 0000FE 1201 iorwf ??_isr,f,c
- 1344 000100 0E00 movlw 0
- 1345 000102 1202 iorwf ??_isr+1,f,c
- 1346 000104 5019 movf isr@i,w,c
- 1347 000106 0D02 mullw 2
- 1348 000108 0E25 movlw low _keypresses
- 1349 00010A 24F3 addwf prodl,w,c
- 1350 00010C 6ED9 movwf fsr2l,c
- 1351 00010E 0E00 movlw high _keypresses
- 1352 000110 20F4 addwfc prodh,w,c
- 1353 000112 6EDA movwf fsr2h,c
- 1354 000114 C001 FFDE movff ??_isr,postinc2
- 1355 000118 C002 FFDD movff ??_isr+1,postdec2
- 1356
- 1357 ;main.c: 119: } while (i-- - 8);
- 1358 00011C 0EF8 movlw 248
- 1359 00011E 6E01 movwf ??_isr& (0+255),c
- 1360 000120 0EFF movlw 255
- 1361 000122 6E02 movwf (??_isr+1)& (0+255),c
- 1362 000124 0619 decf isr@i,f,c
- 1363 000126 2819 incf isr@i,w,c
- 1364 000128 6E03 movwf (??_isr+2)& (0+255),c
- 1365 00012A 6A04 clrf (??_isr+3)& (0+255),c
- 1366 00012C 5001 movf ??_isr,w,c
- 1367 00012E 2603 addwf ??_isr+2,f,c
- 1368 000130 5002 movf ??_isr+1,w,c
- 1369 000132 2204 addwfc ??_isr+3,f,c
- 1370 000134 5003 movf ??_isr+2,w,c
- 1371 000136 1004 iorwf ??_isr+3,w,c
- 1372 000138 A4D8 btfss status,2,c
- 1373 00013A D7C5 goto i2l58
- 1374
- 1375 ;main.c: 129: PORTDbits.RD4 = PORTAbits.RA0;
- 1376 00013C A080 btfss 3968,0,c ;volatile
- 1377 00013E D002 bra i2u33_45
- 1378 000140 8883 bsf 3971,4,c ;volatile
- 1379 000142 D001 bra i2u33_47
- 1380 000144 i2u33_45:
- 1381 000144 9883 bcf 3971,4,c ;volatile
- 1382 000146 i2u33_47:
- 1383
- 1384 ;main.c: 130: PORTDbits.RD2 = (keypresses[0] && !(keypresses[0] & 0xFF00));
- 1385 000146 0E00 movlw 0
- 1386 000148 6E17 movwf _isr$592,c
- 1387 00014A 5025 movf _keypresses,w,c ;volatile
- 1388 00014C 1026 iorwf _keypresses+1,w,c ;volatile
- 1389 00014E B4D8 btfsc status,2,c
- 1390 000150 D006 goto i2l61
- 1391 000152 0EFF movlw 255
- 1392 000154 1426 andwf _keypresses+1,w,c ;volatile
- 1393 000156 A4D8 btfss status,2,c
- 1394 000158 D002 goto i2l61
- 1395 00015A 0E01 movlw 1
- 1396 00015C 6E17 movwf _isr$592,c
- 1397 00015E i2l61:
- 1398 00015E B017 btfsc _isr$592,0,c
- 1399 000160 D002 bra i2u36_45
- 1400 000162 9483 bcf 3971,2,c ;volatile
- 1401 000164 D001 bra i2u36_46
- 1402 000166 i2u36_45:
- 1403 000166 8483 bsf 3971,2,c ;volatile
- 1404 000168 i2u36_46:
- 1405
- 1406 ;main.c: 133: PIR1bits.TMR2IF = 0;
- 1407 000168 929E bcf 3998,1,c ;volatile
- 1408 00016A i2l55:
- 1409
- 1410 ;main.c: 134: }
- 1411 ;main.c: 136: PORTDbits.RD3 = 1;
- 1412 00016A 8683 bsf 3971,3,c ;volatile
- 1413 00016C C016 F048 movff ??_isr+21,btemp+3
- 1414 000170 C015 F047 movff ??_isr+20,btemp+2
- 1415 000174 C014 F046 movff ??_isr+19,btemp+1
- 1416 000178 C013 F045 movff ??_isr+18,btemp
- 1417 00017C C012 FFF5 movff ??_isr+17,tablat
- 1418 000180 C011 FFF8 movff ??_isr+16,tblptru
- 1419 000184 C010 FFF7 movff ??_isr+15,tblptrh
- 1420 000188 C00F FFF6 movff ??_isr+14,tblptrl
- 1421 00018C C00E FFF4 movff ??_isr+13,prodh
- 1422 000190 C00D FFF3 movff ??_isr+12,prodl
- 1423 000194 C00C FFDA movff ??_isr+11,fsr2h
- 1424 000198 C00B FFD9 movff ??_isr+10,fsr2l
- 1425 00019C C00A FFE2 movff ??_isr+9,fsr1h
- 1426 0001A0 C009 FFE1 movff ??_isr+8,fsr1l
- 1427 0001A4 C008 FFEA movff ??_isr+7,fsr0h
- 1428 0001A8 C007 FFE9 movff ??_isr+6,fsr0l
- 1429 0001AC C006 FFFB movff ??_isr+5,pclatu
- 1430 0001B0 C005 FFFA movff ??_isr+4,pclath
- 1431 0001B4 9245 bcf btemp,1,c ;clear compiler interrupt flag (level 2)
- 1432 0001B6 0011 retfie f
- 1433 0001B8 __end_of_isr:
- 1434 opt stack 0
- 1435 0000 pclatu equ 0xFFB
- 1436 pclath equ 0xFFA
- 1437 tblptru equ 0xFF8
- 1438 tblptrh equ 0xFF7
- 1439 tblptrl equ 0xFF6
- 1440 tablat equ 0xFF5
- 1441 prodh equ 0xFF4
- 1442 prodl equ 0xFF3
- 1443 intcon equ 0xFF2
- 1444 postinc0 equ 0xFEE
- 1445 fsr0h equ 0xFEA
- 1446 fsr0l equ 0xFE9
- 1447 wreg equ 0xFE8
- 1448 fsr1h equ 0xFE2
- 1449 fsr1l equ 0xFE1
- 1450 indf2 equ 0xFDF
- 1451 postinc2 equ 0xFDE
- 1452 postdec2 equ 0xFDD
- 1453 fsr2h equ 0xFDA
- 1454 fsr2l equ 0xFD9
- 1455 status equ 0xFD8
- 1456 pclatu equ 0xFFB
- 1457 pclath equ 0xFFA
- 1458 tblptru equ 0xFF8
- 1459 tblptrh equ 0xFF7
- 1460 tblptrl equ 0xFF6
- 1461 tablat equ 0xFF5
- 1462 prodh equ 0xFF4
- 1463 prodl equ 0xFF3
- 1464 intcon equ 0xFF2
- 1465 postinc0 equ 0xFEE
- 1466 fsr0h equ 0xFEA
- 1467 fsr0l equ 0xFE9
- 1468 wreg equ 0xFE8
- 1469 fsr1h equ 0xFE2
- 1470 fsr1l equ 0xFE1
- 1471 indf2 equ 0xFDF
- 1472 postinc2 equ 0xFDE
- 1473 postdec2 equ 0xFDD
- 1474 fsr2h equ 0xFDA
- 1475 fsr2l equ 0xFD9
- 1476 status equ 0xFD8
- 1477
- 1478 psect rparam
- 1479 0000 pclatu equ 0xFFB
- 1480 pclath equ 0xFFA
- 1481 tblptru equ 0xFF8
- 1482 tblptrh equ 0xFF7
- 1483 tblptrl equ 0xFF6
- 1484 tablat equ 0xFF5
- 1485 prodh equ 0xFF4
- 1486 prodl equ 0xFF3
- 1487 intcon equ 0xFF2
- 1488 postinc0 equ 0xFEE
- 1489 fsr0h equ 0xFEA
- 1490 fsr0l equ 0xFE9
- 1491 wreg equ 0xFE8
- 1492 fsr1h equ 0xFE2
- 1493 fsr1l equ 0xFE1
- 1494 indf2 equ 0xFDF
- 1495 postinc2 equ 0xFDE
- 1496 postdec2 equ 0xFDD
- 1497 fsr2h equ 0xFDA
- 1498 fsr2l equ 0xFD9
- 1499 status equ 0xFD8
- 1500
- 1501 psect temp
- 1502 000045 btemp:
- 1503 opt stack 0
- 1504 000045 ds 1
- 1505 0000 int$flags set btemp
- 1506 0000 wtemp6 set btemp+1
- 1507 pclatu equ 0xFFB
- 1508 pclath equ 0xFFA
- 1509 tblptru equ 0xFF8
- 1510 tblptrh equ 0xFF7
- 1511 tblptrl equ 0xFF6
- 1512 tablat equ 0xFF5
- 1513 prodh equ 0xFF4
- 1514 prodl equ 0xFF3
- 1515 intcon equ 0xFF2
- 1516 postinc0 equ 0xFEE
- 1517 fsr0h equ 0xFEA
- 1518 fsr0l equ 0xFE9
- 1519 wreg equ 0xFE8
- 1520 fsr1h equ 0xFE2
- 1521 fsr1l equ 0xFE1
- 1522 indf2 equ 0xFDF
- 1523 postinc2 equ 0xFDE
- 1524 postdec2 equ 0xFDD
- 1525 fsr2h equ 0xFDA
- 1526 fsr2l equ 0xFD9
- 1527 status equ 0xFD8
+ 955 ; BSR set to: 15
+ 956 ;main.c: 203: PIR1bits.TMR2IF = 0;
+ 957 000560 929E bcf 3998,1,c ;volatile
+ 958
+ 959 ; BSR set to: 15
+ 960 ;main.c: 206: INTCONbits.PEIE = 1;
+ 961 000562 8CF2 bsf intcon,6,c ;volatile
+ 962
+ 963 ; BSR set to: 15
+ 964 ;main.c: 209: eusart1_init();
+ 965 000564 EC00 F003 call _eusart1_init ;wreg free
+ 966
+ 967 ;main.c: 210: eusart2_init();
+ 968 000568 ECF2 F002 call _eusart2_init ;wreg free
+ 969 00056C 0012 return ;funcret
+ 970 00056E __end_of_init_hw:
+ 971 opt stack 0
+ 972 tblptru equ 0xFF8
+ 973 intcon equ 0xFF2
+ 974 postinc0 equ 0xFEE
+ 975 wreg equ 0xFE8
+ 976 indf2 equ 0xFDF
+ 977 postinc2 equ 0xFDE
+ 978 postdec2 equ 0xFDD
+ 979 fsr2h equ 0xFDA
+ 980 fsr2l equ 0xFD9
+ 981 status equ 0xFD8
+ 982
+ 983 ;; *************** function _eusart2_init *****************
+ 984 ;; Defined at:
+ 985 ;; line 25 in file "rs232.c"
+ 986 ;; Parameters: Size Location Type
+ 987 ;; None
+ 988 ;; Auto vars: Size Location Type
+ 989 ;; None
+ 990 ;; Return value: Size Location Type
+ 991 ;; 1 wreg void
+ 992 ;; Registers used:
+ 993 ;; wreg, status,2
+ 994 ;; Tracked objects:
+ 995 ;; On entry : 0/0
+ 996 ;; On exit : 0/0
+ 997 ;; Unchanged: 0/0
+ 998 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 999 ;; Params: 0 0 0 0 0 0 0
+ 1000 ;; Locals: 0 0 0 0 0 0 0
+ 1001 ;; Temps: 0 0 0 0 0 0 0
+ 1002 ;; Totals: 0 0 0 0 0 0 0
+ 1003 ;;Total ram usage: 0 bytes
+ 1004 ;; Hardware stack levels used: 1
+ 1005 ;; Hardware stack levels required when called: 1
+ 1006 ;; This function calls:
+ 1007 ;; Nothing
+ 1008 ;; This function is called by:
+ 1009 ;; _init_hw
+ 1010 ;; This function uses a non-reentrant model
+ 1011 ;;
+ 1012
+ 1013 psect text6
+ 1014 0005E4 __ptext6:
+ 1015 opt stack 0
+ 1016 0005E4 _eusart2_init:
+ 1017 opt stack 28
+ 1018
+ 1019 ;rs232.c: 28: TXSTA2bits.SYNC = 0;
+ 1020
+ 1021 ;incstack = 0
+ 1022 0005E4 9872 bcf 3954,4,c ;volatile
+ 1023
+ 1024 ;rs232.c: 29: TXSTA2bits.TX9 = 0;
+ 1025 0005E6 9C72 bcf 3954,6,c ;volatile
+ 1026
+ 1027 ;rs232.c: 32: RCSTA2bits.SPEN = 1;
+ 1028 0005E8 8E71 bsf 3953,7,c ;volatile
+ 1029
+ 1030 ;rs232.c: 33: SPBRG2 = 31;
+ 1031 0005EA 0E1F movlw 31
+ 1032 0005EC 6E75 movwf 3957,c ;volatile
+ 1033
+ 1034 ;rs232.c: 34: SPBRGH2 = 0;
+ 1035 0005EE 0E00 movlw 0
+ 1036 0005F0 6E76 movwf 3958,c ;volatile
+ 1037
+ 1038 ;rs232.c: 35: TXSTA2bits.BRGH = 0;
+ 1039 0005F2 9472 bcf 3954,2,c ;volatile
+ 1040
+ 1041 ;rs232.c: 36: BAUDCON2bits.BRG16 = 0;
+ 1042 0005F4 9670 bcf 3952,3,c ;volatile
+ 1043
+ 1044 ;rs232.c: 39: TRISDbits.TRISD7 = 1;
+ 1045 0005F6 8E95 bsf 3989,7,c ;volatile
+ 1046
+ 1047 ;rs232.c: 40: TRISDbits.TRISD6 = 1;
+ 1048 0005F8 8C95 bsf 3989,6,c ;volatile
+ 1049
+ 1050 ;rs232.c: 42: RCSTA2bits.CREN = 1;
+ 1051 0005FA 8871 bsf 3953,4,c ;volatile
+ 1052
+ 1053 ;rs232.c: 43: TXSTA2bits.TXEN = 1;
+ 1054 0005FC 8A72 bsf 3954,5,c ;volatile
+ 1055 0005FE 0012 return ;funcret
+ 1056 000600 __end_of_eusart2_init:
+ 1057 opt stack 0
+ 1058 tblptru equ 0xFF8
+ 1059 intcon equ 0xFF2
+ 1060 postinc0 equ 0xFEE
+ 1061 wreg equ 0xFE8
+ 1062 indf2 equ 0xFDF
+ 1063 postinc2 equ 0xFDE
+ 1064 postdec2 equ 0xFDD
+ 1065 fsr2h equ 0xFDA
+ 1066 fsr2l equ 0xFD9
+ 1067 status equ 0xFD8
+ 1068
+ 1069 ;; *************** function _eusart1_init *****************
+ 1070 ;; Defined at:
+ 1071 ;; line 4 in file "rs232.c"
+ 1072 ;; Parameters: Size Location Type
+ 1073 ;; None
+ 1074 ;; Auto vars: Size Location Type
+ 1075 ;; None
+ 1076 ;; Return value: Size Location Type
+ 1077 ;; 1 wreg void
+ 1078 ;; Registers used:
+ 1079 ;; wreg, status,2
+ 1080 ;; Tracked objects:
+ 1081 ;; On entry : 0/0
+ 1082 ;; On exit : 0/0
+ 1083 ;; Unchanged: 0/0
+ 1084 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 1085 ;; Params: 0 0 0 0 0 0 0
+ 1086 ;; Locals: 0 0 0 0 0 0 0
+ 1087 ;; Temps: 0 0 0 0 0 0 0
+ 1088 ;; Totals: 0 0 0 0 0 0 0
+ 1089 ;;Total ram usage: 0 bytes
+ 1090 ;; Hardware stack levels used: 1
+ 1091 ;; Hardware stack levels required when called: 1
+ 1092 ;; This function calls:
+ 1093 ;; Nothing
+ 1094 ;; This function is called by:
+ 1095 ;; _init_hw
+ 1096 ;; This function uses a non-reentrant model
+ 1097 ;;
+ 1098
+ 1099 psect text7
+ 1100 000600 __ptext7:
+ 1101 opt stack 0
+ 1102 000600 _eusart1_init:
+ 1103 opt stack 28
+ 1104
+ 1105 ;rs232.c: 7: TXSTA1bits.SYNC = 0;
+ 1106
+ 1107 ;incstack = 0
+ 1108 000600 98AC bcf 4012,4,c ;volatile
+ 1109
+ 1110 ;rs232.c: 8: TXSTA1bits.TX9 = 0;
+ 1111 000602 9CAC bcf 4012,6,c ;volatile
+ 1112
+ 1113 ;rs232.c: 11: RCSTA1bits.SPEN = 1;
+ 1114 000604 8EAB bsf 4011,7,c ;volatile
+ 1115
+ 1116 ;rs232.c: 12: SPBRG1 = 31;
+ 1117 000606 0E1F movlw 31
+ 1118 000608 6EAF movwf 4015,c ;volatile
+ 1119
+ 1120 ;rs232.c: 13: SPBRGH1 = 0;
+ 1121 00060A 0E00 movlw 0
+ 1122 00060C 6EB0 movwf 4016,c ;volatile
+ 1123
+ 1124 ;rs232.c: 14: TXSTA1bits.BRGH = 0;
+ 1125 00060E 94AC bcf 4012,2,c ;volatile
+ 1126
+ 1127 ;rs232.c: 15: BAUDCON1bits.BRG16 = 0;
+ 1128 000610 96B8 bcf 4024,3,c ;volatile
+ 1129
+ 1130 ;rs232.c: 18: TRISCbits.TRISC7 = 1;
+ 1131 000612 8E94 bsf 3988,7,c ;volatile
+ 1132
+ 1133 ;rs232.c: 19: TRISCbits.TRISC6 = 1;
+ 1134 000614 8C94 bsf 3988,6,c ;volatile
+ 1135
+ 1136 ;rs232.c: 21: RCSTA1bits.CREN = 1;
+ 1137 000616 88AB bsf 4011,4,c ;volatile
+ 1138
+ 1139 ;rs232.c: 22: TXSTA1bits.TXEN = 1;
+ 1140 000618 8AAC bsf 4012,5,c ;volatile
+ 1141 00061A 0012 return ;funcret
+ 1142 00061C __end_of_eusart1_init:
+ 1143 opt stack 0
+ 1144 tblptru equ 0xFF8
+ 1145 intcon equ 0xFF2
+ 1146 postinc0 equ 0xFEE
+ 1147 wreg equ 0xFE8
+ 1148 indf2 equ 0xFDF
+ 1149 postinc2 equ 0xFDE
+ 1150 postdec2 equ 0xFDD
+ 1151 fsr2h equ 0xFDA
+ 1152 fsr2l equ 0xFD9
+ 1153 status equ 0xFD8
+ 1154
+ 1155 ;; *************** function _eusart_write_midi *****************
+ 1156 ;; Defined at:
+ 1157 ;; line 261 in file "main.c"
+ 1158 ;; Parameters: Size Location Type
+ 1159 ;; pkt 2 43[COMRAM] PTR const struct .
+ 1160 ;; -> main@message(7),
+ 1161 ;; Auto vars: Size Location Type
+ 1162 ;; data 2 49[COMRAM] PTR unsigned char
+ 1163 ;; -> message.data(4), main@message(7),
+ 1164 ;; length 2 47[COMRAM] unsigned int
+ 1165 ;; Return value: Size Location Type
+ 1166 ;; 2 43[COMRAM] int
+ 1167 ;; Registers used:
+ 1168 ;; wreg, fsr2l, fsr2h, status,2, status,0, cstack
+ 1169 ;; Tracked objects:
+ 1170 ;; On entry : 0/0
+ 1171 ;; On exit : 0/0
+ 1172 ;; Unchanged: 0/0
+ 1173 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 1174 ;; Params: 2 0 0 0 0 0 0
+ 1175 ;; Locals: 4 0 0 0 0 0 0
+ 1176 ;; Temps: 2 0 0 0 0 0 0
+ 1177 ;; Totals: 8 0 0 0 0 0 0
+ 1178 ;;Total ram usage: 8 bytes
+ 1179 ;; Hardware stack levels used: 1
+ 1180 ;; Hardware stack levels required when called: 2
+ 1181 ;; This function calls:
+ 1182 ;; _eusart2_putch
+ 1183 ;; This function is called by:
+ 1184 ;; _main
+ 1185 ;; This function uses a non-reentrant model
+ 1186 ;;
+ 1187
+ 1188 psect text8
+ 1189 000432 __ptext8:
+ 1190 opt stack 0
+ 1191 000432 _eusart_write_midi:
+ 1192 opt stack 28
+ 1193
+ 1194 ;main.c: 263: size_t length;
+ 1195 ;main.c: 264: uint8_t *data;
+ 1196 ;main.c: 266: if (pkt == (0)) {
+ 1197
+ 1198 ;incstack = 0
+ 1199 000432 502C movf eusart_write_midi@pkt,w,c
+ 1200 000434 102D iorwf eusart_write_midi@pkt+1,w,c
+ 1201 000436 B4D8 btfsc status,2,c
+ 1202 000438 0012 return
+ 1203
+ 1204 ;main.c: 268: }
+ 1205 ;main.c: 270: length = pkt->data_size;
+ 1206
+ 1207 ;main.c: 267: return -1;
+ 1208 ; Return value of _eusart_write_midi is never used
+ 1209 00043A EE20 F001 lfsr 2,1
+ 1210 00043E 502C movf eusart_write_midi@pkt,w,c
+ 1211 000440 26D9 addwf fsr2l,f,c
+ 1212 000442 502D movf eusart_write_midi@pkt+1,w,c
+ 1213 000444 22DA addwfc fsr2h,f,c
+ 1214 000446 CFDE F030 movff postinc2,eusart_write_midi@length
+ 1215 00044A CFDD F031 movff postdec2,eusart_write_midi@length+1
+ 1216
+ 1217 ;main.c: 271: data = (uint8_t *) pkt->data;
+ 1218 00044E 0E03 movlw 3
+ 1219 000450 242C addwf eusart_write_midi@pkt,w,c
+ 1220 000452 6E32 movwf eusart_write_midi@data,c
+ 1221 000454 0E00 movlw 0
+ 1222 000456 202D addwfc eusart_write_midi@pkt+1,w,c
+ 1223 000458 6E33 movwf eusart_write_midi@data+1,c
+ 1224
+ 1225 ;main.c: 273: eusart2_putch((char)((pkt->status << 4) | pkt->channel));
+ 1226 00045A C02C FFD9 movff eusart_write_midi@pkt,fsr2l
+ 1227 00045E C02D FFDA movff eusart_write_midi@pkt+1,fsr2h
+ 1228 000462 38DF swapf indf2,w,c
+ 1229 000464 0B0F andlw 15
+ 1230 000466 6E2E movwf ??_eusart_write_midi& (0+255),c
+ 1231 000468 C02C FFD9 movff eusart_write_midi@pkt,fsr2l
+ 1232 00046C C02D FFDA movff eusart_write_midi@pkt+1,fsr2h
+ 1233 000470 50DF movf indf2,w,c
+ 1234 000472 0B0F andlw 15
+ 1235 000474 6E2F movwf (??_eusart_write_midi+1)& (0+255),c
+ 1236 000476 382F swapf ??_eusart_write_midi+1,w,c
+ 1237 000478 0BF0 andlw 240
+ 1238 00047A 102E iorwf ??_eusart_write_midi,w,c
+ 1239 00047C EC1B F003 call _eusart2_putch
+ 1240
+ 1241 ;main.c: 275: while (length--) {
+ 1242 000480 D009 goto l87
+ 1243 000482 l1140:
+ 1244
+ 1245 ;main.c: 276: eusart2_putch((char) *(data++));
+ 1246 000482 C032 FFD9 movff eusart_write_midi@data,fsr2l
+ 1247 000486 C033 FFDA movff eusart_write_midi@data+1,fsr2h
+ 1248 00048A 50DF movf indf2,w,c
+ 1249 00048C EC1B F003 call _eusart2_putch
+ 1250 000490 4A32 infsnz eusart_write_midi@data,f,c
+ 1251 000492 2A33 incf eusart_write_midi@data+1,f,c
+ 1252 000494 l87:
+ 1253 000494 0630 decf eusart_write_midi@length,f,c
+ 1254 000496 A0D8 btfss status,0,c
+ 1255 000498 0631 decf eusart_write_midi@length+1,f,c
+ 1256 00049A 2830 incf eusart_write_midi@length,w,c
+ 1257 00049C E1F2 bnz l1140
+ 1258 00049E 2831 incf eusart_write_midi@length+1,w,c
+ 1259 0004A0 B4D8 btfsc status,2,c
+ 1260 0004A2 0012 return
+ 1261 0004A4 D7EE goto l88
+ 1262 0004A6 __end_of_eusart_write_midi:
+ 1263 opt stack 0
+ 1264 tblptru equ 0xFF8
+ 1265 intcon equ 0xFF2
+ 1266 postinc0 equ 0xFEE
+ 1267 wreg equ 0xFE8
+ 1268 indf2 equ 0xFDF
+ 1269 postinc2 equ 0xFDE
+ 1270 postdec2 equ 0xFDD
+ 1271 fsr2h equ 0xFDA
+ 1272 fsr2l equ 0xFD9
+ 1273 status equ 0xFD8
+ 1274
+ 1275 ;; *************** function _eusart2_putch *****************
+ 1276 ;; Defined at:
+ 1277 ;; line 52 in file "rs232.c"
+ 1278 ;; Parameters: Size Location Type
+ 1279 ;; c 1 wreg unsigned char
+ 1280 ;; Auto vars: Size Location Type
+ 1281 ;; c 1 42[COMRAM] unsigned char
+ 1282 ;; Return value: Size Location Type
+ 1283 ;; 1 wreg void
+ 1284 ;; Registers used:
+ 1285 ;; wreg
+ 1286 ;; Tracked objects:
+ 1287 ;; On entry : 0/0
+ 1288 ;; On exit : 0/0
+ 1289 ;; Unchanged: 0/0
+ 1290 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 1291 ;; Params: 0 0 0 0 0 0 0
+ 1292 ;; Locals: 1 0 0 0 0 0 0
+ 1293 ;; Temps: 0 0 0 0 0 0 0
+ 1294 ;; Totals: 1 0 0 0 0 0 0
+ 1295 ;;Total ram usage: 1 bytes
+ 1296 ;; Hardware stack levels used: 1
+ 1297 ;; Hardware stack levels required when called: 1
+ 1298 ;; This function calls:
+ 1299 ;; Nothing
+ 1300 ;; This function is called by:
+ 1301 ;; _eusart_write_midi
+ 1302 ;; This function uses a non-reentrant model
+ 1303 ;;
+ 1304
+ 1305 psect text9
+ 1306 000636 __ptext9:
+ 1307 opt stack 0
+ 1308 000636 _eusart2_putch:
+ 1309 opt stack 28
+ 1310
+ 1311 ;incstack = 0
+ 1312 ;eusart2_putch@c stored from wreg
+ 1313 000636 6E2B movwf eusart2_putch@c,c
+ 1314 000638
+ 1315 ;rs232.c: 54: while (!TX2IF);
+ 1316 000638 A8A4 btfss 4004,4,c ;volatile
+ 1317 00063A D7FE goto l1052
+ 1318
+ 1319 ;rs232.c: 55: TX2REG = c;
+ 1320 00063C C02B FF73 movff eusart2_putch@c,3955 ;volatile
+ 1321 000640 0012 return ;funcret
+ 1322 000642 __end_of_eusart2_putch:
+ 1323 opt stack 0
+ 1324 tblptru equ 0xFF8
+ 1325 intcon equ 0xFF2
+ 1326 postinc0 equ 0xFEE
+ 1327 wreg equ 0xFE8
+ 1328 indf2 equ 0xFDF
+ 1329 postinc2 equ 0xFDE
+ 1330 postdec2 equ 0xFDD
+ 1331 fsr2h equ 0xFDA
+ 1332 fsr2l equ 0xFD9
+ 1333 status equ 0xFD8
+ 1334
+ 1335 ;; *************** function _isr *****************
+ 1336 ;; Defined at:
+ 1337 ;; line 113 in file "main.c"
+ 1338 ;; Parameters: Size Location Type
+ 1339 ;; None
+ 1340 ;; Auto vars: Size Location Type
+ 1341 ;; i 1 41[COMRAM] unsigned char
+ 1342 ;; data_b 1 37[COMRAM] unsigned char
+ 1343 ;; data_a 1 36[COMRAM] unsigned char
+ 1344 ;; Return value: Size Location Type
+ 1345 ;; 1 wreg void
+ 1346 ;; Registers used:
+ 1347 ;; wreg, fsr2l, fsr2h, status,2, status,0, prodl, prodh
+ 1348 ;; Tracked objects:
+ 1349 ;; On entry : 0/0
+ 1350 ;; On exit : 0/0
+ 1351 ;; Unchanged: 0/0
+ 1352 ;; Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ 1353 ;; Params: 0 0 0 0 0 0 0
+ 1354 ;; Locals: 6 0 0 0 0 0 0
+ 1355 ;; Temps: 36 0 0 0 0 0 0
+ 1356 ;; Totals: 42 0 0 0 0 0 0
+ 1357 ;;Total ram usage: 42 bytes
+ 1358 ;; Hardware stack levels used: 1
+ 1359 ;; This function calls:
+ 1360 ;; Nothing
+ 1361 ;; This function is called by:
+ 1362 ;; Interrupt level 2
+ 1363 ;; This function uses a non-reentrant model
+ 1364 ;;
+ 1365
+ 1366 psect intcode
+ 1367 000008 __pintcode:
+ 1368 opt stack 0
+ 1369 000008 _isr:
+ 1370 opt stack 28
+ 1371
+ 1372 ;incstack = 0
+ 1373 000008 8234 bsf btemp,1,c ;set compiler interrupt flag (level 2)
+ 1374 00000A CFFA F013 movff pclath,??_isr+18
+ 1375 00000E CFFB F014 movff pclatu,??_isr+19
+ 1376 000012 CFE9 F015 movff fsr0l,??_isr+20
+ 1377 000016 CFEA F016 movff fsr0h,??_isr+21
+ 1378 00001A CFE1 F017 movff fsr1l,??_isr+22
+ 1379 00001E CFE2 F018 movff fsr1h,??_isr+23
+ 1380 000022 CFD9 F019 movff fsr2l,??_isr+24
+ 1381 000026 CFDA F01A movff fsr2h,??_isr+25
+ 1382 00002A CFF3 F01B movff prodl,??_isr+26
+ 1383 00002E CFF4 F01C movff prodh,??_isr+27
+ 1384 000032 CFF6 F01D movff tblptrl,??_isr+28
+ 1385 000036 CFF7 F01E movff tblptrh,??_isr+29
+ 1386 00003A CFF8 F01F movff tblptru,??_isr+30
+ 1387 00003E CFF5 F020 movff tablat,??_isr+31
+ 1388 000042 C034 F021 movff btemp,??_isr+32
+ 1389 000046 C035 F022 movff btemp+1,??_isr+33
+ 1390 00004A C036 F023 movff btemp+2,??_isr+34
+ 1391 00004E C037 F024 movff btemp+3,??_isr+35
+ 1392
+ 1393 ;main.c: 115: unsigned char i, data_a, data_b;
+ 1394 ;main.c: 117: PORTDbits.RD3 = 0;
+ 1395 000052 9683 bcf 3971,3,c ;volatile
+ 1396
+ 1397 ;main.c: 119: if (PIR1bits.TMR2IF) {
+ 1398 000054 A29E btfss 3998,1,c ;volatile
+ 1399 000056 D156 goto i2l59
+ 1400
+ 1401 ;main.c: 120: data_a = PORTA;
+ 1402 000058 CF80 F025 movff 3968,isr@data_a ;volatile
+ 1403
+ 1404 ;main.c: 121: data_b = PORTB;
+ 1405 00005C CF81 F026 movff 3969,isr@data_b ;volatile
+ 1406
+ 1407 ;main.c: 122: i = 7;
+ 1408 000060 0E07 movlw 7
+ 1409 000062 6E2A movwf isr@i,c
+ 1410 000064
+ 1411 ;main.c: 125: keys_data[i] = (keys_data[i] << 1) | ((data_a >> i) & 0x01);
+ 1412 000064 502A movf isr@i,w,c
+ 1413 000066 0D04 mullw 4
+ 1414 000068 0E62 movlw low _keys_data
+ 1415 00006A 24F3 addwf prodl,w,c
+ 1416 00006C 6ED9 movwf fsr2l,c
+ 1417 00006E 0E00 movlw high _keys_data
+ 1418 000070 20F4 addwfc prodh,w,c
+ 1419 000072 6EDA movwf fsr2h,c
+ 1420 000074 CFDE F001 movff postinc2,??_isr
+ 1421 000078 CFDE F002 movff postinc2,??_isr+1
+ 1422 00007C CFDE F003 movff postinc2,??_isr+2
+ 1423 000080 CFDE F004 movff postinc2,??_isr+3
+ 1424 000084 90D8 bcf status,0,c
+ 1425 000086 3401 rlcf ??_isr,w,c
+ 1426 000088 6E05 movwf (??_isr+4)& (0+255),c
+ 1427 00008A 3402 rlcf ??_isr+1,w,c
+ 1428 00008C 6E06 movwf (??_isr+5)& (0+255),c
+ 1429 00008E 3403 rlcf ??_isr+2,w,c
+ 1430 000090 6E07 movwf (??_isr+6)& (0+255),c
+ 1431 000092 3404 rlcf ??_isr+3,w,c
+ 1432 000094 6E08 movwf (??_isr+7)& (0+255),c
+ 1433 000096 C02A F009 movff isr@i,??_isr+8
+ 1434 00009A C025 F00A movff isr@data_a,??_isr+9
+ 1435 00009E 2A09 incf ??_isr+8,f,c
+ 1436 0000A0 D002 goto i2u38_44
+ 1437 0000A2 i2u38_45:
+ 1438 0000A2 90D8 bcf status,0,c
+ 1439 0000A4 320A rrcf ??_isr+9,f,c
+ 1440 0000A6 i2u38_44:
+ 1441 0000A6 2E09 decfsz ??_isr+8,f,c
+ 1442 0000A8 D7FC goto i2u38_45
+ 1443 0000AA 0E01 movlw 1
+ 1444 0000AC 160A andwf ??_isr+9,f,c
+ 1445 0000AE 500A movf ??_isr+9,w,c
+ 1446 0000B0 1005 iorwf ??_isr+4,w,c
+ 1447 0000B2 6E0B movwf (??_isr+10)& (0+255),c
+ 1448 0000B4 5006 movf ??_isr+5,w,c
+ 1449 0000B6 6E0C movwf (??_isr+11)& (0+255),c
+ 1450 0000B8 5007 movf ??_isr+6,w,c
+ 1451 0000BA 6E0D movwf (??_isr+12)& (0+255),c
+ 1452 0000BC 5008 movf ??_isr+7,w,c
+ 1453 0000BE 6E0E movwf (??_isr+13)& (0+255),c
+ 1454 0000C0 502A movf isr@i,w,c
+ 1455 0000C2 0D04 mullw 4
+ 1456 0000C4 0E62 movlw low _keys_data
+ 1457 0000C6 24F3 addwf prodl,w,c
+ 1458 0000C8 6ED9 movwf fsr2l,c
+ 1459 0000CA 0E00 movlw high _keys_data
+ 1460 0000CC 20F4 addwfc prodh,w,c
+ 1461 0000CE 6EDA movwf fsr2h,c
+ 1462 0000D0 C00B FFDE movff ??_isr+10,postinc2
+ 1463 0000D4 C00C FFDE movff ??_isr+11,postinc2
+ 1464 0000D8 C00D FFDE movff ??_isr+12,postinc2
+ 1465 0000DC C00E FFDE movff ??_isr+13,postinc2
+ 1466
+ 1467 ;main.c: 126: keys_data[i + 8] = (keys_data[i + 8] << 1) | ((data_b >> i) & 0x01);
+ 1468 0000E0 502A movf isr@i,w,c
+ 1469 0000E2 6E01 movwf ??_isr& (0+255),c
+ 1470 0000E4 6A02 clrf (??_isr+1)& (0+255),c
+ 1471 0000E6 90D8 bcf status,0,c
+ 1472 0000E8 3601 rlcf ??_isr,f,c
+ 1473 0000EA 3602 rlcf ??_isr+1,f,c
+ 1474 0000EC 90D8 bcf status,0,c
+ 1475 0000EE 3601 rlcf ??_isr,f,c
+ 1476 0000F0 3602 rlcf ??_isr+1,f,c
+ 1477 0000F2 0E20 movlw 32
+ 1478 0000F4 2601 addwf ??_isr,f,c
+ 1479 0000F6 0E00 movlw 0
+ 1480 0000F8 2202 addwfc ??_isr+1,f,c
+ 1481 0000FA 0E62 movlw low _keys_data
+ 1482 0000FC 2401 addwf ??_isr,w,c
+ 1483 0000FE 6ED9 movwf fsr2l,c
+ 1484 000100 0E00 movlw high _keys_data
+ 1485 000102 2002 addwfc ??_isr+1,w,c
+ 1486 000104 6EDA movwf fsr2h,c
+ 1487 000106 CFDE F003 movff postinc2,??_isr+2
+ 1488 00010A CFDE F004 movff postinc2,??_isr+3
+ 1489 00010E CFDE F005 movff postinc2,??_isr+4
+ 1490 000112 CFDE F006 movff postinc2,??_isr+5
+ 1491 000116 90D8 bcf status,0,c
+ 1492 000118 3403 rlcf ??_isr+2,w,c
+ 1493 00011A 6E07 movwf (??_isr+6)& (0+255),c
+ 1494 00011C 3404 rlcf ??_isr+3,w,c
+ 1495 00011E 6E08 movwf (??_isr+7)& (0+255),c
+ 1496 000120 3405 rlcf ??_isr+4,w,c
+ 1497 000122 6E09 movwf (??_isr+8)& (0+255),c
+ 1498 000124 3406 rlcf ??_isr+5,w,c
+ 1499 000126 6E0A movwf (??_isr+9)& (0+255),c
+ 1500 000128 C02A F00B movff isr@i,??_isr+10
+ 1501 00012C C026 F00C movff isr@data_b,??_isr+11
+ 1502 000130 2A0B incf ??_isr+10,f,c
+ 1503 000132 D002 goto i2u39_44
+ 1504 000134 i2u39_45:
+ 1505 000134 90D8 bcf status,0,c
+ 1506 000136 320C rrcf ??_isr+11,f,c
+ 1507 000138 i2u39_44:
+ 1508 000138 2E0B decfsz ??_isr+10,f,c
+ 1509 00013A D7FC goto i2u39_45
+ 1510 00013C 0E01 movlw 1
+ 1511 00013E 160C andwf ??_isr+11,f,c
+ 1512 000140 500C movf ??_isr+11,w,c
+ 1513 000142 1007 iorwf ??_isr+6,w,c
+ 1514 000144 6E0D movwf (??_isr+12)& (0+255),c
+ 1515 000146 5008 movf ??_isr+7,w,c
+ 1516 000148 6E0E movwf (??_isr+13)& (0+255),c
+ 1517 00014A 5009 movf ??_isr+8,w,c
+ 1518 00014C 6E0F movwf (??_isr+14)& (0+255),c
+ 1519 00014E 500A movf ??_isr+9,w,c
+ 1520 000150 6E10 movwf (??_isr+15)& (0+255),c
+ 1521 000152 502A movf isr@i,w,c
+ 1522 000154 6E11 movwf (??_isr+16)& (0+255),c
+ 1523 000156 6A12 clrf (??_isr+17)& (0+255),c
+ 1524 000158 90D8 bcf status,0,c
+ 1525 00015A 3611 rlcf ??_isr+16,f,c
+ 1526 00015C 3612 rlcf ??_isr+17,f,c
+ 1527 00015E 90D8 bcf status,0,c
+ 1528 000160 3611 rlcf ??_isr+16,f,c
+ 1529 000162 3612 rlcf ??_isr+17,f,c
+ 1530 000164 0E20 movlw 32
+ 1531 000166 2611 addwf ??_isr+16,f,c
+ 1532 000168 0E00 movlw 0
+ 1533 00016A 2212 addwfc ??_isr+17,f,c
+ 1534 00016C 0E62 movlw low _keys_data
+ 1535 00016E 2411 addwf ??_isr+16,w,c
+ 1536 000170 6ED9 movwf fsr2l,c
+ 1537 000172 0E00 movlw high _keys_data
+ 1538 000174 2012 addwfc ??_isr+17,w,c
+ 1539 000176 6EDA movwf fsr2h,c
+ 1540 000178 C00D FFDE movff ??_isr+12,postinc2
+ 1541 00017C C00E FFDE movff ??_isr+13,postinc2
+ 1542 000180 C00F FFDE movff ??_isr+14,postinc2
+ 1543 000184 C010 FFDE movff ??_isr+15,postinc2
+ 1544
+ 1545 ;main.c: 131: keypresses |= (keys_data[i] && !(keys_data[i] & 0xFFFFFF00))<<i;
+ 1546 000188 0E00 movlw 0
+ 1547 00018A 6E27 movwf _isr$595,c
+ 1548 00018C 502A movf isr@i,w,c
+ 1549 00018E 0D04 mullw 4
+ 1550 000190 0E62 movlw low _keys_data
+ 1551 000192 24F3 addwf prodl,w,c
+ 1552 000194 6ED9 movwf fsr2l,c
+ 1553 000196 0E00 movlw high _keys_data
+ 1554 000198 20F4 addwfc prodh,w,c
+ 1555 00019A 6EDA movwf fsr2h,c
+ 1556 00019C 50DE movf postinc2,w,c
+ 1557 00019E 10DE iorwf postinc2,w,c
+ 1558 0001A0 10DE iorwf postinc2,w,c
+ 1559 0001A2 10DE iorwf postinc2,w,c
+ 1560 0001A4 B4D8 btfsc status,2,c
+ 1561 0001A6 D01C goto i2l62
+ 1562 0001A8 502A movf isr@i,w,c
+ 1563 0001AA 0D04 mullw 4
+ 1564 0001AC 0E62 movlw low _keys_data
+ 1565 0001AE 24F3 addwf prodl,w,c
+ 1566 0001B0 6ED9 movwf fsr2l,c
+ 1567 0001B2 0E00 movlw high _keys_data
+ 1568 0001B4 20F4 addwfc prodh,w,c
+ 1569 0001B6 6EDA movwf fsr2h,c
+ 1570 0001B8 0E00 movlw 0
+ 1571 0001BA 14DE andwf postinc2,w,c
+ 1572 0001BC 6E01 movwf ??_isr& (0+255),c
+ 1573 0001BE 0EFF movlw 255
+ 1574 0001C0 14DE andwf postinc2,w,c
+ 1575 0001C2 6E02 movwf (??_isr+1)& (0+255),c
+ 1576 0001C4 0EFF movlw 255
+ 1577 0001C6 14DE andwf postinc2,w,c
+ 1578 0001C8 6E03 movwf (??_isr+2)& (0+255),c
+ 1579 0001CA 0EFF movlw 255
+ 1580 0001CC 14DE andwf postinc2,w,c
+ 1581 0001CE 6E04 movwf (??_isr+3)& (0+255),c
+ 1582 0001D0 5001 movf ??_isr,w,c
+ 1583 0001D2 1002 iorwf ??_isr+1,w,c
+ 1584 0001D4 1003 iorwf ??_isr+2,w,c
+ 1585 0001D6 1004 iorwf ??_isr+3,w,c
+ 1586 0001D8 A4D8 btfss status,2,c
+ 1587 0001DA D002 goto i2l62
+ 1588 0001DC 0E01 movlw 1
+ 1589 0001DE 6E27 movwf _isr$595,c
+ 1590 0001E0 i2l62:
+ 1591 0001E0 C02A F001 movff isr@i,??_isr
+ 1592 0001E4 5027 movf _isr$595,w,c
+ 1593 0001E6 6E02 movwf (??_isr+1)& (0+255),c
+ 1594 0001E8 6A03 clrf (??_isr+2)& (0+255),c
+ 1595 0001EA 2A01 incf ??_isr,f,c
+ 1596 0001EC D003 goto i2u42_44
+ 1597 0001EE i2u42_45:
+ 1598 0001EE 90D8 bcf status,0,c
+ 1599 0001F0 3602 rlcf ??_isr+1,f,c
+ 1600 0001F2 3603 rlcf ??_isr+2,f,c
+ 1601 0001F4 i2u42_44:
+ 1602 0001F4 2E01 decfsz ??_isr,f,c
+ 1603 0001F6 D7FB goto i2u42_45
+ 1604 0001F8 5002 movf ??_isr+1,w,c
+ 1605 0001FA 0100 movlb 0 ; () banked
+ 1606 0001FC 1360 iorwf _keypresses& (0+255),f,b ;volatile
+ 1607 0001FE 5003 movf ??_isr+2,w,c
+ 1608 000200 1361 iorwf (_keypresses+1)& (0+255),f,b ;volatile
+ 1609
+ 1610 ; BSR set to: 0
+ 1611 ;main.c: 132: keypresses |= (keys_data[i + 8] && !(keys_data[i + 8] & 0xFFFFFF00))<<(i +
+ + 8);
+ 1612 000202 0E00 movlw 0
+ 1613 000204 6E28 movwf _isr$596,c
+ 1614
+ 1615 ; BSR set to: 0
+ 1616 000206 502A movf isr@i,w,c
+ 1617 000208 6E01 movwf ??_isr& (0+255),c
+ 1618 00020A 6A02 clrf (??_isr+1)& (0+255),c
+ 1619 00020C 90D8 bcf status,0,c
+ 1620 00020E 3601 rlcf ??_isr,f,c
+ 1621 000210 3602 rlcf ??_isr+1,f,c
+ 1622 000212 90D8 bcf status,0,c
+ 1623 000214 3601 rlcf ??_isr,f,c
+ 1624 000216 3602 rlcf ??_isr+1,f,c
+ 1625 000218 0E20 movlw 32
+ 1626 00021A 2601 addwf ??_isr,f,c
+ 1627 00021C 0E00 movlw 0
+ 1628 00021E 2202 addwfc ??_isr+1,f,c
+ 1629 000220 0E62 movlw low _keys_data
+ 1630 000222 2401 addwf ??_isr,w,c
+ 1631 000224 6ED9 movwf fsr2l,c
+ 1632 000226 0E00 movlw high _keys_data
+ 1633 000228 2002 addwfc ??_isr+1,w,c
+ 1634 00022A 6EDA movwf fsr2h,c
+ 1635 00022C 50DE movf postinc2,w,c
+ 1636 00022E 10DE iorwf postinc2,w,c
+ 1637 000230 10DE iorwf postinc2,w,c
+ 1638 000232 10DE iorwf postinc2,w,c
+ 1639 000234 B4D8 btfsc status,2,c
+ 1640 000236 D027 goto i2l64
+ 1641
+ 1642 ; BSR set to: 0
+ 1643 000238 502A movf isr@i,w,c
+ 1644 00023A 6E01 movwf ??_isr& (0+255),c
+ 1645 00023C 6A02 clrf (??_isr+1)& (0+255),c
+ 1646 00023E 90D8 bcf status,0,c
+ 1647 000240 3601 rlcf ??_isr,f,c
+ 1648 000242 3602 rlcf ??_isr+1,f,c
+ 1649 000244 90D8 bcf status,0,c
+ 1650 000246 3601 rlcf ??_isr,f,c
+ 1651 000248 3602 rlcf ??_isr+1,f,c
+ 1652 00024A 0E20 movlw 32
+ 1653 00024C 2601 addwf ??_isr,f,c
+ 1654 00024E 0E00 movlw 0
+ 1655 000250 2202 addwfc ??_isr+1,f,c
+ 1656 000252 0E62 movlw low _keys_data
+ 1657 000254 2401 addwf ??_isr,w,c
+ 1658 000256 6ED9 movwf fsr2l,c
+ 1659 000258 0E00 movlw high _keys_data
+ 1660 00025A 2002 addwfc ??_isr+1,w,c
+ 1661 00025C 6EDA movwf fsr2h,c
+ 1662 00025E 0E00 movlw 0
+ 1663 000260 14DE andwf postinc2,w,c
+ 1664 000262 6E03 movwf (??_isr+2)& (0+255),c
+ 1665 000264 0EFF movlw 255
+ 1666 000266 14DE andwf postinc2,w,c
+ 1667 000268 6E04 movwf (??_isr+3)& (0+255),c
+ 1668 00026A 0EFF movlw 255
+ 1669 00026C 14DE andwf postinc2,w,c
+ 1670 00026E 6E05 movwf (??_isr+4)& (0+255),c
+ 1671 000270 0EFF movlw 255
+ 1672 000272 14DE andwf postinc2,w,c
+ 1673 000274 6E06 movwf (??_isr+5)& (0+255),c
+ 1674 000276 5003 movf ??_isr+2,w,c
+ 1675 000278 1004 iorwf ??_isr+3,w,c
+ 1676 00027A 1005 iorwf ??_isr+4,w,c
+ 1677 00027C 1006 iorwf ??_isr+5,w,c
+ 1678 00027E A4D8 btfss status,2,c
+ 1679 000280 D002 goto i2l64
+ 1680
+ 1681 ; BSR set to: 0
+ 1682 000282 0E01 movlw 1
+ 1683 000284 6E28 movwf _isr$596,c
+ 1684 000286 i2l64:
+ 1685
+ 1686 ; BSR set to: 0
+ 1687
+ 1688 ; BSR set to: 0
+ 1689 000286 C02A F001 movff isr@i,??_isr
+ 1690 00028A 0E08 movlw 8
+ 1691 00028C 2601 addwf ??_isr,f,c
+ 1692 00028E 5028 movf _isr$596,w,c
+ 1693 000290 6E02 movwf (??_isr+1)& (0+255),c
+ 1694 000292 6A03 clrf (??_isr+2)& (0+255),c
+ 1695 000294 2A01 incf ??_isr,f,c
+ 1696 000296 D003 goto i2u45_44
+ 1697 000298 i2u45_45:
+ 1698 000298 90D8 bcf status,0,c
+ 1699 00029A 3602 rlcf ??_isr+1,f,c
+ 1700 00029C 3603 rlcf ??_isr+2,f,c
+ 1701 00029E i2u45_44:
+ 1702 00029E 2E01 decfsz ??_isr,f,c
+ 1703 0002A0 D7FB goto i2u45_45
+ 1704 0002A2 5002 movf ??_isr+1,w,c
+ 1705 0002A4 0100 movlb 0 ; () banked
+ 1706 0002A6 1360 iorwf _keypresses& (0+255),f,b ;volatile
+ 1707 0002A8 5003 movf ??_isr+2,w,c
+ 1708 0002AA 1361 iorwf (_keypresses+1)& (0+255),f,b ;volatile
+ 1709
+ 1710 ; BSR set to: 0
+ 1711 ;main.c: 134: } while (i--);
+ 1712 0002AC 062A decf isr@i,f,c
+ 1713 0002AE 282A incf isr@i,w,c
+ 1714 0002B0 A4D8 btfss status,2,c
+ 1715 0002B2 D6D8 goto i2l60
+ 1716
+ 1717 ; BSR set to: 0
+ 1718 ;main.c: 138: PORTDbits.RD4 = PORTAbits.RA0;
+ 1719 0002B4 A080 btfss 3968,0,c ;volatile
+ 1720 0002B6 D002 bra i2u47_45
+ 1721 0002B8 8883 bsf 3971,4,c ;volatile
+ 1722 0002BA D001 bra i2u47_47
+ 1723 0002BC i2u47_45:
+ 1724 0002BC 9883 bcf 3971,4,c ;volatile
+ 1725 0002BE i2u47_47:
+ 1726
+ 1727 ;main.c: 139: PORTDbits.RD2 = (keys_data[0] && !(keys_data[0] & 0xFFFFFF00));
+ 1728 0002BE 0E00 movlw 0
+ 1729 0002C0 6E29 movwf _isr$605,c
+ 1730 0002C2 0100 movlb 0 ; () banked
+ 1731 0002C4 5162 movf _keys_data& (0+255),w,b ;volatile
+ 1732 0002C6 1163 iorwf (_keys_data+1)& (0+255),w,b ;volatile
+ 1733 0002C8 1164 iorwf (_keys_data+2)& (0+255),w,b ;volatile
+ 1734 0002CA 1165 iorwf (_keys_data+3)& (0+255),w,b ;volatile
+ 1735 0002CC B4D8 btfsc status,2,c
+ 1736 0002CE D014 goto i2l67
+ 1737
+ 1738 ; BSR set to: 0
+ 1739 0002D0 0E00 movlw 0
+ 1740 0002D2 1562 andwf _keys_data& (0+255),w,b ;volatile
+ 1741 0002D4 6E01 movwf ??_isr& (0+255),c
+ 1742 0002D6 0EFF movlw 255
+ 1743 0002D8 1563 andwf (_keys_data+1)& (0+255),w,b ;volatile
+ 1744 0002DA 6E02 movwf (??_isr+1)& (0+255),c
+ 1745 0002DC 0EFF movlw 255
+ 1746 0002DE 1564 andwf (_keys_data+2)& (0+255),w,b ;volatile
+ 1747 0002E0 6E03 movwf (??_isr+2)& (0+255),c
+ 1748 0002E2 0EFF movlw 255
+ 1749 0002E4 1565 andwf (_keys_data+3)& (0+255),w,b ;volatile
+ 1750 0002E6 6E04 movwf (??_isr+3)& (0+255),c
+ 1751 0002E8 5001 movf ??_isr,w,c
+ 1752 0002EA 1002 iorwf ??_isr+1,w,c
+ 1753 0002EC 1003 iorwf ??_isr+2,w,c
+ 1754 0002EE 1004 iorwf ??_isr+3,w,c
+ 1755 0002F0 A4D8 btfss status,2,c
+ 1756 0002F2 D002 goto i2l67
+ 1757
+ 1758 ; BSR set to: 0
+ 1759 0002F4 0E01 movlw 1
+ 1760 0002F6 6E29 movwf _isr$605,c
+ 1761 0002F8 i2l67:
+ 1762
+ 1763 ; BSR set to: 0
+ 1764
+ 1765 ; BSR set to: 0
+ 1766 0002F8 B029 btfsc _isr$605,0,c
+ 1767 0002FA D002 bra i2u50_45
+ 1768 0002FC 9483 bcf 3971,2,c ;volatile
+ 1769 0002FE D001 bra i2u50_46
+ 1770 000300 i2u50_45:
+ 1771 000300 8483 bsf 3971,2,c ;volatile
+ 1772 000302 i2u50_46:
+ 1773
+ 1774 ;main.c: 143: PIR1bits.TMR2IF = 0;
+ 1775 000302 929E bcf 3998,1,c ;volatile
+ 1776 000304 i2l59:
+ 1777
+ 1778 ;main.c: 144: }
+ 1779 ;main.c: 146: PORTDbits.RD3 = 1;
+ 1780 000304 8683 bsf 3971,3,c ;volatile
+ 1781 000306 C024 F037 movff ??_isr+35,btemp+3
+ 1782 00030A C023 F036 movff ??_isr+34,btemp+2
+ 1783 00030E C022 F035 movff ??_isr+33,btemp+1
+ 1784 000312 C021 F034 movff ??_isr+32,btemp
+ 1785 000316 C020 FFF5 movff ??_isr+31,tablat
+ 1786 00031A C01F FFF8 movff ??_isr+30,tblptru
+ 1787 00031E C01E FFF7 movff ??_isr+29,tblptrh
+ 1788 000322 C01D FFF6 movff ??_isr+28,tblptrl
+ 1789 000326 C01C FFF4 movff ??_isr+27,prodh
+ 1790 00032A C01B FFF3 movff ??_isr+26,prodl
+ 1791 00032E C01A FFDA movff ??_isr+25,fsr2h
+ 1792 000332 C019 FFD9 movff ??_isr+24,fsr2l
+ 1793 000336 C018 FFE2 movff ??_isr+23,fsr1h
+ 1794 00033A C017 FFE1 movff ??_isr+22,fsr1l
+ 1795 00033E C016 FFEA movff ??_isr+21,fsr0h
+ 1796 000342 C015 FFE9 movff ??_isr+20,fsr0l
+ 1797 000346 C014 FFFB movff ??_isr+19,pclatu
+ 1798 00034A C013 FFFA movff ??_isr+18,pclath
+ 1799 00034E 9234 bcf btemp,1,c ;clear compiler interrupt flag (level 2)
+ 1800 000350 0011 retfie f
+ 1801 000352 __end_of_isr:
+ 1802 opt stack 0
+ 1803 0000 pclatu equ 0xFFB
+ 1804 pclath equ 0xFFA
+ 1805 tblptru equ 0xFF8
+ 1806 tblptrh equ 0xFF7
+ 1807 tblptrl equ 0xFF6
+ 1808 tablat equ 0xFF5
+ 1809 prodh equ 0xFF4
+ 1810 prodl equ 0xFF3
+ 1811 intcon equ 0xFF2
+ 1812 postinc0 equ 0xFEE
+ 1813 fsr0h equ 0xFEA
+ 1814 fsr0l equ 0xFE9
+ 1815 wreg equ 0xFE8
+ 1816 fsr1h equ 0xFE2
+ 1817 fsr1l equ 0xFE1
+ 1818 indf2 equ 0xFDF
+ 1819 postinc2 equ 0xFDE
+ 1820 postdec2 equ 0xFDD
+ 1821 fsr2h equ 0xFDA
+ 1822 fsr2l equ 0xFD9
+ 1823 status equ 0xFD8
+ 1824 pclatu equ 0xFFB
+ 1825 pclath equ 0xFFA
+ 1826 tblptru equ 0xFF8
+ 1827 tblptrh equ 0xFF7
+ 1828 tblptrl equ 0xFF6
+ 1829 tablat equ 0xFF5
+ 1830 prodh equ 0xFF4
+ 1831 prodl equ 0xFF3
+ 1832 intcon equ 0xFF2
+ 1833 postinc0 equ 0xFEE
+ 1834 fsr0h equ 0xFEA
+ 1835 fsr0l equ 0xFE9
+ 1836 wreg equ 0xFE8
+ 1837 fsr1h equ 0xFE2
+ 1838 fsr1l equ 0xFE1
+ 1839 indf2 equ 0xFDF
+ 1840 postinc2 equ 0xFDE
+ 1841 postdec2 equ 0xFDD
+ 1842 fsr2h equ 0xFDA
+ 1843 fsr2l equ 0xFD9
+ 1844 status equ 0xFD8
+ 1845
+ 1846 psect rparam
+ 1847 0000 pclatu equ 0xFFB
+ 1848 pclath equ 0xFFA
+ 1849 tblptru equ 0xFF8
+ 1850 tblptrh equ 0xFF7
+ 1851 tblptrl equ 0xFF6
+ 1852 tablat equ 0xFF5
+ 1853 prodh equ 0xFF4
+ 1854 prodl equ 0xFF3
+ 1855 intcon equ 0xFF2
+ 1856 postinc0 equ 0xFEE
+ 1857 fsr0h equ 0xFEA
+ 1858 fsr0l equ 0xFE9
+ 1859 wreg equ 0xFE8
+ 1860 fsr1h equ 0xFE2
+ 1861 fsr1l equ 0xFE1
+ 1862 indf2 equ 0xFDF
+ 1863 postinc2 equ 0xFDE
+ 1864 postdec2 equ 0xFDD
+ 1865 fsr2h equ 0xFDA
+ 1866 fsr2l equ 0xFD9
+ 1867 status equ 0xFD8
+ 1868
+ 1869 psect temp
+ 1870 000034 btemp:
+ 1871 opt stack 0
+ 1872 000034 ds 1
+ 1873 0000 int$flags set btemp
+ 1874 0000 wtemp6 set btemp+1
+ 1875 pclatu equ 0xFFB
+ 1876 pclath equ 0xFFA
+ 1877 tblptru equ 0xFF8
+ 1878 tblptrh equ 0xFF7
+ 1879 tblptrl equ 0xFF6
+ 1880 tablat equ 0xFF5
+ 1881 prodh equ 0xFF4
+ 1882 prodl equ 0xFF3
+ 1883 intcon equ 0xFF2
+ 1884 postinc0 equ 0xFEE
+ 1885 fsr0h equ 0xFEA
+ 1886 fsr0l equ 0xFE9
+ 1887 wreg equ 0xFE8
+ 1888 fsr1h equ 0xFE2
+ 1889 fsr1l equ 0xFE1
+ 1890 indf2 equ 0xFDF
+ 1891 postinc2 equ 0xFDE
+ 1892 postdec2 equ 0xFDD
+ 1893 fsr2h equ 0xFDA
+ 1894 fsr2l equ 0xFD9
+ 1895 status equ 0xFD8
Data Sizes:
Strings 0
Constant 0
- Data 2
- BSS 30
+ Data 0
+ BSS 66
Persistent 0
Stack 0
Auto Spaces:
Space Size Autos Used
- COMRAM 94 36 68
- BANK0 160 9 9
+ COMRAM 94 51 51
+ BANK0 160 20 86
BANK1 256 0 0
BANK2 256 0 0
BANK3 256 0 0
@@ -1561,36 +1930,36 @@ Auto Spaces:
Pointer List with Targets:
- memset@p1 PTR void size(2) Largest target is 30
- -> keypresses(COMRAM[30]),
+ memset@p1 PTR void size(2) Largest target is 64
+ -> keys_data(BANK0[64]),
- memset@p PTR unsigned char size(2) Largest target is 30
- -> keypresses(COMRAM[30]),
+ memset@p PTR unsigned char size(2) Largest target is 64
+ -> keys_data(BANK0[64]),
midi_note_on@pkt PTR struct . size(2) Largest target is 7
- -> main@sample_message(BANK0[7]),
+ -> main@message(BANK0[7]),
midi_set_channel@pkt PTR struct . size(2) Largest target is 7
- -> main@sample_message(BANK0[7]),
+ -> main@message(BANK0[7]),
midi_set_status@pkt PTR struct . size(2) Largest target is 7
- -> main@sample_message(BANK0[7]),
+ -> main@message(BANK0[7]),
eusart_write_midi@data PTR unsigned char size(2) Largest target is 7
- -> sample_message.data(COMRAM[4]), main@sample_message(BANK0[7]),
+ -> message.data(COMRAM[4]), main@message(BANK0[7]),
eusart_write_midi@pkt PTR const struct . size(2) Largest target is 7
- -> main@sample_message(BANK0[7]),
+ -> main@message(BANK0[7]),
- sp__memset PTR void size(2) Largest target is 30
- -> keypresses(COMRAM[30]),
+ sp__memset PTR void size(2) Largest target is 64
+ -> keys_data(BANK0[64]),
Critical Paths under _main in COMRAM
- _main->_midi_note_on
+ _main->_eusart_write_midi
_midi_note_on->_midi_set_channel
- _eusart_write_midi->_putch
+ _eusart_write_midi->_eusart2_putch
Critical Paths under _isr in COMRAM
@@ -1649,46 +2018,48 @@ Call Graph Tables:
---------------------------------------------------------------------------------
(Depth) Function Calls Base Space Used Autos Params Refs
---------------------------------------------------------------------------------
- (0) _main 9 9 0 2419
- 2 BANK0 7 7 0
+ (0) _main 14 14 0 2013
+ 6 BANK0 14 14 0
_eusart_write_midi
_init_hw
_memset
_midi_note_on
---------------------------------------------------------------------------------
- (1) _midi_note_on 8 2 6 1576
- 30 COMRAM 6 0 6
- 0 BANK0 2 2 0
+ (1) _midi_note_on 6 0 6 1242
+ 0 BANK0 6 0 6
_midi_set_channel
_midi_set_status
---------------------------------------------------------------------------------
- (2) _midi_set_status 4 1 3 453
- 25 COMRAM 4 1 3
+ (2) _midi_set_status 4 1 3 370
+ 42 COMRAM 4 1 3
---------------------------------------------------------------------------------
- (2) _midi_set_channel 5 1 4 453
- 25 COMRAM 5 1 4
+ (2) _midi_set_channel 5 1 4 370
+ 42 COMRAM 5 1 4
---------------------------------------------------------------------------------
- (1) _memset 8 2 6 407
- 25 COMRAM 8 2 6
+ (1) _memset 8 2 6 324
+ 42 COMRAM 8 2 6
---------------------------------------------------------------------------------
(1) _init_hw 0 0 0 0
_eusart1_init
+ _eusart2_init
+ ---------------------------------------------------------------------------------
+ (2) _eusart2_init 0 0 0 0
---------------------------------------------------------------------------------
(2) _eusart1_init 0 0 0 0
---------------------------------------------------------------------------------
- (1) _eusart_write_midi 8 6 2 338
- 26 COMRAM 8 6 2
- _putch
+ (1) _eusart_write_midi 8 6 2 255
+ 43 COMRAM 8 6 2
+ _eusart2_putch
---------------------------------------------------------------------------------
- (2) _putch 1 1 0 22
- 25 COMRAM 1 1 0
+ (2) _eusart2_putch 1 1 0 22
+ 42 COMRAM 1 1 0
---------------------------------------------------------------------------------
Estimated maximum stack depth 2
---------------------------------------------------------------------------------
(Depth) Function Calls Base Space Used Autos Params Refs
---------------------------------------------------------------------------------
- (3) _isr 25 25 0 248
- 0 COMRAM 25 25 0
+ (3) _isr 42 42 0 405
+ 0 COMRAM 42 42 0
---------------------------------------------------------------------------------
Estimated maximum stack depth 3
---------------------------------------------------------------------------------
@@ -1697,9 +2068,10 @@ Call Graph Tables:
_main (ROOT)
_eusart_write_midi
- _putch
+ _eusart2_putch
_init_hw
_eusart1_init
+ _eusart2_init
_memset
_midi_note_on
_midi_set_channel
@@ -1722,92 +2094,101 @@ BANK2 100 0 0 8 0.0%
BITBANK1 100 0 0 5 0.0%
BANK1 100 0 0 6 0.0%
BITBANK0 A0 0 0 3 0.0%
-BANK0 A0 9 9 4 5.6%
+BANK0 A0 14 56 4 53.8%
BITCOMRAM 5E 0 0 0 0.0%
-COMRAM 5E 24 44 1 72.3%
+COMRAM 5E 33 33 1 54.3%
BITSFR_1 0 0 0 200 0.0%
SFR_1 0 0 0 200 0.0%
BITSFR 0 0 0 200 0.0%
SFR 0 0 0 200 0.0%
STACK 0 0 0 2 0.0%
NULL 0 0 0 0 0.0%
-ABS 0 0 4D 9 0.0%
-DATA 0 0 4D 17 0.0%
+ABS 0 0 89 9 0.0%
+DATA 0 0 89 17 0.0%
CODE 0 0 0 0 0.0%
Microchip Technology PIC18 Macro Assembler V1.44 build -154322312
-Symbol Table Fri Feb 23 16:30:02 2018
+Symbol Table Tue Feb 27 10:27:03 2018
- l70 0346 l78 0296 l79 0284
- __CFG_CP0$OFF 000000 __CFG_CP1$OFF 000000 __CFG_CP2$OFF 000000
- __CFG_CP3$OFF 000000 __CFG_LVP$ON 000000 l570 0390
- l569 03A0 __CFG_CPB$OFF 000000 _PR2 000FBB
- __CFG_CPD$OFF 000000 _isr 0008 prod 000FF3
- wreg 000FE8 _TXSTA1bits 000FAC l1071 041A
- l1129 0390 l1163 0284 ?_isr 0001
- i2l61 015E i2l55 016A i2l56 0060
- i2l58 00C6 _main 0308 midi_note_on@channel 0021
- fsr0h 000FEA fsr1h 000FE2 fsr2h 000FDA
- fsr0l 000FE9 indf2 000FDF fsr1l 000FE1
- fsr2l 000FD9 btemp 0045 __CFG_BORV$190 000000
- isr@i 0019 prodh 000FF4 prodl 000FF3
- start 01B8 __CFG_IESO$OFF 000000 midi_note_on@pkt 001F
- ___param_bank 000000 ??_isr 0001 _BAUDCON1bits 000FB8
+ l76 0398 l87 0494 l79 042C
+ l88 0482 __CFG_CP0$OFF 000000 __CFG_CP1$OFF 000000
+ __CFG_CP2$OFF 000000 __CFG_CP3$OFF 000000 __CFG_LVP$ON 000000
+ l596 0588 l597 0578 __CFG_CPB$OFF 000000
+ _PR2 000FBB __CFG_CPD$OFF 000000 u524 03C4
+ u525 03BE u544 0416 u545 0410
+ u577 03F4 _isr 0008 prod 000FF3
+ wreg 000FE8 _TXSTA1bits 000FAC _TXSTA2bits 000F72
+ l1110 0578 l1202 0398 l1052 0638
+ l1140 0482 l1204 03A2 ?_isr 0001
+ i2l60 0064 i2l62 01E0 i2l64 0286
+ i2l59 0304 i2l67 02F8 main@message 00AF
+ _main 0356 midi_note_on@channel 00A4 fsr0h 000FEA
+ fsr1h 000FE2 fsr2h 000FDA fsr0l 000FE9
+ indf2 000FDF fsr1l 000FE1 fsr2l 000FD9
+ btemp 0034 __CFG_BORV$190 000000 isr@i 002A
+ prodh 000FF4 prodl 000FF3 start 0352
+ __CFG_IESO$OFF 000000 midi_note_on@pkt 00A2 ___param_bank 000000
+ ??_isr 0001 _BAUDCON1bits 000FB8 _BAUDCON2bits 000F70
?_main 0001 _RC1IF 007CF5 __CFG_WDTEN$ON 000000
- _TX1IF 007CF4 _PORTA 000F80 _PORTB 000F81
- _TRISA 000F92 _TRISB 000F93 __CFG_WRT0$OFF 000000
- __CFG_WRT1$OFF 000000 __CFG_WRT2$OFF 000000 __CFG_WRT3$OFF 000000
- __CFG_EBTR0$OFF 000000 __CFG_FCMEN$OFF 000000 __CFG_EBTR1$OFF 000000
- __CFG_EBTR2$OFF 000000 __CFG_EBTR3$OFF 000000 __CFG_WRTB$OFF 000000
- __CFG_WRTC$OFF 000000 __CFG_WRTD$OFF 000000 __CFG_EBTRB$OFF 000000
- __end_of_init_hw 0308 __CFG_MCLRE$EXTMCLR 000000 _putch 0418
- pclath 000FFA tablat 000FF5 _eusart_write_midi 0234
- __end_of_midi_set_status 03FC status 000FD8 wtemp6 0046
- __CFG_HFOFST$ON 000000 ?_eusart_write_midi 001B __CFG_PBADEN$ON 000000
- eusart_write_midi@length 001F __initialization 0354 midi_note_on@note 0023
- __end_of_main 0354 ??_eusart_write_midi 001D midi_note_on@velocity 0024
- ??_main 0025 ?_midi_note_on 001F __activetblptr 000002
- __CFG_PLLCFG$ON 000000 __end_of_eusart_write_midi 02A8 _ANSELA 000F38
- ?_putch 0001 _ANSELB 000F39 _ANSELC 000F3A
+ _TX1IF 007CF4 _TX2IF 007D24 _PORTA 000F80
+ _PORTB 000F81 _TRISA 000F92 _TRISB 000F93
+ __CFG_WRT0$OFF 000000 __CFG_WRT1$OFF 000000 __CFG_WRT2$OFF 000000
+ __CFG_WRT3$OFF 000000 __CFG_EBTR0$OFF 000000 __CFG_FCMEN$OFF 000000
+ __CFG_EBTR1$OFF 000000 __CFG_EBTR2$OFF 000000 __CFG_EBTR3$OFF 000000
+ __CFG_WRTB$OFF 000000 __CFG_WRTC$OFF 000000 __CFG_WRTD$OFF 000000
+ __CFG_EBTRB$OFF 000000 __end_of_init_hw 056E __CFG_MCLRE$EXTMCLR 000000
+ main@i 00AD pclath 000FFA tablat 000FF5
+ _eusart_write_midi 0432 __end_of_midi_set_status 05E4 status 000FD8
+ wtemp6 0035 __CFG_HFOFST$ON 000000 ?_eusart_write_midi 002C
+ __CFG_PBADEN$ON 000000 eusart_write_midi@length 0030 __initialization 061C
+ midi_note_on@note 00A6 __end_of_main 0432 ??_eusart_write_midi 002E
+ midi_note_on@velocity 00A7 ??_main 00A8 ?_midi_note_on 00A2
+ __activetblptr 000002 __CFG_PLLCFG$ON 000000 __end_of_eusart_write_midi 04A6
+ _ANSELA 000F38 _ANSELB 000F39 _ANSELC 000F3A
_ANSELD 000F3B _RC1REG 000FAE _SPBRG1 000FAF
- _TX1REG 000FAD ?_eusart1_init 0001 __CFG_XINST$OFF 000000
- __CFG_STVREN$ON 000000 __end_of_midi_set_channel 03D8 _memset 0386
- clear_0 0372 midi_set_status@status 001C ??_midi_note_on 0060
- ??_init_hw 001A __pdataCOMRAM 0043 tblptrh 000FF7
- tblptrl 000FF6 tblptru 000FF8 putch@c 001A
- __accesstop 0060 __end_of__initialization 0378 ?_midi_set_status 001A
- ??_eusart1_init 001A ___rparam_used 000001 __pcstackCOMRAM 0001
- __end_of_putch 0424 __size_of_eusart_write_midi 0074 ??_putch 001A
- __CFG_CCP2MX$PORTC1 000000 __CFG_CCP3MX$PORTB5 000000 ?_memset 001A
- i2u31_44 00F4 i2u31_45 00F0 i2u33_45 0144
- i2u33_47 0146 i2u36_45 0166 i2u36_46 0168
- i2u29_44 008E i2u29_45 008A _SPBRGH1 000FB0
- __end_of_midi_note_on 0234 eusart_write_midi@pkt 001B __CFG_PWRTEN$OFF 000000
- __Hparam 0000 __Lparam 0000 __pcinit 0354
- _isr$592 0017 __size_of_memset 002C __ramtop 0600
- __ptext0 0308 __ptext1 01BC __ptext2 03D8
- __ptext3 03B2 __ptext4 0386 __ptext5 02A8
- __ptext6 03FC __ptext7 0234 __ptext8 0418
- __end_of_eusart1_init 0418 _T2CONbits 000FBA _init_hw 02A8
- __size_of_isr 01B0 _keypresses 0025 end_of_initialization 0378
- isr@data 0018 memset@c 001C memset@n 001E
- memset@p 0020 __Lmediumconst 0000 postdec2 000FDD
- postinc0 000FEE postinc2 000FDE ?_midi_set_channel 001A
- _PORTAbits 000F80 _PORTDbits 000F83 ??_midi_set_channel 001E
+ _SPBRG2 000F75 _TX1REG 000FAD _TX2REG 000F73
+ ?_eusart1_init 0001 ?_eusart2_init 0001 __CFG_XINST$OFF 000000
+ __CFG_STVREN$ON 000000 __end_of_midi_set_channel 05C0 _memset 056E
+ clear_0 0622 midi_set_status@status 002D ??_midi_note_on 0030
+ __size_of_eusart2_putch 000C ??_init_hw 002B tblptrh 000FF7
+ tblptrl 000FF6 tblptru 000FF8 __accesstop 0060
+ __end_of__initialization 0628 ?_midi_set_status 002B ??_eusart1_init 002B
+ ??_eusart2_init 002B ___rparam_used 000001 __pcstackCOMRAM 0001
+__size_of_eusart_write_midi 0074 __pbssBANK0 0060 _eusart2_putch 0636
+ __CFG_CCP2MX$PORTC1 000000 __CFG_CCP3MX$PORTB5 000000 ?_memset 002B
+ i2u42_44 01F4 i2u50_45 0300 i2u42_45 01EE
+ i2u50_46 0302 i2u45_44 029E i2u45_45 0298
+ i2u38_44 00A6 i2u38_45 00A2 i2u39_44 0138
+ i2u47_45 02BC i2u39_45 0134 i2u47_47 02BE
+ _SPBRGH1 000FB0 _SPBRGH2 000F76 ?_eusart2_putch 0001
+ __end_of_midi_note_on 050C eusart_write_midi@pkt 002C __CFG_PWRTEN$OFF 000000
+ __Hparam 0000 __Lparam 0000 __pcinit 061C
+ _isr$605 0029 _isr$595 0027 _isr$596 0028
+ __size_of_memset 002C __ramtop 0600 __ptext0 0356
+ __ptext1 04A6 __ptext2 05C0 __ptext3 059A
+ __ptext4 056E __ptext5 050C __ptext6 05E4
+ __ptext7 0600 __ptext8 0432 __ptext9 0636
+ __end_of_eusart1_init 061C __end_of_eusart2_init 0600 _T2CONbits 000FBA
+ _init_hw 050C __size_of_isr 034A _keypresses 0060
+ end_of_initialization 0628 memset@c 002D memset@n 002F
+ memset@p 0031 __Lmediumconst 0000 postdec2 000FDD
+ postinc0 000FEE postinc2 000FDE ?_midi_set_channel 002B
+ _PORTAbits 000F80 _PORTDbits 000F83 ??_midi_set_channel 002F
__CFG_FOSC$INTIO7 000000 _TRISCbits 000F94 _TRISDbits 000F95
- midi_set_channel@channel 001C __pidataCOMRAM 0424 __end_of_memset 03B2
- start_initialization 0354 __end_of_isr 01B8 __size_of_midi_note_on 0078
- __size_of_midi_set_status 0024 __size_of_eusart1_init 001C ??_memset 0020
- _midi_note_on 01BC __pbssCOMRAM 0025 __pcstackBANK0 0060
- midi_set_status@pkt 001A _eusart1_init 03FC __pintcode 0008
- __CFG_PRICLKEN$ON 000000 main@sample_message 0062 ?_init_hw 0001
- __size_of_putch 000C _PIE1bits 000F9D _PIR1bits 000F9E
- __CFG_WDTPS$32768 000000 ??_midi_set_status 001D __size_of_midi_set_channel 0026
- eusart_write_midi@data 0021 __Hrparam 0000 __Lrparam 0000
- __CFG_BOREN$SBORDIS 000000 __CFG_P2BMX$PORTD2 000000 __size_of_init_hw 0060
- _midi_base_scale 0043 __size_of_main 004C int$flags 0045
- _OSCTUNEbits 000F9B _INTCONbits 000FF2 memset@p1 001A
- midi_set_channel@pkt 001A intlevel2 0000 _RCSTA1bits 000FAB
- _OSCCONbits 000FD3 __CFG_T3CMX$PORTC0 000000 _midi_set_channel 03B2
- _midi_set_status 03D8
+ ??_eusart2_putch 002B midi_set_channel@channel 002D __end_of_memset 059A
+ start_initialization 061C __end_of_isr 0352 __size_of_midi_note_on 0066
+ __size_of_midi_set_status 0024 __size_of_eusart1_init 001C __size_of_eusart2_init 001C
+ ??_memset 0031 _midi_note_on 04A6 __pcstackBANK0 00A2
+ midi_set_status@pkt 002B _eusart1_init 0600 _eusart2_init 05E4
+ __pintcode 0008 __CFG_PRICLKEN$ON 000000 ?_init_hw 0001
+ _keys_data 0062 _PIE1bits 000F9D _PIR1bits 000F9E
+ __CFG_WDTPS$32768 000000 ??_midi_set_status 002E __size_of_midi_set_channel 0026
+ eusart_write_midi@data 0032 isr@data_a 0025 isr@data_b 0026
+ __Hrparam 0000 __Lrparam 0000 __CFG_BOREN$SBORDIS 000000
+ __CFG_P2BMX$PORTD2 000000 eusart2_putch@c 002B __size_of_init_hw 0062
+ __end_of_eusart2_putch 0642 __size_of_main 00DC int$flags 0034
+ _OSCTUNEbits 000F9B _INTCONbits 000FF2 memset@p1 002B
+ midi_set_channel@pkt 002B intlevel2 0000 _RCSTA1bits 000FAB
+ _RCSTA2bits 000F71 _OSCCONbits 000FD3 __CFG_T3CMX$PORTC0 000000
+ _midi_set_channel 059A _midi_set_status 05C0
diff --git a/src/dist/default/production/src.production.map b/src/dist/default/production/src.production.map
index f4c46fc..8af54a4 100644
--- a/src/dist/default/production/src.production.map
+++ b/src/dist/default/production/src.production.map
@@ -5,9 +5,9 @@ Linker command line:
-W-3 --edf=C:\Program Files\Microchip\xc8\v1.44\dat\en_msgs.txt -cs \
-h+dist/default/production\src.production.sym \
--cmf=dist/default/production\src.production.cmf -z -Q18F45K22 \
- -oC:\Users\_prossn\AppData\Local\Temp\s5hg.2 \
+ -oC:\Users\_prossn\AppData\Local\Temp\s514.2 \
-Mdist/default/production/src.production.map -E1 -ver=XC8 \
- -ASTACK=069h-05ffh -pstack=STACK -ACODE=00h-07FFFh -ACONST=00h-07FFFh \
+ -ASTACK=0B6h-05ffh -pstack=STACK -ACODE=00h-07FFFh -ACONST=00h-07FFFh \
-ASMALLCONST=0600h-06FFhx122 -AMEDIUMCONST=0600h-07FFFh -ACOMRAM=01h-05Fh \
-AABS1=00h-05FFh -ABIGRAM=01h-05FFh -ARAM=060h-0FFh,0100h-01FFhx5 \
-ABANK0=060h-0FFh -ABANK1=0100h-01FFh -ABANK2=0200h-02FFh \
@@ -22,7 +22,7 @@ Linker command line:
-pfarbss=FARRAM,fardata=FARRAM,nvFARRAM=FARRAM \
-pintsave_regs=BIGRAM,bigbss=BIGRAM,bigdata=BIGRAM -pbss=RAM \
-pidata=CODE,irdata=CODE,ibigdata=CODE,ifardata=CODE -prparam=COMRAM \
- C:\Users\_prossn\AppData\Local\Temp\s5hg.obj \
+ C:\Users\_prossn\AppData\Local\Temp\s514.obj \
dist/default/production\src.production.obj
Object code version is 3.11
@@ -35,48 +35,47 @@ Call graph: (short form)
Name Link Load Length Selector Space Scale
-C:\Users\_prossn\AppData\Local\Temp\s5hg.obj
- init 1B8 1B8 4 4 0
+C:\Users\_prossn\AppData\Local\Temp\s514.obj
+ init 352 352 4 4 0
reset_vec 0 0 4 0 0
idloc 200000 200000 8 200000 0
config 300000 300000 E 300000 0
dist/default/production\src.production.obj
- intcode 8 8 1B0 4 0
- temp 45 45 1 1 1
- text8 418 418 C 4 0
- text7 234 234 74 4 0
- text6 3FC 3FC 1C 4 0
- text5 2A8 2A8 60 4 0
- text4 386 386 2C 4 0
- text3 3B2 3B2 26 4 0
- text2 3D8 3D8 24 4 0
- text1 1BC 1BC 78 4 0
- text0 308 308 4C 4 0
- cstackCOMRAM 1 1 24 1 1
- cstackBANK0 60 60 9 60 1
- dataCOMRAM 43 43 2 1 1
- bssCOMRAM 25 25 1E 1 1
- cinit 354 354 32 4 0
- idataCOMRAM 424 424 2 4 0
+ intcode 8 8 34A 4 0
+ temp 34 34 1 1 1
+ text9 636 636 C 4 0
+ text8 432 432 74 4 0
+ text7 600 600 1C 4 0
+ text6 5E4 5E4 1C 4 0
+ text5 50C 50C 62 4 0
+ text4 56E 56E 2C 4 0
+ text3 59A 59A 26 4 0
+ text2 5C0 5C0 24 4 0
+ text1 4A6 4A6 66 4 0
+ text0 356 356 DC 4 0
+ cstackCOMRAM 1 1 33 1 1
+ cstackBANK0 A2 A2 14 60 1
+ bssBANK0 60 60 42 60 1
+ cinit 61C 61C 1A 4 0
TOTAL Name Link Load Length Space
CLASS STACK
CLASS CODE
- intcode 8 8 1B0 0
- init 1B8 1B8 4 0
+ intcode 8 8 34A 0
+ init 352 352 4 0
reset_vec 0 0 4 0
- text8 418 418 C 0
- text7 234 234 74 0
- text6 3FC 3FC 1C 0
- text5 2A8 2A8 60 0
- text4 386 386 2C 0
- text3 3B2 3B2 26 0
- text2 3D8 3D8 24 0
- text1 1BC 1BC 78 0
- text0 308 308 4C 0
- cinit 354 354 32 0
- idataCOMRAM 424 424 2 0
+ text9 636 636 C 0
+ text8 432 432 74 0
+ text7 600 600 1C 0
+ text6 5E4 5E4 1C 0
+ text5 50C 50C 62 0
+ text4 56E 56E 2C 0
+ text3 59A 59A 26 0
+ text2 5C0 5C0 24 0
+ text1 4A6 4A6 66 0
+ text0 356 356 DC 0
+ cinit 61C 61C 1A 0
CLASS CONST
@@ -85,10 +84,8 @@ TOTAL Name Link Load Length Sp
CLASS MEDIUMCONST
CLASS COMRAM
- temp 45 45 1 1
- cstackCOMRAM 1 1 24 1
- dataCOMRAM 43 43 2 1
- bssCOMRAM 25 25 1E 1
+ temp 34 34 1 1
+ cstackCOMRAM 1 1 33 1
CLASS ABS1
@@ -97,7 +94,8 @@ TOTAL Name Link Load Length Sp
CLASS RAM
CLASS BANK0
- cstackBANK0 60 60 9 1
+ cstackBANK0 A2 A2 14 1
+ bssBANK0 60 60 42 1
CLASS BANK1
@@ -126,9 +124,9 @@ TOTAL Name Link Load Length Sp
SEGMENTS Name Load Length Top Selector Space Class
reset_vec 000000 000004 000004 0 0 CODE
- cstackCOMRAM 000001 000045 000046 1 1 COMRAM
- intcode 000008 00041E 000426 4 0 CODE
- cstackBANK0 000060 000009 000069 60 1 BANK0
+ cstackCOMRAM 000001 000034 000035 1 1 COMRAM
+ intcode 000008 00063A 000642 4 0 CODE
+ bssBANK0 000060 000056 0000B6 60 1 BANK0
idloc 200000 000008 200008 200000 0 IDLOC
config 300000 00000E 30000E 300000 0 CONFIG
@@ -136,25 +134,25 @@ SEGMENTS Name Load Length Top Selector
UNUSED ADDRESS RANGES
Name Unused Largest block Delta
- BANK0 000069-0000FF 97
+ BANK0 0000B6-0000FF 4A
BANK1 000100-0001FF 100
BANK2 000200-0002FF 100
BANK3 000300-0003FF 100
BANK4 000400-0004FF 100
BANK5 000500-0005FF 100
- BIGRAM 000046-00005F 1A
- 000069-0005FF 597
+ BIGRAM 000035-00005F 2B
+ 0000B6-0005FF 54A
CODE 000004-000007 4
- 000426-007FFF 7BDA
- COMRAM 000046-00005F 1A
+ 000642-007FFF 79BE
+ COMRAM 000035-00005F 2B
CONST 000004-000007 4
- 000426-007FFF 7BDA
+ 000642-007FFF 79BE
EEDATA F00000-F000FF 100
- MEDIUMCONST 000600-007FFF 7A00
- RAM 000069-0005FF 100
+ MEDIUMCONST 000642-007FFF 79BE
+ RAM 0000B6-0005FF 100
SFR 000F38-000FFF 28
- SMALLCONST 000600-007FFF 100
- STACK 000069-0005FF 597
+ SMALLCONST 000642-007FFF 100
+ STACK 0000B6-0005FF 54A
Symbol Table
@@ -163,6 +161,7 @@ _ANSELB (abs) 000F39
_ANSELC (abs) 000F3A
_ANSELD (abs) 000F3B
_BAUDCON1bits (abs) 000FB8
+_BAUDCON2bits (abs) 000F70
_INTCONbits (abs) 000FF2
_OSCCONbits (abs) 000FD3
_OSCTUNEbits (abs) 000F9B
@@ -176,8 +175,11 @@ _PR2 (abs) 000FBB
_RC1IF (abs) 007CF5
_RC1REG (abs) 000FAE
_RCSTA1bits (abs) 000FAB
+_RCSTA2bits (abs) 000F71
_SPBRG1 (abs) 000FAF
+_SPBRG2 (abs) 000F75
_SPBRGH1 (abs) 000FB0
+_SPBRGH2 (abs) 000F76
_T2CONbits (abs) 000FBA
_TRISA (abs) 000F92
_TRISB (abs) 000F93
@@ -185,7 +187,10 @@ _TRISCbits (abs) 000F94
_TRISDbits (abs) 000F95
_TX1IF (abs) 007CF4
_TX1REG (abs) 000FAD
+_TX2IF (abs) 007D24
+_TX2REG (abs) 000F73
_TXSTA1bits (abs) 000FAC
+_TXSTA2bits (abs) 000F72
__CFG_BOREN$SBORDIS (abs) 000000
__CFG_BORV$190 (abs) 000000
__CFG_CCP2MX$PORTC1 (abs) 000000
@@ -236,7 +241,7 @@ __Hbigbss bigbss 000000
__Hbigdata bigdata 000000
__Hbigram bigram 000000
__Hbss bss 000000
-__HbssCOMRAM bssCOMRAM 000000
+__HbssBANK0 bssBANK0 000000
__Hcinit cinit 000000
__Hclrtext clrtext 000000
__Hcomram comram 000000
@@ -245,19 +250,17 @@ __Hconst const 000000
__HcstackBANK0 cstackBANK0 000000
__HcstackCOMRAM cstackCOMRAM 000000
__Hdata data 000000
-__HdataCOMRAM dataCOMRAM 000000
__Heeprom_data eeprom_data 000000
__Hfarbss farbss 000000
__Hfardata fardata 000000
__Hibigdata ibigdata 000000
__Hidata idata 000000
-__HidataCOMRAM idataCOMRAM 000000
__Hidloc idloc 200008
__Hifardata ifardata 000000
-__Hinit init 0001BC
-__Hintcode intcode 0001B8
+__Hinit init 000356
+__Hintcode intcode 000352
__Hintcode_body intcode_body 000000
-__Hintcodelo intcodelo 0001B8
+__Hintcodelo intcodelo 000352
__Hintentry intentry 000000
__Hintret intret 000000
__Hintsave_regs intsave_regs 000000
@@ -267,7 +270,7 @@ __HnvFARRAM nvFARRAM 000000
__Hnvbit nvbit 000000
__Hnvrram nvrram 000000
__Hparam rparam 000000
-__Hpowerup powerup 0001B8
+__Hpowerup powerup 000352
__Hram ram 000000
__Hramtop ramtop 000600
__Hrbit rbit 000000
@@ -278,11 +281,11 @@ __Hrparam rparam 000000
__Hsfr sfr 000000
__Hsmallconst smallconst 000000
__Hspace_0 (abs) 30000E
-__Hspace_1 (abs) 000069
+__Hspace_1 (abs) 0000B6
__Hspace_2 (abs) 000000
__Hstack stack 000000
__Hstruct struct 000000
-__Htemp temp 000046
+__Htemp temp 000035
__Htext text 000000
__Htext0 text0 000000
__Htext1 text1 000000
@@ -293,6 +296,7 @@ __Htext5 text5 000000
__Htext6 text6 000000
__Htext7 text7 000000
__Htext8 text8 000000
+__Htext9 text9 000000
__LRAM (abs) 000001
__Labs1 abs1 000000
__Lbank0 bank0 000000
@@ -305,7 +309,7 @@ __Lbigbss bigbss 000000
__Lbigdata bigdata 000000
__Lbigram bigram 000000
__Lbss bss 000000
-__LbssCOMRAM bssCOMRAM 000000
+__LbssBANK0 bssBANK0 000000
__Lcinit cinit 000000
__Lclrtext clrtext 000000
__Lcomram comram 000000
@@ -314,19 +318,17 @@ __Lconst const 000000
__LcstackBANK0 cstackBANK0 000000
__LcstackCOMRAM cstackCOMRAM 000000
__Ldata data 000000
-__LdataCOMRAM dataCOMRAM 000000
__Leeprom_data eeprom_data 000000
__Lfarbss farbss 000000
__Lfardata fardata 000000
__Libigdata ibigdata 000000
__Lidata idata 000000
-__LidataCOMRAM idataCOMRAM 000000
__Lidloc idloc 200000
__Lifardata ifardata 000000
-__Linit init 0001B8
+__Linit init 000352
__Lintcode intcode 000008
__Lintcode_body intcode_body 000000
-__Lintcodelo intcodelo 0001B8
+__Lintcodelo intcodelo 000352
__Lintentry intentry 000000
__Lintret intret 000000
__Lintsave_regs intsave_regs 000000
@@ -336,7 +338,7 @@ __LnvFARRAM nvFARRAM 000000
__Lnvbit nvbit 000000
__Lnvrram nvrram 000000
__Lparam rparam 000000
-__Lpowerup powerup 0001B8
+__Lpowerup powerup 000352
__Lram ram 000000
__Lramtop ramtop 000600
__Lrbit rbit 000000
@@ -351,7 +353,7 @@ __Lspace_1 (abs) 000000
__Lspace_2 (abs) 000000
__Lstack stack 000000
__Lstruct struct 000000
-__Ltemp temp 000045
+__Ltemp temp 000034
__Ltext text 000000
__Ltext0 text0 000000
__Ltext1 text1 000000
@@ -362,8 +364,9 @@ __Ltext5 text5 000000
__Ltext6 text6 000000
__Ltext7 text7 000000
__Ltext8 text8 000000
+__Ltext9 text9 000000
__S0 (abs) 30000E
-__S1 (abs) 000069
+__S1 (abs) 0000B6
__S2 (abs) 000000
___inthi_sp stack 000000
___intlo_sp stack 000000
@@ -372,37 +375,39 @@ ___rparam_used (abs) 000001
___sp stack 000000
__accesstop (abs) 000060
__activetblptr (abs) 000002
-__end_of__initialization cinit 000378
-__end_of_eusart1_init text6 000418
-__end_of_eusart_write_midi text7 0002A8
-__end_of_init_hw text5 000308
-__end_of_isr intcode 0001B8
-__end_of_main text0 000354
-__end_of_memset text4 0003B2
-__end_of_midi_note_on text1 000234
-__end_of_midi_set_channel text3 0003D8
-__end_of_midi_set_status text2 0003FC
-__end_of_putch text8 000424
-__initialization cinit 000354
+__end_of__initialization cinit 000628
+__end_of_eusart1_init text7 00061C
+__end_of_eusart2_init text6 000600
+__end_of_eusart2_putch text9 000642
+__end_of_eusart_write_midi text8 0004A6
+__end_of_init_hw text5 00056E
+__end_of_isr intcode 000352
+__end_of_main text0 000432
+__end_of_memset text4 00059A
+__end_of_midi_note_on text1 00050C
+__end_of_midi_set_channel text3 0005C0
+__end_of_midi_set_status text2 0005E4
+__initialization cinit 00061C
__mediumconst mediumconst 000000
-__pbssCOMRAM bssCOMRAM 000025
-__pcinit cinit 000354
-__pcstackBANK0 cstackBANK0 000060
+__pbssBANK0 bssBANK0 000060
+__pcinit cinit 00061C
+__pcstackBANK0 cstackBANK0 0000A2
__pcstackCOMRAM cstackCOMRAM 000001
-__pdataCOMRAM dataCOMRAM 000043
-__pidataCOMRAM idataCOMRAM 000424
__pintcode intcode 000008
-__ptext0 text0 000308
-__ptext1 text1 0001BC
-__ptext2 text2 0003D8
-__ptext3 text3 0003B2
-__ptext4 text4 000386
-__ptext5 text5 0002A8
-__ptext6 text6 0003FC
-__ptext7 text7 000234
-__ptext8 text8 000418
+__ptext0 text0 000356
+__ptext1 text1 0004A6
+__ptext2 text2 0005C0
+__ptext3 text3 00059A
+__ptext4 text4 00056E
+__ptext5 text5 00050C
+__ptext6 text6 0005E4
+__ptext7 text7 000600
+__ptext8 text8 000432
+__ptext9 text9 000636
__ramtop ramtop 000600
__size_of_eusart1_init (abs) 000000
+__size_of_eusart2_init (abs) 000000
+__size_of_eusart2_putch (abs) 000000
__size_of_eusart_write_midi (abs) 000000
__size_of_init_hw (abs) 000000
__size_of_isr (abs) 000000
@@ -411,65 +416,68 @@ __size_of_memset (abs) 000000
__size_of_midi_note_on (abs) 000000
__size_of_midi_set_channel (abs) 000000
__size_of_midi_set_status (abs) 000000
-__size_of_putch (abs) 000000
__smallconst smallconst 000000
-_eusart1_init text6 0003FC
-_eusart_write_midi text7 000234
-_init_hw text5 0002A8
+_eusart1_init text7 000600
+_eusart2_init text6 0005E4
+_eusart2_putch text9 000636
+_eusart_write_midi text8 000432
+_init_hw text5 00050C
_isr intcode 000008
-_isr$592 cstackCOMRAM 000017
-_keypresses bssCOMRAM 000025
-_main text0 000308
-_memset text4 000386
-_midi_base_scale dataCOMRAM 000043
-_midi_note_on text1 0001BC
-_midi_set_channel text3 0003B2
-_midi_set_status text2 0003D8
-_putch text8 000418
-btemp temp 000045
-end_of_initialization cinit 000378
-eusart_write_midi@data cstackCOMRAM 000021
-eusart_write_midi@length cstackCOMRAM 00001F
-eusart_write_midi@pkt cstackCOMRAM 00001B
-int$flags temp 000045
+_isr$595 cstackCOMRAM 000027
+_isr$596 cstackCOMRAM 000028
+_isr$605 cstackCOMRAM 000029
+_keypresses bssBANK0 000060
+_keys_data bssBANK0 000062
+_main text0 000356
+_memset text4 00056E
+_midi_note_on text1 0004A6
+_midi_set_channel text3 00059A
+_midi_set_status text2 0005C0
+btemp temp 000034
+end_of_initialization cinit 000628
+eusart2_putch@c cstackCOMRAM 00002B
+eusart_write_midi@data cstackCOMRAM 000032
+eusart_write_midi@length cstackCOMRAM 000030
+eusart_write_midi@pkt cstackCOMRAM 00002C
+int$flags temp 000034
intlevel0 text 000000
intlevel1 text 000000
intlevel2 text 000000
intlevel3 text 000000
-isr@data cstackCOMRAM 000018
-isr@i cstackCOMRAM 000019
-main@sample_message cstackBANK0 000062
-memset@c cstackCOMRAM 00001C
-memset@n cstackCOMRAM 00001E
-memset@p cstackCOMRAM 000020
-memset@p1 cstackCOMRAM 00001A
-midi_note_on@channel cstackCOMRAM 000021
-midi_note_on@note cstackCOMRAM 000023
-midi_note_on@pkt cstackCOMRAM 00001F
-midi_note_on@velocity cstackCOMRAM 000024
-midi_set_channel@channel cstackCOMRAM 00001C
-midi_set_channel@pkt cstackCOMRAM 00001A
-midi_set_status@pkt cstackCOMRAM 00001A
-midi_set_status@status cstackCOMRAM 00001C
-putch@c cstackCOMRAM 00001A
+isr@data_a cstackCOMRAM 000025
+isr@data_b cstackCOMRAM 000026
+isr@i cstackCOMRAM 00002A
+main@i cstackBANK0 0000AD
+main@message cstackBANK0 0000AF
+memset@c cstackCOMRAM 00002D
+memset@n cstackCOMRAM 00002F
+memset@p cstackCOMRAM 000031
+memset@p1 cstackCOMRAM 00002B
+midi_note_on@channel cstackBANK0 0000A4
+midi_note_on@note cstackBANK0 0000A6
+midi_note_on@pkt cstackBANK0 0000A2
+midi_note_on@velocity cstackBANK0 0000A7
+midi_set_channel@channel cstackCOMRAM 00002D
+midi_set_channel@pkt cstackCOMRAM 00002B
+midi_set_status@pkt cstackCOMRAM 00002B
+midi_set_status@status cstackCOMRAM 00002D
stackhi (abs) 0005FF
-stacklo (abs) 000069
-start init 0001B8
-start_initialization cinit 000354
-wtemp6 temp 000046
+stacklo (abs) 0000B6
+start init 000352
+start_initialization cinit 00061C
+wtemp6 temp 000035
FUNCTION INFORMATION:
*************** function _main *****************
Defined at:
- line 204 in file "main.c"
+ line 215 in file "main.c"
Parameters: Size Location Type
None
Auto vars: Size Location Type
- sample_messa 7 2[BANK0 ] struct .
- data 1 0 unsigned char
- i 1 0 unsigned char
+ message 7 13[BANK0 ] struct .
+ i 2 11[BANK0 ] unsigned int
Return value: Size Location Type
1 wreg void
Registers used:
@@ -480,10 +488,10 @@ FUNCTION INFORMATION:
Unchanged:
Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
Params: 0 0 0 0 0 0 0
- Locals: 0 7 0 0 0 0 0
- Temps: 0 0 0 0 0 0 0
- Totals: 0 7 0 0 0 0 0
-Total ram usage: 7 bytes
+ Locals: 0 9 0 0 0 0 0
+ Temps: 0 5 0 0 0 0 0
+ Totals: 0 14 0 0 0 0 0
+Total ram usage: 14 bytes
Hardware stack levels required when called: 3
This function calls:
_eusart_write_midi
@@ -499,15 +507,15 @@ Total ram usage: 7 bytes
Defined at:
line 62 in file "midi.c"
Parameters: Size Location Type
- pkt 2 30[COMRAM] PTR struct .
- -> main@sample_message(7),
- channel 2 32[COMRAM] unsigned int
- note 1 34[COMRAM] enum E31
- velocity 1 35[COMRAM] unsigned char
+ pkt 2 0[BANK0 ] PTR struct .
+ -> main@message(7),
+ channel 2 2[BANK0 ] unsigned int
+ note 1 4[BANK0 ] enum E31
+ velocity 1 5[BANK0 ] unsigned char
Auto vars: Size Location Type
None
Return value: Size Location Type
- 2 30[COMRAM] int
+ 2 0[BANK0 ] int
Registers used:
wreg, fsr2l, fsr2h, status,2, status,0, cstack
Tracked objects:
@@ -515,11 +523,11 @@ Total ram usage: 7 bytes
On exit :
Unchanged:
Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
- Params: 6 0 0 0 0 0 0
+ Params: 0 6 0 0 0 0 0
Locals: 0 0 0 0 0 0 0
- Temps: 0 2 0 0 0 0 0
- Totals: 6 2 0 0 0 0 0
-Total ram usage: 8 bytes
+ Temps: 0 0 0 0 0 0 0
+ Totals: 0 6 0 0 0 0 0
+Total ram usage: 6 bytes
Hardware stack levels used: 1
Hardware stack levels required when called: 2
This function calls:
@@ -534,13 +542,13 @@ Total ram usage: 8 bytes
Defined at:
line 40 in file "midi.c"
Parameters: Size Location Type
- pkt 2 25[COMRAM] PTR struct .
- -> main@sample_message(7),
- status 1 27[COMRAM] enum E40
+ pkt 2 42[COMRAM] PTR struct .
+ -> main@message(7),
+ status 1 44[COMRAM] enum E40
Auto vars: Size Location Type
None
Return value: Size Location Type
- 2 25[COMRAM] int
+ 2 42[COMRAM] int
Registers used:
wreg, fsr2l, fsr2h, status,2, status,0
Tracked objects:
@@ -567,13 +575,13 @@ Total ram usage: 4 bytes
Defined at:
line 51 in file "midi.c"
Parameters: Size Location Type
- pkt 2 25[COMRAM] PTR struct .
- -> main@sample_message(7),
- channel 2 27[COMRAM] unsigned int
+ pkt 2 42[COMRAM] PTR struct .
+ -> main@message(7),
+ channel 2 44[COMRAM] unsigned int
Auto vars: Size Location Type
None
Return value: Size Location Type
- 2 25[COMRAM] int
+ 2 42[COMRAM] int
Registers used:
wreg, fsr2l, fsr2h, status,2, status,0
Tracked objects:
@@ -600,15 +608,15 @@ Total ram usage: 5 bytes
Defined at:
line 8 in file "C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c"
Parameters: Size Location Type
- p1 2 25[COMRAM] PTR void
- -> keypresses(30),
- c 2 27[COMRAM] int
- n 2 29[COMRAM] unsigned int
+ p1 2 42[COMRAM] PTR void
+ -> keys_data(64),
+ c 2 44[COMRAM] int
+ n 2 46[COMRAM] unsigned int
Auto vars: Size Location Type
- p 2 31[COMRAM] PTR unsigned char
- -> keypresses(30),
+ p 2 48[COMRAM] PTR unsigned char
+ -> keys_data(64),
Return value: Size Location Type
- 2 25[COMRAM] PTR void
+ 2 42[COMRAM] PTR void
Registers used:
wreg, fsr2l, fsr2h, status,2, status,0
Tracked objects:
@@ -632,7 +640,7 @@ Total ram usage: 8 bytes
*************** function _init_hw *****************
Defined at:
- line 140 in file "main.c"
+ line 150 in file "main.c"
Parameters: Size Location Type
None
Auto vars: Size Location Type
@@ -655,11 +663,42 @@ Total ram usage: 0 bytes
Hardware stack levels required when called: 2
This function calls:
_eusart1_init
+ _eusart2_init
This function is called by:
_main
This function uses a non-reentrant model
+ *************** function _eusart2_init *****************
+ Defined at:
+ line 25 in file "rs232.c"
+ Parameters: Size Location Type
+ None
+ Auto vars: Size Location Type
+ None
+ Return value: Size Location Type
+ 1 wreg void
+ Registers used:
+ wreg, status,2
+ Tracked objects:
+ On entry :
+ On exit :
+ Unchanged:
+ Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
+ Params: 0 0 0 0 0 0 0
+ Locals: 0 0 0 0 0 0 0
+ Temps: 0 0 0 0 0 0 0
+ Totals: 0 0 0 0 0 0 0
+Total ram usage: 0 bytes
+ Hardware stack levels used: 1
+ Hardware stack levels required when called: 1
+ This function calls:
+ Nothing
+ This function is called by:
+ _init_hw
+ This function uses a non-reentrant model
+
+
*************** function _eusart1_init *****************
Defined at:
line 4 in file "rs232.c"
@@ -692,16 +731,16 @@ Total ram usage: 0 bytes
*************** function _eusart_write_midi *****************
Defined at:
- line 226 in file "main.c"
+ line 261 in file "main.c"
Parameters: Size Location Type
- pkt 2 26[COMRAM] PTR const struct .
- -> main@sample_message(7),
+ pkt 2 43[COMRAM] PTR const struct .
+ -> main@message(7),
Auto vars: Size Location Type
- data 2 32[COMRAM] PTR unsigned char
- -> sample_message.data(4), main@sample_message(7),
- length 2 30[COMRAM] unsigned int
+ data 2 49[COMRAM] PTR unsigned char
+ -> message.data(4), main@message(7),
+ length 2 47[COMRAM] unsigned int
Return value: Size Location Type
- 2 26[COMRAM] int
+ 2 43[COMRAM] int
Registers used:
wreg, fsr2l, fsr2h, status,2, status,0, cstack
Tracked objects:
@@ -717,19 +756,19 @@ Total ram usage: 8 bytes
Hardware stack levels used: 1
Hardware stack levels required when called: 2
This function calls:
- _putch
+ _eusart2_putch
This function is called by:
_main
This function uses a non-reentrant model
- *************** function _putch *****************
+ *************** function _eusart2_putch *****************
Defined at:
- line 29 in file "rs232.c"
+ line 52 in file "rs232.c"
Parameters: Size Location Type
c 1 wreg unsigned char
Auto vars: Size Location Type
- c 1 25[COMRAM] unsigned char
+ c 1 42[COMRAM] unsigned char
Return value: Size Location Type
1 wreg void
Registers used:
@@ -750,18 +789,18 @@ Total ram usage: 1 bytes
Nothing
This function is called by:
_eusart_write_midi
- _getche
This function uses a non-reentrant model
*************** function _isr *****************
Defined at:
- line 101 in file "main.c"
+ line 113 in file "main.c"
Parameters: Size Location Type
None
Auto vars: Size Location Type
- i 1 24[COMRAM] unsigned char
- data 1 23[COMRAM] unsigned char
+ i 1 41[COMRAM] unsigned char
+ data_b 1 37[COMRAM] unsigned char
+ data_a 1 36[COMRAM] unsigned char
Return value: Size Location Type
1 wreg void
Registers used:
@@ -772,10 +811,10 @@ Total ram usage: 1 bytes
Unchanged:
Data sizes: COMRAM BANK0 BANK1 BANK2 BANK3 BANK4 BANK5
Params: 0 0 0 0 0 0 0
- Locals: 3 0 0 0 0 0 0
- Temps: 22 0 0 0 0 0 0
- Totals: 25 0 0 0 0 0 0
-Total ram usage: 25 bytes
+ Locals: 6 0 0 0 0 0 0
+ Temps: 36 0 0 0 0 0 0
+ Totals: 42 0 0 0 0 0 0
+Total ram usage: 42 bytes
Hardware stack levels used: 1
This function calls:
Nothing
@@ -789,33 +828,34 @@ MODULE INFORMATION
Module Function Class Link Load Size
rs232.c
- _putch CODE 0418 0000 13
- _eusart1_init CODE 03FC 0000 29
+ _eusart2_putch CODE 0636 0000 13
+ _eusart1_init CODE 0600 0000 29
+ _eusart2_init CODE 05E4 0000 29
-rs232.c estimated size: 42
+rs232.c estimated size: 71
shared
- __initialization CODE 0354 0000 37
+ __initialization CODE 061C 0000 13
-shared estimated size: 37
+shared estimated size: 13
midi.c
- _midi_set_channel CODE 03B2 0000 39
- _midi_note_on CODE 01BC 0000 121
- _midi_set_status CODE 03D8 0000 37
+ _midi_set_channel CODE 059A 0000 39
+ _midi_note_on CODE 04A6 0000 103
+ _midi_set_status CODE 05C0 0000 37
-midi.c estimated size: 197
+midi.c estimated size: 179
C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
- _memset CODE 0386 0000 45
+ _memset CODE 056E 0000 45
C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c estimated size: 45
main.c
- _init_hw CODE 02A8 0000 97
- _eusart_write_midi CODE 0234 0000 117
- _main CODE 0308 0000 77
- _isr CODE 0008 0000 433
+ _init_hw CODE 050C 0000 99
+ _eusart_write_midi CODE 0432 0000 117
+ _main CODE 0356 0000 221
+ _isr CODE 0008 0000 843
-main.c estimated size: 724
+main.c estimated size: 1280
diff --git a/src/dist/default/production/src.production.mum b/src/dist/default/production/src.production.mum
index c14afe5..0b9440e 100644
--- a/src/dist/default/production/src.production.mum
+++ b/src/dist/default/production/src.production.mum
@@ -1,9 +1,9 @@
Memory Summary:
- Program space used 422h ( 1058) of 7A00h bytes ( 3.4%)
- Data space used 4Eh ( 78) of 5FFh bytes ( 5.1%)
+ Program space used 63Eh ( 1598) of 7A00h bytes ( 5.1%)
+ Data space used 8Ah ( 138) of 5FFh bytes ( 9.0%)
Configuration bits used 7h ( 7) of 7h words (100.0%)
EEPROM space used 0h ( 0) of 100h bytes ( 0.0%)
ID Location space used 8h ( 8) of 8h bytes (100.0%)
- Data stack space used 0h ( 0) of 597h bytes ( 0.0%)
+ Data stack space used 0h ( 0) of 54Ah bytes ( 0.0%)
diff --git a/src/dist/default/production/src.production.obj b/src/dist/default/production/src.production.obj
index 2f7bc81..7306705 100644
--- a/src/dist/default/production/src.production.obj
+++ b/src/dist/default/production/src.production.obj
Binary files differ
diff --git a/src/dist/default/production/src.production.rlf b/src/dist/default/production/src.production.rlf
index 2d46de5..b5a0911 100644
--- a/src/dist/default/production/src.production.rlf
+++ b/src/dist/default/production/src.production.rlf
Binary files differ
diff --git a/src/dist/default/production/src.production.sdb b/src/dist/default/production/src.production.sdb
index f9bbdf0..c0c1673 100644
--- a/src/dist/default/production/src.production.sdb
+++ b/src/dist/default/production/src.production.sdb
@@ -3,8 +3,8 @@
[d edition pro ]
[d chip 18F45K22 ]
[d frameptr 4065 ]
-"216 Z:\SAMB_4\projects\xilofono\src\main.c
-[e E41 . `uc
+"232 Z:\SAMB_4\projects\xilofono\src\main.c
+[e E43 . `uc
C 0
D 1
E 2
@@ -55,13 +55,13 @@ B 6
[v ___flmul __flmul `(d 1 e 3 0 ]
"15 C:\Program Files\Microchip\xc8\v1.44\sources\common\Umul32.c
[v ___lmul __lmul `(ul 1 e 4 0 ]
-"101 Z:\SAMB_4\projects\xilofono\src\main.c
+"113 Z:\SAMB_4\projects\xilofono\src\main.c
[v _isr isr `II(v 1 e 1 0 ]
-"140
+"150
[v _init_hw init_hw `T(v 1 e 1 0 ]
-"204
+"215
[v _main main `(v 1 e 1 0 ]
-"226
+"261
[v _eusart_write_midi eusart_write_midi `(i 1 e 2 0 ]
"40 Z:\SAMB_4\projects\xilofono\src\midi.c
[v _midi_set_status midi_set_status `(i 1 e 2 0 ]
@@ -71,10 +71,14 @@ B 6
[v _midi_note_on midi_note_on `(i 1 e 2 0 ]
"4 Z:\SAMB_4\projects\xilofono\src\rs232.c
[v _eusart1_init eusart1_init `(v 1 e 1 0 ]
-"29
-[v _putch putch `(v 1 e 1 0 ]
-"35
-[v _getch getch `(uc 1 e 1 0 ]
+"25
+[v _eusart2_init eusart2_init `(v 1 e 1 0 ]
+"46
+[v _eusart1_putch eusart1_putch `(v 1 e 1 0 ]
+"52
+[v _eusart2_putch eusart2_putch `(v 1 e 1 0 ]
+"58
+[v _eusart1_getch eusart1_getch `(uc 1 e 1 0 ]
"50 C:\Program Files\Microchip\xc8\v1.44\include\pic18f45k22.h
[v _ANSELA ANSELA `VEuc 1 e 1 @3896 ]
"95
@@ -83,6 +87,97 @@ B 6
[v _ANSELC ANSELC `VEuc 1 e 1 @3898 ]
"196
[v _ANSELD ANSELD `VEuc 1 e 1 @3899 ]
+[s S784 . 1 `uc 1 ABDEN 1 0 :1:0
+`uc 1 WUE 1 0 :1:1
+`uc 1 . 1 0 :1:2
+`uc 1 BRG16 1 0 :1:3
+`uc 1 CKTXP 1 0 :1:4
+`uc 1 DTRXP 1 0 :1:5
+`uc 1 RCIDL 1 0 :1:6
+`uc 1 ABDOVF 1 0 :1:7
+]
+"4328
+[s S793 . 1 `uc 1 . 1 0 :4:0
+`uc 1 SCKP 1 0 :1:4
+]
+[s S1033 . 1 `uc 1 ABDEN2 1 0 :1:0
+`uc 1 WUE2 1 0 :1:1
+`uc 1 . 1 0 :1:2
+`uc 1 BRG162 1 0 :1:3
+`uc 1 SCKP2 1 0 :1:4
+`uc 1 DTRXP2 1 0 :1:5
+`uc 1 RCIDL2 1 0 :1:6
+`uc 1 ABDOVF2 1 0 :1:7
+]
+[s S1042 . 1 `uc 1 . 1 0 :4:0
+`uc 1 TXCKP2 1 0 :1:4
+`uc 1 RXDTP2 1 0 :1:5
+`uc 1 RCMT2 1 0 :1:6
+]
+[u S1047 . 1 `S784 1 . 1 0 `S793 1 . 1 0 `S1033 1 . 1 0 `S1042 1 . 1 0 ]
+[v _BAUDCON2bits BAUDCON2bits `VES1047 1 e 1 @3952 ]
+[s S712 . 1 `uc 1 RX9D 1 0 :1:0
+`uc 1 OERR 1 0 :1:1
+`uc 1 FERR 1 0 :1:2
+`uc 1 ADDEN 1 0 :1:3
+`uc 1 CREN 1 0 :1:4
+`uc 1 SREN 1 0 :1:5
+`uc 1 RX9 1 0 :1:6
+`uc 1 SPEN 1 0 :1:7
+]
+"4593
+[s S721 . 1 `uc 1 . 1 0 :3:0
+`uc 1 ADEN 1 0 :1:3
+]
+[s S968 . 1 `uc 1 RX9D2 1 0 :1:0
+`uc 1 OERR2 1 0 :1:1
+`uc 1 FERR2 1 0 :1:2
+`uc 1 ADDEN2 1 0 :1:3
+`uc 1 CREN2 1 0 :1:4
+`uc 1 SREN2 1 0 :1:5
+`uc 1 RX92 1 0 :1:6
+`uc 1 SPEN2 1 0 :1:7
+]
+[s S977 . 1 `uc 1 RCD82 1 0 :1:0
+`uc 1 . 1 0 :5:1
+`uc 1 RC8_92 1 0 :1:6
+]
+[s S981 . 1 `uc 1 . 1 0 :6:0
+`uc 1 RC92 1 0 :1:6
+]
+[u S984 . 1 `S712 1 . 1 0 `S721 1 . 1 0 `S968 1 . 1 0 `S977 1 . 1 0 `S981 1 . 1 0 ]
+[v _RCSTA2bits RCSTA2bits `VES984 1 e 1 @3953 ]
+[s S663 . 1 `uc 1 TX9D 1 0 :1:0
+`uc 1 TRMT 1 0 :1:1
+`uc 1 BRGH 1 0 :1:2
+`uc 1 SENDB 1 0 :1:3
+`uc 1 SYNC 1 0 :1:4
+`uc 1 TXEN 1 0 :1:5
+`uc 1 TX9 1 0 :1:6
+`uc 1 CSRC 1 0 :1:7
+]
+"4873
+[s S916 . 1 `uc 1 TX9D2 1 0 :1:0
+`uc 1 TRMT2 1 0 :1:1
+`uc 1 BRGH2 1 0 :1:2
+`uc 1 SENDB2 1 0 :1:3
+`uc 1 SYNC2 1 0 :1:4
+`uc 1 TXEN2 1 0 :1:5
+`uc 1 TX92 1 0 :1:6
+`uc 1 CSRC2 1 0 :1:7
+]
+[s S925 . 1 `uc 1 TXD82 1 0 :1:0
+`uc 1 . 1 0 :5:1
+`uc 1 TX8_92 1 0 :1:6
+]
+[u S929 . 1 `S663 1 . 1 0 `S916 1 . 1 0 `S925 1 . 1 0 ]
+[v _TXSTA2bits TXSTA2bits `VES929 1 e 1 @3954 ]
+"5093
+[v _TX2REG TX2REG `VEuc 1 e 1 @3955 ]
+"5164
+[v _SPBRG2 SPBRG2 `VEuc 1 e 1 @3957 ]
+"5202
+[v _SPBRGH2 SPBRGH2 `VEuc 1 e 1 @3958 ]
"6278
[v _PORTA PORTA `VEuc 1 e 1 @3968 ]
[s S160 . 1 `uc 1 RA0 1 0 :1:0
@@ -211,7 +306,7 @@ B 6
[v _TRISA TRISA `VEuc 1 e 1 @3986 ]
"8280
[v _TRISB TRISB `VEuc 1 e 1 @3987 ]
-[s S855 . 1 `uc 1 TRISC0 1 0 :1:0
+[s S867 . 1 `uc 1 TRISC0 1 0 :1:0
`uc 1 TRISC1 1 0 :1:1
`uc 1 TRISC2 1 0 :1:2
`uc 1 TRISC3 1 0 :1:3
@@ -221,7 +316,7 @@ B 6
`uc 1 TRISC7 1 0 :1:7
]
"8534
-[s S864 . 1 `uc 1 RC0 1 0 :1:0
+[s S876 . 1 `uc 1 RC0 1 0 :1:0
`uc 1 RC1 1 0 :1:1
`uc 1 RC2 1 0 :1:2
`uc 1 RC3 1 0 :1:3
@@ -230,8 +325,8 @@ B 6
`uc 1 RC6 1 0 :1:6
`uc 1 RC7 1 0 :1:7
]
-[u S873 . 1 `S855 1 . 1 0 `S864 1 . 1 0 ]
-[v _TRISCbits TRISCbits `VES873 1 e 1 @3988 ]
+[u S885 . 1 `S867 1 . 1 0 `S876 1 . 1 0 ]
+[v _TRISCbits TRISCbits `VES885 1 e 1 @3988 ]
[s S418 . 1 `uc 1 TRISD0 1 0 :1:0
`uc 1 TRISD1 1 0 :1:1
`uc 1 TRISD2 1 0 :1:2
@@ -290,20 +385,8 @@ B 6
]
[u S141 . 1 `S128 1 . 1 0 `S136 1 . 1 0 ]
[v _PIR1bits PIR1bits `VES141 1 e 1 @3998 ]
-[s S700 . 1 `uc 1 RX9D 1 0 :1:0
-`uc 1 OERR 1 0 :1:1
-`uc 1 FERR 1 0 :1:2
-`uc 1 ADDEN 1 0 :1:3
-`uc 1 CREN 1 0 :1:4
-`uc 1 SREN 1 0 :1:5
-`uc 1 RX9 1 0 :1:6
-`uc 1 SPEN 1 0 :1:7
-]
"10396
-[s S709 . 1 `uc 1 . 1 0 :3:0
-`uc 1 ADEN 1 0 :1:3
-]
-[s S712 . 1 `uc 1 RX9D1 1 0 :1:0
+[s S724 . 1 `uc 1 RX9D1 1 0 :1:0
`uc 1 OERR1 1 0 :1:1
`uc 1 FERR1 1 0 :1:2
`uc 1 ADDEN1 1 0 :1:3
@@ -312,29 +395,20 @@ B 6
`uc 1 RX91 1 0 :1:6
`uc 1 SPEN1 1 0 :1:7
]
-[s S721 . 1 `uc 1 RCD8 1 0 :1:0
+[s S733 . 1 `uc 1 RCD8 1 0 :1:0
`uc 1 . 1 0 :5:1
`uc 1 RC8_9 1 0 :1:6
]
-[s S725 . 1 `uc 1 . 1 0 :6:0
+[s S737 . 1 `uc 1 . 1 0 :6:0
`uc 1 RC9 1 0 :1:6
]
-[s S728 . 1 `uc 1 . 1 0 :5:0
+[s S740 . 1 `uc 1 . 1 0 :5:0
`uc 1 SRENA 1 0 :1:5
]
-[u S731 . 1 `S700 1 . 1 0 `S709 1 . 1 0 `S712 1 . 1 0 `S721 1 . 1 0 `S725 1 . 1 0 `S728 1 . 1 0 ]
-[v _RCSTA1bits RCSTA1bits `VES731 1 e 1 @4011 ]
-[s S651 . 1 `uc 1 TX9D 1 0 :1:0
-`uc 1 TRMT 1 0 :1:1
-`uc 1 BRGH 1 0 :1:2
-`uc 1 SENDB 1 0 :1:3
-`uc 1 SYNC 1 0 :1:4
-`uc 1 TXEN 1 0 :1:5
-`uc 1 TX9 1 0 :1:6
-`uc 1 CSRC 1 0 :1:7
-]
+[u S743 . 1 `S712 1 . 1 0 `S721 1 . 1 0 `S724 1 . 1 0 `S733 1 . 1 0 `S737 1 . 1 0 `S740 1 . 1 0 ]
+[v _RCSTA1bits RCSTA1bits `VES743 1 e 1 @4011 ]
"10840
-[s S660 . 1 `uc 1 TX9D1 1 0 :1:0
+[s S672 . 1 `uc 1 TX9D1 1 0 :1:0
`uc 1 TRMT1 1 0 :1:1
`uc 1 BRGH1 1 0 :1:2
`uc 1 SENDB1 1 0 :1:3
@@ -343,12 +417,12 @@ B 6
`uc 1 TX91 1 0 :1:6
`uc 1 CSRC1 1 0 :1:7
]
-[s S669 . 1 `uc 1 TXD8 1 0 :1:0
+[s S681 . 1 `uc 1 TXD8 1 0 :1:0
`uc 1 . 1 0 :5:1
`uc 1 TX8_9 1 0 :1:6
]
-[u S673 . 1 `S651 1 . 1 0 `S660 1 . 1 0 `S669 1 . 1 0 ]
-[v _TXSTA1bits TXSTA1bits `VES673 1 e 1 @4012 ]
+[u S685 . 1 `S663 1 . 1 0 `S672 1 . 1 0 `S681 1 . 1 0 ]
+[v _TXSTA1bits TXSTA1bits `VES685 1 e 1 @4012 ]
"11183
[v _TX1REG TX1REG `VEuc 1 e 1 @4013 ]
"11261
@@ -357,20 +431,8 @@ B 6
[v _SPBRG1 SPBRG1 `VEuc 1 e 1 @4015 ]
"11408
[v _SPBRGH1 SPBRGH1 `VEuc 1 e 1 @4016 ]
-[s S772 . 1 `uc 1 ABDEN 1 0 :1:0
-`uc 1 WUE 1 0 :1:1
-`uc 1 . 1 0 :1:2
-`uc 1 BRG16 1 0 :1:3
-`uc 1 CKTXP 1 0 :1:4
-`uc 1 DTRXP 1 0 :1:5
-`uc 1 RCIDL 1 0 :1:6
-`uc 1 ABDOVF 1 0 :1:7
-]
"12436
-[s S781 . 1 `uc 1 . 1 0 :4:0
-`uc 1 SCKP 1 0 :1:4
-]
-[s S784 . 1 `uc 1 ABDEN1 1 0 :1:0
+[s S796 . 1 `uc 1 ABDEN1 1 0 :1:0
`uc 1 WUE1 1 0 :1:1
`uc 1 . 1 0 :1:2
`uc 1 BRG161 1 0 :1:3
@@ -379,24 +441,24 @@ B 6
`uc 1 RCIDL1 1 0 :1:6
`uc 1 ABDOVF1 1 0 :1:7
]
-[s S793 . 1 `uc 1 . 1 0 :4:0
+[s S805 . 1 `uc 1 . 1 0 :4:0
`uc 1 TXCKP 1 0 :1:4
`uc 1 RXDTP 1 0 :1:5
`uc 1 RCMT 1 0 :1:6
]
-[s S798 . 1 `uc 1 . 1 0 :4:0
+[s S810 . 1 `uc 1 . 1 0 :4:0
`uc 1 TXCKP1 1 0 :1:4
`uc 1 RXDTP1 1 0 :1:5
`uc 1 RCMT1 1 0 :1:6
]
-[s S803 . 1 `uc 1 . 1 0 :5:0
+[s S815 . 1 `uc 1 . 1 0 :5:0
`uc 1 RXCKP 1 0 :1:5
]
-[s S806 . 1 `uc 1 . 1 0 :1:0
+[s S818 . 1 `uc 1 . 1 0 :1:0
`uc 1 W4E 1 0 :1:1
]
-[u S809 . 1 `S772 1 . 1 0 `S781 1 . 1 0 `S784 1 . 1 0 `S793 1 . 1 0 `S798 1 . 1 0 `S803 1 . 1 0 `S806 1 . 1 0 ]
-[v _BAUDCON1bits BAUDCON1bits `VES809 1 e 1 @4024 ]
+[u S821 . 1 `S784 1 . 1 0 `S793 1 . 1 0 `S796 1 . 1 0 `S805 1 . 1 0 `S810 1 . 1 0 `S815 1 . 1 0 `S818 1 . 1 0 ]
+[v _BAUDCON1bits BAUDCON1bits `VES821 1 e 1 @4024 ]
[s S459 . 1 `uc 1 T2CKPS 1 0 :2:0
`uc 1 TMR2ON 1 0 :1:2
`uc 1 T2OUTPS 1 0 :4:3
@@ -460,98 +522,110 @@ B 6
[v _RC1IF RC1IF `VEb 1 e 0 @31989 ]
"19488
[v _TX1IF TX1IF `VEb 1 e 0 @31988 ]
-"95 Z:\SAMB_4\projects\xilofono\src\main.c
-[v _keypresses keypresses `VE[15]ui 1 e 30 0 ]
-"204
+"19496
+[v _TX2IF TX2IF `VEb 1 e 0 @32036 ]
+"105 Z:\SAMB_4\projects\xilofono\src\main.c
+[v _keys_data keys_data `VE[16]ul 1 e 64 0 ]
+"107
+[v _keypresses keypresses `VEui 1 e 2 0 ]
+"215
[v _main main `(v 1 e 1 0 ]
{
-[s S521 . 7 `uc 1 status 1 0 :4:0
+[s S525 . 7 `uc 1 status 1 0 :4:0
`uc 1 channel 1 0 :4:4
`ui 1 data_size 2 1 `[4]uc 1 data 4 3 ]
-"207
-[v main@sample_message sample_message `S521 1 a 7 2 ]
-"223
+"218
+[v main@message message `S525 1 a 7 13 ]
+"217
+[v main@i i `ui 1 a 2 11 ]
+"258
} 0
"62 Z:\SAMB_4\projects\xilofono\src\midi.c
[v _midi_note_on midi_note_on `(i 1 e 2 0 ]
{
-[s S521 . 7 `uc 1 status 1 0 :4:0
+[s S525 . 7 `uc 1 status 1 0 :4:0
`uc 1 channel 1 0 :4:4
`ui 1 data_size 2 1 `[4]uc 1 data 4 3 ]
-[v midi_note_on@pkt pkt `*.39S521 1 p 2 30 ]
-[v midi_note_on@channel channel `ui 1 p 2 32 ]
-[v midi_note_on@note note `E31 1 p 1 34 ]
-[v midi_note_on@velocity velocity `uc 1 p 1 35 ]
-"83
+[v midi_note_on@pkt pkt `*.39S525 1 p 2 0 ]
+[v midi_note_on@channel channel `ui 1 p 2 2 ]
+[v midi_note_on@note note `E31 1 p 1 4 ]
+[v midi_note_on@velocity velocity `uc 1 p 1 5 ]
+"85
} 0
"40
[v _midi_set_status midi_set_status `(i 1 e 2 0 ]
{
-[s S521 . 7 `uc 1 status 1 0 :4:0
+[s S525 . 7 `uc 1 status 1 0 :4:0
`uc 1 channel 1 0 :4:4
`ui 1 data_size 2 1 `[4]uc 1 data 4 3 ]
-[v midi_set_status@pkt pkt `*.39S521 1 p 2 25 ]
-[v midi_set_status@status status `E40 1 p 1 27 ]
+[v midi_set_status@pkt pkt `*.39S525 1 p 2 42 ]
+[v midi_set_status@status status `E40 1 p 1 44 ]
"49
} 0
"51
[v _midi_set_channel midi_set_channel `(i 1 e 2 0 ]
{
-[s S521 . 7 `uc 1 status 1 0 :4:0
+[s S525 . 7 `uc 1 status 1 0 :4:0
`uc 1 channel 1 0 :4:4
`ui 1 data_size 2 1 `[4]uc 1 data 4 3 ]
-[v midi_set_channel@pkt pkt `*.39S521 1 p 2 25 ]
-[v midi_set_channel@channel channel `ui 1 p 2 27 ]
+[v midi_set_channel@pkt pkt `*.39S525 1 p 2 42 ]
+[v midi_set_channel@channel channel `ui 1 p 2 44 ]
"60
} 0
"8 C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
[v _memset memset `(*.39v 1 e 2 0 ]
{
"15
-[v memset@p p `*.39uc 1 a 2 31 ]
+[v memset@p p `*.39uc 1 a 2 48 ]
"8
-[v memset@p1 p1 `*.39v 1 p 2 25 ]
-[v memset@c c `i 1 p 2 27 ]
-[v memset@n n `ui 1 p 2 29 ]
+[v memset@p1 p1 `*.39v 1 p 2 42 ]
+[v memset@c c `i 1 p 2 44 ]
+[v memset@n n `ui 1 p 2 46 ]
"22
} 0
-"140 Z:\SAMB_4\projects\xilofono\src\main.c
+"150 Z:\SAMB_4\projects\xilofono\src\main.c
[v _init_hw init_hw `T(v 1 e 1 0 ]
{
-"200
+"211
} 0
-"4 Z:\SAMB_4\projects\xilofono\src\rs232.c
+"25 Z:\SAMB_4\projects\xilofono\src\rs232.c
+[v _eusart2_init eusart2_init `(v 1 e 1 0 ]
+{
+"44
+} 0
+"4
[v _eusart1_init eusart1_init `(v 1 e 1 0 ]
{
-"22
+"23
} 0
-"226 Z:\SAMB_4\projects\xilofono\src\main.c
+"261 Z:\SAMB_4\projects\xilofono\src\main.c
[v _eusart_write_midi eusart_write_midi `(i 1 e 2 0 ]
{
-"229
-[v eusart_write_midi@data data `*.39uc 1 a 2 32 ]
-"228
-[v eusart_write_midi@length length `ui 1 a 2 30 ]
-[s S521 . 7 `uc 1 status 1 0 :4:0
+"264
+[v eusart_write_midi@data data `*.39uc 1 a 2 49 ]
+"263
+[v eusart_write_midi@length length `ui 1 a 2 47 ]
+[s S525 . 7 `uc 1 status 1 0 :4:0
`uc 1 channel 1 0 :4:4
`ui 1 data_size 2 1 `[4]uc 1 data 4 3 ]
-"226
-[v eusart_write_midi@pkt pkt `*.39CS521 1 p 2 26 ]
-"245
+"261
+[v eusart_write_midi@pkt pkt `*.39CS525 1 p 2 43 ]
+"280
} 0
-"29 Z:\SAMB_4\projects\xilofono\src\rs232.c
-[v _putch putch `(v 1 e 1 0 ]
+"52 Z:\SAMB_4\projects\xilofono\src\rs232.c
+[v _eusart2_putch eusart2_putch `(v 1 e 1 0 ]
{
-[v putch@c c `uc 1 a 1 wreg ]
-[v putch@c c `uc 1 a 1 wreg ]
-[v putch@c c `uc 1 a 1 25 ]
-"33
+[v eusart2_putch@c c `uc 1 a 1 wreg ]
+[v eusart2_putch@c c `uc 1 a 1 wreg ]
+[v eusart2_putch@c c `uc 1 a 1 42 ]
+"56
} 0
-"101 Z:\SAMB_4\projects\xilofono\src\main.c
+"113 Z:\SAMB_4\projects\xilofono\src\main.c
[v _isr isr `II(v 1 e 1 0 ]
{
-"103
-[v isr@i i `uc 1 a 1 24 ]
-[v isr@data data `uc 1 a 1 23 ]
-"137
+"115
+[v isr@i i `uc 1 a 1 41 ]
+[v isr@data_b data_b `uc 1 a 1 37 ]
+[v isr@data_a data_a `uc 1 a 1 36 ]
+"147
} 0
diff --git a/src/dist/default/production/src.production.sym b/src/dist/default/production/src.production.sym
index 4a8ee88..eb8e1a8 100644
--- a/src/dist/default/production/src.production.sym
+++ b/src/dist/default/production/src.production.sym
@@ -1,26 +1,30 @@
+__end_of_eusart2_putch 642 0 CODE 0
__CFG_XINST$OFF 0 0 ABS 0
-main@sample_message 62 0 BANK0 1
_PR2 FBB 0 ABS 0
__S0 30000E 0 ABS 0
-__S1 69 0 ABS 0
+__S1 B6 0 ABS 0
__S2 0 0 ABS 0
__Hintentry 0 0 ABS 0
__Lintentry 0 0 ABS 0
-midi_set_channel@pkt 1A 0 COMRAM 1
-__end_of_init_hw 308 0 CODE 0
+midi_set_channel@pkt 2B 0 COMRAM 1
+__end_of_init_hw 56E 0 CODE 0
_isr 8 0 CODE 0
__CFG_WDTEN$ON 0 0 ABS 0
-__end_of_eusart_write_midi 2A8 0 CODE 0
-_midi_base_scale 43 0 COMRAM 1
-isr@i 19 0 COMRAM 1
-_main 308 0 CODE 0
+__end_of_eusart_write_midi 4A6 0 CODE 0
+_eusart2_putch 636 0 CODE 0
+isr@i 2A 0 COMRAM 1
+_main 356 0 CODE 0
___sp 0 0 STACK 2
-btemp 45 0 COMRAM 1
-start 1B8 0 CODE 0
+btemp 34 0 COMRAM 1
+start 352 0 CODE 0
__size_of_eusart1_init 0 0 ABS 0
-eusart_write_midi@pkt 1B 0 COMRAM 1
+__size_of_eusart2_init 0 0 ABS 0
+eusart_write_midi@pkt 2C 0 COMRAM 1
+eusart2_putch@c 2B 0 COMRAM 1
_RC1IF 7CF5 0 ABS 0
_TX1IF 7CF4 0 ABS 0
+_TX2IF 7D24 0 ABS 0
+isr@data_a 25 0 COMRAM 1
_TRISA F92 0 ABS 0
_TRISB F93 0 ABS 0
_PORTA F80 0 ABS 0
@@ -29,11 +33,13 @@ __Hirdata 0 0 CODE 0
__Lirdata 0 0 CODE 0
__HRAM 0 0 ABS 0
__LRAM 1 0 ABS 0
-wtemp6 46 0 COMRAM 1
+isr@data_b 26 0 COMRAM 1
+wtemp6 35 0 COMRAM 1
__CFG_WDTPS$32768 0 0 ABS 0
__Hconfig 30000E 0 CONFIG 0
__Lconfig 300000 0 CONFIG 0
__CFG_FOSC$INTIO7 0 0 ABS 0
+main@i AD 0 BANK0 1
__Hbigram 0 0 ABS 0
__Lbigram 0 0 ABS 0
__Hrparam 0 0 COMRAM 1
@@ -41,22 +47,21 @@ __Lrparam 0 0 COMRAM 1
__Hram 0 0 ABS 0
__Lram 0 0 ABS 0
__Hcomram 0 0 ABS 0
-_putch 418 0 CODE 0
__Lcomram 0 0 ABS 0
__Hsfr 0 0 ABS 0
__Lsfr 0 0 ABS 0
__size_of_isr 0 0 ABS 0
-eusart_write_midi@data 21 0 COMRAM 1
+eusart_write_midi@data 32 0 COMRAM 1
__Hbss 0 0 RAM 1
__CFG_STVREN$ON 0 0 ABS 0
__Lbss 0 0 RAM 1
___param_bank 0 0 ABS 0
__Hnvrram 0 0 COMRAM 1
__Lnvrram 0 0 COMRAM 1
-int$flags 45 0 COMRAM 1
+int$flags 34 0 COMRAM 1
__size_of_midi_note_on 0 0 ABS 0
_SPBRG1 FAF 0 ABS 0
-__end_of_putch 424 0 CODE 0
+_SPBRG2 F75 0 ABS 0
_PIE1bits F9D 0 ABS 0
__Heeprom_data 0 0 EEDATA 0
__Leeprom_data 0 0 EEDATA 0
@@ -68,6 +73,7 @@ _ANSELB F39 0 ABS 0
_RC1REG FAE 0 ABS 0
_ANSELC F3A 0 ABS 0
_TX1REG FAD 0 ABS 0
+_TX2REG F73 0 ABS 0
_ANSELD F3B 0 ABS 0
__Hbigbss 0 0 BIGRAM 1
__Lbigbss 0 0 BIGRAM 1
@@ -83,61 +89,64 @@ __Hmediumconst 0 0 MEDIUMCONST 0
__Lmediumconst 0 0 MEDIUMCONST 0
__Hfarbss 0 0 FARRAM 0
__Lfarbss 0 0 FARRAM 0
-__Hintcode 1B8 0 CODE 0
+_keys_data 62 0 BANK0 1
+__Hintcode 352 0 CODE 0
__Lintcode 8 0 CODE 0
__Hfardata 0 0 FARRAM 0
__Lfardata 0 0 FARRAM 0
-midi_note_on@velocity 24 0 COMRAM 1
+midi_note_on@velocity A7 0 BANK0 1
__pintcode 8 0 CODE 0
__Habs1 0 0 ABS 0
__Labs1 0 0 ABS 0
__CFG_EBTR0$OFF 0 0 ABS 0
+__size_of_eusart2_putch 0 0 ABS 0
__HnvFARRAM 0 0 FARRAM 0
__LnvFARRAM 0 0 FARRAM 0
__CFG_EBTR1$OFF 0 0 ABS 0
__CFG_CCP2MX$PORTC1 0 0 ABS 0
-putch@c 1A 0 COMRAM 1
-__end_of_eusart1_init 418 0 CODE 0
+__end_of_eusart1_init 61C 0 CODE 0
__CFG_EBTR2$OFF 0 0 ABS 0
__CFG_CCP3MX$PORTB5 0 0 ABS 0
-__end_of_memset 3B2 0 CODE 0
+__end_of_memset 59A 0 CODE 0
__Hdata 0 0 ABS 0
__Ldata 0 0 ABS 0
__CFG_EBTR3$OFF 0 0 ABS 0
stackhi 5FF 0 ABS 0
__HcstackBANK0 0 0 ABS 0
__LcstackBANK0 0 0 ABS 0
-__pcstackBANK0 60 0 BANK0 1
-__Htemp 46 0 COMRAM 1
-__Ltemp 45 0 COMRAM 1
-stacklo 69 0 ABS 0
+__pcstackBANK0 A2 0 BANK0 1
+__Htemp 35 0 COMRAM 1
+__Ltemp 34 0 COMRAM 1
+stacklo B6 0 ABS 0
+_isr$605 29 0 COMRAM 1
__Hrbit 0 0 COMRAM 1
__Lrbit 0 0 COMRAM 1
-__Hinit 1BC 0 CODE 0
-__Linit 1B8 0 CODE 0
-_isr$592 17 0 COMRAM 1
-__Hintcodelo 1B8 0 CODE 0
-__Lintcodelo 1B8 0 CODE 0
-_memset 386 0 CODE 0
+__Hinit 356 0 CODE 0
+__Linit 352 0 CODE 0
+__Hintcodelo 352 0 CODE 0
+__Lintcodelo 352 0 CODE 0
+_memset 56E 0 CODE 0
__Hrbss 0 0 COMRAM 1
-__end_of_main 354 0 CODE 0
+__end_of_main 432 0 CODE 0
__Lrbss 0 0 COMRAM 1
+_isr$595 27 0 COMRAM 1
__Htext 0 0 ABS 0
__Ltext 0 0 ABS 0
+_isr$596 28 0 COMRAM 1
__CFG_LVP$ON 0 0 ABS 0
-end_of_initialization 378 0 CODE 0
-_midi_set_status 3D8 0 CODE 0
+end_of_initialization 628 0 CODE 0
+_midi_set_status 5C0 0 CODE 0
_SPBRGH1 FB0 0 ABS 0
+_SPBRGH2 F76 0 ABS 0
__size_of_init_hw 0 0 ABS 0
-__end_of_midi_set_channel 3D8 0 CODE 0
-midi_note_on@channel 21 0 COMRAM 1
-__size_of_putch 0 0 ABS 0
+__end_of_midi_set_channel 5C0 0 CODE 0
+midi_note_on@channel A4 0 BANK0 1
_TRISCbits F94 0 ABS 0
_PORTAbits F80 0 ABS 0
_TRISDbits F95 0 ABS 0
_PORTDbits F83 0 ABS 0
_T2CONbits FBA 0 ABS 0
-_midi_set_channel 3B2 0 CODE 0
+_midi_set_channel 59A 0 CODE 0
__size_of_eusart_write_midi 0 0 ABS 0
__Hibigdata 0 0 CODE 0
__Libigdata 0 0 CODE 0
@@ -155,54 +164,53 @@ __Hbank4 0 0 ABS 0
__Lbank4 0 0 ABS 0
__Hbank5 0 0 ABS 0
__Lbank5 0 0 ABS 0
-__Hpowerup 1B8 0 CODE 0
-__Lpowerup 1B8 0 CODE 0
+__Hpowerup 352 0 CODE 0
+__Lpowerup 352 0 CODE 0
__Htext0 0 0 ABS 0
__Ltext0 0 0 ABS 0
-_eusart_write_midi 234 0 CODE 0
+_eusart_write_midi 432 0 CODE 0
__Htext1 0 0 ABS 0
__Ltext1 0 0 ABS 0
-__ptext0 308 0 CODE 0
+__ptext0 356 0 CODE 0
__Htext2 0 0 ABS 0
__Ltext2 0 0 ABS 0
-__ptext1 1BC 0 CODE 0
-__end_of_midi_note_on 234 0 CODE 0
+__ptext1 4A6 0 CODE 0
+__end_of_midi_note_on 50C 0 CODE 0
__Htext3 0 0 ABS 0
__Ltext3 0 0 ABS 0
-__ptext2 3D8 0 CODE 0
+__ptext2 5C0 0 CODE 0
__Htext4 0 0 ABS 0
__Ltext4 0 0 ABS 0
-__ptext3 3B2 0 CODE 0
+__ptext3 59A 0 CODE 0
__Htext5 0 0 ABS 0
__CFG_P2BMX$PORTD2 0 0 ABS 0
__Ltext5 0 0 ABS 0
-__ptext4 386 0 CODE 0
+__ptext4 56E 0 CODE 0
__Htext6 0 0 ABS 0
__Ltext6 0 0 ABS 0
-__ptext5 2A8 0 CODE 0
+__ptext5 50C 0 CODE 0
__Htext7 0 0 ABS 0
__Ltext7 0 0 ABS 0
-__ptext6 3FC 0 CODE 0
-__HbssCOMRAM 0 0 ABS 0
-__LbssCOMRAM 0 0 ABS 0
+__ptext6 5E4 0 CODE 0
__Htext8 0 0 ABS 0
__Ltext8 0 0 ABS 0
-__ptext7 234 0 CODE 0
-__pbssCOMRAM 25 0 COMRAM 1
-__ptext8 418 0 CODE 0
+__ptext7 600 0 CODE 0
+__Htext9 0 0 ABS 0
+__Ltext9 0 0 ABS 0
+__ptext8 432 0 CODE 0
__CFG_T3CMX$PORTC0 0 0 ABS 0
+__ptext9 636 0 CODE 0
__Hclrtext 0 0 ABS 0
__Lclrtext 0 0 ABS 0
__CFG_HFOFST$ON 0 0 ABS 0
_OSCTUNEbits F9B 0 ABS 0
-__end_of__initialization 378 0 CODE 0
+__end_of__initialization 628 0 CODE 0
__CFG_PRICLKEN$ON 0 0 ABS 0
-memset@c 1C 0 COMRAM 1
+memset@c 2D 0 COMRAM 1
___rparam_used 1 0 ABS 0
__size_of_memset 0 0 ABS 0
-memset@n 1E 0 COMRAM 1
-memset@p 20 0 COMRAM 1
-isr@data 18 0 COMRAM 1
+memset@n 2F 0 COMRAM 1
+memset@p 31 0 COMRAM 1
__Hidata 0 0 CODE 0
__Lidata 0 0 CODE 0
__Hrdata 0 0 COMRAM 1
@@ -212,30 +220,30 @@ __Lidloc 200000 0 IDLOC 0
__CFG_PWRTEN$OFF 0 0 ABS 0
__Hstack 0 0 STACK 2
__Lstack 0 0 STACK 2
-_midi_note_on 1BC 0 CODE 0
-midi_set_channel@channel 1C 0 COMRAM 1
+_midi_note_on 4A6 0 CODE 0
+midi_set_channel@channel 2D 0 COMRAM 1
__Hparam 0 0 COMRAM 1
__Lparam 0 0 COMRAM 1
__Hspace_0 30000E 0 ABS 0
__HcstackCOMRAM 0 0 ABS 0
__Lspace_0 0 0 ABS 0
__LcstackCOMRAM 0 0 ABS 0
-__end_of_isr 1B8 0 CODE 0
+__end_of_isr 352 0 CODE 0
__pcstackCOMRAM 1 0 COMRAM 1
-__Hspace_1 69 0 ABS 0
+__Hspace_1 B6 0 ABS 0
__Lspace_1 0 0 ABS 0
__Hsmallconst 0 0 SMALLCONST 0
__Lsmallconst 0 0 SMALLCONST 0
-eusart_write_midi@length 1F 0 COMRAM 1
+eusart_write_midi@length 30 0 COMRAM 1
__Hspace_2 0 0 ABS 0
__Lspace_2 0 0 ABS 0
__Hnvbit 0 0 COMRAM 1
__Lnvbit 0 0 COMRAM 1
__Hcinit 0 0 ABS 0
__Lcinit 0 0 ABS 0
-__pcinit 354 0 CODE 0
+__pcinit 61C 0 CODE 0
__CFG_EBTRB$OFF 0 0 ABS 0
-_init_hw 2A8 0 CODE 0
+_init_hw 50C 0 CODE 0
__ramtop 600 0 RAM 0
__mediumconst 0 0 MEDIUMCONST 0
__size_of_main 0 0 ABS 0
@@ -244,207 +252,219 @@ __Lconst 0 0 CONST 0
__CFG_PLLCFG$ON 0 0 ABS 0
__CFG_WRT0$OFF 0 0 ABS 0
__CFG_WRT1$OFF 0 0 ABS 0
-midi_note_on@pkt 1F 0 COMRAM 1
+midi_note_on@pkt A2 0 BANK0 1
+__HbssBANK0 0 0 ABS 0
+__LbssBANK0 0 0 ABS 0
__CFG_MCLRE$EXTMCLR 0 0 ABS 0
__CFG_WRT2$OFF 0 0 ABS 0
+__pbssBANK0 60 0 BANK0 1
__CFG_WRT3$OFF 0 0 ABS 0
__CFG_FCMEN$OFF 0 0 ABS 0
__size_of_midi_set_status 0 0 ABS 0
-midi_note_on@note 23 0 COMRAM 1
-midi_set_status@pkt 1A 0 COMRAM 1
+midi_note_on@note A6 0 BANK0 1
+midi_set_status@pkt 2B 0 COMRAM 1
_RCSTA1bits FAB 0 ABS 0
+_RCSTA2bits F71 0 ABS 0
_TXSTA1bits FAC 0 ABS 0
+_TXSTA2bits F72 0 ABS 0
___inthi_sp 0 0 STACK 2
__size_of_midi_set_channel 0 0 ABS 0
___intlo_sp 0 0 STACK 2
_OSCCONbits FD3 0 ABS 0
_INTCONbits FF2 0 ABS 0
-__HidataCOMRAM 0 0 ABS 0
-__LidataCOMRAM 0 0 ABS 0
-_keypresses 25 0 COMRAM 1
-__pidataCOMRAM 424 0 CODE 0
+_keypresses 60 0 BANK0 1
__CFG_CP0$OFF 0 0 ABS 0
__smallconst 0 0 SMALLCONST 0
+main@message AF 0 BANK0 1
__CFG_CP1$OFF 0 0 ABS 0
-memset@p1 1A 0 COMRAM 1
+memset@p1 2B 0 COMRAM 1
__Hreset_vec 4 0 CODE 0
__Lreset_vec 0 0 CODE 0
__CFG_CP2$OFF 0 0 ABS 0
__CFG_CP3$OFF 0 0 ABS 0
__CFG_BORV$190 0 0 ABS 0
__accesstop 60 0 ABS 0
-__end_of_midi_set_status 3FC 0 CODE 0
+__end_of_midi_set_status 5E4 0 CODE 0
__Hintcode_body 0 0 ABS 0
__Lintcode_body 0 0 ABS 0
__CFG_PBADEN$ON 0 0 ABS 0
intlevel0 0 0 CODE 0
intlevel1 0 0 CODE 0
__CFG_WRTB$OFF 0 0 ABS 0
-midi_set_status@status 1C 0 COMRAM 1
+midi_set_status@status 2D 0 COMRAM 1
intlevel2 0 0 CODE 0
intlevel3 0 0 CODE 0
__CFG_WRTC$OFF 0 0 ABS 0
_BAUDCON1bits FB8 0 ABS 0
__CFG_WRTD$OFF 0 0 ABS 0
-__HdataCOMRAM 0 0 ABS 0
-__LdataCOMRAM 0 0 ABS 0
-__pdataCOMRAM 43 0 COMRAM 1
+_BAUDCON2bits F70 0 ABS 0
__CFG_CPB$OFF 0 0 ABS 0
__CFG_CPD$OFF 0 0 ABS 0
-start_initialization 354 0 CODE 0
+start_initialization 61C 0 CODE 0
__CFG_BOREN$SBORDIS 0 0 ABS 0
__CFG_IESO$OFF 0 0 ABS 0
-_eusart1_init 3FC 0 CODE 0
-__initialization 354 0 CODE 0
+_eusart1_init 600 0 CODE 0
+_eusart2_init 5E4 0 CODE 0
+__end_of_eusart2_init 600 0 CODE 0
+__initialization 61C 0 CODE 0
__activetblptr 2 0 ABS 0
%segments
reset_vec 0 3 CODE 0 0
-intcode 8 425 CODE 8 0
+intcode 8 641 CODE 8 0
config 300000 30000D CONFIG 300000 0
idloc 200000 200007 IDLOC 200000 0
-cstackCOMRAM 1 45 COMRAM 1 1
-cstackBANK0 60 68 BANK0 60 1
+cstackCOMRAM 1 34 COMRAM 1 1
+bssBANK0 60 B5 BANK0 60 1
%locals
dist/default/production\src.production.obj
C:\Program Files\Microchip\xc8\v1.44\include\pic18f45k22.h
-C:\Users\_prossn\AppData\Local\Temp\s5hg.
-1211 354 0 CODE 0
-1213 354 0 CODE 0
-1216 354 0 CODE 0
-1238 354 0 CODE 0
-1239 356 0 CODE 0
-1240 358 0 CODE 0
-1241 35A 0 CODE 0
-1242 35C 0 CODE 0
-1243 35E 0 CODE 0
-1244 360 0 CODE 0
-1245 362 0 CODE 0
-1246 366 0 CODE 0
-1247 368 0 CODE 0
-1251 36C 0 CODE 0
-1252 370 0 CODE 0
-1253 372 0 CODE 0
-1254 372 0 CODE 0
-1255 374 0 CODE 0
-1256 376 0 CODE 0
-1262 378 0 CODE 0
-1264 378 0 CODE 0
-1265 37A 0 CODE 0
-1267 37C 0 CODE 0
-1268 37E 0 CODE 0
-1269 380 0 CODE 0
-1270 382 0 CODE 0
+C:\Users\_prossn\AppData\Local\Temp\s514.
+1219 61C 0 CODE 0
+1221 61C 0 CODE 0
+1224 61C 0 CODE 0
+1239 61C 0 CODE 0
+1240 620 0 CODE 0
+1241 622 0 CODE 0
+1242 622 0 CODE 0
+1243 624 0 CODE 0
+1244 626 0 CODE 0
+1250 628 0 CODE 0
+1252 628 0 CODE 0
+1253 62A 0 CODE 0
+1255 62C 0 CODE 0
+1256 62E 0 CODE 0
+1257 630 0 CODE 0
+1258 632 0 CODE 0
main.c
-204 308 0 CODE 0
-210 308 0 CODE 0
-213 30C 0 CODE 0
-216 328 0 CODE 0
-217 344 0 CODE 0
-220 346 0 CODE 0
-221 346 0 CODE 0
-220 352 0 CODE 0
+215 356 0 CODE 0
+221 356 0 CODE 0
+224 35A 0 CODE 0
+226 376 0 CODE 0
+229 378 0 CODE 0
+232 37A 0 CODE 0
+235 398 0 CODE 0
+237 398 0 CODE 0
+238 3AE 0 CODE 0
+241 3DA 0 CODE 0
+244 3E0 0 CODE 0
+251 3EC 0 CODE 0
+254 3FE 0 CODE 0
+255 42C 0 CODE 0
+237 42C 0 CODE 0
midi.c
-62 1BC 0 CODE 0
-64 1BC 0 CODE 0
-68 1C4 0 CODE 0
-72 1DA 0 CODE 0
-73 1EA 0 CODE 0
-75 1FE 0 CODE 0
-76 20E 0 CODE 0
-79 21E 0 CODE 0
+62 4A6 0 CODE 0
+64 4A6 0 CODE 0
+74 4B0 0 CODE 0
+75 4C0 0 CODE 0
+77 4D4 0 CODE 0
+78 4E6 0 CODE 0
+81 4F6 0 CODE 0
midi.c
-40 3D8 0 CODE 0
-42 3D8 0 CODE 0
-46 3E0 0 CODE 0
+40 5C0 0 CODE 0
+42 5C0 0 CODE 0
+46 5C8 0 CODE 0
midi.c
-51 3B2 0 CODE 0
-53 3B2 0 CODE 0
-57 3BA 0 CODE 0
+51 59A 0 CODE 0
+53 59A 0 CODE 0
+57 5A2 0 CODE 0
C:\Program Files\Microchip\xc8\v1.44\sources\common\memset.c
-8 386 0 CODE 0
-18 386 0 CODE 0
-19 38E 0 CODE 0
-20 390 0 CODE 0
-19 3A0 0 CODE 0
+8 56E 0 CODE 0
+18 56E 0 CODE 0
+19 576 0 CODE 0
+20 578 0 CODE 0
+19 588 0 CODE 0
main.c
-140 2A8 0 CODE 0
-142 2A8 0 CODE 0
-146 2AA 0 CODE 0
-148 2AC 0 CODE 0
-150 2B8 0 CODE 0
-152 2BE 0 CODE 0
-156 2C2 0 CODE 0
-157 2C8 0 CODE 0
-158 2CC 0 CODE 0
-159 2D0 0 CODE 0
-162 2D4 0 CODE 0
-163 2D6 0 CODE 0
-165 2D8 0 CODE 0
-166 2DA 0 CODE 0
-167 2DC 0 CODE 0
-168 2DE 0 CODE 0
-171 2E0 0 CODE 0
-173 2E2 0 CODE 0
-175 2E4 0 CODE 0
-177 2E6 0 CODE 0
-181 2E8 0 CODE 0
-183 2EC 0 CODE 0
-185 2F4 0 CODE 0
-187 2F8 0 CODE 0
-190 2FA 0 CODE 0
-191 2FC 0 CODE 0
-194 2FE 0 CODE 0
-197 300 0 CODE 0
-199 304 0 CODE 0
-200 306 0 CODE 0
+150 50C 0 CODE 0
+152 50C 0 CODE 0
+156 50E 0 CODE 0
+158 510 0 CODE 0
+160 51C 0 CODE 0
+162 522 0 CODE 0
+166 526 0 CODE 0
+167 52C 0 CODE 0
+168 530 0 CODE 0
+169 534 0 CODE 0
+172 538 0 CODE 0
+173 53A 0 CODE 0
+176 53C 0 CODE 0
+177 53E 0 CODE 0
+178 540 0 CODE 0
+179 542 0 CODE 0
+182 544 0 CODE 0
+184 546 0 CODE 0
+186 548 0 CODE 0
+188 54A 0 CODE 0
+193 54C 0 CODE 0
+195 550 0 CODE 0
+197 558 0 CODE 0
+199 55C 0 CODE 0
+202 55E 0 CODE 0
+203 560 0 CODE 0
+206 562 0 CODE 0
+209 564 0 CODE 0
+210 568 0 CODE 0
+211 56C 0 CODE 0
rs232.c
-4 3FC 0 CODE 0
-7 3FC 0 CODE 0
-8 3FE 0 CODE 0
-11 400 0 CODE 0
-12 402 0 CODE 0
-13 406 0 CODE 0
-14 40A 0 CODE 0
-15 40C 0 CODE 0
-18 40E 0 CODE 0
-19 410 0 CODE 0
-20 412 0 CODE 0
-21 414 0 CODE 0
-22 416 0 CODE 0
+25 5E4 0 CODE 0
+28 5E4 0 CODE 0
+29 5E6 0 CODE 0
+32 5E8 0 CODE 0
+33 5EA 0 CODE 0
+34 5EE 0 CODE 0
+35 5F2 0 CODE 0
+36 5F4 0 CODE 0
+39 5F6 0 CODE 0
+40 5F8 0 CODE 0
+42 5FA 0 CODE 0
+43 5FC 0 CODE 0
+44 5FE 0 CODE 0
+rs232.c
+4 600 0 CODE 0
+7 600 0 CODE 0
+8 602 0 CODE 0
+11 604 0 CODE 0
+12 606 0 CODE 0
+13 60A 0 CODE 0
+14 60E 0 CODE 0
+15 610 0 CODE 0
+18 612 0 CODE 0
+19 614 0 CODE 0
+21 616 0 CODE 0
+22 618 0 CODE 0
+23 61A 0 CODE 0
main.c
-226 234 0 CODE 0
-231 234 0 CODE 0
-235 23C 0 CODE 0
-236 250 0 CODE 0
-238 25C 0 CODE 0
-240 282 0 CODE 0
-241 284 0 CODE 0
-242 296 0 CODE 0
-240 296 0 CODE 0
+261 432 0 CODE 0
+266 432 0 CODE 0
+270 43A 0 CODE 0
+271 44E 0 CODE 0
+273 45A 0 CODE 0
+275 480 0 CODE 0
+276 482 0 CODE 0
+277 494 0 CODE 0
+275 494 0 CODE 0
rs232.c
-29 418 0 CODE 0
-31 41A 0 CODE 0
-32 41E 0 CODE 0
-33 422 0 CODE 0
+52 636 0 CODE 0
+54 638 0 CODE 0
+55 63C 0 CODE 0
+56 640 0 CODE 0
rs232.c
-33 8 0 CODE 0
+56 8 0 CODE 0
main.c
-101 8 0 CODE 0
-105 52 0 CODE 0
-107 54 0 CODE 0
-109 58 0 CODE 0
-110 5C 0 CODE 0
-111 60 0 CODE 0
-112 60 0 CODE 0
-113 B6 0 CODE 0
-115 BE 0 CODE 0
-116 C2 0 CODE 0
-117 C6 0 CODE 0
-118 C6 0 CODE 0
-119 11C 0 CODE 0
-129 13C 0 CODE 0
-130 146 0 CODE 0
-133 168 0 CODE 0
-134 16A 0 CODE 0
-136 16A 0 CODE 0
-137 16C 0 CODE 0
+113 8 0 CODE 0
+117 52 0 CODE 0
+119 54 0 CODE 0
+120 58 0 CODE 0
+121 5C 0 CODE 0
+122 60 0 CODE 0
+123 64 0 CODE 0
+125 64 0 CODE 0
+126 E0 0 CODE 0
+131 188 0 CODE 0
+132 202 0 CODE 0
+134 2AC 0 CODE 0
+138 2B4 0 CODE 0
+139 2BE 0 CODE 0
+143 302 0 CODE 0
+144 304 0 CODE 0
+146 304 0 CODE 0
+147 306 0 CODE 0
diff --git a/src/nbproject/Makefile-genesis.properties b/src/nbproject/Makefile-genesis.properties
index 7e799cd..7d48541 100644
--- a/src/nbproject/Makefile-genesis.properties
+++ b/src/nbproject/Makefile-genesis.properties
@@ -1,5 +1,5 @@
#
-#Fri Feb 23 16:05:02 CET 2018
+#Tue Feb 27 08:26:12 CET 2018
default.languagetoolchain.dir=C\:\\Program Files\\Microchip\\xc8\\v1.44\\bin
configurations-xml=b7ce4d9a7385ee4bf81a07319272507b
com-microchip-mplab-nbide-embedded-makeproject-MakeProject.md5=5d30ff5128b14865c8a3796a8f0bb8a0