I want a shifter list for a input buffer. My code is:
//Simulate input whit Slider. Is work perfect. Only work for changes by the user.
list = Table[0, {10}];
Slider[Dynamic[b, (b = #; list = Take[Join[list, {b}], -10]) &], {0,
10, 1}]
Dynamic@list
//x is a simulation of data input
Dynamic[x = RandomInteger[10], UpdateInterval -> 1]
//Shifter list. As 'a' change, the code is replayed.
Dynamic[Take[AppendTo[a, x], -10],UpdateInterval -> 1]
I want to run the code only for 'x' changes. No for changes of 'a'. Help me, please.