WiFiMCU Wireless WiFi Development Board Using Lua From EMW3165 diy rc toy EMW 3165 remote control

SINONING

$8.79 

Introduction

WiFiMCU is developed based on EMW3165 by Headquarters EMW3165. Run the Lua script directly; operate hardware resource; achieve product prototypes. EMW3165 is a low-power embedded WiFi module, which is developed by the Shanghai MXCHIP Technology Co., Ltd. It incorporates a WiFi RF-Chip and a microcontroller based on STM Cortex-M4. The WiFi module includes a "self-hosted" WiFi network library and application components. In addition, it also provides 2M bytes of out-chip flash, 512K bytes of on-chip flash, 128K bytes of RAM, and a rich peripheral resources.

Hardware Feature

Cortex-M4 microcotroller

  • STM32F411CE

  • 100MHz,Cortex-M4 core

  • 2M bytes of SPI flash and 512K bytes of on-chip flash

  • 128K bytes of RAM

Multi-Interface

  • 22 GPIO Pin

  • 3 UARTs

  • ADC/SPI/I2C/USB

  • SWD debug interface

  • PWM

Broadcom IEEE 802.11 b/g/n RF Chip

Operation Temperature:-30  ~ +85

Software Feature

  • Lua Interpreter,Serial Interation,WiFi and Net Module,File System,Interface Module

  • tcp/udp debugging tool

  • serial debugging tool(puttyTera Term Pro),serial parameters:115200,n,8,1

  • Startup

Demo

 

  • Build AP

  • >cfg={ssid='Doit_3165',pwd=''} >wifi.startap(cfg)
  • WebServer

  • >cfg={ssid='Doit_3165',pwd=''} wifi.startap(cfg) >function listen_cb(c,ip,port)     c:on("disconnect",function(c) end)     c:on("sent",function(con) end)     c:on("receive",function(c,pl)     c:send([[HTTP/1.1 200 OK Server: WiFiMCU Content-Type:text/html Content-Length: 19 Connection: close]]..'\r\n\r\n'..[[ Welcome to WiFiMCU!]]) end) end >sk=net.new(net.TCP,net.SERVER) sk:listen(80,listen_cb)
  • Connect Wireless Router

  • >print(wifi.sta.getip()) 0.0.0.0 >cfg={ssid="Doit",pwd="123456789"} wifi.startsta(cfg) >print(wifi.sta.getip()) 192.168.1.112
  • Connect Remote Server

  • >sk2=net.new(net.TCP,net.CLIENT) >sk2:on("connect",function(c) print("client connected") c:send("From WiFiMCU") end) >sk2:on("receive",function(c,pl) print("receive data:"..pl) c:send("Hello WiFiMCU")end) >sk2:connect(6579,"115.29.109.104")
  • GPIO Operation

  • >gpio.mode(6,gpio.INPUT) >print(gpio.read(6)) 0 >print(gpio.read(6)) 1 >gpio.mode(6,gpio.OUTPUT) >gpio.write(6,gpio.HIGH)
  • Timer Operation

  • > function tmr_cb() print('tmr1 is called') end > tmr.start(1,1000,tmr_cb) > tmr1 is called
  • File Operation

  • > file.open ("test.lua","w+") > file.write("this is a test") > file.close() > file.open ("test.lua","r") > data=file.read() > print(data) this is a test > file.close() >
  • Self-Start

  • >file.open ("init.lua","w+") >file.write("print('Hello world!')") >file.close() >mcu.reboot()
  •  

Shipping List

  • WiFiMCU: 1pcs

Our brands