Designing a simple 4bit ALU + question on multiplexers

Discussion in 'General Electronics Chat' started by fadax, Apr 20, 2010.

  1. fadax

    Thread Starter New Member

    Apr 19, 2010

    I was given the task of designing a simple 4 bit ALU which just has the two functions 'A plus B' and 'A minus B'. The design was only supposed to use full adders, multiplexers and inverters.

    The circuit I came up with can be seen here:
    I think it will work (?) but I was unsure if there is a better way of doing it without using 4 multiplexers (one for each of the input bits).

    Also I was wondering if the order of inputs to a multiplexer matters? is there a correct way of ordering the inputs? In my circuit, I have input the inverted bit as the first input to each multiplexer and the original bit as the second input. I also said that when S = 1, this specified the subtraction function (so the inverted bit should be selected).. is it correct to say that when the control bit is 1 the top input to the 2 bit multiplexer will be selected?

    thanks for any advice :)
  2. fadax

    Thread Starter New Member

    Apr 19, 2010
    does anyone know?
  3. retched

    AAC Fanatic!

    Dec 5, 2009
    Have you tried simulation software?

    I see you sketched this via pen and paper. (So Im guessing you haven't used a simulator)

    But you can get a free one here: (Its called LTSpice IV)

    and build you circuit as you have it on paper and run the simulation to see what our inputs turn into on output..

    We actually, I cant tell what MUX you are using OR what pins to what IC you have intended.

    So actually, yes it would work...depending on how it ACTUALLY was wired. The theory is there.
  4. count_volta

    Active Member

    Feb 4, 2009
    Use Altera Quartus simulator to test it.

    And cool, we made a 4 bit ALU recently, but using an ALU chip. Awesome project.