I tried to follow Solution 1 and also Solution 2. Unfortunately, I receive the following:
$ adb shell service call isms 5 s16 "1234564789" i32 0 i32 0 s16 "SMS TEXT HERE"
service: unknown option TEXT
Result: Parcel(a Copying message to Icc: Neither user 2000 nor current process has android permission RECEIVE SMS)
$ adb shell service call isms 5 s16 "+1234564789" i32 0 i32 0 s16 "SMS TEXT HERE"
service: unknown option TEXT
Result: Parcel(a Copying message to Icc: Neither user 2000 nor current process has android permission RECEIVE SMS)
$ adb shell service call isms 7 i32 0 s16 "com.android.mms.service" s16 "+1234564789" s16 "null" s16 "keje" s16 "null" s16 0
Result: Parcel(Attempt to get length of null array)
$adb shell service call isms 7 i32 0 s16 "com.android.mms.service" s16 "+1234564789" s16 0 s16 "Hey you !" s16 0 s16 0
Result: Parcel(Attempt to get length of null array)
$adb shell service call isms 5 s16 "com.android.mms" s16 "+1234564789" s16 "+61418706275" s16 "Hey you !" i32 0 i32 0
Result: Parcel(Attempt to get length of null array)
I tried different combinations of the above, but I am unable to understand how others are able to send SMS using the command but I cannot. I'll appreciate if anyone can point out what I am doing wrong.
I am using a linux machine and an android phone with 5.1 connected with USB cable with USB debugging ON.
ro.build.version.release=5.1
TAG=android-5.1.0_r1