I haven't rtfm at all really, so tell me to step off if this s**t is covered, I will get around to it....
But what is up with the gain staging in the ms?

Here, the waveform on the left is the original signal that I sent to the korg.
As you can see, this is at a steady level so there were no gain fluctuations, I set the korg's audio in to the point JUST before it clipped with this steady signal. I set the korg's sampling level to 0.0 db.
I sent the sample to the korg, then sent it back to my daw at maximum amplitude.
As you can see there is a significant decrease in volume. Why is this, and how can I sample at x db, and resample back into my daw at the same x db?
ALSO, wtf is going on with this waveform? As you can see, the original signal is a mathematically pure square wave. The Korg has majorly altered this square wave. What is up with that?
All info is appreciated.