ContentsIndex
Functions
Functions | Legend
Functions
Function 
Description 
If want to listen to multiple events, then use vm_dcl_register_callback() first to register the callback and use vm_dcl_add_event() to add additional events you want the callback to listen to. 
Closes the device, as specified by the device_handle. After the device operation completes, this function should be invoked to close the device. If the device operation involves a callback, the device should not be closed before the callback finishes. 
Sets the pin mode. 
Sends command to control the device, after the device is opened successfully by vm_dcl_open(). The command specifies what to do and the argument specifies the information needed for controlling the device by the device driver. The specific command is defined in the header file of the device driver.
The device_handle, command and argument should correlate, so that the desired operation command is sent to the desired device. The execution of vm_dcl_control() can be either synchronously or asynchronously, depending on the command and the targeted device. Refer to the command description in the specific driver documentation. 
Gets the identifier of the user. Some device may need this. Most of the time the return value of this function needs to be passed to the driver when the device do asynchronous operations. 
Opens the device. Every device must be opened with this function before it can be used. The device number passed to this function is defined in the header file of the device driver. The returned handle is the identifier of the device. The device handle is used to access the device by the other functions. 
Reads data from the device. This function may not applicable to the devices that do not transfer data. Some devices may also use vm_dcl_control() to transfer data, such as SPI. 
Registers a callback to listen to the events from a device specified by the device_handle. The callback enables an asynchronous operation between the application and the device. 
Writes data to the device. This function may not applicable to the devices that do not transfer data. Refer to the specific device driver document for details. Some devices may also use vm_dcl_control() to transfer data, such as SPI. 
Used in AP mode, it masks the I bit of the processor. This function must be used in pair with the vm_irq_restore(). The I bit mask time should not exceed 5ms. 
Used in AP mode, it restores the I bit of the processor. This function must be used in pair with vm_irq_mask(). 
Created with a commercial version of Doc-O-Matic. In order to make this message disappear you need to register this software. If you have problems registering this software please contact us at support@toolsfactory.com.