I am not familiar with Cakewalk Sonar 4, but most recording software has a MIDI events list section which may help you see what messages are being exchanged back and forth on which channels? The Casio unlike the "bigger models" will not play fair with local host issues sometimes depending on the setup? The Casio evidently does not like being a local controller mode device when external MIDI data is present.The casio 'transmit' channel can be set in the Transpose button/ cursor down 1..to the 'xx keybd ch' display, where the 'xx' is the current output channel for the Casio's internally displayed 'channel 1', thats what you see on the Casio display as 'channel 1' can be transmitted 'out' of the Casio's 'midi out', on any channel (1-16). All SysEx data should travel back and forth based on this setting, and displayed in the events list for that channel in Sonar? Give it a try and see what happens!