Index: firmware/target/arm/imx233/sansa-fuzeplus/button-fuzeplus.c =================================================================== --- firmware/target/arm/imx233/sansa-fuzeplus/button-fuzeplus.c (révision 31049) +++ firmware/target/arm/imx233/sansa-fuzeplus/button-fuzeplus.c (copie de travail) @@ -41,6 +41,7 @@ int sensor_resol = rmi_read_single(RMI_2D_SENSOR_RESOLUTION(0)); int min_dist = rmi_read_single(RMI_2D_MIN_DIST); int gesture_settings = rmi_read_single(RMI_2D_GESTURE_SETTINGS); + int sensibility_counter = 0; union { unsigned char data; @@ -157,10 +158,15 @@ if(btns & BUTTON_VOL_DOWN || btns & BUTTON_VOL_UP) { if(btns & BUTTON_VOL_UP) - sensitivity.value++; + sensibility_counter++; if(btns & BUTTON_VOL_DOWN) - sensitivity.value--; - rmi_write(RMI_2D_SENSITIVITY_ADJ, 1, &sensitivity.data); + sensibility_counter--; + if((sensibility_counter == -15) || (sensibility_counter == 15)) + { + sensitivity.value += (sensibility_counter / 15); + sensibility_counter = 0; + } + rmi_write(RMI_2D_SENSITIVITY_ADJ, 1, &sensitivity.data); } yield(); @@ -184,8 +190,8 @@ {1900, 600, 2500, 1100, BUTTON_RIGHT}, {1300, 0, 1700, 400, BUTTON_DOWN}, {1300, 1300, 1700, 1800, BUTTON_UP}, - {2500, 1600, 2900, 1800, BUTTON_PLAYPAUSE}, - {300, 1600, 500, 1800, BUTTON_BACK}, + {2500, 1600, 2900, 1900, BUTTON_PLAYPAUSE}, + {0, 1600, 500, 1900, BUTTON_BACK}, {0, 0, 0, 0, 0}, };