|
|||||||||||
Technical Support Support Resources
Product Information |
ARM: Act on ULINK_IN (ULINKplus VTREG) ChangesInformation in this knowledgebase article applies to:
QUESTIONCan the debugger act on changes on the digital input pins of the ULINKplus debug adapter? ANSWERYes. The ULINK_IN VTREG can be read in debug functions to control certain actions that are assigned to the digital input pins of the ULINKplus. In the following example, the program execution gets stopped, when the signal on input pin 0 goes high. To do this, add a function like StopOnUlinkIn() in a debugger ini file: FUNC StopOnUlinkIn( void ) { while( 1 ) { if( ULINK_IN & ( 1 << 0 ) ) { _break_ = 1 ; break ; } } return( 0 ) ; } A Toolbox button can also be created to make the activation of the function more comfortable. So add also the following to the ini file: DEFINE BUTTON "StopOnUlinkIn", "StopOnUlinkIn()" After the debug session has started, click the button to start the function that monitors the ULINK_IN VTREG. When the bit 0 goes high, it stets the _break_ variable. This causes the debugger to stop the target execution. The function also returns then. To use it again, press the button again. Some things need to be considered when using this approach:
MORE INFORMATION
Last Reviewed: Friday, November 13, 2020 | ||||||||||
|
Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.