# WM_DisconnectChildren

## C Specification

      #include <nitro/wm.h>

      WMErrCode WM_DisconnectChildren(
              WMCallbackFunc  callback ,
              u16             aidBitmap );

## Description

When a device is active as the parent device, this function disconnects all the established child devices of the designated connection. Since the bits of the child devices with no established connection are ignored, by designating `0xFFFF` inside the bit displayed in `aidBitmap`, all connected child devices can be disconnected.

This function can be executed only when the WM is in either the `PARENT` or `MP_PARENT` state.

When the return value of the API is `WM_ERRCODE_OPERATING`, a callback will occur after the disconnect process is complete. After the process has completed, only the connection with the designated child device is disconnected. The remaining devices will remain connected.

## Arguments

callback | The callback function called when the asynchronous processing has completed
aidBitmap | The AID bit field of the child device to be disconnected. The lowest bit is ignored, and bits 1-15 are each displayed on the AID 1-15 child devices.

## Return Values

Returns the process result as a `WMErrCode` enumerated type.

## See Also

`WM_StartParent`, `WM_Disconnect`

## Revision History

10/22/2004 Changed return value types
08/20/2004 Initial version