Author Topic: Do I have complete USB Host Codebase to extract bulk video from USB Device?  (Read 9617 times)

jani12

  • Member
  • ***
  • Posts: 10
I used open source Packet Capture(Pcap) and Wireshark to view video sent by USB Device.  The device sends 512 Bytes packet about every 200 us.  It's a composite device class.  It's a virtual port and bulk video.  Each monochrome raw frame is 640 x 480.

There is a GUI tool that run in windows that extracts video from this USB device and plays video on the PC.  The company who wrote this GUI tool gave us the source code.  I opened this source code into Visual Studio 2017 Professional version without creating a solution or project.  There are Sixteen projects in this codebase.

There are Two main folders.  They both seem to contain library code.  Their description is as follows:
First Folder -  includes information about bulk processing, command processing, port processing, script processing, and USB header information.
Second Folder name is Video - Library files that contain code on a frame viewer and how to stream video through USB, as well as capturing images off the device.

This code is in C Sharp.  Does this appear to be complete codebase for extracting video frames from USB device?  If yes, how to tell if this code will build and run without any changes?


Jan Axelson

  • Administrator
  • Frequent Contributor
  • *****
  • Posts: 3033
    • Lakeview Research
I think the only way to find out is to try it.

jani12

  • Member
  • ***
  • Posts: 10
I tried and was able to build all the libraries.

My goal is to extract USB Video Stream from the device.  Besides these libraries, do I need additional code in order to extract video data from the device?  I mean do I need
to write application above the libraries?

Currently, I don't have a visual studio project?  The libraries are in Solution Explorer - Folder View.

Do I need to create a C# project that includes these provided libraries and application code that I write above the librariers?

What type of project do I need to create?  Console App or some type of Windows Application?

Jan Axelson

  • Administrator
  • Frequent Contributor
  • *****
  • Posts: 3033
    • Lakeview Research
Yes, create a project. I would do a Windows application but a console app would likely work also.