 #define DEBUGLN(x)
 #endif
 
+/* We're a loconet decoder! */
 #include <LocoNet.h>
 
+/* Include the CV handling and the pin functionalities */
 #include "decoder_conf.h"
 #include "configuredpins.h"
 #include "cvaccess.h"
 
-#define servoEnablePin 15
-
-#define ARTNR 10001
-
 decoder_conf_t EEMEM _CV = {
 #include "default_conf.h"
 };
 
+#define MAX 24
+ConfiguredPin* confpins[MAX];
+
+/* Power to pins management */
+#define servoEnablePin 15
 
 void enableServos();
 void disableServos();
 
+bool pins_busy = false;
+
 /* 
-    Serial related stuff
+The LocoNet CV related stuff
 */
-int incomingByte = 0;
+#define ARTNR 10001
 
 lnMsg *LnPacket;
 


boolean programmingMode;

/* 
    Button related stuff
*/

#define LOCONET_TX_PIN 5

bool pins_busy = false;
/*
	Switch related stuff
*/
#define MAX 24
ConfiguredPin* confpins[MAX];

void reportSwitch(uint16_t Address, uint16_t state){
#ifdef DS54

/*
If serial output is desired uncommment the #undef line. For production, i.e.
without computer connected this line should be commented out. 
*/
#define DEBUG_OUTPUT
//#undef DEBUG_OUTPUT

