Package uk.co.nimp.scard

Examples of uk.co.nimp.scard.SmartwareTerminalManager


        public void run() {
        {*/
        try {

            //MP65TerminalManager.initContext();
            SmartwareTerminalManager manager = new SmartwareTerminalManager();
            List<GenericTerminal> terminals = manager.list();
            terminals = manager.list();
            terminals = manager.list();
            if (0 == terminals.size()) {
                System.out.println("Smartware terminal not detected.");
                return;
            }
            SmartwareTerminal terminal = (SmartwareTerminal) terminals.get(0);
            terminals = manager.list();
            terminal.addLogHandler(new ScardPrintStreamLogHandler(System.out));
            System.out.println("Please insert a card in terminal " + terminal.getName());
            while (false == terminal.isCardPresent()) {
                try {
                    Thread.sleep(200);
                } catch (InterruptedException ex) {
                    Logger.getLogger(SmartwareTerminal.class.getName()).log(Level.SEVERE, null, ex);
                }
            }
            terminals = manager.list();
            terminals = manager.list();
            System.out.println("Try to connect to " + terminal.getName());
            Apdu apdu;
            terminal.coldConnect();
            GenericContactTerminal contactTerminal=terminal;
            contactTerminal.logFrequency();
View Full Code Here

TOP

Related Classes of uk.co.nimp.scard.SmartwareTerminalManager

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.