Video cam based profile probing

This is where you talk about Plugins. How they are made and how they work, show examples.

Re: Video cam based profile probing

Postby Arri » Sun Dec 08, 2019 10:18 am

Hello Eric and Dezsoe,

My mistake on the virus, I just didn't read the time/date as I should have. Norton did provide that false positive on what they call ws.reputation.1... that false positive "completely" disappeared after I updated Norton and re-scanned the extracted files.

I apologize for my mistake and thanks for catching this and for being knowledgeable and insightful. I'm in, I think this is exciting stuff!
Arri
 
Posts: 5
Joined: Thu Dec 05, 2019 7:04 am

Re: Video cam based profile probing

Postby eabrust » Sun Dec 08, 2019 1:57 pm

No worries Arri, Its better these days to be cautious on what you download and install. :D

Will be hoping to hear that the program loads and functions on various camera/computer setups from testers. Also curious if any of the testers use a mini 'fanless' sort of PC. I'm guessing at this point, they are more powerfull than the old PC I'm testing with.

I also think I'm needing to get a different camera for continued testing (currently using this cheapo: https://www.amazon.com/gp/product/B07VF559F3/ref=ppx_yo_dt_b_asin_title_o01_s00?ie=UTF8&psc=1.
I just noticed that the camera I'm using (which has an adjustable 'zoom' wheel on it) has a sloppily loose lens assembly which sort of rattles when you shake the camera. This results in the image bouncing around due to vibration on the CNC machine... doh :? . I wouldn't recommend this type of camera currently. Or, I may find the zoom that best fits my use, and lock the lens in place with a dab of silicone. Oh well, I bought this cheap camera to play with knowing full well it may wind up as a toy for the kids....

regards,
Eric
CraftyCNC: Plugins for UCCNC (and other neat stuff): http://www.craftycnc.com/plugins-for-uccnc/
eabrust
 
Posts: 348
Joined: Fri Sep 16, 2016 2:32 am
Location: Near Shirland IL, USA

Re: Video cam based profile probing

Postby 1JUMPER10 » Sun Dec 08, 2019 6:30 pm

Wow! Great to see your progress on this! I would be willing to test it also if you still need testers.

A few years ago I ran across scanything and had a great idea to use it to trace live edge on wood slabs. I bought and still have the recommended USB camera. But, I wasn't going to use Mach 3 to make it work. Let me know if you need a tester.
1JUMPER10
 
Posts: 76
Joined: Tue Oct 04, 2016 1:54 am

Re: Video cam based profile probing

Postby eabrust » Fri Dec 13, 2019 10:36 pm

Couple part update, as I had a day off work at got to play in the shop :)

First, I received another camera microscope to test. This is another reasonably priced 'Amazon' purchase, from here:
https://www.amazon.com/gp/product/B005P40OXY/ref=ppx_yo_dt_b_asin_title_o02_s00?ie=UTF8&psc=1

I was debating going a more expensive route and looking for a camera that would potentially record at 60+ fps or do 30fps with a higher resolution, but I'm glad I went the cheap route again. The picture from this is great, easily does 30 fps with good light (on my office PC, a little slower on my old shop PC), focus is easy to dial in, and unlike the other camera I tested, there is no 'slop' in any of the lenses or focus mechanism. The only thing I don't like about this camera is the cord is somewhat short and stiff.

Here is is mounted up:
IMG_20191213_090717.jpg


Example pics from it on bench test:
Capture.JPG

Zoomed on the 'O' from 'Lock'
Capture4.JPG


I had been planning on adding the ability to select camera resolutions/modes to the plugin, but based on some testing, I plan to basically lock the plugin to run the camera at 640x480, with the following reasons:
* Every camera I've tried does ~30 fps at 640, but as you go up in resolution, the frame rate falls really quickly.
* Some camera's I've tried will go smaller than 640, but not all would run at a smaller resolution.
* I did do some testing with increased resolution, and the routines that perform line detection/etc really slow down to...

So, I'm glad I didn't buy a fancy 'fast high resolution' camera that would have still run slowly... :lol:
CraftyCNC: Plugins for UCCNC (and other neat stuff): http://www.craftycnc.com/plugins-for-uccnc/
eabrust
 
Posts: 348
Joined: Fri Sep 16, 2016 2:32 am
Location: Near Shirland IL, USA

Re: Video cam based profile probing

Postby eabrust » Fri Dec 13, 2019 11:08 pm

So, with Xmas approaching.... It's time to get going on some gifts... and try to utilize this plugin for test purposes.

I found a knife I really liked for it's size, cost, and is assisted opening... https://www.amazon.com/gp/product/B00XZDKSOW/ref=ppx_yo_dt_b_asin_title_o00_s00?ie=UTF8&psc=1

So my goal was to customize it with an engraved wooden scale. Upon taking the scale off, I realized it was slightly more complicated than I thought, needing pocketing on the back as well. Perfect opportunity for testing!
IMG_20191213_092958.jpg


The orignal scale, despite being black molded nylon, was a challenge to line follow, because the mold had left milling marks on the back side of the scale, which reflected quite a lot and fooled the line detection away from following the actual edge a few times. Plus, the grease... which I didn't feel like wiping of :):
IMG_20191213_090613.jpg


With a bit of playing with adjustments and lighting, I was able to get enough of a trace of the pocket and the outline to work with from a few runs of the plugin:
knifescale1.PNG

Note that the holes were grabbed by just centering the scope over the holes, and capturing the position, they were not 'traced' around their edges. This is a new addition to the plugin added since sent out for testing.

Into VCarve, it took very little time to cleanup and smooth the outlines with node edits and bezier curve fitting (this is cleaned up curves, overlayed over raw recorded dxf):
scaleVcarve3.JPG


From there, I set it up as a multi piece 2-sided machining job, and it turned out well:
IMG_20191213_141828542.jpg
IMG_20191213_142356857.jpg



Will be going back and tweaking the gcode for the chamfer a bit, but all the holes, pocket, and outline were a nice fit, plus I enjoyed my day in the shop :)
CraftyCNC: Plugins for UCCNC (and other neat stuff): http://www.craftycnc.com/plugins-for-uccnc/
eabrust
 
Posts: 348
Joined: Fri Sep 16, 2016 2:32 am
Location: Near Shirland IL, USA

Re: Video cam based profile probing

Postby eabrust » Fri Dec 13, 2019 11:12 pm

And here is one knife cleaned up and laser-engraved, just need to apply some oil finish:
IMG_20191213_152050173.jpg

(yes, of course I'm keeping one for myself :lol: )

Hope to hear from some of you with a copy of the test plugin, to find out if it at least runs without crashing for you .

regards
Eric
CraftyCNC: Plugins for UCCNC (and other neat stuff): http://www.craftycnc.com/plugins-for-uccnc/
eabrust
 
Posts: 348
Joined: Fri Sep 16, 2016 2:32 am
Location: Near Shirland IL, USA

Re: Video cam based profile probing

Postby eabrust » Thu Dec 19, 2019 3:38 am

More progress, although moving slow... :)

I think I've added all features needed to make it a workable program... some of the items added in the last week(s):
-Ability to jog from within the plugin (allow for repositioning and focusing the camera without grabbing pendant)
-Estop button tied in
-Cleaned up the screen so there is now only one video display window (toggle selection of what is shown)
-Manual recording of current position to dxf (ie, center camera over a hole and record position)
-Got color thresholding (HSV) working better, so now instead of just looking for edges, it can find specific colors
-Added demo / licensing scheme into program
-Ability to set the 'direction' the program will line follow by clicking on the screen (This was a big headache, but glad it is working :) )
- DROs overlayed on screen


This video sort of gives the general idea of how some of the features behave relative to the image processing and filtering.


Thought I would give the idea of how the planned license scheme is currently setup, and ask for constructive feedback:
Right now, the program will run for 30 days with no feature limit and will do everything. After 30 days (end of demo period), the program will still run, but will no longer save DXFs or enable the velocity commands to UCCNC.

To obtain a license, an ID based off of the users name and device serial number (same as UCCNC shows on the help page) will be used to generate a key that can be used to unlock the program. The key will be tied to the controller SN and name such that the user can move the license from computer to computer as long as it follows the UC device (just like the UCCNC license file does). You'll also be able to move the plugin to new versions of UCCNC without issues.

By tying the user name into the ID, I'll be able to issue additional discounted or free replacement licenses (such as if your UC100 should get replaced due to failure, upgrade, etc) by verifying the name tied to the new SN is the same person as tied to an old SN. The license will not require the computer to be online, and won't 'phone home' in any manner. It will be obtained by sending me an email with your 'ID' as shown in the program, and I will then email back the 'key' to be pasted in, and that will license the plugin on that PC. Once you have the key for your ID, it works indefinitely and will work even as updates are made to the plugin.

Thoughts / complaints / comments on the scheme ? It's really the same way UCCNC itself is licensed, except for adding the 30 days of unrestricted use as a demo mode.

I'm basically at the point I'm done trying to add new features, and trying to fix remaining bugs and tidy up the interface. I'd like to move some of the controls into 'movable and dockable' panels to pretty it up, but that will likely be a future update. I've also got to work at making an installer and some sort of manual or how to/usage video before its ready to put out.

Its been a fun project and I've learned alot in the process, but as a self-taught (ie, non-programmer), I'm sure some of the code I've written would make Balzas and Dezsoe cringe.... :lol: :oops:

regards
Eric
CraftyCNC: Plugins for UCCNC (and other neat stuff): http://www.craftycnc.com/plugins-for-uccnc/
eabrust
 
Posts: 348
Joined: Fri Sep 16, 2016 2:32 am
Location: Near Shirland IL, USA

Re: Video cam based profile probing

Postby Andygoodman » Thu Dec 19, 2019 9:29 am

Hi Eric.

I can't watch the video. is there any setting on the forum that i missed? :oops:

look forward to this plugin with great excitement :lol:
when do you think you will release it? :roll:

thanx
//Andy Goodman
Andygoodman
 
Posts: 5
Joined: Sat Dec 14, 2019 9:55 am

Re: Video cam based profile probing

Postby beefy » Thu Dec 19, 2019 11:34 am

eabrust wrote:Its been a fun project and I've learned alot in the process, but as a self-taught (ie, non-programmer), I'm sure some of the code I've written would make Balzas and Dezsoe cringe.... :lol: :oops:

regards
Eric


That last sentence made me laugh. I'm in exactly the same boat as you, a self-taught guy when it comes to programming. I've thought exactly the same thing many times about how real programmers would detest my code. But hey, I have my own custom THC that talks to UCCNC and basically it just works, and most of all it feels damn good knowing I achieved that through a lot of time, effort, failures and frustrations. No doubt you get the same feeling of accomplishment and satisfaction, however crap your code may look :) .

Sorry I haven't had a chance to check out the plugin. Been working 7 days with plant overhaul jobs and when I'm home I'm like a knackered sloth. Haven't even found my USB camera yet. Christmas (and any holiday times) are the busiest for where I work so won't even see much in the way of time off over the festive season.

I'm sure I'll be one of the guys forking out money to buy your plugin when it's officially released. I wish you all the best with this little venture, you deserve it.

Keith.
beefy
 
Posts: 449
Joined: Mon Sep 05, 2016 10:34 am

Re: Video cam based profile probing

Postby eabrust » Thu Dec 19, 2019 12:48 pm

Andygoodman wrote:Hi Eric.

I can't watch the video. is there any setting on the forum that i missed? :oops:

//Andy Goodman



Try again, I think it was my fault on posting video as non-public.

I'm hoping to wrap it up enough over the next few weeks with time away from work :). Key word is hope.....

Eric
CraftyCNC: Plugins for UCCNC (and other neat stuff): http://www.craftycnc.com/plugins-for-uccnc/
eabrust
 
Posts: 348
Joined: Fri Sep 16, 2016 2:32 am
Location: Near Shirland IL, USA

PreviousNext

Return to Plugins

Who is online

Users browsing this forum: No registered users and 2 guests