User`s manual

PK2100
5-6 s Software Reference
void up_dac420( int current )
Sends a current value to the DAC output channel. The current is
specified such that 1000 = 1 milliamp. The maximum is 20,000 or
20milliamps. Pins 1-2 on Jumper J7 must be connected for current
output. The maximum output is approximately 12 volts.
void up_expout ( int rawval )
Sends a raw value to UEXP, the internal D/A converter. Use this
function primarily for testing and calibration since, in most cases,
UEXP is subject to constant manipulation by interrupt routines. Use
up_expout( up_docal(value) );
to output a calibrated value expressed in millivolts.
Virtual Driver
The virtual driver does not perform analog output.
High-Speed DMA Counter
The two DMA channels are used as high-speed counters, and are capable
of counting up to 600 kHz. Function calls load the countdown value for
the DMA channel and enable the DMA interrupt. Flags for the DMA
channel are set to 1 once a counter reaches zero. A program can monitor
these flags.
void DMA0Count( uint count )
Loads the DMA channel 0 with the count value and enables the DMA
Channel 0 interrupt. The function sets the flag _DMAFLAG0 to zero.
When count negative edges have been detected, the channel will
cause an interrupt and the interrupt service routine will set the flag
_DMAFLAG0 to 1. A program can monitor _DMAFLAG0 to determine if
the number of counts has occurred.
void DMA1Count( uint count )
Loads DMA Channel 1 with the count value and enables the
DMA Channel 1 interrupt. The function sets the flag
_DMAFLAG1 to zero. When count negative edges have been
detected, the channel will cause an interrupt, and the interrupt
service routine will set the flag _DMAFLAG1 to 1. A program can
monitor _DMAFLAG1 to determine if the number of counts has
occurred.