Hi,the ringbuf stuff is severly broken. C module arithmetic can be pretty akward:
(ringpos - 1) % RING_SIZE, with ringpos = 0 and RING_SIZE = 6: -1 % 6 = -1 WTF? why isn't it 5?I've just made a simple function to fix this, but I'm looking for a more elegant solution.
Ilja