roku device - sets platform
This commit is contained in:
@@ -13,13 +13,15 @@ _roku_device()
|
||||
{
|
||||
if [ "$1" != "" ]; then
|
||||
export ROKU_DEV_TARGET="$1"
|
||||
export ROKU_DEV_PLATFORM="$(_roku.sh device_platform)"
|
||||
fi
|
||||
echo $ROKU_DEV_TARGET
|
||||
echo "device: $ROKU_DEV_TARGET"
|
||||
echo "platform: $ROKU_DEV_PLATFORM"
|
||||
}
|
||||
|
||||
roku()
|
||||
{
|
||||
if [ "$1" = "device" ]; then
|
||||
if [ "$1" = "device" -a "$2" != "info" ]; then
|
||||
shift
|
||||
_roku_device "$@"
|
||||
else
|
||||
|
||||
34
_roku.sh
34
_roku.sh
@@ -30,6 +30,12 @@ __device_cmd()
|
||||
echo "$1; exit" | __netcat
|
||||
}
|
||||
|
||||
_roku_device_platform()
|
||||
{
|
||||
[ -z "$ROKU_DEV_TARGET" ] && echo "ROKU_DEV_TARGET must be defined" && return 0
|
||||
__device_cmd "echo \$ROKU_PLATFORM" | tail -1
|
||||
}
|
||||
|
||||
|
||||
###############################################################################
|
||||
#
|
||||
@@ -83,6 +89,30 @@ _roku_audcap()
|
||||
sox -t raw -r 48000 -b 16 -c 2 -e signed-integer $1.pcm $1.wav
|
||||
}
|
||||
|
||||
###############################################################################
|
||||
#
|
||||
# Debug app
|
||||
#
|
||||
_roku_debug_attach()
|
||||
{
|
||||
PLATFORM=lockhart
|
||||
[ -z "$ROKU_DEV_TARGET" ] && echo "ROKU_DEV_TARGET must be defined" && return 0
|
||||
__device_cmd "/tmp/tools/gdbserver :5555 --attach \$(pgrep Application)"
|
||||
}
|
||||
|
||||
_roku_debug()
|
||||
{
|
||||
PLATFORM=lockhart
|
||||
[ -z "$ROKU_DEV_TARGET" ] && echo "ROKU_DEV_TARGET must be defined" && return 0
|
||||
# __device_cmd "/tmp/tools/gdbserver :5555 --attach \$(pgrep Application)" &
|
||||
# sleep 2
|
||||
gdb-multiarch \
|
||||
-ex "set non-stop off" \
|
||||
-ex "target remote $ROKU_DEBUG_TARGET:5555" \
|
||||
-ex "set solib-absolute-prefix $PWD/port/realtek/stark/$ROKU_DEV_TARGET/dist/rootfs" \
|
||||
-ex "set sysroot $PWD/port/realtek/stark/$ROKU_DEV_TARGET/dist/rootfs"
|
||||
}
|
||||
|
||||
###############################################################################
|
||||
#
|
||||
# Work with channels.
|
||||
@@ -153,9 +183,9 @@ dtail()
|
||||
# Misc
|
||||
#
|
||||
|
||||
_roku_get()
|
||||
_roku_wget()
|
||||
{
|
||||
[ -z "$1" ] && echo "usage: rokuget <url>" && return 0
|
||||
[ -z "$1" ] && echo "usage: roku_wget <url>" && return 0
|
||||
if [ -z "$ROKU_CORP_PASSWORD" ]; then
|
||||
local USER_PASSWORD="--ask-password"
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user