IMbnDeviceService::SetCommand method

Sends a SET control command to the device service of a Mobile Broadband device.

Syntax


HRESULT SetCommand(
  [in]   ULONG commandID,
  [in]   SAFEARRAY(BYTE) deviceServiceData,
  [out]  ULONG *requestID
);

Parameters

commandID [in]

An identifier for the command.

deviceServiceData [in]

A byte array that is passed in to the device.

requestID [out]

A unique request ID assigned by the Mobile Broadband service to identify this request.

Return value

The method can return one of the following values.

Return codeDescription
S_OK

The method completed successfully.

E_ACCESSDENIED

This device service command is not allowed for calling process privileges.

Other

An error was encountered when executing this method.

 

Remarks

SetCommand exists to implement vendor-specific device service functionality which is not otherwise covered in the Mobile Broadband API. A command session on a device service must be opened before the application can call SetCommand.

The Mobile Broadband service will issue a SET request to the device. deviceServiceData will be copied byte-by-byte into the data buffer passed in to the request. This data buffer must be less than MaxCommandSize bytes.

This is an asynchronous operation and SetCommand will return immediately. On completion of the operation, the Mobile Broadband service will call the OnSetCommandComplete method of the IMbnDeviceServicesEvents interface.

Requirements

Minimum supported client

Windows 8 [desktop apps | Windows Store apps]

Minimum supported server

None supported [desktop apps | Windows Store apps]

IDL

Mbnapi.idl

See also

IMbnDeviceService

 

 

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.