Spark server gives the 'Device disconnected' message every 46 seconds

photon
Tags: #<Tag:0x00007fe21f220fc0>

#1

I managed to run the local cloud ( Brewskey/ spark-server) and even connect my photon to it, but I get this message on the server console every ~46 seconds:

Device.js/14528 on hostName: Device disconnected (cache_key=_5, deviceID=deviceId, duration=46.791, disconnectCounter=1)

WARN: DeviceServer.js/14528 on host-name: Session ended for Device (connectionKey=_4, deviceID=deviceId, ownerID=ownerId)

It then reconnects itself after a few seconds, followed by this message:

INFO: DeviceServer.js/14528 on hostName: New Connection
[2019-08-11T13:19:33.315Z]  INFO: Device.js/14528 on hostName: Connection attributes (particleProductId=6, platformId=6, productFirmwareVersion=65535, reservedFlags=6)
[2019-08-11T13:19:33.315Z]  INFO: DeviceServer.js/14528 on hostName: Connection (connectionID=9, deviceID=deviceId, remoteIPAddress=::ffff:10.0.0.9)
(node:14528) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 newStatus listeners added. Use emitter.setMaxListeners() to increase limit
[2019-08-11T13:19:36.500Z]  INFO: Device.js/14528 on hostName: On device protocol initialization complete (cache_key=_9, deviceID=deviceId, firmwareVersion=65535, ip=::ffff:10.0.0.9, particleProductId=6, platformId=6)

Has anyone else faced the similar issue with Brewskey/ spark-server? Can anyone point me to the right direction on how to solve this issue?


#2

Managed to solve it by flashing the core with default usb tinker using particle flash --usb tinker while the core is in DFU mode.


#3

Could you tick the solution box if you think you have solved your original issue?


#4

@armor Thank you for the heads up, I wasn’t aware of the tick box until you mentioned (feeling a bit stupid.) :slight_smile: