当前位置:网站首页>Arduino receives and sends strings
Arduino receives and sends strings
2022-07-07 10:49:00 【HCC2017】
void setup(){
Serial.begin(9600);
}
String bytes ="";
void loop() {
while (Serial.available() > 0)
{
bytes += char(Serial.read());
delay(2);
}
int index=bytes.toInt();
if(index>0&&index<1000)
{
Serial.println(index);
index=0;
bytes="";
}
}
边栏推荐
- July 10, 2022 "five heart public welfare" activity notice + registration entry (two-dimensional code)
- 南航 PA3.1
- 香橙派OrangePi 4 LTS开发板通过Mini PCIE连接SATA硬盘的操作方法
- ArrayList thread insecurity and Solutions
- 优雅的 Controller 层代码
- 软考中级有用吗??
- IIC Basics
- MONAI版本更新到 0.9 啦,看看有什么新功能
- [machine learning 03] Lagrange multiplier method
- 软考中级电子商务师含金量高嘛?
猜你喜欢

Deep understanding of Apache Hudi asynchronous indexing mechanism

软考中级,软件设计师考试那些内容,考试大纲什么的?

Trajectory planning for multi-robot systems: Methods and applications 综述阅读笔记

2022年7月10日“五心公益”活动通知+报名入口(二维码)

BUUCTF---Reverse---reverse1

【推荐系统 01】Rechub

路由器开发知识汇总

Some superficial understanding of word2vec

优雅的 Controller 层代码
![[牛客网刷题 Day5] JZ77 按之字形顺序打印二叉树](/img/ba/b2dfbf121798757c7b9fba4811221b.png)
[牛客网刷题 Day5] JZ77 按之字形顺序打印二叉树
随机推荐
Mendeley--免费的文献管理工具,给论文自动插入参考文献
IIC Basics
[daiy5] jz77 print binary tree in zigzag order
July 10, 2022 "five heart public welfare" activity notice + registration entry (two-dimensional code)
555 circuit details
ArrayList线程不安全和解决方案
SQL Server knowledge gathering 9: modifying data
Multithreaded asynchronous orchestration
Leetcode-303: region and retrieval - array immutable
施努卡:机器人视觉抓取工作原理 机器视觉抓取
China Southern Airlines pa3.1
Schnuka: machine vision positioning technology machine vision positioning principle
OpenGL glLightfv 函数的应用以及光源的相关知识
Applet jump to H5, configure business domain name experience tutorial
IO model review
Multisim--软件相关使用技巧
SQL Server 知识汇集11 : 约束
About hzero resource error (groovy.lang.missingpropertyexception: no such property: weight for class)
Network engineer test questions and answers in May of the first half of 2022
The mobile terminal automatically adjusts the page content and font size by setting rem