ESP8266 does not stop to broadcast SSID

All ESP8266 boards running MicroPython.
Official boards are the Adafruit Huzzah and Feather boards.
Target audience: MicroPython users with an ESP8266 board.
Post Reply
thunder2000nt
Posts: 2
Joined: Thu May 14, 2020 2:49 am

ESP8266 does not stop to broadcast SSID

Post by thunder2000nt » Thu May 14, 2020 3:00 am

Hello everyone,

I have a concerned about my ESP8266 board, the code that I'm using is allowing to connect to my home wifi, but when I ran the wifi analyzer I noticed that this board was broadcasting and SSID called Microphyton-774081.

the code that I'm using to connect to the wifi is as follow:

import machine
import network
import bme280_Rev2
from machine import Pin, I2C
ssid = 'My-Home_SSID'
password = 'My-Wifi-Password'

station = network.WLAN(network.STA)
station.active(True)
station.connect(ssid, password)

Is there a way to stop broadcasting that SSID?

Thanks in advance.

kevinkk525
Posts: 721
Joined: Sat Feb 03, 2018 7:02 pm

Re: ESP8266 does not stop to broadcast SSID

Post by kevinkk525 » Thu May 14, 2020 10:14 am

ap=network.WLAN(network.AP_IF)
ap.active(False)

Turns off the access point.
Kevin Köck
Micropython Smarthome Firmware (with Home-Assistant integration): https://github.com/kevinkk525/pysmartnode

thunder2000nt
Posts: 2
Joined: Thu May 14, 2020 2:49 am

Re: ESP8266 does not stop to broadcast SSID

Post by thunder2000nt » Sat May 16, 2020 2:35 am

Hey Kevin, thanks very much for your answer. I have modified my code and it looks like this:

Code: Select all

import network
from network import WLAN

#WiFi information
ssid = 'My Wifi SSID' 
password = 'Wifi Password'

#Connect ESP8266 to the WiFi
wlan = network.WLAN(network.STA_IF)
wlan.active(True)

ap=network.WLAN(network.AP_IF)
ap.active(False)	#Turns off the access point and avoid to broadcast the Microcontroller SSID

wlan.connect(ssid,password) # Connect to the Wifi
Thanks a lot buddy!
:)

Post Reply