Cirkit Designer LogoCirkit DesignerYour all-in-one circuit design IDE Launch Cirkit Designer App

How to Use Float Switch: Examples, Pinouts, and Specs

Image of Float SwitchDesign with Float Switch in Cirkit Designer

Introduction

A float switch is an essential device used to detect and control the level of liquid within a tank or container. It operates on a simple mechanism: a buoyant float is attached to a switch, which activates as the liquid level rises or falls. This makes float switches ideal for applications such as automatic water level control in tanks, sump pump activation, and overflow prevention.

Explore Projects Built with Float Switch

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of Arduino-Based Automatic Drainage Water Monitoring & Flood Control System with Air Quality and Pressure Sensors: A project utilizing Float Switch in a practical application
Arduino-Based Automatic Drainage Water Monitoring & Flood Control System with Air Quality and Pressure Sensors

This circuit is an Arduino-based automatic drainage water monitoring and flood control system. It uses a float switch, MQ135 air quality sensor, and pressure sensor to monitor environmental conditions and control a relay module that operates a DC motor and solenoid valve. The system includes LEDs for status indication and a stop button to manually halt operations.

Open Project in Cirkit Designer
Image of ESP8266-Based Water Level Detection System: A project utilizing Float Switch in a practical application
ESP8266-Based Water Level Detection System

This circuit features an ESP8266 microcontroller connected to a water level float switch sensor. The ESP8266's ground (G) is connected to one wire of the float switch, and one of its digital pins (D0) is connected to the other wire of the float switch. The purpose of this circuit is likely to monitor the water level and send the status wirelessly using the ESP8266's WiFi capabilities.

Open Project in Cirkit Designer

Common Applications and Use Cases

Technical Specifications

Key Technical Details

Pin Configuration and Descriptions

Pin Number Description
1 Common (COM)
2 Normally Closed (NC) Contact
3 Normally Open (NO) Contact

Usage Instructions

How to Use the Component in a Circuit

  1. Identify the Contacts: Determine the COM, NC, and NO contacts on the float switch.
  2. Connect Power: Attach the COM contact to the power supply.
  3. Set Up Control Circuit: Connect the NO or NC contact to the device you wish to control (e.g., a relay or an alarm).
  4. Mount the Float Switch: Secure the float switch at the desired height in the tank or container.
  5. Test the System: Fill the container with liquid to ensure the float switch activates at the correct level.

Important Considerations and Best Practices

Troubleshooting and FAQs

Common Issues

Solutions and Tips

FAQs

Q: Can I use a float switch with any liquid? A: Float switches are designed for use with a variety of liquids, but always check the material compatibility with the specific liquid in your application.

Q: How do I adjust the switch activation point? A: Adjust the mounting height of the float switch to change the activation point.

Q: Is it possible to use a float switch with an Arduino? A: Yes, a float switch can be connected to an Arduino's digital input pin for liquid level sensing.

Example Arduino Code

// Define the float switch pin
const int floatSwitchPin = 2;

void setup() {
  pinMode(floatSwitchPin, INPUT_PULLUP); // Set the float switch pin as an input
  Serial.begin(9600);                    // Start serial communication
}

void loop() {
  // Read the state of the float switch
  int floatSwitchState = digitalRead(floatSwitchPin);

  // Check if the float switch is triggered (assuming NO configuration)
  if (floatSwitchState == LOW) {
    // The liquid level has reached the float switch
    Serial.println("Liquid level high");
  } else {
    // The liquid level is below the float switch
    Serial.println("Liquid level low");
  }

  delay(1000); // Wait for 1 second before reading again
}

Note: The above code assumes the float switch is wired in a Normally Open (NO) configuration. If your switch is Normally Closed (NC), the logic in the if statement will be reversed.