所有分类
主题 主题
平台 平台
我的工作台
userHead
注册时间 [[userInfo.create_time]]
创造力 [[userInfo.creativity]]
[[userInfo.remark]]
[[d.project_title]]
articleThumb
[[d.material_name]]
timelineThumb
进入工作台
折叠
所有分类 我的工作台
展开

二哈识别数字

李志雄 李志雄 2020-07-05 16:59:56
0
0
简单

家中二宝现在开始牙牙学语,会说简单的数字。手中有二哈,就想着给二宝做一个能识别数字与发音东西,陪二宝玩玩。所以,利用课余时间,试着研究做一个二哈识别数字的盒子。


材料清单 材料清单
1x
Gravity: 二哈识图(HuskyLens)AI 视觉传感器
1x
掌控板(含扩展板)
1x
Speech Synthesizer Bee语音合成模块
1x
小喇叭
1x
WiFi Bee IO扩展板

原理:

人工智能识别图象的二哈,通过学习,能自动重复识别学习过的数字着。 所使用到硬件有:掌控板、二哈误图、语音合成模块等;编程软件是Mind+。先通过编程,再让二哈对准颜色或数字进行学习,学习的内容与程序设置的内容相对应,学习结束后,再次识别到学习过的内容,就能识别并发出语音和显示文字。 

连接示意图

projectImage

二哈与掌控板接线

projectImage
projectImage

语音合成模块、扩展板与掌控板接线

projectImage
projectImage

给二哈穿上硅胶套装上支架

projectImage
projectImage

利用PVC板搭建一个盒子,安装好二哈、掌控板、语音合成模块、小喇叭。

projectImage
projectImage

利用Mind+V1.6.2编程。

projectImage
代码 代码
	                    					/*!
 * MindPlus
 * mpython
 *
 */
#include <MPython.h>
#include <DFRobot_SYN6288.h>
#include <DFRobot_HuskyLens.h>
// 静态常量
const uint8_t imageMatrix[][350] = {
	{0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xc3,0xff,0xff,0xc0,0xff,0xff,0xff,0x83,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xfe,0x3,0xff,0xff,0xc0,0xff,0xff,0xfc,0x3,0xff,0xff,0xc0,0xff,0xff,0xf0,0x3,0xff,0xff,0xc0,0xff,0xff,0xe0,0x3,0xff,0xff,0xc0,0xff,0xff,0xc0,0x3,0xff,0xff,0xc0,0xff,0xff,0x0,0x3,0xff,0xff,0xc0,0xff,0xfe,0x0,0x3,0xff,0xff,0xc0,0xff,0xfe,0x7,0x3,0xff,0xff,0xc0,0xff,0xfe,0xf,0x3,0xff,0xff,0xc0,0xff,0xfe,0x3f,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0},
	{0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xf8,0x1,0xff,0xff,0xc0,0xff,0xff,0xc0,0x0,0x3f,0xff,0xc0,0xff,0xff,0x80,0x0,0x1f,0xff,0xc0,0xff,0xff,0x0,0x0,0xf,0xff,0xc0,0xff,0xfe,0x0,0xf0,0x7,0xff,0xc0,0xff,0xfc,0x3,0xfc,0x7,0xff,0xc0,0xff,0xf8,0xf,0xfe,0x3,0xff,0xc0,0xff,0xf8,0x1f,0xfe,0x3,0xff,0xc0,0xff,0xf0,0x1f,0xff,0x3,0xff,0xc0,0xff,0xff,0x3f,0xff,0x3,0xff,0xc0,0xff,0xff,0xff,0xfe,0x3,0xff,0xc0,0xff,0xff,0xff,0xfe,0x3,0xff,0xc0,0xff,0xff,0xff,0xfe,0x7,0xff,0xc0,0xff,0xff,0xff,0xfc,0x7,0xff,0xc0,0xff,0xff,0xff,0xfc,0xf,0xff,0xc0,0xff,0xff,0xff,0xf8,0xf,0xff,0xc0,0xff,0xff,0xff,0xf0,0x1f,0xff,0xc0,0xff,0xff,0xff,0xe0,0x3f,0xff,0xc0,0xff,0xff,0xff,0xc0,0x7f,0xff,0xc0,0xff,0xff,0xff,0x80,0xff,0xff,0xc0,0xff,0xff,0xff,0x1,0xff,0xff,0xc0,0xff,0xff,0xfe,0x3,0xff,0xff,0xc0,0xff,0xff,0xfc,0x3,0xff,0xff,0xc0,0xff,0xff,0xf8,0xf,0xff,0xff,0xc0,0xff,0xff,0xf0,0xf,0xff,0xff,0xc0,0xff,0xff,0xe0,0x3f,0xff,0xff,0xc0,0xff,0xff,0xc0,0x7f,0xff,0xff,0xc0,0xff,0xff,0x80,0xff,0xff,0xff,0xc0,0xff,0xfe,0x1,0xff,0xff,0xff,0xc0,0xff,0xfe,0x3,0xff,0xff,0xff,0xc0,0xff,0xfc,0x0,0x0,0x1,0xff,0xc0,0xff,0xf8,0x0,0x0,0x1,0xff,0xc0,0xff,0xf8,0x0,0x0,0x1,0xff,0xc0,0xff,0xf8,0x0,0x0,0x1,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0x0,0x0,0x0,0x0,0x0,0x0,0x0},
	{0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xf0,0x7,0xff,0xff,0xc0,0xff,0xff,0x80,0x0,0xff,0xff,0xc0,0xff,0xff,0x0,0x0,0x3f,0xff,0xc0,0xff,0xfe,0x0,0x0,0x1f,0xff,0xc0,0xff,0xfc,0x7,0xf0,0x1f,0xff,0xc0,0xff,0xf8,0x1f,0xf8,0xf,0xff,0xc0,0xff,0xf0,0x1f,0xfc,0xf,0xff,0xc0,0xff,0xf0,0x3f,0xfc,0x7,0xff,0xc0,0xff,0xf0,0x7f,0xfc,0x7,0xff,0xc0,0xff,0xff,0xff,0xfc,0xf,0xff,0xc0,0xff,0xff,0xff,0xfc,0xf,0xff,0xc0,0xff,0xff,0xff,0xf8,0xf,0xff,0xc0,0xff,0xff,0xff,0xf0,0x1f,0xff,0xc0,0xff,0xff,0xff,0xc0,0x3f,0xff,0xc0,0xff,0xff,0xf8,0x0,0x7f,0xff,0xc0,0xff,0xff,0xf8,0x1,0xff,0xff,0xc0,0xff,0xff,0xf8,0x0,0x7f,0xff,0xc0,0xff,0xff,0xff,0x0,0x3f,0xff,0xc0,0xff,0xff,0xff,0xe0,0x1f,0xff,0xc0,0xff,0xff,0xff,0xf8,0xf,0xff,0xc0,0xff,0xff,0xff,0xfc,0x7,0xff,0xc0,0xff,0xff,0xff,0xfc,0x7,0xff,0xc0,0xff,0xff,0xff,0xfe,0x7,0xff,0xc0,0xff,0xff,0xff,0xfe,0x7,0xff,0xc0,0xff,0xe0,0x7f,0xfe,0x7,0xff,0xc0,0xff,0xe0,0x7f,0xfc,0x7,0xff,0xc0,0xff,0xe0,0x3f,0xfc,0x7,0xff,0xc0,0xff,0xf0,0x1f,0xf8,0xf,0xff,0xc0,0xff,0xf8,0xf,0xf0,0x1f,0xff,0xc0,0xff,0xf8,0x0,0x0,0x1f,0xff,0xc0,0xff,0xfe,0x0,0x0,0x7f,0xff,0xc0,0xff,0xff,0x0,0x0,0xff,0xff,0xc0,0xff,0xff,0xc0,0x3,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0},
	{0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xe0,0xff,0xff,0xc0,0xff,0xff,0xff,0xc0,0xff,0xff,0xc0,0xff,0xff,0xff,0x80,0xff,0xff,0xc0,0xff,0xff,0xff,0x0,0xff,0xff,0xc0,0xff,0xff,0xfe,0x0,0xff,0xff,0xc0,0xff,0xff,0xfe,0x0,0xff,0xff,0xc0,0xff,0xff,0xfc,0x0,0xff,0xff,0xc0,0xff,0xff,0xf8,0x0,0xff,0xff,0xc0,0xff,0xff,0xf0,0x0,0xff,0xff,0xc0,0xff,0xff,0xe0,0x20,0xff,0xff,0xc0,0xff,0xff,0xc0,0x60,0xff,0xff,0xc0,0xff,0xff,0x80,0xe0,0xff,0xff,0xc0,0xff,0xff,0x1,0xe0,0xff,0xff,0xc0,0xff,0xff,0x3,0xe0,0xff,0xff,0xc0,0xff,0xfe,0x7,0xe0,0xff,0xff,0xc0,0xff,0xfc,0xf,0xe0,0xff,0xff,0xc0,0xff,0xf8,0xf,0xe0,0xff,0xff,0xc0,0xff,0xf0,0x3f,0xe0,0xff,0xff,0xc0,0xff,0xe0,0x3f,0xe0,0xff,0xff,0xc0,0xff,0xc0,0x7f,0xe0,0xff,0xff,0xc0,0xff,0x80,0xff,0xe0,0xff,0xff,0xc0,0xff,0x81,0xff,0xe0,0xff,0xff,0xc0,0xff,0x0,0x0,0x0,0x3,0xff,0xc0,0xff,0x0,0x0,0x0,0x3,0xff,0xc0,0xff,0x0,0x0,0x0,0x3,0xff,0xc0,0xff,0xff,0xff,0xc0,0xff,0xff,0xc0,0xff,0xff,0xff,0xe0,0xff,0xff,0xc0,0xff,0xff,0xff,0xe0,0xff,0xff,0xc0,0xff,0xff,0xff,0xe0,0xff,0xff,0xc0,0xff,0xff,0xff,0xe0,0xff,0xff,0xc0,0xff,0xff,0xff,0xe0,0xff,0xff,0xc0,0xff,0xff,0xff,0xe0,0xff,0xff,0xc0,0xff,0xff,0xff,0xe0,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0},
	{0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xfe,0x0,0x0,0xf,0xff,0xc0,0xff,0xfe,0x0,0x0,0xf,0xff,0xc0,0xff,0xfe,0x0,0x0,0xf,0xff,0xc0,0xff,0xfc,0xf,0xff,0xff,0xff,0xc0,0xff,0xfc,0xf,0xff,0xff,0xff,0xc0,0xff,0xfc,0xf,0xff,0xff,0xff,0xc0,0xff,0xf8,0x1f,0xff,0xff,0xff,0xc0,0xff,0xf8,0x1f,0xff,0xff,0xff,0xc0,0xff,0xf8,0x1f,0xff,0xff,0xff,0xc0,0xff,0xf8,0x3f,0xff,0xff,0xff,0xc0,0xff,0xf0,0x0,0x3,0xff,0xff,0xc0,0xff,0xf0,0x0,0x0,0xff,0xff,0xc0,0xff,0xf0,0x0,0x0,0x3f,0xff,0xc0,0xff,0xe0,0x7,0x80,0x1f,0xff,0xc0,0xff,0xe0,0x3f,0xf0,0xf,0xff,0xc0,0xff,0xe0,0x7f,0xf8,0xf,0xff,0xc0,0xff,0xff,0xff,0xfc,0x7,0xff,0xc0,0xff,0xff,0xff,0xfe,0x7,0xff,0xc0,0xff,0xff,0xff,0xfe,0x7,0xff,0xc0,0xff,0xff,0xff,0xfe,0x7,0xff,0xc0,0xff,0xff,0xff,0xfe,0x7,0xff,0xc0,0xff,0xff,0xff,0xfe,0x7,0xff,0xc0,0xff,0xf1,0xff,0xfe,0x7,0xff,0xc0,0xff,0xc0,0xff,0xfc,0x7,0xff,0xc0,0xff,0xc0,0xff,0xfc,0xf,0xff,0xc0,0xff,0xc0,0x7f,0xf8,0xf,0xff,0xc0,0xff,0xe0,0x3f,0xe0,0xf,0xff,0xc0,0xff,0xf0,0x7,0x80,0x1f,0xff,0xc0,0xff,0xf8,0x0,0x0,0x7f,0xff,0xc0,0xff,0xfc,0x0,0x0,0xff,0xff,0xc0,0xff,0xff,0x0,0x7,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0},
	{0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xc0,0xff,0xff,0xc0,0xff,0xff,0xff,0x80,0xff,0xff,0xc0,0xff,0xff,0xff,0x1,0xff,0xff,0xc0,0xff,0xff,0xfe,0x3,0xff,0xff,0xc0,0xff,0xff,0xfe,0x3,0xff,0xff,0xc0,0xff,0xff,0xfc,0x7,0xff,0xff,0xc0,0xff,0xff,0xf8,0xf,0xff,0xff,0xc0,0xff,0xff,0xf0,0x1f,0xff,0xff,0xc0,0xff,0xff,0xe0,0x3f,0xff,0xff,0xc0,0xff,0xff,0xc0,0x7f,0xff,0xff,0xc0,0xff,0xff,0x80,0xff,0xff,0xff,0xc0,0xff,0xff,0x80,0xff,0xff,0xff,0xc0,0xff,0xff,0x0,0x0,0xff,0xff,0xc0,0xff,0xfe,0x0,0x0,0x1f,0xff,0xc0,0xff,0xfc,0x0,0x0,0xf,0xff,0xc0,0xff,0xfc,0x1,0xf0,0x7,0xff,0xc0,0xff,0xf8,0x7,0xfe,0x3,0xff,0xc0,0xff,0xf0,0xf,0xff,0x1,0xff,0xc0,0xff,0xf0,0x1f,0xff,0x81,0xff,0xc0,0xff,0xf0,0x3f,0xff,0x80,0xff,0xc0,0xff,0xf0,0x3f,0xff,0x80,0xff,0xc0,0xff,0xe0,0x3f,0xff,0x80,0xff,0xc0,0xff,0xe0,0x3f,0xff,0x80,0xff,0xc0,0xff,0xf0,0x3f,0xff,0x80,0xff,0xc0,0xff,0xf0,0x3f,0xff,0x81,0xff,0xc0,0xff,0xf0,0x1f,0xff,0x1,0xff,0xc0,0xff,0xf8,0xf,0xfe,0x1,0xff,0xc0,0xff,0xf8,0x7,0xfc,0x3,0xff,0xc0,0xff,0xfc,0x1,0xf0,0x7,0xff,0xc0,0xff,0xfe,0x0,0x0,0xf,0xff,0xc0,0xff,0xff,0x80,0x0,0x3f,0xff,0xc0,0xff,0xff,0xe0,0x0,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0},
	{0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xe0,0x0,0x0,0x1,0xff,0xc0,0xff,0xe0,0x0,0x0,0x1,0xff,0xc0,0xff,0xe0,0x0,0x0,0x1,0xff,0xc0,0xff,0xff,0xff,0xff,0x1,0xff,0xc0,0xff,0xff,0xff,0xff,0x3,0xff,0xc0,0xff,0xff,0xff,0xfe,0x7,0xff,0xc0,0xff,0xff,0xff,0xfc,0x7,0xff,0xc0,0xff,0xff,0xff,0xfc,0xf,0xff,0xc0,0xff,0xff,0xff,0xf8,0x1f,0xff,0xc0,0xff,0xff,0xff,0xf0,0x1f,0xff,0xc0,0xff,0xff,0xff,0xe0,0x3f,0xff,0xc0,0xff,0xff,0xff,0xe0,0x7f,0xff,0xc0,0xff,0xff,0xff,0xc0,0x7f,0xff,0xc0,0xff,0xff,0xff,0xc0,0xff,0xff,0xc0,0xff,0xff,0xff,0x81,0xff,0xff,0xc0,0xff,0xff,0xff,0x1,0xff,0xff,0xc0,0xff,0xff,0xff,0x3,0xff,0xff,0xc0,0xff,0xff,0xfe,0x3,0xff,0xff,0xc0,0xff,0xff,0xfe,0x7,0xff,0xff,0xc0,0xff,0xff,0xfc,0x7,0xff,0xff,0xc0,0xff,0xff,0xfc,0xf,0xff,0xff,0xc0,0xff,0xff,0xf8,0xf,0xff,0xff,0xc0,0xff,0xff,0xf8,0x1f,0xff,0xff,0xc0,0xff,0xff,0xf0,0x1f,0xff,0xff,0xc0,0xff,0xff,0xf0,0x3f,0xff,0xff,0xc0,0xff,0xff,0xe0,0x3f,0xff,0xff,0xc0,0xff,0xff,0xe0,0x3f,0xff,0xff,0xc0,0xff,0xff,0xe0,0x7f,0xff,0xff,0xc0,0xff,0xff,0xc0,0x7f,0xff,0xff,0xc0,0xff,0xff,0xc0,0x7f,0xff,0xff,0xc0,0xff,0xff,0xc0,0xff,0xff,0xff,0xc0,0xff,0xff,0x80,0xff,0xff,0xff,0xc0,0xff,0xff,0x80,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xc0}
};
// 创建对象
DFRobot_SYN6288   syn6288;
DFRobot_HuskyLens huskylens;


// 主程序开始
void setup() {
	mPython.begin();
	syn6288.begin(&Serial1, P0, P1, P2);
	syn6288.setVolume(true, 13);
	huskylens.beginI2CUntilSuccess();
}
void loop() {
	huskylens.request();
	if (huskylens.isAppearDirect(HUSKYLENSResultBlock)) {
		if ((huskylens.readBlockCenterParameterDirect().ID==1)) {
			syn6288.playText("1", 0);
			display.drawImage(39, 7, 50, 50, imageMatrix[0]);
			delay(1000);
		}
		if ((huskylens.readBlockCenterParameterDirect().ID==2)) {
			syn6288.playText("2", 0);
			display.drawImage(39, 7, 50, 50, imageMatrix[1]);
			delay(1000);
		}
		if ((huskylens.readBlockCenterParameterDirect().ID==3)) {
			syn6288.playText("三", 0);
			display.drawImage(39, 7, 50, 50, imageMatrix[2]);
			delay(1000);
		}
		if ((huskylens.readBlockCenterParameterDirect().ID==4)) {
			syn6288.playText("四", 0);
			display.drawImage(39, 7, 50, 50, imageMatrix[3]);
			delay(1000);
		}
		if ((huskylens.readBlockCenterParameterDirect().ID==5)) {
			syn6288.playText("5", 0);
			display.drawImage(39, 7, 50, 50, imageMatrix[4]);
			delay(1000);
		}
		if ((huskylens.readBlockCenterParameterDirect().ID==6)) {
			syn6288.playText("6", 0);
			display.drawImage(39, 7, 50, 50, imageMatrix[5]);
			delay(1000);
		}
		if ((huskylens.readBlockCenterParameterDirect().ID==7)) {
			syn6288.playText("7", 0);
			display.drawImage(39, 7, 50, 50, imageMatrix[6]);
			delay(1000);
		}
	}
	else {
	}
}

	                    				

先让二哈进行学习。具体方法参考链接。https://mc.dfrobot.com.cn/thread-304439-1-1.html

二宝学习视频

Makelog作者原创文章,未经授权禁止转载。
0
0
评论
[[c.user_name]] [[c.create_time]]
[[c.parent_comment.count]]
[[c.comment_content]]