opto-coupler: transistor vs logic

Here's a schematic of my wiring (not including wires going to the stepper motors).

That is not much of a schematic is it. Could you make it from that schematic? Dose it show the power supply? Does it show you where the wires are going, especially the ground? Is the screening on your cable still floating? You have been told about that.

I initially had the stepper motor shields connected to ground, but this caused the Uno to think the limit switch was activated.

So how does that work with the shield and Arduino floating with respect to each other?

Those scope readings are AC coupled. Any logic input will be able to cope with that much ripple on the inputs, it should not be an issue if you have your grounds right.