diff --git a/tikz/cmos-sram-cell/Makefile b/tikz/cmos-sram-cell/Makefile new file mode 100644 index 0000000..93dc057 --- /dev/null +++ b/tikz/cmos-sram-cell/Makefile @@ -0,0 +1,35 @@ +SOURCE = cmos-sram-cell +DELAY = 80 +DENSITY = 300 +WIDTH = 512 + +make: + pdflatex $(SOURCE).tex -output-format=pdf + make clean + +clean: + rm -rf $(TARGET) *.class *.html *.log *.aux *.data *.gnuplot + +gif: + pdfcrop $(SOURCE).pdf + convert -verbose -delay $(DELAY) -loop 0 -density $(DENSITY) $(SOURCE)-crop.pdf $(SOURCE).gif + make clean + +png: + make + make svg + inkscape $(SOURCE).svg -w $(WIDTH) --export-png=$(SOURCE).png + +transparentGif: + convert $(SOURCE).pdf -transparent white result.gif + make clean + +svg: + make + #inkscape $(SOURCE).pdf --export-plain-svg=$(SOURCE).svg + pdf2svg $(SOURCE).pdf $(SOURCE).svg + # Necessary, as pdf2svg does not always create valid svgs: + inkscape $(SOURCE).svg --export-plain-svg=$(SOURCE).svg + rsvg-convert -a -w $(WIDTH) -f svg $(SOURCE).svg -o $(SOURCE)2.svg + inkscape $(SOURCE)2.svg --export-plain-svg=$(SOURCE).svg + rm $(SOURCE)2.svg diff --git a/tikz/cmos-sram-cell/cmos-sram-cell.png b/tikz/cmos-sram-cell/cmos-sram-cell.png new file mode 100644 index 0000000..d9b3c65 Binary files /dev/null and b/tikz/cmos-sram-cell/cmos-sram-cell.png differ diff --git a/tikz/cmos-sram-cell/cmos-sram-cell.tex b/tikz/cmos-sram-cell/cmos-sram-cell.tex new file mode 100644 index 0000000..4584bb4 --- /dev/null +++ b/tikz/cmos-sram-cell/cmos-sram-cell.tex @@ -0,0 +1,107 @@ +\documentclass{article} +\usepackage[pdftex,active,tightpage]{preview} +\setlength\PreviewBorder{2mm} +\usepackage{tikz} +\usetikzlibrary{arrows, calc, positioning,decorations.pathreplacing,shapes} + +\begin{document} +\begin{preview} +\begin{tikzpicture}[scale=0.5] + \coordinate (A) at (0,1); + \coordinate (B1) at (1,0); + \coordinate (B2) at (15,0); + \draw (A) -- (16,1); + \draw (B1) -- (1,16); + \draw (B2) -- (15,16); + % to transistors T4 and T5 + \draw (3,1) -- (3,7); + \draw (13,1) -- (13,7); + % transistors T4 and T5 + \draw ( 2,7) -- ( 4,7); + \draw (12,7) -- (14,7); + \draw[dashed] ( 2,7.25) -- ( 4,7.25); + \draw[dashed] (12,7.25) -- (14,7.25); + + \draw ( 2.5,7.25) -- ( 2.5, 7.5); % T5 - tiny to top + \draw ( 3.5,7.25) -- ( 3.5, 7.5); % T5 - tiny to top + \draw ( 2.5, 7.5) -- ( 1, 7.5); % T5 - to left + \draw ( 3.5, 7.5) -- ( 7, 7.5); % T5 - to right + \draw[-latex] ( 3, 8) -- ( 3, 7.25 ); % T5 - Gate + \draw[fill=black] (1,7.5) circle (0.1); % T5- dot + + \draw (12.5,7.25) -- (12.5, 7.5); % T4 - tiny to top + \draw (13.5,7.25) -- (13.5, 7.5); % T4 - tiny to top + \draw (12.5, 7.5) -- (9.0, 7.5); % T4 - to left + \draw (13.5, 7.5) -- (15.0, 7.5); % T4 - to right + \draw[-latex] ( 13, 8) -- ( 13, 7.25 ); % T4 - Gate + \draw[fill=black] (15,7.5) circle (0.1); % T4- dot + + % center - left part + \draw (5,4) -- (5,5); % line to top + \draw (5,6) -- (5,10); % line to top + \draw (5,11) -- (5,12); % line to top + \draw (5,5) -- (5.25,5); % T1 - right + \draw (5,6) -- (5.25,6); % T1 - right + \draw (5,10) -- (5.25,10); % T3 - right + \draw (5,11) -- (5.25,11); % T3 - right + \draw[dashed] (5.25,4.5) -- (5.25, 6.5); % T1 + \draw (5.50,4.5) -- (5.50, 6.5); % T1 + \draw[dashed] (5.25,9.5) -- (5.25,11.5); % T3 + \draw (5.50,9.5) -- (5.50,11.5); % T3 + \draw[-latex] (4.5,5.5) -- (5.25, 5.5); % T1 - Gate + \draw[latex-] (4.5,10.5) -- (5.25,10.5); % T3 - Gate + \draw (5.5, 5.5) -- (7, 5.5); % T1 - rechts + \draw (5.5,10.5) -- (7,10.5); % T3 - rechts + \draw[fill=black] (5,7.5) circle (0.1); + \draw[fill=black] (7,7.5) circle (0.1); + + % center - right part + \draw (11,4) -- (11,5); % line to top + \draw (11,6) -- (11,10); % line to top + \draw (11,11) -- (11,12); % line to top + \draw (11,5) -- (10.75,5); % T0 - left + \draw (11,6) -- (10.75,6); % T0 - right + \draw (11,10) -- (10.75,10); % T2 - right + \draw (11,11) -- (10.75,11); % T2 - right + \draw[dashed] (10.75,4.5) -- (10.75, 6.5); % T0 + \draw (10.50,4.5) -- (10.50, 6.5); % T0 + \draw[dashed] (10.75,9.5) -- (10.75,11.5); % T2 + \draw (10.50,9.5) -- (10.50,11.5); % T2 + \draw[latex-] (10.75,5.5) -- (11.50, 5.5); % T0 - Gate + \draw[-latex] (10.75,10.5) -- (11.50,10.5); % T1 - Gate + \draw (10.5, 5.5) -- (9, 5.5); % T0 - rechts + \draw (10.5,10.5) -- (9,10.5); % T1 - rechts + \draw[fill=black] (11,7.5) circle (0.1); + \draw[fill=black] (9,7.5) circle (0.1); + + % bottom + \draw (5,4) -- (11,4); + \draw (8,4) -- (8,3); + \draw (7.25,3) -- (8.75,3); + \draw (7.5,2.75) -- (8.5,2.75); + + % top + \draw (5,12) -- (11,12); + \draw (8,12) -- (8,15); + \draw[fill=black] (8,12) circle (0.1); + + % middle + \draw (7,5.5) -- (9,7.5); + \draw (7,7.5) -- (9,5.5); + + \draw (7,10.5) -- (9,7.5); + \draw (7,7.5) -- (9,10.5); + + \node (T5-label) at (3.2,8.4){$T_5$}; + \node (T4-label) at (13.2,8.4){$T_4$}; + \node (T3-label) at (4,10.5){$T_3$}; + \node (T1-label) at (4,5.5){$T_1$}; + \node (T3-label) at (12,10.5){$T_2$}; + \node (T1-label) at (12,5.5){$T_0$}; + \node (A-label) [left=1ex of A] {$A$}; + \node (B1-label) [below=1ex of B1] {$B_1$}; + \node (B2-label) [below=1ex of B2] {$B_2$}; + \node (U-label) at (8,15.5) {$+U_B$}; +\end{tikzpicture} +\end{preview} +\end{document}