【开发板试用报告】学习GPIO编程

温湿度传感器

参考许老师教程:https://gitee.com/hihopeorg/

  1. 下载源码git clone https://github.com/xusiwei/harmonyos-aht20

  2. 设置CONFIG_I2C_SUPPORT=y,文件./vendor/hisi/hi3861/hi3861/build/config/usr_config.mk;

  3. 编译烧录,查看串口打印信息,能看到温度(temperature)和湿度(humidity)的实时打印;

oled显示屏

  1. 下载源码git clone https://gitee.com/hihopeorg/harmonyos-ssd1306

  2. 设置CONFIG_I2C_SUPPORT=y,文件./vendor/hisi/hi3861/hi3861/build/config/usr_config.mk;

  3. 编译烧录,查看显示屏显示“你好鸿蒙”;

作者:HarryP0tter
想了解更多内容,请访问:
51CTO和华为官方战略合作共建的鸿蒙技术社区
https://harmonyos.51cto.com#bky

【免费报名直播课】

原文地址:https://www.cnblogs.com/HarmonyOS/p/13962882.html