Sending data from RAM to USB
#16
(01-27-2016, 04:35 PM)admin Wrote: I have never used the command to get the queue status, but it is possible that it only returns the amount in the queue (which could be full).

I would use the FT_Read (that's what I use).

Are you doing this in PureBasic?  If so, how are you opening the FTDXXXX.dll?  I downloaded PureBasic and I am interested in writing some sample code for SCP so that it can be used under Windows, Mac, and Linux.

First you need to open the dll:

Code:
hndFTDLL = OpenLibrary(#PB_Any, GetFolderPath(#CSIDL_SYSTEM) + "\ftd2xx.dll")
if hndFTDLL = 0
  ; Error loading 'ftd2xx.dll'
  End
EndIf

You can then call the functions using something like:


Code:
CallFunction(hndFTDLL, "FT_Read", ftHandle, @Buffer, BytesToRead, @BytesReturned)

All this is explained in more detail in the online PureBasic manual.

If I remember right, the demo version of PureBasic is quite restrictive in what you can do with it, so the above may not work if it is just the demo version you have.

Kind regards,

Francis
Dreamland Fantasy Studios
http://www.dfstudios.co.uk
Reply


Messages In This Thread
Sending data from RAM to USB - by dfstudios - 01-18-2016, 02:41 PM
RE: Sending data from RAM to USB - by admin - 01-18-2016, 03:04 PM
RE: Sending data from RAM to USB - by dfstudios - 01-18-2016, 04:18 PM
RE: Sending data from RAM to USB - by admin - 01-18-2016, 09:54 PM
RE: Sending data from RAM to USB - by dfstudios - 01-19-2016, 02:31 PM
RE: Sending data from RAM to USB - by admin - 01-19-2016, 08:32 PM
RE: Sending data from RAM to USB - by dfstudios - 01-27-2016, 01:59 PM
RE: Sending data from RAM to USB - by admin - 01-27-2016, 02:45 PM
RE: Sending data from RAM to USB - by dfstudios - 01-27-2016, 03:23 PM
RE: Sending data from RAM to USB - by admin - 01-27-2016, 04:30 PM
RE: Sending data from RAM to USB - by dfstudios - 01-27-2016, 04:36 PM
RE: Sending data from RAM to USB - by dfstudios - 01-27-2016, 04:31 PM
RE: Sending data from RAM to USB - by admin - 01-27-2016, 04:35 PM
RE: Sending data from RAM to USB - by dfstudios - 01-27-2016, 04:47 PM
RE: Sending data from RAM to USB - by admin - 01-27-2016, 04:41 PM
RE: Sending data from RAM to USB - by dfstudios - 01-27-2016, 04:50 PM
RE: Sending data from RAM to USB - by admin - 01-27-2016, 04:44 PM
RE: Sending data from RAM to USB - by dfstudios - 01-27-2016, 04:52 PM
RE: Sending data from RAM to USB - by admin - 01-27-2016, 05:02 PM
RE: Sending data from RAM to USB - by admin - 01-27-2016, 05:04 PM
RE: Sending data from RAM to USB - by dfstudios - 01-27-2016, 05:36 PM



Users browsing this thread: 1 Guest(s)