From 739ab6105f074e6514ad0681afd2e7994287a133 Mon Sep 17 00:00:00 2001 From: Pacien TRAN-GIRARD Date: Fri, 11 Apr 2014 21:43:11 +0200 Subject: Replace combinatory logic by mux --- FPGA/commande/commande.qsf | 1 + FPGA/commande/fan.bdf | 389 ++++++++++++++++++++++----------------------- 2 files changed, 194 insertions(+), 196 deletions(-) diff --git a/FPGA/commande/commande.qsf b/FPGA/commande/commande.qsf index 9f700cb..e64ba9e 100644 --- a/FPGA/commande/commande.qsf +++ b/FPGA/commande/commande.qsf @@ -68,4 +68,5 @@ set_location_assignment PIN_AB21 -to speed[0] set_location_assignment PIN_AF23 -to fan_auto set_location_assignment PIN_AE23 -to alarm set_global_assignment -name STRATIX_DEVICE_IO_STANDARD "3.3-V LVTTL" +set_global_assignment -name RESERVE_ALL_UNUSED_PINS_NO_OUTPUT_GND "AS INPUT TRI-STATED" set_instance_assignment -name PARTITION_HIERARCHY root_partition -to | -section_id Top \ No newline at end of file diff --git a/FPGA/commande/fan.bdf b/FPGA/commande/fan.bdf index b67a23a..7a62110 100644 --- a/FPGA/commande/fan.bdf +++ b/FPGA/commande/fan.bdf @@ -23,7 +23,7 @@ applicable agreement for further details. (input) (rect 48 40 224 56) (text "INPUT" (rect 133 0 161 10)(font "Arial" (font_size 6))) - (text "fan_auto_user" (rect 5 0 77 11)(font "Arial" )) + (text "fan_auto_user" (rect 5 0 76 11)(font "Arial" )) (pt 176 8) (drawing (line (pt 92 12)(pt 117 12)) @@ -39,7 +39,7 @@ applicable agreement for further details. (input) (rect 48 56 224 72) (text "INPUT" (rect 133 0 161 10)(font "Arial" (font_size 6))) - (text "fan_speed[1..0]" (rect 5 0 82 11)(font "Arial" )) + (text "fan_speed[1..0]" (rect 5 0 81 11)(font "Arial" )) (pt 176 8) (drawing (line (pt 92 12)(pt 117 12)) @@ -55,7 +55,7 @@ applicable agreement for further details. (input) (rect 56 72 224 88) (text "INPUT" (rect 125 0 153 10)(font "Arial" (font_size 6))) - (text "hot" (rect 5 0 21 11)(font "Arial" )) + (text "hot" (rect 5 0 20 11)(font "Arial" )) (pt 168 8) (drawing (line (pt 84 12)(pt 109 12)) @@ -71,7 +71,7 @@ applicable agreement for further details. (input) (rect 56 24 224 40) (text "INPUT" (rect 125 0 153 10)(font "Arial" (font_size 6))) - (text "enable" (rect 5 0 39 11)(font "Arial" )) + (text "enable" (rect 5 0 38 11)(font "Arial" )) (pt 168 8) (drawing (line (pt 84 12)(pt 109 12)) @@ -85,7 +85,7 @@ applicable agreement for further details. ) (pin (output) - (rect 544 24 720 40) + (rect 664 24 840 40) (text "OUTPUT" (rect 1 0 39 10)(font "Arial" (font_size 6))) (text "fan_auto" (rect 90 0 133 11)(font "Arial" )) (pt 0 8) @@ -101,7 +101,7 @@ applicable agreement for further details. ) (pin (output) - (rect 544 40 720 56) + (rect 664 40 840 56) (text "OUTPUT" (rect 1 0 39 10)(font "Arial" (font_size 6))) (text "speed[1..0]" (rect 90 0 145 11)(font "Arial" )) (pt 0 8) @@ -116,297 +116,294 @@ applicable agreement for further details. ) ) (symbol - (rect 352 24 416 72) - (text "AND2" (rect 1 0 28 10)(font "Arial" (font_size 6))) - (text "inst" (rect 3 37 20 48)(font "Arial" )) + (rect 368 440 480 528) + (text "BUSMUX" (rect 28 0 95 16)(font "Arial" (font_size 10))) + (text "inst1" (rect 3 77 26 88)(font "Arial" )) (port - (pt 0 16) + (pt 0 64) (input) - (text "IN1" (rect 2 7 22 18)(font "Courier New" (bold))(invisible)) - (text "IN1" (rect 2 7 22 18)(font "Courier New" (bold))(invisible)) - (line (pt 0 16)(pt 14 16)) + (text "datab[WIDTH-1..0]" (rect 6 51 111 64)(font "Arial" (font_size 8))) + (text "datab[]" (rect 6 51 44 64)(font "Arial" (font_size 8))) + (line (pt 0 64)(pt 44 64)(line_width 3)) + ) + (port + (pt 56 88) + (input) + (text "sel" (rect 59 70 75 83)(font "Arial" (font_size 8))) + (text "sel" (rect 59 70 75 83)(font "Arial" (font_size 8))) + (line (pt 56 88)(pt 56 72)) ) (port (pt 0 32) (input) - (text "IN2" (rect 2 23 22 34)(font "Courier New" (bold))(invisible)) - (text "IN2" (rect 2 23 22 34)(font "Courier New" (bold))(invisible)) - (line (pt 0 32)(pt 14 32)) + (text "dataa[WIDTH-1..0]" (rect 6 19 111 32)(font "Arial" (font_size 8))) + (text "dataa[]" (rect 6 19 44 32)(font "Arial" (font_size 8))) + (line (pt 0 32)(pt 44 32)(line_width 3)) ) (port - (pt 64 24) + (pt 112 48) (output) - (text "OUT" (rect 48 15 68 26)(font "Courier New" (bold))(invisible)) - (text "OUT" (rect 48 15 68 26)(font "Courier New" (bold))(invisible)) - (line (pt 42 24)(pt 64 24)) + (text "result[WIDTH-1..0]" (rect 75 35 180 48)(font "Arial" (font_size 8))) + (text "result[]" (rect 75 35 112 48)(font "Arial" (font_size 8))) + (line (pt 68 48)(pt 112 48)(line_width 3)) + ) + (parameter + "WIDTH" + "2" + "Width of I/O, any integer > 0" + " 1" " 2" " 3" " 4" " 5" " 6" " 7" " 8" " 9" "10" "11" "12" "13" "14" "15" "16" "20" "24" "28" "32" "40" "48" "56" "64" ) (drawing - (line (pt 14 12)(pt 30 12)) - (line (pt 14 37)(pt 31 37)) - (line (pt 14 12)(pt 14 37)) - (arc (pt 31 37)(pt 30 12)(rect 18 12 43 37)) + (text "0" (rect 52 31 59 41)(font "Arial" (font_size 6))) + (text "1" (rect 52 55 57 65)(font "Arial" (font_size 6))) + (line (pt 68 64)(pt 68 32)) + (line (pt 44 80)(pt 44 16)) + (line (pt 44 16)(pt 68 32)) + (line (pt 44 80)(pt 68 64)) ) + (annotation_block (parameter)(rect 480 408 600 434)) ) (symbol - (rect 360 216 408 248) - (text "NOT" (rect 1 0 21 10)(font "Arial" (font_size 6))) - (text "inst2" (rect 3 21 26 32)(font "Arial" )) + (rect 368 256 480 344) + (text "BUSMUX" (rect 28 0 95 16)(font "Arial" (font_size 10))) + (text "inst3" (rect 3 77 26 88)(font "Arial" )) (port - (pt 0 16) + (pt 0 64) (input) - (text "IN" (rect 2 7 16 18)(font "Courier New" (bold))(invisible)) - (text "IN" (rect 2 7 16 18)(font "Courier New" (bold))(invisible)) - (line (pt 0 16)(pt 13 16)) + (text "datab[WIDTH-1..0]" (rect 6 51 111 64)(font "Arial" (font_size 8))) + (text "datab[]" (rect 6 51 44 64)(font "Arial" (font_size 8))) + (line (pt 0 64)(pt 44 64)(line_width 3)) ) (port - (pt 48 16) - (output) - (text "OUT" (rect 32 7 52 18)(font "Courier New" (bold))(invisible)) - (text "OUT" (rect 32 7 52 18)(font "Courier New" (bold))(invisible)) - (line (pt 39 16)(pt 48 16)) - ) - (drawing - (line (pt 13 25)(pt 13 7)) - (line (pt 13 7)(pt 31 16)) - (line (pt 13 25)(pt 31 16)) - (circle (rect 31 12 39 20)) - ) -) -(symbol - (rect 352 152 416 200) - (text "AND2" (rect 1 0 28 10)(font "Arial" (font_size 6))) - (text "inst4" (rect 3 37 26 48)(font "Arial" )) - (port - (pt 0 16) + (pt 56 88) (input) - (text "IN1" (rect 2 7 22 18)(font "Courier New" (bold))(invisible)) - (text "IN1" (rect 2 7 22 18)(font "Courier New" (bold))(invisible)) - (line (pt 0 16)(pt 14 16)) + (text "sel" (rect 59 70 75 83)(font "Arial" (font_size 8))) + (text "sel" (rect 59 70 75 83)(font "Arial" (font_size 8))) + (line (pt 56 88)(pt 56 72)) ) (port (pt 0 32) (input) - (text "IN2" (rect 2 23 22 34)(font "Courier New" (bold))(invisible)) - (text "IN2" (rect 2 23 22 34)(font "Courier New" (bold))(invisible)) - (line (pt 0 32)(pt 14 32)) + (text "dataa[WIDTH-1..0]" (rect 6 19 111 32)(font "Arial" (font_size 8))) + (text "dataa[]" (rect 6 19 44 32)(font "Arial" (font_size 8))) + (line (pt 0 32)(pt 44 32)(line_width 3)) ) (port - (pt 64 24) + (pt 112 48) (output) - (text "OUT" (rect 48 15 68 26)(font "Courier New" (bold))(invisible)) - (text "OUT" (rect 48 15 68 26)(font "Courier New" (bold))(invisible)) - (line (pt 42 24)(pt 64 24)) + (text "result[WIDTH-1..0]" (rect 75 35 180 48)(font "Arial" (font_size 8))) + (text "result[]" (rect 75 35 112 48)(font "Arial" (font_size 8))) + (line (pt 68 48)(pt 112 48)(line_width 3)) + ) + (parameter + "WIDTH" + "2" + "Width of I/O, any integer > 0" + " 1" " 2" " 3" " 4" " 5" " 6" " 7" " 8" " 9" "10" "11" "12" "13" "14" "15" "16" "20" "24" "28" "32" "40" "48" "56" "64" ) (drawing - (line (pt 14 12)(pt 30 12)) - (line (pt 14 37)(pt 31 37)) - (line (pt 14 12)(pt 14 37)) - (arc (pt 31 37)(pt 30 12)(rect 18 12 43 37)) + (text "0" (rect 52 31 59 41)(font "Arial" (font_size 6))) + (text "1" (rect 52 55 57 65)(font "Arial" (font_size 6))) + (line (pt 68 64)(pt 68 32)) + (line (pt 44 80)(pt 44 16)) + (line (pt 44 16)(pt 68 32)) + (line (pt 44 80)(pt 68 64)) ) + (annotation_block (parameter)(rect 480 224 600 250)) ) (symbol - (rect 352 264 416 312) - (text "AND3" (rect 1 0 28 10)(font "Arial" (font_size 6))) - (text "inst6" (rect 3 37 26 48)(font "Arial" )) + (rect 392 208 424 240) + (text "GND" (rect 8 16 29 26)(font "Arial" (font_size 6))) + (text "inst" (rect 3 21 20 32)(font "Arial" )(invisible)) (port - (pt 0 16) - (input) - (text "IN1" (rect 2 7 22 18)(font "Courier New" (bold))(invisible)) - (text "IN1" (rect 2 7 22 18)(font "Courier New" (bold))(invisible)) - (line (pt 0 16)(pt 16 16)) + (pt 16 0) + (output) + (text "1" (rect 18 0 25 11)(font "Courier New" (bold))(invisible)) + (text "1" (rect 18 0 25 11)(font "Courier New" (bold))(invisible)) + (line (pt 16 8)(pt 16 0)) ) - (port - (pt 0 24) - (input) - (text "IN2" (rect 2 15 22 26)(font "Courier New" (bold))(invisible)) - (text "IN2" (rect 2 15 22 26)(font "Courier New" (bold))(invisible)) - (line (pt 0 24)(pt 16 24)) + (drawing + (line (pt 8 8)(pt 16 16)) + (line (pt 16 16)(pt 24 8)) + (line (pt 8 8)(pt 24 8)) ) +) +(symbol + (rect 384 32 432 64) + (text "WIRE" (rect 1 0 25 10)(font "Arial" (font_size 6))) + (text "inst4" (rect 3 21 26 32)(font "Arial" )) (port - (pt 0 32) + (pt 0 16) (input) - (text "IN3" (rect 2 23 22 34)(font "Courier New" (bold))(invisible)) - (text "IN3" (rect 2 23 22 34)(font "Courier New" (bold))(invisible)) - (line (pt 0 32)(pt 16 32)) + (text "IN" (rect 2 7 16 18)(font "Courier New" (bold))(invisible)) + (text "IN" (rect 2 7 16 18)(font "Courier New" (bold))(invisible)) + (line (pt 0 16)(pt 14 16)) ) (port - (pt 64 24) + (pt 48 16) (output) - (text "OUT" (rect 48 15 68 26)(font "Courier New" (bold))(invisible)) - (text "OUT" (rect 48 15 68 26)(font "Courier New" (bold))(invisible)) - (line (pt 43 24)(pt 64 24)) + (text "OUT" (rect 32 7 52 18)(font "Courier New" (bold))(invisible)) + (text "OUT" (rect 32 7 52 18)(font "Courier New" (bold))(invisible)) + (line (pt 32 16)(pt 48 16)) ) (drawing - (line (pt 16 12)(pt 31 12)) - (line (pt 16 37)(pt 31 37)) - (line (pt 16 12)(pt 16 37)) - (arc (pt 31 36)(pt 31 12)(rect 19 12 44 37)) + (line (pt 14 7)(pt 32 16)) + (line (pt 14 25)(pt 14 7)) + (line (pt 14 25)(pt 32 16)) ) ) (symbol - (rect 352 328 416 376) - (text "AND3" (rect 1 0 28 10)(font "Arial" (font_size 6))) - (text "inst7" (rect 3 37 26 48)(font "Arial" )) + (rect 384 80 432 112) + (text "WIRE" (rect 1 0 25 10)(font "Arial" (font_size 6))) + (text "inst5" (rect 3 21 26 32)(font "Arial" )) (port (pt 0 16) (input) - (text "IN1" (rect 2 7 22 18)(font "Courier New" (bold))(invisible)) - (text "IN1" (rect 2 7 22 18)(font "Courier New" (bold))(invisible)) - (line (pt 0 16)(pt 16 16)) - ) - (port - (pt 0 24) - (input) - (text "IN2" (rect 2 15 22 26)(font "Courier New" (bold))(invisible)) - (text "IN2" (rect 2 15 22 26)(font "Courier New" (bold))(invisible)) - (line (pt 0 24)(pt 16 24)) - ) - (port - (pt 0 32) - (input) - (text "IN3" (rect 2 23 22 34)(font "Courier New" (bold))(invisible)) - (text "IN3" (rect 2 23 22 34)(font "Courier New" (bold))(invisible)) - (line (pt 0 32)(pt 16 32)) + (text "IN" (rect 2 7 16 18)(font "Courier New" (bold))(invisible)) + (text "IN" (rect 2 7 16 18)(font "Courier New" (bold))(invisible)) + (line (pt 0 16)(pt 14 16)) ) (port - (pt 64 24) + (pt 48 16) (output) - (text "OUT" (rect 48 15 68 26)(font "Courier New" (bold))(invisible)) - (text "OUT" (rect 48 15 68 26)(font "Courier New" (bold))(invisible)) - (line (pt 43 24)(pt 64 24)) + (text "OUT" (rect 32 7 52 18)(font "Courier New" (bold))(invisible)) + (text "OUT" (rect 32 7 52 18)(font "Courier New" (bold))(invisible)) + (line (pt 32 16)(pt 48 16)) ) (drawing - (line (pt 16 12)(pt 31 12)) - (line (pt 16 37)(pt 31 37)) - (line (pt 16 12)(pt 16 37)) - (arc (pt 31 36)(pt 31 12)(rect 19 12 44 37)) + (line (pt 14 7)(pt 32 16)) + (line (pt 14 25)(pt 14 7)) + (line (pt 14 25)(pt 32 16)) ) ) (symbol - (rect 352 88 416 136) - (text "OR2" (rect 1 0 22 10)(font "Arial" (font_size 6))) - (text "inst8" (rect 3 37 26 48)(font "Arial" )) - (port - (pt 0 32) - (input) - (text "IN2" (rect 2 23 22 34)(font "Courier New" (bold))(invisible)) - (text "IN2" (rect 2 23 22 34)(font "Courier New" (bold))(invisible)) - (line (pt 0 32)(pt 15 32)) - ) + (rect 384 112 432 144) + (text "WIRE" (rect 1 0 25 10)(font "Arial" (font_size 6))) + (text "inst6" (rect 3 21 26 32)(font "Arial" )) (port (pt 0 16) (input) - (text "IN1" (rect 2 7 22 18)(font "Courier New" (bold))(invisible)) - (text "IN1" (rect 2 7 22 18)(font "Courier New" (bold))(invisible)) - (line (pt 0 16)(pt 15 16)) + (text "IN" (rect 2 7 16 18)(font "Courier New" (bold))(invisible)) + (text "IN" (rect 2 7 16 18)(font "Courier New" (bold))(invisible)) + (line (pt 0 16)(pt 14 16)) ) (port - (pt 64 24) + (pt 48 16) (output) - (text "OUT" (rect 48 15 68 26)(font "Courier New" (bold))(invisible)) - (text "OUT" (rect 48 15 68 26)(font "Courier New" (bold))(invisible)) - (line (pt 48 24)(pt 64 24)) + (text "OUT" (rect 32 7 52 18)(font "Courier New" (bold))(invisible)) + (text "OUT" (rect 32 7 52 18)(font "Courier New" (bold))(invisible)) + (line (pt 32 16)(pt 48 16)) ) (drawing - (line (pt 14 36)(pt 25 36)) - (line (pt 14 13)(pt 25 13)) - (arc (pt 7 29)(pt 7 19)(rect -14 8 19 41)) - (arc (pt 49 24)(pt 25 13)(rect -6 13 57 76)) - (arc (pt 25 35)(pt 49 24)(rect -6 -27 57 36)) + (line (pt 14 7)(pt 32 16)) + (line (pt 14 25)(pt 14 7)) + (line (pt 14 25)(pt 32 16)) ) ) (connector - (text "fan_auto" (rect 440 40 483 51)(font "Arial" )) - (pt 416 48) + (text "fan_auto_user" (rect 312 32 383 43)(font "Arial" )) + (pt 384 48) + (pt 304 48) +) +(connector + (text "fan_auto" (rect 448 32 491 43)(font "Arial" )) (pt 432 48) + (pt 448 48) +) +(connector + (pt 384 128) + (pt 368 128) ) (connector - (text "enable" (rect 296 32 329 43)(font "Arial" )) - (pt 336 40) - (pt 352 40) + (pt 384 96) + (pt 368 96) ) (connector - (text "fan_auto_user" (rect 264 48 335 59)(font "Arial" )) - (pt 336 56) - (pt 352 56) + (text "hot" (rect 312 96 327 107)(font "Arial" )) + (pt 304 112) + (pt 368 112) ) (connector - (text "not_fan_auto_user" (rect 432 224 525 235)(font "Arial" )) - (pt 408 232) - (pt 424 232) + (pt 368 96) + (pt 368 112) ) (connector - (text "speed[0]" (rect 440 344 482 355)(font "Arial" )) - (pt 416 352) - (pt 432 352) + (pt 368 112) + (pt 368 128) ) (connector - (text "fan_auto" (rect 288 160 331 171)(font "Arial" )) - (pt 336 168) - (pt 352 168) + (text "fan_hot[1]" (rect 442 80 491 91)(font "Arial" )) + (pt 432 96) + (pt 448 96) ) (connector - (text "hot" (rect 312 176 327 187)(font "Arial" )) - (pt 336 184) - (pt 352 184) + (text "fan_hot[0]" (rect 440 112 489 123)(font "Arial" )) + (pt 432 128) + (pt 448 128) ) (connector - (text "enable" (rect 296 272 329 283)(font "Arial" )) - (pt 336 280) - (pt 352 280) + (text "fan_speed[1..0]" (rect 296 272 372 283)(font "Arial" )) + (pt 288 288) + (pt 368 288) + (bus) ) (connector - (text "not_fan_auto_user" (rect 248 280 341 291)(font "Arial" )) - (pt 336 288) - (pt 352 288) + (text "fan_value[1..0]" (rect 298 488 371 499)(font "Arial" )) + (pt 368 504) + (pt 288 504) + (bus) ) (connector - (text "fan_speed[1]" (rect 272 288 335 299)(font "Arial" )) - (pt 336 296) - (pt 352 296) + (text "fan_off[1..0]" (rect 295 456 354 467)(font "Arial" )) + (pt 368 472) + (pt 288 472) + (bus) ) (connector - (text "enable" (rect 296 336 329 347)(font "Arial" )) - (pt 336 344) - (pt 352 344) + (text "enable" (rect 408 532 419 565)(font "Arial" )(vertical)) + (pt 424 528) + (pt 424 576) ) (connector - (text "not_fan_auto_user" (rect 248 344 341 355)(font "Arial" )) - (pt 336 352) - (pt 352 352) + (text "speed[1..0]" (rect 496 472 551 483)(font "Arial" )) + (pt 480 488) + (pt 496 488) + (bus) ) (connector - (text "fan_speed[0]" (rect 272 352 335 363)(font "Arial" )) - (pt 336 360) - (pt 352 360) + (text "fan_value[1..0]" (rect 495 288 568 299)(font "Arial" )) + (pt 480 304) + (pt 496 304) + (bus) ) (connector - (text "fan_auto_user" (rect 272 224 343 235)(font "Arial" )) - (pt 344 232) - (pt 360 232) + (text "fan_off[0]" (rect 424 176 470 187)(font "Arial" )) + (pt 408 192) + (pt 424 192) ) (connector - (text "speed[1]" (rect 440 104 482 115)(font "Arial" )) - (pt 416 112) - (pt 432 112) + (text "fan_off[1]" (rect 419 160 465 171)(font "Arial" )) + (pt 408 176) + (pt 424 176) ) (connector - (text "speed1_1" (rect 440 168 488 179)(font "Arial" )) - (pt 416 176) - (pt 432 176) + (text "fan_hot[1..0]" (rect 296 304 357 315)(font "Arial" )) + (pt 288 320) + (pt 368 320) + (bus) ) (connector - (text "speed1_2" (rect 440 280 488 291)(font "Arial" )) - (pt 416 288) - (pt 432 288) + (pt 408 176) + (pt 408 192) ) (connector - (text "speed1_1" (rect 288 96 336 107)(font "Arial" )) - (pt 352 104) - (pt 336 104) + (pt 408 192) + (pt 408 208) ) (connector - (text "speed1_2" (rect 288 112 336 123)(font "Arial" )) - (pt 352 120) - (pt 336 120) + (text "fan_auto_user" (rect 408 339 419 410)(font "Arial" )(vertical)) + (pt 424 344) + (pt 424 416) ) +(junction (pt 368 112)) +(junction (pt 408 192)) -- cgit v1.2.3