User Tools

Site Tools


getting_started:tutorials:hal0

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
getting_started:tutorials:hal0 [2024/12/01 11:59] ursgrafgetting_started:tutorials:hal0 [2024/12/01 12:01] (current) – [Accessing Output Signals Directly] ursgraf
Line 16: Line 16:
  
 ===== Accessing Output Signals Directly ===== ===== Accessing Output Signals Directly =====
-A peripheral output block delivers a signal to external hardware. Its signal value can be accessed with a get method, see line 43 in the comment in the example code in [[https://github.com/eeros-project/eeros-framework/blob/master/examples/hal/HalTest1.cpp|HalTest1.cpp]].+A peripheral output block delivers a signal to external hardware. Its signal value can be accessed with a get method, see line 41 in the comment in the example code in [[https://github.com/eeros-project/eeros-framework/blob/master/examples/hal/HalTest1.cpp|HalTest1.cpp]].
  
 Alternatively the signal in the HAL could be accessed by getting an reference to the corresponding output block with Alternatively the signal in the HAL could be accessed by getting an reference to the corresponding output block with
 <code cpp> <code cpp>
-auto digOut = hal.getLogicOutput("dOut0", false);  // line 42+auto digOut = hal.getLogicOutput("dOut0", false);  // line 37
 </code> </code>
 The signal value can then be logged with The signal value can then be logged with
 block with block with
 <code cpp> <code cpp>
-log.info() << digOut->get(); // line 47+log.info() << digOut->get(); // line 42
 </code> </code>
-You have to make sure to access the output with non-exclusive rights, because the control system already has a handle to it, see line 28 in ''halTest1.hpp''. Likewise, the control system must access the same output in the same fashion.+You have to make sure to access the output with non-exclusive rights, because the control system already has a handle to it, see line 25 in ''halTest1.hpp''. Likewise, the control system must access the same output in the same fashion.
getting_started/tutorials/hal0.txt · Last modified: 2024/12/01 12:01 by ursgraf