Don't understand Logic gates

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Don't understand Logic gates

donz12
I'm really unsure of the way in which the logic gates work... Why does the And gate have parts that are a=a and b=b and out=out whereas the not gate has in=a and out=b ?

Could someone please explain this to me I'm very new to this and I require to understand and complete all the hdl files necessary, for my coursework.

Regards
Reply | Threaded
Open this post in threaded view
|

Re: Don't understand Logic gates

cadet1620
Administrator
Read the Hardware Construction Survival Kit. Particularly the HDL syntax and the meaning of "a=a" section.

Basically, the name on the left side of the "=" is the name of an I/O pin in the part being used.  This name is fixed -- it is in the IN or OUT line of the used part's HDL.

The name on the right side of the "=" is the name of an I/O pin in the part you are writing or the name of a connecting wire you are using to build your part.

The And gate implements the function out=a&b so all And parts used have the form "And (a=?, b=?, out=?)".
The In gate implements the function out=~in so all Not parts are "Not (in=?, out=?)".

This post has a list of all the built in parts and their I/O pin names.

--Mark