Class: FixedPoint::Fixdt

Inherits:
Format
  • Object
show all
Defined in:
lib/fixed_point/fixdt.rb

Instance Attribute Summary

Attributes inherited from Format

#frac_bits, #int_bits, #max_frac, #max_int_signed, #max_int_unsigned, #max_signed, #max_unsigned, #max_value, #min_value, #resolution, #signed, #width

Instance Method Summary collapse

Methods inherited from Format

#calculate_attributes, #signed?

Constructor Details

#initialize(signed, width, frac_bits) ⇒ Fixdt

Designed to be compatible with Matlab/Simulink types



4
5
6
# File 'lib/fixed_point/fixdt.rb', line 4

def initialize(signed, width, frac_bits)
  super( signed, width-frac_bits, frac_bits )
end