YoungWint
Member
Hi All
Bit puzzled.
I have wrote a bit of code to take the 8 channels from an analogue card and store them in an array.
The array data (8 Ints/ Words) is then moved to a Datablock where each card is stored with an index move to step to each card.
I have the code working but am a bit lost as to why or how its working. Could anyone explain, code for setting pointer as below:
L #CH0_Raw
T #RAW_AIN[0] // This is repeated for each channel
L W#16#10002
T LW [AR1,P#0.0]
L 16
T LW [AR1,P#2.0]
L #Dst_block
T #LW [AR1,P#4.0]
L #Dst_Index // Channel Number
L 64
*I
T #Result
L #Result
+I
SLD
L P#DBX0.0
OD
T LD [AR1,P#6.0]
I then use SFC20 to move the array contents to the DB.
It works but how? Particularly puzzled by the 64.
Any one can shed any light on this would appreciate it.
Young Wint
Bit puzzled.
I have wrote a bit of code to take the 8 channels from an analogue card and store them in an array.
The array data (8 Ints/ Words) is then moved to a Datablock where each card is stored with an index move to step to each card.
I have the code working but am a bit lost as to why or how its working. Could anyone explain, code for setting pointer as below:
L #CH0_Raw
T #RAW_AIN[0] // This is repeated for each channel
L W#16#10002
T LW [AR1,P#0.0]
L 16
T LW [AR1,P#2.0]
L #Dst_block
T #LW [AR1,P#4.0]
L #Dst_Index // Channel Number
L 64
*I
T #Result
L #Result
+I
SLD
L P#DBX0.0
OD
T LD [AR1,P#6.0]
I then use SFC20 to move the array contents to the DB.
It works but how? Particularly puzzled by the 64.
Any one can shed any light on this would appreciate it.
Young Wint