Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
08/25/05 20:27
Read: times


 
#100103 - To reduce the data amount to transfer
Responding to: ???'s previous message
To reduce the data amount to transfer,
a) Make up the figure as poly-line. Each line has brightness factor.
b) Send the graphic data as sequence of a pair of corner point coordinates and line brightness (X(n), Y(n), Br(n))....
Line brightness is represented as the moving speed of the laser spot.

On the device, the position of the mirror is refreshed at constant interval.
When the laser spot is on the line of (X(n),Y(n)) - (X(n+1),Y(n+1)), the coordinates (x,y) of the mirror is represented as follows.
x = X(n) + Br(n+1) * dx * cnt / sqrt(dx*dx + dy*dy)
y = Y(n) + Br(n+1) * dy * cnt / sqrt(dx*dx + dy*dy)
where
dx = X(n+1) - X(n), dy = Y(n+1) - Y(n)
cnt: number of time intervals after laser spot is on this line.
sqrt: square root

This formula seems to be heavy for 8bit MCU at a glance, but several 10kHz interval will be achieved on fast one-clocker 51, under next condition.
a) Limit coordinates to 8bit
b) Use table method for the calculation of square root.
c) Integer (fixed point) math

Tsuneo

List of 14 messages in thread
TopicAuthorDate
Laser projecter / 8051 timer/PWM            01/01/70 00:00      
   Doubtful            01/01/70 00:00      
      if speed is an issue            01/01/70 00:00      
         DAC            01/01/70 00:00      
   To reduce the data amount to transfer            01/01/70 00:00      
   table            01/01/70 00:00      
      No free lunch!            01/01/70 00:00      
         understandable            01/01/70 00:00      
      table and another approach...            01/01/70 00:00      
   VC program finished            01/01/70 00:00      
      Interrupt-driven Serial IO            01/01/70 00:00      
         stuck in a rut as so amny before you, wh            01/01/70 00:00      
            F120 overkill            01/01/70 00:00      
               that may be, but the proposed 12 clocker            01/01/70 00:00      

Back to Subject List