4. Functions
CNT32-4MT(LPCI)
53
Sampling function
Sampling function
The sampling function obtains count data periodically using the internal or external clock.
The sampling data is transferred to the PC's memory using bus master transfer. The sampling speed can
be up to 20MHz using the internal clock (for 1ch). As bus master transfer is used, an error occurs and
transfer halts if the CNT32-4MT(LPCI) cannot obtain bus access in time for a transfer. Note that
whether or not continuous transfer at 20MHz is possible depends on factors such as what other
applications are running on the PC.
The CNT32-4MT(LPCI) can perform sampling at various different timings based on the start condition,
clock condition, and stop condition combination. See the "Sampling Control" section later in this manual
for details of how to setup the sampling conditions.
Bus mastering
The bus master transfer function on the CNT32-4MT(LPCI) performs DMA transfer between the board
and the application's memory space by utilizing times when the bus is idle. Use a standard variable
declaration in your program to define a static area to use as the application's memory space. As
application memory space is defined by a logical address in operating systems such as Windows, the area
may not be continuous in the physical address space. However, the CNT32-4MT(LPCI) can still perform
continuous data transfer to such discontinuous physical address spaces. Bus master transfer can transfer
data to physical address spaces up to 64Mbytes. When setting up the transfer area in your application,
note that the actual available memory size depends on the operating system you are using and on the size
of memory installed on the PC.
The bus master transfer function can transfer data to memory as a one-time transfer or as a ring (cyclic)
transfer. For a one-time transfer, the transfer halts when the end of the specified memory area is reached.
For ring transfer, transfer starts again from the start of the specified memory area when the end of the
memory area is reached. The transfer continues until the stop condition is detected or the transfer is
halted by software.
Interrupt (During bus mastering)
The following interrupt features are available during bus mastering:
-
Generating an interrupt upon completion of transfer of the specified number of data items
-
Generating an interrupt upon completion of transfer
These interrupts can be passed to the application using the "API-CNT(98/PC)" routines
in API-PAC(W32).
If transfer halts due to an error such as not being able to obtain bus access in time to perform a transfer,
the CNT32-4MT(LPCI) halts the transfer and generates the transfer completion interrupt. Whether or
not an error has occurred can be determined by checking the status.
Содержание CNT32-4MT
Страница 7: ...vi CNT32 4MT LPCI ...
Страница 35: ...2 Setup 28 CNT32 4MT LPCI 3 Click on End Click on End ...
Страница 73: ...4 Functions 66 CNT32 4MT LPCI ...