Autoresponse
I have found the problem . VGA666 interface use GPIO 2 & 3 for synchronism
GPIO 02: level=0 fsel=6 alt=2 func=LCD_VSYNC
GPIO 03: level=0 fsel=6 alt=2 func=LCD_HSYNC
For the power button function and VGA666 to coexist you have to change the pin, I changed it to 16 and it works without problem.
recalbox/scripts/rpi-pin56-power.py
GPIO.setup(16, GPIO.IN, pull_up_down=GPIO.PUD_UP)
def shutdown():
os.system("shutdown -h now")
try:
if mode == "onoff" :
GPIO.wait_for_edge(16, GPIO.RISING)
in case it is of any help to anyone