summaryrefslogtreecommitdiff
path: root/graphics/circuit_macros/doc/FlipFlop.m4
blob: c04ca6ba896077a294bac460f9bcb5a2ed75bbf5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
.PS
# `FlipFlop.m4'
log_init
iflatex(`textoffset = 1bp__; ifpsfrag(,`latexcommand({\sf)') ')
s_init(Flipflop)
sinclude(Circuit_macros.dim)
right_
  { Q1: FlipFlop(D,Q1)
    s_box(``\tt FlipFlop(D,Q1)'') at last [].Chip.s below
    h1 = L_unit*20
    w1 = L_unit*12
    FlipFlop(T,Q2,ht h1 wid w1 fill_(0.9)) with .w at last [].e+(0.25,0)
    s_box(``\tt FlipFlop(T,Q2,ht h1 wid w1 fill\_(0.9))'') \
      at (last [].Chip,2nd last [].Chip.s)+(0,-0.25)
    FlipFlop(RS) with .w at last [].e+(0.25,0)
    s_box(``\tt FlipFlop(RS)'') at last [].Chip.s below
    FlipFlop(JK) with .w at last [].e+(0.25,0)
    s_box(``\tt FlipFlop(JK)'') with .n at last [].PinPR.end
    }
  move down 1.5; right_
  { FlipFlopX(,,:D;E:CK,,:Q;:lg_bartxt(Q))
    s_box(``\shortstack[l]{\tt FlipFlopX(,{,}\\
       \tt\quad:D;E:CK,{,}:Q;:lg\_bartxt(Q))}'') at last [].Chip.s below
    FlipFlopX(,,:T;E:CK,,:Q;) with .Chip.c at last [].e+(1.25,0)
    s_box(``\shortstack[l]{\tt FlipFlopX(,{,}\\
      \tt\quad:T;E:CK,{,}:Q;)}'') at last [].Chip.s below
    FlipFlopX(,,:J;E:CK;:K,N:CLR,:Q;) with .Chip.c at last [].e+(1.25,0)
    s_box(``\shortstack[l]{\tt FlipFlopX(,{,} \\
      \tt\quad:J;E:CK;:K,N:CLR,:Q;)}'') at last [].Chip.s below
    }
  iflatex(ifpsfrag(,`latexcommand(})'))
.PE