Problem solved after some detective work: The casio was responding to the keyboard twice simultaneously; once from local control and once in a loop through the keyboard track in sonar. Therefore it was playing the same patch twice, layering, but not perfectly in phase. If I shut off "local control" on the keyboard OR "echo keyboard" from sonar the problem would go away. I would imagine that this might be an issue with other brands of keyboards, maybe. Perhaps someone could try it out.