The multiplex selector logical expression is: According to the logical expression of the truth table listed below 1, create a new folder, open the Quartus2 software, select the FLE-> NEW menu, in the pop-up NEW dialog box, select the DEVICE DESGIN FILE page schematic file editor input VHDL FILE, press the OK key to open the VHDL editor window; 2. Enter the VHDL description of the 2-way 1 multiplexer in the VHDL editor window. ENTITYmux21aIS PORT(ab:IN BIT: s:INBIT: y :OUT BIT):END ENITY mux2 1a: ARCHITECTURE one OF mux21a IS BEG IN y "=aWHEN s='0" ELSE b:ENDARCHITECTURE one; or: ENTITYmux21a IS PORT(ab:IN BIT: s:INBIT: y:OUT BIT);END ENTITYmux2 1a; ARCHITECTURE one OF mux2 1a IS BEG IN y "=a WHEN s="O"ELSE b;ENDARCHITECTURE one; 3, open the waveform editor, respectively, run 2 select 1 multiplexer, observe their output waveform: 4. Call up the schematic of the 2-to-1 multiplexer generated by the VHDL description. Click TOOLS-"NELIST VIEWERS-"RTLVIEWERS", which calls out the RIL circuit diagram of the 2-to-1 multiplexer produced by VHDL description, as shown below After this experiment, we have a preliminary understanding of the use of the Quartus2 software, as well as the VHDL expression and the method of designing the circuit. design source `timescale 1ns / 1ps /////////////////////////////////////////////////// ///////////////////////////////// // Company: // Engineer: // // Create Date: 2018/03/17 08:26:28 // Design Name: // Module Name: disTwo2OneSelector // Project Name: // Target Devices: // Tool Versions: // Description: // // Dependencies: // // Revision: // Revision 0.01 - File Created // Additional Comments: // /////////////////////////////////////////////////// ///////////////////////////////// Module disTwo2OneSelector( Input sl, Input a, Input b, Output out ); Reg out; Always @(sl or a or b) Begin // "? :" The return value of the expression must be assigned to a variable. Out=sl? b:a; End Endmodule Analog source `timescale 1ns / 1ps /////////////////////////////////////////////////// ///////////////////////////////// // Company: // Engineer: // // Create Date: 2018/03/17 08:45:19 // Design Name: // Module Name: simTwo2OneSelector // Project Name: // Target Devices: // Tool Versions: // Description: // // Dependencies: // // Revision: // Revision 0.01 - File Created // Additional Comments: // /////////////////////////////////////////////////// ///////////////////////////////// Module simTwo2OneSelector( ); Reg simA,simB,simSl; Wire simOut; Initial Begin simSl=0; simA=0; simB=0; // At the moment when the program is running, "simSl=0;simA=0;simB=0;" has been executed. // In 0-10 time units, the state of the incentive program remains unchanged. #10 simSl=0; simA=1; simB=0; #10 simSl=1; simA=0; simB=0; #10 simSl=1; simA=0; simB=1; End // design file module name object name (parameters in classes in the design file module (parameters in classes in the stimulus file module)) disTwo2OneSelector objTwo2OneSelector(.a(simA),.b(simB),.sl(simSl),.out(simOut)); Endmodule Floating Ball Level Controller The floating ball liquid level controller is composed of floating ball, plug rod, etc. It is installed on the top of the container through the connecting flange, and the floating ball floats on the liquid level according to the principle of equal volume of liquid. When the liquid level of the container changes, the floating ball also moves up and down. Due to the magnetic effect, the dry spring of the floating ball liquid level controller is magnetically attracted to change the liquid level position into an electrical signal, and the actual position of the liquid is digitally displayed through the display instrument, Floating ball liquid level controller to achieve remote detection and control of liquid level. Floating Ball Level Controller,Liquid Level Controller,Alarm Level Measurement Controller,Floating Ball Liquid Level Measuring Controller Taizhou Jiabo Instrument Technology Co., Ltd. , https://www.taizhoujiabo.com
The floating ball liquid level controller is designed according to Archimedes' buoyancy principle. When the liquid level of the container changes, the floating ball also moves up and down. Due to the magnetic effect, the dry reed of the floating ball liquid level controller is magnetically attracted, so that the resistance in the sensor changes linearly, and then the converter converts the change of the resistance value into 4mA ~ 20mA standard DC signal output, Realize the remote detection and control of liquid level.
Select one more multiplexer truth table