# Hall effect sensor (analog,threshold)

**Type:** Product page · **SKU:** CE09441 · **Brand:** [Core Electronics](https://core-electronics.com.au/brands/core-electronics-australia)
**Page:** https://core-electronics.com.au/hall-effect-sensor-analog-threshold.html ([markdown](https://core-electronics.com.au/hall-effect-sensor-analog-threshold.html.md))

Sense invisible magnetic fields around you! Use the adjustable digital output to set a threshold or the analog output to get a gauge of the distance.

## Pricing

- **Price:** $1.80 (inc GST) — $1.64 AUD, exc GST
- **Quantity discounts:** 25+ $1.55 (exc GST) · 50+ $1.47 (exc GST) · 100+ $1.39 (exc GST)

## Availability & dispatch

- In stock, ships same business day if ordered before 2PM (Australia/Sydney).
- We can dispatch 34 today; more stock is typically available with a 8–12 day lead time.

## Description

Sense invisible magnetic fields around you! Use the adjustable digital output to set a threshold or the analog output to get a gauge of how far away a magnet is or sense ambient fields around you!

Pair with [a small cube magnet](https://core-electronics.com.au/magnet-square-0-125.html) to make a puzzle box or a simple short-distance range sensor.

### Specifications

- Voltage input: 2.7-6.5V
- Onboard LED for power and going over the adjustable threshold

### Examples

#### Raspberry Pi Pico - Micropython

 ```
from machine import ADC, Pin
import time

a0 = ADC(Pin(27))  # Create an ADC object on pin 26 (ADC0)
d0 = Pin(22, Pin.IN, Pin.PULL_UP)  # Digital output from sensor

while True:
    reading = a0.read_u16()  # Read the value from the analog interface
    print("Sensor reading:", reading)
    
    threshold_exceeded = d0.value()  # Read the value from the digital interface
    if threshold_exceeded:
        print("Threshold exceeded!")
    
    time.sleep_ms(500)  # Wait for half a second before reading again
```

## Images

- [Product image 1](https://core-electronics.com.au/media/catalog/product/h/a/hall-effect-sensor.jpg)
