PIP Module
2-268
Note:
When DSP/BIOS starts up, it calls the notifyWriter function internally for
each created pipe object to initiate the pipe’s I/O.
The code that calls PIP_free or PIP_put should preserve any necessary
registers.
Often one end of a pipe is controlled by an HWI and the other end is
controlled by a SWI function, such as SWI_andnHook.
HST objects use PIP objects internally for I/O between the host and the
target. Your program only needs to act as the reader or the writer when
you use an HST object, because the host controls the other end of the
pipe.
Pipes can also be used to transfer data within the program between two
application threads.
PIP Manager
Properties
The pipe manager manages objects that allow the efficient transfer of
frames of data between a single reader and a single writer. This transfer
is often between an HWI and a SWI, but pipes can also be used to
transfer data between two application threads.
The following global property can be set for the PIP module in the PIP
Manager Properties dialog of the DSP/BIOS Configuration Tool or in a
Tconf script:
❏
Object Memory
. The memory segment that contains the PIP
objects.
Tconf Name: OBJMEMSEG
Type: Reference
Example:
bios.PIP.OBJMEMSEG = prog.get("myMEM");
PIP Object Properties
A pipe object maintains a single contiguous buffer partitioned into a fixed
number of fixed length frames. All I/O operations on a pipe deal with one
frame at a time; although each frame has a fixed length, the application
can put a variable amount of data in each frame (up to the length of the
frame).
To create a PIP object in a configuration script, use the following syntax.
The Tconf examples that follow assume the object has been created as
shown here.
var myPip = bios.PIP.create("myPip");