console_write_func now wraps if end of line is reached.