Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
gcreate edited this page Jan 29, 2015 · 2 revisions

Batch process

package testcase;

import serialportutil.CommandBatch;

public class SimpleBatch {
    public static void main(String[] args) {
        CommandBatch.addClazz(SimpleCommand.class);
        CommandBatch.addClazz(ConditionCheck.class);
        CommandBatch.go();
    }
}

Output

Start>>class testcase.SimpleCommand
Connecting to COM15 [speed:115200] [databit:8] [stopbit:1] [paritybit:0]
Connected!
ps |grep sh
root      715   2     0      0     bf3ecc88 00000000 D FlashIO
shell     759   1     968    508   c002c9c0 b6f8e378 S /system/bin/sh
root      763   1     940    444   c002c9c0 b6ea1378 S /system/bin/sh
u0_a55    2693  783   337672 20560 ffffffff b6f23494 S push
shell     2956  1     3616   236   ffffffff 000225b8 S xxxxx
root      14156 759   956    484   c002c9c0 b6f46378 S sh
shell@root:/data # Disconnected from COM15
End<<<<class testcase.SimpleCommand

Start>>class testcase.ConditionCheck
Connecting to COM15 [speed:115200] [databit:8] [stopbit:1] [paritybit:0]
Connected!
Has 'ps' command !
Execute 'ps |grep sh' command !
ps |grep sh
root      715   2     0      0     bf3ecc88 00000000 D FlashIO
shell     759   1     968    508   c002c9c0 b6f8e378 S /system/bin/sh
root      763   1     940    444   c002c9c0 b6ea1378 S /system/bin/sh
u0_a55    2693  783   337672 20560 ffffffff b6f23494 S push
shell     2956  1     3616   236   ffffffff 000225b8 S xxxxx
root      14156 759   956    484   c002c9c0 b6f46378 S sh
shell@root:/data # 
Close:class serialportutil.StringOutputStream
Disconnected from COM15
End<<<<class testcase.ConditionCheck

Clone this wiki locally

Morty Proxy This is a proxified and sanitized view of the page, visit original site.