TMC32_QJB/VSP/VSP_init.c
2026-04-30 16:23:12 +08:00

45 lines
1.7 KiB
C

/********************************************************************************
* Copyright (c) 2016, Beijing Tongfang Microelectroics Co., Ltd.
* All rights reserved.
* Module: vsp descripter and global parameter
* Author: Yang Song
* Version: V1.0
* History:
* 2016-09-22 Original version
********************************************************************************/
#include "global.h"
//====================================================
//配置描述符
const u8 usbVspConfigDescriptor[] = {
0x09, // length
0x02, // Fixed config
VSP_CFG_LEN,0x00,
0x02, // Only support 2 interface by this configuratio
0x01, // Configuration Value is 1
0x00, // Index of string descriptor describing this configuration
0xC0, // Doesn't support remote wake up
0x32, // 100mA
//--------------- config
0x09, 0x04, 0x00, 0x00, 0x01, 0x02, 0x02, 0x01, 0x00, //接口0
0x05, 0x24, 0x00, 0x10, 0x01, //quanquan 有描述,固定就好
0x05, 0x24, 0x01, 0x00, 0x00, //
0x04, 0x24, 0x02, 0x02, //
0x05, 0x24, 0x06, 0x00, 0x01, //
0x07, 0x05, 0x83, 0x03, 0x08, 0x00, 0xFF, //0x07, 0x05, 0x82, 0x03, 0x08, 0x00, 0xFF, //端点2 IN 传输类型03-中断
0x09, 0x04, 0x01, 0x00, 0x02, 0x0A, 0x00, 0x00, 0x00, //接口1
0x07, 0x05, 0x01, 0x02, VSPRXLEN, 0x00, 0x00, //0x07, 0x05, 0x01, 0x02, 0x40, 0x00, 0x00, //端点1 OUT 传输类型02-块
0x07, 0x05, 0x82, 0x02, VSPTXLEN, 0x00, 0x00, //0x07, 0x05, 0x81, 0x02, 0x40, 0x00, 0x00, //端点1 IN 传输类型02-块
};
const u8 vspLineCoding[] =
{
//0x00, 0xC2, 0x01, 0x00, //dwDateRate 默认115200
0x80, 0x25, 0x00, 0x00, //dwDateRate 默认9600
0x00, //bCharFormat
0x00, //bParityType
0x08 //bDataBits
};