KeithRB:
You could also fix it by casting z or x to a float in the first case.
Copy that:
int z = pulseIn(cell, HIGH);
int y = pulseIn(cell, LOW);
float x = z + y;
float w = z / x;
int v = w * 4000;
KeithRB:
You could also fix it by casting z or x to a float in the first case.
Copy that:
int z = pulseIn(cell, HIGH);
int y = pulseIn(cell, LOW);
float x = z + y;
float w = z / x;
int v = w * 4000;