??? 12/26/04 08:45 Read: times |
#83879 - More elaborate Responding to: ???'s previous message |
Lets say you want to draw the 9 * 9 grid on the screen - actually my cro has a 10 * 10 grid which I'll use, we have to ouput 'vectors' to draw the grid pretty much like you would with a pencil and paper. In this instance we can't control the on/off of the CRO trace so we can't lift the 'pencil' from the paper. If the CRO has 0-10V on the X and Y the voltage pairs would be - 0,0 10,0 10,1 0,1 0,2 10,2 10,3 0,3 0,4 10,4 10,5 0,5 0,6 10,6 10,7 0,7 0,8 10,8 10,9 0,9 0,10 this would draw all the horizontal lines. I won't continue for the vertical lines as I'll leave that for you. to make things easier, If you can control the CRO's 'z' input - this allows you to turn off the trace which is like 'lifting the pencil'. Anyway, your code would have a table of vectors like above and would output to the DAC these values for X and Y, pause say 1mS then output the next pair and so on until all the vectors have been drawn, then repeat. |