diff --git a/examples/exampleCommLayer.m b/examples/exampleCommLayer.m
deleted file mode 100644
index 48f27d257c3a700483d1b3cca6cfd401532448a9..0000000000000000000000000000000000000000
--- a/examples/exampleCommLayer.m
+++ /dev/null
@@ -1,81 +0,0 @@
-% init the connection
-disp('Connecting ... ')
-% brick usb init
-b = Brick('ioType','usb');
-% beep to indicate connection
-b.beep();
-% print information
-disp('===================================')
-disp('EV3 example code')
-disp('===================================')
-disp('u - increase motor speed')
-disp('d - decrease motor speed')
-disp('t - start the motor')
-disp('s - stop the motor')
-disp('b - beep')
-disp('o - output the tachometer')
-disp('c - clear the tachometer')
-disp('v - output the brick voltage')
-disp('f - quit the program');
-disp('===================================')
-% user intput
-userIn = '';
-% motor power
-motorPower = 10;
-% set motor power and start
-b.outputPower(0,Device.MotorA,motorPower)
-b.outputStart(0,Device.MotorA)
-while(~strcmp(userIn,'f'))
-    % get input
-    userIn = input('> Input(u,d,t,s,b,o,c,v,f): ','s');
-    % increase speed
-    if (userIn == 'u')
-        motorPower = motorPower+10;
-        if motorPower >= 100
-            motorPower = 100;
-        end
-        b.outputPower(0,Device.MotorA,motorPower)
-        disp(['> Motor Power: ' num2str(motorPower)]);
-    end
-     % decrease speed
-    if (userIn == 'd')
-        motorPower = motorPower-10;
-        if motorPower <= -100
-            motorPower = -100;
-        end
-        b.outputPower(0,Device.MotorA,motorPower)
-        disp(['> Motor Power: ' num2str(motorPower)]);
-    end
-    % start the motor
-    if (userIn == 't')
-        b.outputStart(0,Device.MotorA)
-        disp('> Motor Started');
-    end
-    % stop the motor
-    if (userIn == 's')
-        b.outputStop(0,Device.MotorA,0)
-        disp('> Motor Stopped');
-    end
-    % beep test
-    if (userIn == 'b')
-        b.beep();
-        disp('> Beep');
-    end
-    % output the tachometer
-    if (userIn == 'o')
-        tacho = b.outputGetCount(0,Device.MotorA);
-        disp(['> Tachometer: ' num2str(tacho)]);
-    end
-    % clear the tachometer
-    if (userIn == 'c')
-        b.outputClrCount(0,Device.MotorA)
-        disp('> Cleared tacho');
-    end
-    % voltage output
-    if (userIn == 'v')
-        v = b.uiReadVbatt;
-        disp(['> Brick voltage: ' num2str(v) 'V']);
-    end
-end
-% delete the brick object
-delete(b)
\ No newline at end of file
diff --git a/examples/testConnSpeed.m b/old_examples/testConnSpeed.m
similarity index 100%
rename from examples/testConnSpeed.m
rename to old_examples/testConnSpeed.m
diff --git a/examples/testSyncMotor.m b/old_examples/testSyncMotor.m
similarity index 100%
rename from examples/testSyncMotor.m
rename to old_examples/testSyncMotor.m
diff --git a/examples/testToolbox.m b/old_examples/testToolbox.m
similarity index 100%
rename from examples/testToolbox.m
rename to old_examples/testToolbox.m
diff --git a/source/+DeviceMode/Error.m b/source/+DeviceMode/Default.m
similarity index 52%
rename from source/+DeviceMode/Error.m
rename to source/+DeviceMode/Default.m
index 244ea15b1858b236b79684e979a2354732ad702b..1efa576db09f94be29fde9dcae251bb0d076abeb 100644
--- a/source/+DeviceMode/Error.m
+++ b/source/+DeviceMode/Default.m
@@ -1,6 +1,4 @@
-classdef Error < uint8
-    %Error Test
-    
+classdef Default < uint8
     enumeration
         Undefined (0)
     end
diff --git a/source/bitfield2input.m b/source/bitfield2input.m
new file mode 100644
index 0000000000000000000000000000000000000000..2f59bb0151480c5a940484ff5c9fee9fdb8f48fc
--- /dev/null
+++ b/source/bitfield2input.m
@@ -0,0 +1,10 @@
+function inputPort = bitfield2input(bitfield)
+% Converts a motor-bitfield to motor-inputport-number(s).
+    [isSynced, ~, ~] = isSyncedBitfield(bitfield);
+    if isSynced
+        ports = bitfield2port(bitfield);
+        inputPort = [port2input(ports(1)), port2input(ports(2))];
+    else
+        inputPort = port2input(bitfield2port(bitfield));
+    end
+end
\ No newline at end of file
diff --git a/source/bitfield2port.m b/source/bitfield2port.m
index 1b5ab929ce9cf5c1f7abf484ce087e9965c40f3d..85f52b0f046d51cb9393d89ab85d4dbbe839d460 100644
--- a/source/bitfield2port.m
+++ b/source/bitfield2port.m
@@ -1,4 +1,9 @@
 function port = bitfield2port(bitfield)
-% Converts motorBitfield-enum to motorPort-enum.
-	port = MotorPort(log2(double(bitfield)));
+% Converts motor-bitfield to motor-port-number(s).
+    [isSynced, b1, b2] = isSyncedBitfield(bitfield);
+    if isSynced
+        port = [b1-1, b2-1];
+    else
+        port = uint8(log2(double(bitfield)));
+    end
 end
\ No newline at end of file
diff --git a/source/bool2str.m b/source/bool2str.m
index e8200152f05a8a02974fa817506215797423fcc1..f397f84234c4cf30949d92ffb176ebe1dcd0065c 100644
--- a/source/bool2str.m
+++ b/source/bool2str.m
@@ -10,6 +10,10 @@ function bool = bool2str(inp)
         elseif inp~=0
             error('bool2str: Not a valid boolean.');
         end
+    elseif islogical(inp)
+        if inp==true
+            bool = 'on';
+        end
     end
 
 end
diff --git a/source/input2bitfield.m b/source/input2bitfield.m
new file mode 100644
index 0000000000000000000000000000000000000000..cbc3d9e67dfbdd359bef99d856e52e2218db8e6f
--- /dev/null
+++ b/source/input2bitfield.m
@@ -0,0 +1,8 @@
+function bitfield = input2bitfield(varargin)
+% Converts motor-inputport-number(s) to motor-bitfield.
+    if nargin==1
+        bitfield = port2bitfield(input2port(varargin{1}));
+    elseif nargin==2
+        bitfield = port2bitfield(input2port(varargin{1}), input2port(varargin{2}));
+    end
+end
diff --git a/source/input2port.m b/source/input2port.m
index 98bc1b230eec9984307e62bb8c74659e1c8ab3fe..4765c3add7bc160ab7c41ede5266defe74b7ee53 100644
--- a/source/input2port.m
+++ b/source/input2port.m
@@ -1,4 +1,4 @@
 function port = input2port(input)
-% Converts motorInput-enum to motorPort-enum.
-    port = MotorPort(input-16);
+% Converts a motor-inputport-number to motor-port-number.
+    port = uint8(input)-16;
 end
\ No newline at end of file
diff --git a/source/isBool.m b/source/isBool.m
index b7cbb7106c7c2a0eae7744387b2c9f68895536db..c1711a916d6a6a9f9ebe71b019ada707b9d20175 100644
--- a/source/isBool.m
+++ b/source/isBool.m
@@ -1,15 +1,11 @@
 function isValid = isBool(inp)
 % Returns whether given boolean is valid or not.
-    isValid = 0;
     if ischar(inp)
-        if strcmpi(inp, 'on') || strcmpi(inp, 'true') ...
-            || strcmpi(inp, 'off') || strcmpi(inp, 'false')
-            isValid = 1;
-        end
+        isValid = strcmpi(inp, 'on') || strcmpi(inp, 'off');
     elseif isnumeric(inp)
-        if inp==1 || inp==0
-            isValid = 1;
-        end
+        isValid = inp==1 || inp==0;
+    else
+        isValid = islogical(inp);
     end
 end
 
diff --git a/source/isDeviceValid.m b/source/isDeviceValid.m
new file mode 100644
index 0000000000000000000000000000000000000000..a0bcc933a8b351529de553c8ee818dfe9edd58b2
--- /dev/null
+++ b/source/isDeviceValid.m
@@ -0,0 +1,13 @@
+function isValid = isDeviceValid(deviceType, device)
+% Returns whether given device object is valid or not.
+    isValid = 0;
+    try 
+        if ~isempty(device)
+            if isa(device, deviceType) && device.isvalid
+                isValid = 1;
+            end
+        end
+    catch ME
+        % Ignore
+    end
+end
diff --git a/source/isModeValid.m b/source/isModeValid.m
index ef88e572ea6a8519b795b3f424caacc014f28cf6..ac5b575d41b3228831e889ee08b880c52b471280 100644
--- a/source/isModeValid.m
+++ b/source/isModeValid.m
@@ -1,6 +1,6 @@
 function isValid = isModeValid(mode, type)
 % Returns whether given mode is a valid mode in given type.
-    isValid = 1;
+    isValid = true;
     
     if strcmp(class(mode), 'DeviceMode.Error')
         return;
@@ -9,56 +9,58 @@ function isValid = isModeValid(mode, type)
     switch type
         case DeviceType.NXTTouch
             if ~strcmp(class(mode), 'DeviceMode.NXTTouch')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.NXTLight
             if ~strcmp(class(mode), 'DeviceMode.NXTLight')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.NXTSound
             if ~strcmp(class(mode), 'DeviceMode.NXTSound')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.NXTColor
             if ~strcmp(class(mode), 'DeviceMode.NXTColor')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.NXTUltraSonic
             if ~strcmp(class(mode), 'DeviceMode.NXTUltraSonic')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.NXTTemperature
             if ~strcmp(class(mode), 'DeviceMode.NXTTemperature')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.LargeMotor
             if ~strcmp(class(mode), 'DeviceMode.Motor')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.MediumMotor
             if ~strcmp(class(mode), 'DeviceMode.Motor')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.Touch
             if ~strcmp(class(mode), 'DeviceMode.Touch')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.Color
             if ~strcmp(class(mode), 'DeviceMode.Color')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.UltraSonic
             if ~strcmp(class(mode), 'DeviceMode.UltraSonic')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.Gyro
             if ~strcmp(class(mode), 'DeviceMode.Gyro')
-                isValid = 0;
+                isValid = false;
             end
         case DeviceType.InfraRed
             if ~strcmp(class(mode), 'DeviceMode.InfraRed')
-                isValid = 0;
+                isValid = false;
             end
+        otherwise
+            isValid = false;
     end
 end
 
diff --git a/source/isMotorValid.m b/source/isMotorValid.m
deleted file mode 100644
index a6451077e2014ab9b13ee6397b8869252b1ecbc3..0000000000000000000000000000000000000000
--- a/source/isMotorValid.m
+++ /dev/null
@@ -1,9 +0,0 @@
-function isValid = isMotorValid(motor)
-% Returns whether given motor object is valid or not.
-    isValid = 0;
-    if ~isempty(motor)
-        if isa(motor, 'Motor') && motor.isvalid
-            isValid = 1;
-        end
-    end
-end
diff --git a/source/isPortEnumValid.m b/source/isPortEnumValid.m
new file mode 100644
index 0000000000000000000000000000000000000000..009c995e2d6c120fa48bb4434f67f0c57b7fe9db
--- /dev/null
+++ b/source/isPortEnumValid.m
@@ -0,0 +1,27 @@
+function isValid = isPortEnumValid(device, port)
+% Returns whether given port-number is valid for given device
+    isValid = false;
+    
+    if ~ischar(device)
+        error(['isPortValid: First argument has to be a string (''Sensor'', ',...
+            '''Motor'' or ''SyncMotor'')']);
+    end
+    
+    try
+        if strcmpi(device, 'Motor')
+            if ~isa(port, 'MotorBitfield')
+                MotorBitfield(port); 
+            end
+            isValid = true;  % Otherwise, an error would have already been thrown
+        elseif strcmpi(device, 'Sensor')
+            if ~isa(port, 'SensorPort')
+                SensorPort(port); 
+            end
+            isValid = true;  % Otherwise, an error would have already been thrown
+        elseif strcmpi(device, 'SyncMotor')
+            isValid = isSyncedBitfield(port);
+        end
+    catch ME
+        % Ignore
+    end
+end
diff --git a/source/isPortStrValid.m b/source/isPortStrValid.m
new file mode 100644
index 0000000000000000000000000000000000000000..4b2398bae51c87a99b612c9a7b41d8e55525c411
--- /dev/null
+++ b/source/isPortStrValid.m
@@ -0,0 +1,19 @@
+function isValid = isPortStrValid(device, port)
+% Returns whether given port-number is valid for given device
+    if strcmpi(device, 'Motor')
+        validPorts = {'A', 'B', 'C', 'D'};
+    elseif strcmpi(device, 'Sensor')
+        validPorts = {'1', '2', '3', '4'};
+    elseif strcmpi(device, 'SyncMotor')
+        validPorts = {'AB', 'AC', 'AD', 'BA', 'BC', 'BD', ...
+            'CA', 'CB', 'CD', 'DA', 'DB', 'DC'};
+    else
+        error(['isPortValid: First argument has to be either ''Sensor'', ',...
+            '''Motor'' or ''SyncMotor''']);
+    end
+
+    if ischar(port)
+        isValid = ismember(port, validPorts);
+    end
+end
+
diff --git a/source/isPortValid.m b/source/isPortValid.m
deleted file mode 100644
index b2050fe09d265ae4bf7cf994be2ad454b415ef23..0000000000000000000000000000000000000000
--- a/source/isPortValid.m
+++ /dev/null
@@ -1,36 +0,0 @@
-function isValid = isPortValid(device, port)
-% Returns whether given port-string is valid or not.
-    isValid = 0;
-    
-    if ~ischar(device)
-        error(['isPortValid: First argument has to be a string (''Sensor'', ',...
-            '''Motor'' or ''SyncMotor'')']);
-    end
-    
-    if strcmpi(device, 'Motor')
-        validPorts = {'A', 'B', 'C', 'D'};
-    elseif strcmpi(device, 'Sensor')
-        validPorts = {'1', '2', '3', '4'};
-    elseif strcmpi(device, 'SyncMotor')
-        validPorts = {'AB', 'AC', 'AD', 'BA', 'BC', 'BD', ...
-            'CA', 'CB', 'CD', 'DA', 'DB', 'DC'};
-    else
-        error(['isPortValid: First argument has to be either ''Sensor'', ',...
-               '''Motor'' or ''SyncMotor''']);
-    end
-    
-    % Note: Both port2str() and validatestring() generate errors if the input
-    %       argument is 'wrong'. This method here isn't supposed to do this,
-    %       it's only supposed to return whether given port is valid or not.
-    try
-        if ~ischar(port)
-            port = port2str(device, port);
-        end
-
-        if any(validatestring(port, validPorts))
-            isValid = 1;
-        end
-    catch
-        return;
-    end
-end
diff --git a/source/isSensorValid.m b/source/isSensorValid.m
deleted file mode 100644
index fb01ec7450066457e9698d622f0f1dbedccf00b4..0000000000000000000000000000000000000000
--- a/source/isSensorValid.m
+++ /dev/null
@@ -1,9 +0,0 @@
-function isValid = isSensorValid(sensor)
-% Returns whether given sensor object is valid or not.
-    isValid = 0;
-    if ~isempty(sensor)
-        if isa(sensor, 'Sensor') && sensor.isvalid
-            isValid = 1;
-        end
-    end
-end
diff --git a/source/isSyncedBitfield.m b/source/isSyncedBitfield.m
new file mode 100644
index 0000000000000000000000000000000000000000..08ae85cd8e4c6d92a420b0e3f4591125b084d0fd
--- /dev/null
+++ b/source/isSyncedBitfield.m
@@ -0,0 +1,21 @@
+function [isSynced, bit1, bit2] = isSyncedBitfield(bitfield)
+% A SyncMotor-port is the sum of the two ports to sync
+% -> As motor ports are represented by bitfields, check how many bits are set (2
+% bits = 2 ports).
+% -> Just checking 'port' against allowed values would have been too easy :)
+    bit1 = 0; bit2 = 0;
+
+    setBits = [];
+    for i=1:4
+        if bitget(bitfield, i) == 1
+            setBits = [setBits, i];
+        end
+    end
+
+    isSynced = (bitfield<=15)&&(length(setBits)==2);
+    if isSynced
+        bit1 = setBits(1);
+        bit2 = setBits(2);
+    end
+end
+
diff --git a/source/port2bitfield.m b/source/port2bitfield.m
index b4e5de428fc1bd46ea7a41bd3c9a0745c49afca3..9f8d2c7400167d075ca76bca03ef29a91f2d94b6 100644
--- a/source/port2bitfield.m
+++ b/source/port2bitfield.m
@@ -1,8 +1,8 @@
 function bitfield = port2bitfield(varargin)
-% Converts a motorPort-enum to motorBitfield-enum.
+% Converts motor-port-number(s) to motor-bitfield.
     if nargin==1
-        bitfield = MotorBitfield(2 ^ varargin{1});
+        bitfield = uint8(2 ^ varargin{1});
     elseif nargin==2
-        bitfield = MotorBitfield(2 ^ (varargin{1}+varargin{2}));
+        bitfield = uint8(2 ^varargin{1}+2^varargin{2});
     end
 end
diff --git a/source/port2input.m b/source/port2input.m
index cd3bbadf8fdac156638db5df37d4df4e40a95a7d..58c3076dcfbcf7cf8d6c0879022fadba9bc3fbbc 100644
--- a/source/port2input.m
+++ b/source/port2input.m
@@ -1,4 +1,4 @@
 function input = port2input(port)
-% Converts a motorPort-enum to motorInput-enum.
-    input = MotorInput(port+16);
+% Converts a motor-port-number to motor-inputport-number.
+    input = uint8(port)+16;
 end
\ No newline at end of file
diff --git a/source/port2str.m b/source/port2str.m
index 696b990dac243c314e87182cc9bc481d2298d1af..048613d4287fe11a98eb2065fa914883e91dd814 100644
--- a/source/port2str.m
+++ b/source/port2str.m
@@ -1,72 +1,82 @@
-function port = port2str(device, inp)
+function portStr = port2str(varargin)
 % Converts a port-enum to corresponding-string.
-    if ~ischar(device)
-        error(['port2str: First argument has to be a string (''Sensor'', ',...
-            '''Motor'' or ''SyncMotor'')']); 
+    p = inputParser();
+    
+    validDevices = {'Motor', 'Sensor', 'SyncMotor'};
+    validPortTypes = {'Bitfield', 'PortNo', 'InputPortNo'};
+    checkDevice = @(x) ismember(x, validDevices);
+    checkPortType = @(x) ismember(x, validPortTypes);
+    
+    p.addRequired('device', checkDevice);
+    p.addRequired('port');
+    p.addOptional('portType', 'Bitfield', checkPortType);
+    
+    p.parse(varargin{:});
+    
+    device = p.Results.device;
+    port = p.Results.port;
+    portType = p.Results.portType;
+    
+    if ~isPortEnumValid(device, port)
+        error('port2str: Given parameter is not a valid port-enum'); 
     end
     
     if strcmpi(device, 'Motor')
-        if ~ischar(inp)
-            if inp == MotorBitfield.MotorA || inp == MotorPort.MotorA || ...
-                    inp == MotorInput.MotorA
-                port = 'A';
-            elseif inp == MotorBitfield.MotorB || inp == MotorPort.MotorB || ...
-                    inp == MotorInput.MotorB
-                port = 'B';
-            elseif inp == MotorBitfield.MotorC || inp == MotorPort.MotorC || ...
-                    inp == MotorInput.MotorC
-                port = 'C';
-            elseif inp == MotorBitfield.MotorD || inp == MotorPort.MotorD || ...
-                    inp == MotorInput.MotorD
-                port = 'D';            
-            else
-                error('port2str: Given parameter is not a valid motor port.' );
+        if strcmpi(portType, 'Bitfield')
+            if port == MotorBitfield.MotorA
+                portStr = 'A';
+            elseif port == MotorBitfield.MotorB
+                portStr = 'B';
+            elseif port == MotorBitfield.MotorC
+                portStr = 'C';
+            elseif port == MotorBitfield.MotorD
+                portStr = 'D';            
+            end
+        elseif strcmpi(portType, 'PortNo')
+            if port == MotorPort.MotorA
+                portStr = 'A';
+            elseif port == MotorPort.MotorB
+                portStr = 'B';
+            elseif port == MotorPort.MotorC
+                portStr = 'C';
+            elseif port == MotorPort.MotorD
+                portStr = 'D';            
+            end
+        elseif strcmpi(portType, 'InputPortNo')
+            if port == MotorInput.MotorA
+                portStr = 'A';
+            elseif port == MotorInput.MotorB
+                portStr = 'B';
+            elseif port == MotorInput.MotorC
+                portStr = 'C';
+            elseif port == MotorInput.MotorD
+                portStr = 'D';            
             end
-        else
-            warning('port2str: Given parameter already is a string.');
-            port = inp;
         end
     elseif strcmpi(device, 'Sensor')
-        if ~ischar(inp)
-            if inp == SensorPort.Sensor1
-                port = '1';
-            elseif inp == SensorPort.Sensor2
-                port = '2';
-            elseif inp == SensorPort.Sensor3
-                port = '3';
-            elseif inp == SensorPort.Sensor4
-                port = '4';            
-            else
-                error('port2str: Given parameter is not a valid sensor port.' );
-            end
-        else
-            warning('port2str: Given parameter already is a string.');
-            port = inp;
+        if port == SensorPort.Sensor1
+            portStr = '1';
+        elseif port == SensorPort.Sensor2
+            portStr = '2';
+        elseif port == SensorPort.Sensor3
+            portStr = '3';
+        elseif port == SensorPort.Sensor4
+            portStr = '4'; 
         end
     elseif strcmpi(device, 'SyncMotor')
-        if ~ischar(inp)
-            switch inp
-                case MotorBitfield.MotorA+MotorBitfield.MotorB
-                    port = 'AB';
-                case MotorBitfield.MotorA+MotorBitfield.MotorC
-                    port = 'AC';
-                case MotorBitfield.MotorA+MotorBitfield.MotorD
-                    port = 'AD';
-                case MotorBitfield.MotorB+MotorBitfield.MotorC
-                    port = 'BC';
-                case MotorBitfield.MotorB+MotorBitfield.MotorD
-                    port = 'BD';
-                case MotorBitfield.MotorC+MotorBitfield.MotorD
-                    port = 'CD';
-                otherwise
-                    error('port2str: Given parameter is not a valid motor port.' );
-            end
-        else
-            warning('port2str: Given parameter already is a string.');
-            port = inp;
+        switch port
+            case MotorBitfield.MotorA+MotorBitfield.MotorB
+                portStr = 'AB';
+            case MotorBitfield.MotorA+MotorBitfield.MotorC
+                portStr = 'AC';
+            case MotorBitfield.MotorA+MotorBitfield.MotorD
+                portStr = 'AD';
+            case MotorBitfield.MotorB+MotorBitfield.MotorC
+                portStr = 'BC';
+            case MotorBitfield.MotorB+MotorBitfield.MotorD
+                portStr = 'BD';
+            case MotorBitfield.MotorC+MotorBitfield.MotorD
+                portStr = 'CD';
         end
-    else
-        error(['port2str: First argument has to be either ''Sensor'', ',...
-               '''Motor'' or ''SyncMotor''']);
     end
 end
\ No newline at end of file
diff --git a/source/str2PortParam.m b/source/str2PortParam.m
index 75fdb6d3eb5708f8e7350da4b14aad3a68b3a4e0..0f2a139b78b6e717f3fb9cadb7c7af676ed21163 100644
--- a/source/str2PortParam.m
+++ b/source/str2PortParam.m
@@ -34,109 +34,109 @@ function varargout = str2PortParam(device, port)
 
     if strcmpi(device, 'Motor')
         if strcmpi(port, 'A')
-            varargout{1} = uint8(MotorBitfield.MotorA);
-            varargout{2} = uint8(MotorPort.MotorA);
-            varargout{3} = uint8(MotorInput.MotorA);
+            varargout{1} = MotorBitfield.MotorA;
+            varargout{2} = MotorPort.MotorA;
+            varargout{3} = MotorInput.MotorA;
         elseif strcmpi(port, 'B')
-            varargout{1} = uint8(MotorBitfield.MotorB);
-            varargout{2} = uint8(MotorPort.MotorB);
-            varargout{3} = uint8(MotorInput.MotorB);
+            varargout{1} = MotorBitfield.MotorB;
+            varargout{2} = MotorPort.MotorB;
+            varargout{3} = MotorInput.MotorB;
         elseif strcmpi(port, 'C')
-            varargout{1} = uint8(MotorBitfield.MotorC);
-            varargout{2} = uint8(MotorPort.MotorC);
-            varargout{3} = uint8(MotorInput.MotorC);
+            varargout{1} = MotorBitfield.MotorC;
+            varargout{2} = MotorPort.MotorC;
+            varargout{3} = MotorInput.MotorC;
         elseif strcmpi(port, 'D')
-            varargout{1} = uint8(MotorBitfield.MotorD);
-            varargout{2} = uint8(MotorPort.MotorD);
-            varargout{3} = uint8(MotorInput.MotorD);
+            varargout{1} = MotorBitfield.MotorD;
+            varargout{2} = MotorPort.MotorD;
+            varargout{3} = MotorInput.MotorD;
         else
             error('str2PortParam: Given port is not a valid motor port.');
         end
     elseif strcmpi(device, 'Sensor')
         if strcmpi(port, '1')
-            varargout{1} = uint8(SensorPort.Sensor1);
+            varargout{1} = SensorPort.Sensor1;
         elseif strcmpi(port, '2')
-            varargout{1} = uint8(SensorPort.Sensor2);
+            varargout{1} = SensorPort.Sensor2;
         elseif strcmpi(port, '3')
-            varargout{1} = uint8(SensorPort.Sensor3);
+            varargout{1} = SensorPort.Sensor3;
         elseif strcmpi(port, '4')
-            varargout{1} = uint8(SensorPort.Sensor4);
+            varargout{1} = SensorPort.Sensor4;
         else
             error('str2PortParam: Given parameter not a valid sensor port.');
         end
     elseif strcmpi(device, 'SyncMotor')
         if strcmpi(port,'AB')
             varargout{1} = MotorBitfield.MotorA+MotorBitfield.MotorB;
-            varargout{2} = uint8(MotorPort.MotorA);
-            varargout{3} = uint8(MotorInput.MotorA);
-            varargout{4} = uint8(MotorPort.MotorB);
-            varargout{5} = uint8(MotorInput.MotorB);
+            varargout{2} = MotorPort.MotorA;
+            varargout{3} = MotorInput.MotorA;
+            varargout{4} = MotorPort.MotorB;
+            varargout{5} = MotorInput.MotorB;
         elseif strcmpi(port,'AC')
             varargout{1} = MotorBitfield.MotorA+MotorBitfield.MotorC;
-            varargout{2} = uint8(MotorPort.MotorA);
-            varargout{3} = uint8(MotorInput.MotorA);
-            varargout{4} = uint8(MotorPort.MotorC);
-            varargout{5} = uint8(MotorInput.MotorC);
+            varargout{2} = MotorPort.MotorA;
+            varargout{3} = MotorInput.MotorA;
+            varargout{4} = MotorPort.MotorC;
+            varargout{5} = MotorInput.MotorC;
         elseif strcmpi(port,'AD')
             varargout{1} = MotorBitfield.MotorA+MotorBitfield.MotorD;
-            varargout{2} = uint8(MotorPort.MotorA);
-            varargout{3} = uint8(MotorInput.MotorA);
-            varargout{4} = uint8(MotorPort.MotorD);
-            varargout{5} = uint8(MotorInput.MotorD);
+            varargout{2} = MotorPort.MotorA;
+            varargout{3} = MotorInput.MotorA;
+            varargout{4} = MotorPort.MotorD;
+            varargout{5} = MotorInput.MotorD;
         elseif strcmpi(port,'BA')
             varargout{1} = MotorBitfield.MotorB+MotorBitfield.MotorA;
-            varargout{2} = uint8(MotorPort.MotorB);
-            varargout{3} = uint8(MotorInput.MotorB);
-            varargout{4} = uint8(MotorPort.MotorA);
-            varargout{5} = uint8(MotorInput.MotorA);
+            varargout{2} = MotorPort.MotorB;
+            varargout{3} = MotorInput.MotorB;
+            varargout{4} = MotorPort.MotorA;
+            varargout{5} = MotorInput.MotorA;
         elseif strcmpi(port,'BC')
             varargout{1} = MotorBitfield.MotorB+MotorBitfield.MotorC;
-            varargout{2} = uint8(MotorPort.MotorB);
-            varargout{3} = uint8(MotorInput.MotorB);
-            varargout{4} = uint8(MotorPort.MotorC);
-            varargout{5} = uint8(MotorInput.MotorC);
+            varargout{2} = MotorPort.MotorB;
+            varargout{3} = MotorInput.MotorB;
+            varargout{4} = MotorPort.MotorC;
+            varargout{5} = MotorInput.MotorC;
         elseif strcmpi(port,'BD')
             varargout{1} = MotorBitfield.MotorB+MotorBitfield.MotorD;
-            varargout{2} = uint8(MotorPort.MotorB);
-            varargout{3} = uint8(MotorInput.MotorB);
-            varargout{4} = uint8(MotorPort.MotorD);
-            varargout{5} = uint8(MotorInput.MotorD);
+            varargout{2} = MotorPort.MotorB;
+            varargout{3} = MotorInput.MotorB;
+            varargout{4} = MotorPort.MotorD;
+            varargout{5} = MotorInput.MotorD;
         elseif strcmpi(port,'CA')
             varargout{1} = MotorBitfield.MotorC+MotorBitfield.MotorA;
-            varargout{2} = uint8(MotorPort.MotorC);
-            varargout{3} = uint8(MotorInput.MotorC);
-            varargout{4} = uint8(MotorPort.MotorA);
-            varargout{5} = uint8(MotorInput.MotorA);
+            varargout{2} = MotorPort.MotorC;
+            varargout{3} = MotorInput.MotorC;
+            varargout{4} = MotorPort.MotorA;
+            varargout{5} = MotorInput.MotorA;
         elseif strcmpi(port,'CB')
             varargout{1} = MotorBitfield.MotorC+MotorBitfield.MotorB;
-            varargout{2} = uint8(MotorPort.MotorC);
-            varargout{3} = uint8(MotorInput.MotorC);
-            varargout{4} = uint8(MotorPort.MotorB);
-            varargout{5} = uint8(MotorInput.MotorB);
+            varargout{2} = MotorPort.MotorC;
+            varargout{3} = MotorInput.MotorC;
+            varargout{4} = MotorPort.MotorB;
+            varargout{5} = MotorInput.MotorB;
         elseif strcmpi(port,'CD')
             varargout{1} = MotorBitfield.MotorC+MotorBitfield.MotorD;
-            varargout{2} = uint8(MotorPort.MotorC);
-            varargout{3} = uint8(MotorInput.MotorC);
-            varargout{4} = uint8(MotorPort.MotorD);
-            varargout{5} = uint8(MotorInput.MotorD);
+            varargout{2} = MotorPort.MotorC;
+            varargout{3} = MotorInput.MotorC;
+            varargout{4} = MotorPort.MotorD;
+            varargout{5} = MotorInput.MotorD;
         elseif strcmpi(port,'DA')
             varargout{1} = MotorBitfield.MotorD+MotorBitfield.MotorA;
-            varargout{2} = uint8(MotorPort.MotorD);
-            varargout{3} = uint8(MotorInput.MotorD);
-            varargout{4} = uint8(MotorPort.MotorA);
-            varargout{5} = uint8(MotorInput.MotorA);
+            varargout{2} = MotorPort.MotorD;
+            varargout{3} = MotorInput.MotorD;
+            varargout{4} = MotorPort.MotorA;
+            varargout{5} = MotorInput.MotorA;
         elseif strcmpi(port,'DB')
             varargout{1} = MotorBitfield.MotorD+MotorBitfield.MotorB;
-            varargout{2} = uint8(MotorPort.MotorD);
-            varargout{3} = uint8(MotorInput.MotorD);
-            varargout{4} = uint8(MotorPort.MotorB);
-            varargout{5} = uint8(MotorInput.MotorB);
+            varargout{2} = MotorPort.MotorD;
+            varargout{3} = MotorInput.MotorD;
+            varargout{4} = MotorPort.MotorB;
+            varargout{5} = MotorInput.MotorB;
         elseif strcmpi(port,'DC')
             varargout{1} = MotorBitfield.MotorD+MotorBitfield.MotorC;
-            varargout{2} = uint8(MotorPort.MotorD);
-            varargout{3} = uint8(MotorInput.MotorD);
-            varargout{4} = uint8(MotorPort.MotorC);
-            varargout{5} = uint8(MotorInput.MotorC);
+            varargout{2} = MotorPort.MotorD;
+            varargout{3} = MotorInput.MotorD;
+            varargout{4} = MotorPort.MotorC;
+            varargout{5} = MotorInput.MotorC;
         else
             error('str2PortParam: Given port is not a valid sync motor port.');
         end
diff --git a/source/str2bool.m b/source/str2bool.m
index 0b88252174b60c6a3d5898713acc55e473354077..cc656222399c3bb8957f7aa11119e2919f7baa7e 100644
--- a/source/str2bool.m
+++ b/source/str2bool.m
@@ -3,15 +3,12 @@ function bool = str2bool(inp)
 
     bool = 0;
     if ischar(inp)
-        if strcmpi(inp, 'on') || strcmpi(inp, 'true')
+        if strcmpi(inp, 'on')
             bool = 1;
-        elseif ~strcmpi(inp, 'off') && ~strcmpi(inp, 'false')
+        elseif ~strcmpi(inp, 'off')
             error('str2bool: Given parameter is not a valid string.');
         end
-    elseif isnumeric(inp)
-        % warning('str2bool: Given parameter already is a numeric. Returning...');
-        if bool==0 || bool==1
-            bool = inp;
-        end
+    elseif isnumeric(inp) || islogical(inp)
+        bool = inp;
     end
 end