sysfs read
またはsysfs write
のUIボタンの読み取り/書き込み機能を備えたAndroidアプリケーションを作成したいと思います。sysfsの読み書きを行うためのAndroidアプリケーションの作成方法
次の例のコードはjava.io.RandomAccessFileです。
package com.tutorialspoint;
import java.io.*;
public class RandomAccessFileDemo {
public static void main(String[] args) {
try {
// create a new RandomAccessFile with filename test
RandomAccessFile raf = new RandomAccessFile("c:/test.txt", "rw");
// write something in the file
raf.writeUTF("Hello World");
// set the file pointer at 0 position
raf.seek(0);
// read the first byte and print it
System.out.println("" + raf.read());
// set the file pointer at 4rth position
raf.seek(4);
// read the first byte and print it
System.out.println("" + raf.read());
} catch (IOException ex) {
ex.printStackTrace();
}
}
}
誰かがAndroid SDKを使用してこのコードを作成する方法を教えてください。
何が問題になりますか? Androidアプリを書くには?ボタンを作成しますか?ファイルの読み書き –
私は、linuxドライバのプログラミングに慣れています。 sysfsをuserspaceにエクスポートしました。私はユーザー空間のアンドロイドアプリケーションにアクセスしたかったのです。私はアンドロイドアプリケーションの世界に新しいです。私はアンドロイドアプリケーションを書く上で一般化されたリンクから始めたくない。 – kzs
このアプリケーションではどこから始めるべきかを指摘しておいてください。 – kzs