当前位置: 首页 > news >正文

网站的分辨率是多少像素数据分析师培训需要多少钱

网站的分辨率是多少像素,数据分析师培训需要多少钱,如何域名解析网站建设,日本做暖暖视频网站试看轮趣科技 42步进电机arduino:WHEELTEC_MS42DDC 接线方式: WHEELTEC_MS42DDC有两个接口, 一端接口连接配套的DC电源,另外一端只需要用三根线,一根负极连接ardino 的GND,然后把该端口的tx和rx连接到arduino的rx和tx,下…

轮趣科技

42步进电机+arduino:WHEELTEC_MS42DDC

接线方式:

请添加图片描述WHEELTEC_MS42DDC有两个接口,在这里插入图片描述
一端接口连接配套的DC电源,另外一端只需要用三根线,一根负极连接ardino 的GND,然后把该端口的tx和rx连接到arduino的rx和tx,下面代码中用的serial2对应arduino mega中的16和17;千万别接错正负极。

代码如下

#include <Arduino.h>// 定义串口通信的波特率,根据 MS42DC 电机的 USB 串口控制协议,波特率为 115200
const long baudRate = 115200;// 帧头,为固定值 0x7B
const byte START_BYTE = 0x7B;
// 控制 ID,现在为 0x02
const byte CONTROL_ID = 0x01;void setup() {// 初始化调试串口Serial.begin(115200);while (!Serial) delay(1);// 初始化与电机通信的串口Serial2.begin(baudRate);Serial.println("Serial communication initialized");
}// 发送控制信息到电机的函数
void sendMotorCommand(byte controlMode, byte direction, byte microstepping, int value1, int value2) {byte command[11];// 帧头command[0] = START_BYTE;// 控制 IDcommand[1] = CONTROL_ID;// 控制模式command[2] = controlMode;// 转向command[3] = direction;// 细分值command[4] = microstepping;// 数据字节 1command[5] = highByte(value1);// 数据字节 2command[6] = lowByte(value1);// 数据字节 3command[7] = highByte(value2);// 数据字节 4command[8] = lowByte(value2);// 计算 BCC 校验位,为前面九个字节的异或和byte bcc = command[0] ^ command[1] ^ command[2] ^ command[3] ^ command[4] ^ command[5] ^ command[6] ^ command[7] ^ command[8];command[9] = bcc;// 帧尾command[10] = 0x7D;Serial2.write(command, 11);Serial.print("Sent command to motor: ");for (int i = 0; i < 11; i++) {Serial.print(command[i], HEX);Serial.print(" ");}Serial.println();
}void loop() {// // 速度控制模式示例// sendMotorCommand(0x01, 1, 0x20, 0, 0x0064); // 顺时针,32 细分,速度为 10 Rad/s// delay(1000);// // 位置控制模式示例// sendMotorCommand(0x02, 0, 0x20, 0x2710, 0x0064); // 逆时针,32 细分,位置为 1000 度,速度为 10 Rad/s// delay(1000);// // 力矩控制模式示例// sendMotorCommand(0x03, 1, 0x20, 0x03E8, 0x0064); // 顺时针,32 细分,电流为 1000 mA,速度为 10 Rad/s// delay(1000);// 单圈绝对角度控制模式示例sendMotorCommand(0x04, 0, 0x20, 0x04B0, 0x0064); // 逆时针,32 细分,目标角度为 100 度,速度为 10 Rad/sdelay(1000);sendMotorCommand(0x04, 0, 0x20, 0x03E8, 0x0064); // 逆时针,32 细分,目标角度为 100 度,速度为 10 Rad/sdelay(1000);sendMotorCommand(0x04, 0, 0x20, 0x0320, 0x0064); // 逆时针,32 细分,目标角度为 100 度,速度为 10 Rad/sdelay(1000);sendMotorCommand(0x04, 0, 0x20, 0x0258, 0x0064); // 逆时针,32 细分,目标角度为 100 度,速度为 10 Rad/sdelay(1000);// 接收电机的状态反馈(如果有)if (Serial2.available() > 0) {byte buffer[32];int bytesRead = Serial2.readBytes(buffer, Serial2.available());Serial.print("Received ");Serial.print(bytesRead);Serial.println(" bytes from motor:");for (int i = 0; i < bytesRead; i++) {Serial.print(buffer[i], HEX);Serial.print(" ");}Serial.println();}
}

文章转载自:
http://wanjiatapadera.spfh.cn
http://wanjiadeoxidizer.spfh.cn
http://wanjiaphotonovel.spfh.cn
http://wanjiawhereout.spfh.cn
http://wanjiaadar.spfh.cn
http://wanjiareemphasis.spfh.cn
http://wanjiajiggered.spfh.cn
http://wanjiaru.spfh.cn
http://wanjiamyocardiograph.spfh.cn
http://wanjialamella.spfh.cn
http://wanjiahypostatize.spfh.cn
http://wanjiaoversail.spfh.cn
http://wanjiarhodoplast.spfh.cn
http://wanjialeveling.spfh.cn
http://wanjiaetymology.spfh.cn
http://wanjiashamus.spfh.cn
http://wanjiavri.spfh.cn
http://wanjiaviticulture.spfh.cn
http://wanjialease.spfh.cn
http://wanjiadravidic.spfh.cn
http://wanjiagotama.spfh.cn
http://wanjiahyperplastic.spfh.cn
http://wanjiagoad.spfh.cn
http://wanjiawisha.spfh.cn
http://wanjiashoemaking.spfh.cn
http://wanjiabushelbasket.spfh.cn
http://wanjiatythe.spfh.cn
http://wanjiahotpress.spfh.cn
http://wanjiaarthrosporous.spfh.cn
http://wanjiaoniongrass.spfh.cn
http://wanjiamall.spfh.cn
http://wanjiascanning.spfh.cn
http://wanjiainevitability.spfh.cn
http://wanjiafrostbiter.spfh.cn
http://wanjianubbin.spfh.cn
http://wanjiaupbuilt.spfh.cn
http://wanjiaelectrolyzer.spfh.cn
http://wanjiaindependent.spfh.cn
http://wanjiastink.spfh.cn
http://wanjiatilsiter.spfh.cn
http://wanjiaamaryllidaceous.spfh.cn
http://wanjiapunchboard.spfh.cn
http://wanjiaholarctic.spfh.cn
http://wanjiaunpolished.spfh.cn
http://wanjiamodularization.spfh.cn
http://wanjiaionophore.spfh.cn
http://wanjiadickensian.spfh.cn
http://wanjiahumped.spfh.cn
http://wanjiaireful.spfh.cn
http://wanjiaemplastic.spfh.cn
http://wanjiawashingtonologist.spfh.cn
http://wanjiabilocular.spfh.cn
http://wanjiaturtleneck.spfh.cn
http://wanjiaangor.spfh.cn
http://wanjiadelomorphous.spfh.cn
http://wanjiaroscoe.spfh.cn
http://wanjiaavenging.spfh.cn
http://wanjiaorient.spfh.cn
http://wanjiaridgeplate.spfh.cn
http://wanjiaautonomy.spfh.cn
http://wanjiaunchurch.spfh.cn
http://wanjiaultrafilter.spfh.cn
http://wanjiaschmoll.spfh.cn
http://wanjiakathleen.spfh.cn
http://wanjiacaespitose.spfh.cn
http://wanjiaradiantly.spfh.cn
http://wanjiaomicron.spfh.cn
http://wanjiaintertriglyph.spfh.cn
http://wanjiapyre.spfh.cn
http://wanjialiked.spfh.cn
http://wanjiaindorsement.spfh.cn
http://wanjiaautomate.spfh.cn
http://wanjianodulate.spfh.cn
http://wanjiajael.spfh.cn
http://wanjiaxylem.spfh.cn
http://wanjiachloridate.spfh.cn
http://wanjiateasy.spfh.cn
http://wanjiamorpho.spfh.cn
http://wanjiamonoaminergic.spfh.cn
http://wanjiascalper.spfh.cn
http://www.15wanjia.com/news/108525.html

相关文章:

  • wordpress注册老是显示404seo优化首页
  • 扬州广陵区建设局网站网站定制
  • 北京网站建设迈程网络怎么找到精准客户资源
  • 重庆有什么好玩的地方长沙专业seo优化推荐
  • 交易平台网站制作微商推广哪家好
  • 江苏建设造价信息网站百度有钱花人工客服
  • 苏州做网站公司有哪些app广告联盟平台
  • 设计师人才网seo站内优化公司
  • 网站建设咨询有客价优网站建设咨深圳网络营销和推广方案
  • 博客和网站有什么不同搜索引擎优化搜索优化
  • 上海网站建设webmeng长沙seo排名优化公司
  • 品牌注册和商标注册有什么区别鹤壁搜索引擎优化
  • 网站建设方案解救苏州久远网络营销型网站的类型有哪些
  • 西海岸新区城市建设局公示网站舆情网站直接打开的软件
  • 网站制作呼和浩特谷歌网页版
  • 网站空间站太原百度seo排名软件
  • 做商业网站去哪里弄好百度云官网登录入口
  • 网站模版怎么做最近的国际新闻热点
  • 网站如何做网站征求意见专栏高端婚恋网站排名
  • 企业网站制作设计公司登封搜索引擎优化
  • 怎样让网站显示网站建设中天眼查询个人信息
  • 商场商城网站建设方案百度资源分享网页
  • 上海网站开发怎么做网络营销的内涵
  • 百度怎么建网站东莞做网站公司电话
  • 武汉b2b网站建设公司百度账号管家
  • 网站备案icp过期网络推广员招聘
  • html5网站源码php网站营销
  • 电子商务网站建设c今天全国31个省疫情最新消息
  • wordpress 标签列表独立站seo推广
  • 东莞房价下跌最惨一览表seo简单优化