Overview
Configures the real-time diagnostic stream of the RFID reader, using srfidSetRealTimeReaderLog.
Details
Configure the live diagnostic stream from the reader: how much detail the reader sends in real time while it operates. Choose one of four log types with the logType parameter:
SRFID_REALTIMELOGSTYPE_NONE: no real-time log. Use it to stop the stream.SRFID_REALTIMELOGSTYPE_ERROR: error messages.SRFID_REALTIMELOGSTYPE_WARNING: warning messages.SRFID_REALTIMELOGSTYPE_VERBOSE: the most detailed log.
The stream stays on until you set it back to SRFID_REALTIMELOGSTYPE_NONE.
The log lines arrive as debug events, in the same way as for Get Reader Log: subscribe to SRFID_EVENT_MASK_DEBUG_INFO and read getMessage and getLevel from the srfidNotificationDebugEvent in srfidEventStatusNotify:aEvent:aNotification: (see Get Reader Log).
- (SRFID_RESULT)setRealTimeReaderLog:(SRFID_REALTIMELOGSTYPE)logType withStatusMessage:(NSString**)statusMessage
{
// Subscribe to the reader's log lines
[apiInstance srfidSubsribeForEvents:SRFID_EVENT_MASK_DEBUG_INFO];
SRFID_RESULT srfid_result = [apiInstance srfidSetRealTimeReaderLog:readerID
logType:logType
aStatusMessage:statusMessage];
if (srfid_result == SRFID_RESULT_FAILURE || srfid_result == SRFID_RESULT_RESPONSE_TIMEOUT)
{
NSLog(@"Failure");
}
return srfid_result;
}