fixed IDs on arduino, changed calculation of parameters