Output of exors are showing x in EDA playground

Status
Not open for further replies.

sushl

Junior Member level 2
Joined
Aug 22, 2018
Messages
24
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
238
Hi all ,
I've tried a simple EXOR verilog code along with test bench on the EDA playground, test bench is forced with inputs 00,01,10,11 respectively ;

can anybody tell me why were not getting correct outputs? all are showing x,x,x,x in the LOG.


Here's the link to page
https://www.edaplayground.com/x/3QTX

thanks and regards
Sushl
 


Code Verilog - [expand]
1
2
3
4
5
6
7
8
module my_XOR(output Out, input A, input B);
  wire x,y,inA,inB,not_inA,not_inB;
  and(x,inA,not_inB);
  and(y,not_inA,inB);
  not(not_inA,inA);
  not(not_inB,inB);
  or(Out,x,y);
endmodule


Do you see inA and inB being driven anywhere? I don't.
 
Reactions: sushl

    sushl

    Points: 2
    Helpful Answer Positive Rating

Thanks FVM. I have mistakenly considered the input's inA and inB as wire's ; i have rectified them it works now.
 
Last edited:

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…