First check that you don’t have the Transpose button lit on the XP50 (with that lit the OCT-/OCT+ buttons will shift the Kbrd by semitones - without it lit the OCT-/OCT+ shift by octaves plus anything you’ve already setup with transpose lit).
On the XP50 check out System/Setup/Setup and make sure that no transpose has been set there. If is has set it back to zero.
Make the MIDI connection IN/OUT from the XP50 to your Cubase host and fire up Cubase.
Set the XP50 to single patch mode and select a chromatic patch known not to have built in transpose (eg A001 - Piano) and turn “local off” (easiest way is from the front panel button).
Check MIDI thru is enabled in Cubase preferences.
Create a MIDI track in Cubase and connect it to your XP50.
Load a “MIDI Monitor” to an insert slot in the track inspector.
Monitor enable the track and then play a note on the XP50.
You should see the note you played displayed in the MIDI Monitor (you will see two events for the same note, one where you pressed it and another when you released it).
The note you see displayed should correspond to the note you pressed if there is nothing transposing it en route to/from the track. Assuming no transpose is set-up in C6 and you have no transpose set on the XP50 then everything should match.
PS I have an XP80 - I think the XP50 is functionally the same in respect of the above.