Index: format/app_mouse.format
===================================================================
--- /YC1308AF/branch/mouse/YDN_Project/Multi_Mode/PB_3m_3ch_pair_G903-FS/format/app_mouse.format	(revision 4414)
+++ /YC1308AF/branch/mouse/YDN_Project/Multi_Mode/PB_3m_3ch_pair_G903-FS/format/app_mouse.format	(working copy)
@@ -445,6 +445,7 @@
 0X07 MOUSE_LMR_BUTTON
 0x09 MOUSE_L_BK_BUTTON
 0x0a MOUSE_R_BK_BUTTON
+0x12 MOUSE_R_FW_BUTTON
 0x11 MOUSE_L_FW_BUTTON
 0x14 MOUSE_M_FW_BUTTON
 0X18 MOUSE_BK_FW_BUTTON
Index: output/eeprom.dat
===================================================================
--- /YC1308AF/branch/mouse/YDN_Project/Multi_Mode/PB_3m_3ch_pair_G903-FS/output/eeprom.dat	(revision 4414)
+++ /YC1308AF/branch/mouse/YDN_Project/Multi_Mode/PB_3m_3ch_pair_G903-FS/output/eeprom.dat	(working copy)
@@ -2,7 +2,7 @@
 02
 aa
 55
-ae
+e6
 17
 c2
 84
@@ -67,7 +67,7 @@
 c0
 68
 05
-b5
+b6
 c0
 69
 03
@@ -3743,7 +3743,7 @@
 20
 40
 05
-e5
+e6
 d8
 40
 00
@@ -3951,7 +3951,7 @@
 20
 40
 05
-e8
+e9
 68
 48
 c9
@@ -5843,7 +5843,11 @@
 20
 40
 05
-b5
+b6
+20
+40
+05
+ec
 20
 20
 41
@@ -5863,15 +5867,15 @@
 20
 40
 05
-bc
+bd
 20
 40
 05
-cb
+cc
 20
 40
 05
-d8
+d9
 20
 20
 41
@@ -5883,7 +5887,7 @@
 20
 40
 05
-e5
+e6
 20
 40
 41
@@ -5903,7 +5907,7 @@
 20
 40
 05
-e5
+e6
 20
 40
 41
@@ -5923,7 +5927,7 @@
 20
 40
 05
-e5
+e6
 20
 40
 41
@@ -5967,7 +5971,7 @@
 c0
 7f
 85
-d4
+d5
 20
 20
 41
@@ -5979,7 +5983,7 @@
 20
 40
 05
-e8
+e9
 68
 48
 c9
@@ -6019,7 +6023,7 @@
 c0
 7f
 85
-e1
+e2
 20
 20
 41
@@ -6031,7 +6035,7 @@
 20
 40
 05
-e8
+e9
 68
 48
 c9
@@ -6064,8 +6068,60 @@
 20
 61
 2c
-15
-1d
+70
+4b
+a9
+00
+70
+4b
+aa
+00
+70
+4b
+ab
+00
+1f
+e2
+04
+00
+20
+40
+05
+f3
+20
+40
+05
+f6
+20
+20
+41
+33
+18
+41
+7e
+09
+c0
+04
+c1
+4e
+20
+60
+00
+00
+18
+41
+7e
+12
+c0
+09
+41
+4e
+20
+60
+00
+00
+85
+78
 aa
 55
 40
@@ -7395,64 +7451,8 @@
 55
 bf
 8f
-06
-46
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
-ff
+86
+90
 ff
 ff
 ff
@@ -8188,5 +8188,5 @@
 ff
 ff
 ff
-06
-e7
+d1
+c5
Index: output/program.lis
===================================================================
--- /YC1308AF/branch/mouse/YDN_Project/Multi_Mode/PB_3m_3ch_pair_G903-FS/output/program.lis	(revision 4414)
+++ /YC1308AF/branch/mouse/YDN_Project/Multi_Mode/PB_3m_3ch_pair_G903-FS/output/program.lis	(working copy)
@@ -15,7 +15,7 @@
 000c c066858f beq patch19_5 ,p_mouse_motion 
 000d c06703dd beq patch19_6 ,p_mouse_dpi_process 
 000e c06783ee beq patch19_7 ,p_mouse_seting_dpi 
-000f c06805b5 beq patch1a_0 ,p_mouse_check_key_gpio 
+000f c06805b6 beq patch1a_0 ,p_mouse_check_key_gpio 
 0010 c0690366 beq patch1a_2 ,p_mouse_init_sunt 
 0011 c0698382 beq patch1a_3 ,p_mouse_sensor_poweron 
 0012 c06a8436 beq patch1a_5 ,p_mouse_priority_bb_event 
@@ -1254,7 +1254,7 @@
 03a3 6848c914 fetcht 1 ,mem_matrix_public_gpio 
 03a4 204060e6 call gpio_clr_wake 
 03a5 6fe0c924 fetch 1 ,mem_mouse_sensor_sdio_gpio 
-03a6 204005e5 call p_mouse_gpio_config_output_high 
+03a6 204005e6 call p_mouse_gpio_config_output_high 
 03a7 d8400003 arg 3 ,temp 
 03a8 20403f96 call mouse_gpio_config_input_pu 
 03a9 20403e80 call mouse_lpm_before_common 
@@ -1324,7 +1324,7 @@
 
 p_mouse_3io6key_dpi_check:
 03d9 6fe0c913 fetch 1 ,mem_dpi_button_gpio 
-03da 204005e8 call p_mouse_gpio_config_output_low 
+03da 204005e9 call p_mouse_gpio_config_output_low 
 03db 6848c913 fetcht 1 ,mem_dpi_button_gpio 
 03dc 202041d5 branch mouse_3io6key_check 
 
@@ -1973,82 +1973,102 @@
 05b2 20204758 branch mouse_drawing_optima 
 
 p_mouse_key:
-05b3 204005b5 call p_mouse_check_key_gpio 
-05b4 2020411e branch mouse_key + 2 
+05b3 204005b6 call p_mouse_check_key_gpio 
+05b4 204005ec call p_mouse_ghost_key_check 
+05b5 2020411e branch mouse_key + 2 
 
 p_mouse_check_key_gpio:
-05b5 6fe0cbf2 fetch 1 ,mem_sensor_shutdown_flag 
-05b6 245a4161 ncall mouse_check_key_gpio_once ,blank 
-05b7 da200000 arg 0 ,rega 
-05b8 204005bc call p_mouse_check_lkey_gpio 
-05b9 204005cb call p_mouse_check_bkkey_gpio 
-05ba 204005d8 call p_mouse_check_fwkey_gpio 
-05bb 2020415e branch mouse_check_key_gpio_next 
+05b6 6fe0cbf2 fetch 1 ,mem_sensor_shutdown_flag 
+05b7 245a4161 ncall mouse_check_key_gpio_once ,blank 
+05b8 da200000 arg 0 ,rega 
+05b9 204005bd call p_mouse_check_lkey_gpio 
+05ba 204005cc call p_mouse_check_bkkey_gpio 
+05bb 204005d9 call p_mouse_check_fwkey_gpio 
+05bc 2020415e branch mouse_check_key_gpio_next 
 
 p_mouse_check_lkey_gpio:
-05bc 6fe0c91c fetch 1 ,mem_lbutton_gpio 
-05bd 204005e5 call p_mouse_gpio_config_output_high 
-05be 20404164 call mouse_check_lkey_gpio 
-05bf 6848c91c fetcht 1 ,mem_lbutton_gpio 
-05c0 20403f96 call mouse_gpio_config_input_pu 
+05bd 6fe0c91c fetch 1 ,mem_lbutton_gpio 
+05be 204005e6 call p_mouse_gpio_config_output_high 
+05bf 20404164 call mouse_check_lkey_gpio 
+05c0 6848c91c fetcht 1 ,mem_lbutton_gpio 
+05c1 20403f96 call mouse_gpio_config_input_pu 
 
 p_mouse_check_rkey_gpio:
-05c1 6fe0c91d fetch 1 ,mem_rbutton_gpio 
-05c2 204005e5 call p_mouse_gpio_config_output_high 
-05c3 2040416a call mouse_check_rkey_gpio 
-05c4 6848c91d fetcht 1 ,mem_rbutton_gpio 
-05c5 20403f96 call mouse_gpio_config_input_pu 
+05c2 6fe0c91d fetch 1 ,mem_rbutton_gpio 
+05c3 204005e6 call p_mouse_gpio_config_output_high 
+05c4 2040416a call mouse_check_rkey_gpio 
+05c5 6848c91d fetcht 1 ,mem_rbutton_gpio 
+05c6 20403f96 call mouse_gpio_config_input_pu 
 
 p_mouse_check_mkey_gpio:
-05c6 6fe0c91e fetch 1 ,mem_mbutton_gpio 
-05c7 204005e5 call p_mouse_gpio_config_output_high 
-05c8 20404170 call mouse_check_mkey_gpio 
-05c9 6848c91e fetcht 1 ,mem_mbutton_gpio 
-05ca 20203f96 branch mouse_gpio_config_input_pu 
+05c7 6fe0c91e fetch 1 ,mem_mbutton_gpio 
+05c8 204005e6 call p_mouse_gpio_config_output_high 
+05c9 20404170 call mouse_check_mkey_gpio 
+05ca 6848c91e fetcht 1 ,mem_mbutton_gpio 
+05cb 20203f96 branch mouse_gpio_config_input_pu 
 
 p_mouse_check_bkkey_gpio:
-05cb 6fe0c911 fetch 1 ,mem_bk_button_gpio 
-05cc c17f8000 rtneq gpio_disable 
-05cd 704ba703 jam mouse_bk_key ,mem_mouse_key_temp 
-05ce 6fe0cba2 fetch 1 ,mem_mouse_bkkey_press_status 
-05cf 1fe22600 copy pdata ,regc 
-05d0 6848c911 fetcht 1 ,mem_bk_button_gpio 
-05d1 6fe0c914 fetch 1 ,mem_matrix_public_gpio 
-05d2 c07f85d4 beq gpio_disable ,p_mouse_3io6key_bk_check 
-05d3 2020417e branch mouse_check_bkkey_gpio_next 
+05cc 6fe0c911 fetch 1 ,mem_bk_button_gpio 
+05cd c17f8000 rtneq gpio_disable 
+05ce 704ba703 jam mouse_bk_key ,mem_mouse_key_temp 
+05cf 6fe0cba2 fetch 1 ,mem_mouse_bkkey_press_status 
+05d0 1fe22600 copy pdata ,regc 
+05d1 6848c911 fetcht 1 ,mem_bk_button_gpio 
+05d2 6fe0c914 fetch 1 ,mem_matrix_public_gpio 
+05d3 c07f85d5 beq gpio_disable ,p_mouse_3io6key_bk_check 
+05d4 2020417e branch mouse_check_bkkey_gpio_next 
 
 p_mouse_3io6key_bk_check:
-05d4 6fe0c911 fetch 1 ,mem_bk_button_gpio 
-05d5 204005e8 call p_mouse_gpio_config_output_low 
-05d6 6848c911 fetcht 1 ,mem_bk_button_gpio 
-05d7 2020418b branch mouse_3io6key_bk_check 
+05d5 6fe0c911 fetch 1 ,mem_bk_button_gpio 
+05d6 204005e9 call p_mouse_gpio_config_output_low 
+05d7 6848c911 fetcht 1 ,mem_bk_button_gpio 
+05d8 2020418b branch mouse_3io6key_bk_check 
 
 p_mouse_check_fwkey_gpio:
-05d8 6fe0c912 fetch 1 ,mem_fw_button_gpio 
-05d9 c17f8000 rtneq gpio_disable 
-05da 704ba704 jam mouse_fw_key ,mem_mouse_key_temp 
-05db 6fe0cba3 fetch 1 ,mem_mouse_fwkey_press_status 
-05dc 1fe22600 copy pdata ,regc 
-05dd 6848c912 fetcht 1 ,mem_fw_button_gpio 
-05de 6fe0c914 fetch 1 ,mem_matrix_public_gpio 
-05df c07f85e1 beq gpio_disable ,p_mouse_3io6key_fw_check 
-05e0 20204197 branch mouse_check_fwkey_gpio_next 
+05d9 6fe0c912 fetch 1 ,mem_fw_button_gpio 
+05da c17f8000 rtneq gpio_disable 
+05db 704ba704 jam mouse_fw_key ,mem_mouse_key_temp 
+05dc 6fe0cba3 fetch 1 ,mem_mouse_fwkey_press_status 
+05dd 1fe22600 copy pdata ,regc 
+05de 6848c912 fetcht 1 ,mem_fw_button_gpio 
+05df 6fe0c914 fetch 1 ,mem_matrix_public_gpio 
+05e0 c07f85e2 beq gpio_disable ,p_mouse_3io6key_fw_check 
+05e1 20204197 branch mouse_check_fwkey_gpio_next 
 
 p_mouse_3io6key_fw_check:
-05e1 6fe0c912 fetch 1 ,mem_fw_button_gpio 
-05e2 204005e8 call p_mouse_gpio_config_output_low 
-05e3 6848c912 fetcht 1 ,mem_fw_button_gpio 
-05e4 202041a4 branch mouse_3io6key_fw_check 
+05e2 6fe0c912 fetch 1 ,mem_fw_button_gpio 
+05e3 204005e9 call p_mouse_gpio_config_output_low 
+05e4 6848c912 fetcht 1 ,mem_fw_button_gpio 
+05e5 202041a4 branch mouse_3io6key_fw_check 
 
 p_mouse_gpio_config_output_high:
-05e5 c17f8000 rtneq gpio_disable 
-05e6 d840003f arg gpcfg_output_high ,temp 
-05e7 2020612c branch gpio_config_function_int 
+05e6 c17f8000 rtneq gpio_disable 
+05e7 d840003f arg gpcfg_output_high ,temp 
+05e8 2020612c branch gpio_config_function_int 
 
 p_mouse_gpio_config_output_low:
-05e8 c17f8000 rtneq gpio_disable 
-05e9 d840003e arg gpcfg_output_low ,temp 
-05ea 2020612c branch gpio_config_function_int 
+05e9 c17f8000 rtneq gpio_disable 
+05ea d840003e arg gpcfg_output_low ,temp 
+05eb 2020612c branch gpio_config_function_int 
+
+p_mouse_ghost_key_check:
+05ec 704ba900 jam 0 ,mem_mouse_matrix_key_cow_count 
+05ed 704baa00 jam 0 ,mem_mouse_matrix_key_row_count 
+05ee 704bab00 jam 0 ,mem_mouse_ghost_flag 
+05ef 1fe20400 copy pdata ,temp 
+05f0 204005f3 call p_mouse_ghost_key_check_l_bk 
+05f1 204005f6 call p_mouse_ghost_key_check_r_fw 
+05f2 20204133 branch mouse_ghost_key_check + 6 
+
+p_mouse_ghost_key_check_l_bk:
+05f3 18417e09 and temp ,mouse_l_bk_button ,pdata 
+05f4 c004c14e beq mouse_l_bk_button ,mouse_matrix_cow_more_than_one_key 
+05f5 20600000 rtn 
+
+p_mouse_ghost_key_check_r_fw:
+05f6 18417e12 and temp ,mouse_r_fw_button ,pdata 
+05f7 c009414e beq mouse_r_fw_button ,mouse_matrix_cow_more_than_one_key 
+05f8 20600000 rtn 
               org 0x800
 
 start:
Index: program/patch.prog
===================================================================
--- /YC1308AF/branch/mouse/YDN_Project/Multi_Mode/PB_3m_3ch_pair_G903-FS/program/patch.prog	(revision 4414)
+++ /YC1308AF/branch/mouse/YDN_Project/Multi_Mode/PB_3m_3ch_pair_G903-FS/program/patch.prog	(working copy)
@@ -2262,7 +2262,7 @@
 
 p_mouse_key:
 	call p_mouse_check_key_gpio
-//	call p_mouse_ghost_key_check
+	call p_mouse_ghost_key_check
 	branch mouse_key+2
 
 p_mouse_check_key_gpio:
@@ -2338,26 +2338,26 @@
 	rtneq GPIO_DISABLE
 	arg gpcfg_output_low,temp
 	branch gpio_config_function_int
-/*
+
 p_mouse_ghost_key_check:
 	jam 0,mem_mouse_matrix_key_cow_count
 	jam 0,mem_mouse_matrix_key_row_count
 	jam 0,mem_mouse_ghost_flag
 	copy pdata,temp
-	call p_mouse_ghost_key_check_L_FW
-	call p_mouse_ghost_key_check_R_BK
+	call p_mouse_ghost_key_check_L_BK
+	call p_mouse_ghost_key_check_R_FW
 	branch mouse_ghost_key_check+6
 
-p_mouse_ghost_key_check_L_FW:
-	and temp,MOUSE_L_FW_BUTTON,pdata
-	beq MOUSE_L_FW_BUTTON,mouse_matrix_cow_more_than_one_key
+p_mouse_ghost_key_check_L_BK:
+	and temp,MOUSE_L_BK_BUTTON,pdata
+	beq MOUSE_L_BK_BUTTON,mouse_matrix_cow_more_than_one_key
 	rtn
 
-p_mouse_ghost_key_check_R_BK:
-	and temp,MOUSE_R_BK_BUTTON,pdata
-	beq MOUSE_R_BK_BUTTON,mouse_matrix_cow_more_than_one_key
+p_mouse_ghost_key_check_R_FW:
+	and temp,MOUSE_R_FW_BUTTON,pdata
+	beq MOUSE_R_FW_BUTTON,mouse_matrix_cow_more_than_one_key
 	rtn
-*/
+
 
 
 ifdef UART_LOG
