![]()  | 
     BALTECH Docs | 
    C API for BALTECH SDK
   
    
   
   | 
   
| brp_errcode brp_AR_SetMode | ( | brp_protocol | protocol, | 
| brp_AutoReadMode | Mode | ||
| ) | 
This command controls Autoread mode at runtime.
Usually, the Autoread subsystem will be stared at boot time if the reader is __ configured to work autonomously__. However, you can still enable and disable Autoread at runtime. This is e.g. needed if you use VHL & Autoread in combination, so you can interrupt Autoread to run VHL commands.
**_AR.SetMode_ automatically empties the reader's message buffer. This ensures that the next brp_AR_GetMessage() you run doesn't return "old" data from a card detected before running AR.SetMode .**
| [in] | protocol | used to execute the command | 
| [in] | Mode | Defines if Autoread is active, so the reader scans autonomously for cards. The reader will disable Autoread mode automatically if you execute a card- accessing command (e.g brp_VHL_Select() ). |