Demux help

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

Demux help

alejo
Hello,

I just started yesterday with the course and I'm trying to finish the whole exercises by myself.
I already have (what I actually think and hope are) pretty efficient implementations for all the chips on project 01, but I'm struggling with DMux8Way (by efficient I mean with a minimal set of instructions on the PARTS section).

Actually, I did struggle a lot with DMux in general. I had to research in other places about dmux cause I couldn't follow the canonical expression from the truth table.

Then based on that 'native' DMux implementation, I notice I could use that to build a DMux4Way, but I didn't follow that approach since it looked pretty cumbersome. I struggled for a while and end up implementing DMux4Way using 3 DMux calls. Now, to be honest, it did came in after some trial an error, and not in a more methodical way which I would think is more convenient for learning.

I would assume that DMux8Way can be constructed using several DMux4Way. I have been trying to draw the diagram, but haven't been able to figure it out.

Can someone give me some pointers? Any links in which I can get a better explanation of DMux? How can I build a canonical expression for the DMux based on its truth table? Any other exercise I can do in order to grasp the concept better?

Any feedback will be greatly appreciated!
Reply | Threaded
Open this post in threaded view
|

Re: Demux help

cadet1620
Administrator
You are correct that the canonical representation grows rapidly complex. In fact it grows exponentially on the order of 2n when n is the number of inputs.

Using three DMux to make the DMux4Way is a good approach. You can use seven Dmux to make a DMux8Way, but if you use a combination of DMux and DMux4Way you can get it down to three lines of HDL.

One of the important concepts in Computer Science is the binary tree. As a data structure it lets you search for things efficiently; in an algorithm it lets you break larger tasks in half and repeatedly, often recursively, work with the data in smaller chunks. Here's a visual representation of a binary tree.

Binary tree

If you want more explicit help, ask me using "More|Reply to Author" and I'll be happy to help you off forum.

--Mark

Reply | Threaded
Open this post in threaded view
|

Re: Demux help

alejo
Thank you very much for your answer. I saw it earlier but couldn't work on this until now.

After giving it a little more of thought I finally implement the DMux8Way using only 3 HDL lines :)
It did follow somehow the implementation of DMux4Way in the end. Also I was able to figure out the canonical representation, and saw the growth it shows as n increases.

I'll keep going with the other chapters!

Thanks again.
Reply | Threaded
Open this post in threaded view
|

Re: Demux help

AntonioCS
If you could give me some pointers on how to make the dmux I would appreciate it :)

I have made the mux chip using the canonical expression (there are many and's and or's I think I can replace some with nand calls)  but as you too have come to that conclusion, for the dmux the canonical expression is no good (at least this is what it seems)

Any place in particular you looked? I have tried the wiki but didn't find anything there I could use (or maybe I missed something).
Reply | Threaded
Open this post in threaded view
|

Re: Demux help

cadet1620
Administrator
AntonioCS wrote
I have made the mux chip using the canonical expression (there are many and's and or's I think I can replace some with nand calls) but as you too have come to that conclusion, for the dmux the canonical expression is no good (at least this is what it seems)
Treat the two outputs of the DMux separately. You get two canonical expressions, both of which are fairly simple.

insel|ainsel|b
00|0 00|0
01|0 01|0
10|1 10|0
11|0 11|1
--Mark
Reply | Threaded
Open this post in threaded view
|

Re: Demux help

AntonioCS
I will try this :) Thanks!!
Reply | Threaded
Open this post in threaded view
|

Re: Demux help

AntonioCS
In reply to this post by cadet1620
Sorry for the late reply!

I tried your approach and it worked great. I know only have a few more chips to make (4 to be exact).

I am struggling a bit with difficulty of the task, time and sometimes motivation, but I am getting there.
Reply | Threaded
Open this post in threaded view
|

Re: Demux help

AntonioCS
In reply to this post by cadet1620
Hey!

I found the solution to this problem (I was searching for Dmux4way and a page with the hdl appeared).

I now understand what you meant by binary tree, but before actually seeing the code, what you said just didn't make any sense to me.

I know you are not suppose to just give us the answers but you must remember that most of us (at least I don't) don't have any other type of helper/teacher/guide to give us any hint.

Just to say that your comment on this was not very helpful I am not trying to say anything bad about you, but I really did spend a lot of time trying to figure out the Dmux4Way without any type of success. Maybe if there were some more tips or something....
Reply | Threaded
Open this post in threaded view
|

Re: Demux help

kris.arj90
In reply to this post by cadet1620

Treat the two outputs of the DMux separately.  You get two canonical expressions, both of which are fairly simple.

That helped so much Thank you