Menu

quantity invalid

yasin
2021-09-04
2021-09-04
  • yasin

    yasin - 2021-09-04

    When I run this code, it crashes after a while, why?
    quantity invalid

        public async void Start()
        {
            await Task.Delay(10).ContinueWith(_ =>
            {
    
    
                for (int ferdi = 0; ferdi < 32; ferdi++)
                {
                    modbusClient.WriteSingleCoil(ferdi, true);
                    Thread.Sleep(5);
                    modbusClient.WriteSingleCoil(ferdi, false);
                }
                for (int j = 31; j > 0; j--)
                {
                    modbusClient.WriteSingleCoil(j, true);
                    Thread.Sleep(5);
                    modbusClient.WriteSingleCoil(j, false);
                }
                Start();
            });
    
     
  • yasin

    yasin - 2021-09-04

    EasyModbus.Exceptions.QuantityInvalidException: 'quantity invalid

     
  • Anonymous

    Anonymous - 2022-02-17
    Post awaiting moderation.

Anonymous
Anonymous

Add attachments
Cancel