Re: seek for help on Libusb & STM32

Pradeepa Senanayake <[email protected]>
Newsgroups gmane.comp.lib.libusb.devel.windows
Message-ID <CA+1tQ722OiOcphsG5YCTsCMPGk_wPyuveiGkn0iOth8zcwcd9w@mail.gmail.com>
Best regards,
Pradeepa Senanayake.
On Mar 10, 2014 9:00 AM, "Pradeepa Senanayake" <[email protected]>
wrote:

> Hello Duan,
>
> Since the firmware you use is for a VCP it will be enumerated within the
> PC side as a COM port. In that case you can directly use serial writing
> methods to access the device. I don't think that you need libusb in that
> case. But if you wan't to have lets say a Vendor Specific class with your
> own descriptors (ie. Endpoint types, etc. ) then LibUSB will come in handy.
>
> For your application, if COM port is enough, I would recommend using
> methods to access COM port rather than using LibUSB. Do a google search
> with keywords such as " Writing to a COM port using visual studio" and you
> will get plenty of hits.
>
>
> >>   I  learned  you had done similar works from here
> >> https://sourceforge.net/p/libusb-win32/mailman/libusb-win32-devel/thread/CA+1tQ71CeMubpzV2rBHPnWQ5Zcnihx1e>>>>
>   [email protected]/<https://sourceforge.net/p/libusb-win32/mailman/libusb-win32-devel/thread/CA+1tQ71CeMubpzV2rBHPnWQ5Zcnihx1e24_1wqFHicofGqsi0Q@mail.gmail.com/>
>
> In the above link, he is not using VCP. That is why it is easier to use
> LibUSB. I'm just a LibUSB user (not a developer) so the devs will correct
> me if I am wrong.
>
> Please refer to this discussion,
>
> http://sourceforge.net/p/libusb-win32/mailman/message/31338949/
>
> it will hopefully clear most of the doubts.
>
> Hope I helped.
>
> Thank you,
>
>
>
> Best Regards,
> Pradeepa Senanayake.
>
>
> On Sun, Mar 9, 2014 at 2:22 PM, Duan Xiudong <[email protected]> wrote:
>
>> Hello   Pradeepa,
>>
>>      I am a student form China. I'm trying to get some data  using USB
>>  from a board based on STM32F4xx chips. Right now I'm trying it on  a
>> STM32F4discovery  board.
>>
>>     On  the  device side,  I  implement a  Virtual COM Port project form
>> ST firmware.It can work well as a COM port with PC.
>>
>>     And now I download  libusb-win32-1.2.6 , generate and install the
>> drivers (INF file) as  it requires. Then I  test  it on VS  using the
>> example code from the official  website. It seems  that PC can get the
>> configuration information correctly,  but can not execute  any bulk_read
>> operation. When it runs to * usb_bulk_read()* or *usb_submit_async()*
>> function, the program ends with error.
>>
>>     I  don't  know where the problem is.  Is there any problem  on PC
>> side codes?  OR something  wrong  with device firmware? It puzzled me a lot.
>>
>>        I  learned  you had done similar works from here
>>
>> https://sourceforge.net/p/libusb-win32/mailman/libusb-win32-devel/thread/CA+1tQ71CeMubpzV2rBHPnWQ5Zcnihx1e24_1wqFHicofGqsi0Q@mail.gmail.com/
>>
>>       I hope you can give me some instructions. If you're kindly  to
>> offer some help, I will give more details.
>>       Thank you very much!  Hope  for  your  reply.
>>
>> --
>> Daniel
>>
>
>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech

_______________________________________________
Libusb-win32-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/libusb-win32-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.