EXHIBIT 10(M)

                        RELEASE AND SETTLEMENT AGREEMENT

 This Release and Settlement Agreement (the "Agreement") is hereby entered into
   as of the 21st day of November, 2006 by and between the following parties:

                  A.   CompuDyne Corporation, including any of its predecessors,
successors, subsidiaries and present and former officers, directors, employees,
assigns, and persons acting on their behalf (collectively, "CompuDyne");
                  B.   William Blair Mezzanine Capital Fund II, L.P. including
any of its predecessors, successors, subsidiaries and present and former
officers, directors, employees, assigns, and persons acting on their behalf
(collectively, "Blair"); and
                  C.   Friedman, Billings, Ramsey Group, Inc., including any of
its predecessors, successors, subsidiaries and  present  and  former  officers,
directors, employees, assigns, and persons acting on their behalf (collectively,
"FBR")  (CompuDyne,  Blair and FBR are  collectively  referred  to herein as the
"Parties").
                  WHEREAS, on September 12, 2001, CompuDyne and FBR entered into
an agreement, which was amended on September 27, 2001, whereby FBR agreed to act
as  financial  advisor  and lead  underwriter  in  connection  with the  private
placement of two million  four  hundred  fifty  thousand  (2,450,000)  shares of
CompuDyne common stock (the "Offering");
                  WHEREAS,  CompuDyne and FBR have  expressed a desire to engage
in future  business  dealings and recognize that resolving the issues covered by
this Agreement will foster the ability to engage in future business dealings;
                  WHEREAS, the Parties do not admit that liability or wrongdoing
of any kind occurred in connection with the Offering.
                  WHEREAS,  the Parties mutually desire to enter into a full and
final  settlement  of all claims that the Parties  have or may have  against one
another,  from the  beginning of time to the date of this  Agreement,  including
without  limitation  any  and  all  claims  arising  out of or  relating  to the
Offering,  or arising out of or relating to FBR's  alleged  trading in shares of
CompuDyne common stock (CDCY);
                  NOW, THEREFORE, in consideration of mutual covenants contained
herein,  it is agreed by and between  the Parties as follows:
                  1.   FBR shall make the following payments to CompuDyne, for
the benefit of CompuDyne and Blair:
                       a.   FBR shall pay to CompuDyne  any amounts  directed to
be paid by FBR to CompuDyne and/or Blair pursuant to a settlement between FBR
and the United States Securities and Exchange Commission (the "SEC") in In the
Matter of Friedman, Billings, Ramsey & Co., Inc. (the "SEC Settlement"); and
                       b.   FBR shall pay to CompuDyne two million three hundred
thirty three thousand nine hundred fifty nine dollars ($2,333,959), within two
business days following the execution of this Agreement by all Parties, by wire
transfer pursuant to wiring instructions to be provided by CompuDyne.
                  2.   In the event that the total amount paid by FBR to
CompuDyne and/or Blair pursuant to Paragraph 1 of this Agreement is less than
four million five hundred thousand dollars ($4,500,000), FBR shall pay the
difference to CompuDyne at such time as the SEC-directed funds are paid to
CompuDyne,  by wire transfer pursuant to wiring instructions to be provided by
CompuDyne.
                  3.   In the event that the total amount paid by FBR to
CompuDyne and/or Blair pursuant to Paragraph 1 of this Agreement exceeds four
million five hundred thousand dollars ($4,500,000), CompuDyne and Blair agree to
deduct any amount paid in excess of four million five hundred thousand dollars


                                       65
<PAGE>

($4,500,000) from the amount paid to CompuDyne pursuant to Paragraph 1(b) of
this Agreement, and CompuDyne and Blair further agree to return  promptly such
excess amounts up to two million three hundred  thirty three thousand nine
hundred fifty nine dollars ($2,333,959) to FBR. Except as provided in this
paragraph, neither CompuDyne nor Blair shall have any obligation to pay any
amounts to FBR under this  Agreement.
                  4.   In the event the SEC determines not to require FBR to
make any payment to CompuDyne and/or Blair in In the Matter of Friedman,
Billings,  Ramsey & Co., Inc., within two business days of receiving such notice
from the SEC, FBR shall pay $2,166,041 to CompuDyne, by wire transfer pursuant
to wiring instructions to be provided by CompuDyne.
                  5.   The Parties hereby enter into the following releases:
                       a.   CompuDyne  and  Blair,   for  themselves,   their
predecessors, successors, insurers, attorneys and present and former agents,
servants, principals, directors, owners, officers, employees and assigns, hereby
fully, finally, and forever release and discharge FBR, from any and all claims,
rights, debts, liabilities, charges, losses, demands, acts, costs, attorneys'
fees, damages, suits, and causes of action of whatsoever kind, whether now known
or unknown and whether or not suspected or unsuspected,  contingent or fixed,
that CompuDyne and Blair now have or may have against FBR, from the beginning of
time through the date of this Agreement, including without limitation any and
all claims, rights, debts, liabilities, charges,  losses,  demands, acts, costs,
attorneys' fees, damages, suits, and causes of action arising out of or relating
to: (i) the  Offering; (ii) any  transaction(s)  in CompuDyne  securities  prior
to the date of this Agreement; or (iii) any other financial transaction related
to CompuDyne entered into prior to the date of this Agreement, provided however,
that:  (i) no release of FBR for any claim by CompuDyne  and/or Blair shall take
effect until after FBR has discharged its obligations to CompuDyne  and/or Blair
pursuant to the SEC  Settlement;  and (ii) this  release  shall have no force or
effect with respect to claims that Blair or CompuDyne  may have against  persons
other than FBR in connection with such person's  trading in CompuDyne  stock.
                       b.   FBR, for itself, its predecessors,  successors,
insurers,  attorneys  and  present  and  former  agents,  servants,  principals,
directors,  owners, officers,  employees and assigns, hereby fully, finally, and
forever  releases and  discharges  CompuDyne  and Blair from any and all claims,
rights, debts,  liabilities,  charges,  losses, demands, acts, costs, attorneys'
fees, damages, suits, and causes of action of whatsoever kind, whether now known
or unknown and whether or not  suspected or  unsuspected,  contingent  or fixed,
that FBR now has or may have against  CompuDyne and Blair, from the beginning of
time through the date of this Agreement,  including  without  limitation any and
all claims, rights, debts,  liabilities,  charges, losses, demands, acts, costs,
attorneys' fees, damages, suits, and causes of action arising out of or relating
to: (i) the Offering;  (ii) any transaction(s) in CompuDyne  securities prior to
the date of this Agreement;  or (iii) any other financial transaction related to
CompuDyne  entered into prior to the date of this Agreement,  provided  however,
that no release of CompuDyne and/or Blair for any claim by FBR shall take effect
until  after FBR has  discharged  its  obligations  to  CompuDyne  and/or  Blair
pursuant to the SEC  Settlement.
                  6.   From the date of this  Agreement  until the date the
releases  in  Paragraph  5 become  effective,  CompuDyne  and Blair agree not to
commence  any  litigation  against  FBR,  and FBR  agrees  not to  commence  any
litigation  against  CompuDyne  or  Blair,  arising  out of or  relating  to any
financial  transactions  related to CompuDyne  entered into prior to the date of
this Agreement,  including without  limitation any and all claims covered by the
releases in Paragraph 5.
                  7. Within two business days  following the execution of this
Agreement by all Parties,  FBR shall return,  or cause to be returned,  to
CompuDyne the 40,000 warrants,  which have no value, issued to FBR in connection
with its work on the  Offering.  Upon receipt of the warrants,  CompuDyne  shall
promptly cause the warrants to be cancelled.


                                       66
<PAGE>

                  8.   Any controversy or claim arising out of or relating  to
this  Agreement,   or  the  breach   thereof,   including  any  disputes  as  to
arbitrability,  shall  be  settled  by any  means  mutually  agreed  upon by the
Parties.  In the  absence  of  any  such  agreement,  it  shall  be  settled  by
arbitration in accordance with the Commercial  Arbitration Rules of the American
Arbitration Association, and judgment upon the award rendered by the arbitrators
may be  entered  in any  court  having  jurisdiction  thereof.
                       a.   The  place of arbitration  shall be  Washington,
D.C., and the arbitration  tribunal shall consist of three (3)  arbitrators,  of
whom one shall be  nominated  by each of the  parties  and the third,  who shall
serve as chairman, shall be chosen by the two party-nominated arbitrators or, in
the event the  party-nominated  arbitrators are unable or unwilling to designate
the third arbitrator,  by the American Arbitration Association.
                       b.   The award of the  arbitrators  shall be final and
binding. The Parties waive any right to appeal the arbitral award, to the extent
the right to appeal may be lawfully waived. Each Party retains the right to seek
judicial  assistance:  (i) to compel or aid arbitration;  (ii) to obtain interim
measures of protection pending arbitration, including equitable relief; or (iii)
to enforce any decision of the  arbitrators,  including the final award.
                  9.   Each of the Parties  represents and warrants that it has
read this Agreement and that it is authorized to enter into this Agreement. Each
Party represents that it has made such  investigation of the facts pertaining to
this   Agreement  as  they  deem  necessary  and  desirable  and  have  received
independent  legal and  business  advice  with  respect to the  advisability  of
executing this Agreement.
                  10.  This Agreement is final and binding and inures to the
benefit of each of the Parties  together with their  respective  successors,
transferees  and assigns.  No  modification  or waiver of any  provision of this
Agreement  is  effective  unless  agreed to, in writing,  by all of the affected
Parties.
                  11.  Any notice, demand, consent, approval, request, or  other
communication  required or permitted to be given  hereunder  shall be in writing
and delivered either  personally to the persons specified below, or by overnight
express mail, as follows:
                  If to CompuDyne or Blair:

                  Jeffrey A. Klafter, Esq.
                  Kurt B. Olsen, Esq.
                  Klafter & Olsen LLP
                  1250 Connecticut Avenue, N.W., Suite 200
                  Washington, D.C. 20036

                  If to the FBR:

                  Howard W. Gutman, Esq.
                  Steven M. Farina, Esq.
                  Williams & Connolly LLP
                  725 Twelfth Street, N.W.
                  Washington, D.C. 20005


                                       67
<PAGE>

                  Copy to:

                  William J. Ginivan
                  Chief Legal Officer
                  Friedman, Billings, Ramsey Group, Inc.
                  1001 Nineteenth Street North
                  Arlington, VA 22209

                  12.  This Agreement may be executed in identical counterparts.
Each  counterpart  hereof  is  deemed  to be an  original  instrument,  but  all
counterparts  hereof  taken  together  constitute a single  document.  Facsimile
signatures are deemed originals.
                  13.  The Parties agree to execute any and all documents
reasonably necessary to implement the terms and provisions of the Agreement. 14.
This Agreement was mutually  drafted and agreed upon and should not be construed
against any Party.
                  IN WITNESS  WHEREOF,  the  Parties  hereto  have  caused  this
Agreement   to  be   executed   by  each  of  them  or  their  duly   authorized
representatives as of the date first noted above.

                                 COMPUDYNE CORPORATION, by its Authorized Agent:


                                 /s/ Geoffrey F. Feidelberg
                                 -----------------------------------------------
                                 Printed Name:  Geoffrey F. Feidelberg
                                 Title: Chief Financial Officer


                                 WILLIAM BLAIR MEZZANINE CAPITAL FUND II, L.P.,
                                 by its Authorized Agent:


                                 /s/ Timothy J. MacKenze
                                 -----------------------------------------------
                                 Printed Name: Timothy J. MacKenze
                                 Title: Managing Director

                                 FRIEDMAN, BILLINGS, RAMSEY GROUP, INC.,
                                 by its Authorized Agent:


                                 /s/ William J. Ginivan
                                 -----------------------------------------------
                                 Printed Name:  William J. Ginivan
                                 Title: Chief Legal Officer


                                       68