Class: Gamma

Inherits:
Base show all
Defined in:
lib/functions/gamma.rb

Instance Attribute Summary collapse

Attributes inherited from Base

#frame_optimized, #name

Instance Method Summary collapse

Methods inherited from Base

#add_arduino_code, #add_cycle_level_scope, #add_top_level_scope, #append_tsortable, #buildit, #cycle_level_arduino_code, #depends_on, #resolve_frame_optimized, #top_level_scope_arduino_code

Constructor Details

#initialize(params) ⇒ Gamma

Returns a new instance of Gamma.



17
18
19
20
# File 'lib/functions/gamma.rb', line 17

def initialize(params)
  super(params)
  @frame_optimized = false
end

Instance Attribute Details

#inputObject

Returns the value of attribute input.



15
16
17
# File 'lib/functions/gamma.rb', line 15

def input
  @input
end

Instance Method Details

#arduino_codeObject



26
27
28
29
30
# File 'lib/functions/gamma.rb', line 26

def arduino_code
  [
    "gamma(#{@input.name}, #{@name});"
  ]
end

#param_keysObject



22
23
24
# File 'lib/functions/gamma.rb', line 22

def param_keys
  [:input]
end

#top_level_scope_codeObject



32
33
34
35
36
# File 'lib/functions/gamma.rb', line 32

def top_level_scope_code
  [
    "long #{@name}[3];"
  ]
end