All Projects → cs8425 → Go Adbbot

cs8425 / Go Adbbot

Licence: mit
android bot based on adb and golang

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to Go Adbbot

Divvydroid
Qt/C++ Application to screencast and remote control Android devices
Stars: ✭ 29 (-14.71%)
Mutual labels:  remote-control, adb
Androidscreencast
View and control your android device on PC
Stars: ✭ 571 (+1579.41%)
Mutual labels:  remote-control, adb
Aspia
Remote desktop and file transfer tool.
Stars: ✭ 784 (+2205.88%)
Mutual labels:  remote-control
Botbuilder Dotnet
Welcome to the Bot Framework SDK for .NET repository, which is the home for the libraries and packages that enable developers to build sophisticated bot applications using .NET.
Stars: ✭ 631 (+1755.88%)
Mutual labels:  bot-framework
Awesome Cheatsheets
超级速查表 - 编程语言、框架和开发工具的速查表,单个文件包含一切你需要知道的东西 ⚡
Stars: ✭ 7,930 (+23223.53%)
Mutual labels:  adb
Pythonadvancedhttpreverseshell
Advanced python HTTP reverse shell made for Hacking Competition purpose. I am not responsible of what you do with this tool.
Stars: ✭ 22 (-35.29%)
Mutual labels:  remote-control
Cog
Bringing the power of the command line to chat
Stars: ✭ 910 (+2576.47%)
Mutual labels:  bot-framework
Androidscreenshare
android
Stars: ✭ 883 (+2497.06%)
Mutual labels:  remote-control
Bot Banko
Sample for using Luis with Bot Framework V4 in a simple banking scenario
Stars: ✭ 28 (-17.65%)
Mutual labels:  bot-framework
Phonesploit
Using open Adb ports we can exploit a Andriod Device
Stars: ✭ 854 (+2411.76%)
Mutual labels:  adb
Weblabdeusto
Scalable, web-based and experiment-agnostic remote laboratory management system
Stars: ✭ 26 (-23.53%)
Mutual labels:  remote-control
C4bot
Chat bot that plays Connect Four with you
Stars: ✭ 21 (-38.24%)
Mutual labels:  bot-framework
Skyrat
SkyRAT - Powershell Remote Administration Tool
Stars: ✭ 21 (-38.24%)
Mutual labels:  remote-control
Botframework Sdk
Bot Framework provides the most comprehensive experience for building conversation applications.
Stars: ✭ 6,673 (+19526.47%)
Mutual labels:  bot-framework
Adaptivecards
A new way for developers to exchange card content in a common and consistent way.
Stars: ✭ 950 (+2694.12%)
Mutual labels:  bot-framework
Weiqunkong
微群控, 电脑统一控制多台Android设备
Stars: ✭ 777 (+2185.29%)
Mutual labels:  adb
Neovim Remote
👌 Support for --remote and friends.
Stars: ✭ 935 (+2650%)
Mutual labels:  remote-control
Botframework Solutions
Welcome to the Bot Framework Solutions repository which is the home for a set of templates and solutions to help build advanced conversational experiences using Azure Bot Service and Bot Framework. Microsoft Bot Framework is a comprehensive framework for building enterprise-grade conversational AI experiences.
Stars: ✭ 965 (+2738.24%)
Mutual labels:  bot-framework
Reminder Bot
A clone of the 'Hello Jarvis' Facebook Messenger bot, built with Microsoft Bot Framework and Wit.ai.
Stars: ✭ 34 (+0%)
Mutual labels:  bot-framework
Badusb botnet
👥😈 Infect a pc with badusb and establish a connection through telegram.
Stars: ✭ 32 (-5.88%)
Mutual labels:  remote-control

adbbot

Package adbbot provides basic functions for Android app automate. This package is based on the standard Go package and Android Debug Bridge (adb) execute file.

Code example

package main

import (
	"flag"
	"log"
	"runtime"
	"time"

	"./adbbot"
)

var verbosity = flag.Int("v", 2, "verbosity")
var ADB = flag.String("adb", "adb", "adb exec path")
var DEV = flag.String("dev", "", "select device")

var OnDevice = flag.Bool("od", true, "run on device")

var APP = flag.String("app", "com.android.vending", "app package name")
var TMPL = flag.String("tmpl", "tmpl.png", "app package name")

func main() {

	log.SetFlags(log.Ldate|log.Ltime)
	flag.Parse()
	runtime.GOMAXPROCS(runtime.NumCPU())

	adbbot.Verbosity = *verbosity
	bot := adbbot.NewLocalBot(*DEV, *ADB)

	// run on android by adb user(shell)
	bot.IsOnDevice = *OnDevice

	Vlogln(2, "[adb]", "wait-for-device")
	_, err := bot.Adb("wait-for-device")
	if err != nil {
		Vlogln(1, "adb err", err)
	}

	// press Home key
	bot.KeyHome()

	// start APP
	bot.StartApp(*APP)

	// wait
	time.Sleep(time.Millisecond * 10000)


	// create matching region between Point <100,635> and <9999,9999>
	//reg := bot.NewRectAbs(100, 635, 9999, 9999)

	// or All the screen (slow)
	reg := bot.NewRectAll()

	// create matching template
	tmpl, err := bot.NewTmpl(*TMPL, reg)
	if err != nil {
		Vlogln(2, "load template image err", err)
	} else {

		// try to find target
		// 10 times with 1000ms delay between each search
		x, y, val := bot.FindExistReg(tmpl, 10, 1000)
		if x == -1 && y == -1 {
			Vlogln(2, "template not found", x, y, val)
		} else {
			Vlogln(2, "template found at", x, y, val)
		}

	}

	infoname := time.Now().Format("20060102_150405")
	err = bot.SaveScreen(infoname + ".png")
	if err != nil {
		Vlogln(2, "SaveScreen err", err)
	} else {
		Vlogln(2, "SaveScreen as file ", infoname + ".png")
	}

	// force-stop APP
	bot.KillApp(*APP)

}

func Vlogln(level int, v ...interface{}) {
	if level <= *verbosity {
		log.Println(v...)
	}
}

TODO

  • [ ] more and faster block-matching algorithm
    • [x] Full Search
    • [ ] Three Step Search
    • [ ] New Three Step Search
    • [ ] Four Step Search
    • [ ] Diamond Search
  • [ ] auto resize/scale template image to fit in device resolution

Thanks to:

Imaging : Image Load/Save and parallel process function are modify from here

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].