Working code, now I need to get the correct buffers working.