Index: format/app_mouse.format
===================================================================
--- /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/format/app_mouse.format	(revision 5300)
+++ /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/format/app_mouse.format	(working copy)
@@ -500,6 +500,7 @@
 1 mem_store_key_info_delay_timer_init
 1 mem_key_info_store_flag
 10 mem_mouse_key_fuction_info_temp
+1 mem_mouse_key_bit_index_value
 )
 
 (
@@ -510,6 +511,10 @@
 //key type
 0 MS_KEY
 1 KB_KEY
+//kb key type
+0x00 KB_NORMAL_KEY
+0x02 KB_SYSTEM_KEY
+0x03 KB_MULTIKEY
 )
 
 (
Index: output/eeprom.dat
===================================================================
--- /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/eeprom.dat	(revision 5300)
+++ /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/eeprom.dat	(working copy)
@@ -2,8 +2,8 @@
 02
 aa
 55
-a6
-1d
+0a
+1f
 20
 20
 00
@@ -311,7 +311,7 @@
 c0
 64
 07
-2c
+85
 c0
 64
 84
@@ -330,8 +330,8 @@
 ec
 c0
 68
-06
-c6
+07
+1f
 c0
 69
 04
@@ -371,7 +371,7 @@
 c0
 6c
 87
-32
+8b
 c0
 6d
 05
@@ -2107,11 +2107,11 @@
 20
 40
 07
-25
+7e
 20
 40
 07
-34
+8d
 20
 40
 41
@@ -3675,7 +3675,7 @@
 20
 40
 07
-2c
+85
 20
 20
 32
@@ -3699,7 +3699,7 @@
 20
 20
 07
-28
+81
 20
 40
 22
@@ -5006,8 +5006,8 @@
 13
 20
 40
-06
-f9
+07
+52
 68
 48
 c9
@@ -5123,11 +5123,11 @@
 c0
 1e
 07
-2e
+87
 c0
 1c
 87
-2a
+83
 c0
 1d
 05
@@ -5139,7 +5139,7 @@
 c0
 0a
 87
-30
+89
 c0
 0a
 05
@@ -5335,7 +5335,7 @@
 24
 5a
 07
-2c
+85
 6f
 e4
 48
@@ -6758,8 +6758,8 @@
 d5
 20
 40
-06
-a9
+07
+02
 58
 00
 00
@@ -6782,8 +6782,8 @@
 c3
 20
 40
-06
-c3
+07
+1c
 6f
 e0
 c8
@@ -6796,10 +6796,14 @@
 e0
 c8
 d4
+20
+40
+06
+aa
 24
 34
 06
-a7
+a8
 70
 4d
 e9
@@ -6810,8 +6814,8 @@
 01
 20
 40
-06
-b9
+07
+12
 20
 20
 45
@@ -6824,146 +6828,498 @@
 20
 47
 66
-6f
-e0
-c4
-ae
-c1
-80
-00
-00
-20
-40
-3f
-a5
-6f
-e0
-c9
-2c
+70
+4e
+ce
+02
+d8
 c0
-05
-86
-af
-20
-20
-42
-83
+4e
+48
 20
 40
-43
+06
+b6
+70
+4e
+ce
 04
-6f
-e0
-c9
-15
+d8
 c0
-7f
-86
-b5
-68
-48
-c9
-15
+4e
+3e
 20
 40
-60
-fd
-24
-60
-80
-00
-58
-00
-00
-00
+06
+b6
+70
+4e
+ce
+08
+d8
+c0
+4e
+5c
 20
 40
-5d
-65
+06
+b6
+70
+4e
+ce
+10
+d8
 c0
-ac
-41
-f2
+4e
+52
 20
 20
-42
-b9
+06
+b6
+d8
+a0
+4e
+c4
+20
+40
+01
+79
 6f
-e4
-4b
+e0
+ce
+c4
+c0
+00
+06
 bc
-c3
-8c
-80
+c0
 00
-c3
-8d
+86
+df
+20
+60
 00
 00
-c3
-8f
+6f
+e0
+ce
+c5
+20
+7a
 00
 00
-c3
-8f
-80
+68
+48
+ce
+ce
+98
+46
+7c
 00
-6f
-e0
-c9
-2c
-c1
-01
+20
+62
 80
 00
-c1
-05
+c2
 80
-00
-20
-40
-47
-58
+86
+c6
+c2
+81
+06
+cd
+c2
+81
+86
+d3
+c2
+82
+06
+d9
 20
 60
 00
 00
-20
-40
-06
-c6
-20
-40
-41
-2d
-20
-20
-41
-1e
+68
+48
+c8
+d4
 6f
 e0
-cb
-f2
-24
-5a
+ce
+ce
+98
 41
-61
-da
+7e
+00
 20
+7a
 00
 00
+79
 20
-40
-06
-cd
-20
-40
-06
-dc
+04
+01
+60
+48
+c8
+d4
 20
-40
-06
-e9
+60
+00
+00
+68
+48
+c8
+d4
+6f
+e0
+ce
+ce
+98
+41
+7e
+00
+20
+7a
+00
+00
+79
+20
+04
+02
+20
+20
+06
+cb
+68
+48
+c8
+d4
+6f
+e0
+ce
+ce
+98
+41
+7e
+00
+20
+7a
+00
+00
+79
+20
+04
+03
+20
+20
+06
+cb
+68
+48
+c8
+d4
+6f
+e0
+ce
+ce
+98
+41
+7e
+00
+20
+7a
+00
+00
+79
+20
+04
+04
+20
+20
+06
+cb
+58
+00
+00
+00
+67
+e4
+4b
+e6
+6f
+e0
+ce
+c5
+20
+5a
+06
+f3
+68
+48
+c8
+d4
+6f
+e0
+ce
+ce
+98
+41
+7e
+00
+20
+3a
+41
+b6
+68
+48
+ce
+ce
+28
+4f
+fe
+01
+20
+40
+86
+f5
+28
+4f
+fe
+02
+20
+40
+86
+f9
+28
+4f
+fe
+03
+20
+40
+86
+fc
+28
+4f
+fe
+04
+20
+40
+86
+ff
+6f
+e4
+4e
+c5
+67
+e4
+4b
+dd
+20
+20
+41
+ba
+67
+e0
+cb
+e6
+20
+60
+00
+00
+6f
+e0
+c8
+d4
+79
+3f
+fe
+01
+67
+e0
+c8
+d4
+20
+60
+00
+00
+6f
+e0
+c8
+d4
+79
+3f
+fe
+02
+20
+20
+06
+f7
+6f
+e0
+c8
+d4
+79
+3f
+fe
+03
+20
+20
+06
+f7
+6f
+e0
+c8
+d4
+79
+3f
+fe
+04
+20
+20
+06
+f7
+6f
+e0
+c4
+ae
+c1
+80
+00
+00
+20
+40
+3f
+a5
+6f
+e0
+c9
+2c
+c0
+05
+87
+08
+20
+20
+42
+83
+20
+40
+43
+04
+6f
+e0
+c9
+15
+c0
+7f
+87
+0e
+68
+48
+c9
+15
+20
+40
+60
+fd
+24
+60
+80
+00
+58
+00
+00
+00
+20
+40
+5d
+65
+c0
+ac
+41
+f2
+20
+20
+42
+b9
+6f
+e4
+4b
+bc
+c3
+8c
+80
+00
+c3
+8d
+00
+00
+c3
+8f
+00
+00
+c3
+8f
+80
+00
+6f
+e0
+c9
+2c
+c1
+01
+80
+00
+c1
+05
+80
+00
+20
+40
+47
+58
+20
+60
+00
+00
+20
+40
+07
+1f
+20
+40
+41
+2d
+20
+20
+41
+1e
+6f
+e0
+cb
+f2
+24
+5a
+41
+61
+da
+20
+00
+00
+20
+40
+07
+26
+20
+40
+07
+35
+20
+40
+07
+42
 20
 20
 41
@@ -6974,8 +7330,8 @@
 1c
 20
 40
-06
-f6
+07
+4f
 20
 40
 41
@@ -6994,8 +7350,8 @@
 1d
 20
 40
-06
-f6
+07
+4f
 20
 40
 41
@@ -7014,8 +7370,8 @@
 1e
 20
 40
-06
-f6
+07
+4f
 20
 40
 41
@@ -7058,8 +7414,8 @@
 14
 c0
 7f
-86
-e5
+87
+3e
 20
 20
 41
@@ -7070,8 +7426,8 @@
 11
 20
 40
-06
-f9
+07
+52
 68
 48
 c9
@@ -7110,8 +7466,8 @@
 14
 c0
 7f
-86
-f2
+87
+4b
 20
 20
 41
@@ -7122,8 +7478,8 @@
 12
 20
 40
-06
-f9
+07
+52
 68
 48
 c9
@@ -7167,23 +7523,23 @@
 20
 40
 07
-12
+6b
 20
 40
 07
-02
+5b
 20
 40
 07
-18
+71
 20
 20
-06
-ff
+07
+58
 20
 40
-06
-c6
+07
+1f
 1a
 21
 7e
@@ -7191,7 +7547,7 @@
 c0
 00
 87
-07
+60
 70
 4e
 3c
@@ -7231,15 +7587,15 @@
 c0
 00
 07
-12
+6b
 c0
 00
 87
-14
+6d
 c0
 01
 07
-16
+6f
 20
 60
 00
@@ -7315,7 +7671,7 @@
 c2
 00
 07
-21
+7a
 20
 60
 00
@@ -7331,7 +7687,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7339,7 +7695,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7347,7 +7703,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7355,7 +7711,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7363,7 +7719,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7371,7 +7727,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7379,7 +7735,7 @@
 20
 20
 07
-37
+90
 20
 75
 80
@@ -7391,7 +7747,7 @@
 20
 20
 07
-37
+90
 68
 48
 cd
@@ -7411,7 +7767,7 @@
 20
 22
 87
-53
+ac
 60
 48
 cd
@@ -7451,19 +7807,19 @@
 20
 40
 07
-55
+ae
 20
 40
 07
-61
+ba
 20
 40
 07
-58
+b1
 24
 22
 87
-45
+9e
 6f
 e2
 0e
@@ -7479,7 +7835,7 @@
 24
 22
 87
-45
+9e
 58
 00
 0e
@@ -7547,7 +7903,7 @@
 c2
 00
 07
-5b
+b4
 ef
 e2
 00
@@ -7592,8 +7948,8 @@
 20
 3f
 a5
-f2
-8f
+5c
+0d
 aa
 55
 40
@@ -7735,7 +8091,7 @@
 4b
 04
 09
-06
+26
 00
 00
 12
@@ -9059,14 +9415,14 @@
 00
 d7
 4d
-6f
-29
+d3
+2a
 00
 55
 aa
 aa
 55
-33
+b8
 b0
 ff
 20
@@ -9887,8 +10243,8 @@
 24
 20
 40
-06
-f6
+07
+4f
 20
 40
 04
@@ -10091,8 +10447,8 @@
 00
 f5
 8a
-8d
-6e
+8e
+c7
 20
 20
 00
@@ -10119,8 +10475,8 @@
 07
 c0
 01
-86
-fc
+87
+55
 6f
 e4
 4b
@@ -10347,8 +10703,8 @@
 00
 fd
 39
-13
-0f
+14
+68
 20
 20
 00
@@ -10609,5 +10965,5 @@
 00
 00
 00
-61
-9a
+ae
+0f
Index: output/flash.dat
===================================================================
--- /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/flash.dat	(revision 5300)
+++ /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/flash.dat	(working copy)
@@ -2,8 +2,8 @@
 02
 aa
 55
-a6
-1d
+0a
+1f
 20
 20
 00
@@ -311,7 +311,7 @@
 c0
 64
 07
-2c
+85
 c0
 64
 84
@@ -330,8 +330,8 @@
 ec
 c0
 68
-06
-c6
+07
+1f
 c0
 69
 04
@@ -371,7 +371,7 @@
 c0
 6c
 87
-32
+8b
 c0
 6d
 05
@@ -2107,11 +2107,11 @@
 20
 40
 07
-25
+7e
 20
 40
 07
-34
+8d
 20
 40
 41
@@ -3675,7 +3675,7 @@
 20
 40
 07
-2c
+85
 20
 20
 32
@@ -3699,7 +3699,7 @@
 20
 20
 07
-28
+81
 20
 40
 22
@@ -5006,8 +5006,8 @@
 13
 20
 40
-06
-f9
+07
+52
 68
 48
 c9
@@ -5123,11 +5123,11 @@
 c0
 1e
 07
-2e
+87
 c0
 1c
 87
-2a
+83
 c0
 1d
 05
@@ -5139,7 +5139,7 @@
 c0
 0a
 87
-30
+89
 c0
 0a
 05
@@ -5335,7 +5335,7 @@
 24
 5a
 07
-2c
+85
 6f
 e4
 48
@@ -6758,8 +6758,8 @@
 d5
 20
 40
-06
-a9
+07
+02
 58
 00
 00
@@ -6782,8 +6782,8 @@
 c3
 20
 40
-06
-c3
+07
+1c
 6f
 e0
 c8
@@ -6796,10 +6796,14 @@
 e0
 c8
 d4
+20
+40
+06
+aa
 24
 34
 06
-a7
+a8
 70
 4d
 e9
@@ -6810,8 +6814,8 @@
 01
 20
 40
-06
-b9
+07
+12
 20
 20
 45
@@ -6824,146 +6828,498 @@
 20
 47
 66
-6f
-e0
-c4
-ae
-c1
-80
-00
-00
-20
-40
-3f
-a5
-6f
-e0
-c9
-2c
+70
+4e
+ce
+02
+d8
 c0
-05
-86
-af
-20
-20
-42
-83
+4e
+48
 20
 40
-43
+06
+b6
+70
+4e
+ce
 04
-6f
-e0
-c9
-15
+d8
 c0
-7f
-86
-b5
-68
-48
-c9
-15
+4e
+3e
 20
 40
-60
-fd
-24
-60
-80
-00
-58
-00
-00
-00
+06
+b6
+70
+4e
+ce
+08
+d8
+c0
+4e
+5c
 20
 40
-5d
-65
+06
+b6
+70
+4e
+ce
+10
+d8
 c0
-ac
-41
-f2
+4e
+52
 20
 20
-42
-b9
+06
+b6
+d8
+a0
+4e
+c4
+20
+40
+01
+79
 6f
-e4
-4b
+e0
+ce
+c4
+c0
+00
+06
 bc
-c3
-8c
-80
+c0
 00
-c3
-8d
+86
+df
+20
+60
 00
 00
-c3
-8f
+6f
+e0
+ce
+c5
+20
+7a
 00
 00
-c3
-8f
-80
+68
+48
+ce
+ce
+98
+46
+7c
 00
-6f
-e0
-c9
-2c
-c1
-01
+20
+62
 80
 00
-c1
-05
+c2
 80
-00
-20
-40
-47
-58
+86
+c6
+c2
+81
+06
+cd
+c2
+81
+86
+d3
+c2
+82
+06
+d9
 20
 60
 00
 00
-20
-40
-06
-c6
-20
-40
-41
-2d
-20
-20
-41
-1e
+68
+48
+c8
+d4
 6f
 e0
-cb
-f2
-24
-5a
+ce
+ce
+98
 41
-61
-da
+7e
+00
 20
+7a
 00
 00
+79
 20
-40
-06
-cd
-20
-40
-06
-dc
+04
+01
+60
+48
+c8
+d4
 20
-40
-06
-e9
+60
+00
+00
+68
+48
+c8
+d4
+6f
+e0
+ce
+ce
+98
+41
+7e
+00
+20
+7a
+00
+00
+79
+20
+04
+02
+20
+20
+06
+cb
+68
+48
+c8
+d4
+6f
+e0
+ce
+ce
+98
+41
+7e
+00
+20
+7a
+00
+00
+79
+20
+04
+03
+20
+20
+06
+cb
+68
+48
+c8
+d4
+6f
+e0
+ce
+ce
+98
+41
+7e
+00
+20
+7a
+00
+00
+79
+20
+04
+04
+20
+20
+06
+cb
+58
+00
+00
+00
+67
+e4
+4b
+e6
+6f
+e0
+ce
+c5
+20
+5a
+06
+f3
+68
+48
+c8
+d4
+6f
+e0
+ce
+ce
+98
+41
+7e
+00
+20
+3a
+41
+b6
+68
+48
+ce
+ce
+28
+4f
+fe
+01
+20
+40
+86
+f5
+28
+4f
+fe
+02
+20
+40
+86
+f9
+28
+4f
+fe
+03
+20
+40
+86
+fc
+28
+4f
+fe
+04
+20
+40
+86
+ff
+6f
+e4
+4e
+c5
+67
+e4
+4b
+dd
+20
+20
+41
+ba
+67
+e0
+cb
+e6
+20
+60
+00
+00
+6f
+e0
+c8
+d4
+79
+3f
+fe
+01
+67
+e0
+c8
+d4
+20
+60
+00
+00
+6f
+e0
+c8
+d4
+79
+3f
+fe
+02
+20
+20
+06
+f7
+6f
+e0
+c8
+d4
+79
+3f
+fe
+03
+20
+20
+06
+f7
+6f
+e0
+c8
+d4
+79
+3f
+fe
+04
+20
+20
+06
+f7
+6f
+e0
+c4
+ae
+c1
+80
+00
+00
+20
+40
+3f
+a5
+6f
+e0
+c9
+2c
+c0
+05
+87
+08
+20
+20
+42
+83
+20
+40
+43
+04
+6f
+e0
+c9
+15
+c0
+7f
+87
+0e
+68
+48
+c9
+15
+20
+40
+60
+fd
+24
+60
+80
+00
+58
+00
+00
+00
+20
+40
+5d
+65
+c0
+ac
+41
+f2
+20
+20
+42
+b9
+6f
+e4
+4b
+bc
+c3
+8c
+80
+00
+c3
+8d
+00
+00
+c3
+8f
+00
+00
+c3
+8f
+80
+00
+6f
+e0
+c9
+2c
+c1
+01
+80
+00
+c1
+05
+80
+00
+20
+40
+47
+58
+20
+60
+00
+00
+20
+40
+07
+1f
+20
+40
+41
+2d
+20
+20
+41
+1e
+6f
+e0
+cb
+f2
+24
+5a
+41
+61
+da
+20
+00
+00
+20
+40
+07
+26
+20
+40
+07
+35
+20
+40
+07
+42
 20
 20
 41
@@ -6974,8 +7330,8 @@
 1c
 20
 40
-06
-f6
+07
+4f
 20
 40
 41
@@ -6994,8 +7350,8 @@
 1d
 20
 40
-06
-f6
+07
+4f
 20
 40
 41
@@ -7014,8 +7370,8 @@
 1e
 20
 40
-06
-f6
+07
+4f
 20
 40
 41
@@ -7058,8 +7414,8 @@
 14
 c0
 7f
-86
-e5
+87
+3e
 20
 20
 41
@@ -7070,8 +7426,8 @@
 11
 20
 40
-06
-f9
+07
+52
 68
 48
 c9
@@ -7110,8 +7466,8 @@
 14
 c0
 7f
-86
-f2
+87
+4b
 20
 20
 41
@@ -7122,8 +7478,8 @@
 12
 20
 40
-06
-f9
+07
+52
 68
 48
 c9
@@ -7167,23 +7523,23 @@
 20
 40
 07
-12
+6b
 20
 40
 07
-02
+5b
 20
 40
 07
-18
+71
 20
 20
-06
-ff
+07
+58
 20
 40
-06
-c6
+07
+1f
 1a
 21
 7e
@@ -7191,7 +7547,7 @@
 c0
 00
 87
-07
+60
 70
 4e
 3c
@@ -7231,15 +7587,15 @@
 c0
 00
 07
-12
+6b
 c0
 00
 87
-14
+6d
 c0
 01
 07
-16
+6f
 20
 60
 00
@@ -7315,7 +7671,7 @@
 c2
 00
 07
-21
+7a
 20
 60
 00
@@ -7331,7 +7687,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7339,7 +7695,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7347,7 +7703,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7355,7 +7711,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7363,7 +7719,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7371,7 +7727,7 @@
 20
 20
 07
-37
+90
 70
 4d
 d1
@@ -7379,7 +7735,7 @@
 20
 20
 07
-37
+90
 20
 75
 80
@@ -7391,7 +7747,7 @@
 20
 20
 07
-37
+90
 68
 48
 cd
@@ -7411,7 +7767,7 @@
 20
 22
 87
-53
+ac
 60
 48
 cd
@@ -7451,19 +7807,19 @@
 20
 40
 07
-55
+ae
 20
 40
 07
-61
+ba
 20
 40
 07
-58
+b1
 24
 22
 87
-45
+9e
 6f
 e2
 0e
@@ -7479,7 +7835,7 @@
 24
 22
 87
-45
+9e
 58
 00
 0e
@@ -7547,7 +7903,7 @@
 c2
 00
 07
-5b
+b4
 ef
 e2
 00
@@ -7592,8 +7948,8 @@
 20
 3f
 a5
-f2
-8f
+5c
+0d
 aa
 55
 40
@@ -7735,7 +8091,7 @@
 4b
 04
 09
-06
+26
 00
 00
 12
@@ -9059,14 +9415,14 @@
 00
 d7
 4d
-6f
-29
+d3
+2a
 00
 55
 aa
 aa
 55
-33
+b8
 b0
 ff
 20
@@ -9887,8 +10243,8 @@
 24
 20
 40
-06
-f6
+07
+4f
 20
 40
 04
@@ -10091,8 +10447,8 @@
 00
 f5
 8a
-8d
-6e
+8e
+c7
 20
 20
 00
@@ -10119,8 +10475,8 @@
 07
 c0
 01
-86
-fc
+87
+55
 6f
 e4
 4b
@@ -10347,8 +10703,8 @@
 00
 fd
 39
-13
-0f
+14
+68
 20
 20
 00
@@ -10609,5 +10965,5 @@
 00
 00
 00
-61
-9a
+ae
+0f
Index: output/memmap.format
===================================================================
--- /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/memmap.format	(revision 5300)
+++ /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/memmap.format	(working copy)
@@ -2351,6 +2351,7 @@
 0x4ec2 mem_store_key_info_delay_timer_init
 0x4ec3 mem_key_info_store_flag
 0x4ec4 mem_mouse_key_fuction_info_temp
+0x4ece mem_mouse_key_bit_index_value
 0x48d4 mem_remote_car_hard_soft_switch
 0x48d5 mem_remote_car_queue_each_size
 0x48d6 mem_remote_car_queue_length
Index: output/program.lis
===================================================================
--- /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/program.lis	(revision 5300)
+++ /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/program.lis	(working copy)
@@ -82,12 +82,12 @@
 0049 c061839b beq patch18_3 ,p_mouse_start_work 
 004a c0630392 beq patch18_6 ,p_mouse_app_enter_hibernate 
 004b c0638397 beq patch18_7 ,p_mouse_before_hibernate 
-004c c064072c beq patch19_0 ,p_mouse_setgpio_hibernate 
+004c c0640785 beq patch19_0 ,p_mouse_setgpio_hibernate 
 004d c064849d beq patch19_1 ,p_mouse_lpm_before_common 
 004e c0668695 beq patch19_5 ,p_mouse_motion 
 004f c06704e5 beq patch19_6 ,p_mouse_dpi_process 
 0050 c06784ec beq patch19_7 ,p_mouse_seting_dpi 
-0051 c06806c6 beq patch1a_0 ,p_mouse_check_key_gpio 
+0051 c068071f beq patch1a_0 ,p_mouse_check_key_gpio 
 0052 c0690475 beq patch1a_2 ,p_mouse_init_sunt 
 0053 c0698485 beq patch1a_3 ,p_mouse_sensor_poweron 
 0054 c06a84fe beq patch1a_5 ,p_mouse_priority_bb_event 
@@ -97,7 +97,7 @@
 0058 c070019b beq patch1c_0 ,p_mouse_led_off 
 0059 c0708198 beq patch1c_1 ,p_mouse_led_on 
 005a c06b060a beq patch1a_6 ,p_mouse_le 
-005b c06c8732 beq patch1b_1 ,p_mouse_start_discovery 
+005b c06c878b beq patch1b_1 ,p_mouse_start_discovery 
 005c c06d0569 beq patch1b_2 ,p_mouse_stop_discovery 
 005d c06e0453 beq patch1b_4 ,p_mouse_store_device_info 
 005e 2020137e branch loop 
@@ -709,8 +709,8 @@
 
 p_mouse_init:
 020c 20406e5e call enable_authrom 
-020d 20400725 call p_mouse_setting_config 
-020e 20400734 call p_mouse_report_param_set 
+020d 2040077e call p_mouse_setting_config 
+020e 2040078d call p_mouse_report_param_set 
 020f 204041e7 call mouse_init_sunt 
 0210 20758000 rtn wake 
 0211 204004ee call p_mouse_seting_sensor_type 
@@ -1221,7 +1221,7 @@
 0394 c2818395 bbit1 3 ,p_mouse_app_enter_hibernate_set 
 
 p_mouse_app_enter_hibernate_set:
-0395 2040072c call p_mouse_setgpio_hibernate 
+0395 20400785 call p_mouse_setgpio_hibernate 
 0396 20203289 branch app_enter_hibernate 
 
 p_mouse_before_hibernate:
@@ -1231,7 +1231,7 @@
 039a 20600000 rtn 
 
 p_mouse_start_work:
-039b 20200728 branch p_mouse_start_work_next 
+039b 20200781 branch p_mouse_start_work_next 
 
 p_mouse_bb_event_timer:
 039c 204022e1 call g24_pair_timeout_timer 
@@ -1706,7 +1706,7 @@
 
 p_mouse_3io6key_dpi_check:
 04e1 6fe0c913 fetch 1 ,mem_dpi_button_gpio 
-04e2 204006f9 call p_mouse_gpio_config_output_low 
+04e2 20400752 call p_mouse_gpio_config_output_low 
 04e3 6848c913 fetcht 1 ,mem_dpi_button_gpio 
 04e4 202041d5 branch mouse_3io6key_check 
 
@@ -1753,11 +1753,11 @@
 
 p_mouse_priority_bb_event:
 04fe 1a627e00 copy regc ,pdata 
-04ff c01e072e beq bt_evt_24g_attempt_success ,p_mouse_24g_attempt_success 
-0500 c01c872a beq bt_evt_24g_pairing_complete ,p_mouse_24g_pairing_complete 
+04ff c01e0787 beq bt_evt_24g_attempt_success ,p_mouse_24g_attempt_success 
+0500 c01c8783 beq bt_evt_24g_pairing_complete ,p_mouse_24g_pairing_complete 
 0501 c01d0511 beq bt_evt_24g_attempt_fail ,p_mouse_24g_attempt_fail 
 0502 c0190559 beq bt_evt_le_start_enc ,p_mouse_le_ll_start_encryt 
-0503 c00a8730 beq bt_evt_le_disconnected ,p_mouse_le_bb_disconnected 
+0503 c00a8789 beq bt_evt_le_disconnected ,p_mouse_le_bb_disconnected 
 0504 c00a0565 beq bt_evt_le_connected ,p_mouse_le_bb_event_connected 
 0505 c0200560 beq bt_evt_le_parse_conn_papa_update_rsp ,p_mouse_le_conn_param_update_rsp_recieved 
 0506 c0010508 beq bt_evt_bb_disconnected ,p_mouse_bb_disconnected 
@@ -1818,7 +1818,7 @@
 0531 704c3201 jam 1 ,mem_long_sleep_flag 
 0532 204002cb call p_send_time_long_wake 
 0533 6fe0cbf2 fetch 1 ,mem_sensor_shutdown_flag 
-0534 245a072c ncall p_mouse_setgpio_hibernate ,blank 
+0534 245a0785 ncall p_mouse_setgpio_hibernate ,blank 
 0535 6fe4485f fetch 8 ,mem_24g_enter_hibernate 
 0536 202026bf branch g24_long_seep2 
 
@@ -2292,295 +2292,414 @@
 0695 78547c00 disable user 
 0696 58000000 setarg 0 
 0697 67e348d5 store 6 ,mem_mouse_x 
-0698 204006a9 call p_mouse_check_sensor_data 
+0698 20400702 call p_mouse_check_sensor_data 
 0699 58000089 setarg 0x0089 
 069a 20405d5e call twspi_write 
 069b 204004ee call p_mouse_seting_sensor_type 
 069c 20403fbe call mouse_zwheel 
 069d 20403fc3 call mouse_t_zwheel 
-069e 204006c3 call p_mouse_key 
+069e 2040071c call p_mouse_key 
 069f 6fe0c8d4 fetch 1 ,mem_mouse_key 
 06a0 1fe17e1f and_into 0x1f ,pdata 
 06a1 67e0c8d4 store 1 ,mem_mouse_key 
-06a2 243406a7 nbranch p_mouse_drawing_optima_init ,user 
-06a3 704de900 jam 0 ,mem_device_tx_heart_data_flag 
-06a4 704de401 jam 1 ,mem_24g_rf_data_flag 
-06a5 204006b9 call p_mouse_drawing_optima 
-06a6 20204584 branch mouse_no_data_timer_init 
+06a2 204006aa call p_mouse_key_flag_check 
+06a3 243406a8 nbranch p_mouse_drawing_optima_init ,user 
+06a4 704de900 jam 0 ,mem_device_tx_heart_data_flag 
+06a5 704de401 jam 1 ,mem_24g_rf_data_flag 
+06a6 20400712 call p_mouse_drawing_optima 
+06a7 20204584 branch mouse_no_data_timer_init 
 
 p_mouse_drawing_optima_init:
-06a7 704de400 jam 0 ,mem_24g_rf_data_flag 
-06a8 20204766 branch mouse_drawing_optima_init 
+06a8 704de400 jam 0 ,mem_24g_rf_data_flag 
+06a9 20204766 branch mouse_drawing_optima_init 
+
+p_mouse_key_flag_check:
+06aa 704ece02 jam 0x02 ,mem_mouse_key_bit_index_value 
+06ab d8c04e48 arg mem_mouse_rkey_fuction_info ,contr 
+06ac 204006b6 call p_mouse_key_flag_check_interface 
+06ad 704ece04 jam 0x04 ,mem_mouse_key_bit_index_value 
+06ae d8c04e3e arg mem_mouse_mkey_fuction_info ,contr 
+06af 204006b6 call p_mouse_key_flag_check_interface 
+06b0 704ece08 jam 0x08 ,mem_mouse_key_bit_index_value 
+06b1 d8c04e5c arg mem_mouse_b5_fuction_info ,contr 
+06b2 204006b6 call p_mouse_key_flag_check_interface 
+06b3 704ece10 jam 0x10 ,mem_mouse_key_bit_index_value 
+06b4 d8c04e52 arg mem_mouse_b4_fuction_info ,contr 
+06b5 202006b6 branch p_mouse_key_flag_check_interface 
+
+p_mouse_key_flag_check_interface:
+06b6 d8a04ec4 arg mem_mouse_key_fuction_info_temp ,contw 
+06b7 20400179 call p_memcpy_10 
+06b8 6fe0cec4 fetch 1 ,mem_mouse_key_fuction_info_temp 
+06b9 c00006bc beq ms_key ,p_mouse_mkey_ms_fuction_check 
+06ba c00086df beq kb_key ,p_mouse_mkey_kb_fuction_check 
+06bb 20600000 rtn 
+
+p_mouse_mkey_ms_fuction_check:
+06bc 6fe0cec5 fetch 1 ,mem_mouse_key_fuction_info_temp + 1 
+06bd 207a0000 rtn blank 
+06be 6848cece fetcht 1 ,mem_mouse_key_bit_index_value 
+06bf 98467c00 isub temp ,null 
+06c0 20628000 rtn zero 
+06c1 c28086c6 bbit1 mouse_r_key ,p_mouse_ms_rkey_fuction_check 
+06c2 c28106cd bbit1 mouse_m_key ,p_mouse_ms_mkey_fuction_check 
+06c3 c28186d3 bbit1 mouse_bk_key ,p_mouse_ms_bk_fuction_check 
+06c4 c28206d9 bbit1 mouse_fw_key ,p_mouse_ms_fw_fuction_check 
+06c5 20600000 rtn 
+
+p_mouse_ms_rkey_fuction_check:
+06c6 6848c8d4 fetcht 1 ,mem_mouse_key 
+06c7 6fe0cece fetch 1 ,mem_mouse_key_bit_index_value 
+06c8 98417e00 iand temp ,pdata 
+06c9 207a0000 rtn blank 
+06ca 79200401 set1 mouse_r_key ,temp 
+
+p_mouse_storet_mouse_key:
+06cb 6048c8d4 storet 1 ,mem_mouse_key 
+06cc 20600000 rtn 
+
+p_mouse_ms_mkey_fuction_check:
+06cd 6848c8d4 fetcht 1 ,mem_mouse_key 
+06ce 6fe0cece fetch 1 ,mem_mouse_key_bit_index_value 
+06cf 98417e00 iand temp ,pdata 
+06d0 207a0000 rtn blank 
+06d1 79200402 set1 mouse_m_key ,temp 
+06d2 202006cb branch p_mouse_storet_mouse_key 
+
+p_mouse_ms_bk_fuction_check:
+06d3 6848c8d4 fetcht 1 ,mem_mouse_key 
+06d4 6fe0cece fetch 1 ,mem_mouse_key_bit_index_value 
+06d5 98417e00 iand temp ,pdata 
+06d6 207a0000 rtn blank 
+06d7 79200403 set1 mouse_bk_key ,temp 
+06d8 202006cb branch p_mouse_storet_mouse_key 
+
+p_mouse_ms_fw_fuction_check:
+06d9 6848c8d4 fetcht 1 ,mem_mouse_key 
+06da 6fe0cece fetch 1 ,mem_mouse_key_bit_index_value 
+06db 98417e00 iand temp ,pdata 
+06dc 207a0000 rtn blank 
+06dd 79200404 set1 mouse_fw_key ,temp 
+06de 202006cb branch p_mouse_storet_mouse_key 
+
+p_mouse_mkey_kb_fuction_check:
+06df 58000000 setarg 0 
+06e0 67e44be6 store 8 ,mem_customer_key_release 
+06e1 6fe0cec5 fetch 1 ,mem_mouse_key_fuction_info_temp + 1 
+06e2 205a06f3 call p_mouse_customer_key_type_store ,blank 
+06e3 6848c8d4 fetcht 1 ,mem_mouse_key 
+06e4 6fe0cece fetch 1 ,mem_mouse_key_bit_index_value 
+06e5 98417e00 iand temp ,pdata 
+06e6 203a41b6 branch mouse_customerkey_release_set ,blank 
+06e7 6848cece fetcht 1 ,mem_mouse_key_bit_index_value 
+06e8 284ffe01 isolate1 mouse_r_key ,temp 
+06e9 204086f5 call p_mouse_rkey_clear_set ,true 
+06ea 284ffe02 isolate1 mouse_m_key ,temp 
+06eb 204086f9 call p_mouse_mkey_clear_set ,true 
+06ec 284ffe03 isolate1 mouse_bk_key ,temp 
+06ed 204086fc call p_mouse_bk_clear_set ,true 
+06ee 284ffe04 isolate1 mouse_fw_key ,temp 
+06ef 204086ff call p_mouse_fw_clear_set ,true 
+06f0 6fe44ec5 fetch 8 ,mem_mouse_key_fuction_info_temp + 1 
+06f1 67e44bdd store 8 ,mem_customer_key_press 
+06f2 202041ba branch mouse_customerkey_press 
+
+p_mouse_customer_key_type_store:
+06f3 67e0cbe6 store 1 ,mem_customer_key_release 
+06f4 20600000 rtn 
+
+p_mouse_rkey_clear_set:
+06f5 6fe0c8d4 fetch 1 ,mem_mouse_key 
+06f6 793ffe01 set0 mouse_r_key ,pdata 
+
+p_mouse_store_mouse_key:
+06f7 67e0c8d4 store 1 ,mem_mouse_key 
+06f8 20600000 rtn 
+
+p_mouse_mkey_clear_set:
+06f9 6fe0c8d4 fetch 1 ,mem_mouse_key 
+06fa 793ffe02 set0 mouse_m_key ,pdata 
+06fb 202006f7 branch p_mouse_store_mouse_key 
+
+p_mouse_bk_clear_set:
+06fc 6fe0c8d4 fetch 1 ,mem_mouse_key 
+06fd 793ffe03 set0 mouse_bk_key ,pdata 
+06fe 202006f7 branch p_mouse_store_mouse_key 
+
+p_mouse_fw_clear_set:
+06ff 6fe0c8d4 fetch 1 ,mem_mouse_key 
+0700 793ffe04 set0 mouse_fw_key ,pdata 
+0701 202006f7 branch p_mouse_store_mouse_key 
 
 p_mouse_check_sensor_data:
-06a9 6fe0c4ae fetch 1 ,mem_spi_write_flash_sm 
-06aa c1800000 rtnne flash_sm_no_buys 
-06ab 20403fa5 call mouse_sensor_spi_init 
-06ac 6fe0c92c fetch 1 ,mem_config_sensor_type 
-06ad c00586af beq ka8g2 ,p_mouse_ka8g2_sensor_motion 
-06ae 20204283 branch mouse_check_sensor_data + 3 
+0702 6fe0c4ae fetch 1 ,mem_spi_write_flash_sm 
+0703 c1800000 rtnne flash_sm_no_buys 
+0704 20403fa5 call mouse_sensor_spi_init 
+0705 6fe0c92c fetch 1 ,mem_config_sensor_type 
+0706 c0058708 beq ka8g2 ,p_mouse_ka8g2_sensor_motion 
+0707 20204283 branch mouse_check_sensor_data + 3 
 
 p_mouse_ka8g2_sensor_motion:
-06af 20404304 call mouse_clear_sensor_data 
-06b0 6fe0c915 fetch 1 ,mem_sensor_motion_gpio 
-06b1 c07f86b5 beq gpio_disable ,p_mouse_ka8g2_sensor_motion_1 
-06b2 6848c915 fetcht 1 ,mem_sensor_motion_gpio 
-06b3 204060fd call gpio_get_bit 
-06b4 24608000 nrtn true 
+0708 20404304 call mouse_clear_sensor_data 
+0709 6fe0c915 fetch 1 ,mem_sensor_motion_gpio 
+070a c07f870e beq gpio_disable ,p_mouse_ka8g2_sensor_motion_1 
+070b 6848c915 fetcht 1 ,mem_sensor_motion_gpio 
+070c 204060fd call gpio_get_bit 
+070d 24608000 nrtn true 
 
 p_mouse_ka8g2_sensor_motion_1:
-06b5 58000000 setarg pan_reg_pid_l 
-06b6 20405d65 call twspi_read 
-06b7 c0ac41f2 bne pka8g2_id1 ,mouse_twspi_reset 
-06b8 202042b9 branch mouse_p3212_sensor_motion_2 
+070e 58000000 setarg pan_reg_pid_l 
+070f 20405d65 call twspi_read 
+0710 c0ac41f2 bne pka8g2_id1 ,mouse_twspi_reset 
+0711 202042b9 branch mouse_p3212_sensor_motion_2 
 
 p_mouse_drawing_optima:
-06b9 6fe44bbc fetch mouse_flag_len ,mem_mouse_flag 
-06ba c38c8000 rtnbit1 mouse_enable_24g_500hz 
-06bb c38d0000 rtnbit1 mouse_enable_24g_1000 
-06bc c38f0000 rtnbit1 mouse_enable_usb_500 
-06bd c38f8000 rtnbit1 mouse_enable_usb_1000 
-06be 6fe0c92c fetch 1 ,mem_config_sensor_type 
-06bf c1018000 rtneq p3212 
-06c0 c1058000 rtneq ka8g2 
-06c1 20404758 call mouse_drawing_optima 
-06c2 20600000 rtn 
+0712 6fe44bbc fetch mouse_flag_len ,mem_mouse_flag 
+0713 c38c8000 rtnbit1 mouse_enable_24g_500hz 
+0714 c38d0000 rtnbit1 mouse_enable_24g_1000 
+0715 c38f0000 rtnbit1 mouse_enable_usb_500 
+0716 c38f8000 rtnbit1 mouse_enable_usb_1000 
+0717 6fe0c92c fetch 1 ,mem_config_sensor_type 
+0718 c1018000 rtneq p3212 
+0719 c1058000 rtneq ka8g2 
+071a 20404758 call mouse_drawing_optima 
+071b 20600000 rtn 
 
 p_mouse_key:
-06c3 204006c6 call p_mouse_check_key_gpio 
-06c4 2040412d call mouse_ghost_key_check 
-06c5 2020411e branch mouse_key + 2 
+071c 2040071f call p_mouse_check_key_gpio 
+071d 2040412d call mouse_ghost_key_check 
+071e 2020411e branch mouse_key + 2 
 
 p_mouse_check_key_gpio:
-06c6 6fe0cbf2 fetch 1 ,mem_sensor_shutdown_flag 
-06c7 245a4161 ncall mouse_check_key_gpio_once ,blank 
-06c8 da200000 arg 0 ,rega 
-06c9 204006cd call p_mouse_check_lkey_gpio 
-06ca 204006dc call p_mouse_check_bkkey_gpio 
-06cb 204006e9 call p_mouse_check_fwkey_gpio 
-06cc 2020415e branch mouse_check_key_gpio_next 
+071f 6fe0cbf2 fetch 1 ,mem_sensor_shutdown_flag 
+0720 245a4161 ncall mouse_check_key_gpio_once ,blank 
+0721 da200000 arg 0 ,rega 
+0722 20400726 call p_mouse_check_lkey_gpio 
+0723 20400735 call p_mouse_check_bkkey_gpio 
+0724 20400742 call p_mouse_check_fwkey_gpio 
+0725 2020415e branch mouse_check_key_gpio_next 
 
 p_mouse_check_lkey_gpio:
-06cd 6fe0c91c fetch 1 ,mem_lbutton_gpio 
-06ce 204006f6 call p_mouse_gpio_config_output_high 
-06cf 20404164 call mouse_check_lkey_gpio 
-06d0 6848c91c fetcht 1 ,mem_lbutton_gpio 
-06d1 20403f96 call mouse_gpio_config_input_pu 
+0726 6fe0c91c fetch 1 ,mem_lbutton_gpio 
+0727 2040074f call p_mouse_gpio_config_output_high 
+0728 20404164 call mouse_check_lkey_gpio 
+0729 6848c91c fetcht 1 ,mem_lbutton_gpio 
+072a 20403f96 call mouse_gpio_config_input_pu 
 
 p_mouse_check_rkey_gpio:
-06d2 6fe0c91d fetch 1 ,mem_rbutton_gpio 
-06d3 204006f6 call p_mouse_gpio_config_output_high 
-06d4 2040416a call mouse_check_rkey_gpio 
-06d5 6848c91d fetcht 1 ,mem_rbutton_gpio 
-06d6 20403f96 call mouse_gpio_config_input_pu 
+072b 6fe0c91d fetch 1 ,mem_rbutton_gpio 
+072c 2040074f call p_mouse_gpio_config_output_high 
+072d 2040416a call mouse_check_rkey_gpio 
+072e 6848c91d fetcht 1 ,mem_rbutton_gpio 
+072f 20403f96 call mouse_gpio_config_input_pu 
 
 p_mouse_check_mkey_gpio:
-06d7 6fe0c91e fetch 1 ,mem_mbutton_gpio 
-06d8 204006f6 call p_mouse_gpio_config_output_high 
-06d9 20404170 call mouse_check_mkey_gpio 
-06da 6848c91e fetcht 1 ,mem_mbutton_gpio 
-06db 20203f96 branch mouse_gpio_config_input_pu 
+0730 6fe0c91e fetch 1 ,mem_mbutton_gpio 
+0731 2040074f call p_mouse_gpio_config_output_high 
+0732 20404170 call mouse_check_mkey_gpio 
+0733 6848c91e fetcht 1 ,mem_mbutton_gpio 
+0734 20203f96 branch mouse_gpio_config_input_pu 
 
 p_mouse_check_bkkey_gpio:
-06dc 6fe0c911 fetch 1 ,mem_bk_button_gpio 
-06dd c17f8000 rtneq gpio_disable 
-06de 704ba703 jam mouse_bk_key ,mem_mouse_key_temp 
-06df 6fe0cba2 fetch 1 ,mem_mouse_bkkey_press_status 
-06e0 1fe22600 copy pdata ,regc 
-06e1 6848c911 fetcht 1 ,mem_bk_button_gpio 
-06e2 6fe0c914 fetch 1 ,mem_matrix_public_gpio 
-06e3 c07f86e5 beq gpio_disable ,p_mouse_3io6key_bk_check 
-06e4 2020417e branch mouse_check_bkkey_gpio_next 
+0735 6fe0c911 fetch 1 ,mem_bk_button_gpio 
+0736 c17f8000 rtneq gpio_disable 
+0737 704ba703 jam mouse_bk_key ,mem_mouse_key_temp 
+0738 6fe0cba2 fetch 1 ,mem_mouse_bkkey_press_status 
+0739 1fe22600 copy pdata ,regc 
+073a 6848c911 fetcht 1 ,mem_bk_button_gpio 
+073b 6fe0c914 fetch 1 ,mem_matrix_public_gpio 
+073c c07f873e beq gpio_disable ,p_mouse_3io6key_bk_check 
+073d 2020417e branch mouse_check_bkkey_gpio_next 
 
 p_mouse_3io6key_bk_check:
-06e5 6fe0c911 fetch 1 ,mem_bk_button_gpio 
-06e6 204006f9 call p_mouse_gpio_config_output_low 
-06e7 6848c911 fetcht 1 ,mem_bk_button_gpio 
-06e8 2020418b branch mouse_3io6key_bk_check 
+073e 6fe0c911 fetch 1 ,mem_bk_button_gpio 
+073f 20400752 call p_mouse_gpio_config_output_low 
+0740 6848c911 fetcht 1 ,mem_bk_button_gpio 
+0741 2020418b branch mouse_3io6key_bk_check 
 
 p_mouse_check_fwkey_gpio:
-06e9 6fe0c912 fetch 1 ,mem_fw_button_gpio 
-06ea c17f8000 rtneq gpio_disable 
-06eb 704ba704 jam mouse_fw_key ,mem_mouse_key_temp 
-06ec 6fe0cba3 fetch 1 ,mem_mouse_fwkey_press_status 
-06ed 1fe22600 copy pdata ,regc 
-06ee 6848c912 fetcht 1 ,mem_fw_button_gpio 
-06ef 6fe0c914 fetch 1 ,mem_matrix_public_gpio 
-06f0 c07f86f2 beq gpio_disable ,p_mouse_3io6key_fw_check 
-06f1 20204197 branch mouse_check_fwkey_gpio_next 
+0742 6fe0c912 fetch 1 ,mem_fw_button_gpio 
+0743 c17f8000 rtneq gpio_disable 
+0744 704ba704 jam mouse_fw_key ,mem_mouse_key_temp 
+0745 6fe0cba3 fetch 1 ,mem_mouse_fwkey_press_status 
+0746 1fe22600 copy pdata ,regc 
+0747 6848c912 fetcht 1 ,mem_fw_button_gpio 
+0748 6fe0c914 fetch 1 ,mem_matrix_public_gpio 
+0749 c07f874b beq gpio_disable ,p_mouse_3io6key_fw_check 
+074a 20204197 branch mouse_check_fwkey_gpio_next 
 
 p_mouse_3io6key_fw_check:
-06f2 6fe0c912 fetch 1 ,mem_fw_button_gpio 
-06f3 204006f9 call p_mouse_gpio_config_output_low 
-06f4 6848c912 fetcht 1 ,mem_fw_button_gpio 
-06f5 202041a4 branch mouse_3io6key_fw_check 
+074b 6fe0c912 fetch 1 ,mem_fw_button_gpio 
+074c 20400752 call p_mouse_gpio_config_output_low 
+074d 6848c912 fetcht 1 ,mem_fw_button_gpio 
+074e 202041a4 branch mouse_3io6key_fw_check 
 
 p_mouse_gpio_config_output_high:
-06f6 c17f8000 rtneq gpio_disable 
-06f7 d840003f arg gpcfg_output_high ,temp 
-06f8 2020612c branch gpio_config_function_int 
+074f c17f8000 rtneq gpio_disable 
+0750 d840003f arg gpcfg_output_high ,temp 
+0751 2020612c branch gpio_config_function_int 
 
 p_mouse_gpio_config_output_low:
-06f9 c17f8000 rtneq gpio_disable 
-06fa d840003e arg gpcfg_output_low ,temp 
-06fb 2020612c branch gpio_config_function_int 
+0752 c17f8000 rtneq gpio_disable 
+0753 d840003e arg gpcfg_output_low ,temp 
+0754 2020612c branch gpio_config_function_int 
 
 p_mouse_freq_test_mode:
-06fc 70486801 jam 0x01 ,mem_24g_tx_phy 
-06fd 704e3d00 jam 0 ,mem_mouse_ch_count 
-06fe 20400712 call p_mouse_set_ch_l 
+0755 70486801 jam 0x01 ,mem_24g_tx_phy 
+0756 704e3d00 jam 0 ,mem_mouse_ch_count 
+0757 2040076b call p_mouse_set_ch_l 
 
 p_mouse_freq_test_mode_loop:
-06ff 20400702 call p_mouse_freq_test_mode_state_check 
-0700 20400718 call p_mouse_freq_test_single_wave 
-0701 202006ff branch p_mouse_freq_test_mode_loop 
+0758 2040075b call p_mouse_freq_test_mode_state_check 
+0759 20400771 call p_mouse_freq_test_single_wave 
+075a 20200758 branch p_mouse_freq_test_mode_loop 
 
 p_mouse_freq_test_mode_state_check:
-0702 204006c6 call p_mouse_check_key_gpio 
-0703 1a217e07 and rega ,0x07 ,pdata 
-0704 c0008707 beq mouse_l_button ,p_mouse_change_freq_set 
-0705 704e3c00 jam 0 ,mem_mouse_ch_set_flag 
-0706 20600000 rtn 
+075b 2040071f call p_mouse_check_key_gpio 
+075c 1a217e07 and rega ,0x07 ,pdata 
+075d c0008760 beq mouse_l_button ,p_mouse_change_freq_set 
+075e 704e3c00 jam 0 ,mem_mouse_ch_set_flag 
+075f 20600000 rtn 
 
 p_mouse_change_freq_set:
-0707 6fe0ce3c fetch 1 ,mem_mouse_ch_set_flag 
-0708 247a0000 nrtn blank 
-0709 704e3c01 jam 1 ,mem_mouse_ch_set_flag 
-070a 6fe0ce3d fetch 1 ,mem_mouse_ch_count 
-070b 1fe0fe01 increase 1 ,pdata 
-070c 1fe17e03 and pdata ,0x03 ,pdata 
-070d 67e0ce3d store 1 ,mem_mouse_ch_count 
-070e c0000712 beq 0 ,p_mouse_set_ch_l 
-070f c0008714 beq 1 ,p_mouse_set_ch_m 
-0710 c0010716 beq 2 ,p_mouse_set_ch_h 
-0711 20600000 rtn 
+0760 6fe0ce3c fetch 1 ,mem_mouse_ch_set_flag 
+0761 247a0000 nrtn blank 
+0762 704e3c01 jam 1 ,mem_mouse_ch_set_flag 
+0763 6fe0ce3d fetch 1 ,mem_mouse_ch_count 
+0764 1fe0fe01 increase 1 ,pdata 
+0765 1fe17e03 and pdata ,0x03 ,pdata 
+0766 67e0ce3d store 1 ,mem_mouse_ch_count 
+0767 c000076b beq 0 ,p_mouse_set_ch_l 
+0768 c000876d beq 1 ,p_mouse_set_ch_m 
+0769 c001076f beq 2 ,p_mouse_set_ch_h 
+076a 20600000 rtn 
 
 p_mouse_set_ch_l:
-0712 70483d00 jam 0 ,mem_24g_ch 
-0713 20600000 rtn 
+076b 70483d00 jam 0 ,mem_24g_ch 
+076c 20600000 rtn 
 
 p_mouse_set_ch_m:
-0714 70483d26 jam 0x26 ,mem_24g_ch 
-0715 20600000 rtn 
+076d 70483d26 jam 0x26 ,mem_24g_ch 
+076e 20600000 rtn 
 
 p_mouse_set_ch_h:
-0716 70483d4c jam 0x4c ,mem_24g_ch 
-0717 20600000 rtn 
+076f 70483d4c jam 0x4c ,mem_24g_ch 
+0770 20600000 rtn 
 
 p_mouse_freq_test_single_wave:
-0718 7041e800 jam tx_power_0db ,mem_tx_power 
-0719 204021f5 call g24_set_freq_tx 
-071a 7843fc00 disable enable_white 
-071b 782efc00 enable encode_fec0 
-071c 78307c00 enable is_tx 
-071d 79202a00 set1 txgfsk ,radio_ctrl 
-071e 70890d22 jam 0x22 ,core_tx_test_mode 
-071f 5800ffff setarg 0xffff 
-0720 1fe27200 copy pdata ,loopcnt 
+0771 7041e800 jam tx_power_0db ,mem_tx_power 
+0772 204021f5 call g24_set_freq_tx 
+0773 7843fc00 disable enable_white 
+0774 782efc00 enable encode_fec0 
+0775 78307c00 enable is_tx 
+0776 79202a00 set1 txgfsk ,radio_ctrl 
+0777 70890d22 jam 0x22 ,core_tx_test_mode 
+0778 5800ffff setarg 0xffff 
+0779 1fe27200 copy pdata ,loopcnt 
 
 p_pnloop_carrier:
-0721 efe08006 ifetch 1 ,contr 
-0722 08008608 inject mod ,8 
-0723 c2000721 loop p_pnloop_carrier 
-0724 20600000 rtn 
+077a efe08006 ifetch 1 ,contr 
+077b 08008608 inject mod ,8 
+077c c200077a loop p_pnloop_carrier 
+077d 20600000 rtn 
 
 p_mouse_setting_config:
-0725 20758000 rtn wake 
-0726 704dd100 jam zcode_00 ,mem_zcode_temp_param0 
-0727 20200737 branch p_zcode_entrance 
+077e 20758000 rtn wake 
+077f 704dd100 jam zcode_00 ,mem_zcode_temp_param0 
+0780 20200790 branch p_zcode_entrance 
 
 p_mouse_start_work_next:
-0728 704dd110 jam zcode_10 ,mem_zcode_temp_param0 
-0729 20200737 branch p_zcode_entrance 
+0781 704dd110 jam zcode_10 ,mem_zcode_temp_param0 
+0782 20200790 branch p_zcode_entrance 
 
 p_mouse_24g_pairing_complete:
-072a 704dd111 jam zcode_11 ,mem_zcode_temp_param0 
-072b 20200737 branch p_zcode_entrance 
+0783 704dd111 jam zcode_11 ,mem_zcode_temp_param0 
+0784 20200790 branch p_zcode_entrance 
 
 p_mouse_setgpio_hibernate:
-072c 704dd120 jam zcode_20 ,mem_zcode_temp_param0 
-072d 20200737 branch p_zcode_entrance 
+0785 704dd120 jam zcode_20 ,mem_zcode_temp_param0 
+0786 20200790 branch p_zcode_entrance 
 
 p_mouse_24g_attempt_success:
-072e 704dd121 jam zcode_21 ,mem_zcode_temp_param0 
-072f 20200737 branch p_zcode_entrance 
+0787 704dd121 jam zcode_21 ,mem_zcode_temp_param0 
+0788 20200790 branch p_zcode_entrance 
 
 p_mouse_le_bb_disconnected:
-0730 704dd130 jam zcode_30 ,mem_zcode_temp_param0 
-0731 20200737 branch p_zcode_entrance 
+0789 704dd130 jam zcode_30 ,mem_zcode_temp_param0 
+078a 20200790 branch p_zcode_entrance 
 
 p_mouse_start_discovery:
-0732 704dd131 jam zcode_31 ,mem_zcode_temp_param0 
-0733 20200737 branch p_zcode_entrance 
+078b 704dd131 jam zcode_31 ,mem_zcode_temp_param0 
+078c 20200790 branch p_zcode_entrance 
 
 p_mouse_report_param_set:
-0734 20758000 rtn wake 
-0735 704dd140 jam zcode_40 ,mem_zcode_temp_param0 
-0736 20200737 branch p_zcode_entrance 
+078d 20758000 rtn wake 
+078e 704dd140 jam zcode_40 ,mem_zcode_temp_param0 
+078f 20200790 branch p_zcode_entrance 
 
 p_zcode_entrance:
-0737 6848cdd1 fetcht 1 ,mem_zcode_temp_param0 
-0738 18518400 rshift4 temp ,temp 
-0739 6fe0cdd6 fetch 1 ,mem_zcode_current_number 
-073a 98467c00 isub temp ,null 
-073b 20228753 branch p_zcode_run ,zero 
-073c 6048cdd6 storet 1 ,mem_zcode_current_number 
-073d 18408401 increase 1 ,temp 
-073e 58000100 setarg zcode_buff_size 
-073f 984f8400 imul32 temp ,temp 
-0740 6fe1cdd7 fetch 3 ,mem_xip_flash_offset 
-0741 98467e00 isub temp ,pdata 
-0742 6849cdda fetcht 3 ,mem_flash_start_addr 
-0743 9840fe00 iadd temp ,pdata 
-0744 67e1cddd store 3 ,mem_flash_address 
+0790 6848cdd1 fetcht 1 ,mem_zcode_temp_param0 
+0791 18518400 rshift4 temp ,temp 
+0792 6fe0cdd6 fetch 1 ,mem_zcode_current_number 
+0793 98467c00 isub temp ,null 
+0794 202287ac branch p_zcode_run ,zero 
+0795 6048cdd6 storet 1 ,mem_zcode_current_number 
+0796 18408401 increase 1 ,temp 
+0797 58000100 setarg zcode_buff_size 
+0798 984f8400 imul32 temp ,temp 
+0799 6fe1cdd7 fetch 3 ,mem_xip_flash_offset 
+079a 98467e00 isub temp ,pdata 
+079b 6849cdda fetcht 3 ,mem_flash_start_addr 
+079c 9840fe00 iadd temp ,pdata 
+079d 67e1cddd store 3 ,mem_flash_address 
 
 p_zcode_read_loop:
-0745 20400755 call p_zcode_buff_clear 
-0746 20400761 call p_read_data_from_flash 
-0747 20400758 call p_zcode_data_check 
-0748 24228745 nbranch p_zcode_read_loop ,zero 
-0749 6fe20e00 fetch 4 ,mem_zcode_buff 
-074a 684a4de0 fetcht 4 ,mem_zcode_head 
-074b 98467c00 isub temp ,null 
-074c 24228745 nbranch p_zcode_read_loop ,zero 
-074d 58000e00 setarg mem_zcode_buff 
-074e 67e141a6 store 2 ,mem_patch_ptr 
-074f 7041a840 jam zcode_code_size ,mem_patch_len 
-0750 20405ca3 call load_ucode 
-0751 58000000 setarg 0 
-0752 67e241a6 store 4 ,mem_patch_ptr 
+079e 204007ae call p_zcode_buff_clear 
+079f 204007ba call p_read_data_from_flash 
+07a0 204007b1 call p_zcode_data_check 
+07a1 2422879e nbranch p_zcode_read_loop ,zero 
+07a2 6fe20e00 fetch 4 ,mem_zcode_buff 
+07a3 684a4de0 fetcht 4 ,mem_zcode_head 
+07a4 98467c00 isub temp ,null 
+07a5 2422879e nbranch p_zcode_read_loop ,zero 
+07a6 58000e00 setarg mem_zcode_buff 
+07a7 67e141a6 store 2 ,mem_patch_ptr 
+07a8 7041a840 jam zcode_code_size ,mem_patch_len 
+07a9 20405ca3 call load_ucode 
+07aa 58000000 setarg 0 
+07ab 67e241a6 store 4 ,mem_patch_ptr 
 
 p_zcode_run:
-0753 6fe0cdd1 fetch 1 ,mem_zcode_temp_param0 
-0754 20200001 branch p_zcode 
+07ac 6fe0cdd1 fetch 1 ,mem_zcode_temp_param0 
+07ad 20200001 branch p_zcode 
 
 p_zcode_buff_clear:
-0755 d8a00e00 arg mem_zcode_buff ,contw 
-0756 df200100 arg 256 ,loopcnt 
-0757 20207d9b branch clear_mem 
+07ae d8a00e00 arg mem_zcode_buff ,contw 
+07af df200100 arg 256 ,loopcnt 
+07b0 20207d9b branch clear_mem 
 
 p_zcode_data_check:
-0758 d8c00e00 arg mem_zcode_buff ,contr 
-0759 da200000 arg 0 ,rega 
-075a df20003f arg 63 ,loopcnt 
+07b1 d8c00e00 arg mem_zcode_buff ,contr 
+07b2 da200000 arg 0 ,rega 
+07b3 df20003f arg 63 ,loopcnt 
 
 p_zcode_data_loop:
-075b efe20006 ifetch 4 ,contr 
-075c 9a20a200 iadd rega ,rega 
-075d c200075b loop p_zcode_data_loop 
-075e efe20006 ifetch 4 ,contr 
-075f 9a267c00 isub rega ,null 
-0760 20600000 rtn 
+07b4 efe20006 ifetch 4 ,contr 
+07b5 9a20a200 iadd rega ,rega 
+07b6 c20007b4 loop p_zcode_data_loop 
+07b7 efe20006 ifetch 4 ,contr 
+07b8 9a267c00 isub rega ,null 
+07b9 20600000 rtn 
 
 p_read_data_from_flash:
-0761 20405daf call spid_init_flash 
-0762 2040464a call mouse_spid_flash_release_form_powerdown 
-0763 6fe1cddd fetch 3 ,mem_flash_address 
-0764 d8400100 arg zcode_buff_size ,temp 
-0765 da200e00 arg mem_zcode_buff ,rega 
-0766 20405dd2 call spid_read_flash 
-0767 20404651 call mouse_spid_flash_powerdown 
-0768 20203fa5 branch mouse_sensor_spi_init 
+07ba 20405daf call spid_init_flash 
+07bb 2040464a call mouse_spid_flash_release_form_powerdown 
+07bc 6fe1cddd fetch 3 ,mem_flash_address 
+07bd d8400100 arg zcode_buff_size ,temp 
+07be da200e00 arg mem_zcode_buff ,rega 
+07bf 20405dd2 call spid_read_flash 
+07c0 20404651 call mouse_spid_flash_powerdown 
+07c1 20203fa5 branch mouse_sensor_spi_init 
               org 0x800
 
 start:
@@ -22120,6 +22239,8 @@
 41b3 67e0cba6 store 1 ,mem_mouse_customerkey_press_status 
 41b4 1a227e00 copy rega ,pdata 
 41b5 c283c1ba bbit1 mouse_customer_key ,mouse_customerkey_press 
+
+mouse_customerkey_release_set:
 41b6 204041bd call mouse_customerkey_release 
 
 mouse_check_customerkey_gpio_exit:
@@ -43060,7 +43181,7 @@
 z_mouse_start_work_next:
 20004 20404150 call mouse_key_check_once 
 20005 1a217e07 and rega ,0x07 ,pdata 
-20006 c00186fc beq mouse_lr_button ,p_mouse_freq_test_mode 
+20006 c0018755 beq mouse_lr_button ,p_mouse_freq_test_mode 
 20007 6fe44bbc fetch mouse_flag_len ,mem_mouse_flag 
 20008 c2978026 bbit1 mouse_enable_24g_first_auto_pairing ,z_mouse_24g_first_start_auto_pair_mode 
 20009 6fe0c93d fetch 1 ,mem_device_flag 
@@ -43139,7 +43260,7 @@
 30009 20407f52 call clear_wake 
 3000a 20404055 call mouse_before_hibernate_wheel_gpio_set 
 3000b 6fe0c924 fetch 1 ,mem_mouse_sensor_sdio_gpio 
-3000c 204006f6 call p_mouse_gpio_config_output_high 
+3000c 2040074f call p_mouse_gpio_config_output_high 
 3000d 2040049d call p_mouse_lpm_before_common 
 3000e 20403e72 call mouse_gpio_pu_idle 
 3000f d8400013 arg 19 ,temp 
Index: output/ramcode.rom
===================================================================
--- /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/ramcode.rom	(revision 5300)
+++ /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/ramcode.rom	(working copy)
@@ -74,12 +74,12 @@
 c061839b
 c0630392
 c0638397
-c064072c
+c0640785
 c064849d
 c0668695
 c06704e5
 c06784ec
-c06806c6
+c068071f
 c0690475
 c0698485
 c06a84fe
@@ -89,7 +89,7 @@
 c070019b
 c0708198
 c06b060a
-c06c8732
+c06c878b
 c06d0569
 c06e0453
 2020137e
@@ -523,8 +523,8 @@
 708a3a00
 20201226
 20406e5e
-20400725
-20400734
+2040077e
+2040078d
 204041e7
 20758000
 204004ee
@@ -915,13 +915,13 @@
 58000006
 20405d65
 c2818395
-2040072c
+20400785
 20203289
 20403e5f
 6848c915
 204060da
 20600000
-20200728
+20200781
 204022e1
 2040255f
 204003b0
@@ -1248,7 +1248,7 @@
 c07f84e1
 2020407f
 6fe0c913
-204006f9
+20400752
 6848c913
 202041d5
 204040b2
@@ -1277,11 +1277,11 @@
 704cb601
 20600000
 1a627e00
-c01e072e
-c01c872a
+c01e0787
+c01c8783
 c01d0511
 c0190559
-c00a8730
+c00a8789
 c00a0565
 c0200560
 c0010508
@@ -1330,7 +1330,7 @@
 704c3201
 204002cb
 6fe0cbf2
-245a072c
+245a0785
 6fe4485f
 202026bf
 6fe0cde9
@@ -1686,32 +1686,121 @@
 78547c00
 58000000
 67e348d5
-204006a9
+20400702
 58000089
 20405d5e
 204004ee
 20403fbe
 20403fc3
-204006c3
+2040071c
 6fe0c8d4
 1fe17e1f
 67e0c8d4
-243406a7
+204006aa
+243406a8
 704de900
 704de401
-204006b9
+20400712
 20204584
 704de400
 20204766
+704ece02
+d8c04e48
+204006b6
+704ece04
+d8c04e3e
+204006b6
+704ece08
+d8c04e5c
+204006b6
+704ece10
+d8c04e52
+202006b6
+d8a04ec4
+20400179
+6fe0cec4
+c00006bc
+c00086df
+20600000
+6fe0cec5
+207a0000
+6848cece
+98467c00
+20628000
+c28086c6
+c28106cd
+c28186d3
+c28206d9
+20600000
+6848c8d4
+6fe0cece
+98417e00
+207a0000
+79200401
+6048c8d4
+20600000
+6848c8d4
+6fe0cece
+98417e00
+207a0000
+79200402
+202006cb
+6848c8d4
+6fe0cece
+98417e00
+207a0000
+79200403
+202006cb
+6848c8d4
+6fe0cece
+98417e00
+207a0000
+79200404
+202006cb
+58000000
+67e44be6
+6fe0cec5
+205a06f3
+6848c8d4
+6fe0cece
+98417e00
+203a41b6
+6848cece
+284ffe01
+204086f5
+284ffe02
+204086f9
+284ffe03
+204086fc
+284ffe04
+204086ff
+6fe44ec5
+67e44bdd
+202041ba
+67e0cbe6
+20600000
+6fe0c8d4
+793ffe01
+67e0c8d4
+20600000
+6fe0c8d4
+793ffe02
+202006f7
+6fe0c8d4
+793ffe03
+202006f7
+6fe0c8d4
+793ffe04
+202006f7
 6fe0c4ae
 c1800000
 20403fa5
 6fe0c92c
-c00586af
+c0058708
 20204283
 20404304
 6fe0c915
-c07f86b5
+c07f870e
 6848c915
 204060fd
 24608000
@@ -1729,28 +1818,28 @@
 c1058000
 20404758
 20600000
-204006c6
+2040071f
 2040412d
 2020411e
 6fe0cbf2
 245a4161
 da200000
-204006cd
-204006dc
-204006e9
+20400726
+20400735
+20400742
 2020415e
 6fe0c91c
-204006f6
+2040074f
 20404164
 6848c91c
 20403f96
 6fe0c91d
-204006f6
+2040074f
 2040416a
 6848c91d
 20403f96
 6fe0c91e
-204006f6
+2040074f
 20404170
 6848c91e
 20203f96
@@ -1761,10 +1850,10 @@
 1fe22600
 6848c911
 6fe0c914
-c07f86e5
+c07f873e
 2020417e
 6fe0c911
-204006f9
+20400752
 6848c911
 2020418b
 6fe0c912
@@ -1774,10 +1863,10 @@
 1fe22600
 6848c912
 6fe0c914
-c07f86f2
+c07f874b
 20204197
 6fe0c912
-204006f9
+20400752
 6848c912
 202041a4
 c17f8000
@@ -1788,13 +1877,13 @@
 2020612c
 70486801
 704e3d00
-20400712
-20400702
-20400718
-202006ff
-204006c6
+2040076b
+2040075b
+20400771
+20200758
+2040071f
 1a217e07
-c0008707
+c0008760
 704e3c00
 20600000
 6fe0ce3c
@@ -1804,9 +1893,9 @@
 1fe0fe01
 1fe17e03
 67e0ce3d
-c0000712
-c0008714
-c0010716
+c000076b
+c000876d
+c001076f
 20600000
 70483d00
 20600000
@@ -1825,31 +1914,31 @@
 1fe27200
 efe08006
 08008608
-c2000721
+c200077a
 20600000
 20758000
 704dd100
-20200737
+20200790
 704dd110
-20200737
+20200790
 704dd111
-20200737
+20200790
 704dd120
-20200737
+20200790
 704dd121
-20200737
+20200790
 704dd130
-20200737
+20200790
 704dd131
-20200737
+20200790
 20758000
 704dd140
-20200737
+20200790
 6848cdd1
 18518400
 6fe0cdd6
 98467c00
-20228753
+202287ac
 6048cdd6
 18408401
 58000100
@@ -1859,14 +1948,14 @@
 6849cdda
 9840fe00
 67e1cddd
-20400755
-20400761
-20400758
-24228745
+204007ae
+204007ba
+204007b1
+2422879e
 6fe20e00
 684a4de0
 98467c00
-24228745
+2422879e
 58000e00
 67e141a6
 7041a840
@@ -1883,7 +1972,7 @@
 df20003f
 efe20006
 9a20a200
-c200075b
+c20007b4
 efe20006
 9a267c00
 20600000
Index: output/romcode.rom
===================================================================
--- /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/romcode.rom	(revision 5300)
+++ /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/output/romcode.rom	(working copy)
@@ -30612,7 +30612,7 @@
 20600000
 20404150
 1a217e07
-c00186fc
+c0018755
 6fe44bbc
 c2978026
 6fe0c93d
@@ -30670,7 +30670,7 @@
 20407f52
 20404055
 6fe0c924
-204006f6
+2040074f
 2040049d
 20403e72
 d8400013
@@ -30776,4 +30776,4 @@
 67e1cc16
 202026e8
 20600000
-00003678
+00008b38
Index: program/app_mouse.prog
===================================================================
--- /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/program/app_mouse.prog	(revision 5289)
+++ /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/program/app_mouse.prog	(working copy)
@@ -1800,6 +1800,7 @@
 	store 1,mem_mouse_customerkey_press_status
 	copy rega,pdata
 	bbit1 MOUSE_CUSTOMER_KEY,mouse_customerkey_press
+mouse_customerkey_release_set:
 	call mouse_customerkey_release
 mouse_check_customerkey_gpio_exit:
 	fetch 1,mem_customer_data_trigger
Index: program/patch.prog
===================================================================
--- /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/program/patch.prog	(revision 5300)
+++ /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/program/patch.prog	(working copy)
@@ -2792,6 +2792,7 @@
 	fetch 1,mem_mouse_key
 	and_into 0x1f,pdata
 	store 1,mem_mouse_key
+	call p_mouse_key_flag_check
 	nbranch p_mouse_drawing_optima_init,user
 	jam 0,mem_device_tx_heart_data_flag
 	jam 1,mem_24g_rf_data_flag
@@ -2802,6 +2803,130 @@
 	jam 0,mem_24g_rf_data_flag
 	branch mouse_drawing_optima_init
 
+//===============key fution change check==================//
+p_mouse_key_flag_check:
+	//rkey check
+	jam 0x02,mem_mouse_key_bit_index_value
+ 	arg mem_mouse_rkey_fuction_info,contr
+ 	call p_mouse_key_flag_check_interface
+ 	//mkey check
+	jam 0x04,mem_mouse_key_bit_index_value
+ 	arg mem_mouse_mkey_fuction_info,contr
+ 	call p_mouse_key_flag_check_interface
+ 	//bk check
+	jam 0x08,mem_mouse_key_bit_index_value
+ 	arg mem_mouse_b5_fuction_info,contr
+ 	call p_mouse_key_flag_check_interface
+ 	//fw check
+	jam 0x10,mem_mouse_key_bit_index_value
+ 	arg mem_mouse_b4_fuction_info,contr
+ 	branch p_mouse_key_flag_check_interface
+ 	
+//contr:key fuction ptr
+p_mouse_key_flag_check_interface:
+	arg mem_mouse_key_fuction_info_temp,contw
+	call p_memcpy_10
+	fetch 1,mem_mouse_key_fuction_info_temp
+	beq MS_KEY,p_mouse_mkey_ms_fuction_check
+	beq KB_KEY,p_mouse_mkey_kb_fuction_check
+	rtn
+
+//=======ms key fution change check=========//
+p_mouse_mkey_ms_fuction_check:
+	fetch 1,mem_mouse_key_fuction_info_temp+1
+	rtn blank
+	fetcht 1,mem_mouse_key_bit_index_value			//key function=former fuction
+	isub temp,null
+	rtn zero
+	bbit1 MOUSE_R_KEY,p_mouse_ms_rkey_fuction_check
+	bbit1 MOUSE_M_KEY,p_mouse_ms_mkey_fuction_check
+	bbit1 MOUSE_BK_KEY,p_mouse_ms_bk_fuction_check
+	bbit1 MOUSE_FW_KEY,p_mouse_ms_fw_fuction_check
+	rtn
+
+p_mouse_ms_rkey_fuction_check:
+	fetcht 1,mem_mouse_key
+	fetch 1,mem_mouse_key_bit_index_value
+	iand temp,pdata
+	rtn blank
+	set1 MOUSE_R_KEY,temp
+p_mouse_storet_mouse_key:
+	storet 1,mem_mouse_key
+	rtn
+	
+p_mouse_ms_mkey_fuction_check:
+	fetcht 1,mem_mouse_key
+	fetch 1,mem_mouse_key_bit_index_value
+	iand temp,pdata
+	rtn blank
+	set1 MOUSE_M_KEY,temp
+	branch p_mouse_storet_mouse_key
+
+p_mouse_ms_bk_fuction_check:
+	fetcht 1,mem_mouse_key
+	fetch 1,mem_mouse_key_bit_index_value
+	iand temp,pdata
+	rtn blank
+	set1 MOUSE_BK_KEY,temp
+	branch p_mouse_storet_mouse_key
+
+p_mouse_ms_fw_fuction_check:
+	fetcht 1,mem_mouse_key
+	fetch 1,mem_mouse_key_bit_index_value
+	iand temp,pdata
+	rtn blank
+	set1 MOUSE_FW_KEY,temp
+	branch p_mouse_storet_mouse_key
+
+//=======kb key fution change check=========//
+p_mouse_mkey_kb_fuction_check:
+	setarg 0
+	store 8,mem_customer_key_release
+	fetch 1,mem_mouse_key_fuction_info_temp+1
+	call p_mouse_customer_key_type_store,blank	//system key or multil key
+	fetcht 1,mem_mouse_key
+	fetch 1,mem_mouse_key_bit_index_value
+	iand temp,pdata
+	branch mouse_customerkey_release_set,blank
+	fetcht 1,mem_mouse_key_bit_index_value
+	isolate1 MOUSE_R_KEY,temp
+	call p_mouse_rkey_clear_set,true
+	isolate1 MOUSE_M_KEY,temp
+	call p_mouse_mkey_clear_set,true
+	isolate1 MOUSE_BK_KEY,temp
+	call p_mouse_bk_clear_set,true
+	isolate1 MOUSE_FW_KEY,temp
+	call p_mouse_fw_clear_set,true
+	fetch 8,mem_mouse_key_fuction_info_temp+1
+	store 8,mem_customer_key_press
+	branch mouse_customerkey_press
+
+p_mouse_customer_key_type_store:
+	store 1,mem_customer_key_release
+	rtn
+
+p_mouse_rkey_clear_set:
+	fetch 1,mem_mouse_key
+	set0 MOUSE_R_KEY,pdata
+p_mouse_store_mouse_key:
+	store 1,mem_mouse_key
+	rtn
+
+p_mouse_mkey_clear_set:
+	fetch 1,mem_mouse_key
+	set0 MOUSE_M_KEY,pdata
+	branch p_mouse_store_mouse_key
+
+p_mouse_bk_clear_set:
+	fetch 1,mem_mouse_key
+	set0 MOUSE_BK_KEY,pdata
+	branch p_mouse_store_mouse_key
+	
+p_mouse_fw_clear_set:
+	fetch 1,mem_mouse_key
+	set0 MOUSE_FW_KEY,pdata
+	branch p_mouse_store_mouse_key
+
 p_mouse_check_sensor_data:
 	fetch 1,mem_spi_write_flash_sm
 	rtnne FLASH_SM_NO_BUYS
Index: sched/mouse.dat
===================================================================
--- /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/sched/mouse.dat	(revision 5300)
+++ /YC1308AF/branch/mouse/USB_4Mode_Project/RongYuan_Project/mouse_public_3mode_usb/sched/mouse.dat	(working copy)
@@ -40,7 +40,7 @@
 #bit4 MOUSE_ENABLE_ADC
 #bit5 MOUSE_ENABLE_KEYBOARD
 #bit6 MOUSE_ENABLE_24G_SEARCH_DONGLE
-06
+26
 
 #mouse flag byte4
 #bit0 MOUSE_ENABLE_24G_250Hz
