NXC: Dexter pressure sensor

Discussion specific to the intelligent brick, sensors, motors, and more.
Post Reply
HaWe
Posts: 2500
Joined: 04 Nov 2014, 19:00

NXC: Dexter pressure sensor

Post by HaWe »

out of an old nxtasy thread:
NXC: polling the value of the Dexter pressure sensor (70 psi version):

Code: Select all

task main(){
  int val = SensorValue[port];
  pressure = ((val / 1023)  - 0.04) / 0.0018;
}
Post Reply

Who is online

Users browsing this forum: No registered users and 5 guests