摘要:
KERNELDIR =/home/wenhao/platform/linux-2.6.34PWD := $(shell pwd)CROSS_COMPILE = /usr/local/arm/4.3.2/bin/arm-linux-CC = $(CROSS_COMPILE)gccobj-m := ke... 阅读全文
摘要:
/*************************************************Function: hexStringtoByteArray()Description: 十六进制字串转化为十六进制编码Calls: formatString()Called By:Input: he... 阅读全文
摘要:
#include "stdio.h"void set(int *ch,int a,int *c,int *d){ c[0]=12; c[1]=133; c[2]=14; ch[0]=ch[0]+1; ch[2]=ch[2]+1; ch[1]=ch[1]+1;*d=10;}void main(){ ... 阅读全文
摘要:
/*************************************************Function: formatString()Description: 将十六进制字串每字节中间加空格分隔Calls:Called By:hexStringtoByteArray()Input: o... 阅读全文
摘要:
typedef unsigned char UCHAR;typedef unsigned char BOOL;/* 计算cnt字节数据的crc,最后一个字节的低7比特必须是0,实际上求的是(cnt×8-1)比特数据的crc */UCHAR CRC7_Cal(UCHAR *pSrc, UINT32 c... 阅读全文
摘要:
使用头文件#include #include "QTimer"#include "QTime"#include "QMessageBox"#include #include #include #include #include "stdio.h"#include "stdlib.h"#include... 阅读全文
摘要:
QString str = QString("%1").arg(outChar&0xFF,2,16,QLatin1Char('0'));int a=0001;QString str = QString("%1").arg(a,4,10,QLatin1Char('0')); 阅读全文
摘要:
#include "stdio.h"/*int* set(int a,int *c){int *b;b=malloc(sizeof(int)*3);c[0]=a;c[1]=1+a;c[2]=2+a;b[0]=13;b[1]=14;b[2]=15;return b;}*/char *set(void)... 阅读全文
摘要:
jni.c中注册中int register_android_boa(JNIEnv *env){ jclass clazz; static const char* const kClassName = "com/lxl/ledClass"; //命名的类 /* look up the class */... 阅读全文
摘要:
一、编写JNI模块当安装好NDK编译环境后,会在它的目录下找到sample目录,它里面有一些例子,可以参考这些例子来写我们自已的模块。1、在/home/android/文件夹下,新建“ledjni”文件夹。2、/ledjni/jni/目录下,新建“led-jni.c”led-jni.c文件[html... 阅读全文