Perform the following procedure to start and stop system event capture from external trigger detection:
- Claim the ownership by setting the OWNERSHIP bit in the SMSET configuration register (SMSET_CFG) to 1.
- Check the ownership and the current owner by reading the OWNERSHIP bit in the SMSET configuration register (SMSET_CFG).
- Set the appropriate sampling window size value in the system event sampling window register (SMSET_SESW).
- Enable the events to be detected by setting the appropriate bits in the programming of the system event detection enable registers (SMSET_SEDEN_i) to 1.
- Select the polarity of the event detection by writing the appropriate value to the EventPolarity bit in the SMSET configuration register (SMSET_CFG).
- Select the message event generation by writing the appropriate value to the MessageEventGeneration bit in the SMSET configuration register (SMSET_CFG).
- Enable capturing system events from external trigger detection by setting the StopCapturingSystemEvents bit in the SMSET configuration register to 1.
- Enable capturing system events from external trigger detection by setting the StartCapturingSystemEvents bit in the SMSET configuration register to 1.
- Enable system event capture by writing a 1 to the SystemEventCapture bit in the SMSET configuration register.