I am a little confused by what should be stored in the header files
for drivers in these two locations and I do not want to further any
existing mistakes:

include/nuttx/<subsystem>/<driver>.h
and
drivers/<subsystem/<driver.h>

To mean it seems it should be organized like this:

drivers/<subsystem/<driver.h>
should be holding internal to the driver interfaces, such register
definitions, low level communication interfaces readreg, writereg,
etc... that might be shared across implementations.

include/nuttx/<subsystem>/<driver>.h
should hold the interfaces/types required to interact with the driver,
registration, initialization, callbacks, etc... that are expected to
be used by the board integration.  As well as things like IOCTL and
types used by userspace.


Currently there are lots of examples of both and it also seems odd to
me that the header used for the internal board interfaces is also used
by user space applications.  So maybe I am very off base here.

--Brennan

Reply via email to