zivillian / ism7mqtt

GNU General Public License v3.0
49 stars 8 forks source link

System.IO.InvalidDataException: invalid login state #99

Closed ansysic closed 3 months ago

ansysic commented 3 months ago

CHA-10 with ISM7. Cannot get it to work. Anything I'm missing?

image image

PS C:\Users\ansys\Downloads\ism7mqtt-win-x64> .\ism7mqtt.exe -i 192.168.1.27 -p YourMom -p .\parameter.json -m 192.168.1.42
System.IO.InvalidDataException: invalid login state
   at ism7mqtt.Ism7Client.OnAuthenticateAsync(IResponse response, CancellationToken cancellationToken) in /home/runner/work/ism7mqtt/ism7mqtt/src/ism7mqtt/ISM7/Ism7Client.cs:line 338
   at ism7mqtt.ResponseDispatcher.DispatchAsync(IResponse response, CancellationToken cancellationToken) in /home/runner/work/ism7mqtt/ism7mqtt/src/ism7mqtt/ISM7/ResponseDispatcher.cs:line 32
   at ism7mqtt.Ism7Client.ReadPipeAsync(PipeReader source, CancellationToken cancellationToken) in /home/runner/work/ism7mqtt/ism7mqtt/src/ism7mqtt/ISM7/Ism7Client.cs:line 212
System.IO.IOException: Unable to read data from the transport connection: The I/O operation has been aborted because of either a thread exit or an application request..
 ---> System.Net.Sockets.SocketException (995): The I/O operation has been aborted because of either a thread exit or an application request.
   --- End of inner exception stack trace ---
   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError , CancellationToken )
   at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource<System.Int32>.GetResult(Int16 )
   at System.Net.Security.SslStream.EnsureFullTlsFrameAsync[TIOAdapter](TIOAdapter )
   at System.Net.Security.SslStream.ReadAsyncInternal[TIOAdapter](TIOAdapter , Memory`1 )
   at ism7mqtt.Ism7Client.FillPipeAsync(PipeWriter target, CancellationToken cancellationToken) in /home/runner/work/ism7mqtt/ism7mqtt/src/ism7mqtt/ISM7/Ism7Client.cs:line 166
zivillian commented 3 months ago

it looks like you use the wrong commandline parameter. The switch for the parameter.json is -t. Can you try again with:

.\ism7mqtt.exe -i 192.168.1.27 -p YourMom -t .\parameter.json -m 192.168.1.42

Since you've put the parameter.json next to the binary, you also omit the parameter:

.\ism7mqtt.exe -i 192.168.1.27 -p YourMom -m 192.168.1.42

To get more output you can also enable the debug mode with -d.

ansysic commented 3 months ago

I'm so sorry, yes, it's working now. Didn't have enough coffee yet this morning.