通过Android代码发送彩信
ConnectivityManager.requestRouteToHost(ConnectivityManager.TYPE_MOBILE_MMS,APNBACKENDIP);
And that function returns true
意味着它应该通过 TYPE_MOBILE_MMS
接口路由流量,但它总是超时。有人能指出我正确的方向吗?我还尝试使用 TYPE_MOBILE
而不是 TYPE_MOBILE_MMS
并且该函数返回 false。
I'm looking at the code posted here for sending MMS through an Android Application, and I'm very close. I have successfully sent an MMS while the Wifi connection is NOT enabled. But when it comes time to use the httpConnection
in never connections when Wifi is enabled. I've read several posts saying to use
ConnectivityManager.requestRouteToHost(ConnectivityManager.TYPE_MOBILE_MMS,APNBACKENDIP);
And that function returns true
meaning that it should route traffic over the TYPE_MOBILE_MMS
interface, but it always times out. Can anyone point me in the right direction? Also I tried using TYPE_MOBILE
instead of TYPE_MOBILE_MMS
and the function returns false instead.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
![扫码二维码加入Web技术交流群](/public/img/jiaqun_03.jpg)
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
事实证明这是一个非常简单的答案......在计算 requestRouteToHost 的 IP 地址时,我的 IP 四元组颠倒了。
IE 我有:
而它应该是:
Turns out it was an incredibly simple answer....I had my IP quad reversed when calculating the IP address for requestRouteToHost.
I.E I had:
Whereas it should be: