PORTS Forum

Ports and Interfaces => USB => Topic started by: Stephane on March 21, 2013, 04:00:07 am

Title: Programming the USB device with the mpusbapi.dll
Post by: Stephane on March 21, 2013, 04:00:07 am
Hi all,

I have an few question for building an PowerBasic application for read and write data from the USB port with the mpusbapi.dll.

1) Wat are the important programming steps for using this mpusbapi.dll?.

2) Can someone help me how I can written my first program to control the mpusbapi.dll?

Kind regards
Stephane
Title: Re: Programming the USB device with the mpusbapi.dll
Post by: Tsuneo on March 21, 2013, 08:25:27 am
I don't recommend mpusbapi.dll for new design. Instead, apply WinUSB.dll directly.

As Microchip wrote in their announcement (*1), current version of mpusbapi.dll is a wrapper DLL over WinUSB.dll. They provide this DLL for painless migration from former versions, when they have decided to deprecate their custom PC driver, mchpusb(64).sys, and moved to WinUSB. If you would have many examples on mpusbapi.dll to start with, you might have good reason to use this DLL.

Jan has an excellent VB example for WinUSB on her WinUSB page.
http://www.lvr.com/winusb.htm

(*1) Microchip Libraries for Applications
http://www.microchip.com/stellent/idcplg?IdcService=SS_GET_PAGE&nodeId=2680&dDocName=en547784
C:\microchip_solutions_v2013-02-15\USB\Tools\MCHPUSB Custom Driver\Mpusbapi\README for MPUSBAPI 6.0.0.0.htm

Tsuneo