Mar 5, 2016 #1 M mohsansaleem Newbie level 3 Joined Mar 2, 2016 Messages 4 Helped 0 Reputation 0 Reaction score 0 Trophy points 1 Activity points 72 hi I want to build even parity check for the data of size [7:0] with data flow operators ? can anyone help me , thanx
hi I want to build even parity check for the data of size [7:0] with data flow operators ? can anyone help me , thanx
Mar 5, 2016 #2 FvM Super Moderator Staff member Joined Jan 22, 2008 Messages 52,392 Helped 14,748 Reputation 29,778 Reaction score 14,091 Trophy points 1,393 Location Bochum, Germany Activity points 297,965 Consider XOR operator...
Mar 5, 2016 #3 M mohsansaleem Newbie level 3 Joined Mar 2, 2016 Messages 4 Helped 0 Reputation 0 Reaction score 0 Trophy points 1 Activity points 72 like , Code: assign parity_bit =(data_in[0]^data_in[1])^(data_in[2]^data_in[3])^(data_in[4]^data_in[5])^(data_in[6]^data_in[7]); or Code: assign parity_bit =(data_in[7]^data_in[6])^(data_in[5]^data_in[4])^(data_in[3]^data_in[2])^(data_in[1]^data_in[0]);
like , Code: assign parity_bit =(data_in[0]^data_in[1])^(data_in[2]^data_in[3])^(data_in[4]^data_in[5])^(data_in[6]^data_in[7]); or Code: assign parity_bit =(data_in[7]^data_in[6])^(data_in[5]^data_in[4])^(data_in[3]^data_in[2])^(data_in[1]^data_in[0]);
Mar 5, 2016 #4 M mohsansaleem Newbie level 3 Joined Mar 2, 2016 Messages 4 Helped 0 Reputation 0 Reaction score 0 Trophy points 1 Activity points 72 so will use this statment without brackets Code: assign parity_bit =(data_in[7]^data_in[6])^(data_in[5]^data_in[4])^(data_in[3]^data_in[2])^(data_in[1]^data_in[0]); to get even parity ??
so will use this statment without brackets Code: assign parity_bit =(data_in[7]^data_in[6])^(data_in[5]^data_in[4])^(data_in[3]^data_in[2])^(data_in[1]^data_in[0]); to get even parity ??
Mar 5, 2016 #5 FvM Super Moderator Staff member Joined Jan 22, 2008 Messages 52,392 Helped 14,748 Reputation 29,778 Reaction score 14,091 Trophy points 1,393 Location Bochum, Germany Activity points 297,965 Yes. Brackets aren't needed. - - - Updated - - - Sure, even parity. Check yourself with pencil and paper method.
Yes. Brackets aren't needed. - - - Updated - - - Sure, even parity. Check yourself with pencil and paper method.
Mar 5, 2016 #6 ads-ee Super Moderator Staff member Joined Sep 10, 2013 Messages 7,944 Helped 1,822 Reputation 3,654 Reaction score 1,808 Trophy points 1,393 Location USA Activity points 60,207 Instead of all that typing, use the reduction XOR operator e.g. assign even_parity = ^data_in