MATLAB XPC TARGET 4 - DEVICE DRIVERS User's Guide Page 78

  • Download
  • Add to my manuals
  • Print
  • Page
    / 111
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 77
7 Creating Custom Drivers Using the xPC Target™ D river Authoring Tool
xPC Tar get Driver Authoring Tool
xPC Target Driver Authoring Tool helps you create templates for simple
custom device drivers. A simple custom device driver is one that does not
perform DMA or interrupt processing. The xPC Target Driver Authoring Tool
is not useful for thes e more complicated applications.
Based o n the inputs you p rovide to xPC Target Driver Authoring Tool, it can
create a number o f files, including the following. Of these files, you need to edit
only the source C code file. You can also optionally edit the block mask file.
File
Description
driver_name.c
Template for the source C co de for driver. You
need to enter your C code.
driver_name.h
Header file for driver.
sfcn_driver_name.c
S-function file for driver. This file contains
S-function callback methods and options for
the driver.
sfcn_dr
iver_name.tlc
Optiona
l. Real-Time Workshop TLC code
generat
ion file. You ty pically need a
.tlc file
only if
youwanttoinlineyourcustomdriver.
See “In
lining xPC Target Drivers” on page
1-10 for f
urther information. The xPC Target
Drive
r Authoring Tool creates this file for you
wheth
er or not you want to inline the driver.
driv
er_block_name.mdl
Optio
nal. Blockmaskmodelfilefordriver.
Afte
r the xPC Target Driver Authoring Tool
crea
tes the supporting files, it creates the
bloc
kmaskforthedriveranddisplaysitinthe
Simu
link model window. The tool creates this
fil
eonlyifyouselecttheMEX C file check
box
.
sfcn_driver_-
name.mexw32
Optional. If you requested the creation of a C
MEX file, the tool g enerates one for you.
7-2
Page view 77
1 2 ... 73 74 75 76 77 78 79 80 81 82 83 ... 110 111

Comments to this Manuals

No comments