3 ms·
Linux kernel source is a good start. Read up on just about everything in thr kernel docs on I2C, SPI, and regsets. Read datasheets, play around with dev boards.
by mondoshawan 6y ago
Linux kernel source is a good start. Read up on just about everything in thr kernel docs on I2C, SPI, and regsets. Read datasheets, play around with dev boards.
There's no manul for it, really -- its close to old school software engineering on old machines. You have to learn the raw memory layouts, interfaces and some level of electronics theory, and wrestle with datasheets in the start.
Once you've figured out how a peripheral does its work, then you start looking at kernel drivers. For Android, drivers are a split thing: you have to write the kernel driver, then write a user space component called the HAL backend. There's a bit more documentation on that in thr AOSP tree, but not a whole lot.
Basically, you have to learn by doing. Find a chip you want to use in Android, and give it a try on a PandaBoard or some other SBC that can run it.
- mbrumlow 6y agoThanks for taking the time to reply. Its good to know that there is no quick path to this and simply need to sit down and understand the code, and play around with real hardware.