Renesa Version Board和微信小程序通信

news2024/9/21 9:25:25

目录

概述

1. 系统框架结构

1.1 功能介绍

1.2 系统框图

2 微信小程序开发

2.1 UI介绍

2.2  代码实现

3 功能实现

3.1 通信协议

3.2 系统测试


概述

本文主要介绍基于Renesa Version Board,采集多个传感器数据,并将这些数据通过蓝牙模块发送微信小程序上。笔者还介绍微信小程序App的源代码,并介绍app和下位机的通信协议。

1. 系统框架结构

1.1 功能介绍

Renesa Version Board实现功能:

1)读取Sensor数据

1)通过I2C和SH20温湿度传感器通信,读取该sensor上的温度和湿度值

2)通过I2C和ISL2003L光照传感器通信,读取该sensor上的lux值

3)通过IO接口读取SR04超声波测距数据

2)传输数据

Renesa Version Board通过UART接口将采集到的数据传送到STM32F103板卡,该板卡主要实现数据转发功能。

3)蓝牙模块数据传输

STM32F103板卡接收到Renesa Version Board传递的sensor数据后,对这些数据进行打包,然后将该数据包通过蓝牙接口发送出去。

4)微信小程序

微信小程序主要实现接收下位机蓝牙模块发送的数据,并对该数据包进行解析,然后通过UI将数据呈现出来。

1.2 系统框图

2 微信小程序开发

2.1 UI介绍

接收数据:

1) 显示温度和湿度数据

2) 显示光照数据

3) 显示SR04超声波测距数据

发送端数据:

通过4个按钮控制小车的行为 

2.2  代码实现

1)创建detail.wxml文件,实现UI框架

详细代码如下:

<view class="connect_box">
    <text class='connect_device_name'>{{deviceName}}</text>
    <text wx:if="{{connected}}" class="connect_state" catchtap="DisConnectTap">已连接</text>
    <text wx:else class="connect_state" catchtap="DisConnectTap" >未连接</text>
</view>

<view class="block-content">

    <view class="block-item column">
            <view class="item-row slider-box">
                <view class="item-title" >
                  <image class="item-title-icon" src="/images/light_s.png" />温度(℃)
                </view>
                <view class="input-unit"></view>

                <view class="item-title" style="position: relative;  left: 30rpx; ">
                  <image class="item-title-icon" src="/images/light_s.png" />湿度(%)
                </view>
                <view class="input-unit"></view>
            </view>
          
            <view class="item-row">
                <view class="input-value">
                    <input type="digit" value="{{temphtValue}}" disabled="false"/>
                </view>

                <view class="input-value" style="position: relative;  left: -90rpx; ">
                    <input type="digit" value="{{humidityValue}}" disabled="false"/>
                </view>

            </view>
    </view> 

    <view class="block-item column">
            <view class="item-row slider-box">
                <view class="item-title">
                  <image class="item-title-icon" src="/images/light_s.png" />光照(lux)
                </view>
                <view class="input-unit"></view>

                <view class="item-title" style="position: relative;  left: 60rpx; ">
                  <image class="item-title-icon" src="/images/light_s.png" />SR测距(cm)
                </view>
                <view class="input-unit"></view>

            </view>
          
            <view class="item-row">
                <view class="input-value" >
                    <input type="digit" value="{{luxValue}}" disabled="false"/>
                </view>

                <view class="input-value" style="position: relative;  left: -90rpx; ">
                    <input type="digit" value="{{srValue}}" disabled="false"/>
                </view>

            </view>
    </view> 


    <view class="block-item column" style="width: 750rpx; height: 507rpx; display: flex; box-sizing: border-box; left: 0rpx; top: 0rpx; position: relative">
      <button type="primary" bindtap="run_up" plain="true" style="position: relative; left: 3rpx; top: 5rpx; width: 183rpx; height: 357rpx; display: block; box-sizing: border-box">前进</button>
      <button type="primary" bindtap="run_up" plain="true" style="position: relative; left: 0rpx; top: 263rpx; width: 188rpx; height: 326rpx; display: block; box-sizing: border-box">后退</button>
      <button type="primary" bindtap="run_up" plain="true" style="position: relative; left: -247rpx; top: 3rpx; width: 183rpx; height: 361rpx; display: block; box-sizing: border-box">左转</button>
      <button type="primary" bindtap="run_up" plain="true" style="position: relative; left: 256rpx; top: -82rpx; width: 183rpx; height: 343rpx; display: block; box-sizing: border-box">右转</button>
      <button type="primary" bindtap="run_up" plain="true" style="position: relative; left: 5rpx; top: -173rpx; width: 179rpx; height: 361rpx; display: block; box-sizing: border-box">停止</button>
    </view> 
</view>

2)样式文件

详细代码如下:

.connect_box {
    width: 100%;
    height: 30px;
    line-height: 30px;
    font-size: 32rpx;
    color: #666;
    background-color: antiquewhite;
    font-family: "Microsoft YaHei";
}
.connect_device_name{
    float: left;
    padding-left: 10px;
    color: #39beff;
}

.connect_state {
    float: right;
    padding-right: 10px;
    text-decoration: underline;
    color: #39beff;
}

page {
    min-height: 100%;
  }
  
  .container {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    box-sizing: border-box;
    background-color: cadetblue;
  }
  
  .block {
    padding: 15px;
    width: 100%;
    box-sizing: border-box;
  }
  
  .block-title {
    font-size: 20px;
    margin-bottom: 30px;
  }
  
  .block-subtitle {
    margin: 15px 0;
    font-size: 14px;
    color: #666;
  }
  
  .block-item {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 15px 0;
    padding: 15px;
    font-size: 18px;
    border-radius: 8px;
    background:azure;
    box-shadow: 0px 2px 8px rgba(0, 0, 0, 0.1);
  }
  
  .block-item:last-child {
    margin-bottom: 0;
  }
  .block-item.column {
    flex-direction: column;
  }
  
  .item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
  }
  
  .item-row + .item-row {
    margin-top: 10px;
  }
  
  .item-column {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-self: stretch;
    flex-grow: 1;
  }
  
  .item-title {
    font-size: 16px;
  }
  
  .item-title-icon {
    height: 1.2em;
    width: 1.2em;
    margin-right: 10px;
    vertical-align: middle;
  }
  
  .slider-box {
    flex-grow: 1;
  }
  
  .slider {
    margin-left: 10px;
    margin-right: 20px;
    flex-grow: 1;
  }
  
  .slider-value {
    display: flex;
    justify-content: space-around;
    align-items: center;
    margin: 15px auto;
    width: 70%;
  }
  
  .input-unit {
    text-align: right;
    font-size: 14px;
    color: #999;
  }
  
  .input-value {
    display: inline-block;
    padding: 0 16px;
    border: 1px solid #CCCCCC;
    border-radius: 4px;
    max-width: 3.5em;
    font-size: 16px;
    text-align: center;
  }

3) JS文件

详细代码如下:

const utils = require('utils.js')
const ble = require('bluetooth.js')
Page({
    /**
     * 页面的初始数据
     */
    data: {
        pageload: false,
        connected: false,
        send_hex: false,
        send_string: true,
        send_string_val: 'Hex',
        recv_string: true,
        recv_string_val: 'Hex',
        recv_value: '',
        send_number: 0,
        recv_number: 0,
        recv_hex: true,
        try_cnt:0,
        rece_string:'',
        deviceArray: []
    },


    /**
     * 生命周期函数--监听页面加载
     */
    onLoad: function (options) {
        var that = this; 

        console.log(options);
        this.setData({
            pageload:true,
            connected: false,
            deviceId: options.id,
            try_cnt:0,
            deviceName: options.name
        });

        console.log("detail:  onLoad");
        wx.stopBluetoothDevicesDiscovery({
            success: function (res) {
                console.log('停止搜索设备', res)
            }
        })

        that.closeBLEConnection(that.data.deviceId);
        that.createBLEConnection(that.data.deviceId, that.data.deviceName); 
    }, 

    onHide () {
        var that = this;
        // Do something when hide.
        // 断开连接
        console.log("detail:  onHide");
    },

    onShow:function()
    {      
        // var that = this; 
        // connect bluetooth
        // that.closeBLEConnection(that.data.deviceId);
        // that.createBLEConnection(that.data.deviceId, that.data.deviceName); 
    },

    onUnload() {
        var that = this;

        this.setData({
            pageload:true,
            connected: false,
            try_cnt:0,
        });

        console.log("page:  onUnload  ");
        that.offBLEMonitor();
        that.closeBLEConnection(that.data.deviceId);
        that.closeBluetoothAdapter();

        wx.showToast({
            title: '断开蓝牙',
            icon: 'success',
            duration: 2000
          })  
    },


    DisConnectTap:function()
    {
        var that = this;

        that.setData({
            pageload:true,
            connected: false,
            try_cnt:0,
        });

        ble.openBluetoothAdapter(that.data.deviceId, that.data.deviceName);
        that.createBLEConnection(that.data.deviceId, that.data.deviceName); 
    },



    RecvCleanTap: function () {
        this.setData({
            recv_value: '',
            recv_number: 0
        });
    },  

    /**
     * 创建连接
     * @param {*} deviceId 
     * @param {*} name 
     */
    createBLEConnection(deviceId, name) 
    {
        wx.createBLEConnection({
            deviceId,  
            success: (res) => {
                console.log('createBLEConnection - success: ', res)
                this.getBLEDeviceServices(deviceId)              
            },
            fail: (res) => {
                console.error('createBLEConnection - fail: ', res)
                if(res.errCode == 10006 ){
                    this.createBLEConnection(deviceId, name)
                }
                else{
                    ble.openBluetoothAdapter(deviceId, name)
                    this.createBLEConnection(deviceId, name)
                }

                this.setData({
                    connected: false,
                })               
            } 
        })
    },
        
    getBLEDeviceServices(deviceId) 
    {
        var that = this;
        wx.getBLEDeviceServices({
            deviceId,
            success: (res) => 
            {
                console.log('getBLEDeviceServices - success: ', res)
                for (let i = 0; i < res.services.length; i++) 
                {
                    var ergodic_UUID =res.services[i].uuid;      //取出服务里面的UUID
                    var UUID_slice = ergodic_UUID.slice(4, 8);   //截取4到8位

                    console.log('getBLEDeviceServices, service ID =  ', res.services[i].uuid);
                    if ( res.services[i].isPrimary && (UUID_slice == "FFE0") ) 
                    {
                        that.setData({
                            serviceId: res.services[i].uuid,
                        });
                        break;
                    }
                }

                wx.getConnectedBluetoothDevices({
                    services: res.services,
                    success: (res) => 
                    {                         
                      console.log("getConnectedBluetoothDevices - success:  " +  res)
                    },
                    fail: (res) => {
                        console.error('getConnectedBluetoothDevices - fail: ', res)
                        ble.openBluetoothAdapter(deviceId, that.data.deviceName)
                    }                    
                })

                that.getBLEDeviceCharacteristics(deviceId, that.data.serviceId);
            },
            fail: (res) => {
                console.error('getBLEDeviceServices - fail: ', res)
                // try it again
                ble.openBluetoothAdapter(deviceId, that.data.deviceName)
                that.monitor_connected();
            } 
        });
    },

   getBLEDeviceCharacteristics(deviceId, serviceId) 
   {
        var that = this;
        let falg = false;

        wx.getBLEDeviceCharacteristics({
            deviceId,
            serviceId,
            success: (res) => 
            {
                that.setData({
                    connected: true,
                })                
                console.log('getBLEDeviceCharacteristics success', res.characteristics)
                for (let i = 0; i < res.characteristics.length; i++) 
                {
                    let item = res.characteristics[i]
                     
                    console.log('getBLEDeviceCharacteristics, Characteristics ID =  ', item.uuid)
                    // 该特征值:可读
                    if (item.properties.read) 
                    {
                        wx.readBLECharacteristicValue({
                            deviceId,
                            serviceId,
                            characteristicId: item.uuid,
                        })
                    }

                    // 该特征值:可写
                    if (item.properties.write) 
                    {
                        this.setData({
                            canWrite: true
                        })
                        this._deviceId = deviceId
                        this._serviceId = serviceId
                        this._characteristicId = item.uuid
                        this.writeValue()
                    }

                    if (item.properties.notify || item.properties.indicate) 
                    {
                        that.setData({
                            characteristicId: item.uuid
                        });
                        falg = true;
                        break;
                    }
                }

                
                if( falg )
                {
                    console.debug('getBLEDeviceCharacteristics - deviceId : ', deviceId)
                    console.debug('getBLEDeviceCharacteristics - serviceId : ', serviceId)
                    console.debug('getBLEDeviceCharacteristics - characteristicId: ', that.data.characteristicId)

                    // read device character value 
                    that.readBLECharacteristicValue(deviceId, serviceId, that.data.characteristicId)   
                    that.notifyBLECharacteristicValueChange(deviceId, serviceId, that.data.characteristicId) 
                }
            },
            fail: (res) => {
                console.error('getBLEDeviceCharacteristics -- fail: ', res)
                this.setData({
                    connected: false,
                })

                if (res.errCode === 10006)
                {
                    that.offBLEMonitor();
                    that.createBLEConnection(deviceId, that.data.deviceName); 
                }
            }
        })

   },

   readBLECharacteristicValue(deviceId,serviceId, characteristicId )
   {
        wx.readBLECharacteristicValue({
                // 这里的 deviceId 需要已经通过 createBLEConnection 与对应设备建立链接
                deviceId,
                // 这里的 serviceId 需要在 getBLEDeviceServices 接口中获取
                serviceId,
                // 这里的 characteristicId 需要在 getBLEDeviceCharacteristics 接口中获取
                characteristicId,
                success (res) {
                    console.log('readBLECharacteristicValue:', res.errCode)
                }
         })
   },

   notifyBLECharacteristicValueChange(deviceId,serviceId, characteristicId )
   {
        var that = this;

        wx.notifyBLECharacteristicValueChange({
            state: true,    // enable notify
            deviceId,
            serviceId,
            characteristicId,

            success: (res) => {
                console.info('notifyBLECharacteristicValueChange success: ', res.errMsg)

                // read data here 
                // 操作之前先监听,保证第一时间获取数据
                wx.onBLECharacteristicValueChange(function(res) 
                {
                    that.data.connected = true; 
                    console.info('onBLECharacteristicValueChange', res);
                    console.info(`characteristic ${res.characteristicId} has changed, now is ${res.value}`);

                    var result = res.value;
                    var hex = utils.buf2hex(result);
                    var _hex_ss =  utils.hex2string(hex);

                    console.info("hex: " + hex);
                    console.info("string: " + _hex_ss);
                    that.data.rece_string += _hex_ss;

                    var recv_number_1 = that.data.recv_number + _hex_ss.length / 2;
                    var recv_number = Math.round(recv_number_1);

                    if( that.data.rece_string.includes("log:") && that.data.rece_string.includes(":end")){
                        that.setData({
                            recv_number: recv_number,
                            recv_value: that.data.recv_value + that.data.rece_string,
                        });

                        console.info("string: " + that.data.rece_string);
                        let buff =  that.data.rece_string.split(':')
                        console.log(buff)
                        that.data.rece_string = ''

                        let valueList = buff[1].split(',')
                        that.data.recv_value = "";
                        that.data.recv_number = 0;
                        console.log(valueList)
                        if(valueList.length == 4 ){
                        that.setData({
                            temphtValue: valueList[0],
                            humidityValue: valueList[1],
                            luxValue: valueList[2],
                            srValue: valueList[3],
                        });
                        } 
                    }     
                    that.monitor_connected();
                })                                 
            },

            fail: (res) => {
                console.error('notifyBLECharacteristicValueChange fail: ', res)
                that.monitor_connected();
            }
        })    
   },

   monitor_connected_action()
   {
        var that = this;


        let deviceId = that.data.deviceId;

        wx.onBLEConnectionStateChange(function(res) {
            // 该方法回调中可以用于处理连接意外断开等异常情况
            console.log( "onBLEConnectionStateChange ----- " +  `device ${res.deviceId} state has changed, connected: ${res.connected}`)
            if( res.deviceId == deviceId && res.connected == false )
            {    
                wx.closeBLEConnection({
                    deviceId,
                    success: (res) => {
                        console.debug('detail: closeBLEConnection success', res);  
                        that.offBLEMonitor();
                        that.createBLEConnection(deviceId, that.data.deviceName); 
                    },
                    fail: (res) => {                     
                        console.error('detail: closeBLEConnection fail', res);  
                        if (res.errCode === 10006) {
                            that.offBLEMonitor();
                            that.createBLEConnection(deviceId, that.data.deviceName); 
                        }
                    }
                })

                that.setData({
                    try_cnt: that.data.try_cnt + 1,
                })
            }
            else{
                that.data.try_cnt  = 0;
            }
        })   
   },

   monitor_connected()
   {
        var that = this;

        setTimeout(that.monitor_connected_action, 200);
   },

    writeValue( val ) 
    {
        // 向蓝牙设备发送一个0x00的16进制数据
        let buffer = new ArrayBuffer(1);
        let dataView = new DataView(buffer);

        dataView.setUint8(0, val);

        console.debug('getBLEDeviceCharacteristics - deviceId : ', this._deviceId)
        console.debug('getBLEDeviceCharacteristics - serviceId : ', this._serviceId)
        console.debug('getBLEDeviceCharacteristics - characteristicId: ', this._characteristicId)

        wx.writeBLECharacteristicValue({
            deviceId: this._deviceId,
            serviceId: this._serviceId,
            characteristicId: this._characteristicId,
            value: buffer,
            success: (res) => {
                console.debug('writeBLECharacteristicValue success', res);  
            },
            fail: (res) => {
                console.error(' writeBLECharacteristicValue fail', res);  
                this.setData({
                    connected: false,
                }) 
            }
        })
    },

    closeBluetoothAdapter() 
    {
        wx.closeBluetoothAdapter({           
            success (res) {
              console.log(res)
            }        
        })

        this.setData({
            connected: false,
        }),         
        this._discoveryStarted = false
    },

    closeBLEConnection( deviceId ) 
    {
        wx.closeBLEConnection({
            deviceId,
            success: (res) => {
                console.debug('detail: closeBLEConnection success', res);  
            },
            fail: (res) => {
                console.error('detail: closeBLEConnection fail', res);  
            }
        })

        this.setData({
            connected: false,
            canWrite: false,
        })
    },

    run_up:function()
    {
        var that = this;

        var val = 0x18 ;      
        that.writeValue( val );   
    }, 
    
    run_down:function()
    {
        var that = this;

        var val = 0x52;      
        that.writeValue( val );   
    },

    run_left:function()
    {
        var that = this;

        var val = 0x08;      
        that.writeValue( val );   

    },

    run_right:function()
    {
        var that = this;

        var val = 0x5a;      
        that.writeValue( val );   
    },

    whiteLightValueSliderChange:function(e)
    {
        var that = this;
        // 向蓝牙设备发送一个0x00的16进制数据
        var val = Math.random() * 255 | 0;      
        that.writeValue( val );   
    },

    offBLEMonitor(){
        this.setData({
            connected: false,
        }), 
        wx.offBLEPeripheralConnectionStateChanged();
        wx.offBLEConnectionStateChange();
        wx.offBLECharacteristicValueChange();
        wx.offBLEMTUChange();
    }
})

3 功能实现

3.1 通信协议

发送数据协议如下:

log: %d,%d,...,%d:end

Demo log如下:

log:25.07,60.69,1312,172.76:end

微信小程序log 调试信息

微信小程序端解析数据方法:

代码第313行: 判断数据包的头(log:)和尾部(:end)

代码第320行:解析字符串

3.2 系统测试 

 调试log信息,解析到下位机上传的数据

App上数据显示信息

 

 系统硬件框图:

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/2086450.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

《黑神话悟空》:国产3A游戏的崛起与AI绘画技术的融合

一、游戏简介 近年来&#xff0c;国产3A游戏《黑神话悟空》以其精美的画面、丰富的剧情和独特的文化底蕴吸引了众多玩家的关注。这款游戏以中国古典名著《西游记》为背景&#xff0c;讲述了孙悟空历经磨难&#xff0c;最终成长为斗战胜佛的故事。在游戏制作过程中&#xff0c;开…

办公必备,免费的在线万能格式转换工具

在当今数字化时代&#xff0c;文件格式转换已成为办公和日常生活中不可或缺的一部分。随着各种文件格式的不断涌现&#xff0c;人们对于高效、便捷的文件转换工具的需求日益增长。小编将为大家介绍几款免费的在线万能格式转换工具&#xff0c;帮助大家轻松应对各种文件转换需求…

golang uint8 转int出现ascll码值

在Golang中&#xff0c;uint8类型被用来表示ASCII码值。 结果是51 如果是uint8(3)的话结果还是3 所以在我们想把一个uint8类型的字符数字转换为int类型时需要特殊处理 减去对应ASCII码’0’的值 结果就是3了

Python循环结束语句 break语句 continue语句

Python break 语句 Python break语句&#xff0c;就像在C语言中&#xff0c;打破了最小封闭for或while循环。 break语句用来终止循环语句&#xff0c;即循环条件没有False条件或者序列还没被完全递归完&#xff0c;也会停止执行循环语句。 break语句用在while和for循环中。 …

df的 一列,是文字, 比如 xxxxx-1, xxxx-2 , 最后有 -1 或者 -2,把最后的数字减去1,写道一个新的列里面

file_pathrf"D:\file\工作簿1-1.xlsx"# from stutil import PandasUtil import pandas as pd dfpd.read_excel(file_path) # PandasUtil. # df的 一列&#xff0c;是文字&#xff0c; 比如 xxxxx-1, xxxx-2 , 最后有 -1 或者 -2&#xff0c;把 -1 变成 -0&#xff…

【测试面试题】14题常见APP测试面试题(参考答案)

大家好&#xff0c;这份面试题不难&#xff0c;都是一些基础题。 先上一个面试题汇总图&#xff0c;建议大家可以先思考下如果是自己能不能回答全&#xff0c;再去对照看参考答案。 下面为参考答案&#xff1a; 一、基础篇 1、APP的测试流程&#xff1f; APP测试流程与web测…

数分基础(03-3)客户特征分析--Tableau

文章目录 客户特征分析 - Tableau1. 说明2. 思路与步骤3. 数据准备和导入3.1 用EXCEL初步检查和处理数据3.1.1 打开3.1.2 初步检查&#xff08;1&#xff09;缺失值检查缺失值处理 &#xff08;2&#xff09;格式化日期字段&#xff08;3&#xff09;其他字段数据类型 &#xf…

在离线环境中安装依赖包

在离线环境中安装依赖包的方法&#xff1a; 参考文章&#xff1a; 1.如何离线下载python依赖包 2.python 依赖包打包 离线下载 3.Python的国内安装源&#xff08;也称为镜像源&#xff09; 最终安装效果&#xff0c;有部分失败的&#xff0c;重新下载失败的再去试试

达梦数据库启动与停止

1.1.1数据库启停之菜单方式启动、停止达梦数据库 当数据库服务器是Windows时&#xff0c;开始-->达梦数据库-->点击“DM服务查看器”&#xff0c;找到 “DmService【数据库实例名】” -->右键启动或停止。 下图中数据库实例名是DMSERVER 当数据库服务器是Linux时&…

kali

目录 一、网络配置 二、nat模式 1.检查服务 2.创建虚拟网卡 3.创建kali的网卡信息 三、桥接模式 四、nmap的使用 1.端口扫描 1>扫描主机端口 2>扫描指定端口 2.主机扫描 3.服务识别 4.系统识别 5.漏洞检测 6.导出扫描结果 五、msfconsole的使用 1.简介 …

imFile:全平台下载工具的新星

在数字化时代&#xff0c;我们经常需要下载各种文件和数据。一款好的下载工具不仅能提高我们的工作效率&#xff0c;还能带来愉悦的用户体验。今天&#xff0c;电脑天空将为大家介绍一款基于Motrix开发的全平台下载工具——imFile。 imFile是一款功能强大的下载工具&#xff0…

网络爬虫--生成假数据

爬取网址中的数据。 下面3个分别是姓、女孩名字、男孩名字的网址。 String familyURLStr "http://www.baijiaxing.net.cn/";String girlNameURLStr "https://wannianli.tianqi.com/qiming/news/16536.html";String boyNameURLStr "https://wanni…

python脚本自动备份华为交换机配置,Console重置密码,升级系统文件

Python脚本自动备份华为交换机配置,Console重置密码,升级系统文件 1.说明2.Console口重置密码3.版本升级4.SSH配置5.python脚本—————————————————————————————————————————————————— 1.说明 恢复密码交换机型号:Quidwa…

YB2421E是一款专为降低电磁干扰特性而设计的降压型DC/DC转换器

现代生活中&#xff0c;我们离不开各种电子设备的陪伴&#xff0c;而这些设备的正常运行离不开稳定的电源供应。YB2421E同步降压电压转换器可以满足您对电源供应的需求。 YB2421E是一款专为降低电磁干扰特性而设计的降压型DC/DC转换器。它采用了单片集成电路的设计&#xff0c;…

MyBatis错误

说明&#xff1a;记录一次MyBatis错误&#xff0c;错误信息如下&#xff0c;说数字转换异常&#xff0c;显然&#xff0c;把一个字符串类型转为数字类型&#xff0c;肯定是不行的。 2024-08-29 19:44:43.198 ERROR 24216 --- [nio-9090-exec-2] o.a.c.c.C.[.[.[/].[dispatcher…

RocketMQ部署单机版及集群版本(Docker部署)

目录 前言 单机版部署 1. 准备工作 2. 创建Docker网络 3.启动NameServer 4.启动Broker 5.启动RocketMQ控制台 集群版部署 1.启动NameServer 2.启动Broker 配置文件说明 前言 废话不多直接上干货&#xff0c;我负责踩坑&#xff0c;你负责验证。 单机版部署 1. 准备工…

DCMM数据管理能力成熟度评估模型解读

DCMM(GBT36073-2018)数据管理能力成熟度评估模型解读 DCMM标准的核心点在于通过八个核心能力域和五个成熟度等级的划分&#xff0c;全面评估企业的数据管理能力&#xff0c;并为企业提供提升数据管理能力的路径和方法&#xff0c;从而推动企业在信息化、数字化、智能化方面的发…

光伏设计中组串逆变和微型逆变是什么意思?有什么区别?

在光伏系统设计中&#xff0c;逆变器是核心组件之一&#xff0c;负责将太阳能电池板产生的直流电转换为交流电&#xff0c;以供家庭、商业或电网使用。根据设计和应用场景的不同&#xff0c;逆变器主要分为组串逆变器和微型逆变器两大类。 一、组串逆变器的定义 组串逆变器是太…

力扣面试经典算法150题:整数转罗马数字

整数转罗马数字 今天的题目是力扣面试经典150题中的数组的中等难度题&#xff1a; 整数转罗马数字。 题目链接&#xff1a;https://leetcode.cn/problems/integer-to-roman/description/?envTypestudy-plan-v2&envIdtop-interview-150 题目描述 七个不同的符号代表罗马…

【EI稳定检索】2024年第三届环境工程与可持续能源国际会议

2024年第三届环境工程与可持续能源国际会议&#xff08;EESE 2024&#xff09;将于12月20日至22日在长沙举行&#xff0c;由西安交通大学等支持&#xff0c;EI检索&#xff0c;投稿截止10月18日&#xff0c;AC学术中心提供技术支持和免费投稿系统。 2024年第三届环境工程与可持…