const devicesEmitter = require('adb-devices-emitter')
devicesEmitter.on('deviceAdded', ({ sn }) => {
console.log('deviceAdded sn:', sn)
})
devicesEmitter.on('deviceRemoved', ({ sn }) => {
console.log('deviceRemoved sn:', sn)
})
devicesEmitter.start()
const devicesEmitter = require('adb-devices-emitter')
devicesEmitter.on('deviceAdded', ({ sn }) => {
console.log('deviceAdded sn:', sn)
})
devicesEmitter.on('deviceRemoved', ({ sn }) => {
console.log('deviceRemoved sn:', sn)
})
devicesEmitter.start()
setTimeout(() => {
console.log('stop')
devicesEmitter.stop()
}, 100000)