USB键盘实现——设备限定描述符(五)
文章目录
- 设备限定描述符
- 仓库地址
- 设备限定描述符介绍
- 设备限定描述符结构体定义
- 获取设备限定描述符的请求
- 标准设备请求
- USB 控制端点收到的数据
- 设备限定描述符返回
- 附 STM32 枚举日志
设备限定描述符
设备限定描述符内容解析和 HID鼠标 一致。
仓库地址
仓库地址
设备限定描述符介绍
设备限定描述符(Device Qualifier Descriptor)说明了能进行高速操作的设备在其他速度时产生的变化信息。例如,如果设备当前在全速下操作,设备限定描述符返回它如何在高速运行的信息。
如果设备既支持全速状态又支持高速状态,那么就必须含有设备限定描述符(Device Qualifier Descriptor)。设备限定描述符(Device Qualifier Descriptor)中含有当前没有使用的速度下这些字段的取值。
设备限定描述符(Device Qualifier Descriptor)不包含标准设备描述符中的厂商、产品、设备、制造厂商、产品和序列号场,因为在所有支持的速度下设备的这些信息都是常数。这个描述符的版本号至少是2.0(0200H)。
如果只能进行全速(full-speed)操作的设备(设备描述符的版本号等于0200H)接收到请求设备限定符的Get Descriptor请求,它必须用请求错误响应,回复STALL来响应。
主机端只能在成功取得设备限定描述符(Device Qualifier Descriptor)之后,才能请求其他速度配置(other_speed_configuration)描述符。
- bLength:0x0a
- 设备限定描述符的长度。
- bDescriptorType:0x06
- 设备限定描述符类型,为DEVICE_QUALIFIER (0x06)。
- bcdUSB:版本号
- 是设备所符合的USB规范的版本号,该值采用BCD(用二进制编码的十进制数)格式。USB 2.0是0x0200;USB 2.1是0x0210。
- bDeviceClass类码
- 这个字段为那些在设备层次定义功能的设备规定了它们所属的类。
- bDeviceSubClass子类码
- 这个字段规定一个类的子类
- bDeviceProtocol协议码
- 这个字段为所选的类和子类规定一个协议。
- bMaxPacketSize0
- 为其他速度(Other-speed)的端点0最大包大小。
- bNumConfigurations
- 为其他速度(Other-speed)配置的数量。
设备限定描述符结构体定义
typedef struct __attribute__ ((packed))
{uint8_t bLength ; ///< Size of descriptoruint8_t bDescriptorType ; ///< Device Qualifier Typeuint16_t bcdUSB ; ///< USB specification version number (e.g., 0200H for V2.00)uint8_t bDeviceClass ; ///< Class Codeuint8_t bDeviceSubClass ; ///< SubClass Codeuint8_t bDeviceProtocol ; ///< Protocol Codeuint8_t bMaxPacketSize0 ; ///< Maximum packet size for other speeduint8_t bNumConfigurations ; ///< Number of Other-speed Configurationsuint8_t bReserved ; ///< Reserved for future use, must be zero
}usb_desc_device_qualifier_t;
获取设备限定描述符的请求
标准设备请求
typedef struct __attribute__ ((packed)){union {struct __attribute__ ((packed)) {uint8_t recipient : 5; ///< Recipient type usb_request_recipient_t.uint8_t type : 2; ///< Request type usb_request_type_t.uint8_t direction : 1; ///< Direction type. usb_dir_t} bmRequestType_bit;uint8_t bmRequestType;};uint8_t bRequest;uint16_t wValue;uint16_t wIndex;uint16_t wLength;
} usb_control_request_t;
USB 控制端点收到的数据
0x80 0x6 0x0 0x6 0x0 0x0 0xa 0x0
- bmRequestType:0x80
- 数据传输方向为 1,device-to-host
- 标准请求
- 请求的接收者为设备
- bRequest:0x06
- GET_DESCRIPTOR 获取描述符请求
- wValue:0x0006(LSB)
- 低位:0x06 设备限定描述符
- 高位:0x00 索引号
- wIndex:0x0000(LSB)
- 低位:0x00
- 高位:0x00
- wLength:0x0a
- 低位:0x0a 请求返回的字节数为 0x0a,设备限定描述符的长度为 0x0a
- 高位:0x00
设备限定描述符返回
由于当前只能进行全速(full-speed)操作(设备描述符的版本号等于0200H),设备接收到请求设备限定符的 Get Descriptor 请求,它必须用请求错误响应,回复 STALL 来响应。
USB 传输日志片段如下:
output ep int
h->d: 0x80 0x6 0x0 0x6 0x0 0x0 0xa 0x0
send xfer complete event
get device qualifier
stall ep0
如果需要返回设备限定描述符,设备限定描述符的实现如下(当前未使用)
usb_desc_device_qualifier_t const desc_device_qualifier =
{.bLength = sizeof(usb_desc_device_qualifier_t),.bDescriptorType = USB_DESC_DEVICE_QUALIFIER,.bcdUSB = USB_BCD,.bDeviceClass = 0x00,.bDeviceSubClass = 0x00,.bDeviceProtocol = 0x00,.bMaxPacketSize0 = USBD_ENDPOINT0_SIZE,.bNumConfigurations = 0x01,.bReserved = 0x00
};
附 STM32 枚举日志
HID 键盘枚举日志
suspend int
bus reset int
enum done int
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x0 0x1 0x0 0x0 0x40 0x0
dcd xfer 12
input ep int
d->h :0x12 0x1 0x0 0x2 0x0 0x0 0x0 0x40 0xfe 0xca 0x8 0x40 0x0 0x1 0x1 0x2 0x3 0x1
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
bus reset int
output ep int
send xfer complete event
enum done int
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x0 0x5 0x4 0x0 0x0 0x0 0x0 0x0
dcd xfer 0
input ep int
edpt int send xfer complete event
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x0 0x1 0x0 0x0 0x12 0x0
dcd xfer 12
input ep int
d->h :0x12 0x1 0x0 0x2 0x0 0x0 0x0 0x40 0xfe 0xca 0x8 0x40 0x0 0x1 0x1 0x2 0x3 0x1
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
output ep int
send xfer complete event
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x0 0x2 0x0 0x0 0xff 0x0
dcd xfer 22
input ep int
d->h :0x9 0x2 0x22 0x0 0x1 0x1 0x0 0xa0 0x32 0x9 0x4 0x0 0x0 0x1 0x3 0x1 0x1 0x0 0x9 0x21 0x11 0x1 0x0 0x1 0x22 0x41 0x0 0x7 0x5 0x81 0x3 0x8 0x0 0xa
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x3 0x3 0x9 0x4 0xff 0x0
send xfer complete event
dcd xfer e
input ep int
d->h :0xe 0x3 0x31 0x0 0x32 0x0 0x33 0x0 0x34 0x0 0x35 0x0 0x36 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x0 0x3 0x0 0x0 0xff 0x0
send xfer complete event
dcd xfer 4
input ep int
d->h :0x4 0x3 0x9 0x4
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x2 0x3 0x9 0x4 0xff 0x0
send xfer complete event
dcd xfer 1e
input ep int
d->h :0x1e 0x3 0x74 0x0 0x79 0x0 0x75 0x0 0x73 0x0 0x74 0x0 0x6c 0x0 0x69 0x0 0x20 0x0 0x44 0x0 0x65 0x0 0x76 0x0 0x69 0x0 0x63 0x0 0x65 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x0 0x6 0x0 0x0 0xa 0x0
send xfer complete event
get device qualifier
stall ep0
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x0 0x1 0x0 0x0 0x12 0x0
dcd xfer 12
input ep int
d->h :0x12 0x1 0x0 0x2 0x0 0x0 0x0 0x40 0xfe 0xca 0x8 0x40 0x0 0x1 0x1 0x2 0x3 0x1
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x0 0x2 0x0 0x0 0x9 0x0
send xfer complete event
dcd xfer 9
input ep int
d->h :0x9 0x2 0x22 0x0 0x1 0x1 0x0 0xa0 0x32
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x0 0x2 0x0 0x0 0x22 0x0
send xfer complete event
dcd xfer 22
input ep int
d->h :0x9 0x2 0x22 0x0 0x1 0x1 0x0 0xa0 0x32 0x9 0x4 0x0 0x0 0x1 0x3 0x1 0x1 0x0 0x9 0x21 0x11 0x1 0x0 0x1 0x22 0x41 0x0 0x7 0x5 0x81 0x3 0x8 0x0 0xa
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x0 0x9 0x1 0x0 0x0 0x0 0x0 0x0
send xfer complete event
edpt open
dcd xfer 0
input ep int
edpt int send xfer complete event
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x21 0xa 0x0 0x0 0x0 0x0 0x0 0x0
dcd xfer 0
input ep int
edpt int send xfer complete event
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x81 0x6 0x0 0x22 0x0 0x0 0x81 0x0
dcd xfer 40
input ep int
d->h :0x5 0x1 0x9 0x6 0xa1 0x1 0x5 0x7 0x19 0xe0 0x29 0xe7 0x15 0x0 0x25 0x1 0x95 0x8 0x75 0x1 0x81 0x2 0x95 0x1 0x75 0x8 0x81 0x1 0x5 0x8 0x19 0x1 0x29 0x5 0x95 0x5 0x75 0x1 0x91 0x2 0x95 0x1 0x75 0x3 0x91 0x1 0x5 0x7 0x19 0x0 0x2a 0xff 0x0 0x15 0x0 0x26 0xff 0x0 0x95 0x6 0x75 0x8 0x81 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 1
input ep int
d->h :0xc0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
output ep int
send xfer complete event
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x21 0x9 0x0 0x2 0x0 0x0 0x1 0x0
dcd xfer 1
rxflvl int
output ep int
send xfer complete event
dcd xfer 0
input ep int
edpt int send xfer complete event
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x0 0x3 0x0 0x0 0xff 0x0
dcd xfer 4
input ep int
d->h :0x4 0x3 0x9 0x4
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x1 0x3 0x9 0x4 0xff 0x0
send xfer complete event
dcd xfer 10
input ep int
d->h :0x10 0x3 0x74 0x0 0x79 0x0 0x75 0x0 0x73 0x0 0x74 0x0 0x6c 0x0 0x69 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
setup packed recvd
setup packed done
output ep int
h->d: 0x80 0x6 0x2 0x3 0x9 0x4 0xff 0x0
send xfer complete event
dcd xfer 1e
input ep int
d->h :0x1e 0x3 0x74 0x0 0x79 0x0 0x75 0x0 0x73 0x0 0x74 0x0 0x6c 0x0 0x69 0x0 0x20 0x0 0x44 0x0 0x65 0x0 0x76 0x0 0x69 0x0 0x63 0x0 0x65 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 0
rxflvl int
output ep int
send xfer complete event
dcd xfer 8
0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
input ep int
d->h :0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 8
0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
input ep int
d->h :0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 8
0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
input ep int
d->h :0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 8
0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
input ep int
d->h :0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 8
0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
input ep int
d->h :0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 8
0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
input ep int
d->h :0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 8
0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
input ep int
d->h :0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 8
0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
input ep int
d->h :0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 8
0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
input ep int
d->h :0x0 0x0 0x4 0x0 0x0 0x0 0x0 0x0
turn off txfe
input ep int
edpt int send xfer complete event
dcd xfer 8
0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0
input ep int
d->h :0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0
turn off txfe
input ep int
edpt int send xfer complete event
相关文章:
USB键盘实现——设备限定描述符(五)
文章目录设备限定描述符仓库地址设备限定描述符介绍设备限定描述符结构体定义获取设备限定描述符的请求标准设备请求USB 控制端点收到的数据设备限定描述符返回附 STM32 枚举日志设备限定描述符 设备限定描述符内容解析和 HID鼠标 一致。 仓库地址 仓库地址 设备限定描述符…...
【C++】map和set(一文拿捏,包教包会)
目录 1.关联式容器和序列式容器 2.键值对 3.树型结构的关联式容器 4.set 5.multiset 6.map 7.multimap 1.关联式容器和序列式容器 set:关联式容器——数据之间关联紧密 线性表(vector,list,deque):序…...
爬虫Day2 正则表达式
爬虫Day2 正则表达式 一、正则表达式 1. 正则的作用 正则表达式是一种可以让复杂的字符串变得简单的工具。 写正则表达式就是用正则符号来描述字符串规则 # 案例1:判断一个字符串是否是一个合法的手机号码 tel 23297293329# 方法1:不用正则 if len…...
LeetCode-0324~28
leetCode1032 思路:想的是维护一个后缀数组,然后用Set去判断一下,结果超时了,去看题解,好家伙AC自动机,没办法,开始学。 正确题解: class ACNode{public ACNode[] children;publi…...
Vue2自己封装的基础组件库或基于Element-ui再次封装的基础组件库,如何发布到npm并使用(支持全局或按需引入使用),超详细
最终效果如下 一、先创建vue2项目 1、 可以用vue-cli自己来创建;也可以直接使用我开源常规的vue2后台管理系统模板 以下我以 wocwin-admin-vue2 项目为例 修改目录结构,最终如下 2、修改vue.config.js文件 module.exports { // 修改 src 目录 为 exam…...
【开发】中间件——MongoDB
MongoDB是一个基于分布式(海量数据存储)文件存储的数据库。 MongoDB是一个介于关系数据库和非关系数据库之间的产品,是非关系数据库当中功能最丰富,最像关系数据库的,它支持的数据结构非常松散,是类似json…...
C++进阶 — 【C++11】
目录 一、 C11简介 二、 统一的列表初始化 1.{}初始化 2. initializer_list 三、声明 1. auto 2. decltype 3. nullptr 四、范围for循环 五、STL中一些变化 1. 提供了一些新容器 2.容器中增加了一些新方法 六、右值引用和移动语义 1. 左值引用和右…...
Mac安装Homebrew
1.前往Homebrew官网,复制官网的安装命令 https://brew.sh/ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"安装结束后,记得仔细看脚本执行最后的提示,需要我们复制两行命令执…...
【详细】利用VS2019创建Web项目,并发送到IIS,以及IIS与ASP.NET配置
一、打开VS2019选择创建新项目【最好以管理员身份运行VS2019,后面发布网站时需要以管理员身份,避免后面还要重启,可以一开始就以管理员身份运行】 二、选择语言为C#,然后选择“ASP.NET Web应用程序(.NET Framework&…...
FasterRcnn,Yolov2,Yolov3中的Label Assignment机制 和 ATSS
一般把anchor到gt之间如何匹配的方法称为label assignment,也就是给预设的anchor打上正负样本等标签,方便我们后续进一步回归。 其实RPN和Yolo有各自的label assignment方法, 在Faster rcnn,yolo,RetinaNet中…...
使用Java技术WebSocket创建聊天、群聊,实现好友列表,添加好友,好友分组,聊天记录查询功能。
文章目录 引入依赖主要代码配置WebSocket创建通讯完整后台项目代码下载WebSocket的由来: 之前只有一个http协议,http协议是请求响应,存在缺陷,就是请求只能由客户端发起,然后请求到服务器,服务器做响应,但是如果服务器状态做了改变,客户端并不能即使的更新,之前的是按照…...
【Redis07】Redis基础:Bitmap 与 HyperLogLog 相关操作
Redis基础学习:Bitmap 与 HyperLogLog 相关操作继续进行 Redis 基础部分的学习,今天我们学习的是两种另外的数据类型。说是数据类型,但其实它们实际上使用的都是 String 类型做为底层基础,只不过是在存储的时候进行了一些特殊的操…...
华为路由器 VRRP主备配置
组网需求 如下图所示,PC1通过SW1双归属到R1和R2。为保证用户的各种业务在网络传输中不中断,需在R1和R2上配置VRRP主备备份功能。 正常情况下,主机以R1为默认网关接入Internet,当R1故障时,R2接替R1作为网关继续进行工作…...
docker容器安装ES
1.拉取镜像 docker pull elasticsearch:6.5.42.修改别名 docker tag [容器ID] es65:6.5.42.启动应用 docker run -it -d -p 9200:9200 -p 9300:9300 --name es -e ES_JAVA_OPTS"-Xms128m -Xmx128m" es65:6.5.43.拷贝配置文件到宿主机 docker cp es:/usr/share/ela…...
Python Module — prompt_toolkit CLI 库
目录 文章目录目录prompt_toolkit示例化历史记录热键自动补全多行输入Python 代码高亮自定义样式prompt_toolkit prompt_toolkit 是一个用于构建 CLI 应用程序的 Python 库,可以让我们轻松地构建强大的交互式命令行应用程序。 自动补全:当用户输入命令…...
springboot mybatis-plus 调用 sqlserver 的 存储过程 返回值问题
问题: 在使用 mybatis-plus 调用sqlserver 存储过程 没有返回值 经过资料查找 注意点 此处使用Map传参,原因在于存储过程的返回值,通常在参数定义中实现,如In 入参、out 出参。 这样当执行后有结果返回时,则可以将结…...
【0180】PG内核读取pg_hba.conf并创建HbaLine记录(1)
文章目录 1. pg_hba.conf文件是什么?2. postmaster何时读取pg_hba.conf?2.1 pg内核使用pg_hba.conf完成客户端认证的原理2.2 读取pg_hba.conf的几个模块3. pg内核读取pg_hba.conf过程3.1 VFD机制获取文件描述符3.2 根据fd读取文件内容相关阅读: 【0178】DBeaver、pgAdmin I…...
【原型设计工具】上海道宁为您提供Justinmind,助力您在几分钟内形成原型,并现场测试,无需编写任何代码
Justinmind是用于 Web和应用程序的原型制作工具 在几分钟内形成原型 并在现场进行测试 无需编写任何代码 单击一下即可轻松在线获取您的设计 并与整个团队共享 享受高效的沟通和快速反馈 以实现持续改进和利益相关者的支持 开发商介绍 JustinMind是由西班牙JustinMind公…...
计算机网络中---HDLP协议和PPP协议
目录 HDLC协议PPP协议HDLC协议和PPP协议HDLC协议 HDLC协议【高级数据链路控制协议】是一种数据链路层协议,用于在两个节点之间传输数据。以下是HDLC协议的重点知识: HDLC协议定义了一种标准的帧格式,包括起始标志、地址字段、控制字段、信息字段、校验字段和结束标志。HDLC…...
k8s之节点kubelet预留资源配置
k8s之kubelet预留资源配置1 前言2 预留资源Kube-reservedSystem-reservedEviction Thresholds实施节点可分配约束3 Pod优先级4 生产应用配置文件重启kubelet服务查看节点资源1 前言 最近k8s在使用过程中遇到这样一个问题 由于Pod没有对内存及CPU进行限制,导致Pod在…...
ES6从入门到精通:前言
ES6简介 ES6(ECMAScript 2015)是JavaScript语言的重大更新,引入了许多新特性,包括语法糖、新数据类型、模块化支持等,显著提升了开发效率和代码可维护性。 核心知识点概览 变量声明 let 和 const 取代 var…...
<6>-MySQL表的增删查改
目录 一,create(创建表) 二,retrieve(查询表) 1,select列 2,where条件 三,update(更新表) 四,delete(删除表…...
Debian系统简介
目录 Debian系统介绍 Debian版本介绍 Debian软件源介绍 软件包管理工具dpkg dpkg核心指令详解 安装软件包 卸载软件包 查询软件包状态 验证软件包完整性 手动处理依赖关系 dpkg vs apt Debian系统介绍 Debian 和 Ubuntu 都是基于 Debian内核 的 Linux 发行版ÿ…...
在rocky linux 9.5上在线安装 docker
前面是指南,后面是日志 sudo dnf config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo sudo dnf install docker-ce docker-ce-cli containerd.io -y docker version sudo systemctl start docker sudo systemctl status docker …...
java调用dll出现unsatisfiedLinkError以及JNA和JNI的区别
UnsatisfiedLinkError 在对接硬件设备中,我们会遇到使用 java 调用 dll文件 的情况,此时大概率出现UnsatisfiedLinkError链接错误,原因可能有如下几种 类名错误包名错误方法名参数错误使用 JNI 协议调用,结果 dll 未实现 JNI 协…...
Yolov8 目标检测蒸馏学习记录
yolov8系列模型蒸馏基本流程,代码下载:这里本人提交了一个demo:djdll/Yolov8_Distillation: Yolov8轻量化_蒸馏代码实现 在轻量化模型设计中,**知识蒸馏(Knowledge Distillation)**被广泛应用,作为提升模型…...
JVM 内存结构 详解
内存结构 运行时数据区: Java虚拟机在运行Java程序过程中管理的内存区域。 程序计数器: 线程私有,程序控制流的指示器,分支、循环、跳转、异常处理、线程恢复等基础功能都依赖这个计数器完成。 每个线程都有一个程序计数…...
LLMs 系列实操科普(1)
写在前面: 本期内容我们继续 Andrej Karpathy 的《How I use LLMs》讲座内容,原视频时长 ~130 分钟,以实操演示主流的一些 LLMs 的使用,由于涉及到实操,实际上并不适合以文字整理,但还是决定尽量整理一份笔…...
CRMEB 中 PHP 短信扩展开发:涵盖一号通、阿里云、腾讯云、创蓝
目前已有一号通短信、阿里云短信、腾讯云短信扩展 扩展入口文件 文件目录 crmeb\services\sms\Sms.php 默认驱动类型为:一号通 namespace crmeb\services\sms;use crmeb\basic\BaseManager; use crmeb\services\AccessTokenServeService; use crmeb\services\sms\…...
Caliper 配置文件解析:fisco-bcos.json
config.yaml 文件 config.yaml 是 Caliper 的主配置文件,通常包含以下内容: test:name: fisco-bcos-test # 测试名称description: Performance test of FISCO-BCOS # 测试描述workers:type: local # 工作进程类型number: 5 # 工作进程数量monitor:type: - docker- pro…...
