Home / Blog /

MicroController Web-Server: Getting Started

MicroController Web-Server: Getting Started

Before we begin, head over to our GitHub repository (link in the description) and copy the repository link which you can find when clicking the the green code button.

This repository contains all the code for our WebServer.

  1. Ensure your microcontroller is powered and connected to your computer with the latest MicroPython firmware installed.

  2. Open a terminal or command prompt and navigate to the directory where you want to store the MicroPython files. Use the cd command to change directories.

To download the necessary files, clone the GitHub repository using the following command:

''' bash git clone https://github.com/gurgleapps/pico-web-server-control.git '''

  • the link is the link you copied from the GitHub repository

This will create a local copy of the repository on your computer.

  1. Open your code editor or IDE (Integrated Development Environment), such as Thonny or Mu.

  2. Open the folder you just downloaded from the GitHub repository.

Upload all the files and folders from the downloaded repository to your microcontroller.

Locate and open the config.py file on your microcontroller. This file may have a different name or location based on your MicroPython version, but its purpose remains the same.

Within the file, locate the placeholders for Wi-Fi SSID and password.

Replace your_wifi_ssid with your Wi-Fi network's name (SSID) and your_wifi_password with your Wi-Fi password.

This step is crucial for your microcontroller to connect to the internet.

In the same config.py file, you may find options that control the onboard LED behavior.

Enabling these options allows the microcontroller to blink its IP address. We don't need to enable these options as the ip address will be shown in repel.

Open the main.py file in your code editor and run the script. You should see the message "Waiting for connection..." followed by your microcontroller's IP address in the output.

Open your web browser and type http:// followed by the IP address displayed in the script's output. This should lead you to the microcontroller's web interface.