MBS Plugin Documentation
Statistics - FAQ - Plugin Parts (All, Dependencies) - Class hierarchie
New in Version 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 9.0
The list of the themes, classes, controls, modules, global methods by category, global methods by name, screenshots, licenses and examples.
Platforms to show: All Mac Windows Linux Cross-Platform
class MacHIDMBS
class, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: A class to work with HID devices on Mac OS X.
class, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: A class to work with HID devices on Mac OS X.
MacHIDMBS.Close
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Closes the active connection.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Closes the active connection.
MacHIDMBS.Connect
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Creates a connection to the current device.
Example:
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Creates a connection to the current device.
Example:
Function OpenUSBDevice() As boolean
dim i as integer
h=FindDevice // see FindFirst example
if h=nil then
MsgBox "No XYZ device found."
Return false
end if
h.Connect
if h.Lasterror<>0 then
MsgBox "Failed to connect to USB Device."
Return false
end if
h.InstallCallback
Return true
End Function
Notes: Lasterror is set.MacHIDMBS.DeviceRemoved(result as integer)
event, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Plugin version: 8.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The event called whenever the device is removed.
Notes: You need to call connect to install the callback which raises this event.
event, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Plugin version: 8.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The event called whenever the device is removed.
Notes: You need to call connect to install the callback which raises this event.
MacHIDMBS.Disconnect
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Disconnets current USB device.
Notes: Lasterror is set.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Disconnets current USB device.
Notes: Lasterror is set.
MacHIDMBS.FindFirstDevice as boolean
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Finds the first device and loads the properties.
Example:
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Finds the first device and loads the properties.
Example:
Function FindDevice() As MyHID
dim h as MyHID
dim p as string
h=new MyHID // your own subclass of MacHIDMBS so you can get events
if h.FindFirstDevice then
p=h.Product
if p="MyProduct" then
Return h
end if
while h.FindNextDevice
p=h.Product
if p="MyProduct" then
Return h
end if
wend
end if
End Function
Notes: Returns true on success and false on failure.MacHIDMBS.FindNextDevice as boolean
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Finds next device.
Notes: Returns true on success and false on failure.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Finds next device.
Notes: Returns true on success and false on failure.
MacHIDMBS.InstallCallback
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Installs the callback used for the event handler.
Notes:
Lasterror is set.
Please use after connect.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Installs the callback used for the event handler.
Notes:
Lasterror is set.
Please use after connect.
MacHIDMBS.Lasterror as Integer
property, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Last error code.
Notes:
0 is success.
-1 means that the function is not available.
else Mac OS USB error codes.
error -536854447 is an USB timeout.
(Read and Write property)
property, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Last error code.
Notes:
0 is success.
-1 means that the function is not available.
else Mac OS USB error codes.
error -536854447 is an USB timeout.
(Read and Write property)
MacHIDMBS.Manufacturer as string
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The manufacturer name.
Notes: On any error an empty string is returned.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The manufacturer name.
Notes: On any error an empty string is returned.
MacHIDMBS.Product as string
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The product string of the selected device.
Notes: Lasterror is set.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The product string of the selected device.
Notes: Lasterror is set.
MacHIDMBS.ProductID as integer
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The product ID of the selected device.
Notes: Lasterror is set.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The product ID of the selected device.
Notes: Lasterror is set.
MacHIDMBS.ReadMessage(length as integer) as string
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Reads a message from the device.
Notes:
Length is the length of the receive buffer you want to use.
With Mac OS X 10.4 this function seems to not always work correct so using the event seems better.
The string returned is 0 to length bytes long.
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
Internally ReportID=0 is used.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Reads a message from the device.
Notes:
Length is the length of the receive buffer you want to use.
With Mac OS X 10.4 this function seems to not always work correct so using the event seems better.
The string returned is 0 to length bytes long.
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
Internally ReportID=0 is used.
MacHIDMBS.ReadMessage(ReportID as integer, length as integer) as string
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 8.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Reads a message from the device.
Notes:
Length is the length of the receive buffer you want to use.
With Mac OS X 10.4 this function seems to not always work correct so using the event seems better.
The string returned is 0 to length bytes long.
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 8.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Reads a message from the device.
Notes:
Length is the length of the receive buffer you want to use.
With Mac OS X 10.4 this function seems to not always work correct so using the event seems better.
The string returned is 0 to length bytes long.
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
MacHIDMBS.ReadMessageMemory(length as integer) as memoryblock
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Reads a message from the device.
Notes:
Length is the length of the receive buffer you want to use.
With Mac OS X 10.4 this function seems to not always work correct so using the event seems better.
The memoryblock returned has a size of 0 to length bytes.
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
Internally ReportID=0 is used.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Reads a message from the device.
Notes:
Length is the length of the receive buffer you want to use.
With Mac OS X 10.4 this function seems to not always work correct so using the event seems better.
The memoryblock returned has a size of 0 to length bytes.
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
Internally ReportID=0 is used.
MacHIDMBS.ReadMessageMemory(ReportID as integer, length as integer) as memoryblock
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 8.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Reads a message from the device.
Notes:
Length is the length of the receive buffer you want to use.
With Mac OS X 10.4 this function seems to not always work correct so using the event seems better.
The memoryblock returned has a size of 0 to length bytes.
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 8.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Reads a message from the device.
Notes:
Length is the length of the receive buffer you want to use.
With Mac OS X 10.4 this function seems to not always work correct so using the event seems better.
The memoryblock returned has a size of 0 to length bytes.
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
MacHIDMBS.ReceivedData(data as string, size as integer)
event, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Data was received and is available for processing.
Example:
event, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Data was received and is available for processing.
Example:
Sub ReceivedData(data as string, size as integer)
dim m as MemoryBlock
dim s as string
dim n,i as integer
// Debug Output data received:
m=data
n=lenb(data)-1
for i=0 to n
s=s+str(m.Byte(i))+" "
next
s=s+"= "+data
System.DebugLog s
End Sub
Notes: Event is only called when InstallCallback was used and a connection is open.MacHIDMBS.SendMessage(data as string)
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Sends a message to the USB device.
Notes:
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Sends a message to the USB device.
Notes:
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
MacHIDMBS.SendMessage(ReportID as integer, data as string)
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 8.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Sends a message to the USB device.
Notes:
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 8.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Sends a message to the USB device.
Notes:
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
MacHIDMBS.SendMessageMemory(data as memoryblock, offset as integer, length as integer)
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Sends a message to the USB device.
Notes:
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
Internally ReportID=0 is used.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Sends a message to the USB device.
Notes:
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
Internally ReportID=0 is used.
MacHIDMBS.SendMessageMemory(ReportID as integer, data as memoryblock, offset as integer, length as integer)
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 8.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Sends a message to the USB device.
Notes:
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 8.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Sends a message to the USB device.
Notes:
A connection must be open.
Lasterror is set. Lasterror -536854447 is an USB timeout.
MacHIDMBS.SerialNumber as string
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The serial number of the current selected device.
Notes: Lasterror is set.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The serial number of the current selected device.
Notes: Lasterror is set.
MacHIDMBS.TimeOut as Integer
property, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Timeout value to use for sending/reading USB data.
Notes: (Read and Write property)
property, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Timeout value to use for sending/reading USB data.
Notes: (Read and Write property)
MacHIDMBS.VendorID as integer
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The vendor ID of the selected device.
Notes: Lasterror is set.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 6.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The vendor ID of the selected device.
Notes: Lasterror is set.
MacHIDMBS.VersionNumber as integer
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The device specific version number.
Notes:
Value can be anything.
On any error, 0 is returned.
method, HID, MBS USB Plugin (MacHID), class MacHIDMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The device specific version number.
Notes:
Value can be anything.
On any error, 0 is returned.
The items on this page are in the following plugins: MBS USB Plugin.
Monkeybread Software Realbasic Plugins - Christians Software