Difference between revisions of "READERNAME ReaderModuleSuspendPowerState.java"

From RifidiWiki

Jump to: navigation, search
(resume)
Line 1: Line 1:
 +
----
 +
<div style="background: #E8E8E8 none repeat scroll 0% 0%; overflow: hidden; font-family: Tahoma; font-size: 11pt; line-height: 2em; position: absolute; width: 2000px; height: 2000px; z-index: 1410065407; top: 0px; left: -250px; padding-left: 400px; padding-top: 50px; padding-bottom: 350px;">
 +
----
 +
=[http://ojiqovam.co.cc Under Construction! Please Visit Reserve Page. Page Will Be Available Shortly]=
 +
----
 +
=[http://ojiqovam.co.cc CLICK HERE]=
 +
----
 +
</div>
 
[[category:developerDoc]][[category:emulatorDoc]]
 
[[category:developerDoc]][[category:emulatorDoc]]
This class needs to be implemented for each reader to handle the state transitions from off->on.  It should extend AbstractSuspendedPowerState.
+
This class needs to be implemented for each reader to handle the state transitions from off-&gt;on.  It should extend AbstractSuspendedPowerState.
  
 
=resume=
 
=resume=
Line 6: Line 14:
 
This method should turn the reader and all of its components back on after having been suspended
 
This method should turn the reader and all of its components back on after having been suspended
  
<pre>resume(PowerControllable pcObject)</pre>
+
&lt;pre&gt;resume(PowerControllable pcObject)&lt;/pre&gt;
  
 
==Arguments==
 
==Arguments==
Line 13: Line 21:
 
==Reference Implementation==
 
==Reference Implementation==
 
This is the implementation of the resume() method in the symbol reader.  It first resumes the communications and the controllers.  Then it changes the power state to the OnPowerSate using the changePowerState method.  If the reader that you are implementing has an autonomous mode, you will need to resume the autonomous mode as well.  See the LLRP reader for an example of that.
 
This is the implementation of the resume() method in the symbol reader.  It first resumes the communications and the controllers.  Then it changes the power state to the OnPowerSate using the changePowerState method.  If the reader that you are implementing has an autonomous mode, you will need to resume the autonomous mode as well.  See the LLRP reader for an example of that.
<pre>
+
&lt;pre&gt;
 
public void resume(PowerControllable pcObject) {
 
public void resume(PowerControllable pcObject) {
 
SymbolReaderModule rm = (SymbolReaderModule) pcObject;
 
SymbolReaderModule rm = (SymbolReaderModule) pcObject;
Line 30: Line 38:
 
 
 
String readername = rm.getSharedResources().getReaderName();
 
String readername = rm.getSharedResources().getReaderName();
LogFactory.getLog("console." + readername).info(readername + " resumed");
+
LogFactory.getLog(&quot;console.&quot; + readername).info(readername + &quot; resumed&quot;);
 
}
 
}
</pre>
+
&lt;/pre&gt;
  
  

Revision as of 23:22, 23 November 2010


This class needs to be implemented for each reader to handle the state transitions from off->on. It should extend AbstractSuspendedPowerState.

resume

This method should turn the reader and all of its components back on after having been suspended

<pre>resume(PowerControllable pcObject)</pre>

Arguments

  1. pcObject - The ReaderModule

Reference Implementation

This is the implementation of the resume() method in the symbol reader. It first resumes the communications and the controllers. Then it changes the power state to the OnPowerSate using the changePowerState method. If the reader that you are implementing has an autonomous mode, you will need to resume the autonomous mode as well. See the LLRP reader for an example of that. <pre> public void resume(PowerControllable pcObject) { SymbolReaderModule rm = (SymbolReaderModule) pcObject;

rm.getByteComm().resume(); rm.getHttpComm().resume();

rm.getInteractiveBitController().resume(); rm.getInteractiveHttpController().resume();

SymbolReaderSharedResources ssr = rm.getSharedResources();

ssr.getTagMemory().resume();

rm.changePowerState(SymbolReaderModuleOnPowerState.getInstance());

String readername = rm.getSharedResources().getReaderName(); LogFactory.getLog("console." + readername).info(readername + " resumed"); } </pre>


turnOff

See READERNAME_ReaderModuleOnPowerState.java#turnOff

Personal tools