
140721
PRODUCT
MANUAL
PCM-MIO-G-1 22
1. Write
xxxx0xxx
to bit 3 of BASE +11.
Select access to CMD
2. Write
Span data 0000xxxx
to BASE +8.
Where
xxxx
= Span
3. Write
00000000 (zero)
BASE +9.
High order byte for Span
4. Write
CMD 01100xxx
to BASE +10.
Where
xxx
= DAC channel
5. Write
Low Byte data
to BASE +8.
6. Write
High Byte data
to BASE +9.
7. Write
CMD 01110xxx
to BASE +10.
Where
xxx
= DAC channel
8. Additional channels are then programmed by repeating steps 2 through 7.
D/A Interrupts
To operate using interrupt mode, IRQ routing must be configured and interrupts enabled for each device. This is achieved
with the Resource and Resource Enable registers. The following would apply to D/A1:
1. Write
xxxx1xxx
to bit 3 of BASE +11 (select access to Resource Register).
2. Write IRQ selection (0-15 hex) to bits 3-0 of BASE +10 (
xF Hex
= IRQ 15).
3. Write
xxxxxx1
BASE +11 to enable the IRQ.
Enabling an interrupt for D/A2 can be achieved in the same manner with the appropriate offset.
It is possible for both devices to share an interupt or use individual interrupts. When sharing interrupts, the most efficient
method to determine which device generated an interrupt request is to utilize the Master Interrupt Status Register.
DMA Support
DMA operation is available for this device. A sample of these operations under DOS is provided on website. These
operations under other operating systems can be quite complex and are beyond the scope of this manual.
D/A Examples
The most basic method is to first set the output span for a channel and then write the output value for that channel.
Notice that the configuration and data write operations can each be performed with either a single or double instruction
sequence. Each channel can be updated individually using command values 6x & 7x (for configuration and output data,
respectively) which will pre-load the value and present it to the DAC with a single instruction sequence. The second option
is to pre-load the configuration and output data using command values 2x & 3x and then present the values to the DAC
either individually (with command value 4x) or simultaneously (with command value 5x).
Example 1 - Single Instruction Sequence
To configure and write data to a DAC channel, each with a single command sequence, is very simple. The configuration
must be set first and then the data output is written. Of course the span configuration is only required to be set once
unless changes are required during the application.
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com