社区
驱动开发/核心开发
帖子详情
bus hound发送命令时invalid command
wq703058
2020-08-03 04:54:54
自己的USB设备,插入电脑后能够正常的枚举识别,bushound中也能看到新插入的USB设备,可以通过bushound向USB设备发送命令时,出现invalid commnad的提示,即使点reset device也会出现invalid command,请问有大神知道怎么调试这个问题吗 是硬件有问题还是软件有问题
...全文
17566
5
打赏
收藏
bus hound发送命令时invalid command
自己的USB设备,插入电脑后能够正常的枚举识别,bushound中也能看到新插入的USB设备,可以通过bushound向USB设备发送命令时,出现invalid commnad的提示,即使点reset device也会出现invalid command,请问有大神知道怎么调试这个问题吗 是硬件有问题还是软件有问题
复制链接
扫一扫
分享
转发到动态
举报
写回复
配置赞助广告
用AI写文章
5 条
回复
切换为时间正序
请发表友善的回复…
发表回复
打赏红包
墓碑chun
2022-02-23
打赏
举报
回复
我的不是锁不锁的原因,只要复位到时间久一点,就发送无效,不知道咋个机制
wq703058
2020-10-30
打赏
举报
回复
1
我也是试了好久才发现
qq_26078991
2020-09-02
打赏
举报
回复
我也试了好久才发现
qq_26078991
2020-09-02
打赏
举报
回复
点Lock之后才能发
C_linux_233
2021-11-08
举报
回复
@qq_26078991
还真的是这样,查代码查了半天找不到问题,原来要LOCK以后才能发
BUS
Hound
Bus
Hound
5.0
Copyright (C) Perisoft 2000-2003. All rights reserved worldwide.
Bus
Hound
is a powerful software
bus
analyzer for capturing I/O and protocol from devices. Features include:
Supports every version of IDE, SCSI, USB, 1394
Supports all devices such as hard drives, DVD, mice, scanners, web cams, and everything else
Supports Windows 95, 98, Me, NT 4.0, 2000, 2003, XP and XP Embedded
Capture megabytes of I/O limited only by available memory
Automatically stop the capture upon a trigger condition
Measure individual read, write, and isochronous device performance
Captures device driver packets such as IRP’s
Filter what type of phases are captured
Run on an unlimited number of machines at the same time
Capture any number of devices in parallel, regardless of
bus
type
Fits on a diskette for easy transportability and quick downloads
Drag and drop captured data to other products in html format
Save captured data to a text file or zip file
Simple device selection from a graphical tree of devices
Capture the system startup process
Arrange captured data to user preferences such as the byte width per line
View low level protocol including SCSI sense data and USB setup packets
View microsecond resolution timing of each phase
Watch I/O on screen in real time as it happens
Pure software solution--no extra hardware or system changes needed
The Capture Window
Command
s sent to devices consist of one or more phases. Examples of phases are
command
bytes, data bytes, and status bytes.
Bus
hound
logs each phase complete with timing information and a description of the content.
Capture columns
Below are descriptions of information in each column of the Capture Window:
Device
Device ID. Each device is assigned a number which can be matched up with devices in the Devices Window. The first detected device on the system is Device ID 0, the second is Device ID 1, and so on. This field is useful in the event multiple devices are being captured in parallel.
For USB devices, the endpoint is also displayed (eg: 4.1 = device 4, endpoint 1).
Phase
Phase type. Please refer to the table for details of each phase type.
Phase Description
ADDR 8 byte 1394 transfer address
ATI 7 byte ATA task file returned from an IDE device
ATO 7 byte ATA task file sent to an IDE device
ATP Windows ATA_PASS_THROUGH data structure
CDB SCSI
command
descriptor block
(Known as a packet
command
for ATAPI devices)
CTL 8 byte setup packet of a USB control transfer
DI Data In (Device to PC transfer)
DO Data Out (PC to device transfer)
IOR Windows VXD I/O Request data structure
IRB Windows 1394 I/O Request Block data structure
IRP Windows I/O Request Packet data structure
ISOC Isochronous transfer data bytes
LEN Data transfer length of a DI,DO, or ISOC phase in
decimal units. This field is off by default and can be
turned on from the settings Window
LOCK 1394 lock transaction
NSTS Windows 4 byte kernel mode NTSTATUS field
RSET
Bus
or device reset
RSTS Windows VXD IOR status
SNS SCSI request sense data
SPT Windows SCSI Pass Through data structure
SRB Windows SCSI Request Block (SRB) data structure
SSTS Windows 1 byte SCSI Request Block (SRB) status
STAK Windows IO_STACK_LOCATION data structure
URB Windows USB Request Block (URB) data structure
USTS Windows 4 byte USBD_STATUS code
Data
Data bytes associated with the phase. Examples are
command
bytes, data transfer bytes, and status bytes.
Description
A text description of this phase provided for your convenience.
Delta
Elapsed time from the previous phase to the current phase. The following table describes the units of the time format.
Name Units
us Microseconds
ms Milliseconds
sc Seconds
mn Minutes
hr Hours
dy Days
Cmd.Phase.Ofs(rep)
This unique tag identifies the exact position within the captured data. All values are in decimal.
Cmd is the
command
number.
Command
s start at 1 and increment for each new
command
sent to a device.
Phase is the phase number within this
command
. A
command
is usually composed of multiple phases such as data transfer and status. This value starts at 1 and increments for each new phase within the
command
.
Ofs is the byte offset of the data within this phase. This value starts at 0 and increments for each byte of data in the data transfer.
Rep is the number of identical
command
s issued back to back. The repeat count feature can be turned off by deselecting the “Merge Repeated
Command
s” check box in the settings Window.
Date
Date the phase occurred in year/month/day format.
Time
Time the phase occurred in hour:minute:second.millisecond format. The hour ranges from 0 to 23 (military time).
Capturing the system startup process
If the
Bus
Hound
application is exited while the Run button is pressed, the device driver portion of
Bus
Hound
continues capturing data. In the event the system is restarted, it will start capturing data early in the system startup process.
If
Bus
Hound
is exited while stopped, no capture will occur until returning to the product and pressing Run.
Customizing the capture display
The column order can be modified by dragging the column headers to the desired position. The byte width per line can be 1, 2, 4, 8, 16, or 32 bytes and is based on the width of the window. These settings are respected for Saving and drag & drop.
Searching
Searching can be performed from the capture window in either the up or down direction by typing the search string in the lower left edit box followed by pressing the up or down arrow to search up or down respectively. If the search string is not found, the trace position is not changed. Searching is not case sensitive.
Drag and Drop
To use drag and drop, first select the desired range of lines by clicking on the starting line, then hold down shift and click the ending line. The data can now be dragged using the mouse to another product.
Pressing control-c copies the selected lines to the clipboard.
Command
Overlap
Overlapped
command
s are identified when a
command
starts before previous
command
s to the same device have completed. It is possible for
Command
s to be overlapped at the I/O subsystem level (which
Bus
Hound
displays), but not at the hardware level.
Multiple DI/DO phases
Windows 9x only: if multiple DI/DO phases are listed for the same
command
, it indicates the transfer was split across multiple memory address ranges
PS2 Mouse data format
Below is the format of the data returned in the data in phase for PS/2 mice. This is known as the MOUSE_INPUT_DATA structure in the Windows DDK:
Offset Length Content
0 2 Not used
2 2 Position type:
0000h = relative position
0001h = absolute position
4 2 Button flags:
0001h = left button down
0002h = left button up
0004h = right button down
0008h = right button up
0010h = middle button down
0020h = middle button up
0040h = button 4 down
0080h = button 4 up
0100h = button 5 down
0200h = button 5 up
0400h = mouse wheel
6 2 Mouse wheel data
8 4 Not used
12 4 X position
16 4 Y position
20 4 Device specific information
PS2 Keyboard data format
Below is the format of the data returned in the data in phase for PS/2 keyboards. This is known as the KEYBOARD_INPUT_DATA structure in the Windows DDK:
Offset Length Content
0 2 Not used
2 2 Scan code of key
4 2 Flags:
0000h = key pressed
0001h = key released
0002h = extended scan code E0
0004h = extended scan code E1
6 2 Not used
8 4 Device specific information
The Save Window
The Save button saves all captured data to the specified file. The format of the file can be either a text file containing standard ASCII characters or a Zip file. The data will be saved in the same column order and byte width as seen on the screen.
A comment can be provided that will be placed into the header of the captured data. The current date and time can be included in the comment by inserting %c anywhere inside the comment. If saving to a zip file, the comment is also used for the zip file comment.
The Settings Window
This Window allows you to customize the capture process. Checkbox options in this window are applied instantly. Numeric entries are applied by pressing the apply button, switching to another window, or exiting
Bus
Hound
.
Buffer Size
Specifies the number of kilobytes of RAM to use for capturing data. The size is limited only by system RAM. If not enough RAM is available to satisfy the requested size, the size is reduced to available RAM. If you need to get as much space as possible, besides adding more RAM to a system you can also try setting the buffer size before starting other applications. Note: allocating a very large buffer size under Windows 95/98/Me can take a minute.
Max Phase
Specifies the maximum number of bytes that will be captured on each phase. Example: if Max Phase is set to 32 bytes and a 64K read operation occurs, only the first 32 bytes of the read will be captured. This option is useful for keeping the size of the captured data to a minimum.
Stop When...
These are triggers that allow the capture to automatically stop when the specified condition is met. Any combination of triggers may be selected. When a trigger condition is met, the capture stops and the trigger text is highlighted in red.
Any Other Error stops the capture when an error occurs that does not fall into any of the other categories.
Buffer Full stops the capture when
Bus
Hound
's buffer is full. If Buffer Full is deselected, capturing continues after the buffer is full, keeping the most recently captured data.
Bus
Reset stops the capture when a
bus
reset occurs.
Data Overrun stops the capture when a data overrun or data underrun occurs.
Hardware Error stops the capture when a hardware error occurs.
Invalid
Command
stops the capture when an
invalid
command
is issued.
Media Error stops the capture when a device reports a media error such as a bad sector.
No Media stops the capture when a device reports no media is present.
Not Ready stops the capture upon a not ready, timeout, or
bus
y condition.
Text Pattern / Hex Pattern stops the capture when the specified data pattern is detected in the captured data. For text patterns, the match is case sensitive. The pattern is checked against the data transferred in any phase including
command
s, data, and status.
Vendor Error stops the capture when a vendor unique error occurs.
Windows Error stops the capture when an operating system type error occurs.
Phases to Capture
Contains a list of all the phase types
Bus
Hound
can capture. Placing a check mark next to a phase allows it to be captured. Removing a check mark next to a phase results in the phase not being captured. This option is useful for filtering out phases that are not of interest or including special operating system phases that are off by default.
To the right of the check box, a white circle may appear. This indicates the phase has been detected and exists in the captured data. If the circle blinks bright green, it is a real time activity light indicating the phase has occurred and has been captured.
Merge Repeated
Command
s
When selected, if a
command
occurs that is identical to the previous
command
, the new
command
will not be logged separately. Instead, the repeat count of the previous
command
is incremented. This option is useful for compacting the captured data when a device is being continually polled with the same
command
.
Enable Sounds
If this option is enabled,
Bus
Hound
will make an audible "ping" if the capture, settings, or devices window is up and a trigger condition is met.
Columns to Display
Place a checkmark in the boxes to include the desired columns in the Capture Window. The selected columns will also be included in drag & drop and save operations. See the section “The Capture Window” for more details about each column.
The Devices Window
The list of devices represents every device on the system which
Bus
Hound
supports. The list automatically refreshes to reflect new or removed devices. To select/deselect a device to capture, click in the check box next to the device. The selection will be applied instantly.
Each device is assigned a number which is in parenthesis before the name of the device. This number is displayed in the capture window under the "Device" column. The number reflects the order in which the device was added to the system.
If a device is displayed in a light font, it indicates the device is not currently present on the system.
Capture new devices
Selecting this checkbox will automatically capture data for new devices that are detected. This feature is useful for capturing the first
command
s sent to hot plugged devices.
Device Properties
This window pane displays details about the device such as the performance. The performance is calculated by summing the total bytes transferred divided by the total elapsed time of the
command
s. The performance statistics are cleared when the run button is pressed in the Capture window.
Send
Command
s
You can send your own custom
command
s to a device using
Bus
Command
er. To start
Bus
Command
er, highlight a device with the mouse and click the “Send
Command
s” button or simply double click the device.
Bus
Command
er is a very powerful complementary tool that lets you submit USB, 1394, ATA and SCSI
command
s to devices. You can also perform operations like
bus
resets and hardware port i/o.
Files Installed
BUS
HOUND
.EXE -
Bus
Hound
application
BUS
CMDR.EXE -
Bus
Command
er application
BHUNINST.EXE - uninstaller
BHLOG.EXE - capture to disk tool (site license version only)
B
HOUND
3.VXD - device driver for Windows 95, 98, Me
B
HOUND
4.SYS - device driver for Windows NT 4.0
B
HOUND
5.SYS - device driver for Windows 98, Me, 2000, 2003, XP
HELP.RTF - product help file (this file)
Site License
The site license version of
Bus
Hound
includes the bhlog.exe
command
line tool in the folder where
Bus
Hound
is installed. bhlog spools captured data to a disk file in real time. This tool raises the maximum capture size from available RAM to available disk space. bhlog also has the ability to retain captured data in the event a system freezes or reboots by directing captured data to a file on a network drive.
FAQ
1. What type of I/O is captured?
Bus
Hound
takes a snap shot of packets sent across the
bus
. This includes
command
s, data, status, and timing of each
command
.
Bus
Hound
does not monitor individual hardware signals.
2. Will
Bus
Hound
change the behavior of my devices?
No.
Bus
Hound
simply “listens” for packets.
Bus
Hound
does not alter
command
s, does not send its own
command
s, does not replace any system drivers, and does not access the hardware. The system and devices will operate identically whether
Bus
Hound
is installed or not.
3. Will
Bus
Hound
degrade system performance?
Customers capturing data from extremely fast devices in parallel have been impressed by
Bus
Hound
’s ability not to effect performance.
Bus
Hound
is even more innocuous when in the stopped state.
4. Which devices are supported?
All IDE, SCSI, USB and 1394 devices are supported including disk drives, mice, scanners, web cams, and everything else. Devices that emulate one of these
bus
es are also supported such as certain parallel port devices.
5. Why are there duplicate devices?
For some devices, Windows first forms high level packets that are then translated into low level packets which are in turn sent to the hardware.
Bus
Hound
shows several devices so you can choose which level of I/O you wish to capture.
6. What does capturing I/O for a controller do?
Some controllers receive
command
s and some do not. You can experiment capturing data for a controller to see if the packets are of interest.
7. What if
Bus
Hound
does not show a device?
No devices are displayed when the system is started in safe mode. This is a safety feature to keep safe mode as clean as possible.
Devices which are marked with a problem in device manager are not displayed.
SCSI adapters are not displayed under Windows 95/98/Me unless they have one or more devices attached.
8. Why are some devices grayed out?
A grayed out device indicates it is currently not attached to the system.
9. Windows 95/98/Me crashes when pressing run. What do I do?
Due to limitations in the Windows 9x architecture, if too many device drivers ask to receive notification of I/O completion, the system will crash. Microsoft device drivers and other installed software such as
Bus
Hound
need such notifications. To resolve this, remove software likely to have additional device drivers installed for the device. For CD/DVD drives, an easy solution is to rename the legacy scsi1hlp.vxd to scsi1hlp.bak which is in the windows/system/iosubsys folder.
10. Why am I not able to capture all 1394 events?
Some 1394 devices
Bus
Hound
displays are logical devices such as AV/VHS devices. Select devices further up the tree to capture
bus
activity for such devices.
While
Bus
Hound
logs every isochronous transaction, there is no practical way for
Bus
Hound
to see every asynchronous transaction. If you need to see more 1394 activity, note
Bus
Hound
can capture a great deal more in operating systems prior to XP, particularly for SBP-2 devices.
11. Why am I not seeing task file (ATA)
command
s for IDE hard drives?
Bus
Hound
captures ATA
command
s only when an application or driver explicitly sends an ATA
command
(eg: SMART, IDENTIFY). For normal file system requests,
Bus
Hound
captures SCSI CDB's instead of ATA
command
s due to the monolithic nature of the Windows IDE device driver. Note the CDB's captured have a one to one relationship with ATA
command
s and can be easily translated to their native ATA equivalent. Also note the data captured with the CDB is identical to the ATA data transfer.
12. Where can I get more detailed information on the captured data?
For your convenience, please visit www.perisoft.net/engineer for handy reference data and specifications. Also please note the following resources:
Specification Location
USB www.usb.org
SCSI www.t10.org
IDE, ATA, ATAPI www.t13.org
1394, Firewire www.1394ta.org or www.ieee.org
Windows DDK www.microsoft.com/ddk
14. Where do I get support?
Visit www.perisoft.net. Any questions, comments, or problem reports on the free or full version are welcome.
Bus
Hound
详解
1、简介
Bus
Hound
是一个超级软件总线协议分析器,用于捕捉来自设备的协议包和输入输出操作 2、详解 1)Setting:参数设置 Buffer Size(缓冲区大小)用于捕获数据缓冲区的RAM大小,以K为单位,设置上限仅受系统内存限制,如果出现内存不够,缓冲区尺寸将缩减到可用RAM的大小 Max Phase(最大阶段)指定每阶段捕获数据的最大数量 Stop When…(停止条件) 用...
【开发工具】【
Bus
Hound
】USB抓包工具(
Bus
Hound
)的使用
获取更多相关的嵌入式开发工具,可收藏系列博文,持续更新中:【开发工具】嵌入式常用开发工具汇总帖 目录
Bus
Hound
概述
Bus
Hound
使用说明 settings设置 - 设置捕捉的内容 Device设置 - 设置捕捉的设备 Capture设置 - 开始捕捉数据 Save - 导出捕捉的数据
Bus
Hound
概述
Bus
Hound
是一个超级软件总线协议分析器,用于捕捉来自设备的协议包和输入输出操作。该软件是由美国perisoft公司研制的一种专用于PC机各种总线数据包监视和控
【bug】页面显示
Invalid
command
,端口占用
1,前言 当我启动项目的
时
候,因为项目是分模块的,其他几个模块都能正常进入并显示, 但是【1模块】点进去就会出现如下页面 2,经过测试, 前端1+后端1 【1模块】页面正常显示 前端1+我后端 【1模块】页面正常显示 我前端+我后端 【1模块】
Invalid
command
所以应该与代码无关,与环境有关,然后百度 大概就是端口冲造成的 3,这里给出两个解决方案 方案一:【1模块】换一个端口 方案二:释放被占用的端口 4,方案二具体操作: 4.1 查看前端定位的【1模块】的访问路径端口
Bus
Hound
详细使用说明
Bus
Hound
不同功能界面通过上面一排按钮进行选择 一、Capture 数据抓取界面 数据抓取界面就是用来显示抓取了数据的界面,这个界面本身需要说明的东西不多,但是其它界面跟数据抓取界面相关的内容比较多,所以介绍的过程中如果有涉及到的,就一并介绍了。 1. 数据标签栏 数据标签栏即为上图红框中的内容,用来说明这一列数据的作用。这个标签可以进行设置,可以增加说明项或删减说明项,设置的位置是在Settings界面下方。 说明一下各个选项的内容: (1) Devi...
驱动开发/核心开发
21,597
社区成员
21,709
社区内容
发帖
与我相关
我的任务
驱动开发/核心开发
硬件/嵌入开发 驱动开发/核心开发
复制链接
扫一扫
分享
社区描述
硬件/嵌入开发 驱动开发/核心开发
社区管理员
加入社区
获取链接或二维码
近7日
近30日
至今
加载中
查看更多榜单
社区公告
暂无公告
试试用AI创作助手写篇文章吧
+ 用AI写文章