Im trying to create an S-function which will read/capture data from hardware in a system, which will then be used in a Simulink model. The hardware drivers and hardware API makes use of ".dll" files. Is it possible to include/use these .dll files in a Simulink s-function so that the functions within can be used in the C MEX S-function?? If so will you be able to give an example or directions? All attempts so far has led to syntax errors or the following: error LNK2019: unresolved external symbol __imp__fntest_dll referenced in function _doubleIt test.mexw32 : fatal error LNK1120: 1 unresolved externals Thank U Jeffrey