Bottom Vision Released!

1,069 views
Skip to first unread message

Jason von Nieda

unread,
Apr 25, 2016, 12:00:08 AM4/25/16
to ope...@googlegroups.com
Hi folks,

I'm very excited to announce that the first version of OpenPnP's bottom vision module has been released. This feature has been in development for a very long time and I'm really excited for it to finally see the light of day!

Bottom vision, in essence, uses computer vision and an upward looking camera to improve your placement results. You can read more about it here:

This module is brand new and will probably require a few more iterations before it's very reliable. That being said, I am getting great results with it already and I hope it will be a big help on your machines too.

The feature is now in the develop branch and you can either update your code or download the Develop releases from http://openpnp.org/downloads/

There is a lot more info to come on this huge feature, and lots of documentation to be written, but I wanted to get this out there so people can start playing with it.

With Bottom Vision comes a number of smaller but also important changes. I've been documenting those here:

So, please give it a try and let me know what you think. All feedback is welcome and encouraged!

Thanks,
Jason


Michael Anton

unread,
Apr 25, 2016, 1:08:15 AM4/25/16
to OpenPnP
Wow!!  That is a great update list, and seems to include many of the functions that I was hoping would make it into a release someday.  Now if only I had a working machine with driver support (I have a FPD at the moment)... :-(

Mike

Anthony Webb

unread,
Apr 25, 2016, 12:24:57 PM4/25/16
to OpenPnP
Oh man, cant wait to give this a whirl!  Such a huge milestone, really moves openpnp to another level.  Thanks for all your hard work Jason, this is just awesome!

Robert Walter

unread,
Apr 25, 2016, 12:33:53 PM4/25/16
to OpenPnP
Jason,

Stunning implementation! I can not believe how much functionality you put into the first revision. The pipeline editor is freakin' amazing... So flexible. WOW!



Jason von Nieda

unread,
Apr 25, 2016, 2:21:10 PM4/25/16
to OpenPnP
Thanks everyone! I'm very happy with how it's turned out so far and it's just going to get better and better. I think the CvPipeline stuff is going to be a game changer when it comes to vision across a wide spectrum of machines, cameras, lighting conditions, etc. 

Please don't be shy about feedback. I'd like to hear any thoughts you all have on the system.

Jason


On Mon, Apr 25, 2016 at 9:33 AM Robert Walter <ttsther...@gmail.com> wrote:
Jason,

Stunning implementation! I can not believe how much functionality you put into the first revision. The pipeline editor is freakin' amazing... So flexible. WOW!



--
You received this message because you are subscribed to the Google Groups "OpenPnP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openpnp+u...@googlegroups.com.
To post to this group, send email to ope...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/openpnp/accb6dbe-03a2-4715-ba2b-2922cf6d3dfc%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Peter Betz

unread,
Apr 25, 2016, 3:53:03 PM4/25/16
to OpenPnP
Nice work Jason. I'm glad I bought two ELP cameras!!

Lisandro B

unread,
Apr 27, 2016, 5:06:14 PM4/27/16
to OpenPnP
Peter: what is the advantage of the ELP cameras to a, IE, a logitech c270?

(sorry for the slightly off topic)

Peter Betz

unread,
Apr 27, 2016, 5:56:44 PM4/27/16
to ope...@googlegroups.com
My pick and place hasn't even moved under its own power yet so I'm not the right guy to ask. Firepick spec'd them for the upward camera and Anthony suggested it and he uses them for his design. I think they are the best he has tried. Pretty sure there have been threads on cameras if you search. 

Peter Betz
--
You received this message because you are subscribed to a topic in the Google Groups "OpenPnP" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/openpnp/dumBEEgHg8E/unsubscribe.
To unsubscribe from this group and all its topics, send an email to openpnp+u...@googlegroups.com.

To post to this group, send email to ope...@googlegroups.com.

Jason von Nieda

unread,
Apr 27, 2016, 6:36:22 PM4/27/16
to ope...@googlegroups.com
Lisandro,

From everything I have seen the C270 is a great camera. I have one myself, although I am not currently using it. 

My preference for the ELP is just that it's a module instead of a finished product that needs to be torn apart and modified for use with a pick and place. I actually think the C270 is probably a better camera than the low end ELP but since it has to be modified for mounting and lens adjustment I hesitate to recommend it.

Jason


--
You received this message because you are subscribed to the Google Groups "OpenPnP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openpnp+u...@googlegroups.com.
To post to this group, send email to ope...@googlegroups.com.

Oz-Ron

unread,
May 1, 2016, 9:35:59 AM5/1/16
to OpenPnP

Jason, tremendous to see your project evolving and gaining momentum.  Keep up all the great work everyone as it is getting even more interesting by the day!

 

Help please:

With the latest OpenPnP develop version running on WIN7 / 32 and two (identical) of the preferred ELP 1080p USB cameras, only the image from one (either if only one connected) is displayed in BOTH the UP looking and DOWN looking image windows. In Windows device manager it shows two USB HD Cameras on separate USB addresses so both data streams should be available?   I expect the changes I made to the OpenBuilds Driver to add the up looking camera on the machine didn’t cut the mustard.  Any help here would be most greatly appreciated.

 

Thanks, Ron

Andrew Frazer

unread,
May 1, 2016, 6:43:22 PM5/1/16
to OpenPnP
I'm wondering if it would be possible to support multiple upwards cameras..

The only reason to do this, is speed.   If i put a couple of cameras ( or more ) on different parts of the machine,  it would be possible to work out which one is "closer", and that woudl reduce the travel distance..

Thoughts.


I know someone is thinking of doing a moving upwards camera,  whch woudl travel on its on gantry in one axis, so it could intercept the placement head, but this seems like a huge amount of work, and I'm thinking its much more complex that perhaps is nessarary..


Andrew Frazer

unread,
May 1, 2016, 6:44:21 PM5/1/16
to OpenPnP

Also is there merit in having two cameras, with different feild of view?  ( wide and narrow for example ? )

Jason von Nieda

unread,
May 1, 2016, 7:35:40 PM5/1/16
to OpenPnP
Yes, I think this may have merit. There is no code for it yet, but I think that for machines that are doing a significant amount of large chip placement this may become more important.

Jason


Andrew Frazer

unread,
May 1, 2016, 7:46:09 PM5/1/16
to OpenPnP
At least one of the commerical desktop machiens ( YongSheng? ) has done this i think..   I might at least design in for an additional camera module.

obiwanke...@gmail.com

unread,
May 1, 2016, 9:58:31 PM5/1/16
to OpenPnP
I don't recall if it was homemade or commercial, I think there was a PnP that had a stationary mirror or mirrors in front of the tape feeders, downward camera was able to do upward rotation by looking at the part in the mirror. I would guess the downward camera was at an angle, the mirrors may have been angled as well. Would save travel time on discrete components, doubt that larger IC's would work like that. Much simpler than a camera on a gantry.

Graeme Bridge

unread,
May 2, 2016, 3:13:19 AM5/2/16
to OpenPnP
i plan to go with a design like the yamaha impulse m7 with 2 upward facing cameras on the pick beam. this is one of the reasons I'm looking at IP cameras rather than usb
Screen Shot 2015-12-04 at 19.44.27.png

Andrew Frazer

unread,
May 2, 2016, 4:48:59 AM5/2/16
to OpenPnP

Is that your cad model?  If it is any chance of you sharing the Feeders?

Graeme Bridge

unread,
May 2, 2016, 9:18:50 AM5/2/16
to OpenPnP
sadly not its screen grab from the youtube video showing the machine. its a yamaha i-pulse m7

Mike Harrison

unread,
May 3, 2016, 5:15:48 PM5/3/16
to ope...@googlegroups.com
Saw a comment yesterday about multiple cameras with different fields of view - remember that it's
possible to image large parts by taking several shots while moving the part around to get it all
into view. A bit slower, but it would be fairly unusual to be placing so many large parts that this
was a big deal for overall speed.

Jason von Nieda

unread,
May 3, 2016, 5:19:30 PM5/3/16
to ope...@googlegroups.com
Hey Mike,

While I agree that this is possible, I feel like it would be quite error prone. Maybe I am wrong, but I'd think that with lens distortion and finite precision in the mechanics it would be tough to get good accuracy using this method. I guess there would be no harm in trying.

Jason


--
You received this message because you are subscribed to the Google Groups "OpenPnP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openpnp+u...@googlegroups.com.
To post to this group, send email to ope...@googlegroups.com.

Mike Harrison

unread,
May 3, 2016, 5:38:20 PM5/3/16
to ope...@googlegroups.com
On Tue, 03 May 2016 21:19:20 +0000, you wrote:

>Hey Mike,
>
>While I agree that this is possible, I feel like it would be quite error
>prone. Maybe I am wrong, but I'd think that with lens distortion and finite
>precision in the mechanics it would be tough to get good accuracy using
>this method. I guess there would be no harm in trying.

If the mechanism is accurate enough to place, it should accurate enough to move the part for
multiple visioning.
The lens field of view needs to somehow be mapped to "real" linear dimensions anyway, so I don't
see that multiple shots would be inherently any less accurate.
And as you're mostly looking for offset and rotation, I don't think it even matters if the stitching
isn't entirely seamless.

An issue is that larger QFPs need good rotational accuracy, but that's no different whether you're
using single or multiple shots.

Multi-shot can be invoked automatically based on the part size and camera FOV, so it "just works"
regardless of part size. Of course the option for multiuple cameras can still be useful, either
different FOVs, or multiple locations to reduce avarage travel times from all feeders. .

The RV handles all this automatically with 4 different methods depending on part size : flying cam,
fixed cam, 2 shots on fixed cam, 4 shots on fixed cam

Mike Harrison

unread,
May 3, 2016, 5:48:40 PM5/3/16
to ope...@googlegroups.com
On Tue, 03 May 2016 22:38:45 +0100, you wrote:

>On Tue, 03 May 2016 21:19:20 +0000, you wrote:
>
>>Hey Mike,
>>
>>While I agree that this is possible, I feel like it would be quite error
>>prone. Maybe I am wrong, but I'd think that with lens distortion and finite
>>precision in the mechanics it would be tough to get good accuracy using
>>this method. I guess there would be no harm in trying.

Thinking about it some more, I think it actually should be pretty easy.
You only care about the corners. it doesn't matter if there is a hole or overlap in the middle. For
a large part, you just shoot 2 or 4 times and offset the centre far enough to make sure the corners
are in the FOV.


obiwanke...@gmail.com

unread,
May 11, 2016, 1:11:44 AM5/11/16
to OpenPnP
I've got the same issue, an ELP camera for up looking, and a borescope USB 2.0 camera on the head. Win 7 finds them both, and if either is plugged in by itself, I get that camera in both panels whether its the up or down cam. If both are plugged in I get the down looking in both panels. Bottom vision check box is ticked. Tried adding a second camera entry into machine.xml without success. Something subtle I'm overlooking ?

Jason von Nieda

unread,
May 11, 2016, 1:33:29 AM5/11/16
to OpenPnP
Can you please post or send me your machine.xml?

Jason


--
You received this message because you are subscribed to the Google Groups "OpenPnP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openpnp+u...@googlegroups.com.
To post to this group, send email to ope...@googlegroups.com.

obiwanke...@gmail.com

unread,
May 11, 2016, 2:00:36 AM5/11/16
to OpenPnP
Just saw there was another entry for camera class near the bottom.

<openpnp-machine>
   <machine class="org.openpnp.machine.reference.ReferenceMachine" speed="1.0">
      <heads>
         <head class="org.openpnp.machine.reference.ReferenceHead" id="22964dce-252a-453e-8106-65db104a0763" name="H1">
            <nozzles>
               <nozzle class="org.openpnp.machine.reference.ReferenceNozzle" id="69edd567-df6c-495a-9b30-2fcbf5c9742f" name="N1" pick-dwell-milliseconds="0" place-dwell-milliseconds="0" current-nozzle-tip-id="e092921a-2eef-449b-b340-aa3f40d8d791" changer-enabled="false" limit-rotation="true">
                  <nozzle-tips>
                     <nozzle-tip class="org.openpnp.machine.reference.ReferenceNozzleTip" id="e092921a-2eef-449b-b340-aa3f40d8d791" name="NT1" allow-incompatible-packages="true">
                        <compatible-package-ids class="java.util.HashSet"/>
                        <changer-start-location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
                        <changer-mid-location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
                        <changer-end-location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
                     </nozzle-tip>
                  </nozzle-tips>
                  <head-offsets units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
                  <safe-z value="0.0" units="Millimeters"/>
               </nozzle>
            </nozzles>
            <actuators>
               <actuator class="org.openpnp.machine.reference.ReferenceActuator" id="5b8a8cbd-d6c1-4324-af8b-eba5f0444622" name="A1" index="0">
                  <head-offsets units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
                  <safe-z value="0.0" units="Millimeters"/>
               </actuator>
            </actuators>
            <cameras>
               <camera class="org.openpnp.machine.reference.camera.OpenCvCamera" id="2c1351fb-0d96-46b1-9e0b-e544decbb8db" name="OpenCvCamera" looking="Down" settle-time-ms="250" rotation="0.0" flip-x="false" flip-y="false" offset-x="0" offset-y="0" device-index="0" preferred-width="0" preferred-height="0">
                  <units-per-pixel units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
                  <vision-provider class="org.openpnp.machine.reference.vision.OpenCvVisionProvider"/>
                  <head-offsets units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
                  <safe-z value="0.0" units="Millimeters"/>
                  <calibration enabled="false">
                     <camera-matrix length="9">3.504997936E-315, 3.50499829E-315, 0.0, 0.0, 0.0, 1.001800636925404E-308, 3.50504928E-315, 3.50486019E-315, 0.0</camera-matrix>
                     <distortion-coefficients length="5">4.3434222404334E-311, 4.343422245611E-311, 100.0, 6.365987375E-314, 0.0</distortion-coefficients>
                  </calibration>
               </camera>
            </cameras>
            <paste-dispensers>
               <paste-dispenser class="org.openpnp.machine.reference.ReferencePasteDispenser" id="53050ccf-59a0-4d9f-a8d3-6216f5412e4e" name="D1">
                  <head-offsets units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
                  <safe-z value="0.0" units="Millimeters"/>
               </paste-dispenser>
            </paste-dispensers>
         </head>
      </heads>
      <feeders>
         <feeder class="org.openpnp.machine.reference.feeder.ReferenceStripFeeder" id="923eedf1-6a1a-4bbc-b603-421066262adc" name="R0805" enabled="true" part-id="R0805-1K" tape-type="WhitePaper" vision-enabled="true" feed-count="0">
            <location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
            <reference-hole-location units="Millimeters" x="147.347" y="40.285" z="0.0" rotation="0.0"/>
            <last-hole-location units="Millimeters" x="147.433" y="36.238" z="0.0" rotation="0.0"/>
            <part-pitch value="4.0" units="Millimeters"/>
            <tape-width value="8.0" units="Millimeters"/>
         </feeder>
         <feeder class="org.openpnp.machine.reference.feeder.ReferenceStripFeeder" id="f869fbd5-4e6f-4ba7-bfc7-476bd6cce845" name="R0603" enabled="true" part-id="R0603-1K" tape-type="WhitePaper" vision-enabled="true" feed-count="0">
            <location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
            <reference-hole-location units="Millimeters" x="157.385" y="40.199" z="0.0" rotation="0.0"/>
            <last-hole-location units="Millimeters" x="157.328" y="36.267" z="0.0" rotation="0.0"/>
            <part-pitch value="4.0" units="Millimeters"/>
            <tape-width value="8.0" units="Millimeters"/>
         </feeder>
         <feeder class="org.openpnp.machine.reference.feeder.ReferenceStripFeeder" id="bcfa145d-0783-4681-a520-082c9ed65799" name="R0402" enabled="true" part-id="R0402-1K" tape-type="WhitePaper" vision-enabled="true" feed-count="0">
            <location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
            <reference-hole-location units="Millimeters" x="167.366" y="40.256" z="0.0" rotation="0.0"/>
            <last-hole-location units="Millimeters" x="167.366" y="36.295" z="0.0" rotation="0.0"/>
            <part-pitch value="2.0" units="Millimeters"/>
            <tape-width value="8.0" units="Millimeters"/>
         </feeder>
         <feeder class="org.openpnp.machine.reference.feeder.ReferenceStripFeeder" id="fdd41763-bb15-4b45-9ffd-cbbc0c52f630" name="R0201" enabled="true" part-id="R0201-1K" tape-type="WhitePaper" vision-enabled="true" feed-count="0">
            <location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
            <reference-hole-location units="Millimeters" x="177.404" y="40.256" z="0.0" rotation="0.0"/>
            <last-hole-location units="Millimeters" x="177.376" y="36.267" z="0.0" rotation="0.0"/>
            <part-pitch value="2.0" units="Millimeters"/>
            <tape-width value="8.0" units="Millimeters"/>
         </feeder>
         <feeder class="org.openpnp.machine.reference.feeder.ReferenceStripFeeder" id="93acbdf4-d715-4bf9-bc70-23016f06b8e4" name="R0805-2" enabled="true" part-id="R0805-1K" tape-type="WhitePaper" vision-enabled="true" feed-count="0">
            <location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
            <reference-hole-location units="Millimeters" x="138.715" y="88.244" z="0.0" rotation="0.0"/>
            <last-hole-location units="Millimeters" x="139.057" y="84.226" z="0.0" rotation="0.0"/>
            <part-pitch value="4.0" units="Millimeters"/>
            <tape-width value="8.0" units="Millimeters"/>
         </feeder>
         <feeder class="org.openpnp.machine.reference.feeder.ReferenceStripFeeder" id="d50c9d17-75c5-45ee-b179-a93630f2070b" name="R0805-3" enabled="true" part-id="R0805-1K" tape-type="WhitePaper" vision-enabled="true" feed-count="0">
            <location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
            <reference-hole-location units="Millimeters" x="155.055" y="87.275" z="0.0" rotation="0.0"/>
            <last-hole-location units="Millimeters" x="154.713" y="83.314" z="0.0" rotation="0.0"/>
            <part-pitch value="4.0" units="Millimeters"/>
            <tape-width value="8.0" units="Millimeters"/>
         </feeder>
         <feeder class="org.openpnp.machine.reference.feeder.ReferenceStripFeeder" id="0eafdd64-6a46-4230-9fd1-9cdac1dfc055" name="R0805-4" enabled="true" part-id="R0805-1K" tape-type="WhitePaper" vision-enabled="true" feed-count="0">
            <location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
            <reference-hole-location units="Millimeters" x="172.679" y="56.242" z="0.0" rotation="0.0"/>
            <last-hole-location units="Millimeters" x="172.251" y="60.289" z="0.0" rotation="0.0"/>
            <part-pitch value="4.0" units="Millimeters"/>
            <tape-width value="8.0" units="Millimeters"/>
         </feeder>
         <feeder class="org.openpnp.machine.reference.feeder.ReferenceStripFeeder" id="2597a4ca-abe9-4c9d-8261-5591ca9dc6fe" name="R0805-5" enabled="true" part-id="R0805-1K" tape-type="WhitePaper" vision-enabled="true" feed-count="0">
            <location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
            <reference-hole-location units="Millimeters" x="184.199" y="55.074" z="0.0" rotation="0.0"/>
            <last-hole-location units="Millimeters" x="184.456" y="59.035" z="0.0" rotation="0.0"/>
            <part-pitch value="4.0" units="Millimeters"/>
            <tape-width value="8.0" units="Millimeters"/>
         </feeder>
      </feeders>
      <cameras>
         <camera class="org.openpnp.machine.reference.camera.OpenCvCamera" id="dfa4d108-4e08-4227-8e56-c233248cbd89" name="OpenCvCamera" looking="Up" settle-time-ms="250" rotation="0.0" flip-x="false" flip-y="false" offset-x="0" offset-y="0" device-index="0" preferred-width="0" preferred-height="0">
            <units-per-pixel units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
            <vision-provider class="org.openpnp.machine.reference.vision.OpenCvVisionProvider"/>
            <head-offsets units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
            <safe-z value="0.0" units="Millimeters"/>
            <calibration enabled="false">
               <camera-matrix length="9">3.18299368645E-313, 1.89608146E-315, 1.4E-322, 0.0, 6.364138617905435E-66, 4.46835643435405E-310, 3.18299368645E-313, 7.175787989480809E139, 1.9153200321625E-310</camera-matrix>
               <distortion-coefficients length="5">3.18299368645E-313, 0.0, 1.0E-322, 0.0, 0.0</distortion-coefficients>
            </calibration>
         </camera>
      </cameras>
      <actuators/>
      <job-processors class="java.util.HashMap">
         <job-processor type="PickAndPlace">
            <job-processor class="org.openpnp.machine.reference.ReferenceJobProcessor" demo-mode="false">
               <job-planner class="org.openpnp.planner.SimpleJobPlanner"/>
            </job-processor>
         </job-processor>
      </job-processors>
      <part-alignment class="org.openpnp.machine.reference.vision.ReferenceBottomVision" enabled="true">
         <pipeline>
            <stages>
               <cv-stage class="org.openpnp.vision.pipeline.stages.ImageCapture" name="0" enabled="true" settle-first="true"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.ImageWriteDebug" name="13" enabled="true" prefix="bv_source_" suffix=".png"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.BlurGaussian" name="10" enabled="true" kernel-size="9"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.MaskCircle" name="4" enabled="true" diameter="525"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.ConvertColor" name="1" enabled="true" conversion="Bgr2HsvFull"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.MaskHsv" name="2" enabled="true" hue-min="60" hue-max="130" saturation-min="0" saturation-max="255" value-min="0" value-max="255"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.ConvertColor" name="3" enabled="true" conversion="Hsv2BgrFull"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.ConvertColor" name="6" enabled="true" conversion="Bgr2Gray"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.Threshold" name="12" enabled="true" threshold="100" auto="false" invert="false"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.FindContours" name="5" enabled="true" retrieval-mode="List" approximation-method="None"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.FilterContours" name="9" enabled="true" contours-stage-name="5" min-area="50.0" max-area="900000.0"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.MaskCircle" name="11" enabled="true" diameter="0"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.DrawContours" name="7" enabled="true" contours-stage-name="9" thickness="2" index="-1">
                  <color r="255" g="255" b="255" a="255"/>
               </cv-stage>
               <cv-stage class="org.openpnp.vision.pipeline.stages.MinAreaRect" name="result" enabled="true" threshold-min="100" threshold-max="255"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.ImageRecall" name="14" enabled="true" image-stage-name="0"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.DrawRotatedRects" name="8" enabled="true" rotated-rects-stage-name="result" thickness="2"/>
               <cv-stage class="org.openpnp.vision.pipeline.stages.ImageWriteDebug" name="15" enabled="true" prefix="bv_result_" suffix=".png"/>
            </stages>
         </pipeline>
         <part-settings-by-part-id class="java.util.HashMap"/>
      </part-alignment>
      <fiducial-locator class="org.openpnp.machine.reference.vision.ReferenceFiducialLocator"/>
      <discard-location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
      <driver class="org.openpnp.machine.reference.driver.TinygDriver" port-name="COM4" baud="115200" feed-rate-mm-per-minute="5000.0">
         <home-location units="Millimeters" x="0.0" y="0.0" z="0.0" rotation="0.0"/>
      </driver>
   </machine>
</openpnp-machine>

Jason von Nieda

unread,
May 11, 2016, 2:37:37 AM5/11/16
to ope...@googlegroups.com
Looks like you have the same device-index set for both cameras. The device-index is what chooses which camera in the system will be displayed. Typically they are ordered from 0 through however many cameras are attached. If you change this to 1 for either camera (and leave the other 0) it should work.

Screen Shot 2016-05-10 at 11.36.16 PM.png

Jason


--
You received this message because you are subscribed to the Google Groups "OpenPnP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openpnp+u...@googlegroups.com.
To post to this group, send email to ope...@googlegroups.com.

Oz-Ron

unread,
May 11, 2016, 3:40:58 AM5/11/16
to OpenPnP
G'Day,
 
I ran into this problem too.

The solution:
Go to Cameras Tab & Select the UP Camera,  Select Camera Specific, Scroll down and you will see the Device Index.  Increment that to 1 from 0.

Worked for me.

Good luck,
Ron 

obiwanke...@gmail.com

unread,
May 11, 2016, 10:39:49 AM5/11/16
to OpenPnP
Thanks, that was it !

alex

unread,
May 20, 2016, 5:15:09 PM5/20/16
to OpenPnP


Just one image about bottom vision:


This is a test job with 100 0603 resistors. Top one without bottom vision, bottom one with bottom vision enabled.
The result without bottom vision could be a bit better if I setup a feeder more accurately. But due to lack of feeder setup this job run was a great test for bottom vision system and it definitely passed it.
here is a small video of this job: https://www.youtube.com/watch?v=-CnZq6fosFU

понедельник, 25 апреля 2016 г., 7:00:08 UTC+3 пользователь Jason von Nieda написал:
Hi folks,

I'm very excited to announce that the first version of OpenPnP's bottom vision module has been released. This feature has been in development for a very long time and I'm really excited for it to finally see the light of day!

Bottom vision, in essence, uses computer vision and an upward looking camera to improve your placement results. You can read more about it here:

This module is brand new and will probably require a few more iterations before it's very reliable. That being said, I am getting great results with it already and I hope it will be a big help on your machines too.

The feature is now in the develop branch and you can either update your code or download the Develop releases from http://openpnp.org/downloads/

There is a lot more info to come on this huge feature, and lots of documentation to be written, but I wanted to get this out there so people can start playing with it.

With Bottom Vision comes a number of smaller but also important changes. I've been documenting those here:

So, please give it a try and let me know what you think. All feedback is welcome and encouraged!

Thanks,
Jason


Michael Anton

unread,
May 20, 2016, 6:23:35 PM5/20/16
to OpenPnP
Very nice!!

Anthony Webb

unread,
May 20, 2016, 8:27:21 PM5/20/16
to ope...@googlegroups.com
Nice visual on the value of bottom vision.  Kudos to Jason for pulling this off, simply awesome!

--
You received this message because you are subscribed to the Google Groups "OpenPnP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openpnp+u...@googlegroups.com.
To post to this group, send email to ope...@googlegroups.com.

Jason von Nieda

unread,
May 20, 2016, 9:11:58 PM5/20/16
to ope...@googlegroups.com
Alex, this is an awesome image! Did you do this with openpnp? What a great demonstration!

Jason

alex

unread,
May 20, 2016, 9:22:21 PM5/20/16
to OpenPnP
Yes, of course this is openpnp!

The only thing that was changed between the jobs is "enable vision" option and board location to run the same board in another place.

Andrew Frazer

unread,
May 21, 2016, 2:07:01 AM5/21/16
to OpenPnP
This is very cool.


AS a guide line, how big an image do we need for bottom vision to work properly?

Jason von Nieda

unread,
May 21, 2016, 11:33:09 AM5/21/16
to OpenPnP
You just need to be able to fit your largest part into the frame, in focus.

Message has been deleted

Jason von Nieda

unread,
May 22, 2016, 9:51:14 PM5/22/16
to OpenPnP
I'm not sure on pixels yet. I will try to get some numbers soon. For reference, I have my camera masked down to 600x600 pixels and a TQFP100 is slightly too large for that.

To try to control the motor, check out https://itunes.apple.com/us/app/webcam-settings/id533696630?mt=12. This is able to control the focus of my ELP cameras.

Jason


On Sat, May 21, 2016 at 1:35 PM Andrew Frazer <andrew...@stellascapes.com> wrote:
The in focus,  is achievable.   How many pixels do you think  is needed?

Also do you have drivers for the ULP Cameras?  The vari-focus one i have has a motor on the lenses, its wired up, but i cant' for the life of me control it.  
On plugging them into my macbook,  they just auto-deteced and worked, but seem featureless.



Andrew Frazer

unread,
May 23, 2016, 5:28:42 PM5/23/16
to OpenPnP
Thanks for the pointer to the app. Thats handy.. I've discovered that the "vari-focal" lenses i have which i thought was machine controllable is not.. The thing on the base of it is an IR cut.

The 5MB autofocus one, is maually focusable..      Opticaly, the 2MB ones with the zoom, look like they might be a better choice for bottom cameras.. If i put two side by side, i'll be able to set one quite narrow ( good for small parts ) and get another setup wider ( better for larger parts ).. 

For downfacing i think i'm going to need something different..

This project has a lot more to it than i ever though!

Lisandro B

unread,
Jun 9, 2016, 8:20:30 PM6/9/16
to OpenPnP
What may I have uncorrectly configured, that bottom vision correctly identifies the part contour but it doesn't  center the part to t


Auto Generated Inline Image 1

Jason von Nieda

unread,
Jun 9, 2016, 8:32:18 PM6/9/16
to OpenPnP
Lisandro,

It's tough to say from the image. Does the head move after imaging the part? It should do something like:

1. Move the nozzle to the center of the camera.
2. Image and recognize the part.
3. Move the part to the center of the image.

If you are seeing a movement at step 3 but it's moving the wrong direction then I'd guess your camera needs to be flipped. You can do this in the camera settings.

One way to check that your camera geometry is correct is to move the nozzle over the camera and then jog it in each direction. The camera should move in the following ways:

X+ camera moves right
X- camera moves left
Y+ camera moves towards top of frame
Y- camera moves towards bottom of frame

Jason


On Thu, Jun 9, 2016 at 5:20 PM 'Lisandro B' via OpenPnP <ope...@googlegroups.com> wrote:
What may I have uncorrectly configured, that bottom vision correctly identifies the part contour but it doesn't  center the part to t


--
You received this message because you are subscribed to the Google Groups "OpenPnP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openpnp+u...@googlegroups.com.
To post to this group, send email to ope...@googlegroups.com.

Lisandro B

unread,
Jun 9, 2016, 8:45:19 PM6/9/16
to OpenPnP
For step 3, it only makes a small rotation.
It got me confused the fact that it
seems to be recognizing the part correctly

Jason von Nieda

unread,
Jun 9, 2016, 8:48:49 PM6/9/16
to OpenPnP
Lisandro,

That's very strange. Try turning on debug logging and send the log results. It should include information about what is found, including the offsets, and this should tell us if everything is working as expected: https://github.com/openpnp/openpnp/wiki/Bottom-Vision#how-do-i-see-debug-images. Look for a log line called "Final offsets".

Jason


--
You received this message because you are subscribed to the Google Groups "OpenPnP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openpnp+u...@googlegroups.com.
To post to this group, send email to ope...@googlegroups.com.

Михаил Юров

unread,
Jun 10, 2016, 1:11:37 AM6/10/16
to OpenPnP

I think the problem is that the machine has to play (backlash / slack).

It would be cool if Jason add backlash compensation to the program.
Perhaps this can be done with the GCodeDriver, but I have not tried. (move to X - 0,5 мм, Y - 0,5 мм, and then move to the destination point X, Y).

My SMD machine also has a small gap (about 0.1 mm).
I bought a linear encoders in China to fix backlash in my machine.

To use linear encoders require a controller. I'm going to make a very inexpensive version of this controller.

Lisandro B

unread,
Jun 10, 2016, 10:02:10 AM6/10/16
to OpenPnP
Closing the loop it's not done at software (openpnp) level, but at the controler, don't know if smoothie supports it

Михаил Юров

unread,
Jun 10, 2016, 11:03:20 AM6/10/16
to OpenPnP
I'm projecting a controller for linear scale (and rotation encoder).
But if the motor drivers are integrated into the controller board - then not be able to connect my closed loop controller.

пятница, 10 июня 2016 г., 19:02:10 UTC+5 пользователь Lisandro B написал:
Reply all
Reply to author
Forward
0 new messages