Android 推送消息(MQTT) PHP发送
来源:互联网 发布:bs软件开发工具 编辑:程序博客网 时间:2024/05/16 12:06
1.服务器安装:IBM的 RSMB (MQTT协议代理)
Really Small Message Broke(rsmb_1.2.0)
http://download.csdn.net/detail/wuzehai02/4735055
安装
To start the broker on Windows:
- In the folder where you installed the broker, double-click broker.exe.
To start the broker on Linux:
- In a terminal, change to the directory where you installed the broker; for example:
cd /home/laura/broker
- Enter the appropriate command for your platform. For example, on Ubuntu, type:
./broker.ubuntu
Alternatively, to run the broker in the background so that it will continue to run when you log out of the session, enter the following command:nohup ./broker.ubuntu >> /dev/null &
The broker is now ready to publish messages.
To stop the broker cleanly, type Ctrl-C. On Linux, if you prefer, you can just kill the process of the running broker:
ps -ef | grep brokerkill -term process_id_of_the_running_broker
2 服务器消息发送方:
PHP服务器端使用的是:SAM 针对MQTT写的PHP库 (下载链接为Tokudu PHPMQTT通信项目),其中send_mqtt.php是一个通过POST接收消息并且通过SAM将消息发送给RSMB的PHP脚本。
下载地址
http://download.csdn.net/detail/wuzehai02/4735078
3 ANDROID 客户端的消息PUSH DEMO
下载地址
http://download.csdn.net/detail/wuzehai02/4735172
经过本人测试过,代码绝对可用
- Android 推送消息(MQTT) PHP发送
- Android MQTT消息推送实践
- Android MQTT实现消息推送
- [Android实例] MQTT协议,Android消息推送
- mqtt向android推送消息(一)——发送端使用.net
- 采用MQTT协议实现Android消息推送
- 用MQTT协议实现android消息推送
- android采用IBM-MQTT协议消息推送。
- 采用MQTT协议实现Android消息推送
- 采用MQTT协议实现Android消息推送
- 采用MQTT协议实现Android消息推送
- android消息推送——mqtt协议
- 采用MQTT协议实现Android消息推送
- 采用MQTT协议实现Android消息推送
- 采用MQTT协议实现android消息推送
- 基于MQTT协议推送Android消息
- 采用MQTT协议实现Android消息推送
- 采用MQTT协议实现Android消息推送
- 蓝牙 模式和规格
- 安森美半导体强化汽车战略,倾力服务中国汽车市场
- ODI 反向导入Essbase模型
- PHP 批量删除功能
- [IOS] Storyboard全解析-第一部分
- Android 推送消息(MQTT) PHP发送
- 冒泡排序(php)
- 通向架构师的道路(第一天)之Apache整合Tomcat
- oAuth 授权及其他
- 黑马程序员_Annotation
- 学习一下数据结构
- delete指针时coredump的分析之旅
- 一步一步学习Vim 全图解释
- wince 5.0 eVC 4.0设置输入法选项窗口的位置