Changes between Version 15 and Version 16 of Tutorial
- Timestamp:
- Aug 23, 2013, 3:27:59 PM (11 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Tutorial
v15 v16 63 63 ├── device.py 64 64 ├── fb 65 │ 66 │ 65 │ ├── __init__.py 66 │ └── timerFB.py 67 67 ├── __init__.py 68 68 └── plugins … … 157 157 DESC = "Timer FB" 158 158 159 def _init(self):159 def init(self): 160 160 self._timer = 0 161 161 … … 284 284 DESC = "Timer FB" 285 285 286 def _init(self):286 def init(self): 287 287 self._timer = 0 288 288 }}} … … 296 296 There are a few parameters in the dicts; some are obvious, some will need more explanations. But this is out of the scope of this tutorial. 297 297 298 The '''{{{ _init()}}}''' method is called at the end of the Functional Block instanciation (creation); it can be used to init some additionnal global vars, or make initial tasks. Here, we just create the '''{{{_timer}}}''' var, and set it to 0.298 The '''{{{init()}}}''' method is called at the end of the Functional Block instanciation (creation); it can be used to init some additionnal global vars, or make initial tasks. Here, we just create the '''{{{_timer}}}''' var, and set it to 0. 299 299 300 300 Ok, it's time to dig in the active part of our functional block: