I need to create a transmitter that generates 100000 binary bits encoded as +/-3 volts using rand() but it doesn't seem to recognize the if just goes to the else. I know its something dumb any help would be appreciated I have:
x = rand(1,100000)bit=(x>.5)if bit==0 bit = bit-3else x == 1 bit = bit+3end
Best Answer