private byte[] createMeshAddressingHeader(byte[] packet){
		int packetPosition = 0;
		byte actualByte = packet[packetPosition];
		
		//check length of originatorAddress (xxYxxxxx)
		int maskedByte = (actualByte&(byte)32) & 0xFF;
		if(maskedByte == 32){
			vFlag = true;
		} else {
			vFlag = false;
		}
		
		//check length of finalAddress (xxYxxxxx)
		maskedByte = (actualByte&(byte)16) & 0xFF;
		if(maskedByte == 16){
			fFlag = true;
		} else {
			fFlag = false;
		}
		
		//get the hops left
		maskedByte = (actualByte&(byte)15) & 0xFF;
		hopsLeft = maskedByte;
		packetPosition ++;
		
		//get orginatorAddress
		if(vFlag){
			originatorAddress = Arrays.copyOfRange(packet, packetPosition, packetPosition+2);
			packetPosition += 2;
		} else {
			originatorAddress = Arrays.copyOfRange(packet, packetPosition, packetPosition+8);
			packetPosition += 8;
		}
		
		//get finalAddress
		if(fFlag){
			finalAddress = Arrays.copyOfRange(packet, packetPosition, packetPosition+2);
			packetPosition += 2;
		} else {
			finalAddress = Arrays.copyOfRange(packet, packetPosition, packetPosition+8);
			packetPosition += 8;
		}
		
		headerSize += packetPosition;
		//return the remaining payload
		return Arrays.copyOfRange(packet, packetPosition, packet.length);
	}