You are consistently attempting to pass your 2-D arrays as single char values to your functions. If these arrays are global then you don't really need to pass them at all.