1
                                                                  EXHIBIT 10.2




           AMENDMENT NO. 2 TO LOAN AND CREDIT AGREEMENT AND TERM NOTE


       This Amendment is made as of August 10, 1995, to the Loan and Credit
Agreement dated June 29, 1993, as amended by Amendment No. 1 to Loan and Credit
Agreement dated June 13, 1994 (as amended, the "Agreement"), among Medar, Inc.,
a Michigan corporation ("Medar"), Automatic Inspection Devices, Inc., an Ohio
corporation ("Automatic") and NBD Bank (successor to NBD Bank, N.A.), a
Michigan banking corporation (the "Bank").  This Amendment also amends the Term
Note dated June 29, 1993 ("Term Note") from Medar to the Bank in the original
principal amount of $2,500,000.


                                    RECITALS

       A.     The Bank has agreed to extend a revolving credit facility to
Medar, Automatic and Intergral Vision Ltd. pursuant to a Revolving Credit and
Loan Agreement being executed simultaneously herewith ("Revolving Credit
Agreement").  Such revolving credit facility replaces the prior authorizations
given to Medar and Automatic.

       B.     The Bank has also agreed to extend an equipment loan facility to
Medar and Automatic pursuant to the terms of the Revolving Credit Agreement.

       C.     Medar, Automatic and the Bank have agreed to amend the Agreement
to conform certain covenants of the parties to the Revolving Credit Agreement
and to amend the interest rate under the Term Note.

       THEREFORE, the parties agree as follows:

              1.     All capitalized terms not otherwise defined herein shall
                     have the meanings given to them in the Agreement.

              2.     The Term Note evidencing the indebtedness of Medar under
Facility A is hereby amended to delete the clause "of one fourth of one percent
(1/4%) per annum more than the rate" from the first paragraph of the Term Note
so that effective May 12, 1995, the Note Rate as defined in the Term Note will
be the Bank's prime rate as announced from time to time.

              3.     Facility D is terminated.

              4.     Sections 5.3(A), (B) and (C) are hereby deleted in their
entirety and replaced with the following:

       (A)    The Borrowers shall not violate Sections 6.2(a) or (b) of the
       Revolving Credit Agreement, as the same may be amended from time to
       time; or in the event that the Revolving Credit Agreement is restated or
       replaced by another agreement which provides a revolving credit facility
       to Medar or any of its affiliates, the Borrowers shall not violate any
       financial covenant in such replacement or restated
   2

       agreement; or in the event that there ceases to be any agreement between
       NBD and Medar or its affiliates for a revolving credit facility, the
       Borrowers shall not violate the financial covenants which were
       established by NBD in its agreement that was executed latest in time
       with Medar that provided for a revolving credit facility, regardless of
       the termination of such facility.

              5.     Except as expressly modified by this Amendment, the terms
of the Agreement and the Term Note are hereby ratified and confirmed and remain
in full force and effect.

              6.     In the event of an express conflict between the terms of
this Amendment and the Agreement or the Term Note, the terms of this Amendment
will govern and control.

       IN WITNESS WHEREOF, the parties have executed this Amendment as of the
10th day of August, 1995.

                                        MEDAR, INC.

                                        By: /s/ CHARLES DRAKE
                                            _____________________________
                                                Charles Drake 
                                                Its:  President


                                        AUTOMATIC INSPECTION DEVICES, INC.

                                        By: /s/ CHARLES DRAKE
                                            _____________________________
                                                Charles Drake 
                                                Its:  President


                                        NBD BANK

                                        By: /s/ JOSEPH KABOUREK
                                            _____________________________ 
                                                Joseph Kabourek 
                                                Its:  Vice President

                                        and

                                        By: /s/ GLENN ANSIEL
                                            _____________________________ 
                                                Glenn Ansiel 
                                                Its:  Loan Officer





                                      2