
10_日积月累
文章平均质量分 55
jackie_gnu
这个作者很懒,什么都没留下…
展开
-
12 Bash For Loop Examples for Your Linux Shell Scripting
There are two types of bash for loops available. One using the “in” keyword with list of values, another using the C programming like syntax转载 2011-07-11 16:38:22 · 1630 阅读 · 0 评论 -
Service and Binder(2)
Aidl生成的接口文件: IRemoteService.java/* * This file is auto-generated. DO NOT MODIFY. * Original file: C:\\Documents and Settings\\qujia原创 2011-09-20 17:45:01 · 635 阅读 · 0 评论 -
Service and Binder(1)
Aidl定义:IRemoteService.aidlpackage com.bst.test;import com.bst.test.IRemoteServiceCallback;/** * Example of defining an interface原创 2011-09-20 17:40:30 · 372 阅读 · 0 评论 -
Service and Binder (4)
AndroidManifest.xml原创 2011-09-20 18:08:09 · 286 阅读 · 0 评论 -
Message,MessageQueue,Looper,Handler详解
from:http://hi.baidu.com/%CE%DE%D0%C4%B1%B1%BE%A9/blog/item/82897fae220a7ad67dd92ad7.html 一、几个关键概念1、MessageQueue:是一种数据结构,见名知义,就是一个消息队列转载 2011-09-21 16:16:56 · 443 阅读 · 0 评论 -
加快Android编译速度
## Include all of the makefiles in the system## Can't use first-makefiles-under here because# --mindepth=2 makes the prunes not work原创 2011-08-27 18:53:01 · 1211 阅读 · 0 评论 -
Android make脚本简记
http://quanminchaoren.iteye.com/blog/840918内容提要文档简要整理Android的make脚本的内容。以供备忘和参考。 1. Build LayersBuild Layers描述的是产品的硬件配置情况,据此m转载 2011-08-27 18:06:50 · 488 阅读 · 0 评论 -
Android 的View不是线程安全的.
当在UI 线程之外更新view组件时会出现exception. E/AndroidRuntime( 4371): FATAL EXCEPTION: Thread-10E/AndroidRuntime( 4371): android.view.ViewRoot$Cal原创 2011-09-23 15:08:58 · 903 阅读 · 0 评论 -
批处理LOG_NDEBUG
查找LOG_NDEBUG find . -name "*.cpp" -exec sed -n -e '/LOG_NDEBUG/p' {} \; 查找//#define LOG_NDEBUGfind . -name "*.cpp" -exec sed -n -e '/^\/\/#define LOG_NDEBUG/p' {} \; 去掉注释 // #define LOG_ND原创 2011-11-16 09:17:12 · 918 阅读 · 0 评论 -
Linux正则表达式技术指南
作为一个Linux管理员,您需要对文本文件进行处理。您可以使用不同的工具如grep、awk以及sed去查找包含特定文本串的文件。这里,我将介绍一种使用正则表达式,以灵活的方式,去搜索文件中的文本的方法。 让我们考虑一个正则表达式发挥作用的例子。比如,当你尝试使用命令grep –r host /时,其返回的结果会很庞大。因为每一个包含host这个文本串的字(像ghostscript这样的字转载 2011-11-16 09:17:47 · 442 阅读 · 0 评论 -
RGB2YUV
#define RGB2YUV_SHIFT 16#define BY ((int)( 0.098*(1<<RGB2YUV_SHIFT)+0.5))#define BV ((int)(-0.071*(1<<RGB2YUV_SHIFT)+0.5))#define BU ((int)( 0.439*(1<<RGB2YUV_SHIFT)+0.5))#define GY ((int)( 0.转载 2011-11-23 21:37:38 · 1240 阅读 · 0 评论 -
jpg压缩步骤
由于JPEG的无损压缩方式并不比其他的压缩方法更优秀,因此我们着重来看它的有损压缩。以一幅24位彩色图像为例,JPEG的压缩步骤分为: 1.颜色转换 由于JPEG只支持YUV颜色模式的数据结构,而不支持RGB图像数据结构,所以在将彩色图像进行压缩之前,必须先对颜色模式进行数据转换。各个值的转换可以通过下面的转换公式计算得出: Y=0.299R+0转载 2011-11-23 21:53:52 · 1122 阅读 · 1 评论 -
查看gcc搜索路径
gcc -print-search-dirs原创 2011-11-24 15:13:55 · 1756 阅读 · 0 评论 -
android I/DEBUG堆栈信息
堆栈错误信息:I/DEBUG ( 30): r0 afd4d4a4 r1 ffffffff r2 7fffffff r3 afd4d4a4I/DEBUG ( 30): r4 00000000 r5 ffffffff r6 00000001 r7 be9f6cccI/DEBUG ( 30): r8 00000000 r9 00000000 10 000转载 2011-11-07 17:19:10 · 483 阅读 · 0 评论 -
推荐10个Android开源项目
1.Android团队提供的示例项目 如果不是从学习Android SDK中提供的那些样例代码开始,可能没有更好的方法来掌握在Android这个框架上开发。由Android的核心开发团队提供了15个优秀的示例项 目,包含了游戏、图像处理、时间显示、开始菜单快捷方式等。地址:http://code.google.com/p/apps-for-android/2.Remote转载 2011-11-07 22:07:36 · 429 阅读 · 0 评论 -
去掉文件中LF(dos->unix)
#!/bin/shwhich sed || (echo "sed unavailable" 1>&2; exit 1)echo "Creating obj directories..."test -d lencod/obj && rm -rf lencod/obj ; mkdir lencod/objtest -d ldecod/obj && rm -rf ldecod/obj ;原创 2011-11-29 16:41:40 · 1080 阅读 · 0 评论 -
How to tacktrace In Android for Java code
When I debug android app, if I work with Java, I can use Log.d(“TAG”,“xxxx”, new Throwable()) to print backtrace of Java code. This isreally handy for me to find bugs.原创 2011-12-02 22:26:45 · 683 阅读 · 0 评论 -
Service and Binder(3)
使用RemoteService. 在RemoteService 中调用RemoteServiceCallback. /** * This is a list of callbacks that have been registered with the原创 2011-09-20 18:01:39 · 393 阅读 · 0 评论 -
Aidl生成的ICalc接口文件
/* * This file is auto-generated. DO NOT MODIFY. * Original file: C:\\Documents and Settings\\userName\\RemoteService\\src\\com\\bst\\t原创 2011-09-20 09:17:14 · 452 阅读 · 0 评论 -
Java培训笔记
1. instal CVSmyEclipse 8.6 netstat -an | grep port_numlsof -i :prot_numcat /etc/service, 所有端口号及用途. ArrayList 泛型设计原创 2011-08-19 08:42:25 · 372 阅读 · 0 评论 -
Help Needed in compilation when TARGET_BUILD_VARIANT is set as "user".
have downloaded the code from http://source.android.com/ andtry to compile the TARGET_BUILD_VARIANT as user.I got the following error. It se原创 2011-07-11 15:45:55 · 777 阅读 · 0 评论 -
Talking about Android Initialization Process
[First written by Steve Guo, please keep the mark if forwarding.]init is the first process after kernel started. The corresponding source co转载 2011-07-20 22:24:56 · 564 阅读 · 0 评论 -
StevGuo系列文章翻译之Android系统属性
StevGuo系列文章翻译之Android系统属性 每一个属性都是一个名值对,名和值都是文本。Android系统中,属性被大量使用,用来记录系统设置或者在进程间交换信息。属性在整个系统中是可见的,每一个进程都可以get/set属性。系统初始化时,在init这个daemon中,A转载 2011-07-21 09:03:29 · 521 阅读 · 0 评论 -
15 Practical Grep Command Examples In Linux / UNIX
You should get a grip on the Linux grep command. This is part of the on-going 15 Examples series, where 15 detailed examples will be provide转载 2011-07-26 14:51:17 · 682 阅读 · 0 评论 -
Mommy, I found it! — 15 Practical Linux Find Command Examples
原文地址:http://www.thegeekstuff.com/2009/03/15-practical-linux-find-command-examples/Apart from the basic operation of looking for files under转载 2011-07-26 15:52:51 · 661 阅读 · 0 评论 -
SSH 自动远程登陆
1. 在client端使用ssh-keygen生成, public & private key$ ssh-keygenEnter passphrase (empty for no passphrase):Enter same passphrase again:Note:原创 2011-07-27 08:59:33 · 536 阅读 · 0 评论 -
Unix Sed Tutorial: Delete File Lines Using Address and Patterns
Unix Sed Tutorial: Delete File Lines Using Address and PatternsIn this article, let us review how to delete lines from a file using address转载 2011-07-27 08:39:15 · 637 阅读 · 0 评论 -
Sed Tips and Tricks
Sed Tips and Tricks basical Unix Sed Tutorial: Delete File Lines Using Address and PatternsUnix Sed Tutorial: Printing File Lines using Addr原创 2011-07-27 08:45:36 · 507 阅读 · 0 评论 -
解压三星.rfs文件
copy from:http://www.hiapk.com/thread-543835-1-1.html你的环境是linux,且安装了ruby2、运行ruby stage1.rb,在本目录下会生成stage1文件,此生成过程比较长,因为ruby的效率实在太差(到时候改成C实现应转载 2011-07-18 20:25:58 · 2464 阅读 · 1 评论 -
Unix Sed Tutorial: Printing File Lines using Address and Patterns
Unix Sed Tutorial: Printing File Lines using Address and PatternsUnix Sed Introductionsed is a “non-interactive” stream-oriented editor. Sin转载 2011-07-27 08:36:31 · 749 阅读 · 0 评论 -
adb shell am broadcast
使用am发启广播adb shell am broadcast -a android.provider.Telephony.SECRET_CODE -d android_secret_code://28346 广播端: import stati原创 2011-07-14 10:39:11 · 5997 阅读 · 2 评论 -
Android电源管理
copy from: StevGuo系列文章翻译之Android电源管理 上图展示了Android电源管理的整体设计框架。Android实现了一个非常简单的电源管理机制,目前,它只支持screen on/off,screen backlight on/off,keyboard b转载 2011-07-21 16:27:21 · 1401 阅读 · 0 评论 -
动态库so打包到android apk
编译libjnisimple.so Android/development/samples/SimpleJNI/jni/Android.mk# This makefile supplies the rules for building a library of JNI code原创 2011-07-21 11:30:24 · 2947 阅读 · 0 评论 -
Awk Tutorial Examples
Awk Tutorial Examples原创 2011-08-04 10:30:14 · 663 阅读 · 0 评论 -
Fragment demo
left fragment:package com.easymorse.demos;import android.os.Bundle;import android.support.v4.app.Fragment;import android.view.Layo转载 2011-08-11 08:20:56 · 2158 阅读 · 2 评论 -
android.widget.PopupWindow,生成Dialog
public static void showPopupWindow(Context context, View parent) { LayoutInflater inflater = (LayoutInflater) context .getSystemServ原创 2011-08-12 17:25:10 · 871 阅读 · 0 评论 -
为Android Sdk 关联reference文档
1. Select a JAR or Java project, open the context menu and select Properties > Javadoc Location 2. 加入:file:/D:/Android/Android_3.0/And原创 2011-09-15 11:28:08 · 612 阅读 · 0 评论 -
一句话
sed pattern 替换并备份文件. 1).$sed -i.bak "s/src/dest/" inputfile.txt 2). 把所有cpp文件中的"//#define LOG_NDEBUG 0"去掉"//" find . -name "*.cpp" -exec sed -i "s|//#define LOG_NDEBUG 0|#原创 2011-07-29 19:02:22 · 400 阅读 · 0 评论