Somwhow working, but resetting connection