You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

78 lines
6.6 KiB

\documentclass[11pt]{article}
\usepackage{graphicx}
\usepackage{caption} % for \captionof
%Gummi|065|=)
\title{\textbf{ZMHW Project: Map}}
\author{Steak Electronics}
\date{11/2018 - 1/2019}
\begin{document}
%\maketitle
\maketitle
\tableofcontents
\section{Overview}
ZMHW Map is a device to generate a type of heat map, or map whereby you can visually see where on your property alarms are occuring. It does this by connecting to the Zoneminder server\footnote{Via zmtrigger.pl}, and lighting LEDs on a PCB, with a CAD layout of your property on the PCB. By lighting certain LEDs that correspond to an alarm (with either motion, or better $\rightarrow$ hardware detection. See ZMHW Motion Detector \footnote{https://git.steakelectronics.com/adminguy/ZMHWProject}).
ZMHW Map is built as an Arduino sketch around the common Arduino Mega 2560, with a PCB layout (gerber files) that you can have fabbed\footnote{Fabbing can be done in the US within a span of about two weeks from purchase to delivery for a low price at MakerBright aka https://pcbs.io in Florida or OSH Park, https://oshpark.com based in Oregon. Users can also use overseas PCB services - see https://pcbshopper.com}. Minimal experience with a soldering iron is required. The current layout allows for up to 45 alarms to be set. As not all alarms will be active at any given time, each LED is set to output at 5mA, and should be within the 100-200mA output pin limit of the atmega 2560.
\begin{center}
\includegraphics[scale=0.8]{../pics/absolutemaximum.jpg}
\captionof{figure}{Atmega2560 Maximums}
\end{center}
\section{PCB Revision 1}
Upon Building the first rev, I noticed a few things that I've found important with the other shields I've been making with the ENC28J60. First off, I want the ENC to be upside down, so that it fits snug between the Mega USB and Barrel plug. The ENC module is sold with male pin headers (not female) so it's a matter of placing it and soldering. However, I didn't realize how well it fit until I made the first shield of ZMHW Motion Sensor, so I hadn't yet flipped the pins. Rev2 will have the ENC upside down. The 5x2 pins are enough to hold it in place. Ideally, a custom enclosure would add additional support.
\begin{center}
\includegraphics[scale=0.5]{../pics/DSCN0974.JPG}
\captionof{figure}{Board assembled with ENC, speaker, and pre-wired LEDs}
\end{center}
\subsection{Troubleshooting the board:}
In this type of shield (NOTE that this won't be required in later revisions. This is one of the reasons, I flipped the ENC), where you must cut off the old ENC 0.1" headers, there is a trick to getting them off without damaging the module. You must cut each pair of headers at the plastic part (don't cut the actual pins) with a pair of flush cut pliers, then desolder each pair off. I accidentally pulled a pad when doing this, and found the error with a microscope.
\begin{center}
\includegraphics[scale=0.3]{../pics/DSCN0966.JPG}
\captionof{figure}{Cut plastic part off in pairs, then desolder. OR, design your board so you don't have to remove the pin headers!}
\end{center}
\begin{center}
\includegraphics[scale=0.3]{../pics/DSCN0976.JPG}
\captionof{figure}{If you are going to be soldering high gauge magnet wire, you should use a microscope. It makes the process much more enjoyable, and efficient.}
\end{center}
\subsection{Build Considerations}
After I built this up, I realized that it was quite laborious to do soldering for the LEDs. The original idea was to buy a canvas print with an image of the property, and put LEDs through the canvas to alight where alarms were found. However, that would mean I might have to soldering wires for 30 LEDs (if you have 30 monitors), which is a slow, slow process. Instead, since I have already made PCBs of fairly large sizes, I will put the business property map on a PCB as the silk screen layer, and connect the board directly to the shield. I won't use a cable, as cables are an additional BOM item, and setup required, which is mentioned on the Amp Hour podcast (270 or so).
As for the option of using a shield with 30 wired LEDs vs. a large PCB, I've weighed the options of each. While the 30 wired LEDs may be a 'better' solution, the labour involved outweighs the benefits, and instead a PCB is the more practical choice. I can make large PCBs and solder LEDs on a board much quicker than I can make 30 wired LEDs. I intend to make a type of picture frame for the board, and mount it behind glass, so dust doesn't collect on it. This means each property requires its own PCB, but the building PCB is a simple one to make.
\section{PCB - Revision 2}
PCB Revision 2 was made, and while it works there were some caveats. First, I accidentally made my business property maps to start at the opposite end of the 50 Pin header than the main board. Oops. Second, the ENC pins were not placed correctly. Otherwise, I was able to hack around and get 1 prototype working, but I'll go to revision 3 to eliminate these issues. I also tested a PCB that was white, and a black PCB. While I've only actually lit lights on the white PCB, I think I prefer the black for this application.
\begin{center}
\includegraphics[scale=1.5]{../pics/DSCN1150.JPG}
\captionof{figure}{Revision 2 build, with Map PCB}
\end{center}
\vspace{0.2in}
On the plus side, the software code, which I had already made, is working without issue (in my short time testing) and overall, I am pleased with how the map works. It's a tool, and it gets the job done. You can quickly get an overview of where people are on your property. If you were to try to do this without the map, it would necessitate reviewing each camera stream, which means perhaps, 10-30 seconds. The map is more efficient. This is a new avenue of Zoneminder that isn't addressed currently. In addition, the random nature of the alarms going off, means that the map is always lighting up a new pattern of lights.
\begin{center}
\includegraphics[scale=0.8]{../pics/bottomrev3.png}
\captionof{figure}{Revision 3 Back}
\end{center}
\vspace{0.2in}
\section{PCB - Revision 3 Layout}
On this PCB revision I did the following things:
\begin{itemize}
\item Flipped IO to start at the right side, instead of the left
\item Fixed error with ENC28J60 Pins
\item Added screw terminal for external RESET button
\item Added picture to back
\end{itemize}
One thing I would like to do for the next revision: When I shortened the length of the MEGA footprint, I removed some pins, and RESET is one of the pins removed. I'd like to reinstate it. I'd also like to remove the silkscreen outline of the mega on the footprint.
\subsection{PCB - Revision 3 Build}
This revision works 100\%. That is good. The bad thing is:
\end{document}