InvalidReport event is thrown as StreamingInterrupted as well.
Closed this issue · 2 comments
There was not a string name assigned to AdapterEvent.InvalidReport
or AdapterEvent.StreamingInterrupted
, so they both were notified as undefined
. This means that every time you get an invalid report that could not be fixed, you will also be disconnected from the device.
https://github.com/iotile/iotile-device/blob/master/src/device/iotile-serv.ts#L149
This is the cause of https://github.com/iotile/iotile-mobile-ionic/issues/1125
@dkarchmer @kayliedehart The impact of this bug is that every time a report is received from a device that is corrupt (and could not be fixed) since we installed the report reassembler logic will result in the user seeing a message that 'they were disconnected from the device because the app went to sleep'.
I'm fixing it now.