Tag Archives: USB

error RC2247 : SYMBOL name too long [How to Solve]

An error was reported in compiling usbview today…

error RC2247 : SYMBOL name too long

Therefore, you only need to add it in front of the original usbview.rc


#define APSTUDIO_HIDDEN_SYMBOLS
#include "windows.h"
#include "prsht.h"
#include "wtypes.h"
#undef APSTUDIO_HIDDEN_SYMBOLS

Then it’s OK
later, use the resource editor provided by vs to change the location and update the resource content again

In this case, the modified full usview.rc content is provided:

#define APSTUDIO_HIDDEN_SYMBOLS
#include "windows.h"
#include "prsht.h"
#include "wtypes.h"
#undef APSTUDIO_HIDDEN_SYMBOLS


#include <windows.h>
#include <commctrl.h>
#include "resource.h"



//#if WINNT
//#include <ntverp.h>
//#else
//#include <version.h>
//#endif


//
//
// VERSION
//
#define VER_FILEDESCRIPTION_STR     "Microsoft\256 Windows(TM) USB Device Viewer"
#define VER_INTERNALNAME_STR        "USBVIEW"
#define VER_ORIGINALFILENAME_STR    "USBVIEW.EXE"
#define VER_LEGALCOPYRIGHT_STR      "Copyright \251 Microsoft Corporation 1996-2008.  All Rights Reserved."

#define VER_FILETYPE     VFT_APP
#define VER_FILESUBTYPE  VFT2_UNKNOWN

//#include <common.ver>


//
//
// ICON
//
IDI_ICON                ICON    DISCARDABLE     "USB.ICO"
IDI_BADICON				ICON	DISCARDABLE		"BANG.ICO"
IDI_COMPUTER			ICON	DISCARDABLE		"MONITOR.ICO"
IDI_HUB					ICON	DISCARDABLE		"HUB.ICO"
IDI_NODEVICE			ICON	DISCARDABLE		"PORT.ICO"

//
//
// Cursor
//
IDC_SPLIT               CURSOR  DISCARDABLE     "SPLIT.CUR"

/
//
// Dialog
//

IDD_MAINDIALOG DIALOGEX 0, 0, 640, 350
STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU | 
    WS_THICKFRAME
CAPTION "USB View"
MENU IDR_MENU
FONT 8, "MS Shell Dlg"
BEGIN
    CONTROL         "Tree1",IDC_TREE,"SysTreeView32",TVS_HASBUTTONS | 
                    TVS_HASLINES | TVS_LINESATROOT | WS_BORDER | WS_TABSTOP,
                    0,0,400,341,WS_EX_CLIENTEDGE
    EDITTEXT        IDC_EDIT,400,0,240,341,ES_MULTILINE | ES_READONLY | 
                    WS_VSCROLL | WS_HSCROLL
    CONTROL         "Devices Connected: 0",IDC_STATUS,"msctls_statusbar32",
                    SBARS_SIZEGRIP,
                    0,342,640,8
END


IDD_ABOUT DIALOG DISCARDABLE  0, 0, 212, 82
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "About USBView"
FONT 8, "MS Shell Dlg"
BEGIN
    DEFPUSHBUTTON   "OK",IDOK,80,62,50,14
    LTEXT           "USB Device Viewer",IDC_STATIC,54,15,64,8
    LTEXT           "Copyright (c) 1996-2008 Microsoft Corporation",
                    IDC_STATIC,54,30,145,8
#ifndef WINNT
    LTEXT           "Version",IDC_STATIC,55,45,24,8
    LTEXT           VER_PRODUCTVERSION_STR,IDC_STATIC,87,45,33,8
#endif
    ICON            IDI_ICON,IDC_STATIC,15,15,21,20
END


/
//
// Menu
//

IDR_MENU MENU DISCARDABLE 
BEGIN
    POPUP "&File"
    BEGIN
        MENUITEM "&Refresh\tF5",                ID_REFRESH
        MENUITEM SEPARATOR
        MENUITEM "E&xit",                       ID_EXIT
    END
    POPUP "&Options"
    BEGIN
        MENUITEM "&Auto Refresh",               ID_AUTO_REFRESH
        MENUITEM "&Config Descriptors",         ID_CONFIG_DESCRIPTORS
    END
    POPUP "&Help"
    BEGIN
        MENUITEM "&About",                      ID_ABOUT
    END
END

//
//
// Accelerator
//

IDACCEL ACCELERATORS DISCARDABLE 
BEGIN
    VK_F5,          ID_REFRESH,             VIRTKEY,NOINVERT
END

Content of resource.H:

/*++
Copyright (c) 1998 Microsoft Corporation, All Rights Reserved.
--*/

#define IDD_MAINDIALOG                  101
#define IDR_MENU                        102
#define IDD_ABOUT                       103
#define IDI_ICON                        104
#define IDC_SPLIT                       105
#define IDACCEL                         106

// added ScottT
#define IDI_BADICON                     107
#define IDI_COMPUTER                    108
#define IDI_HUB                         109
#define IDI_NODEVICE                    110

#define IDC_TREE                        1000
#define IDC_EDIT                        1001
#define IDC_STATUS                      1002
#define ID_EXIT                         40001
#define ID_REFRESH                      40002
#define ID_AUTO_REFRESH                 40003
#define ID_CONFIG_DESCRIPTORS           40004
#define ID_ABOUT                        40005
#define IDC_STATIC                      0xFFFFFFFF


#define VER_PRODUCTVERSION_STR			"ubzh.com"

Introduction to total phase data center

Have a Beagle ™ 480 USB Protocol Analyzer Protocol analysis tool
(https://www.totalphase.com/media/datasheet/TP_Beagle_USB_480_Protocol_Analyzer-Datasheet.pdf), you can grab the data on the USB bus. Data Center Software can be used to capture and analyze Data on the USB bus.
Software Download address
https://www.totalphase.com/products/data-center/
according to the need to choose which one to download. This software does not require installation and can be opened directly.

USB Drive Download
Windows:https://www.totalphase.com/products/usb-drivers-windows/
Linux:https://www.totalphase.com/products/usb-drivers-linux/
The USB driver under Linux is based on Libusb, so there is no need to install, just copy the extracted 99-totalphase rules to /etc/udev/rules.d/ directory and update the udev rules.

	For all products, the Linux driver is based on libusb and there is no need to install 
	any other drivers on the operating 	system. For information on access permissions,
	refer to the datasheets and the hotplug or udev infrastructure under Linux.

Use of Data Center software
There is a doc/ directory in the directory of the software, which contains the usage instructions of Beagle, Datacenter and Komodo.

Beagle. PDF contains knowledge points related to USB protocol, I2C protocol and SPI protocol;
datacenter. PDF on the use of Data Center software, including capture, filter, trigger, etc.;
komodo. PDF looks like it is about usb-to-can.
For example, if we want to see the enumeration process, we can quickly filter the data of other endpoints. If we Only want to keep the data of Endpoint 0, right click on the data panel to display the fast filtering option, in this case Show Only Endpoint. Of course, if you don’t want to Filter anything, click Disable Filter.

More importantly, if we know that an endpoint is transmitting audio files, we can display data for that endpoint only, filter out other endpoints, and finally File -> Export exports the data to a specific format, and the audio file is ready to play.

While fetching, there are always things that seem to be orphded-nanded-and SPLIT, as follows:

In the article below about the SPLIT and ORPHANED details:
https://www.totalphase.com/blog/2015/03/causes-split-orphaned-packets-beagle-usb-480-protocol-analyzer-captures-detects/
In summary:
SPLIT transfers are used by hosts to communicate with full-/low-speed devices through a high-speed hub. These transfers will have at least a Start SPLIT, and may include polling and handshaking as well.Orphaned packets can occur when a device is connected through a path that does not pass through the Beagle analyzer.
That is, at the time of the grab, there is another low-speed or full-speed device communicating on the USB bus, so SPILIT’s transfer occurs. Such warnings are perfectly normal. To get them out, I filtered the following in the LiveFilter panel:

Windows Realtek USB wireless network card boot failure Rtlihvs. DLL module stop problem

June 4, 2020 Update:
Another reason was found that the USB wireless network card of the chip could not be connected to the USB interface of the monitor (USB interface is provided on the AOC monitor of the blogger).
It is speculated that the network card device could not be successfully initialized due to insufficient power supply of THE USB interface on the display when the system started. In this case, the network card can only be directly inserted into the host computer.
Or buy a separate USB extension cord and place it on the desktop (it may cause signal problems if some partners plug it into the host).


Problem description
After booting up, the wireless network card does not start successfully. When entering the device manager, you can see that the network card is marked as warning. The device can be successfully activated and used by disabling and enabling the device.
The log
In the Windows system log, we can see a warning log with the event ID of 10002, which is described as follows:

WLAN Extensibility Module has stopped.

Module Path: C:\WINDOWS\system32\Rtlihvs.dll

Analysis of the
Preliminary analysis indicates that the component version is too low (the current system is Windows 10) or the driver version is too low. Through the replacement of various versions of the driver can not solve the problem. Hence Google…
To solve
Reference: WLAN Extensibility Module has failed to start-up – Microsoft Community
The solution steps are as follows:

    Win + R open regedit registry editor; Expand and locate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\ Class\{4d36e972-e325-11ce-bfc1-08002be10318}; There are several items beginning with 00, and the sub-items Ndi are searched in turn for the presence of IHVExtensions. Its contents are roughly as follows:

    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\{4d36e972-e325-11ce-bfc1-08002be10318}\0008\Ndi\IHVExtensions]
    "ExtensibilityDLL"="%SystemRoot%\\system32\\Rtlihvs.dll"
    "UIExtensibilityCLSID"="{6C2A8CCA-B2A2-4d81-A3B2-4E15F445C312}"
    "GroupName"="Realtek CCX SDK IHV Service"
    "AdapterOUI"=dword:0000e04c
    

    After confirmation, right-click IHVExtensions and select export and backup to any place. Delete IHVExtensions, restart the system and confirm, Fixed!

Ubuntu cannot access USB device, failed to create a proxy device for the USB device

Ubuntu cannot access the USB device, Failed to create a proxy device for the USB device

method one: trying to install VirtualBox Extension Pack, address: https://www.virtualbox.org/wiki/Downloads. The WARNING in USB setting will disappear. Also: All warnings of Virtual Box should be alert and try to handle, or the OS inside the sandbox will be buggy.


method failed, try: https://superuser.com/questions/1136607/virtualbox-usb-capture-issue-windows-7-host-guest