Romeo v1.1 hangup while controll two Motors

Hi,
I’m from Germany. I’m sorry for my bad English.
I have bought a Rome v1.1 controller and the motor and wheel set KIT0014-S form your shop.
I want to build a self Balance-Roboter.
I have connect the tow motors to the Romeo Motor terminals and give 7,4V from an Lipo to the Motorpower Terminal.
If I test the sample sketch form your wiki, every think is fine the Motor move forward and backwards. But if I try my own source code with the calculation of the Position the Romeo Controller is hanging up after a few Seconds. The Serial monitor is no more working and the Motor becomes the voltage from the last loop of the Controller.
It makes no difference if I connect internal or external Power to the Motors.
If I try the code without power for the Motors the code is running without any problems.
I don’t know how is the mistake .
Can anybody help me?
I’m from Germany. I’m sorry for my bad English.
I have bought a Rome v1.1 controller and the motor and wheel set KIT0014-S form your shop.
I want to build a self Balance-Roboter.
I have connect the tow motors to the Romeo Motor terminals and give 7,4V from an Lipo to the Motorpower Terminal.
If I test the sample sketch form your wiki, every think is fine the Motor move forward and backwards. But if I try my own source code with the calculation of the Position the Romeo Controller is hanging up after a few Seconds. The Serial monitor is no more working and the Motor becomes the voltage from the last loop of the Controller.
It makes no difference if I connect internal or external Power to the Motors.
If I try the code without power for the Motors the code is running without any problems.
I don’t know how is the mistake .
Can anybody help me?