Highlighted

Controller not recognized on Android TV

Explorer ,
Nov 24, 2015

Copy link to clipboard

Copied

Hi there,

I've started using AIR 20 to take advantage of the Android TV support. I successfully built a version of my game supporting Android TV and have it running great on the new Razer Forge TV.

I can't, however, seem to get the controller to be recognized. I'm using a wired Xbox360 controller, which works perfectly when plugging it on the PC build, but not on the Forge TV. The controller works well in the Forge TV menus and in other games.

Are there any outstanding issues with controller recognition on Android TV? The GameInputEvent.DEVICE_ADDED doesn't trigger at all.

Thank you

TOPICS
Air beta

Views

1.1K

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Controller not recognized on Android TV

Explorer ,
Nov 24, 2015

Copy link to clipboard

Copied

Hi there,

I've started using AIR 20 to take advantage of the Android TV support. I successfully built a version of my game supporting Android TV and have it running great on the new Razer Forge TV.

I can't, however, seem to get the controller to be recognized. I'm using a wired Xbox360 controller, which works perfectly when plugging it on the PC build, but not on the Forge TV. The controller works well in the Forge TV menus and in other games.

Are there any outstanding issues with controller recognition on Android TV? The GameInputEvent.DEVICE_ADDED doesn't trigger at all.

Thank you

TOPICS
Air beta

Views

1.1K

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Nov 24, 2015 0
Adobe Employee ,
Nov 24, 2015

Copy link to clipboard

Copied

Hi,

To get the support of game controller in your application, you have to ensure that your application is well-suited for multiple input devices with varying capabilities and controls.

Can you please check if your controller device is getting detected using below code:

trace("GameInput.isSupported - " + GameInput.isSupported);

trace("GameInput.numDevices - " + GameInput.numDevices);

trace("GameInput.getDeviceAt- " + GameInput.getDeviceAt(0));

you can refer to this blog to get the support of game controller in your application:

Game controllers on Adobe AIR | Adobe Developer Connection


Thanks.

Adobe Air Team

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Nov 24, 2015 0
Explorer ,
Nov 27, 2015

Copy link to clipboard

Copied

I just ran a test and both isSupported=true and numDevices=1 so it correctly sees there's a controller connected.

However the listeners still fail to activate, whether the controller is plugged in at app start or not.

No errors are thrown.

Is what I'm experiencing related to this?

[Android] AIR Game Pad is not getting launched on Android M. (4015404)

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Nov 27, 2015 0
Adobe Employee ,
Nov 30, 2015

Copy link to clipboard

Copied

Hi,

No, Your issue is not related to bug: [Android] AIR Game Pad is not getting launched on Android M. (4015404)

I want to confirm if you are not getting the device id when using trace("GameInput.getDeviceAt- " + GameInput.getDeviceAt(0)); ?

Thanks,

Adobe AIR Team

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Nov 30, 2015 0
Explorer ,
Dec 01, 2015

Copy link to clipboard

Copied

I've done some more testing:

I tried with a PS4 Controller (via bluetooth) and the result is:

GameInput.isSupported = true

GameInput.numDevices = 0

GameInput.getDeviceAt(0) = null

And I tried with a plugged in X360 controller:

GameInput.isSupported = true

GameInput.numDevices = 0

GameInput.getDeviceAt(0) = null

So the exact same thing. Not sure how i got numDevices = 1 the previous time. I can't get that to happen again.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Dec 01, 2015 0
New Here ,
Dec 04, 2015

Copy link to clipboard

Copied

Hi,

I've got same issue =/ I get this results :

GameInput.isSupported true

GameInput.numDevices 1

GameInput.getDeviceAt null

I need to instantiate one GameInput object before in order to have one device. But still can't access to it because it's always null value. =/

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Dec 04, 2015 0
Explorer ,
Dec 10, 2015

Copy link to clipboard

Copied

Any answer on this? Is this officially a bug?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Dec 10, 2015 0
Explorer ,
Dec 14, 2015

Copy link to clipboard

Copied

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Dec 14, 2015 0
Adobe Employee ,
Dec 15, 2015

Copy link to clipboard

Copied

Hi,

We tried diagnosing the bug at our end and we are able to get the below results:

GameInput.isSupported - true

GameInput.numDevices - 1

GameInput.getDeviceAt- [object GameInputDevice]

AIRSDK Used: 20.0.0.185

Please find the attached sample project here: Bug#4099831 - Controller not recognized on Android TV

Please verify the bug at your end using the sample project.

Do let us know if you face any further problem.

Thanks,

Adobe AIR Team

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Dec 15, 2015 0
Explorer ,
Dec 16, 2015

Copy link to clipboard

Copied

I'll test it soon and get you a response. Thanks for checking into it

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Dec 16, 2015 0
geretti LATEST
Explorer ,
Dec 22, 2015

Copy link to clipboard

Copied

The latest AIR SDKs on Windows (.225 or .230) have trouble compiling with the AndroidTV tags. It says they're invalid and I can no longer compile 😕

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Dec 22, 2015 0