LrJposChannel.connect

Connects the client to the server. This function is used when the channel is the client that sends messages to the server.

public static void connect() throws IOException

Return values

This function does not return any values.

Example

Copy code
public int init() throws Throwable {
        
        AsciiPackager2003 pack = new AsciiPackager2003();
        LrJposChannel.initChannel(LrJposChannel.ChannelType.ASCIIChannel);
        LrJposChannel.setHost("localhost", 8000);
        LrJposChannel.setPackager(pack);
        LrJposChannel.connect();
        
        
        return 0;
 }