USA
Asked — Edited

Ez-Bv4 And Camera With Surface Pro

I'd like to use the 160x120 resolution in my project running ARC (the latest version) for Windows on a Windows 10 Surface Pro 2 but I get the following error:

11/3/2018 11:37:43 AM - Error Camera.SetCaptureImage: AForge.Imaging.UnsupportedImageFormatException: Source pixel format is not supported by the filter. at AForge.Imaging.Filters.BaseTransformationFilter.CheckSourceFormat(PixelFormat pixelFormat) at AForge.Imaging.Filters.BaseTransformationFilter.Apply(BitmapData imageData) at AForge.Imaging.Filters.BaseTransformationFilter.Apply(Bitmap image) at EZ_B.Camera.eihiq5ToKN(Object )

It runs at 320x240 okay but uses a lot of CPU and the image tends to hang or stutter and falls behind when face tracking. Anyone else have issues with the surface pro? The exact same builder file works fine on my laptop (with Windows 7). Thanks:)


ARC Pro

Upgrade to ARC Pro

ARC Pro will give you immediate updates and new features needed to unleash your robot's potential!

PRO
Synthiam
#1  

Not all resolutions are supported on all devices. It’s up to the hardware manufacturer.

What tracking types are you using that’s requiring so much cpu? Let’s see what we can do to help with that

#2  

Hey DJ, it's been a long time. I finally got around to getting a Surface Pro 2 for iRobot:

https://synthiam.com/Community/Questions/9877

I'm going to install it in the pedestal so folks can see Builder running. I made a couple of apps but I like the the look of Builder better. It's going to be in a show at Northern Illinois University in January so I'm trying to get it all buttoned up.

All I'm using is face tracking right now. I've tried adding motion and a few custom colors but simple face tracking seems to work best. Maybe I overstated "a lot of CPU", it jumps between zero and 40%. I shrank the camera control window and that seemed to help with the stuttering. I guess I just assumed 160x120 should be available.

Oh, and it's been disconnecting every night between 3:30 and 4:00 AM. Three nights in a row, now. 2 with the Surface and once with the laptop. This is a new problem. When I first got iRobot put together, it ran for about 5 weeks with no issues. Here is the error message:

EZB 0: 11/1/2018 4:16 PM - Windows version: Microsoft Windows NT 10.0.16299.0 11/1/2018 4:16 PM - Object Recognition Initialized. 11/1/2018 4:16 PM - Object Recognition loaded. EZB 1: EZB 2: EZB 3: EZB 4: 11/1/2018 4:16:21 PM - Screen Resolution: 1920x1080 (96x96 dpi) 11/1/2018 4:16:21 PM - Version: 2018.09.30.02 11/1/2018 4:16:25 PM - Attempting connection on 192.168.1.1:23 11/1/2018 4:16:26 PM - Connected to 192.168.1.1:23 11/1/2018 4:16:26 PM - Reports EZB v4 OS With Comm 2 11/1/2018 4:16:26 PM - EZ-B v4 ID: 73-49-0-0-46-255-58-56-56-38-38-38 11/1/2018 4:16:26 PM - Setting battery monitor voltage: 5.5 11/1/2018 4:16:26 PM - Setting battery protection: True 11/1/2018 4:16:26 PM - **WARNING: The low battery warning monitor value is set LOWER than the recommended default of 7v. Your voltage monitor set for 5.5v. If using the LiPo batteries from a Revolution EZ-Robot, for battery longevity and your safety we highly recommend that you change the low battery monitor back to 7v. This setting can be found in the Connection Control Config Menu. 11/1/2018 4:16:26 PM - Setting i2c rate: 100000 11/1/2018 4:16:26 PM - EZ-B voltage is 5.677777980 11/1/2018 4:16:26 PM - EZ-B temperature is 24.33952776160016496C 11/1/2018 4:16:26 PM - Connected 11/1/2018 4:16:30 PM - Camera Initialized: EZB://192.168.1.1 @ 320x240 11/1/2018 5:10:57 PM - Saved C:\Users\reset\Desktop\iRobot_Final.EZB 11/1/2018 5:11:09 PM - Saved C:\Users\reset\Desktop\iRobot_Final.EZB 11/1/2018 5:22:15 PM - Camera Disabled 11/1/2018 5:22:15 PM - Camera Disabled 11/1/2018 5:24:14 PM - Camera Initialized: EZB://192.168.1.1 @ 320x240 11/2/2018 4:15:42 AM - EZ-B v4 Camera Error: System.IO.IOException: Unable to read data from the transport connection: An established connection was aborted by the software in your host machine. ---> System.Net.Sockets.SocketException: An established connection was aborted by the software in your host machine at System.Net.Sockets.Socket.Receive(Byte[] buffer, Int32 offset, Int32 size, SocketFlags socketFlags) at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size) --- End of inner exception stack trace --- at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size) at EZ_B.EZBv4Video.zhDAFhUutB(Int32 , Object ) 11/2/2018 4:15:42 AM - Camera Disabled 11/2/2018 4:15:42 AM - Error Camera.SetCaptureImage: System.NullReferenceException: Object reference not set to an instance of an object. at AForge.Imaging.Drawing.Line(UnmanagedImage image, IntPoint point1, IntPoint point2, Color color) at EZ_B.Camera.eihiq5ToKN(Object ) 11/2/2018 4:15:42 AM - Comm Err: System.IO.IOException: Unable to write data to the transport connection: An existing connection was forcibly closed by the remote host. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host at System.Net.Sockets.Socket.Send(Byte[] buffer, Int32 offset, Int32 size, SocketFlags socketFlags) at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset, Int32 size) --- End of inner exception stack trace --- at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset, Int32 size) at EZ_B.EZB.nM1edIYc5k(Int32 , Byte[] cmdData) 11/2/2018 4:15:42 AM - BbytesToExpect: 2 11/2/2018 4:15:42 AM - Received: 0 0 11/2/2018 4:15:43 AM - Disconnected

PRO
Synthiam
#3  

Right on man, that’s great! Good for you

I have a new face tracking feature planned in the next few weeks. That should handle your cpu usage better.

As for the disconnects - that’s a tough one because there’s so many factors. The biggest being the 3 am time:) that’s when Microsoft does its update query for windows - so who knows what’s going on there!

Since the computer and robot are connected, I recommend wiring the ezb and pc directly like so: https://synthiam.com/Tutorials/Lesson/76?courseId=4

Additionally, I believe you were using the ezrobot camera? If so, that can be wired to the pc directly as well:D

#4  

Yeah man, the show should be pretty cool. It's artwork of college profs and their students shown together so it's a little different. I'm excited.

I'm not ready to hard wire this thing quite yet but it did disconnect again this morning around 6:30 AM. I turned off auto-update but it didn't help. This is just odd; it's never done this before.

"An established connection was aborted by the software in your host machine."

What does "the software" mean? ARC? Did I check a wrong box somewhere? More likely, that message means Windows itself. I'll look into that end of it.

I'm also going to bump up the power brick from 2 amp to 3, maybe a little more. Last night I found your article about servo inrush. I hadn't seen that before now. But still, it doesn't explain why it worked for weeks on end last year. And at night, with the house dark, the camera is seeing black so the servos shouldn't be activating. Could it be just a lack of activity?

#5  

Just a thought here.......... Check your power setting on your laptop. Maybe there's a setting that puts the computer into sleep mode, reboots or shuts down a device in the computer after so many hours.

Also random wifi disconnects are sometime associated with wifi signal strength or other router activity. Are you connecting in Client or AP mode? How old is your router? Look closely at your router's settings. I'm definitely not a network guy but have struggled through it successfully with help from this forum. When I first started using EZ Robot I had to upgrade my router because it would not stay connected and had random disconnects. I also assigned EZB a static IP address in my router and that seemed to help. However I was told by DJ not to do that for some reason and he advised the community not to listen to my advice on this subject of static IP addresses (I did it anyway, LOL. Sorry DJ ;) ).

Good luck and I hope you are well. It's been awhile since you've visited. Good to see you back. :)

PRO
Synthiam
#6  

Haha Dave:)

The disconnect is not ARC, but the computer operating system. As Dave said there’s a few things, specially power. He’s got it right - power saving would do that. Hibernation mode would do it. So would the WiFi device being in energy saving mode.

One thing to do that ensures the device is not updating windows and such is to set the WiFi connection as Metered

Lastly, it could be a neighbor messing with you? Is the ezb on a network with a password?

#7  

Thanks fellas, I appreciate the suggestions. Power saving options in Windows was the first thing I looked at but I'll look again. It's completely possible there is a setting buried deep in the OS somewhere. That still doesn't explain why it used to work fine, with the same laptop that disconnected one of the nights.

I'm connecting directly to the EZB, no router involved. The sculpture, the Surface (or laptop), microwave, home internet router, and all furniture are in the same locations they were in last year (we're boring!). And I have no neighbors, lol. Bean field, corn field, corn field, bean field.

Is there any chance the camera or EZB is going belly up? The sculpture has been covered with a black sheet in the living room for the past year but hadn't been powered up in about that long.

Lastly, do you guys ever use electrolytic grease on the connections? I may have to completely disassemble the head and check the connections.

And "hey" back, Dave. Good to hear from you too.:)

#8  

Okay guys, I found a couple of settings on the Surface that I think might help. But mostly I think it was the "allow the computer to turn off this device to save power" on the wireless card's options in the device manager that was causing the problem. I unchecked the box and....well....I'll find out tomorrow morning if that was the issue. This is just the Surface though. But if it solves it, I'm good with it :D