allow to work in overwrite-mode

writes will advance the read pointer overwriting older data if the ringbuffer is full and
mode is set to RBUF_OVERWRITE_MODE
test the overwrite mode