fifo to use gray  pointer