daily pastebin goal
28%
SHARE
TWEET

Code for floating values

Ishan_Bansal Jun 7th, 2017 26 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. a = Signal(12)
  2. # value of sqrt_2 = 1.414
  3. #migen doesn't support floating values.
  4. a = Signal(181) #181 = 1.414*128
  5.  
  6. b = Signal(12)
  7. b.eq(3)
  8.  
  9. c = Signal(12)
  10. c.eq(b*a)
  11. c.eq(c >> 7)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top