18 0
Contact Author Sign in to rate

Contanki - Controller Support for Anki (beta)

3.43MB. Updated 2022-08-03.
The author has shared 2 other item(s).


Contanki allows Anki to be used with a gamepad or other controller device. Features: Usage Notes Connect your controller via USB or Bluetooth, install the add-on, restart Anki, and press any button to get started. Since Anki has a lot of functions to map, Contanki uses modifier buttons (by default, the triggers (R2 and L2) are used). This mean that the other buttons will trigger different commands according to whether a modifier button is held down, similar to shift, control, etc on a keyboard. Holding down the modifier buttons will also pull up an overlay showing the control binding for the current context. To show the overlay for the unmodified controls, hold down both triggers at once. Controls can be reassigned using the add-on's config dialog. You can assign controls for each context (review, deck browser, etc), as well as global settings that are used if a control isn't assigned to a particular context. It is suggested that you try the default control bindings to begin with, and make changes as needed. You can remove any actions you don't need if the controls overlay is too cluttered. Support is provided for 2.1.45 and above, but please note the version specific issues below. Analog Sticks By default the right stick is used to move and click the mouse, and you can use L2 + right stick for a secondary click. It is only possible to click within Anki. The left stick is used to scroll and to navigate between views. Sticks can be reassigned and can also be put in 'button mode', where actions can be assigned to the directions of a stick. Choosing a Controller I have been testing using a DualShock 4, which makes a good choice and can be readily purchased secondhand at a reasonable price. The cheapest option would be a knockoff SNES controller, which can be found for $10 or less. Currently it is only possible to use a single controller at a time. This may include Joy-Cons depending on your system, but support for using both Joy Cons is planned. Testing This add-on is still in beta, so there may still be some bugs. Please report all issues on the GitHub issue tracker or on the Anki add-on forum. Reports about bugs on Windows or when using an Xbox controller are particularly welcome as I have been testing mostly on Mac using a DualShock 4 up to now. If you encounter an issue, let me know what you were trying to do, what platform and controller you're using, and the text of any error or message your receive. You can also obtain some debug information by clicking the help button in the Contanki's config. Please take note of the known issues and don't report anything listed there. Suggestions are also welcome, and can also be raised on the issue tracker or forum. ## Known issues - Interaction outside of the main window (especially the browser and preferences) is only partially implemented - Clicking outside Anki or in the title or menu bars doesn't work - Add-on doesn't function in the profile window - Unable to open or close webview context menus Version Specific: - Opening certain menus or dialogs prevents any actions from firing, until it's closed and they fire all at once. This mostly affectts Anki 2.1.49 and below. The above issue is mostly fixed in 2.1.50, but some dialogs may still prevent actions from firing - A small number of actions are only supported in 2.1.50 Platform Specific - Volume controls only work on MacOS - Steam Deck is currently unsupported while we wait for Qt to upgrade to a newer Chromium version - Cursor control doesn't work on Linux Controller Specific - Only a single Joy-Con can be used at a time. Support for using a pair of Joy-Cons as a single controller is planned - Certain 8BitDo controllers may have incorrect button mapping or fail to be detect if they are set on the wrong mode. Try a different controller mode if this happens. More info here. Add-on compatibility - Not compatible with: - Anjoy - Has issues: - Customize Keyboard Shortcuts - a small number of actions rely on simulating a key press, and won't work if you've changed that shortcut. Instead you can create a custom action in the controller options using your assigned shortcut


As add-ons are programs downloaded from the internet, they are potentially malicious. You should only download add-ons you trust.

Supported Anki versions:

To download this add-on, please copy and paste the following code into Anki 2.1:


If you were linked to this page from the internet, please open Anki on your computer, go to the Tools menu and then Add-ons>Browse & Install to paste in the code.

All Anki 2.1.x Add-Ons Contact Author


on 1659525566
on 1659449273
Can you add support to turn off light bar in dual shock 4 ? it's really irritating
Comment from author
Yeah this annoys me too, but unfortunately the API doesn't support controlling the light. It's possible with other software - on Windows DS4Windows lets you turn off the light and on Mac (and Windows) it can be done with Steam. Not super convenient but it does work.
on 1656639107
An error occurred. Please start Anki while holding down the shift key, which will temporarily disable the add-ons you have installed.
If the issue only occurs when add-ons are enabled, please use the Tools > Add-ons menu item to disable some add-ons and restart Anki, repeating until you discover the add-on that is causing the problem.
When you've discovered the add-on that is causing the problem, please report the issue to the add-on author.
Debug info:
Anki 2.1.53 (96bacf79) Python 3.9.7 Qt 5.15.2 PyQt 5.15.5
Platform: Windows 10
Flags: frz=True ao=True sv=3
Add-ons, last update check: 2022-06-30 02:35:44

Caught exception:
Traceback (most recent call last):
File "aqt.webview", line 42, in cmd
File "aqt.webview", line 149, in _onCmd
File "aqt.webview", line 613, in _onBridgeCmd
File "aqt.hooks_gen", line 4323, in __call__
File "C:\Users\victo\AppData\Roaming\Anki2\addons21\1898790263\contanki.py", line 103, in on_receive_message
File "C:\Users\victo\AppData\Roaming\Anki2\addons21\1898790263\contanki.py", line 47, in on_connect
self.buttons = [False] * buttons
TypeError: can't multiply sequence by non-int of type 'str'

Can you help?
Comment from author
This issue should already be resolved in the update I pushed yesterday. If it's still not working for you, try reinstalling the add-on to make sure you have the latest version, and if it still doesn't work it would be great if you could post on GitHub as it's easier to discuss the issue on there. Thanks for reporting the problem!

on 1656578968

当你已经发现是因为插件引起的问题,请在我们的支持网站上 [插件支持](https://help.ankiweb.net/discussions/add-ons/) 上报告问题。
Anki 2.1.49 (dc80804a) Python 3.8.6 Qt 5.14.2 PyQt 5.14.2
Platform: Mac 10.16
Flags: frz=True ao=True sv=2
Add-ons, last update check: 2022-06-29 17:37:59
相关扩展:⁨Contanki - Controller Support for Anki beta⁩

Caught exception:
Traceback (most recent call last):
File "aqt/webview.py", line 41, in cmd
File "aqt/webview.py", line 142, in _onCmd
File "aqt/webview.py", line 589, in _onBridgeCmd
File "aqt/hooks_gen.py", line 4034, in __call__
File "/Users/lingyi/Library/Application Support/Anki2/addons21/1898790263/contanki.py", line 103, in on_receive_message
File "/Users/lingyi/Library/Application Support/Anki2/addons21/1898790263/contanki.py", line 47, in on_connect
self.buttons = [False] * buttons
TypeError: can't multiply sequence by non-int of type 'str'
Comment from author
这个问题应该被昨天的更新已经解决了。如果你还有问题重新安装。 还有问题的话我建议你在GitHub上发帖,比较容易沟通。谢谢你告诉我有这个问题

on 1655888325
PRO: Epic addon! Really has everything one could wish for and also works reasonably well for its age. Support for the main controllers and direct binding of anki functions. SUPER NICE! I was waiting for this for a long time!

Con: There are still a range of bugs. Particularly when using full screen swaps. Nonetheless, the pros already outweigh the cons by far :) Keep up the good work!!
on 1655615416
Works amazingly well.
on 1653882388
I have been using it for about an hour with my Xbox controller on Windows. I do not see any problems so far. I could comfortably lie on my gaming chair while going over the cards. 10/10
on 1653700245
This is gold. Got a donation link? Smashing the spacebar was wrecking my fingers until I got the 8bitdo. Then I heard nightmares of using Karabiner.
One thing I'm looking for is a toggle function, normally the 'g' key on keyboard. Any way to do this at present? I might have overlooked it within the different settings. Thank you for this glorious add on, brilliant work!
Comment from author
Not yet, but I'll think about it <3.

Yeah... Karabiner is great for certain use cases, but it's definitely a pain for something like this.

You can add 'custom actions' in the controller preferences. Custom actions are just keyboard shortcuts - add them in the main preferences screen, and that action will then be available to be assigned to buttons on the controls screen.
on 1651747496
Great addon! Much more stable than Joymapper :)
on 1651699952
on 1651583944
Phenomenal addon!
on 1651583939
This works impressively well and the dialog is incredibly clean. I will be adding this to all my Recommended add-ons pages :)
- The AnKing
Comment from author
Thanks! Don't hesitate to pass on any feedback 😁
on 1650543893
Connects easier than most of my games! Thanks so much for making the overlays, they're genius.

I don't know if it's possible, but in some future update it would be cool for the controller to vibrate when you get a question wrong, like when you take damage in a game.
Comment from author
This will probably be added at some point, though my priority right now is ensuring controller and platform compatibility rather than new features. Still, thanks for the feedback!
on 1650262609
Great idea, thanks!
on 1650070296
Ever since switching from using a PC to a Mac, I tried many different ways to connect my controller to Anki. THIS IS THE ONLY THING THAT WORKS!! THANK YOU FOR MAKING ANKI SO MUCH MORE FUN AND EASY!!
on 1649679211
It's a must have!!!
on 1649634750
It works very well! Thank you very much!
on 1649511609
Nice work :)