分类: 学习

97 篇文章

arduino 温度湿度计 (DH11)
data 接在数据接口上 #include "dhtTest.h" #include "DHT.h" // 接在 pin 3 上,型号 DHT11 DHT dht(3, DHT11); void initTemperature() { dht.begin(); } /** 更新温度 */ void updateTemperature() { aut…
arduino 1602 一些符号
发现 createChar 后直接 write 不能直接显示 // 自定义字符, 指定哪个像素亮,哪个灭 byte heart[8] = { 0b00000, 0b01010, 0b11111, 0b11111, 0b11111, 0b01110, 0b00100, 0b00000}; byte smiley[8] = { 0b00000, 0b0…
arduino 一些资料
详解Arduino Uno开发板的引脚分配图及定义:https://www.yiboard.com/thread-831-1-1.html Arduino 中文社区: https://www.arduino.cn/forum.php 【Arduino】168种传感器模块系列实验(资料+代码+图形+仿真) Arduino教程汇总贴 论坛(https:…
arduino 拆分源码
在目录下创建 .h 与 .cpp 文件 inlcude.h 将常用文件引用放在这里 #ifndef _INCLUDE_H__ #define _INCLUDE_H__ //导入Arduino核心头文件, 必须 #include"Arduino.h" // 日志 #include <ArduinoLog.h> // #define DIS…
arduino 查询 I2C 设备地址
arduino 查询 I2C 设备地址 https://zhuanlan.zhihu.com/p/349791145 \#include <Wire.h> #include "I2cScan.h" // 扫描 i2c 地址 void scanI2C() { Log.infoln("开始扫描 I2C"); auto count = 0; …
arduino 调用 1602a
我的 1602a 使用 i2c 接口 不同芯片有不同的 I2C 地址, 从下面的链接查看 I2C LCD与Arduino接口 #include <LiquidCrystal_I2C.h> LiquidCrystal_I2C lcd(0x3f, 16, 2); //声明I2C地址和点阵的规格为16字符和2行 // 定义字符.1, 指定哪个…
arduino 日志
arduino 使用日志系统 https://github.com/thijse/Arduino-Log #include <ArduinoLog.h> // 日志, https://github.com/thijse/Arduino-Log // #define DISABLE_LOGGING // 关闭日志功能 void setup…
android studio 启动卡死解决
android studio 无法启动解决。启动 android studio 时显示启动画面,但一直无法继续 可以安装 IntelliJ IDEA Edition 启动时提示 bind 错误。 因为 IDEA需要在端口6942~6991间找到一个可用端口并绑定(bind) 。但是这些端口被 Hyper-V 占用。有两种解决方案 执行 ```net…
windows 下 docker 的一些设置
wsl 2 的内存占用过大问题 编辑 %UserProfile%.wslconfig [wsl2] memory=2GB swap=0 localhostForwarding=true wsl --shutdown https://blog.n0ts.cn/1155.html 设置 docker 占用空间问题 设置 data-root 报错或是提示…
WSL 学习
WSL https://docs.microsoft.com/zh-cn/windows/wsl/ 安装 安装 WSL 安装 linux 子系统,可以让开发人员在在windows 下使用 linux 环境 - 包括大多数命令行工具、实用工具和应用程序 - 且不会产生传统虚拟机或双启动设置开销。 安装指南 :https://docs.microsof…