public List<AcrDefaultLEDAndBuzzerBehaviour> getDefaultLEDAndBuzzerBehaviour() { byte[] response; try { response = readerControl.getDefaultLEDAndBuzzerBehaviour(); } catch (RemoteException e) { throw new AcrReaderException(e); } return parseBehaviour(readInteger(response)); }
public boolean setDefaultLEDAndBuzzerBehaviour(AcrDefaultLEDAndBuzzerBehaviour ... types) { byte[] response; try { int operation = serializeBehaviour(types); response = readerControl.setDefaultLEDAndBuzzerBehaviour(operation); } catch (RemoteException e) { throw new AcrReaderException(e); } return readBoolean(response); }
@Override public byte[] transmit(int slotNum, byte[] command) { byte[] response; try { response = readerControl.transmit(slotNum, command); } catch (RemoteException e) { throw new AcrReaderException(e); } return readByteArray(response); }
} else if (reader instanceof Acr1252UReader) { Acr1252UReader acr1252UReader = (Acr1252UReader) reader; acr1252UReader.setPICC( AcrPICC.POLL_ISO14443_TYPE_B, AcrPICC.POLL_ISO14443_TYPE_A ); acr1252UReader.setAutomaticPICCPolling(AcrAutomaticPICCPolling.AUTO_PICC_POLLING, AcrAutomaticPICCPolling.ACTIVATE_PICC_WHEN_DETECTED, AcrAutomaticPICCPolling.ENFORCE_ISO14443A_PART_4); } else if (reader instanceof Acr1255UReader) { Acr1255UReader acr1255UReader = (Acr1255UReader) reader;
public boolean setBuzzer(boolean value) { byte[] response; try { response = readerControl.setBuzzer(value); } catch (RemoteException e) { throw new AcrReaderException(e); } return readBoolean(response); }
public List<AcrPICC> getPICC() { byte[] response; try { response = readerControl.getPICC(); } catch (RemoteException e) { throw new AcrReaderException(e); } int operation = readInteger(response); ArrayList<AcrPICC> values = new ArrayList<AcrPICC>(); if((operation & POLL_TOPAZ) != 0) { values.add(AcrPICC.POLL_TOPAZ); } if((operation & POLL_FELICA_424K) != 0) { values.add(AcrPICC.POLL_FELICA_424K); } if((operation & POLL_FELICA_212K) != 0) { values.add(AcrPICC.POLL_FELICA_212K); } if((operation & POLL_ISO14443_TYPE_B) != 0) { values.add(AcrPICC.POLL_ISO14443_TYPE_B); } if((operation & POLL_ISO14443_TYPE_A) != 0) { values.add(AcrPICC.POLL_ISO14443_TYPE_A); } return values; }
public String getFirmware() throws AcrReaderException { byte[] response; try { response = readerControl.getFirmware(); } catch (RemoteException e) { throw new AcrReaderException(e); } return readString(response); }
public boolean setLEDs(AcrLED ... types) { byte[] response; try { int operation = 0; for(AcrLED type : types) { if(type == AcrLED.GREEN) { operation |= LED_GREEN; } else if(type == AcrLED.RED) { operation |= LED_RED; } else { throw new IllegalArgumentException("LED " + type + " not supported"); } } response = readerControl.setLEDs(operation); } catch (RemoteException e) { throw new AcrReaderException(e); } return readBoolean(response); }
public List<AcrAutomaticPICCPolling> getAutomaticPICCPolling() { byte[] response; try { response = readerControl.getAutomaticPICCPolling(); } catch (RemoteException e) { throw new AcrReaderException(e); } return AcrAutomaticPICCPolling.parse(readInteger(response)); }
public boolean setAutomaticPICCPolling(AcrAutomaticPICCPolling ... types) { byte[] response; try { response = readerControl.setAutomaticPICCPolling(AcrAutomaticPICCPolling.serialize(types)); } catch (RemoteException e) { throw new AcrReaderException(e); } return readBoolean(response); }
@Override public byte[] control(int slotNum, int controlCode, byte[] command) { byte[] response; try { response = readerControl.control(slotNum, controlCode, command); } catch (RemoteException e) { throw new AcrReaderException(e); } return readByteArray(response); }
return readBoolean(response);