     delay(18);
   }
 
+*/
+
 }

}

void loop() {
  delay(5000);

  for(int i = 0; i < 8; i++)
  {

#define PinTransportMotor 11
#define PinStepSensor 12

#define BufferSize 10

int pins[] = {PinBit0, PinBit1, PinBit2, PinBit3, PinBit4, PinBit5, PinBit6, PinBit7};

byte buffArray[BufferSize]; // Buffer array, used as ring buffer
int buffWritePos = 0;       // Write position - write at this position, increment afterwards.
int buffReadPos = 0;        // Read position - read at this position, increment afterwards.
int buffLevel = 0;          // Distance between read and write position. Overflow detected when larger than BufferSize 
int buffValue;

int lastTime = 0;
int highTime = 20;
int lowTime = 180;
bool isHigh = false;

void setup() {
  // initialize serial communication at 9600 bits per second:
