this is the code I posted to the pilotlamp thread + //==================GREEN LED=========================== + if (f.ARMED && f.ANGLE_MODE) useResource('G',1000,1000); + else if (f.ARMED && f.HORIZON_MODE) useResource('G',100,1000); + else if (f.ARMED) useResource('G',1000,0); + else useResource('G',0,0); //switch off