📄 trafficlight.bdf
字号:
/*
WARNING: Do NOT edit the input and output ports in this file in a text
editor if you plan to continue editing the block that represents it in
the Block Editor! File corruption is VERY likely to occur.
*/
/*
Copyright (C) 1991-2004 Altera Corporation
Any megafunction design, and related netlist (encrypted or decrypted),
support information, device programming or simulation file, and any other
associated documentation or information provided by Altera or a partner
under Altera's Megafunction Partnership Program may be used only
to program PLD devices (but not masked PLD devices) from Altera. Any
other use of such megafunction design, netlist, support information,
device programming or simulation file, or any other related documentation
or information is prohibited for any other purpose, including, but not
limited to modification, reverse engineering, de-compiling, or use with
any other silicon devices, unless such use is explicitly licensed under
a separate agreement with Altera or a megafunction partner. Title to the
intellectual property, including patents, copyrights, trademarks, trade
secrets, or maskworks, embodied in any such megafunction design, netlist,
support information, device programming or simulation file, or any other
related documentation or information provided by Altera or a megafunction
partner, remains with Altera, the megafunction partner, or their respective
licensors. No other licenses, including any licenses needed under any third
party's intellectual property, are provided herein.
*/
(header "graphic" (version "1.3"))
(pin
(input)
(rect 240 728 408 744)
(text "INPUT" (rect 133 0 161 9)(font "Arial" (font_size 6)))
(text "Reset" (rect 5 0 34 12)(font "Arial" ))
(pt 168 8)
(drawing
(line (pt 92 12)(pt 117 12)(line_width 1))
(line (pt 92 4)(pt 117 4)(line_width 1))
(line (pt 121 8)(pt 168 8)(line_width 1))
(line (pt 92 12)(pt 92 4)(line_width 1))
(line (pt 117 4)(pt 121 8)(line_width 1))
(line (pt 117 12)(pt 121 8)(line_width 1))
)
(text "VCC" (rect 136 7 156 17)(font "Arial" (font_size 6)))
)
(pin
(input)
(rect 240 752 408 768)
(text "INPUT" (rect 133 0 161 9)(font "Arial" (font_size 6)))
(text "SW" (rect 5 0 22 12)(font "Arial" ))
(pt 168 8)
(drawing
(line (pt 92 12)(pt 117 12)(line_width 1))
(line (pt 92 4)(pt 117 4)(line_width 1))
(line (pt 121 8)(pt 168 8)(line_width 1))
(line (pt 92 12)(pt 92 4)(line_width 1))
(line (pt 117 4)(pt 121 8)(line_width 1))
(line (pt 117 12)(pt 121 8)(line_width 1))
)
(text "VCC" (rect 136 7 156 17)(font "Arial" (font_size 6)))
)
(pin
(input)
(rect 240 776 408 792)
(text "INPUT" (rect 133 0 161 9)(font "Arial" (font_size 6)))
(text "CLK" (rect 5 0 26 12)(font "Arial" ))
(pt 168 8)
(drawing
(line (pt 92 12)(pt 117 12)(line_width 1))
(line (pt 92 4)(pt 117 4)(line_width 1))
(line (pt 121 8)(pt 168 8)(line_width 1))
(line (pt 92 12)(pt 92 4)(line_width 1))
(line (pt 117 4)(pt 121 8)(line_width 1))
(line (pt 117 12)(pt 121 8)(line_width 1))
)
(text "GND" (rect 136 7 157 17)(font "Arial" (font_size 6)))
)
(pin
(output)
(rect 784 656 960 672)
(text "OUTPUT" (rect 1 0 34 9)(font "Arial" (font_size 6)))
(text "Red1" (rect 90 0 115 12)(font "Arial" ))
(pt 0 8)
(drawing
(line (pt 0 8)(pt 52 8)(line_width 1))
(line (pt 52 4)(pt 78 4)(line_width 1))
(line (pt 52 12)(pt 78 12)(line_width 1))
(line (pt 52 12)(pt 52 4)(line_width 1))
(line (pt 78 4)(pt 82 8)(line_width 1))
(line (pt 82 8)(pt 78 12)(line_width 1))
(line (pt 78 12)(pt 82 8)(line_width 1))
)
)
(pin
(output)
(rect 784 672 960 688)
(text "OUTPUT" (rect 1 0 34 9)(font "Arial" (font_size 6)))
(text "Red2" (rect 90 0 115 12)(font "Arial" ))
(pt 0 8)
(drawing
(line (pt 0 8)(pt 52 8)(line_width 1))
(line (pt 52 4)(pt 78 4)(line_width 1))
(line (pt 52 12)(pt 78 12)(line_width 1))
(line (pt 52 12)(pt 52 4)(line_width 1))
(line (pt 78 4)(pt 82 8)(line_width 1))
(line (pt 82 8)(pt 78 12)(line_width 1))
(line (pt 78 12)(pt 82 8)(line_width 1))
)
)
(pin
(output)
(rect 784 688 960 704)
(text "OUTPUT" (rect 1 0 34 9)(font "Arial" (font_size 6)))
(text "Yellow1" (rect 90 0 127 12)(font "Arial" ))
(pt 0 8)
(drawing
(line (pt 0 8)(pt 52 8)(line_width 1))
(line (pt 52 4)(pt 78 4)(line_width 1))
(line (pt 52 12)(pt 78 12)(line_width 1))
(line (pt 52 12)(pt 52 4)(line_width 1))
(line (pt 78 4)(pt 82 8)(line_width 1))
(line (pt 82 8)(pt 78 12)(line_width 1))
(line (pt 78 12)(pt 82 8)(line_width 1))
)
)
(pin
(output)
(rect 784 704 960 720)
(text "OUTPUT" (rect 1 0 34 9)(font "Arial" (font_size 6)))
(text "Yellow2" (rect 90 0 127 12)(font "Arial" ))
(pt 0 8)
(drawing
(line (pt 0 8)(pt 52 8)(line_width 1))
(line (pt 52 4)(pt 78 4)(line_width 1))
(line (pt 52 12)(pt 78 12)(line_width 1))
(line (pt 52 12)(pt 52 4)(line_width 1))
(line (pt 78 4)(pt 82 8)(line_width 1))
(line (pt 82 8)(pt 78 12)(line_width 1))
(line (pt 78 12)(pt 82 8)(line_width 1))
)
)
(pin
(output)
(rect 784 720 960 736)
(text "OUTPUT" (rect 1 0 34 9)(font "Arial" (font_size 6)))
(text "Green1" (rect 90 0 125 12)(font "Arial" ))
(pt 0 8)
(drawing
(line (pt 0 8)(pt 52 8)(line_width 1))
(line (pt 52 4)(pt 78 4)(line_width 1))
(line (pt 52 12)(pt 78 12)(line_width 1))
(line (pt 52 12)(pt 52 4)(line_width 1))
(line (pt 78 4)(pt 82 8)(line_width 1))
(line (pt 82 8)(pt 78 12)(line_width 1))
(line (pt 78 12)(pt 82 8)(line_width 1))
)
)
(pin
(output)
(rect 784 736 960 752)
(text "OUTPUT" (rect 1 0 34 9)(font "Arial" (font_size 6)))
(text "Green2" (rect 90 0 125 12)(font "Arial" ))
(pt 0 8)
(drawing
(line (pt 0 8)(pt 52 8)(line_width 1))
(line (pt 52 4)(pt 78 4)(line_width 1))
(line (pt 52 12)(pt 78 12)(line_width 1))
(line (pt 52 12)(pt 52 4)(line_width 1))
(line (pt 78 4)(pt 82 8)(line_width 1))
(line (pt 82 8)(pt 78 12)(line_width 1))
(line (pt 78 12)(pt 82 8)(line_width 1))
)
)
(pin
(output)
(rect 784 760 960 776)
(text "OUTPUT" (rect 1 0 34 9)(font "Arial" (font_size 6)))
(text "SEG_Data[7..0]" (rect 90 0 167 12)(font "Arial" ))
(pt 0 8)
(drawing
(line (pt 0 8)(pt 52 8)(line_width 1))
(line (pt 52 4)(pt 78 4)(line_width 1))
(line (pt 52 12)(pt 78 12)(line_width 1))
(line (pt 52 12)(pt 52 4)(line_width 1))
(line (pt 78 4)(pt 82 8)(line_width 1))
(line (pt 82 8)(pt 78 12)(line_width 1))
(line (pt 78 12)(pt 82 8)(line_width 1))
)
)
(pin
(output)
(rect 784 776 960 792)
(text "OUTPUT" (rect 1 0 34 9)(font "Arial" (font_size 6)))
(text "SEG_Sel[1..0]" (rect 90 0 159 12)(font "Arial" ))
(pt 0 8)
(drawing
(line (pt 0 8)(pt 52 8)(line_width 1))
(line (pt 52 4)(pt 78 4)(line_width 1))
(line (pt 52 12)(pt 78 12)(line_width 1))
(line (pt 52 12)(pt 52 4)(line_width 1))
(line (pt 78 4)(pt 82 8)(line_width 1))
(line (pt 82 8)(pt 78 12)(line_width 1))
(line (pt 78 12)(pt 82 8)(line_width 1))
)
)
(symbol
(rect 736 160 912 288)
(text "datamux" (rect 5 0 47 12)(font "Arial" ))
(text "inst6" (rect 8 112 31 124)(font "Arial" ))
(port
(pt 0 32)
(input)
(text "D_IN3[3..0]" (rect 0 0 57 12)(font "Arial" ))
(text "D_IN3[3..0]" (rect 21 27 78 39)(font "Arial" ))
(line (pt 0 32)(pt 16 32)(line_width 3))
)
(port
(pt 0 48)
(input)
(text "D_IN2[3..0]" (rect 0 0 57 12)(font "Arial" ))
(text "D_IN2[3..0]" (rect 21 43 78 55)(font "Arial" ))
(line (pt 0 48)(pt 16 48)(line_width 3))
)
(port
(pt 0 64)
(input)
(text "D_IN1[3..0]" (rect 0 0 57 12)(font "Arial" ))
(text "D_IN1[3..0]" (rect 21 59 78 71)(font "Arial" ))
(line (pt 0 64)(pt 16 64)(line_width 3))
)
(port
(pt 0 80)
(input)
(text "D_IN0[3..0]" (rect 0 0 57 12)(font "Arial" ))
(text "D_IN0[3..0]" (rect 21 75 78 87)(font "Arial" ))
(line (pt 0 80)(pt 16 80)(line_width 3))
)
(port
(pt 0 96)
(input)
(text "SEL[1..0]" (rect 0 0 46 12)(font "Arial" ))
(text "SEL[1..0]" (rect 21 91 67 103)(font "Arial" ))
(line (pt 0 96)(pt 16 96)(line_width 3))
)
(port
(pt 176 32)
(output)
(text "D_OUT1[3..0]" (rect 0 0 68 12)(font "Arial" ))
(text "D_OUT1[3..0]" (rect 87 27 155 39)(font "Arial" ))
(line (pt 176 32)(pt 160 32)(line_width 3))
)
(port
(pt 176 48)
(output)
(text "D_OUT0[3..0]" (rect 0 0 68 12)(font "Arial" ))
(text "D_OUT0[3..0]" (rect 87 43 155 55)(font "Arial" ))
(line (pt 176 48)(pt 160 48)(line_width 3))
)
(drawing
(rectangle (rect 16 16 160 112)(line_width 1))
)
)
(symbol
(rect 752 312 928 408)
(text "dispmux" (rect 5 0 46 12)(font "Arial" ))
(text "inst8" (rect 8 80 31 92)(font "Arial" ))
(port
(pt 0 32)
(input)
(text "D_IN1[3..0]" (rect 0 0 57 12)(font "Arial" ))
(text "D_IN1[3..0]" (rect 21 27 78 39)(font "Arial" ))
(line (pt 0 32)(pt 16 32)(line_width 3))
)
(port
(pt 0 48)
(input)
(text "D_IN0[3..0]" (rect 0 0 57 12)(font "Arial" ))
(text "D_IN0[3..0]" (rect 21 43 78 55)(font "Arial" ))
(line (pt 0 48)(pt 16 48)(line_width 3))
)
(port
(pt 0 64)
(input)
(text "SEL[1..0]" (rect 0 0 46 12)(font "Arial" ))
(text "SEL[1..0]" (rect 21 59 67 71)(font "Arial" ))
(line (pt 0 64)(pt 16 64)(line_width 3))
)
(port
(pt 176 32)
(output)
(text "D_OUT[3..0]" (rect 0 0 62 12)(font "Arial" ))
(text "D_OUT[3..0]" (rect 93 27 155 39)(font "Arial" ))
(line (pt 176 32)(pt 160 32)(line_width 3))
)
(drawing
(rectangle (rect 16 16 160 80)(line_width 1))
)
)
(symbol
(rect 576 568 712 664)
(text "dispselect" (rect 5 0 54 12)(font "Arial" ))
(text "inst9" (rect 8 80 31 92)(font "Arial" ))
(port
(pt 0 32)
(input)
(text "CLK" (rect 0 0 21 12)(font "Arial" ))
(text "CLK" (rect 21 27 42 39)(font "Arial" ))
(line (pt 0 32)(pt 16 32)(line_width 1))
)
(port
(pt 136 32)
(output)
(text "D_OUT[1..0]" (rect 0 0 62 12)(font "Arial" ))
(text "D_OUT[1..0]" (rect 53 27 115 39)(font "Arial" ))
(line (pt 136 32)(pt 120 32)(line_width 3))
)
(drawing
(rectangle (rect 16 16 120 80)(line_width 1))
)
)
(symbol
(rect 336 328 480 424)
(text "countersel" (rect 89 0 139 12)(font "Arial" ))
(text "inst3" (rect 113 80 136 92)(font "Arial" ))
(port
(pt 144 32)
(input)
(text "D_IN[1..0]" (rect 0 0 51 12)(font "Arial" ))
(text "D_IN[1..0]" (rect 72 27 123 39)(font "Arial" ))
(line (pt 144 32)(pt 128 32)(line_width 3))
)
(port
(pt 0 32)
(output)
(text "D_OUT1" (rect 0 0 42 12)(font "Arial" ))
(text "D_OUT1" (rect 21 27 63 39)(font "Arial" ))
(line (pt 0 32)(pt 16 32)(line_width 1))
)
(port
(pt 0 48)
(output)
(text "D_OUT0" (rect 0 0 42 12)(font "Arial" ))
(text "D_OUT0" (rect 21 43 63 55)(font "Arial" ))
(line (pt 0 48)(pt 16 48)(line_width 1))
)
(drawing
(rectangle (rect 16 16 128 80)(line_width 1))
)
(flipy)
)
(symbol
(rect 440 568 560 664)
(text "fdiv1khz" (rect 5 0 47 12)(font "Arial" ))
(text "inst12" (rect 8 80 37 92)(font "Arial" ))
(port
(pt 0 32)
(input)
(text "clk_in" (rect 0 0 28 12)(font "Arial" ))
(text "clk_in" (rect 21 27 49 39)(font "Arial" ))
(line (pt 0 32)(pt 16 32)(line_width 1))
)
(port
(pt 120 32)
(output)
(text "clk_out" (rect 0 0 35 12)(font "Arial" ))
(text "clk_out" (rect 64 27 99 39)(font "Arial" ))
(line (pt 120 32)(pt 104 32)(line_width 1))
)
(drawing
(rectangle (rect 16 16 104 80)(line_width 1))
)
)
(symbol
(rect 296 568 416 664)
(text "fdiv1hz" (rect 79 0 115 12)(font "Arial" ))
(text "inst11" (rect 83 80 112 92)(font "Arial" ))
(port
(pt 120 32)
(input)
(text "clk_in" (rect 0 0 28 12)(font "Arial" ))
(text "clk_in" (rect 71 27 99 39)(font "Arial" ))
(line (pt 120 32)(pt 104 32)(line_width 1))
)
(port
(pt 0 32)
(output)
(text "clk_out" (rect 0 0 35 12)(font "Arial" ))
(text "clk_out" (rect 21 27 56 39)(font "Arial" ))
(line (pt 0 32)(pt 16 32)(line_width 1))
)
(drawing
(rectangle (rect 16 16 104 80)(line_width 1))
)
(flipy)
)
(symbol
(rect 832 424 928 608)
(text "dispdecoder" (rect 84 5 96 64)(font "Arial" )(vertical))
(text "inst7" (rect 4 8 16 31)(font "Arial" )(vertical))
(port
(pt 64 0)
(input)
(text "data_in[3..0]" (rect 0 0 61 12)(font "Arial" ))
(text "data_in[3..0]" (rect 57 21 69 82)(font "Arial" )(vertical))
(line (pt 64 0)(pt 64 16)(line_width 3))
)
(port
(pt 64 184)
(output)
(text "data_out[7..0]" (rect 0 0 68 12)(font "Arial" ))
(text "data_out[7..0]" (rect 57 95 69 163)(font "Arial" )(vertical))
(line (pt 64 184)(pt 64 168)(line_width 3))
)
(drawing
(rectangle (rect 16 16 80 168)(line_width 1))
)
(rotate270)
)
(symbol
(rect 344 440 488 536)
(text "scan" (rect 116 0 139 12)(font "Arial" ))
(text "inst" (rect 119 80 136 92)(font "Arial" ))
(port
(pt 144 32)
(input)
(text "EN_in1" (rect 0 0 35 12)(font "Arial" ))
(text "EN_in1" (rect 88 27 123 39)(font "Arial" ))
(line (pt 144 32)(pt 128 32)(line_width 1))
)
(port
(pt 144 48)
(input)
(text "EN_in0" (rect 0 0 35 12)(font "Arial" ))
(text "EN_in0" (rect 88 43 123 55)(font "Arial" ))
(line (pt 144 48)(pt 128 48)(line_width 1))
)
(port
(pt 0 32)
(output)
(text "sdata[1..0]" (rect 0 0 53 12)(font "Arial" ))
(text "sdata[1..0]" (rect 21 27 74 39)(font "Arial" ))
(line (pt 0 32)(pt 16 32)(line_width 3))
)
(drawing
(rectangle (rect 16 16 128 80)(line_width 1))
)
(flipy)
)
(symbol
(rect 528 384 672 544)
(text "control" (rect 5 0 38 12)(font "Arial" ))
(text "inst14" (rect 8 144 37 156)(font "Arial" ))
(port
(pt 0 32)
(input)
(text "EN_in[1..0]" (rect 0 0 55 12)(font "Arial" ))
(text "EN_in[1..0]" (rect 21 27 76 39)(font "Arial" ))
(line (pt 0 32)(pt 16 32)(line_width 3))
)
(port
(pt 0 48)
(input)
(text "SW1" (rect 0 0 23 12)(font "Arial" ))
(text "SW1" (rect 21 43 44 55)(font "Arial" ))
(line (pt 0 48)(pt 16 48)(line_width 1))
)
(port
(pt 0 64)
(input)
(text "RST" (rect 0 0 21 12)(font "Arial" ))
(text "RST" (rect 21 59 42 71)(font "Arial" ))
(line (pt 0 64)(pt 16 64)(line_width 1))
)
(port
(pt 144 32)
(output)
(text "Red1" (rect 0 0 25 12)(font "Arial" ))
(text "Red1" (rect 98 27 123 39)(font "Arial" ))
(line (pt 144 32)(pt 128 32)(line_width 1))
)
(port
(pt 144 48)
(output)
(text "Red2" (rect 0 0 25 12)(font "Arial" ))
(text "Red2" (rect 98 43 123 55)(font "Arial" ))
(line (pt 144 48)(pt 128 48)(line_width 1))
)
(port
(pt 144 64)
(output)
(text "Yellow1" (rect 0 0 37 12)(font "Arial" ))
(text "Yellow1" (rect 86 59 123 71)(font "Arial" ))
(line (pt 144 64)(pt 128 64)(line_width 1))
)
(port
(pt 144 80)
(output)
(text "Yellow2" (rect 0 0 37 12)(font "Arial" ))
(text "Yellow2" (rect 86 75 123 87)(font "Arial" ))
(line (pt 144 80)(pt 128 80)(line_width 1))
)
(port
(pt 144 96)
(output)
(text "Green1" (rect 0 0 35 12)(font "Arial" ))
(text "Green1" (rect 88 91 123 103)(font "Arial" ))
(line (pt 144 96)(pt 128 96)(line_width 1))
)
(port
(pt 144 112)
(output)
(text "Green2" (rect 0 0 35 12)(font "Arial" ))
(text "Green2" (rect 88 107 123 119)(font "Arial" ))
(line (pt 144 112)(pt 128 112)(line_width 1))
)
(drawing
(rectangle (rect 16 16 128 144)(line_width 1))
)
)
(symbol
(rect 336 112 496 208)
(text "counter05" (rect 5 0 53 12)(font "Arial" ))
(text "inst1" (rect 8 80 31 92)(font "Arial" ))
(port
(pt 0 32)
(input)
(text "C_CLK" (rect 0 0 35 12)(font "Arial" ))
(text "C_CLK" (rect 21 27 56 39)(font "Arial" ))
(line (pt 0 32)(pt 16 32)(line_width 1))
)
(port
(pt 0 48)
(input)
(text "RST" (rect 0 0 21 12)(font "Arial" ))
(text "RST" (rect 21 43 42 55)(font "Arial" ))
(line (pt 0 48)(pt 16 48)(line_width 1))
)
(port
(pt 0 64)
(input)
(text "C_EN" (rect 0 0 29 12)(font "Arial" ))
(text "C_EN" (rect 21 59 50 71)(font "Arial" ))
(line (pt 0 64)(pt 16 64)(line_width 1))
)
(port
(pt 160 32)
(output)
(text "C_out" (rect 0 0 29 12)(font "Arial" ))
(text "C_out" (rect 110 27 139 39)(font "Arial" ))
(line (pt 160 32)(pt 144 32)(line_width 1))
)
(port
(pt 160 48)
(output)
(text "D_OUT1[3..0]" (rect 0 0 68 12)(font "Arial" ))
(text "D_OUT1[3..0]" (rect 71 43 139 55)(font "Arial" ))
(line (pt 160 48)(pt 144 48)(line_width 3))
)
(port
(pt 160 64)
(output)
(text "D_OUT0[3..0]" (rect 0 0 68 12)(font "Arial" ))
(text "D_OUT0[3..0]" (rect 71 59 139 71)(font "Arial" ))
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -