Behavioral PowerPoint PPT Presentation

presentation player overlay
1 / 3
About This Presentation
Transcript and Presenter's Notes

Title: Behavioral


1
Behavioral
  • module MUX4_to_1(y, x, s)
  • input x30, s10
  • output y
  • reg y
  • always _at_(x or s)
  • begin
  • if (s 0)
  • yx0
  • else if
  • end
  • endmodule

2
Continuous Assignment
  • module MUX4_to_1(y, x, s)
  • input x30, s10
  • output y
  • assign y (!s0!s1x0)
    (!s1s0x1)
  • (s0!s1x2) (s1s0x3)
  • endmodule

3
Structure
  • module MUX4_to_1(y, x, s)
  • input x30, s10
  • output y
  • wire s1_, s0_, y0, y1, y2, y3 // optional
  • not(s1_, s1) not(s0_, s0)
  • and(y0, s1_, s0_, x0)
  • and(y1, s1_, s0, x1)
  • or (y, y0, y1, y2, y3)
  • endmodule
Write a Comment
User Comments (0)
About PowerShow.com