ClientTest.java 747 B

1234567891011121314151617181920212223242526272829
  1. import io.netty.buffer.PooledByteBufAllocator;
  2. import io.netty.util.internal.PlatformDependent;
  3. import wei.yigulu.iec104.nettyconfig.Iec104HSMasterBuilder;
  4. import wei.yigulu.iec104.util.SendDataFrameHelper;
  5. /**
  6. * 客户端测试
  7. *
  8. * @author 修唯xiuwei
  9. * @create 2019-01-22 16:05
  10. * @Email 524710549@qq.com
  11. **/
  12. public class ClientTest {
  13. public static void main(String[] args) throws Exception {
  14. Iec104HSMasterBuilder a = new Iec104HSMasterBuilder("127.0.0.1", 2404);
  15. a.createByUnBlock();
  16. Thread.sleep(5000L);
  17. for (;;){
  18. Thread.sleep(3000L);
  19. System.out.println( );
  20. SendDataFrameHelper.sendTotalSummonFrame(a.getFuture().channel(),1,6,a.getLog());
  21. }
  22. }
  23. }