Magnetic Hall Module (Analog) Sensor

Magnetic Hall Module (Analog)

  • $3.15


Analog Magnetic Hall Module Code


/* SETUP

Analog Hall    Arduino
-       -      GND
        -      5V
S       -      A5
*/
 
int sensorPin = A5;    // select the input pin
int ledPin = 13;       // select the pin for the LED
int sensorValue = 0;   // variable to store the value coming from the sensor
 
void setup () {
  pinMode (ledPin, OUTPUT);
  Serial.begin (9600);
}
 
void loop () {
  sensorValue = analogRead (sensorPin);
  digitalWrite (ledPin, HIGH);
  delay (sensorValue);
  digitalWrite (ledPin, LOW);
  delay (sensorValue);
  Serial.println (sensorValue, DEC);
}

We Also Recommend


where to buy Magnetic Hall in toronto

Magnetic Hall toronto

buy Magnetic Hall toronto