anchor.diff:  #define APC_COVER_OPENED 1
   #define APC_COVER_REMOVED 2
   
  +#define APC_NOT_CHARGING 0
  +#define APC_CHARGING 1
  +#define APC_FULLY_CHARGED 2
  +
   // the Area Power Controller (APC), formerly Power Distribution Unit (PDU)
   // one per area, needs wire connection to power network through a terminal
   
  
positive.code: 		if("charge")
  			chargemode = !chargemode
  			if(!chargemode)
  				charging = 0
  				update_icon()
  			. = TRUE
  		if("channel")
  
negative.code: 
  		if(!charging)
  			update_overlay |= APC_UPOVERLAY_CHARGEING0
  		else if(charging == APC_CHARGING)
  			update_overlay |= APC_UPOVERLAY_CHARGEING1
  		else if(charging == APC_FULLY_CHARGED)
  			update_overlay |= APC_UPOVERLAY_CHARGEING2
  
  		if (!equipment)
  