当前位置: 首页 > news >正文

制作网站的图片哪来电子商务网站建设初学视频教程

制作网站的图片哪来,电子商务网站建设初学视频教程,温州网站链接怎么做,wordpress 分类折叠知识点:什么是掌控板? 掌控板是一块普及STEAM创客教育、人工智能教育、机器人编程教育的开源智能硬件。它集成ESP-32高性能双核芯片,支持WiFi和蓝牙双模通信,可作为物联网节点,实现物联网应用。同时掌控板上集成了OLED…

知识点:什么是掌控板?
掌控板是一块普及STEAM创客教育、人工智能教育、机器人编程教育的开源智能硬件。它集成ESP-32高性能双核芯片,支持WiFi和蓝牙双模通信,可作为物联网节点,实现物联网应用。同时掌控板上集成了OLED显示屏、RGB灯、加速度计、麦克风、光线传感器、蜂鸣器、按键开关、触摸开关、金手指外部拓展接口,支持图形化及MicroPython代码编程,可实现智能机器人、创客智造作品等智能控制类应用。

在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

掌控板硬件特性:
ESP-32主控
处理器:Tensilica LX6双核处理器(一核处理高速连接;一核独立应用开发)
主频:高达240MHz的时钟频率
SRAM:520KB
Flash:8MB
Wi-Fi标准:FCC/CE/TELEC/KCC
Wi-Fi协议:802.11 b/g/n/d/e/i/k/r (802.11n,速度高达150 Mbps),A-MPDU和A-MSDU聚合,支持0.4us防护间隔
频率范围:2.4~2.5 GHz
蓝牙协议:符合蓝牙v4.2 BR/EDR和BLE标准
蓝牙音频:CVSD和SBC音频低功耗:10uA
供电方式:Micro USB供电
工作电压:3.3V
最大工作电流:200mA
最大负载电流:1000mA
掌控板载
三轴加速度计MSA300,测量范围:±2/4/8/16G
地磁传感器MMC5983MA,测量范围:±8 Gauss;精度0.4mGz,电子罗盘误差±0.5°
光线传感器
麦克风
3 颗全彩ws2812灯珠
1.3英寸OLED显示屏,支持16*16字符显示,分辨率128x64
无源蜂鸣器
支持2个物理按键(A/B)、6个触摸按键
支持1路鳄鱼夹接口,可方便接入各种阻性传感器
拓展接口
20通道数字I/O, (其中支持12路PWM,6路触摸输入)
5通道12bit模拟输入ADC,P0~P4
1路的外部输入鳄鱼夹接口:EXT/GND
支持I2C、UART、SPI通讯协议

在这里插入图片描述
在这里插入图片描述
7、6个触摸按键控制RGB灯并显示按键名

#MicroPython动手做(17)——掌控板之触摸引脚
#6个触摸按键控制RGB灯并显示按键名from mpython import *from machine import Timerimport time_status_p = _status_y = _status_t = _status_h = _status_o = _status_n = 0
def on_touchpad_P_pressed():pass
def on_touchpad_P_unpressed():pass
def on_touchpad_Y_pressed():pass
def on_touchpad_Y_unpressed():pass
def on_touchpad_T_pressed():pass
def on_touchpad_T_unpressed():pass
def on_touchpad_H_pressed():pass
def on_touchpad_H_unpressed():pass
def on_touchpad_O_pressed():pass
def on_touchpad_O_unpressed():pass
def on_touchpad_N_pressed():pass
def on_touchpad_N_unpressed():passtim12 = Timer(12)def timer12_tick(_):global _status_p, _status_y, _status_t, _status_h, _status_o, _status_ntry:touchPad_P.read();passexcept:returnif touchPad_P.read() < 400:if 1 != _status_p:_status_p = 1;on_touchpad_P_pressed()elif 0 != _status_p:_status_p = 0;on_touchpad_P_unpressed()if touchPad_Y.read() < 400:if 1 != _status_y:_status_y = 1;on_touchpad_Y_pressed()elif 0 != _status_y:_status_y = 0;on_touchpad_Y_unpressed()if touchPad_T.read() < 400:if 1 != _status_t:_status_t = 1;on_touchpad_T_pressed()elif 0 != _status_t:_status_t = 0;on_touchpad_T_unpressed()if touchPad_H.read() < 400:if 1 != _status_h:_status_h = 1;on_touchpad_H_pressed()elif 0 != _status_h:_status_h = 0;on_touchpad_H_unpressed()if touchPad_O.read() < 400:if 1 != _status_o:_status_o = 1;on_touchpad_O_pressed()elif 0 != _status_o:_status_o = 0;on_touchpad_O_unpressed()if touchPad_N.read() < 400:if 1 != _status_n:_status_n = 1;on_touchpad_N_pressed()elif 0 != _status_n:_status_n = 0;on_touchpad_N_unpressed()tim12.init(period=100, mode=Timer.PERIODIC, callback=timer12_tick)def on_touchpad_P_pressed():global ioled.fill(0)oled.DispChar('P', 60, 22, 1)oled.show()rgb[0] = (int(255), int(0), int(0))rgb.write()time.sleep_ms(1)time.sleep(1)rgb.fill( (0, 0, 0) )rgb.write()time.sleep_ms(1)def on_touchpad_H_pressed():global ioled.fill(0)oled.DispChar('H', 60, 22, 1)oled.show()rgb[0] = (int(255), int(102), int(0))rgb.write()time.sleep_ms(1)time.sleep(1)rgb.fill( (0, 0, 0) )rgb.write()time.sleep_ms(1)def on_touchpad_Y_pressed():global ioled.fill(0)oled.DispChar('Y', 60, 22, 1)oled.show()rgb[1] = (int(0), int(153), int(0))rgb.write()time.sleep_ms(1)time.sleep(1)rgb.fill( (0, 0, 0) )rgb.write()time.sleep_ms(1)def on_touchpad_O_pressed():global ioled.fill(0)oled.DispChar('O', 60, 22, 1)oled.show()rgb[0] = (int(255), int(102), int(0))rgb.write()time.sleep_ms(1)rgb[1] = (int(255), int(102), int(0))rgb.write()time.sleep_ms(1)time.sleep(1)rgb.fill( (0, 0, 0) )rgb.write()time.sleep_ms(1)def on_touchpad_T_pressed():global ioled.fill(0)oled.DispChar('T', 60, 22, 1)oled.show()rgb[2] = (int(51), int(51), int(255))rgb.write()time.sleep_ms(1)time.sleep(1)rgb.fill( (0, 0, 0) )rgb.write()time.sleep_ms(1)def on_touchpad_N_pressed():global ioled.fill(0)oled.DispChar('N', 60, 22, 1)oled.show()rgb.fill((int(255), int(102), int(0)))rgb.write()time.sleep_ms(1)time.sleep(1)rgb.fill( (0, 0, 0) )rgb.write()time.sleep_ms(1)

mPython 图形编程
在这里插入图片描述

8、简易触摸按键电子琴(6键)

在这里插入图片描述

#MicroPython动手做(17)——掌控板之触摸引脚
#简易触摸按键电子琴(6键)from mpython import *import music
while True:music.stop()if touchPad_P.read() < 400:music.pitch(262, 500)else:if touchPad_Y.read() < 400:music.pitch(294, 500)else:if touchPad_T.read() < 400:music.pitch(330, 500)else:if touchPad_H.read() < 400:music.pitch(349, 500)else:if touchPad_O.read() < 400:music.pitch(392, 500)else:if touchPad_N.read() < 400:music.pitch(440, 500)

mPython 图形编程
在这里插入图片描述

视频:掌控板模拟简易触摸按键电子琴(6键)

https://v.youku.com/v_show/id_XNDY0ODEwMjcxMg==.html?spm=a2hbt.13141534.app.55!25!2555!255!25!25!255A

9、触摸按键点播六首曲子

#MicroPython动手做(17)——掌控板之触摸引脚
# 触摸按键点播六首曲子from mpython import *
import time
import music
from machine import Timerdef on_button_a_down(_):time.sleep_ms(10)if button_a.value() == 1: returnmusic.stop()_status_p = _status_y = _status_t = _status_h = _status_o = _status_n = 0
def on_touchpad_P_pressed():pass
def on_touchpad_P_unpressed():pass
def on_touchpad_Y_pressed():pass
def on_touchpad_Y_unpressed():pass
def on_touchpad_T_pressed():pass
def on_touchpad_T_unpressed():pass
def on_touchpad_H_pressed():pass
def on_touchpad_H_unpressed():pass
def on_touchpad_O_pressed():pass
def on_touchpad_O_unpressed():pass
def on_touchpad_N_pressed():pass
def on_touchpad_N_unpressed():passtim12 = Timer(12)def timer12_tick(_):global _status_p, _status_y, _status_t, _status_h, _status_o, _status_ntry:touchPad_P.read();passexcept:returnif touchPad_P.read() < 400:if 1 != _status_p:_status_p = 1;on_touchpad_P_pressed()elif 0 != _status_p:_status_p = 0;on_touchpad_P_unpressed()if touchPad_Y.read() < 400:if 1 != _status_y:_status_y = 1;on_touchpad_Y_pressed()elif 0 != _status_y:_status_y = 0;on_touchpad_Y_unpressed()if touchPad_T.read() < 400:if 1 != _status_t:_status_t = 1;on_touchpad_T_pressed()elif 0 != _status_t:_status_t = 0;on_touchpad_T_unpressed()if touchPad_H.read() < 400:if 1 != _status_h:_status_h = 1;on_touchpad_H_pressed()elif 0 != _status_h:_status_h = 0;on_touchpad_H_unpressed()if touchPad_O.read() < 400:if 1 != _status_o:_status_o = 1;on_touchpad_O_pressed()elif 0 != _status_o:_status_o = 0;on_touchpad_O_unpressed()if touchPad_N.read() < 400:if 1 != _status_n:_status_n = 1;on_touchpad_N_pressed()elif 0 != _status_n:_status_n = 0;on_touchpad_N_unpressed()tim12.init(period=100, mode=Timer.PERIODIC, callback=timer12_tick)def on_touchpad_P_pressed():music.play(music.DONG_FANG_HONG, wait=False, loop=False)def on_touchpad_Y_pressed():music.play(music.BIRTHDAY, wait=False, loop=False)def on_touchpad_T_pressed():music.play(music.MO_LI_HUA, wait=False, loop=False)def on_touchpad_H_pressed():music.play(music.ODE, wait=False, loop=False)def on_touchpad_O_pressed():music.play(music.PRELUDE, wait=False, loop=False)def on_touchpad_N_pressed():music.play(music.CAI_YUN_ZHUI_YUE, wait=False, loop=False)button_a.irq(trigger=Pin.IRQ_FALLING, handler=on_button_a_down)while True:oled.fill(0)oled.DispChar("A键:停止", 35, 0, 1)oled.DispChar("P:东方红  Y:生日快乐", 6, 20, 1)oled.DispChar("T:茉莉花  H:欢乐颂", 11, 35, 1)oled.DispChar("O:婚宴 N:彩云追月", 13, 50, 1)oled.show()

mPython X 图形编程
在这里插入图片描述

视频:触摸按键点播六首曲子

https://v.youku.com/v_show/id_XNDY1Mzc0MTc0OA==.html?spm=a2h0c.8166622.PhoneSokuUgc_1.dtitle

在这里插入图片描述

10、六个触摸键控制的RGB颜色灯

#MicroPython动手做(17)——掌控板之触摸引脚
#六个触摸键控制的RGB颜色灯from mpython import *
import network
import time
import music
from yeelight import *
from machine import Timermy_wifi = wifi()my_wifi.connectWiFi("zh", "zy1567")_status_p = _status_y = _status_t = _status_h = _status_o = _status_n = 0
def on_touchpad_P_pressed():pass
def on_touchpad_P_unpressed():pass
def on_touchpad_Y_pressed():pass
def on_touchpad_Y_unpressed():pass
def on_touchpad_T_pressed():pass
def on_touchpad_T_unpressed():pass
def on_touchpad_H_pressed():pass
def on_touchpad_H_unpressed():pass
def on_touchpad_O_pressed():pass
def on_touchpad_O_unpressed():pass
def on_touchpad_N_pressed():pass
def on_touchpad_N_unpressed():passtim12 = Timer(12)def timer12_tick(_):global _status_p, _status_y, _status_t, _status_h, _status_o, _status_ntry:touchPad_P.read();passexcept:returnif touchPad_P.read() < 400:if 1 != _status_p:_status_p = 1;on_touchpad_P_pressed()elif 0 != _status_p:_status_p = 0;on_touchpad_P_unpressed()if touchPad_Y.read() < 400:if 1 != _status_y:_status_y = 1;on_touchpad_Y_pressed()elif 0 != _status_y:_status_y = 0;on_touchpad_Y_unpressed()if touchPad_T.read() < 400:if 1 != _status_t:_status_t = 1;on_touchpad_T_pressed()elif 0 != _status_t:_status_t = 0;on_touchpad_T_unpressed()if touchPad_H.read() < 400:if 1 != _status_h:_status_h = 1;on_touchpad_H_pressed()elif 0 != _status_h:_status_h = 0;on_touchpad_H_unpressed()if touchPad_O.read() < 400:if 1 != _status_o:_status_o = 1;on_touchpad_O_pressed()elif 0 != _status_o:_status_o = 0;on_touchpad_O_unpressed()if touchPad_N.read() < 400:if 1 != _status_n:_status_n = 1;on_touchpad_N_pressed()elif 0 != _status_n:_status_n = 0;on_touchpad_N_unpressed()tim12.init(period=100, mode=Timer.PERIODIC, callback=timer12_tick)def on_touchpad_P_pressed():global itime.sleep_ms(500)bulb.set_rgb(153, 0, 0)oled.DispChar("P键  红色", 38, 32, 1)oled.show()rgb.fill((int(153), int(0), int(0)))rgb.write()time.sleep_ms(1)def on_touchpad_Y_pressed():global itime.sleep_ms(500)bulb.set_rgb(0, 153, 0)oled.DispChar("Y键  绿色", 38, 32, 1)oled.show()rgb.fill((int(0), int(153), int(0)))rgb.write()time.sleep_ms(1)def on_touchpad_T_pressed():global itime.sleep_ms(500)bulb.set_rgb(51, 51, 255)oled.DispChar("T键  蓝色", 38, 32, 1)oled.show()rgb.fill((int(51), int(51), int(255)))rgb.write()time.sleep_ms(1)def on_touchpad_H_pressed():global itime.sleep_ms(500)bulb.set_rgb(255, 102, 0)oled.DispChar("H键  橙色", 38, 32, 1)oled.show()rgb.fill((int(153), int(51), int(0)))rgb.write()time.sleep_ms(1)def on_touchpad_O_pressed():global itime.sleep_ms(500)bulb.set_rgb(204, 51, 204)oled.DispChar("O键  紫色", 38, 32, 1)oled.show()rgb.fill((int(102), int(51), int(102)))rgb.write()time.sleep_ms(1)def on_touchpad_N_pressed():global itime.sleep_ms(500)bulb.set_rgb(255, 204, 51)oled.DispChar("N键  黄色", 38, 32, 1)oled.show()rgb.fill((int(153), int(102), int(51)))rgb.write()time.sleep_ms(1)rgb[1] = (int(51), int(51), int(51))
rgb.write()
time.sleep_ms(1)
music.play('G5:1')
bulb = Bulb(discover_bulbs()[0]["ip"])
time.sleep_ms(500)
bulb.turn_on()
oled.fill(0)
oled.DispChar("触摸键控制RGB灯", 18, 16, 1)
oled.show()

mPython X 实验图形编程
在这里插入图片描述

#MicroPython动手做(17)——掌控板之触摸引脚
#六个触摸键控制的RGB颜色灯(实验视频)

https://v.youku.com/v_show/id_XNDcwMTY3MzkxNg==.html?spm=a2h0c.8166622.PhoneSokuUgc_1.dtitle

在这里插入图片描述
11、触摸不同按键,点亮不同色RGB灯

from mpython import *while True:if(touchPad_P.read() < 100):rgb[0] = (255,0,0)    # 开灯,设置红色rgb[1] = (255,0,0)  # 设定为红色rgb[2] = (255,0,0)   # 设置为红色rgb.write()elif(touchPad_Y.read() < 100):rgb[0] = (0,255,0) #关灯rgb[1] = (0,255,0)rgb[2] = (0,255,0)rgb.write()elif(touchPad_T.read() < 100):rgb[0] = (0,0,255) #关灯rgb[1] = (0,0,255)rgb[2] = (0,0,255)rgb.write()elif(touchPad_H.read() < 100):rgb[0] = (255,255,0) #关灯rgb[1] = (255,255,0)rgb[2] = (255,255,0)rgb.write()elif(touchPad_O.read() < 100):rgb[0] = (255,0,255) #关灯rgb[1] = (255,0,255)rgb[2] = (255,0,255)rgb.write()elif(touchPad_N.read() < 100):rgb[0] = (0,255,255) #关灯rgb[1] = (0,255,255)rgb[2] = (0,255,255)rgb.write()
http://www.yayakq.cn/news/111673/

相关文章:

  • 如何介绍设计的网站模板下载fr后缀网站
  • 网站开发工程师求职信网站管理手册
  • 网站主题制作网站seo流程
  • 网站设计流程是什么柳州网站建设优化推广
  • 外贸网站建设书籍蒙古文网站建设情况
  • 湖州童装网站兰州seo优化入门
  • 在建设部网站如何查询注册信息设计一个好的wordpress主题的10个准则_
  • 个人网站如何做淘宝客服务号微网站怎么做
  • 做个公司网站大概多少钱手机网站模版更换技巧
  • 商城网站开发时间个人 网站备案 幕布
  • 教育行业网站建设审批联合建设官方网站
  • 新泰高品质网站建设娱乐网站制作
  • 浙江住房城乡建设厅网站电子商城网站建设公司
  • akcms做的网站宁夏建设工程招标投标信息管理中心网站
  • 专业做全景图的网站平台中山哪家做网站好
  • 怎么加入电商平台卖货安徽搜索引擎优化
  • 好品质自适应网站建设网站开发需求说明
  • 合肥搭建网站自己找网站开发项目
  • 西安通程建设工程 网站wordpress朗读句子插件
  • 建立网站英文泉州网站网站建设
  • 扬州网站建设开发建设肯德基网站的好处
  • 网站根目录在哪wordpress网站维护有文化建设费
  • 长春网络建站模板十堰网站优化排名
  • 公司网站建设应注意wordpress广告插件
  • 家具行业网站建设湖南网上注册公司流程
  • 注册公司什么网站网站建设的简历
  • 安徽网站优化厂家报价大丰网站建设找哪家好
  • 注册了域名怎么添加到自己的网站山东seo优化
  • 优秀网站首页网站建设通知
  • 做网站竞品分析招聘h5是什么意思