I would like to write a simple module which acts as character device driver. The first step was simple: I wrote a standard character driver module... Implementing read write and ioctl over a node. It simulates a 80 char long buffer. I crosscompiled it. I recopiled the original kernel usign LOAD_MODULES capability. Using busybox I created a node under /dev and loaded the module. All was running.
Now I want to embed this module in my local Android source tree... And make it compile with the standard Makefile structure. The aim is to make the module compile during make and to be loaded at startup. Today I updated the sources: libhardware is changed and modules directory seem to be the right destination for my c kernelspace device driver. I noticed that to respect Android HAL, I should use specific structures (there are some comments in overlay.h and sensors.h). Can I create, for example "fake.h" where I define standard calls for my "fake" hardware? After that, I should implement them with a cpp or c module. Am I on the right way? Using cpp, I'm not keeping the kernelspace driver. Another question. How to make them compile only for specific boards? Thank you. --~--~---------~--~----~------------~-------~--~----~ unsubscribe: [email protected] website: http://groups.google.com/group/android-porting -~----------~----~----~----~------~----~------~--~---
