How to simulate the outputs of comparator and the output of the NOR gate?

Thread Starter

tienk

Joined Apr 8, 2024
76
Hi tie,
Please explain what you are asking?
What problem do you have with the circuit?
E
i do not have a problem im just confused on how to simulate that red boxed part which is the input of the NOR gate and the output of the logic gate
 

Papabravo

Joined Feb 24, 2006
21,264
Unused inputs are net-listed as "not present". This is different than gates in real life. There are parameters that you need to set for those gates so it would be best to read the HELP page on them. It also helps to make them visible on the schematic so that it is clear what the behavior should be. Connecting a voltage to the input of an OR gate means it will be ON all the time.
 

Papabravo

Joined Feb 24, 2006
21,264
The 'A' devices in LTspice are logic gates and they require an awareness of the settable parameters associated with their proper operation. In your schematic you have chosen a 5-input OR gate with complementary outputs. You have also tied one of the inputs to what looks like 5 volts. This will guarantee the 'true' output will ALWAYS be high and the complementary output will ALSWAYS be low. You must have skipped the HELP page for these devices. That was an ill-advised choice on your part.
 

Thread Starter

tienk

Joined Apr 8, 2024
76
The 'A' devices in LTspice are logic gates and they require an awareness of the settable parameters associated with their proper operation. In your schematic you have chosen a 5-input OR gate with complementary outputs. You have also tied one of the inputs to what looks like 5 volts. This will guarantee the 'true' output will ALWAYS be high and the complementary output will ALSWAYS be low. You must have skipped the HELP page for these devices. That was an ill-advised choice on your part.
yes i have removed the 5 volts and kept the other 2 connections but im confused as to why when simulating the output im not getting a pulse, its just staying constant at 0V which obviously means something is wrong
 

ericgibbs

Joined Jan 29, 2010
19,017
Hi, tie
The digital gates have a default logic Low and High levels of 0v and 1v.
As you know TTL gates have logic levels 0v and 5v

So if you want to use the gate as a TTL gate you must change logic levels by setting those values. Vhigh =5v Vlow=0v

If required you could set the logic levels to say 0v and 12V for say another project when you are trying to simulate CMOS logic gates.

Do you follow, OK.?
E
 

Papabravo

Joined Feb 24, 2006
21,264
The gate operates as follows:
1713983153406.png
U1 takes a square wave input and produces complementary outputs with an approximate dead time of 1 µsec. The OR gate shows you where the deadtime occurs.
 

Alec_t

Joined Sep 17, 2013
14,382
what is wrong?
You have your OR gate configured for 1V logic, but your power supply is 5V. Change the Vhigh setting in your OR gate to Vhigh=5.
Right-click the MOSFET symbols and swap those default MOSFETs for 'proper' ones from the provided library.
 
Last edited:

Thread Starter

tienk

Joined Apr 8, 2024
76
You have your OR gate configured for 1V logic, but your power supply is 5V. Change the Vhigh setting in your OR gate to Vhigh=5.
Right-click the MOSFET symbols and swap those default MOSFETs for 'proper' ones from the provided library.
1713991295257.png
im testing it seperatly but yes the mosfets needs changing but for some reason im getting a constant line at 5V
 

ericgibbs

Joined Jan 29, 2010
19,017
Hi tie,
I must repeat, please post a full/complete asc file, a cropped off clip does not help us.

Where did you get the LM393 model?, and are you sure you have the pins on the LM393 matched correctly to the model file?

E
 

Attachments

Top