The stream-open function

Your stream-open function must take the following steps:
  1. Accept as its arguments the type-specific initialization information and use them to open the data.
  2. Call mi_stream_init() with appropriate information to initialize an MI_STREAM structure (see DataBlade API data type structures).
The stream-open function must prepare the arguments for the call to the mi_stream_init() function, which initializes and optionally allocates an MI_STREAM structure. The mi_stream_init() function takes the following arguments:
  • The stream-operations structure
  • The stream data
  • A stream descriptor