dgis / emu48android

Emu48 for Android
GNU General Public License v2.0
56 stars 17 forks source link

Is it possible to use the phone's IR blaster? #16

Open MicaelJarniac opened 3 years ago

MicaelJarniac commented 3 years ago

Hi!

I have a Xiaomi POCO X3 NFC, and this phone has a built-in IR blaster. I also happen to have the physical HP 82240B.

So I was wondering, is it possible to have the app use the phone's IR blaster, so I can use it with my printer, instead of only using the virtual printer?

I tried searching for it, and also searched around in the settings, but I couldn't find it.

dgis commented 3 years ago

Hi, It is an interesting idea, but it could be too difficult to implement without the hardware. I don't have printer or your mobile phone which is quite specific. I'm not sure that this kind of IR blaster use the same API (https://www.amazon.fr/gp/product/B07Q367FC2).

MicaelJarniac commented 3 years ago

I've done some searching around, and I found the following library: https://github.com/OneButtonDeveloper/AndroidInfraRed

And I believe this is what is used for interacting with the IR blaster: https://developer.android.com/reference/android/hardware/ConsumerIrManager

I'd gladly help testing and debugging. I've never developed for Android before, but I'll see if I can figure it out.