MixPY——让爱(AI)触手可及
MixPY布局
主控芯片:K210(64位双核带硬件FPU和卷积加速器的 RISC-V CPU)
显示屏:LCD_2.8寸 320*240分辨率,支持电阻触摸
摄像头:OV2640,200W像素
扬声器:3W单声道喇叭,及2.5mm双声道耳机孔
麦克风:一颗数字高灵敏MEMS硅麦
存储介质:16MBFlash,可外接<32G calss10 TF内存卡
板载功能:RGB三色灯,自定义2颗按键,重力感应
电池管理:PMU电源管理,3重电池保护电路及550mah锂电池
无线网卡:ESP8285,WiFi无线网卡
下载驱动:CH340,USB转TTL串口驱动电路
外接拓展:3个 Type-C扩展接口,可外接18IO口及双电源输出
10、变色七彩字体
#MicroPython动手做(37)——驱动LCD与图文显示
#变色七彩字体
import mixno
import lcd
import image
lcd.init(freq=150000,color=0x0000)
image = image.Image()
while True:
lcd.display(image.draw_string(30,60,"MixPY",248,12,mono_space=0))
lcd.display(image)
lcd.display(image.draw_string(30,60,"MixPY",24630,12,mono_space=0))
lcd.display(image)
lcd.display(image.draw_string(30,60,"MixPY",7936,12,mono_space=0))
lcd.display(image)
lcd.display(image.draw_string(30,60,"MixPY",8443,12,mono_space=0))
lcd.display(image)
lcd.display(image.draw_string(30,60,"MixPY",39369,12,mono_space=0))
lcd.display(image)
lcd.display(image.draw_string(30,60,"MixPY",57599,12,mono_space=0))
lcd.display(image)
lcd.display(image.draw_string(30,60,"MixPY",4912,12,mono_space=0))
lcd.display(image)
#MicroPython动手做(37)——驱动LCD与图文显示
#变色七彩字体(实验视频)
https://v.youku.com/v_show/id_XNDczNjkxMDc2NA==.html?spm=a2h0c.8166622.PhoneSokuUgc_1.dtitle
MixPY 实验图形编程
11、Hello MixPY 变色字体
#MicroPython动手做(37)——驱动LCD与图文显示
#Hello MixPY 变色字体
import time
import mixno
import lcd
import image
lcd.init(freq=1000000,color=0x0000)
image = image.Image()
while True:
lcd.display(image.draw_string(6,30,'''Hello
MixPY''',248,9,mono_space=0))
lcd.display(image)
time.sleep_ms(1000)
lcd.clear(0)
lcd.display(image.draw_string(6,30,'''Hello
MixPY''',24630,9,mono_space=0))
lcd.display(image)
time.sleep_ms(1000)
lcd.clear(0)
lcd.display(image.draw_string(6,30,'''Hello
MixPY''',7936,9,mono_space=0))
lcd.display(image)
time.sleep_ms(1000)
lcd.clear(0)
MixPY 实验图形编程
12、LCD绿色呼吸屏幕
#MicroPython动手做(37)——驱动LCD与图文显示
#LCD红绿色呼吸屏幕
import time
import mixno
import lcd
lcd.init(freq=15000000,color=(0,0,0))
mylist = [0,0,0]
while True:
for i in range(0, 255, 1):
mylist[0] = i
mylist[1] = 0
mylist[2] = 0
lcd.clear(tuple(mylist))
time.sleep_ms(10)
for i in range(255, 0, -1):
mylist[0] = i
mylist[1] = 0
mylist[2] = 0
lcd.clear(tuple(mylist))
time.sleep_ms(10)
MixPY 实验图形编程
13、循环变色彩虹屏幕
#MicroPython动手做(37)——驱动LCD与图文显示
#循环变色彩虹屏幕
import time
import mixno
import lcd
lcd.init(freq=15000000,color=(0,0,0))
mylist = [0,0,0]
while True:
for i in range(0, 255, 1):
mylist[0] = i
mylist[1] = 255 - i
mylist[2] = 0
lcd.clear(tuple(mylist))
time.sleep_ms(15)
time.sleep_ms(300)
for i in range(255, 0, -1):
mylist[0] = i
mylist[1] = 0
mylist[2] = 255 - i
lcd.clear(tuple(mylist))
time.sleep_ms(15)
time.sleep_ms(300)
for i in range(0, 255, 1):
mylist[0] = 0
mylist[1] = i
mylist[2] = 255 - i
lcd.clear(tuple(mylist))
time.sleep_ms(15)
time.sleep_ms(300)
#MicroPython动手做(37)——驱动LCD与图文显示
#循环变色彩虹屏幕(实验视频)
https://v.youku.com/v_show/id_XNDczNzcyNzQ5Mg==.html?spm=a2h0c.8166622.PhoneSokuUgc_19.dtitle
MixPY 实验图形编程