通过 iPhone 音频插孔读取数据 [英] Read data through iPhone audio jack

查看:23
本文介绍了通过 iPhone 音频插孔读取数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在寻找一种方法来读取通过 iPhone 音频插孔从 Arduino 发送的原始数据.

我搜索了很多,发现

输入信号将是 analogue,因此您需要将其(通过 Frequency-shift keying 调制解调器)转换为 digital,这调制解调器库应该可以解决这个问题(我已经用它来转换成数字,不幸的是我没有我的旧项目可以分享,但它已经过测试):

https://github.com/jensmeder/FSKModemhttps://en.wikipedia.org/wiki/Frequency-shift_keying

也看看这个库(你试过了吗?也许它对你的情况会有更好的帮助):

https://github.com/billhsu/jackDuino

另请查看(适用于 iPhone 的音频插孔调制解调器):

https://www.sparkfun.com/products/retired/10331

I am looking for a way to read raw data that is being sent from the Arduino through iPhone's audio jack.

I searched a lot and found this which detects whether a jack plug is connected or not but couldn't find any code to read the raw data.

Any help in this regard will be greatly appreciated!

Thanks.

解决方案

If the bandwidth of the incoming signal fits into the bandwidth of the iPhone's A/D converter (± 20Hz to 20kHz) you can read it.

You'll need audio jack to audio jack cable with Tip/Ring1/Ring2/Sleeve pinout (Balanced plug on the picture) on both sides (Tip/Ring/Sleeve (Conventional stereo plug) won't work).

The incoming signal will be analogue so you'll need to convert it (through Frequency-shift keying modem) to digital, this modem library should do the trick (I've used it to convert into digital, unfortunately I do not have my old project to share but it's tested):

https://github.com/jensmeder/FSKModem https://en.wikipedia.org/wiki/Frequency-shift_keying

Also take a look at this lib (Did you try it? Maybe it will help better in your case):

https://github.com/billhsu/jackDuino

Also check this out (Audio Jack Modem for iPhone):

https://www.sparkfun.com/products/retired/10331

这篇关于通过 iPhone 音频插孔读取数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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