Skip to first unread message

Erik Vikersveen

unread,
Oct 11, 2015, 6:05:00 PM10/11/15
to MIT App Inventor Forum
Hey, been looking around to get some access to the IR-Blaster in my Samsung Galaxy S6 and found that Peel have an API for their app.

I found this, but seems to only do shows, not TV buttons:
http://tuneinapi.peel-ci.com

The idea is that at an electronic store there's a whole bunch of TV's that needs to be turned on in the morning, and off at the end of the day. So I only really need a lot of Power on/off buttons. Though access to the "ok" button would be nice as well.

Then I found this, and wondered if activity starter somehow could do this. I have no idea what I'm looking at here! (Android 4.4 API)

When running on a device that includes an infrared (IR) transmitter, you can now transmit IR signals using theConsumerIrManager APIs. To get an instance of ConsumerIrManager, call getSystemService() withCONSUMER_IR_SERVICE as the argument. You can then query the device's supported IR frequencies withgetCarrierFrequencies() and transmit signals by passing your desired frequency and signal pattern withtransmit().

You should always first check whether a device includes an IR transmitter by calling hasIrEmitter(), but if your app is compatible only with devices that do have one, you should include a <uses-feature> element in your manifest for"android.hardware.consumerir" (FEATURE_CONSUMER_IR).


Erik Vikersveen

unread,
Oct 11, 2015, 6:11:36 PM10/11/15
to MIT App Inventor Forum
Perhaps this is a way? Is there anyway I can get AI2 to run this java thing?

https://github.com/rngtng/IrDude/blob/master/src/com/rngtng/irdude/MainActivity.java

Erik Vikersveen

unread,
Oct 11, 2015, 6:16:07 PM10/11/15
to MIT App Inventor Forum

Abraham Getzler

unread,
Oct 12, 2015, 9:28:55 AM10/12/15
to MIT App Inventor Forum
Feel free to develop and test an extension for this facility.
See this link ...

ABG

Reply all
Reply to author
Forward
0 new messages