建立和建立通过PHP中的GSM调制解调器接听电话 [英] Establish & Receive Calls via a GSM modem in PHP

查看:106
本文介绍了建立和建立通过PHP中的GSM调制解调器接听电话的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个基于php的CRM(客户关系管理软件),并在localhost(Windows XP系统)上运行它.这包含我的客户列表.我希望能够直接从我的CRM呼叫这些客户,并保持相同的日志. (通话时间,通话时间和通话记录).对于来电,我应该可以将其链接到我的CRM,显示客户详细信息并记录数据.

I am having a CRM (Customer Relationship Management Software) built on php and running it on localhost (windows XP system). This contains the list of my clients. I want to be able to call these clients directly from my CRM and keep a log of the same. (Call time, call duration and record the calls). For incoming calls, I should be able to link it to my CRM, display the client details and log the data.

我有一个启用语音的3G GSM调制解调器(带有USB连接器),可用于此目的.通过搜索,我了解到我需要从PHP发送AT命令才能与调制解调器进行交互.但是我无法继续前进,因为我对此完全陌生.在此之前,我从未做过任何设备接口.

I have a voice enabled 3G GSM Modem (with USB connector) which can be used for this purpose. From my search, I understand I would need to send AT commands from PHP to interact with the modem. But I am not able to move ahead as I am completely new to this. I have never done any device interfacing before this.

您能帮助我了解如何解决上述问题吗?任何线索,朝这个方向的资源都会有很大帮助.

Can you help me to understand how can I go about solving the above issue? Any leads, resources in this direction will be of great help.

推荐答案

我不会尝试使用纯PHP进行此操作,因为那样的话,您将不得不通过Web服务器与硬件建立PHP接口,这可能会很麻烦,如果它是可管理的.我认为有(编辑)三个选项:

I wouldn't try to do this with pure PHP since then you would have to have PHP interface with the hardware through the webserver, which can be a pain, if it is manageable at all. There are (edit) three options in my view:

1:又是硬道理:
用C编写一个PHP扩展来实现您想要的功能,但这将意味着为一个相对较小的任务进行大量编程.

1: AKA the hard way:
Write a PHP extension in C that does what you want, but this would mean a lot of programming for a relative small task.

2:简便[y/ier]方式:
查找可以与调制解调器进行语音通信并具有API或CLI的程序(也许是Skype?),以便运行PHP:
voiceprogram.exe --call=555-000-5555 --saveTo=client1_20113103_1200.mp3
这使应用程序可以做其所擅长的事情,并且仅使用PHP作为控制器.生成的MP3(或Wav,OGG等)可以保存回CRM.

2: The eas[y/ier] way:
Find a program (Maybe Skype?) that can do voice communication with your modem and has an API or a CLI so you can make PHP run:
voiceprogram.exe --call=555-000-5555 --saveTo=client1_20113103_1200.mp3
This allows the application to do what it's good as and only use PHP as the controller. The resulting MP3 (or Wav, OGG, etc) can be saved back to the CRM.

3:其他选项
如果您能够使用与调制解调器轻松通信的其他语言进行编程,则可以编写一些可由PHP触发的自定义代码(套接字/SOAP/CLI)并处理该调用.完成后,它可以将呼叫信息发布"回您的PHP脚本.

3: Other options
If you are able to program in a different language that does communicate easily with your modem you can write some custom code that can be triggered by PHP (sockets/SOAP/CLI) and handles the call. When finished it can 'POST' the call information back to your PHP script.

前两个解决方案仅在CRM在本地主机上运行时才有效,如果您计划在共享的网络环境中使用此解决方案,则复杂性将会增加.如果正确完成,最后一个选项可以在共享环境中使用.

The first 2 solutions only work when the CRM runs on localhost, if you plan on using this in a shared network environment complexity will go up. The last option, if done correctly, can be used in a shared environment.

这篇关于建立和建立通过PHP中的GSM调制解调器接听电话的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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