Is possible to have an app in background waiting for a peripheral?

Hi!
Im starting to use ionic with peripherals (earphones,onboard computers, etc)

Is possible to connect a peripheral via bluetooth and keep the app waiting in background to catch an event? For example, when a button is pushed , a wheel is rotated or u change the volume in the pheripheral.

If the app is in foreground, the pheripheral works, but in background it doesnt.

I saw that “background-mode” , let the app works in background, but I dont know if I possible to catch events from pheripherals.

Is this possible? And is “background-mode” the correct library?

Thanks!!