Arduino Ping sensor and motors

I have the Arduino Uno with the Arduino motor shield stacked on top of it, The ping is connected to the bread board with wire leads going from it to the motor shield that pins downs of course the Arduino Uno. I have the ping signal wire on pin 7 and the power going to 5v and ground of the shield. The motors are connected in the A and B terminals of the motor shield. The robot is powered through the motor shield by a 9.6v battery pack. The problem I’m having is the ping sensor is flickering green as if it were programmed when the motors are running like a power interference. when I disconnect the signal wire from the ping nothing changes but when power or ground is disconnected from the ping it obviously stops. What can I do to fix this. I want the robot to work with the ping and motors. Shouldn’t the ping be able to work through the 5v terminal without interference?

The motors keep going so it seems as if its continuing to keep going the power light on the Arduino stays on the green power light that is on the board. Is that what you wanted to know?

Yes the power on the ping does erratically go off and on when the motors start turning, the Arduino Uno board has a consistent green status light when this is going on. do I need to upgrade the battery source or power the ping separate? I want to also run a servo to pan the PING sensor so I’m assuming I do? 12v battery?

If we understand correctly, the power on the Ping seems to go OFF and ON again erratically when the motors start turning. This might be caused by your battery not being powerful enough (and the voltage dropping when you consume too much current). Is the Arduino stopping as well?