I want to access a particular memory location of an array. the condition that i have is somewhat like this
Let us say the array is arr[] have 100 elements and i want to access the 10th elements. so for that i want to move to the 10th memory location. the memory location is defined by the user so it is stored in a data register. so how do i use the value data register to move to the required address. this is the code that i have
lea morse,a1
clr.b d2
add.b #11,d1
move.b (d1,a1,d2.w),d1
move.l #6,d0
trap #15
I also tried this code but it does not work
lea morse,a1
clr.b d2
move.b #13,d2
move d2(a1),d3
move.b d3,d1
move.l #6, d0
trap #15