<bdo id='nKILr'></bdo><ul id='nKILr'></ul>
    1. <small id='nKILr'></small><noframes id='nKILr'>

      <i id='nKILr'><tr id='nKILr'><dt id='nKILr'><q id='nKILr'><span id='nKILr'><b id='nKILr'><form id='nKILr'><ins id='nKILr'></ins><ul id='nKILr'></ul><sub id='nKILr'></sub></form><legend id='nKILr'></legend><bdo id='nKILr'><pre id='nKILr'><center id='nKILr'></center></pre></bdo></b><th id='nKILr'></th></span></q></dt></tr></i><div id='nKILr'><tfoot id='nKILr'></tfoot><dl id='nKILr'><fieldset id='nKILr'></fieldset></dl></div>
      <legend id='nKILr'><style id='nKILr'><dir id='nKILr'><q id='nKILr'></q></dir></style></legend>

    2. <tfoot id='nKILr'></tfoot>
    3. Android 串口通过音频插孔

      Android serial port via audio jack(Android 串口通过音频插孔)

        <tfoot id='PH2qw'></tfoot>

          <bdo id='PH2qw'></bdo><ul id='PH2qw'></ul>
          <legend id='PH2qw'><style id='PH2qw'><dir id='PH2qw'><q id='PH2qw'></q></dir></style></legend>

            • <i id='PH2qw'><tr id='PH2qw'><dt id='PH2qw'><q id='PH2qw'><span id='PH2qw'><b id='PH2qw'><form id='PH2qw'><ins id='PH2qw'></ins><ul id='PH2qw'></ul><sub id='PH2qw'></sub></form><legend id='PH2qw'></legend><bdo id='PH2qw'><pre id='PH2qw'><center id='PH2qw'></center></pre></bdo></b><th id='PH2qw'></th></span></q></dt></tr></i><div id='PH2qw'><tfoot id='PH2qw'></tfoot><dl id='PH2qw'><fieldset id='PH2qw'></fieldset></dl></div>
            • <small id='PH2qw'></small><noframes id='PH2qw'>

                <tbody id='PH2qw'></tbody>
                本文介绍了Android 串口通过音频插孔的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                问题描述

                我想通过音频插孔使用串行端口获取数据.我对此一无所知.但我发现一个应用 audioserial 可以向其发送数据.所以,我认为应该获取 audioserial 之类的数据.是否有相同的项目或熟悉这个?

                I want to get data using serial port via audio jack. I don't have any idea about this. But I find a app audioserial can send data to. So, I think it should be get data like audioserial. Is there same project or familiar about this?

                推荐答案

                您可以毫无问题地在麦克风插孔上录制音频.这样做,您基本上可以将您的 Android 手机用作数字示波器.然后,您可以通过编程方式将其转换回数字 I/O.

                You can record audio on the microphone jack without any problems. Doing this, you can essentially use your Android phone as a digital oscilloscope. You can then programatically convert this back to digital I/O.

                Serial output -> Android audio input -> Sampled square block wave -> digital I/O
                

                请注意,大多数串行电平是 5V 或 3.3V.这会破坏您的麦克风输入!消费类音频电子产品的峰值电平通常为 1.7V.您将需要使用两个电阻器创建一个分压器,以便能够将您的 android 麦克风输入用作串行输入.如果您想创建符合规范 (http://en.wikipedia.org/wiki/RS-232#Voltage_levels) 的设备,您需要能够处理 -3V 到 +25V!

                Please note that most serial levels are either 5V or 3.3V. This will destroy your microphone input! Peak level for consumer audio electronics is usually 1.7V. You will need to create a voltage divider using two resistors to be able to use your android microphone input as a serial input. If you want to create a device that behaves according to the spec (http://en.wikipedia.org/wiki/RS-232#Voltage_levels), you will need to be able to handle -3V to +25V!

                然后您需要对音频输入进行采样.请参阅 http://en.wikipedia.org/wiki/File:Rs232_oscilloscope_trace.svg 获取您将收到的输入内容的良好示波器轨迹.您将需要创建 Java 代码来检测 RS-232 的时间以及开始和停止位(如果已配置).

                You will then need to sample the audio input. See http://en.wikipedia.org/wiki/File:Rs232_oscilloscope_trace.svg for a nice oscilloscope trace of what you will receive as input. You will need to create Java code to detect the timing of RS-232 as well as the start and stop bits (if configured).

                我认为您项目的决定因素将是手机的 CPU 速度.我不确定您是否能够以 19200 波特率与对方通话并同时生成 UI.

                I think the determining factor in your project will be CPU speed of the phone. I'm not sure you will be able to talk 19200baud with the remote party and be able to generate a UI at the same time.

                顺便说一句,也可以进行反向操作(生成方波来驱动串行输出),但需要一些电压倍增器(达林顿链或其他基于晶体管的方法)将电压增加到所需的水平(+5V).

                Doing the inverse is also possible by the way (generating a square waveform to drive a serial output), but will require some voltage multiplier (darlington chain or other transistor-based method) to increase the voltage to the desired level (+5V).

                这篇关于Android 串口通过音频插孔的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                相关文档推荐

                script.sh: line 1: ./gradlew: No such file or directory on Jenkins(script.sh:第 1 行:./gradlew:Jenkins 上没有这样的文件或目录)
                Arduino: using Serial and Software Serial with bluetooth module(Arduino:使用带有蓝牙模块的串口和软件串口)
                Access native serial port on Android(在Android上访问本机串口)
                Android: USB Communication Android lt;-gt; External Device(Android:USB通信Androidlt;-gt;外接设备)
                Sending commands from a PC to an Android phone - via physical connection (USB, Serial, etc)(从 PC 向 Android 手机发送命令 - 通过物理连接(USB、串行等))
                Android: RS232 Serial Communication with android device(Android:与安卓设备的RS232串行通信)
              • <tfoot id='nQ4Aq'></tfoot>

                  <legend id='nQ4Aq'><style id='nQ4Aq'><dir id='nQ4Aq'><q id='nQ4Aq'></q></dir></style></legend>
                    <tbody id='nQ4Aq'></tbody>

                    <bdo id='nQ4Aq'></bdo><ul id='nQ4Aq'></ul>

                          <small id='nQ4Aq'></small><noframes id='nQ4Aq'>

                        1. <i id='nQ4Aq'><tr id='nQ4Aq'><dt id='nQ4Aq'><q id='nQ4Aq'><span id='nQ4Aq'><b id='nQ4Aq'><form id='nQ4Aq'><ins id='nQ4Aq'></ins><ul id='nQ4Aq'></ul><sub id='nQ4Aq'></sub></form><legend id='nQ4Aq'></legend><bdo id='nQ4Aq'><pre id='nQ4Aq'><center id='nQ4Aq'></center></pre></bdo></b><th id='nQ4Aq'></th></span></q></dt></tr></i><div id='nQ4Aq'><tfoot id='nQ4Aq'></tfoot><dl id='nQ4Aq'><fieldset id='nQ4Aq'></fieldset></dl></div>