Nightingale Posing Mischievously

    kcp-transceiver

    0.1.0 • Public • Published

    Host-1

    const kcpTransceiver = require('kcp-transceiver');
    const kcpTran = new kcpTransceiver({
    	listenPort: 5080,
    	listenCallback: (buf, address, port) => {
    		console.log(buf, `${address}:${port}`);
    	}
    })
    
    kcpTran.send({
    	buf: payload,
    	address: host_2_address,
    	port: 5081
    })
    
    

    Host-2

    const kcpTransceiver = require('kcp-transceiver');
    const kcpTran = new kcpTransceiver({
    	listenPort: 5081,
    	listenCallback: (buf, address, port) => {
    		console.log(buf, `${address}:${port}`);
    	}
    })
    
    kcpTran.send({
    	buf: payload,
    	address: host_1_address,
    	port: 5080
    })
    
    

    Install

    npm i kcp-transceiver

    DownloadsWeekly Downloads

    0

    Version

    0.1.0

    License

    MIT

    Unpacked Size

    14.1 kB

    Total Files

    3

    Last publish

    Collaborators

    • liufanghua2012