Добавил в проект модуль ШИМ (регистры согласно описанию в адресном пространстве). Подключил модуль к портам вводы/вывода, кроме внешнего error. Его пока завел на константу. В каждый цифровой фильтр добавил библиотечный элемент D-тригера (dff), тем самым сместив вправо еще на один такт все сигналы. Такую прошивку надо еще раз тестировать.
This commit is contained in:
parent
512359714c
commit
da0eef977c
File diff suppressed because it is too large
Load Diff
846
MainController/DigitalFilterBlock6.bdf
Normal file
846
MainController/DigitalFilterBlock6.bdf
Normal file
@ -0,0 +1,846 @@
|
||||
/*
|
||||
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-2013 Altera Corporation
|
||||
Your use of Altera Corporation's design tools, logic functions
|
||||
and other software and tools, and its AMPP partner logic
|
||||
functions, and any output files from any of the foregoing
|
||||
(including device programming or simulation files), and any
|
||||
associated documentation or information are expressly subject
|
||||
to the terms and conditions of the Altera Program License
|
||||
Subscription Agreement, Altera MegaCore Function License
|
||||
Agreement, or other applicable license agreement, including,
|
||||
without limitation, that your use is for the sole purpose of
|
||||
programming logic devices manufactured by Altera and sold by
|
||||
Altera or its authorized distributors. Please refer to the
|
||||
applicable agreement for further details.
|
||||
*/
|
||||
(header "graphic" (version "1.4"))
|
||||
(pin
|
||||
(input)
|
||||
(rect 128 208 296 224)
|
||||
(text "INPUT" (rect 125 0 153 10)(font "Arial" (font_size 6)))
|
||||
(text "clk" (rect 5 0 19 12)(font "Arial" ))
|
||||
(pt 168 8)
|
||||
(drawing
|
||||
(line (pt 84 12)(pt 109 12))
|
||||
(line (pt 84 4)(pt 109 4))
|
||||
(line (pt 113 8)(pt 168 8))
|
||||
(line (pt 84 12)(pt 84 4))
|
||||
(line (pt 109 4)(pt 113 8))
|
||||
(line (pt 109 12)(pt 113 8))
|
||||
)
|
||||
(text "VCC" (rect 128 7 148 17)(font "Arial" (font_size 6)))
|
||||
)
|
||||
(pin
|
||||
(input)
|
||||
(rect 128 280 296 296)
|
||||
(text "INPUT" (rect 125 0 153 10)(font "Arial" (font_size 6)))
|
||||
(text "d[5..0]" (rect 5 0 37 12)(font "Arial" ))
|
||||
(pt 168 8)
|
||||
(drawing
|
||||
(line (pt 84 12)(pt 109 12))
|
||||
(line (pt 84 4)(pt 109 4))
|
||||
(line (pt 113 8)(pt 168 8))
|
||||
(line (pt 84 12)(pt 84 4))
|
||||
(line (pt 109 4)(pt 113 8))
|
||||
(line (pt 109 12)(pt 113 8))
|
||||
)
|
||||
(text "VCC" (rect 128 7 148 17)(font "Arial" (font_size 6)))
|
||||
)
|
||||
(pin
|
||||
(output)
|
||||
(rect 1032 264 1208 280)
|
||||
(text "OUTPUT" (rect 1 0 39 10)(font "Arial" (font_size 6)))
|
||||
(text "q[5..0]" (rect 90 0 121 12)(font "Arial" ))
|
||||
(pt 0 8)
|
||||
(drawing
|
||||
(line (pt 0 8)(pt 52 8))
|
||||
(line (pt 52 4)(pt 78 4))
|
||||
(line (pt 52 12)(pt 78 12))
|
||||
(line (pt 52 12)(pt 52 4))
|
||||
(line (pt 78 4)(pt 82 8))
|
||||
(line (pt 82 8)(pt 78 12))
|
||||
(line (pt 78 12)(pt 82 8))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 544 264 608 344)
|
||||
(text "DFF" (rect 1 0 19 10)(font "Arial" (font_size 6)))
|
||||
(text "inst" (rect 3 68 20 80)(font "Arial" ))
|
||||
(port
|
||||
(pt 32 80)
|
||||
(input)
|
||||
(text "CLRN" (rect 21 59 44 71)(font "Courier New" (bold)))
|
||||
(text "CLRN" (rect 21 58 44 70)(font "Courier New" (bold)))
|
||||
(line (pt 32 80)(pt 32 76))
|
||||
)
|
||||
(port
|
||||
(pt 0 40)
|
||||
(input)
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(line (pt 0 40)(pt 12 40))
|
||||
)
|
||||
(port
|
||||
(pt 0 24)
|
||||
(input)
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(line (pt 0 24)(pt 12 24))
|
||||
)
|
||||
(port
|
||||
(pt 32 0)
|
||||
(input)
|
||||
(text "PRN" (rect 24 13 41 25)(font "Courier New" (bold)))
|
||||
(text "PRN" (rect 24 11 41 23)(font "Courier New" (bold)))
|
||||
(line (pt 32 4)(pt 32 0))
|
||||
)
|
||||
(port
|
||||
(pt 64 24)
|
||||
(output)
|
||||
(text "Q" (rect 45 20 50 32)(font "Courier New" (bold)))
|
||||
(text "Q" (rect 43 20 48 32)(font "Courier New" (bold)))
|
||||
(line (pt 52 24)(pt 64 24))
|
||||
)
|
||||
(drawing
|
||||
(line (pt 12 12)(pt 52 12))
|
||||
(line (pt 12 68)(pt 52 68))
|
||||
(line (pt 52 68)(pt 52 12))
|
||||
(line (pt 12 68)(pt 12 12))
|
||||
(line (pt 19 40)(pt 12 47))
|
||||
(line (pt 12 32)(pt 20 40))
|
||||
(circle (rect 28 4 36 12))
|
||||
(circle (rect 28 68 36 76))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 656 240 800 320)
|
||||
(text "DigitalFilter" (rect 5 0 60 12)(font "Arial" ))
|
||||
(text "inst2" (rect 8 64 31 76)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 14 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 35 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "input" (rect 0 0 23 12)(font "Arial" ))
|
||||
(text "input" (rect 21 43 44 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 144 32)
|
||||
(output)
|
||||
(text "output" (rect 0 0 30 12)(font "Arial" ))
|
||||
(text "output" (rect 98 27 128 39)(font "Arial" ))
|
||||
(line (pt 144 32)(pt 128 32))
|
||||
)
|
||||
(parameter
|
||||
"PHASE_SHIFT"
|
||||
"1"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 128 64))
|
||||
)
|
||||
(annotation_block (parameter)(rect 656 208 856 240))
|
||||
)
|
||||
(symbol
|
||||
(rect 544 384 608 464)
|
||||
(text "DFF" (rect 1 0 19 10)(font "Arial" (font_size 6)))
|
||||
(text "inst1" (rect 3 68 26 80)(font "Arial" ))
|
||||
(port
|
||||
(pt 32 80)
|
||||
(input)
|
||||
(text "CLRN" (rect 21 59 44 71)(font "Courier New" (bold)))
|
||||
(text "CLRN" (rect 21 58 44 70)(font "Courier New" (bold)))
|
||||
(line (pt 32 80)(pt 32 76))
|
||||
)
|
||||
(port
|
||||
(pt 0 40)
|
||||
(input)
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(line (pt 0 40)(pt 12 40))
|
||||
)
|
||||
(port
|
||||
(pt 0 24)
|
||||
(input)
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(line (pt 0 24)(pt 12 24))
|
||||
)
|
||||
(port
|
||||
(pt 32 0)
|
||||
(input)
|
||||
(text "PRN" (rect 24 13 41 25)(font "Courier New" (bold)))
|
||||
(text "PRN" (rect 24 11 41 23)(font "Courier New" (bold)))
|
||||
(line (pt 32 4)(pt 32 0))
|
||||
)
|
||||
(port
|
||||
(pt 64 24)
|
||||
(output)
|
||||
(text "Q" (rect 45 20 50 32)(font "Courier New" (bold)))
|
||||
(text "Q" (rect 43 20 48 32)(font "Courier New" (bold)))
|
||||
(line (pt 52 24)(pt 64 24))
|
||||
)
|
||||
(drawing
|
||||
(line (pt 12 12)(pt 52 12))
|
||||
(line (pt 12 68)(pt 52 68))
|
||||
(line (pt 52 68)(pt 52 12))
|
||||
(line (pt 12 68)(pt 12 12))
|
||||
(line (pt 19 40)(pt 12 47))
|
||||
(line (pt 12 32)(pt 20 40))
|
||||
(circle (rect 28 4 36 12))
|
||||
(circle (rect 28 68 36 76))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 544 504 608 584)
|
||||
(text "DFF" (rect 1 0 19 10)(font "Arial" (font_size 6)))
|
||||
(text "inst3" (rect 3 68 26 80)(font "Arial" ))
|
||||
(port
|
||||
(pt 32 80)
|
||||
(input)
|
||||
(text "CLRN" (rect 21 59 44 71)(font "Courier New" (bold)))
|
||||
(text "CLRN" (rect 21 58 44 70)(font "Courier New" (bold)))
|
||||
(line (pt 32 80)(pt 32 76))
|
||||
)
|
||||
(port
|
||||
(pt 0 40)
|
||||
(input)
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(line (pt 0 40)(pt 12 40))
|
||||
)
|
||||
(port
|
||||
(pt 0 24)
|
||||
(input)
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(line (pt 0 24)(pt 12 24))
|
||||
)
|
||||
(port
|
||||
(pt 32 0)
|
||||
(input)
|
||||
(text "PRN" (rect 24 13 41 25)(font "Courier New" (bold)))
|
||||
(text "PRN" (rect 24 11 41 23)(font "Courier New" (bold)))
|
||||
(line (pt 32 4)(pt 32 0))
|
||||
)
|
||||
(port
|
||||
(pt 64 24)
|
||||
(output)
|
||||
(text "Q" (rect 45 20 50 32)(font "Courier New" (bold)))
|
||||
(text "Q" (rect 43 20 48 32)(font "Courier New" (bold)))
|
||||
(line (pt 52 24)(pt 64 24))
|
||||
)
|
||||
(drawing
|
||||
(line (pt 12 12)(pt 52 12))
|
||||
(line (pt 12 68)(pt 52 68))
|
||||
(line (pt 52 68)(pt 52 12))
|
||||
(line (pt 12 68)(pt 12 12))
|
||||
(line (pt 19 40)(pt 12 47))
|
||||
(line (pt 12 32)(pt 20 40))
|
||||
(circle (rect 28 4 36 12))
|
||||
(circle (rect 28 68 36 76))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 544 624 608 704)
|
||||
(text "DFF" (rect 1 0 19 10)(font "Arial" (font_size 6)))
|
||||
(text "inst4" (rect 3 68 26 80)(font "Arial" ))
|
||||
(port
|
||||
(pt 32 80)
|
||||
(input)
|
||||
(text "CLRN" (rect 21 59 44 71)(font "Courier New" (bold)))
|
||||
(text "CLRN" (rect 21 58 44 70)(font "Courier New" (bold)))
|
||||
(line (pt 32 80)(pt 32 76))
|
||||
)
|
||||
(port
|
||||
(pt 0 40)
|
||||
(input)
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(line (pt 0 40)(pt 12 40))
|
||||
)
|
||||
(port
|
||||
(pt 0 24)
|
||||
(input)
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(line (pt 0 24)(pt 12 24))
|
||||
)
|
||||
(port
|
||||
(pt 32 0)
|
||||
(input)
|
||||
(text "PRN" (rect 24 13 41 25)(font "Courier New" (bold)))
|
||||
(text "PRN" (rect 24 11 41 23)(font "Courier New" (bold)))
|
||||
(line (pt 32 4)(pt 32 0))
|
||||
)
|
||||
(port
|
||||
(pt 64 24)
|
||||
(output)
|
||||
(text "Q" (rect 45 20 50 32)(font "Courier New" (bold)))
|
||||
(text "Q" (rect 43 20 48 32)(font "Courier New" (bold)))
|
||||
(line (pt 52 24)(pt 64 24))
|
||||
)
|
||||
(drawing
|
||||
(line (pt 12 12)(pt 52 12))
|
||||
(line (pt 12 68)(pt 52 68))
|
||||
(line (pt 52 68)(pt 52 12))
|
||||
(line (pt 12 68)(pt 12 12))
|
||||
(line (pt 19 40)(pt 12 47))
|
||||
(line (pt 12 32)(pt 20 40))
|
||||
(circle (rect 28 4 36 12))
|
||||
(circle (rect 28 68 36 76))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 544 744 608 824)
|
||||
(text "DFF" (rect 1 0 19 10)(font "Arial" (font_size 6)))
|
||||
(text "inst5" (rect 3 68 26 80)(font "Arial" ))
|
||||
(port
|
||||
(pt 32 80)
|
||||
(input)
|
||||
(text "CLRN" (rect 21 59 44 71)(font "Courier New" (bold)))
|
||||
(text "CLRN" (rect 21 58 44 70)(font "Courier New" (bold)))
|
||||
(line (pt 32 80)(pt 32 76))
|
||||
)
|
||||
(port
|
||||
(pt 0 40)
|
||||
(input)
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(line (pt 0 40)(pt 12 40))
|
||||
)
|
||||
(port
|
||||
(pt 0 24)
|
||||
(input)
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(line (pt 0 24)(pt 12 24))
|
||||
)
|
||||
(port
|
||||
(pt 32 0)
|
||||
(input)
|
||||
(text "PRN" (rect 24 13 41 25)(font "Courier New" (bold)))
|
||||
(text "PRN" (rect 24 11 41 23)(font "Courier New" (bold)))
|
||||
(line (pt 32 4)(pt 32 0))
|
||||
)
|
||||
(port
|
||||
(pt 64 24)
|
||||
(output)
|
||||
(text "Q" (rect 45 20 50 32)(font "Courier New" (bold)))
|
||||
(text "Q" (rect 43 20 48 32)(font "Courier New" (bold)))
|
||||
(line (pt 52 24)(pt 64 24))
|
||||
)
|
||||
(drawing
|
||||
(line (pt 12 12)(pt 52 12))
|
||||
(line (pt 12 68)(pt 52 68))
|
||||
(line (pt 52 68)(pt 52 12))
|
||||
(line (pt 12 68)(pt 12 12))
|
||||
(line (pt 19 40)(pt 12 47))
|
||||
(line (pt 12 32)(pt 20 40))
|
||||
(circle (rect 28 4 36 12))
|
||||
(circle (rect 28 68 36 76))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 544 864 608 944)
|
||||
(text "DFF" (rect 1 0 19 10)(font "Arial" (font_size 6)))
|
||||
(text "inst6" (rect 3 68 26 80)(font "Arial" ))
|
||||
(port
|
||||
(pt 32 80)
|
||||
(input)
|
||||
(text "CLRN" (rect 21 59 44 71)(font "Courier New" (bold)))
|
||||
(text "CLRN" (rect 21 58 44 70)(font "Courier New" (bold)))
|
||||
(line (pt 32 80)(pt 32 76))
|
||||
)
|
||||
(port
|
||||
(pt 0 40)
|
||||
(input)
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(line (pt 0 40)(pt 12 40))
|
||||
)
|
||||
(port
|
||||
(pt 0 24)
|
||||
(input)
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(line (pt 0 24)(pt 12 24))
|
||||
)
|
||||
(port
|
||||
(pt 32 0)
|
||||
(input)
|
||||
(text "PRN" (rect 24 13 41 25)(font "Courier New" (bold)))
|
||||
(text "PRN" (rect 24 11 41 23)(font "Courier New" (bold)))
|
||||
(line (pt 32 4)(pt 32 0))
|
||||
)
|
||||
(port
|
||||
(pt 64 24)
|
||||
(output)
|
||||
(text "Q" (rect 45 20 50 32)(font "Courier New" (bold)))
|
||||
(text "Q" (rect 43 20 48 32)(font "Courier New" (bold)))
|
||||
(line (pt 52 24)(pt 64 24))
|
||||
)
|
||||
(drawing
|
||||
(line (pt 12 12)(pt 52 12))
|
||||
(line (pt 12 68)(pt 52 68))
|
||||
(line (pt 52 68)(pt 52 12))
|
||||
(line (pt 12 68)(pt 12 12))
|
||||
(line (pt 19 40)(pt 12 47))
|
||||
(line (pt 12 32)(pt 20 40))
|
||||
(circle (rect 28 4 36 12))
|
||||
(circle (rect 28 68 36 76))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 656 360 800 440)
|
||||
(text "DigitalFilter" (rect 5 0 60 12)(font "Arial" ))
|
||||
(text "inst7" (rect 8 64 31 76)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 14 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 35 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "input" (rect 0 0 23 12)(font "Arial" ))
|
||||
(text "input" (rect 21 43 44 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 144 32)
|
||||
(output)
|
||||
(text "output" (rect 0 0 30 12)(font "Arial" ))
|
||||
(text "output" (rect 98 27 128 39)(font "Arial" ))
|
||||
(line (pt 144 32)(pt 128 32))
|
||||
)
|
||||
(parameter
|
||||
"PHASE_SHIFT"
|
||||
"1"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 128 64))
|
||||
)
|
||||
(annotation_block (parameter)(rect 656 328 856 360))
|
||||
)
|
||||
(symbol
|
||||
(rect 656 480 800 560)
|
||||
(text "DigitalFilter" (rect 5 0 60 12)(font "Arial" ))
|
||||
(text "inst8" (rect 8 64 31 76)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 14 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 35 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "input" (rect 0 0 23 12)(font "Arial" ))
|
||||
(text "input" (rect 21 43 44 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 144 32)
|
||||
(output)
|
||||
(text "output" (rect 0 0 30 12)(font "Arial" ))
|
||||
(text "output" (rect 98 27 128 39)(font "Arial" ))
|
||||
(line (pt 144 32)(pt 128 32))
|
||||
)
|
||||
(parameter
|
||||
"PHASE_SHIFT"
|
||||
"1"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 128 64))
|
||||
)
|
||||
(annotation_block (parameter)(rect 656 448 856 480))
|
||||
)
|
||||
(symbol
|
||||
(rect 656 600 800 680)
|
||||
(text "DigitalFilter" (rect 5 0 60 12)(font "Arial" ))
|
||||
(text "inst9" (rect 8 64 31 76)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 14 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 35 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "input" (rect 0 0 23 12)(font "Arial" ))
|
||||
(text "input" (rect 21 43 44 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 144 32)
|
||||
(output)
|
||||
(text "output" (rect 0 0 30 12)(font "Arial" ))
|
||||
(text "output" (rect 98 27 128 39)(font "Arial" ))
|
||||
(line (pt 144 32)(pt 128 32))
|
||||
)
|
||||
(parameter
|
||||
"PHASE_SHIFT"
|
||||
"1"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 128 64))
|
||||
)
|
||||
(annotation_block (parameter)(rect 656 568 856 600))
|
||||
)
|
||||
(symbol
|
||||
(rect 656 720 800 800)
|
||||
(text "DigitalFilter" (rect 5 0 60 12)(font "Arial" ))
|
||||
(text "inst10" (rect 8 64 37 76)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 14 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 35 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "input" (rect 0 0 23 12)(font "Arial" ))
|
||||
(text "input" (rect 21 43 44 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 144 32)
|
||||
(output)
|
||||
(text "output" (rect 0 0 30 12)(font "Arial" ))
|
||||
(text "output" (rect 98 27 128 39)(font "Arial" ))
|
||||
(line (pt 144 32)(pt 128 32))
|
||||
)
|
||||
(parameter
|
||||
"PHASE_SHIFT"
|
||||
"1"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 128 64))
|
||||
)
|
||||
(annotation_block (parameter)(rect 656 688 856 720))
|
||||
)
|
||||
(symbol
|
||||
(rect 656 840 800 920)
|
||||
(text "DigitalFilter" (rect 5 0 60 12)(font "Arial" ))
|
||||
(text "inst11" (rect 8 64 37 76)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 14 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 35 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "input" (rect 0 0 23 12)(font "Arial" ))
|
||||
(text "input" (rect 21 43 44 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 144 32)
|
||||
(output)
|
||||
(text "output" (rect 0 0 30 12)(font "Arial" ))
|
||||
(text "output" (rect 98 27 128 39)(font "Arial" ))
|
||||
(line (pt 144 32)(pt 128 32))
|
||||
)
|
||||
(parameter
|
||||
"PHASE_SHIFT"
|
||||
"1"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 128 64))
|
||||
)
|
||||
(annotation_block (parameter)(rect 656 808 856 840))
|
||||
)
|
||||
(connector
|
||||
(pt 608 288)
|
||||
(pt 656 288)
|
||||
)
|
||||
(connector
|
||||
(pt 656 272)
|
||||
(pt 632 272)
|
||||
)
|
||||
(connector
|
||||
(pt 544 304)
|
||||
(pt 520 304)
|
||||
)
|
||||
(connector
|
||||
(pt 656 392)
|
||||
(pt 632 392)
|
||||
)
|
||||
(connector
|
||||
(pt 632 216)
|
||||
(pt 632 272)
|
||||
)
|
||||
(connector
|
||||
(pt 656 512)
|
||||
(pt 632 512)
|
||||
)
|
||||
(connector
|
||||
(pt 632 272)
|
||||
(pt 632 392)
|
||||
)
|
||||
(connector
|
||||
(pt 656 632)
|
||||
(pt 632 632)
|
||||
)
|
||||
(connector
|
||||
(pt 632 392)
|
||||
(pt 632 512)
|
||||
)
|
||||
(connector
|
||||
(pt 656 752)
|
||||
(pt 632 752)
|
||||
)
|
||||
(connector
|
||||
(pt 632 512)
|
||||
(pt 632 632)
|
||||
)
|
||||
(connector
|
||||
(pt 656 872)
|
||||
(pt 632 872)
|
||||
)
|
||||
(connector
|
||||
(pt 632 632)
|
||||
(pt 632 752)
|
||||
)
|
||||
(connector
|
||||
(pt 632 752)
|
||||
(pt 632 872)
|
||||
)
|
||||
(connector
|
||||
(pt 608 408)
|
||||
(pt 656 408)
|
||||
)
|
||||
(connector
|
||||
(pt 608 528)
|
||||
(pt 656 528)
|
||||
)
|
||||
(connector
|
||||
(pt 608 768)
|
||||
(pt 656 768)
|
||||
)
|
||||
(connector
|
||||
(pt 608 888)
|
||||
(pt 656 888)
|
||||
)
|
||||
(connector
|
||||
(pt 936 272)
|
||||
(pt 936 392)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 936 392)
|
||||
(pt 936 512)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 936 512)
|
||||
(pt 936 632)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 544 904)
|
||||
(pt 520 904)
|
||||
)
|
||||
(connector
|
||||
(pt 544 784)
|
||||
(pt 520 784)
|
||||
)
|
||||
(connector
|
||||
(pt 520 904)
|
||||
(pt 520 784)
|
||||
)
|
||||
(connector
|
||||
(pt 544 664)
|
||||
(pt 520 664)
|
||||
)
|
||||
(connector
|
||||
(pt 544 544)
|
||||
(pt 520 544)
|
||||
)
|
||||
(connector
|
||||
(pt 520 216)
|
||||
(pt 520 304)
|
||||
)
|
||||
(connector
|
||||
(pt 520 544)
|
||||
(pt 520 664)
|
||||
)
|
||||
(connector
|
||||
(pt 520 664)
|
||||
(pt 520 784)
|
||||
)
|
||||
(connector
|
||||
(pt 544 424)
|
||||
(pt 520 424)
|
||||
)
|
||||
(connector
|
||||
(pt 520 304)
|
||||
(pt 520 424)
|
||||
)
|
||||
(connector
|
||||
(pt 520 424)
|
||||
(pt 520 544)
|
||||
)
|
||||
(connector
|
||||
(pt 424 528)
|
||||
(pt 424 648)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 424 408)
|
||||
(pt 424 528)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 520 216)
|
||||
(pt 632 216)
|
||||
)
|
||||
(connector
|
||||
(pt 424 288)
|
||||
(pt 424 408)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 296 216)
|
||||
(pt 520 216)
|
||||
)
|
||||
(connector
|
||||
(text "d[5..0]" (rect 306 272 337 284)(font "Arial" ))
|
||||
(pt 424 288)
|
||||
(pt 296 288)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(text "d[0]" (rect 434 272 452 284)(font "Arial" ))
|
||||
(pt 544 288)
|
||||
(pt 424 288)
|
||||
)
|
||||
(connector
|
||||
(text "d[1]" (rect 434 392 452 404)(font "Arial" ))
|
||||
(pt 544 408)
|
||||
(pt 424 408)
|
||||
)
|
||||
(connector
|
||||
(text "d[2]" (rect 434 512 452 524)(font "Arial" ))
|
||||
(pt 544 528)
|
||||
(pt 424 528)
|
||||
)
|
||||
(connector
|
||||
(text "d[3]" (rect 434 632 452 644)(font "Arial" ))
|
||||
(pt 544 648)
|
||||
(pt 424 648)
|
||||
)
|
||||
(connector
|
||||
(text "d[4]" (rect 434 752 452 764)(font "Arial" ))
|
||||
(pt 544 768)
|
||||
(pt 424 768)
|
||||
)
|
||||
(connector
|
||||
(pt 424 648)
|
||||
(pt 424 768)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 424 768)
|
||||
(pt 424 888)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(text "d[5]" (rect 434 872 452 884)(font "Arial" ))
|
||||
(pt 544 888)
|
||||
(pt 424 888)
|
||||
)
|
||||
(connector
|
||||
(text "q[5..0]" (rect 946 256 977 268)(font "Arial" ))
|
||||
(pt 1032 272)
|
||||
(pt 936 272)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(text "q[0]" (rect 810 256 828 268)(font "Arial" ))
|
||||
(pt 800 272)
|
||||
(pt 936 272)
|
||||
)
|
||||
(connector
|
||||
(text "q[1]" (rect 810 376 828 388)(font "Arial" ))
|
||||
(pt 800 392)
|
||||
(pt 936 392)
|
||||
)
|
||||
(connector
|
||||
(text "q[2]" (rect 810 496 828 508)(font "Arial" ))
|
||||
(pt 800 512)
|
||||
(pt 936 512)
|
||||
)
|
||||
(connector
|
||||
(text "q[3]" (rect 810 616 828 628)(font "Arial" ))
|
||||
(pt 800 632)
|
||||
(pt 936 632)
|
||||
)
|
||||
(connector
|
||||
(text "q[4]" (rect 810 736 828 748)(font "Arial" ))
|
||||
(pt 800 752)
|
||||
(pt 936 752)
|
||||
)
|
||||
(connector
|
||||
(pt 936 632)
|
||||
(pt 936 752)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 936 752)
|
||||
(pt 936 872)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(text "q[5]" (rect 810 856 828 868)(font "Arial" ))
|
||||
(pt 800 872)
|
||||
(pt 936 872)
|
||||
)
|
||||
(junction (pt 520 216))
|
||||
(junction (pt 632 272))
|
||||
(junction (pt 632 392))
|
||||
(junction (pt 632 512))
|
||||
(junction (pt 632 632))
|
||||
(junction (pt 632 752))
|
||||
(junction (pt 936 272))
|
||||
(junction (pt 936 392))
|
||||
(junction (pt 936 512))
|
||||
(junction (pt 936 632))
|
||||
(junction (pt 936 752))
|
||||
(junction (pt 520 784))
|
||||
(junction (pt 520 304))
|
||||
(junction (pt 520 544))
|
||||
(junction (pt 520 664))
|
||||
(junction (pt 520 424))
|
||||
(junction (pt 424 768))
|
||||
(junction (pt 424 648))
|
||||
(junction (pt 424 528))
|
||||
(junction (pt 424 408))
|
||||
(junction (pt 424 288))
|
50
MainController/DigitalFilterBlock6.bsf
Normal file
50
MainController/DigitalFilterBlock6.bsf
Normal file
@ -0,0 +1,50 @@
|
||||
/*
|
||||
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-2013 Altera Corporation
|
||||
Your use of Altera Corporation's design tools, logic functions
|
||||
and other software and tools, and its AMPP partner logic
|
||||
functions, and any output files from any of the foregoing
|
||||
(including device programming or simulation files), and any
|
||||
associated documentation or information are expressly subject
|
||||
to the terms and conditions of the Altera Program License
|
||||
Subscription Agreement, Altera MegaCore Function License
|
||||
Agreement, or other applicable license agreement, including,
|
||||
without limitation, that your use is for the sole purpose of
|
||||
programming logic devices manufactured by Altera and sold by
|
||||
Altera or its authorized distributors. Please refer to the
|
||||
applicable agreement for further details.
|
||||
*/
|
||||
(header "symbol" (version "1.2"))
|
||||
(symbol
|
||||
(rect 16 16 144 112)
|
||||
(text "DigitalFilterBlock6" (rect 5 0 102 14)(font "Arial" (font_size 8)))
|
||||
(text "inst" (rect 8 80 25 92)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 15 14)(font "Arial" (font_size 8)))
|
||||
(text "clk" (rect 21 27 36 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "d[5..0]" (rect 0 0 35 14)(font "Arial" (font_size 8)))
|
||||
(text "d[5..0]" (rect 21 43 56 57)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 48)(pt 16 48)(line_width 3))
|
||||
)
|
||||
(port
|
||||
(pt 128 32)
|
||||
(output)
|
||||
(text "q[5..0]" (rect 0 0 35 14)(font "Arial" (font_size 8)))
|
||||
(text "q[5..0]" (rect 72 27 107 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 128 32)(pt 112 32)(line_width 3))
|
||||
)
|
||||
(drawing
|
||||
(rectangle (rect 16 16 112 80))
|
||||
)
|
||||
)
|
191
MainController/DigitalFilterBlockSingle.bdf
Normal file
191
MainController/DigitalFilterBlockSingle.bdf
Normal file
@ -0,0 +1,191 @@
|
||||
/*
|
||||
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-2013 Altera Corporation
|
||||
Your use of Altera Corporation's design tools, logic functions
|
||||
and other software and tools, and its AMPP partner logic
|
||||
functions, and any output files from any of the foregoing
|
||||
(including device programming or simulation files), and any
|
||||
associated documentation or information are expressly subject
|
||||
to the terms and conditions of the Altera Program License
|
||||
Subscription Agreement, Altera MegaCore Function License
|
||||
Agreement, or other applicable license agreement, including,
|
||||
without limitation, that your use is for the sole purpose of
|
||||
programming logic devices manufactured by Altera and sold by
|
||||
Altera or its authorized distributors. Please refer to the
|
||||
applicable agreement for further details.
|
||||
*/
|
||||
(header "graphic" (version "1.4"))
|
||||
(pin
|
||||
(input)
|
||||
(rect 304 192 472 208)
|
||||
(text "INPUT" (rect 125 0 153 10)(font "Arial" (font_size 6)))
|
||||
(text "d" (rect 5 0 11 12)(font "Arial" ))
|
||||
(pt 168 8)
|
||||
(drawing
|
||||
(line (pt 84 12)(pt 109 12))
|
||||
(line (pt 84 4)(pt 109 4))
|
||||
(line (pt 113 8)(pt 168 8))
|
||||
(line (pt 84 12)(pt 84 4))
|
||||
(line (pt 109 4)(pt 113 8))
|
||||
(line (pt 109 12)(pt 113 8))
|
||||
)
|
||||
(text "VCC" (rect 128 7 148 17)(font "Arial" (font_size 6)))
|
||||
)
|
||||
(pin
|
||||
(input)
|
||||
(rect 304 256 472 272)
|
||||
(text "INPUT" (rect 125 0 153 10)(font "Arial" (font_size 6)))
|
||||
(text "clk" (rect 5 0 20 12)(font "Arial" ))
|
||||
(pt 168 8)
|
||||
(drawing
|
||||
(line (pt 84 12)(pt 109 12))
|
||||
(line (pt 84 4)(pt 109 4))
|
||||
(line (pt 113 8)(pt 168 8))
|
||||
(line (pt 84 12)(pt 84 4))
|
||||
(line (pt 109 4)(pt 113 8))
|
||||
(line (pt 109 12)(pt 113 8))
|
||||
)
|
||||
(text "VCC" (rect 128 7 148 17)(font "Arial" (font_size 6)))
|
||||
)
|
||||
(pin
|
||||
(output)
|
||||
(rect 864 176 1040 192)
|
||||
(text "OUTPUT" (rect 1 0 39 10)(font "Arial" (font_size 6)))
|
||||
(text "q" (rect 90 0 95 12)(font "Arial" ))
|
||||
(pt 0 8)
|
||||
(drawing
|
||||
(line (pt 0 8)(pt 52 8))
|
||||
(line (pt 52 4)(pt 78 4))
|
||||
(line (pt 52 12)(pt 78 12))
|
||||
(line (pt 52 12)(pt 52 4))
|
||||
(line (pt 78 4)(pt 82 8))
|
||||
(line (pt 82 8)(pt 78 12))
|
||||
(line (pt 78 12)(pt 82 8))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 528 176 592 256)
|
||||
(text "DFF" (rect 1 0 19 10)(font "Arial" (font_size 6)))
|
||||
(text "inst" (rect 3 68 20 80)(font "Arial" ))
|
||||
(port
|
||||
(pt 32 80)
|
||||
(input)
|
||||
(text "CLRN" (rect 21 59 44 71)(font "Courier New" (bold)))
|
||||
(text "CLRN" (rect 21 58 44 70)(font "Courier New" (bold)))
|
||||
(line (pt 32 80)(pt 32 76))
|
||||
)
|
||||
(port
|
||||
(pt 0 40)
|
||||
(input)
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(text "CLK" (rect 3 29 20 41)(font "Courier New" (bold))(invisible))
|
||||
(line (pt 0 40)(pt 12 40))
|
||||
)
|
||||
(port
|
||||
(pt 0 24)
|
||||
(input)
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(text "D" (rect 14 20 19 32)(font "Courier New" (bold)))
|
||||
(line (pt 0 24)(pt 12 24))
|
||||
)
|
||||
(port
|
||||
(pt 32 0)
|
||||
(input)
|
||||
(text "PRN" (rect 24 13 41 25)(font "Courier New" (bold)))
|
||||
(text "PRN" (rect 24 11 41 23)(font "Courier New" (bold)))
|
||||
(line (pt 32 4)(pt 32 0))
|
||||
)
|
||||
(port
|
||||
(pt 64 24)
|
||||
(output)
|
||||
(text "Q" (rect 45 20 50 32)(font "Courier New" (bold)))
|
||||
(text "Q" (rect 43 20 48 32)(font "Courier New" (bold)))
|
||||
(line (pt 52 24)(pt 64 24))
|
||||
)
|
||||
(drawing
|
||||
(line (pt 12 12)(pt 52 12))
|
||||
(line (pt 12 68)(pt 52 68))
|
||||
(line (pt 52 68)(pt 52 12))
|
||||
(line (pt 12 68)(pt 12 12))
|
||||
(line (pt 19 40)(pt 12 47))
|
||||
(line (pt 12 32)(pt 20 40))
|
||||
(circle (rect 28 4 36 12))
|
||||
(circle (rect 28 68 36 76))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 640 152 784 232)
|
||||
(text "DigitalFilter" (rect 5 0 60 12)(font "Arial" ))
|
||||
(text "inst2" (rect 8 64 31 76)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 14 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 35 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "input" (rect 0 0 23 12)(font "Arial" ))
|
||||
(text "input" (rect 21 43 44 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 144 32)
|
||||
(output)
|
||||
(text "output" (rect 0 0 30 12)(font "Arial" ))
|
||||
(text "output" (rect 98 27 128 39)(font "Arial" ))
|
||||
(line (pt 144 32)(pt 128 32))
|
||||
)
|
||||
(parameter
|
||||
"PHASE_SHIFT"
|
||||
"1"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 128 64))
|
||||
)
|
||||
(annotation_block (parameter)(rect 784 120 984 152))
|
||||
)
|
||||
(connector
|
||||
(pt 472 200)
|
||||
(pt 528 200)
|
||||
)
|
||||
(connector
|
||||
(pt 592 200)
|
||||
(pt 640 200)
|
||||
)
|
||||
(connector
|
||||
(pt 640 184)
|
||||
(pt 616 184)
|
||||
)
|
||||
(connector
|
||||
(pt 616 264)
|
||||
(pt 616 184)
|
||||
)
|
||||
(connector
|
||||
(pt 528 216)
|
||||
(pt 504 216)
|
||||
)
|
||||
(connector
|
||||
(pt 504 216)
|
||||
(pt 504 264)
|
||||
)
|
||||
(connector
|
||||
(pt 472 264)
|
||||
(pt 504 264)
|
||||
)
|
||||
(connector
|
||||
(pt 504 264)
|
||||
(pt 616 264)
|
||||
)
|
||||
(connector
|
||||
(pt 784 184)
|
||||
(pt 864 184)
|
||||
)
|
||||
(junction (pt 504 264))
|
50
MainController/DigitalFilterBlockSingle.bsf
Normal file
50
MainController/DigitalFilterBlockSingle.bsf
Normal file
@ -0,0 +1,50 @@
|
||||
/*
|
||||
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-2013 Altera Corporation
|
||||
Your use of Altera Corporation's design tools, logic functions
|
||||
and other software and tools, and its AMPP partner logic
|
||||
functions, and any output files from any of the foregoing
|
||||
(including device programming or simulation files), and any
|
||||
associated documentation or information are expressly subject
|
||||
to the terms and conditions of the Altera Program License
|
||||
Subscription Agreement, Altera MegaCore Function License
|
||||
Agreement, or other applicable license agreement, including,
|
||||
without limitation, that your use is for the sole purpose of
|
||||
programming logic devices manufactured by Altera and sold by
|
||||
Altera or its authorized distributors. Please refer to the
|
||||
applicable agreement for further details.
|
||||
*/
|
||||
(header "symbol" (version "1.2"))
|
||||
(symbol
|
||||
(rect 16 16 112 112)
|
||||
(text "DigitalFilterBlockSingle" (rect 5 0 130 14)(font "Arial" (font_size 8)))
|
||||
(text "inst" (rect 8 80 25 92)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "d" (rect 0 0 7 14)(font "Arial" (font_size 8)))
|
||||
(text "d" (rect 21 27 28 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 15 14)(font "Arial" (font_size 8)))
|
||||
(text "clk" (rect 21 43 36 57)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 96 32)
|
||||
(output)
|
||||
(text "q" (rect 0 0 7 14)(font "Arial" (font_size 8)))
|
||||
(text "q" (rect 68 27 75 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 96 32)(pt 80 32))
|
||||
)
|
||||
(drawing
|
||||
(rectangle (rect 16 16 80 80))
|
||||
)
|
||||
)
|
@ -21,7 +21,7 @@ applicable agreement for further details.
|
||||
(header "graphic" (version "1.4"))
|
||||
(pin
|
||||
(input)
|
||||
(rect 392 24 560 40)
|
||||
(rect 376 24 544 40)
|
||||
(text "INPUT" (rect 125 0 153 10)(font "Arial" (font_size 6)))
|
||||
(text "FPGA_CLK" (rect 5 0 61 12)(font "Arial" ))
|
||||
(pt 168 8)
|
||||
@ -34,7 +34,7 @@ applicable agreement for further details.
|
||||
(line (pt 109 12)(pt 113 8))
|
||||
)
|
||||
(text "VCC" (rect 128 7 148 17)(font "Arial" (font_size 6)))
|
||||
(annotation_block (location)(rect 336 24 384 40))
|
||||
(annotation_block (location)(rect 320 24 368 40))
|
||||
)
|
||||
(pin
|
||||
(input)
|
||||
@ -142,7 +142,7 @@ applicable agreement for further details.
|
||||
(input)
|
||||
(rect 368 984 536 1000)
|
||||
(text "INPUT" (rect 125 0 153 10)(font "Arial" (font_size 6)))
|
||||
(text "PBack" (rect 5 0 37 12)(font "Arial" ))
|
||||
(text "PBack" (rect 5 0 36 12)(font "Arial" ))
|
||||
(pt 168 8)
|
||||
(drawing
|
||||
(line (pt 84 12)(pt 109 12))
|
||||
@ -155,6 +155,23 @@ applicable agreement for further details.
|
||||
(text "VCC" (rect 128 7 148 17)(font "Arial" (font_size 6)))
|
||||
(annotation_block (location)(rect 312 984 360 1000))
|
||||
)
|
||||
(pin
|
||||
(input)
|
||||
(rect 368 1520 536 1536)
|
||||
(text "INPUT" (rect 125 0 153 10)(font "Arial" (font_size 6)))
|
||||
(text "PWM[5..0]" (rect 5 0 57 12)(font "Arial" ))
|
||||
(pt 168 8)
|
||||
(drawing
|
||||
(line (pt 84 12)(pt 109 12))
|
||||
(line (pt 84 4)(pt 109 4))
|
||||
(line (pt 113 8)(pt 168 8))
|
||||
(line (pt 84 12)(pt 84 4))
|
||||
(line (pt 109 4)(pt 113 8))
|
||||
(line (pt 109 12)(pt 113 8))
|
||||
)
|
||||
(text "VCC" (rect 128 7 148 17)(font "Arial" (font_size 6)))
|
||||
(annotation_block (location)(rect 304 1520 360 1608))
|
||||
)
|
||||
(pin
|
||||
(output)
|
||||
(rect 1840 24 2016 40)
|
||||
@ -410,6 +427,40 @@ applicable agreement for further details.
|
||||
)
|
||||
(annotation_block (location)(rect 2024 8 2072 24))
|
||||
)
|
||||
(pin
|
||||
(output)
|
||||
(rect 1848 1456 2024 1472)
|
||||
(text "OUTPUT" (rect 1 0 39 10)(font "Arial" (font_size 6)))
|
||||
(text "Interrupt" (rect 90 0 131 12)(font "Arial" ))
|
||||
(pt 0 8)
|
||||
(drawing
|
||||
(line (pt 0 8)(pt 52 8))
|
||||
(line (pt 52 4)(pt 78 4))
|
||||
(line (pt 52 12)(pt 78 12))
|
||||
(line (pt 52 12)(pt 52 4))
|
||||
(line (pt 78 4)(pt 82 8))
|
||||
(line (pt 82 8)(pt 78 12))
|
||||
(line (pt 78 12)(pt 82 8))
|
||||
)
|
||||
(annotation_block (location)(rect 2032 1456 2088 1472))
|
||||
)
|
||||
(pin
|
||||
(output)
|
||||
(rect 1848 1440 2024 1456)
|
||||
(text "OUTPUT" (rect 1 0 39 10)(font "Arial" (font_size 6)))
|
||||
(text "TK[31..0]" (rect 90 0 134 12)(font "Arial" ))
|
||||
(pt 0 8)
|
||||
(drawing
|
||||
(line (pt 0 8)(pt 52 8))
|
||||
(line (pt 52 4)(pt 78 4))
|
||||
(line (pt 52 12)(pt 78 12))
|
||||
(line (pt 52 12)(pt 52 4))
|
||||
(line (pt 78 4)(pt 82 8))
|
||||
(line (pt 82 8)(pt 78 12))
|
||||
(line (pt 78 12)(pt 82 8))
|
||||
)
|
||||
(annotation_block (location)(rect 2096 984 2144 1440))
|
||||
)
|
||||
(pin
|
||||
(bidir)
|
||||
(rect 1840 280 2016 296)
|
||||
@ -444,7 +495,7 @@ applicable agreement for further details.
|
||||
(line (pt 52 8)(pt 56 12))
|
||||
)
|
||||
(text "VCC" (rect 4 7 24 17)(font "Arial" (font_size 6)))
|
||||
(annotation_block (location)(rect 2096 968 2144 1200))
|
||||
(annotation_block (location)(rect 2032 968 2080 1200))
|
||||
)
|
||||
(symbol
|
||||
(rect 704 88 856 200)
|
||||
@ -528,77 +579,6 @@ applicable agreement for further details.
|
||||
(line (pt 8 8)(pt 24 8))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 704 208 936 336)
|
||||
(text "DigitalFilterBlock" (rect 5 0 95 14)(font "Arial" (font_size 8)))
|
||||
(text "inst3" (rect 8 112 31 124)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 15 14)(font "Arial" (font_size 8)))
|
||||
(text "clk" (rect 21 27 36 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "cein" (rect 0 0 23 14)(font "Arial" (font_size 8)))
|
||||
(text "cein" (rect 21 43 44 57)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 0 64)
|
||||
(input)
|
||||
(text "oein" (rect 0 0 23 14)(font "Arial" (font_size 8)))
|
||||
(text "oein" (rect 21 59 44 73)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 64)(pt 16 64))
|
||||
)
|
||||
(port
|
||||
(pt 0 80)
|
||||
(input)
|
||||
(text "wein" (rect 0 0 28 14)(font "Arial" (font_size 8)))
|
||||
(text "wein" (rect 21 75 49 89)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 80)(pt 16 80))
|
||||
)
|
||||
(port
|
||||
(pt 0 96)
|
||||
(input)
|
||||
(text "addressin[8..0]" (rect 0 0 84 14)(font "Arial" (font_size 8)))
|
||||
(text "addressin[8..0]" (rect 21 91 105 105)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 96)(pt 16 96)(line_width 3))
|
||||
)
|
||||
(port
|
||||
(pt 232 32)
|
||||
(output)
|
||||
(text "ceout" (rect 0 0 31 14)(font "Arial" (font_size 8)))
|
||||
(text "ceout" (rect 180 27 211 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 232 32)(pt 216 32))
|
||||
)
|
||||
(port
|
||||
(pt 232 48)
|
||||
(output)
|
||||
(text "oeout" (rect 0 0 31 14)(font "Arial" (font_size 8)))
|
||||
(text "oeout" (rect 180 43 211 57)(font "Arial" (font_size 8)))
|
||||
(line (pt 232 48)(pt 216 48))
|
||||
)
|
||||
(port
|
||||
(pt 232 64)
|
||||
(output)
|
||||
(text "weout" (rect 0 0 36 14)(font "Arial" (font_size 8)))
|
||||
(text "weout" (rect 175 59 211 73)(font "Arial" (font_size 8)))
|
||||
(line (pt 232 64)(pt 216 64))
|
||||
)
|
||||
(port
|
||||
(pt 232 80)
|
||||
(output)
|
||||
(text "addressout[8..0]" (rect 0 0 93 14)(font "Arial" (font_size 8)))
|
||||
(text "addressout[8..0]" (rect 118 75 211 89)(font "Arial" (font_size 8)))
|
||||
(line (pt 232 80)(pt 216 80)(line_width 3))
|
||||
)
|
||||
(drawing
|
||||
(rectangle (rect 16 16 216 112))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 1040 544 1368 688)
|
||||
(text "RAM9X8_SerialBusMaster" (rect 5 0 131 12)(font "Arial" ))
|
||||
@ -711,76 +691,6 @@ applicable agreement for further details.
|
||||
)
|
||||
(annotation_block (parameter)(rect 1040 416 1360 544))
|
||||
)
|
||||
(symbol
|
||||
(rect 712 624 856 704)
|
||||
(text "DigitalFilter" (rect 5 0 60 12)(font "Arial" ))
|
||||
(text "inst5" (rect 8 64 31 76)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 14 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 35 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "input" (rect 0 0 23 12)(font "Arial" ))
|
||||
(text "input" (rect 21 43 44 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 144 32)
|
||||
(output)
|
||||
(text "output" (rect 0 0 30 12)(font "Arial" ))
|
||||
(text "output" (rect 98 27 128 39)(font "Arial" ))
|
||||
(line (pt 144 32)(pt 128 32))
|
||||
)
|
||||
(parameter
|
||||
"PHASE_SHIFT"
|
||||
"1"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 128 64))
|
||||
)
|
||||
(annotation_block (parameter)(rect 712 592 912 624))
|
||||
)
|
||||
(symbol
|
||||
(rect 712 944 856 1024)
|
||||
(text "DigitalFilter" (rect 5 0 60 12)(font "Arial" ))
|
||||
(text "inst6" (rect 8 64 31 76)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 14 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 35 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "input" (rect 0 0 23 12)(font "Arial" ))
|
||||
(text "input" (rect 21 43 44 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 144 32)
|
||||
(output)
|
||||
(text "output" (rect 0 0 30 12)(font "Arial" ))
|
||||
(text "output" (rect 98 27 128 39)(font "Arial" ))
|
||||
(line (pt 144 32)(pt 128 32))
|
||||
)
|
||||
(parameter
|
||||
"PHASE_SHIFT"
|
||||
"1"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 128 64))
|
||||
)
|
||||
(annotation_block (parameter)(rect 712 912 912 944))
|
||||
)
|
||||
(symbol
|
||||
(rect 1040 256 1368 368)
|
||||
(text "RAM" (rect 5 0 28 12)(font "Arial" ))
|
||||
@ -1124,13 +1034,387 @@ applicable agreement for further details.
|
||||
(line (pt 8 8)(pt 24 8))
|
||||
)
|
||||
)
|
||||
(connector
|
||||
(pt 560 32)
|
||||
(pt 608 32)
|
||||
(symbol
|
||||
(rect 704 208 936 336)
|
||||
(text "DigitalFilterBlock" (rect 5 0 95 14)(font "Arial" (font_size 8)))
|
||||
(text "inst3" (rect 8 112 31 124)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 15 14)(font "Arial" (font_size 8)))
|
||||
(text "clk" (rect 21 27 36 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "cein" (rect 0 0 23 14)(font "Arial" (font_size 8)))
|
||||
(text "cein" (rect 21 43 44 57)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 0 64)
|
||||
(input)
|
||||
(text "oein" (rect 0 0 23 14)(font "Arial" (font_size 8)))
|
||||
(text "oein" (rect 21 59 44 73)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 64)(pt 16 64))
|
||||
)
|
||||
(port
|
||||
(pt 0 80)
|
||||
(input)
|
||||
(text "wein" (rect 0 0 28 14)(font "Arial" (font_size 8)))
|
||||
(text "wein" (rect 21 75 49 89)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 80)(pt 16 80))
|
||||
)
|
||||
(port
|
||||
(pt 0 96)
|
||||
(input)
|
||||
(text "addressin[8..0]" (rect 0 0 84 14)(font "Arial" (font_size 8)))
|
||||
(text "addressin[8..0]" (rect 21 91 105 105)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 96)(pt 16 96)(line_width 3))
|
||||
)
|
||||
(port
|
||||
(pt 232 32)
|
||||
(output)
|
||||
(text "ceout" (rect 0 0 31 14)(font "Arial" (font_size 8)))
|
||||
(text "ceout" (rect 180 27 211 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 232 32)(pt 216 32))
|
||||
)
|
||||
(port
|
||||
(pt 232 48)
|
||||
(output)
|
||||
(text "oeout" (rect 0 0 31 14)(font "Arial" (font_size 8)))
|
||||
(text "oeout" (rect 180 43 211 57)(font "Arial" (font_size 8)))
|
||||
(line (pt 232 48)(pt 216 48))
|
||||
)
|
||||
(port
|
||||
(pt 232 64)
|
||||
(output)
|
||||
(text "weout" (rect 0 0 36 14)(font "Arial" (font_size 8)))
|
||||
(text "weout" (rect 175 59 211 73)(font "Arial" (font_size 8)))
|
||||
(line (pt 232 64)(pt 216 64))
|
||||
)
|
||||
(port
|
||||
(pt 232 80)
|
||||
(output)
|
||||
(text "addressout[8..0]" (rect 0 0 93 14)(font "Arial" (font_size 8)))
|
||||
(text "addressout[8..0]" (rect 118 75 211 89)(font "Arial" (font_size 8)))
|
||||
(line (pt 232 80)(pt 216 80)(line_width 3))
|
||||
)
|
||||
(drawing
|
||||
(rectangle (rect 16 16 216 112))
|
||||
)
|
||||
)
|
||||
(connector
|
||||
(pt 608 32)
|
||||
(pt 704 32)
|
||||
(symbol
|
||||
(rect 712 624 808 720)
|
||||
(text "DigitalFilterBlockSingle" (rect 5 0 130 14)(font "Arial" (font_size 8)))
|
||||
(text "inst5" (rect 8 80 31 92)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "d" (rect 0 0 7 14)(font "Arial" (font_size 8)))
|
||||
(text "d" (rect 21 27 28 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 15 14)(font "Arial" (font_size 8)))
|
||||
(text "clk" (rect 21 43 36 57)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 96 32)
|
||||
(output)
|
||||
(text "q" (rect 0 0 7 14)(font "Arial" (font_size 8)))
|
||||
(text "q" (rect 68 27 75 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 96 32)(pt 80 32))
|
||||
)
|
||||
(drawing
|
||||
(rectangle (rect 16 16 80 80))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 712 944 808 1040)
|
||||
(text "DigitalFilterBlockSingle" (rect 5 0 130 14)(font "Arial" (font_size 8)))
|
||||
(text "inst6" (rect 8 80 31 92)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "d" (rect 0 0 7 14)(font "Arial" (font_size 8)))
|
||||
(text "d" (rect 21 27 28 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 15 14)(font "Arial" (font_size 8)))
|
||||
(text "clk" (rect 21 43 36 57)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 48)(pt 16 48))
|
||||
)
|
||||
(port
|
||||
(pt 96 32)
|
||||
(output)
|
||||
(text "q" (rect 0 0 7 14)(font "Arial" (font_size 8)))
|
||||
(text "q" (rect 68 27 75 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 96 32)(pt 80 32))
|
||||
)
|
||||
(drawing
|
||||
(rectangle (rect 16 16 80 80))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 736 1480 864 1576)
|
||||
(text "DigitalFilterBlock6" (rect 5 0 102 14)(font "Arial" (font_size 8)))
|
||||
(text "inst17" (rect 8 80 37 92)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 15 14)(font "Arial" (font_size 8)))
|
||||
(text "clk" (rect 21 27 36 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "d[5..0]" (rect 0 0 35 14)(font "Arial" (font_size 8)))
|
||||
(text "d[5..0]" (rect 21 43 56 57)(font "Arial" (font_size 8)))
|
||||
(line (pt 0 48)(pt 16 48)(line_width 3))
|
||||
)
|
||||
(port
|
||||
(pt 128 32)
|
||||
(output)
|
||||
(text "q[5..0]" (rect 0 0 35 14)(font "Arial" (font_size 8)))
|
||||
(text "q[5..0]" (rect 72 27 107 41)(font "Arial" (font_size 8)))
|
||||
(line (pt 128 32)(pt 112 32)(line_width 3))
|
||||
)
|
||||
(drawing
|
||||
(rectangle (rect 16 16 112 80))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 896 1480 928 1496)
|
||||
(text "VCC" (rect 7 0 27 10)(font "Arial" (font_size 6)))
|
||||
(text "inst18" (rect 3 5 32 17)(font "Arial" )(invisible))
|
||||
(port
|
||||
(pt 16 16)
|
||||
(output)
|
||||
(text "1" (rect 19 7 24 19)(font "Courier New" (bold))(invisible))
|
||||
(text "1" (rect 19 7 24 19)(font "Courier New" (bold))(invisible))
|
||||
(line (pt 16 16)(pt 16 8))
|
||||
)
|
||||
(drawing
|
||||
(line (pt 8 8)(pt 24 8))
|
||||
)
|
||||
)
|
||||
(symbol
|
||||
(rect 1048 1400 1376 1576)
|
||||
(text "RAM9X8_PWM" (rect 5 0 78 12)(font "Arial" ))
|
||||
(text "inst15" (rect 8 160 37 172)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 14 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 35 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "address[address_bus_width-1..0]" (rect 0 0 161 12)(font "Arial" ))
|
||||
(text "address[address_bus_width-1..0]" (rect 21 43 182 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48)(line_width 3))
|
||||
)
|
||||
(port
|
||||
(pt 0 64)
|
||||
(input)
|
||||
(text "we" (rect 0 0 12 12)(font "Arial" ))
|
||||
(text "we" (rect 21 59 33 71)(font "Arial" ))
|
||||
(line (pt 0 64)(pt 16 64))
|
||||
)
|
||||
(port
|
||||
(pt 0 80)
|
||||
(input)
|
||||
(text "oe" (rect 0 0 11 12)(font "Arial" ))
|
||||
(text "oe" (rect 21 75 32 87)(font "Arial" ))
|
||||
(line (pt 0 80)(pt 16 80))
|
||||
)
|
||||
(port
|
||||
(pt 0 96)
|
||||
(input)
|
||||
(text "ce" (rect 0 0 11 12)(font "Arial" ))
|
||||
(text "ce" (rect 21 91 32 103)(font "Arial" ))
|
||||
(line (pt 0 96)(pt 16 96))
|
||||
)
|
||||
(port
|
||||
(pt 0 112)
|
||||
(input)
|
||||
(text "pwm[5..0]" (rect 0 0 48 12)(font "Arial" ))
|
||||
(text "pwm[5..0]" (rect 21 107 69 119)(font "Arial" ))
|
||||
(line (pt 0 112)(pt 16 112)(line_width 3))
|
||||
)
|
||||
(port
|
||||
(pt 0 128)
|
||||
(input)
|
||||
(text "error" (rect 0 0 22 12)(font "Arial" ))
|
||||
(text "error" (rect 21 123 43 135)(font "Arial" ))
|
||||
(line (pt 0 128)(pt 16 128))
|
||||
)
|
||||
(port
|
||||
(pt 328 48)
|
||||
(output)
|
||||
(text "tk[31..0]" (rect 0 0 41 12)(font "Arial" ))
|
||||
(text "tk[31..0]" (rect 273 43 307 55)(font "Arial" ))
|
||||
(line (pt 328 48)(pt 312 48)(line_width 3))
|
||||
)
|
||||
(port
|
||||
(pt 328 64)
|
||||
(output)
|
||||
(text "interrupt" (rect 0 0 40 12)(font "Arial" ))
|
||||
(text "interrupt" (rect 274 59 307 71)(font "Arial" ))
|
||||
(line (pt 328 64)(pt 312 64))
|
||||
)
|
||||
(port
|
||||
(pt 328 32)
|
||||
(bidir)
|
||||
(text "data[data_bus_width-1..0]" (rect 0 0 126 12)(font "Arial" ))
|
||||
(text "data[data_bus_width-1..0]" (rect 208 27 334 39)(font "Arial" ))
|
||||
(line (pt 328 32)(pt 312 32)(line_width 3))
|
||||
)
|
||||
(parameter
|
||||
"REG_ADDR_MODE_CONTROL_UPPER_BYTE"
|
||||
"14"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_MODE_CONTROL_LOWER_BYTE"
|
||||
"15"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_MASK_2_UPPER_BYTE"
|
||||
"16"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_MASK_2_LOWER_BYTE"
|
||||
"17"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_MASK_1_UPPER_BYTE"
|
||||
"18"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_MASK_1_LOWER_BYTE"
|
||||
"19"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECT_CONTROL_2_UPPER_BYTE"
|
||||
"20"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECT_CONTROL_2_LOWER_BYTE"
|
||||
"21"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECT_CONTROL_1_UPPER_BYTE"
|
||||
"22"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECT_CONTROL_1_LOWER_BYTE"
|
||||
"23"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_PERIOD_UPPER_BYTE"
|
||||
"24"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_PERIOD_LOWER_BYTE"
|
||||
"25"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECTION_2_UPPER_BYTE"
|
||||
"26"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECTION_2_LOWER_BYTE"
|
||||
"27"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECTION_1_UPPER_BYTE"
|
||||
"28"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECTION_1_LOWER_BYTE"
|
||||
"29"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CHANNEL_UPPER_BYTE"
|
||||
"30"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CHANNEL_LOWER_BYTE"
|
||||
"31"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_TIMING_UPPER_BYTE"
|
||||
"32"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_TIMING_LOWER_BYTE"
|
||||
"33"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CMD_UPPER_BYTE"
|
||||
"34"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CMD_LOWER_BYTE"
|
||||
"35"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CONTROL_UPPER_BYTE"
|
||||
"36"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CONTROL_LOWER_BYTE"
|
||||
"37"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"DATA_BUS_WIDTH"
|
||||
"8"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"ADDRESS_BUS_WIDTH"
|
||||
"9"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 312 160))
|
||||
)
|
||||
(annotation_block (parameter)(rect 1024 1016 1400 1400))
|
||||
)
|
||||
(connector
|
||||
(pt 488 136)
|
||||
@ -1249,34 +1533,10 @@ applicable agreement for further details.
|
||||
(pt 1368 288)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 712 656)
|
||||
(pt 608 656)
|
||||
)
|
||||
(connector
|
||||
(pt 544 672)
|
||||
(pt 712 672)
|
||||
)
|
||||
(connector
|
||||
(pt 856 656)
|
||||
(pt 1040 656)
|
||||
)
|
||||
(connector
|
||||
(pt 704 256)
|
||||
(pt 544 256)
|
||||
)
|
||||
(connector
|
||||
(pt 608 976)
|
||||
(pt 712 976)
|
||||
)
|
||||
(connector
|
||||
(pt 608 576)
|
||||
(pt 608 656)
|
||||
)
|
||||
(connector
|
||||
(pt 712 992)
|
||||
(pt 536 992)
|
||||
)
|
||||
(connector
|
||||
(pt 856 136)
|
||||
(pt 936 136)
|
||||
@ -1285,91 +1545,6 @@ applicable agreement for further details.
|
||||
(pt 936 -16)
|
||||
(pt 936 136)
|
||||
)
|
||||
(connector
|
||||
(pt 1000 912)
|
||||
(pt 1040 912)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 984 928)
|
||||
(pt 1040 928)
|
||||
)
|
||||
(connector
|
||||
(pt 968 944)
|
||||
(pt 1040 944)
|
||||
)
|
||||
(connector
|
||||
(pt 952 960)
|
||||
(pt 1040 960)
|
||||
)
|
||||
(connector
|
||||
(pt 608 896)
|
||||
(pt 1040 896)
|
||||
)
|
||||
(connector
|
||||
(pt 1848 912)
|
||||
(pt 1368 912)
|
||||
)
|
||||
(connector
|
||||
(pt 1848 928)
|
||||
(pt 1368 928)
|
||||
)
|
||||
(connector
|
||||
(pt 1848 944)
|
||||
(pt 1368 944)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 1848 960)
|
||||
(pt 1368 960)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 856 976)
|
||||
(pt 1040 976)
|
||||
)
|
||||
(connector
|
||||
(pt 608 656)
|
||||
(pt 608 896)
|
||||
)
|
||||
(connector
|
||||
(pt 608 896)
|
||||
(pt 608 976)
|
||||
)
|
||||
(connector
|
||||
(pt 1000 288)
|
||||
(pt 1000 592)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 1000 592)
|
||||
(pt 1000 912)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 984 304)
|
||||
(pt 984 608)
|
||||
)
|
||||
(connector
|
||||
(pt 984 608)
|
||||
(pt 984 928)
|
||||
)
|
||||
(connector
|
||||
(pt 968 320)
|
||||
(pt 968 624)
|
||||
)
|
||||
(connector
|
||||
(pt 968 624)
|
||||
(pt 968 944)
|
||||
)
|
||||
(connector
|
||||
(pt 952 336)
|
||||
(pt 952 640)
|
||||
)
|
||||
(connector
|
||||
(pt 952 640)
|
||||
(pt 952 960)
|
||||
)
|
||||
(connector
|
||||
(pt 1368 608)
|
||||
(pt 1592 608)
|
||||
@ -1488,6 +1663,200 @@ applicable agreement for further details.
|
||||
(pt 1712 64)
|
||||
(pt 1712 80)
|
||||
)
|
||||
(connector
|
||||
(pt 1000 912)
|
||||
(pt 1040 912)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 984 928)
|
||||
(pt 1040 928)
|
||||
)
|
||||
(connector
|
||||
(pt 968 944)
|
||||
(pt 1040 944)
|
||||
)
|
||||
(connector
|
||||
(pt 952 960)
|
||||
(pt 1040 960)
|
||||
)
|
||||
(connector
|
||||
(pt 608 896)
|
||||
(pt 1040 896)
|
||||
)
|
||||
(connector
|
||||
(pt 1848 912)
|
||||
(pt 1368 912)
|
||||
)
|
||||
(connector
|
||||
(pt 1848 928)
|
||||
(pt 1368 928)
|
||||
)
|
||||
(connector
|
||||
(pt 1848 944)
|
||||
(pt 1368 944)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 1848 960)
|
||||
(pt 1368 960)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 1000 288)
|
||||
(pt 1000 592)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 984 304)
|
||||
(pt 984 608)
|
||||
)
|
||||
(connector
|
||||
(pt 968 320)
|
||||
(pt 968 624)
|
||||
)
|
||||
(connector
|
||||
(pt 952 336)
|
||||
(pt 952 640)
|
||||
)
|
||||
(connector
|
||||
(pt 608 656)
|
||||
(pt 712 656)
|
||||
)
|
||||
(connector
|
||||
(pt 1040 656)
|
||||
(pt 808 656)
|
||||
)
|
||||
(connector
|
||||
(pt 544 672)
|
||||
(pt 712 672)
|
||||
)
|
||||
(connector
|
||||
(pt 608 576)
|
||||
(pt 608 656)
|
||||
)
|
||||
(connector
|
||||
(pt 608 976)
|
||||
(pt 712 976)
|
||||
)
|
||||
(connector
|
||||
(pt 1040 976)
|
||||
(pt 808 976)
|
||||
)
|
||||
(connector
|
||||
(pt 536 992)
|
||||
(pt 712 992)
|
||||
)
|
||||
(connector
|
||||
(pt 608 656)
|
||||
(pt 608 896)
|
||||
)
|
||||
(connector
|
||||
(pt 608 32)
|
||||
(pt 704 32)
|
||||
)
|
||||
(connector
|
||||
(pt 544 32)
|
||||
(pt 608 32)
|
||||
)
|
||||
(connector
|
||||
(pt 608 896)
|
||||
(pt 608 976)
|
||||
)
|
||||
(connector
|
||||
(pt 736 1512)
|
||||
(pt 608 1512)
|
||||
)
|
||||
(connector
|
||||
(pt 736 1528)
|
||||
(pt 536 1528)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 608 1432)
|
||||
(pt 1048 1432)
|
||||
)
|
||||
(connector
|
||||
(pt 1000 1448)
|
||||
(pt 1048 1448)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 984 1464)
|
||||
(pt 1048 1464)
|
||||
)
|
||||
(connector
|
||||
(pt 968 1480)
|
||||
(pt 1048 1480)
|
||||
)
|
||||
(connector
|
||||
(pt 952 1496)
|
||||
(pt 1048 1496)
|
||||
)
|
||||
(connector
|
||||
(pt 1848 1448)
|
||||
(pt 1376 1448)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 1848 1464)
|
||||
(pt 1376 1464)
|
||||
)
|
||||
(connector
|
||||
(pt 864 1512)
|
||||
(pt 1048 1512)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 912 1528)
|
||||
(pt 1048 1528)
|
||||
)
|
||||
(connector
|
||||
(pt 912 1496)
|
||||
(pt 912 1528)
|
||||
)
|
||||
(connector
|
||||
(pt 608 976)
|
||||
(pt 608 1432)
|
||||
)
|
||||
(connector
|
||||
(pt 608 1432)
|
||||
(pt 608 1512)
|
||||
)
|
||||
(connector
|
||||
(pt 1000 592)
|
||||
(pt 1000 912)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 1000 912)
|
||||
(pt 1000 1448)
|
||||
(bus)
|
||||
)
|
||||
(connector
|
||||
(pt 984 608)
|
||||
(pt 984 928)
|
||||
)
|
||||
(connector
|
||||
(pt 984 928)
|
||||
(pt 984 1464)
|
||||
)
|
||||
(connector
|
||||
(pt 968 624)
|
||||
(pt 968 944)
|
||||
)
|
||||
(connector
|
||||
(pt 968 944)
|
||||
(pt 968 1480)
|
||||
)
|
||||
(connector
|
||||
(pt 952 640)
|
||||
(pt 952 960)
|
||||
)
|
||||
(connector
|
||||
(pt 952 960)
|
||||
(pt 952 1496)
|
||||
)
|
||||
(junction (pt 608 32))
|
||||
(junction (pt 1000 288))
|
||||
(junction (pt 984 304))
|
||||
@ -1506,3 +1875,9 @@ applicable agreement for further details.
|
||||
(junction (pt 608 408))
|
||||
(junction (pt 1712 0))
|
||||
(junction (pt 1712 64))
|
||||
(junction (pt 608 976))
|
||||
(junction (pt 1000 912))
|
||||
(junction (pt 984 928))
|
||||
(junction (pt 968 944))
|
||||
(junction (pt 952 960))
|
||||
(junction (pt 608 1432))
|
||||
|
@ -198,4 +198,86 @@ set_global_assignment -name OUTPUT_IO_TIMING_NEAR_END_VMEAS "HALF VCCIO" -rise
|
||||
set_global_assignment -name OUTPUT_IO_TIMING_NEAR_END_VMEAS "HALF VCCIO" -fall
|
||||
set_global_assignment -name OUTPUT_IO_TIMING_FAR_END_VMEAS "HALF SIGNAL SWING" -rise
|
||||
set_global_assignment -name OUTPUT_IO_TIMING_FAR_END_VMEAS "HALF SIGNAL SWING" -fall
|
||||
set_global_assignment -name VHDL_FILE RAM9X8_PWM.vhd
|
||||
set_global_assignment -name BDF_FILE DigitalFilterBlockSingle.bdf
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to PWM[5]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to PWM[4]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to PWM[3]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[0]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[5]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[9]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[14]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to PWM[2]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to Error
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to Interrupt
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to PWM[1]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to PWM[0]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[1]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[2]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[3]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[4]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[6]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[7]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[8]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[10]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[11]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[12]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[13]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[15]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[16]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[17]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[18]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[19]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[20]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[21]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[22]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[23]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[24]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[25]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[26]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[27]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[28]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[29]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[30]
|
||||
set_instance_assignment -name IO_STANDARD "3.3-V LVTTL" -to TK[31]
|
||||
set_location_assignment PIN_236 -to Interrupt
|
||||
set_location_assignment PIN_202 -to PWM[0]
|
||||
set_location_assignment PIN_201 -to PWM[1]
|
||||
set_location_assignment PIN_203 -to PWM[2]
|
||||
set_location_assignment PIN_216 -to PWM[3]
|
||||
set_location_assignment PIN_214 -to PWM[4]
|
||||
set_location_assignment PIN_207 -to PWM[5]
|
||||
set_location_assignment PIN_134 -to TK[0]
|
||||
set_location_assignment PIN_133 -to TK[1]
|
||||
set_location_assignment PIN_128 -to TK[2]
|
||||
set_location_assignment PIN_164 -to TK[3]
|
||||
set_location_assignment PIN_162 -to TK[4]
|
||||
set_location_assignment PIN_161 -to TK[5]
|
||||
set_location_assignment PIN_160 -to TK[6]
|
||||
set_location_assignment PIN_159 -to TK[7]
|
||||
set_location_assignment PIN_146 -to TK[8]
|
||||
set_location_assignment PIN_139 -to TK[9]
|
||||
set_location_assignment PIN_145 -to TK[10]
|
||||
set_location_assignment PIN_144 -to TK[11]
|
||||
set_location_assignment PIN_137 -to TK[12]
|
||||
set_location_assignment PIN_147 -to TK[13]
|
||||
set_location_assignment PIN_135 -to TK[14]
|
||||
set_location_assignment PIN_142 -to TK[15]
|
||||
set_location_assignment PIN_181 -to TK[16]
|
||||
set_location_assignment PIN_182 -to TK[17]
|
||||
set_location_assignment PIN_183 -to TK[18]
|
||||
set_location_assignment PIN_184 -to TK[19]
|
||||
set_location_assignment PIN_132 -to TK[20]
|
||||
set_location_assignment PIN_131 -to TK[21]
|
||||
set_location_assignment PIN_112 -to TK[22]
|
||||
set_location_assignment PIN_111 -to TK[23]
|
||||
set_location_assignment PIN_117 -to TK[24]
|
||||
set_location_assignment PIN_185 -to TK[25]
|
||||
set_location_assignment PIN_186 -to TK[26]
|
||||
set_location_assignment PIN_114 -to TK[27]
|
||||
set_location_assignment PIN_120 -to TK[28]
|
||||
set_location_assignment PIN_119 -to TK[29]
|
||||
set_location_assignment PIN_113 -to TK[30]
|
||||
set_location_assignment PIN_118 -to TK[31]
|
||||
set_global_assignment -name BDF_FILE DigitalFilterBlock6.bdf
|
||||
set_instance_assignment -name PARTITION_HIERARCHY root_partition -to | -section_id Top
|
230
MainController/RAM9X8_PWM.bsf
Normal file
230
MainController/RAM9X8_PWM.bsf
Normal file
@ -0,0 +1,230 @@
|
||||
/*
|
||||
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-2013 Altera Corporation
|
||||
Your use of Altera Corporation's design tools, logic functions
|
||||
and other software and tools, and its AMPP partner logic
|
||||
functions, and any output files from any of the foregoing
|
||||
(including device programming or simulation files), and any
|
||||
associated documentation or information are expressly subject
|
||||
to the terms and conditions of the Altera Program License
|
||||
Subscription Agreement, Altera MegaCore Function License
|
||||
Agreement, or other applicable license agreement, including,
|
||||
without limitation, that your use is for the sole purpose of
|
||||
programming logic devices manufactured by Altera and sold by
|
||||
Altera or its authorized distributors. Please refer to the
|
||||
applicable agreement for further details.
|
||||
*/
|
||||
(header "symbol" (version "1.1"))
|
||||
(symbol
|
||||
(rect 16 16 344 192)
|
||||
(text "RAM9X8_PWM" (rect 5 0 75 12)(font "Arial" ))
|
||||
(text "inst" (rect 8 160 20 172)(font "Arial" ))
|
||||
(port
|
||||
(pt 0 32)
|
||||
(input)
|
||||
(text "clk" (rect 0 0 10 12)(font "Arial" ))
|
||||
(text "clk" (rect 21 27 31 39)(font "Arial" ))
|
||||
(line (pt 0 32)(pt 16 32)(line_width 1))
|
||||
)
|
||||
(port
|
||||
(pt 0 48)
|
||||
(input)
|
||||
(text "address[address_bus_width-1..0]" (rect 0 0 129 12)(font "Arial" ))
|
||||
(text "address[address_bus_width-1..0]" (rect 21 43 150 55)(font "Arial" ))
|
||||
(line (pt 0 48)(pt 16 48)(line_width 3))
|
||||
)
|
||||
(port
|
||||
(pt 0 64)
|
||||
(input)
|
||||
(text "we" (rect 0 0 10 12)(font "Arial" ))
|
||||
(text "we" (rect 21 59 31 71)(font "Arial" ))
|
||||
(line (pt 0 64)(pt 16 64)(line_width 1))
|
||||
)
|
||||
(port
|
||||
(pt 0 80)
|
||||
(input)
|
||||
(text "oe" (rect 0 0 9 12)(font "Arial" ))
|
||||
(text "oe" (rect 21 75 30 87)(font "Arial" ))
|
||||
(line (pt 0 80)(pt 16 80)(line_width 1))
|
||||
)
|
||||
(port
|
||||
(pt 0 96)
|
||||
(input)
|
||||
(text "ce" (rect 0 0 9 12)(font "Arial" ))
|
||||
(text "ce" (rect 21 91 30 103)(font "Arial" ))
|
||||
(line (pt 0 96)(pt 16 96)(line_width 1))
|
||||
)
|
||||
(port
|
||||
(pt 0 112)
|
||||
(input)
|
||||
(text "pwm[5..0]" (rect 0 0 38 12)(font "Arial" ))
|
||||
(text "pwm[5..0]" (rect 21 107 59 119)(font "Arial" ))
|
||||
(line (pt 0 112)(pt 16 112)(line_width 3))
|
||||
)
|
||||
(port
|
||||
(pt 0 128)
|
||||
(input)
|
||||
(text "error" (rect 0 0 20 12)(font "Arial" ))
|
||||
(text "error" (rect 21 123 41 135)(font "Arial" ))
|
||||
(line (pt 0 128)(pt 16 128)(line_width 1))
|
||||
)
|
||||
(port
|
||||
(pt 328 48)
|
||||
(output)
|
||||
(text "tk[31..0]" (rect 0 0 30 12)(font "Arial" ))
|
||||
(text "tk[31..0]" (rect 277 43 307 55)(font "Arial" ))
|
||||
(line (pt 328 48)(pt 312 48)(line_width 3))
|
||||
)
|
||||
(port
|
||||
(pt 328 64)
|
||||
(output)
|
||||
(text "interrupt" (rect 0 0 31 12)(font "Arial" ))
|
||||
(text "interrupt" (rect 276 59 307 71)(font "Arial" ))
|
||||
(line (pt 328 64)(pt 312 64)(line_width 1))
|
||||
)
|
||||
(port
|
||||
(pt 328 32)
|
||||
(bidir)
|
||||
(text "data[data_bus_width-1..0]" (rect 0 0 99 12)(font "Arial" ))
|
||||
(text "data[data_bus_width-1..0]" (rect 208 27 307 39)(font "Arial" ))
|
||||
(line (pt 328 32)(pt 312 32)(line_width 3))
|
||||
)
|
||||
(parameter
|
||||
"REG_ADDR_MODE_CONTROL_UPPER_BYTE"
|
||||
"14"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_MODE_CONTROL_LOWER_BYTE"
|
||||
"15"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_MASK_2_UPPER_BYTE"
|
||||
"16"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_MASK_2_LOWER_BYTE"
|
||||
"17"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_MASK_1_UPPER_BYTE"
|
||||
"18"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_MASK_1_LOWER_BYTE"
|
||||
"19"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECT_CONTROL_2_UPPER_BYTE"
|
||||
"20"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECT_CONTROL_2_LOWER_BYTE"
|
||||
"21"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECT_CONTROL_1_UPPER_BYTE"
|
||||
"22"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECT_CONTROL_1_LOWER_BYTE"
|
||||
"23"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_PERIOD_UPPER_BYTE"
|
||||
"24"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_PERIOD_LOWER_BYTE"
|
||||
"25"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECTION_2_UPPER_BYTE"
|
||||
"26"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECTION_2_LOWER_BYTE"
|
||||
"27"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECTION_1_UPPER_BYTE"
|
||||
"28"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_DIRECTION_1_LOWER_BYTE"
|
||||
"29"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CHANNEL_UPPER_BYTE"
|
||||
"30"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CHANNEL_LOWER_BYTE"
|
||||
"31"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_TIMING_UPPER_BYTE"
|
||||
"32"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_TIMING_LOWER_BYTE"
|
||||
"33"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CMD_UPPER_BYTE"
|
||||
"34"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CMD_LOWER_BYTE"
|
||||
"35"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CONTROL_UPPER_BYTE"
|
||||
"36"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"REG_ADDR_CONTROL_LOWER_BYTE"
|
||||
"37"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"DATA_BUS_WIDTH"
|
||||
"8"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(parameter
|
||||
"ADDRESS_BUS_WIDTH"
|
||||
"9"
|
||||
""
|
||||
(type "PARAMETER_SIGNED_DEC") )
|
||||
(drawing
|
||||
(rectangle (rect 16 16 312 160)(line_width 1))
|
||||
)
|
||||
(annotation_block (parameter)(rect 344 -64 444 16))
|
||||
)
|
@ -1,3 +1,8 @@
|
||||
library ieee;
|
||||
use ieee.std_logic_1164.all;
|
||||
use ieee.std_logic_arith.all;
|
||||
use ieee.std_logic_unsigned.all;
|
||||
|
||||
entity RAM9X8_PWM is
|
||||
generic(
|
||||
REG_ADDR_MODE_CONTROL_UPPER_BYTE : integer := 14;
|
||||
@ -12,16 +17,18 @@ entity RAM9X8_PWM is
|
||||
REG_ADDR_DIRECT_CONTROL_1_LOWER_BYTE : integer := 23;
|
||||
REG_ADDR_PERIOD_UPPER_BYTE : integer := 24;
|
||||
REG_ADDR_PERIOD_LOWER_BYTE : integer := 25;
|
||||
REG_ADDR_DIRECTION_UPPER_BYTE : integer := 26;
|
||||
REG_ADDR_DIRECTION_LOWER_BYTE : integer := 27;
|
||||
REG_ADDR_CHANNEL_UPPER_BYTE : integer := 28;
|
||||
REG_ADDR_CHANNEL_LOWER_BYTE : integer := 29;
|
||||
REG_ADDR_TIMING_UPPER_BYTE : integer := 30;
|
||||
REG_ADDR_TIMING_LOWER_BYTE : integer := 31;
|
||||
REG_ADDR_CMD_UPPER_BYTE : integer := 32;
|
||||
REG_ADDR_CMD_LOWER_BYTE : integer := 33;
|
||||
REG_ADDR_CONTROL_UPPER_BYTE : integer := 34;
|
||||
REG_ADDR_CONTROL_LOWER_BYTE : integer := 35;
|
||||
REG_ADDR_DIRECTION_2_UPPER_BYTE : integer := 26;
|
||||
REG_ADDR_DIRECTION_2_LOWER_BYTE : integer := 27;
|
||||
REG_ADDR_DIRECTION_1_UPPER_BYTE : integer := 28;
|
||||
REG_ADDR_DIRECTION_1_LOWER_BYTE : integer := 29;
|
||||
REG_ADDR_CHANNEL_UPPER_BYTE : integer := 30;
|
||||
REG_ADDR_CHANNEL_LOWER_BYTE : integer := 31;
|
||||
REG_ADDR_TIMING_UPPER_BYTE : integer := 32;
|
||||
REG_ADDR_TIMING_LOWER_BYTE : integer := 33;
|
||||
REG_ADDR_CMD_UPPER_BYTE : integer := 34;
|
||||
REG_ADDR_CMD_LOWER_BYTE : integer := 35;
|
||||
REG_ADDR_CONTROL_UPPER_BYTE : integer := 36;
|
||||
REG_ADDR_CONTROL_LOWER_BYTE : integer := 37;
|
||||
|
||||
DATA_BUS_WIDTH : integer := 8;
|
||||
ADDRESS_BUS_WIDTH : integer := 9
|
||||
@ -38,7 +45,8 @@ entity RAM9X8_PWM is
|
||||
|
||||
tk : out std_logic_vector(31 downto 0) := (others => '1');
|
||||
interrupt : out std_logic := '1';
|
||||
pwm : in std_logic_vector(5 downto 0)
|
||||
pwm : in std_logic_vector(5 downto 0);
|
||||
error : in std_logic
|
||||
);
|
||||
end entity;
|
||||
|
||||
@ -48,30 +56,38 @@ signal modeBuf : std_logic_vector(15 downto 0) := (others => '0');
|
||||
signal maskBuf : std_logic_vector(31 downto 0) := (others => '1');
|
||||
signal directControlBuf : std_logic_vector(31 downto 0) := (others => '1');
|
||||
signal periodBuf : std_logic_vector(15 downto 0) := (others => '0');
|
||||
signal directionBuf : std_logic_vector(15 downto 0) := (others => '0');
|
||||
signal directionBuf : std_logic_vector(31 downto 0) := (others => '0');
|
||||
signal channelBuf : std_logic_vector(15 downto 0) := (others => '0');
|
||||
signal cmdBuf : std_logic_vector(15 downto 0) := (others => '0');
|
||||
signal controlBuf : std_logic_vector(15 downto 0) := (others => '0');
|
||||
|
||||
type mem is array (15 downto 0) of std_logic_vector(15 downto 0);
|
||||
signal memory : mem;
|
||||
signal tkBuf : std_logic_vector(31 downto 0) := (others => '1');
|
||||
|
||||
signal lineBusy : std_logic := '1';
|
||||
signal start : std_logic := '0';
|
||||
signal startPrev : std_logic := '0';
|
||||
type mem is array (31 downto 0) of std_logic_vector(15 downto 0);
|
||||
signal memory : mem;
|
||||
signal memoryBuf : mem;
|
||||
|
||||
signal pwm3level : std_logic_vector(31 downto 0) := (others => '1');
|
||||
signal upDown : std_logic := '0';
|
||||
signal upDownPrev : std_logic := '0';
|
||||
signal interruptBuf : std_logic := '0';
|
||||
signal period : std_logic_vector(15 downto 0) := (others => '0');
|
||||
signal counter : std_logic_vector(15 downto 0) := (others => '0');
|
||||
|
||||
signal enableWriteControlBuf : std_logic := '1';
|
||||
|
||||
begin
|
||||
|
||||
process (we, oe, ce)
|
||||
variable addr : integer range 0 to 2**ADDRESS_BUS_WIDTH - 1 := 0;
|
||||
variable position : integer range 0 to ARRAY_LENGTH - 1 := 0;
|
||||
begin
|
||||
if (ce = '0') then -- Если микросхема выбрана
|
||||
addr := conv_integer(address);
|
||||
if (addr = REG_ADDR_MODE_CONTROL_UPPER_BYTE or addr = REG_ADDR_MODE_CONTROL_LOWER_BYTE
|
||||
or addr = REG_ADDR_MASK_2_UPPER_BYTE or addr = REG_ADDR_MASK_2_LOWER_BYTE or addr = REG_ADDR_MASK_1_UPPER_BYTE or addr = REG_ADDR_MASK_1_LOWER_BYTE
|
||||
or addr = REG_ADDR_DIRECT_CONTROL_2_UPPER_BYTE or addr = REG_ADDR_DIRECT_CONTROL_2_LOWER_BYTE or addr = REG_ADDR_DIRECT_CONTROL_1_UPPER_BYTE or addr = REG_ADDR_DIRECT_CONTROL_1_LOWER_BYTE
|
||||
or addr = REG_ADDR_PERIOD_UPPER_BYTE or addr = REG_ADDR_PERIOD_LOWER_BYTE or addr = REG_ADDR_DIRECTION_UPPER_BYTE or addr = REG_ADDR_DIRECTION_LOWER_BYTE
|
||||
or addr = REG_ADDR_PERIOD_UPPER_BYTE or addr = REG_ADDR_PERIOD_LOWER_BYTE
|
||||
or addr = REG_ADDR_DIRECTION_2_UPPER_BYTE or addr = REG_ADDR_DIRECTION_2_LOWER_BYTE or addr = REG_ADDR_DIRECTION_1_UPPER_BYTE or addr = REG_ADDR_DIRECTION_1_LOWER_BYTE
|
||||
or addr = REG_ADDR_CHANNEL_UPPER_BYTE or addr = REG_ADDR_CHANNEL_LOWER_BYTE or addr = REG_ADDR_TIMING_UPPER_BYTE or addr = REG_ADDR_TIMING_LOWER_BYTE
|
||||
or addr = REG_ADDR_CMD_UPPER_BYTE or addr = REG_ADDR_CMD_LOWER_BYTE or addr = REG_ADDR_CONTROL_UPPER_BYTE or addr = REG_ADDR_CONTROL_LOWER_BYTE) then
|
||||
if (oe = '0' and we = '1') then -- Если сигнал чтения активен, а записи нет
|
||||
@ -100,18 +116,22 @@ begin
|
||||
data <= periodBuf(15 downto 8);
|
||||
when REG_ADDR_PERIOD_LOWER_BYTE =>
|
||||
data <= periodBuf(7 downto 0);
|
||||
when REG_ADDR_DIRECTION_UPPER_BYTEE =>
|
||||
when REG_ADDR_DIRECTION_2_UPPER_BYTE =>
|
||||
data <= directionBuf(31 downto 24);
|
||||
when REG_ADDR_DIRECTION_2_LOWER_BYTE =>
|
||||
data <= directionBuf(23 downto 16);
|
||||
when REG_ADDR_DIRECTION_1_UPPER_BYTE =>
|
||||
data <= directionBuf(15 downto 8);
|
||||
when REG_ADDR_DIRECTION_LOWER_BYTE =>
|
||||
when REG_ADDR_DIRECTION_1_LOWER_BYTE =>
|
||||
data <= directionBuf(7 downto 0);
|
||||
when REG_ADDR_CHANNEL_UPPER_BYTE =>
|
||||
data <= channelBuf(15 downto 8);
|
||||
when REG_ADDR_CHANNEL_LOWER_BYTE =>
|
||||
data <= channelBuf(7 downto 0);
|
||||
when REG_ADDR_TIMING_UPPER_BYTE =>
|
||||
data <= memory(conv_integer(channelBuf)(15 downto 8));
|
||||
data <= memory(conv_integer(channelBuf))(15 downto 8);
|
||||
when REG_ADDR_TIMING_LOWER_BYTE =>
|
||||
data <= memory(conv_integer(channelBuf)(7 downto 0);
|
||||
data <= memory(conv_integer(channelBuf))(7 downto 0);
|
||||
when REG_ADDR_CMD_UPPER_BYTE =>
|
||||
data <= cmdBuf(15 downto 8);
|
||||
when REG_ADDR_CMD_LOWER_BYTE =>
|
||||
@ -123,6 +143,12 @@ begin
|
||||
when others =>
|
||||
data <= (others => 'Z'); -- Запретить запись на шину
|
||||
end case;
|
||||
|
||||
if addr /= REG_ADDR_CONTROL_UPPER_BYTE then
|
||||
enableWriteControlBuf <= '1';
|
||||
else
|
||||
enableWriteControlBuf <= '0';
|
||||
end if;
|
||||
elsif (oe = '1' and we = '0') then -- Если сигнал записи активен, а чтения нет
|
||||
case addr is
|
||||
when REG_ADDR_MODE_CONTROL_UPPER_BYTE =>
|
||||
@ -149,32 +175,36 @@ begin
|
||||
periodBuf(15 downto 8) <= data;
|
||||
when REG_ADDR_PERIOD_LOWER_BYTE =>
|
||||
periodBuf(7 downto 0) <= data;
|
||||
when REG_ADDR_DIRECTION_UPPER_BYTEE =>
|
||||
when REG_ADDR_DIRECTION_2_UPPER_BYTE =>
|
||||
directionBuf(31 downto 24) <= data;
|
||||
when REG_ADDR_DIRECTION_2_LOWER_BYTE =>
|
||||
directionBuf(23 downto 16) <= data;
|
||||
when REG_ADDR_DIRECTION_1_UPPER_BYTE =>
|
||||
directionBuf(15 downto 8) <= data;
|
||||
when REG_ADDR_DIRECTION_LOWER_BYTE =>
|
||||
when REG_ADDR_DIRECTION_1_LOWER_BYTE =>
|
||||
directionBuf(7 downto 0) <= data;
|
||||
when REG_ADDR_CHANNEL_UPPER_BYTE =>
|
||||
channelBuf(15 downto 8) <= data;
|
||||
when REG_ADDR_CHANNEL_LOWER_BYTE =>
|
||||
channelBuf(7 downto 0) <= data;
|
||||
when REG_ADDR_TIMING_UPPER_BYTE =>
|
||||
memory(conv_integer(channelBuf)(15 downto 8)) <= data;
|
||||
memory(conv_integer(channelBuf))(15 downto 8) <= data;
|
||||
when REG_ADDR_TIMING_LOWER_BYTE =>
|
||||
memory(conv_integer(channelBuf)(7 downto 0) <= data;
|
||||
memory(conv_integer(channelBuf))(7 downto 0) <= data;
|
||||
when REG_ADDR_CMD_UPPER_BYTE =>
|
||||
cmdBuf(15 downto 8) <= data;
|
||||
when REG_ADDR_CMD_LOWER_BYTE =>
|
||||
cmdBuf(7 downto 0) <= data;
|
||||
when REG_ADDR_CONTROL_UPPER_BYTE =>
|
||||
controlBuf(15 downto 8) <= data;
|
||||
when REG_ADDR_CONTROL_LOWER_BYTE =>
|
||||
controlBuf(7 downto 0) <= data;
|
||||
-- when REG_ADDR_CONTROL_UPPER_BYTE =>
|
||||
-- controlBuf(15 downto 8) <= data;
|
||||
-- when REG_ADDR_CONTROL_LOWER_BYTE =>
|
||||
-- controlBuf(7 downto 0) <= data;
|
||||
when others =>
|
||||
data <= (others => 'Z'); -- Запретить запись на шину
|
||||
end case;
|
||||
else
|
||||
data <= (others => 'Z'); -- Запретить запись на шину
|
||||
end if;;
|
||||
end if;
|
||||
else
|
||||
data <= (others => 'Z'); -- Запретить запись на шину
|
||||
end if;
|
||||
@ -184,25 +214,153 @@ begin
|
||||
end process;
|
||||
|
||||
process(clk) is
|
||||
variable counter : integer range 0 to 65666 := 0;
|
||||
begin
|
||||
if(rising_edge clk) then
|
||||
if(conv_integer(memory(0)) > counter) then
|
||||
if(directionBuf(0) = '0') then
|
||||
pwm3level(0) <= '0';
|
||||
if rising_edge(clk) then
|
||||
if upDown = '0' then
|
||||
if conv_integer(counter) < conv_integer(period) then
|
||||
counter <= counter + 1;
|
||||
else
|
||||
pwm3level(0) <= '1';
|
||||
counter <= period;
|
||||
updown <= '1';
|
||||
end if;
|
||||
else
|
||||
if(directionBuf(0) = '0') then
|
||||
pwm3level(0) <= '1';
|
||||
if conv_integer(counter) > 0 then
|
||||
counter <= counter - 1;
|
||||
else
|
||||
pwm3level(0) <= '0';
|
||||
counter <= (others => '0');
|
||||
upDown <= '0';
|
||||
end if;
|
||||
end if;
|
||||
|
||||
|
||||
|
||||
upDownPrev <= upDown;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
process(clk) is
|
||||
variable count : integer range 0 to 7 := 0;
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
if upDown /= upDownPrev then
|
||||
count := 0;
|
||||
if cmdBuf(14) = '0' then
|
||||
interrupt <= '1';
|
||||
else
|
||||
if updown = '0' then
|
||||
interrupt <= '1';
|
||||
interruptBuf <= '1';
|
||||
period <= periodBuf; -- новый период грузится сразу во время начала подъема пилы
|
||||
end if;
|
||||
end if;
|
||||
else
|
||||
if count < 7 then
|
||||
count := count + 1;
|
||||
else
|
||||
interrupt <= '0';
|
||||
interruptBuf <= '0';
|
||||
end if;
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
process(interruptBuf) is
|
||||
begin
|
||||
if interruptBuf = '0' then
|
||||
for i in 0 to 31 loop
|
||||
memoryBuf(i) <= memory(i); -- а вот новые значения таймингов загрузяться только после счетчика. Но зато могут грузиться дважды за период, если выбран соответствующий тип формирования прерывания
|
||||
end loop;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
process(clk) is
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
for i in 0 to 11 loop
|
||||
if(conv_integer(memoryBuf(i)) > counter) then
|
||||
if(directionBuf(i) = '0') then
|
||||
pwm3level(i) <= '0';
|
||||
else
|
||||
pwm3level(i) <= '1';
|
||||
end if;
|
||||
else
|
||||
if(directionBuf(i) = '0') then
|
||||
pwm3level(i) <= '1';
|
||||
else
|
||||
pwm3level(i) <= '0';
|
||||
end if;
|
||||
end if;
|
||||
end loop;
|
||||
|
||||
for i in 12 to 15 loop
|
||||
if(conv_integer(memoryBuf(i)) > counter) then
|
||||
pwm3level(i) <= '0';
|
||||
else
|
||||
pwm3level(i) <= '1';
|
||||
end if;
|
||||
end loop;
|
||||
|
||||
for i in 16 to 27 loop
|
||||
if(conv_integer(memoryBuf(i)) > counter) then
|
||||
if(directionBuf(i) = '0') then
|
||||
pwm3level(i) <= '0';
|
||||
else
|
||||
pwm3level(i) <= '1';
|
||||
end if;
|
||||
else
|
||||
if(directionBuf(i) = '0') then
|
||||
pwm3level(i) <= '1';
|
||||
else
|
||||
pwm3level(i) <= '0';
|
||||
end if;
|
||||
end if;
|
||||
end loop;
|
||||
|
||||
for i in 28 to 31 loop
|
||||
if(conv_integer(memoryBuf(i)) > counter) then
|
||||
pwm3level(i) <= '0';
|
||||
else
|
||||
pwm3level(i) <= '1';
|
||||
end if;
|
||||
end loop;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
process(clk) is
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
case modeBuf is
|
||||
when x"0000" =>
|
||||
tkBuf <= pwm3level;
|
||||
when x"0001" =>
|
||||
tkBuf <= (others => '1');
|
||||
tkBuf(5 downto 0) <= pwm;
|
||||
when x"0002" =>
|
||||
tkBuf <= pwm3level;
|
||||
when x"0003" =>
|
||||
tkBuf <= directControlBuf;
|
||||
when others =>
|
||||
tkBuf <= (others => '1');
|
||||
end case;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
process(clk) is
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
if cmdBuf(15) = '1' and error = '1' then
|
||||
tk <= tkBuf or maskBuf;
|
||||
else
|
||||
tk <= (others => '1');
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
process(clk) is
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
if enableWriteControlBuf = '1' then
|
||||
controlBuf <= counter;
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
|
||||
end behavorial;
|
Loading…
Reference in New Issue
Block a user