I had several issues with my foscam and UI5. I gave up with that plugin. I already had the Blueiris software, really great for DVR of my cameras. I then found a Blueiris plugin in mios app store and works great. Also, since I have blue iris and it supports 100's of cameras, I can easily add any camera to my vera with no issue now, just use the blueiris plugin. So, not sure about your issue, but try the blue iris software and plugin. You can down load 15 day trial of software to try.
Hope this helps.