通过处理/控制Arduino的Spotify的 [英] Controlling Spotify through Processing/Arduino

查看:136
本文介绍了通过处理/控制Arduino的Spotify的的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我提出了Spotify的有形控制器(像霍尔迪帕拉之一, http://vimeo.com/21387481#at = 0 )使用一个Arduino微控制器。

I am making a tangible controller for Spotify (like the one from Jordi Parra, http://vimeo.com/21387481#at=0) using an Arduino microcontroller.

我有一个处理草图运行的所有不与Arduino的数据计算。我想这个处理草图能在Spotify的控制不同的选项,如:下一步,previous,播放/暂停,音量加/减,随机

I have a Processing sketch running which does all the calculations with the data from the Arduino. I want this Processing sketch to be able to control different options in Spotify like: Next, Previous, Play/Pause, Volume Up/Down, Shuffle.

现在,我使用一个额外的Arduino莱昂纳多它模拟键presses而AutoHotkey的倾听者,并将它们发送到Spotify的。它不工作得很好,我只有有限的选择。

Right now I use an extra Arduino Leonardo which simulates key presses while AutoHotKey listens to those and sends them to Spotify. It does not work very well and I only have limited options.

我希望同时获得更多的控制权,以摆脱额外的Arduino的。
我工作在Windows的事情,所以苹果脚本将无法工作(对我来说)。

I would love to get rid of that extra Arduino while getting more control. I am working on a Windows thing so Apple script won't work (for me).

有没有控制从处理Spotify应用的可能?或者是有可能使用该库创建在处理一个新的Spotify应用?

Is there a possibility to control the Spotify app from Processing? Or is it possible to use the library to create a new Spotify app in Processing?

提前感谢!

推荐答案

免责声明:我在Spotify的工作

现在有没有跨平台的方式来控制Spotify的应用程序。在Linux上,Spotify的将要DBUS响应命令,这意味着黑客一点的可以发送播放/暂停/下一首/ previous。我听说,它也可以通过AppleScript的控制Spotify的Mac OSX上,但我不是100%肯定这一点。快速谷歌搜索控制Spotify的Mac OS X的AppleScript的产生了一些有趣的结果,但我不知道如何对现有的或相关的任何人都。为Windows,我不知道是否/如何一会在所有控制应用程序。

Right now there is no cross-platform way to control the Spotify application. On Linux, Spotify will respond to dbus commands, which means that a bit of hacking could send play/pause/next/previous. I have heard that it is also possible to control Spotify on Mac OSX via applescript, but I'm not 100% certain about this. A quick google search for "control spotify mac os x applescript" produced some interesting results, though I'm not sure how current or relevant any of them are. As for Windows, I'm not sure if/how one would control the application at all.

否则,您最好的选择是 libspotify ,为此你需要编写一个处理库进行沟通它。基于有点快的研究,似乎处理库是用Java编写的,这意味着你要么需要使用包装如的 jlibspotify 或手工滚你自己的JNI包装器libspotify。

Otherwise, your best bet would be libspotify, for which you would need to write a Processing library to communicate with it. Based on a bit of quick research, it seems that Processing libraries are written in Java, which means you'd either need to use a wrapper such as jlibspotify or hand-roll your own JNI wrapper for libspotify.

我不知道怎么jlibspotify电流,因为他们是一个包裹,而老版本的库。如果任何libspotify黑客它是在C / C做得更好++以最小的JNI包装,但所有的这可能是方式更多的工作比你正打算为这个项目。

I'm not sure how current jlibspotify is, given that they are wrapping a rather old version of the library. If you do any libspotify hacking it is better done in C/C++ with a minimal JNI wrapper, but all of this may be way more work than you are intending for this project.

这篇关于通过处理/控制Arduino的Spotify的的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆