使用 Tasker 应用程序在三星 Android 设备上发送短信失败

问题描述 投票:0回答:1

我需要在一段时间后自动尝试在 Samsung Android (Galaxy S10) 设备上重新发送失败的传出短信(由于信号质量差、没有积分、没有插入 SIM 卡等)。

我找到了Tasker应用程序(任何其他方法/建议来做这件事也可以)。

我尝试捕捉 Tasker

SMS Failure
事件,但没有帮助。手册中对此事件有注释:
Only works for an SMS sent by Tasker's Send SMS action
。但我需要从本机短信应用程序捕获失败事件。

我也尝试过用 Tasker 捕捉 Intent

com.samsung.intent.action.SMS_SEND_FAIL
。它也不起作用(可能是错误的意图名称?)。

LogCat条目解析也无用,因为不包含短信数据(我需要短信接收者电话号码和短信才能尝试重新发送)。

最后我尝试从手机内部本机数据库获取短信,但我只能获取成功发送的消息和收件箱:

content://sms/inbox
- 好的(收到短信)

content://sms/sent
- 好的(发送成功)

content://sms
- 好的(收件箱+已发送)

content://sms/all
- 空

content://sms/failed
- 空

content://sms/queued
- 空

content://sms/draft
- 空

content://sms/outbox
- 空

content://sms/undelivered
- 空

还有其他解决方案吗?非常感谢!

android sms tasker
1个回答
0
投票

这是我的污垢解决方案(需要根)。

<TaskerData sr="" dvi="1" tv="6.1.32">
 <Profile sr="prof12" ve="2">
  <cdate>1691745640721</cdate>
  <edate>1691750328401</edate>
  <flags>8</flags>
  <id>12</id>
  <limit>true</limit>
  <mid0>13</mid0>
  <nme>Failed SMS Retry</nme>
  <Time sr="con0">
   <fh>6</fh>
   <fm>0</fm>
   <rep>2</rep>
   <repval>10</repval>
   <th>23</th>
   <tm>0</tm>
  </Time>
 </Profile>
 <Task sr="task13">
  <cdate>1691745663215</cdate>
  <edate>1691750291965</edate>
  <id>13</id>
  <nme>Process Failed Sms</nme>
  <pri>100</pri>
  <Action sr="act0" ve="7">
   <code>667</code>
   <Int sr="arg0" val="0"/>
   <Str sr="arg1" ve="3">/data/data/com.android.providers.telephony/databases/mmssms.db</Str>
   <Int sr="arg10" val="1"/>
   <Str sr="arg2" ve="3"/>
   <Str sr="arg3" ve="3"/>
   <Str sr="arg4" ve="3">SELECT _id, address, body, type FROM sms WHERE [type] = 5 ORDER BY _id ASC LIMIT 1</Str>
   <Str sr="arg5" ve="3"/>
   <Str sr="arg6" ve="3"/>
   <Str sr="arg7" ve="3">∆</Str>
   <Str sr="arg8" ve="3">%SMSES</Str>
   <Int sr="arg9" val="0"/>
  </Action>
  <Action sr="act1" ve="7">
   <code>548</code>
   <on>false</on>
   <Str sr="arg0" ve="3">%SMSES(1)</Str>
   <Int sr="arg1" val="1"/>
   <Str sr="arg10" ve="3"/>
   <Int sr="arg11" val="1"/>
   <Int sr="arg12" val="0"/>
   <Str sr="arg13" ve="3"/>
   <Int sr="arg14" val="0"/>
   <Str sr="arg15" ve="3"/>
   <Int sr="arg2" val="0"/>
   <Str sr="arg3" ve="3"/>
   <Str sr="arg4" ve="3"/>
   <Str sr="arg5" ve="3"/>
   <Str sr="arg6" ve="3"/>
   <Str sr="arg7" ve="3"/>
   <Str sr="arg8" ve="3"/>
   <Int sr="arg9" val="1"/>
  </Action>
  <Action sr="act2" ve="7">
   <code>547</code>
   <Str sr="arg0" ve="3">%SMS</Str>
   <Str sr="arg1" ve="3">%SMSES(1)</Str>
   <Int sr="arg2" val="0"/>
   <Int sr="arg3" val="0"/>
   <Int sr="arg4" val="0"/>
   <Int sr="arg5" val="3"/>
   <Int sr="arg6" val="1"/>
   <ConditionList sr="if">
    <Condition sr="c0" ve="3">
     <lhs>%SMSES(#)</lhs>
     <op>0</op>
     <rhs>1</rhs>
    </Condition>
   </ConditionList>
  </Action>
  <Action sr="act3" ve="7">
   <code>590</code>
   <Str sr="arg0" ve="3">%SMS</Str>
   <Str sr="arg1" ve="3">∆</Str>
   <Int sr="arg2" val="1"/>
   <Int sr="arg3" val="0"/>
   <ConditionList sr="if">
    <Condition sr="c0" ve="3">
     <lhs>%SMSES(#)</lhs>
     <op>0</op>
     <rhs>1</rhs>
    </Condition>
   </ConditionList>
  </Action>
  <Action sr="act4" ve="7">
   <code>548</code>
   <on>false</on>
   <Str sr="arg0" ve="3">%SMS3</Str>
   <Int sr="arg1" val="1"/>
   <Str sr="arg10" ve="3"/>
   <Int sr="arg11" val="1"/>
   <Int sr="arg12" val="0"/>
   <Str sr="arg13" ve="3"/>
   <Int sr="arg14" val="0"/>
   <Str sr="arg15" ve="3"/>
   <Int sr="arg2" val="0"/>
   <Str sr="arg3" ve="3"/>
   <Str sr="arg4" ve="3"/>
   <Str sr="arg5" ve="3"/>
   <Str sr="arg6" ve="3"/>
   <Str sr="arg7" ve="3"/>
   <Str sr="arg8" ve="3"/>
   <Int sr="arg9" val="1"/>
  </Action>
  <Action sr="act5" ve="7">
   <code>667</code>
   <Int sr="arg0" val="0"/>
   <Str sr="arg1" ve="3">/data/data/com.android.providers.telephony/databases/mmssms.db</Str>
   <Int sr="arg10" val="1"/>
   <Str sr="arg2" ve="3"/>
   <Str sr="arg3" ve="3"/>
   <Str sr="arg4" ve="3">DELETE FROM sms WHERE [type] = 5 AND _id = %SMS1</Str>
   <Str sr="arg5" ve="3"/>
   <Str sr="arg6" ve="3"/>
   <Str sr="arg7" ve="3"/>
   <Str sr="arg8" ve="3">%XXX</Str>
   <Int sr="arg9" val="0"/>
   <ConditionList sr="if">
    <Condition sr="c0" ve="3">
     <lhs>%SMSES(#)</lhs>
     <op>0</op>
     <rhs>1</rhs>
    </Condition>
   </ConditionList>
  </Action>  
  <Action sr="act6" ve="7">
   <code>667</code>
   <Int sr="arg0" val="0"/>
   <Str sr="arg1" ve="3">/data/data/com.android.providers.telephony/databases/mmssms.db</Str>
   <Int sr="arg10" val="1"/>
   <Str sr="arg2" ve="3"/>
   <Str sr="arg3" ve="3"/>
   <Str sr="arg4" ve="3">UPDATE sms SET [type] = 2 WHERE [type] = 5 AND _id = %SMS1</Str>
   <Str sr="arg5" ve="3"/>
   <Str sr="arg6" ve="3"/>
   <Str sr="arg7" ve="3"/>
   <Str sr="arg8" ve="3">%XXX</Str>
   <Int sr="arg9" val="0"/>
   <ConditionList sr="if">
    <Condition sr="c0" ve="3">
     <lhs>%SMSES(#)</lhs>
     <op>0</op>
     <rhs>1</rhs>
    </Condition>
   </ConditionList>
  </Action>
  <Action sr="act7" ve="7">
   <code>41</code>
   <Str sr="arg0" ve="3">%SMS2</Str>
   <Str sr="arg1" ve="3">%SMS3</Str>
   <Int sr="arg2" val="0"/>
   <Str sr="arg3" ve="3"/>
   <Int sr="arg4" val="0"/>
   <ConditionList sr="if">
    <Condition sr="c0" ve="3">
     <lhs>%SMSES(#)</lhs>
     <op>0</op>
     <rhs>1</rhs>
    </Condition>
   </ConditionList>
  </Action>
 </Task>
</TaskerData>
© www.soinside.com 2019 - 2024. All rights reserved.