Raspberry - arduino over i2C, multi bytes

Here is code snipet of code that can transfer multi bytes over i2C between Raspberry - Arduino:

 

Raspberry

def writeNumber(value): 
#bus.write_byte(address, value) 
try: 
  bus.write_byte_data(address, 0, value) 
except: 
  return "No communication" 
return -1 
 
def readNumber(): 
number = list() 
try: 
  number = bus.read_i2c_block_data(address,0) 
except: 
  return "No communication" 
#print number max = int(number[0]) 
if (max >= len(number)): 
  return st = list() 
for i in range (max): 
  st.append(chr(number[i+2])) 
st = ''.join(st) 
#number = bus.read_byte_data(address, 5) 
return st while True: time.sleep(1) 
writeNumber(I2C_GPS_POSITION) 
gps = readNumber() 
writeNumber(I2C_GPS_ADDITION) 
gps2 = readNumber() 
print gps + " " + gps2

Arduino

Wire.onReceive(receiveData); 
Wire.onRequest(sendData); 
void receiveData(int byteCount){
  while(Wire.available()) { 
      short sta = Wire.read(); 
      if (sta > 0) 
	i2cstatus = sta; 
    }	 
 }
 
void sendData(){ 
  if (i2cstatus == I2C_GPS_POSITION){ 
      String out = "" + String(gps.location.isValid()) + " " + 
	  String(gps.location.lat(),5) + " " + String(gps.location.lng(),5); 
      sendI2cString(I2C_GPS_POSITION, out); 
  } else if (i2cstatus == I2C_GPS_ADDITION){ 
      String out = "" + String(gps.location.isValid()) + " " + 
	  String(gps.speed.mps(),1) + " " + String(gps.course.deg(),1); 
      sendI2cString(I2C_GPS_ADDITION, out); 
  } 
} 
void sendI2cString(short id, String data){
  data += " "; char out[data.length()]; 
  data.toCharArray(out, data.length()); 
  sendI2cData(id, out, data.length() - 1); 
} 
void sendI2cData(short id, char data[], short data_size){ 
  char out[data_size+3]; 
  if (data_size > 29){ 
      out[0] = byte (5); 
      out[1] = id; 
      out[2] = 'E'; 
      out[3] = 'r'; 
      out[4] = 'r'; 
      out[5] = 'o'; 
      out[6] = 'r'; 
      Wire.write(out); 
      return; 
  }
 
  out[0] = byte (data_size); 
  out[1] = byte (1); 
  for (int i = 0; i < data_size; ++i){ 
      out[i+2] = data[i]; 
  } 
  Wire.write(out); 
}