I would love it if there was some way that all library writers could easily inherit predefined baseclasses when implementing a library for something.
This way we would ensure a intuitive, consistent and clean API for the end user.
There has already been talk about a baseclass for streams/serial objects.
Why not define an API for things like Motors, Temperature Sensors, Range Sensors, things that needs to be polled [like
update() or such], things that can be
off(), thigs that has a
begin() [init() start() construct() setup()] and an
end() [stop() destruct() cleanup()] etc etc ?
I have many ideas on this subject, and I have a lot of interface suggestions ready. I’d love a discussion on the matter.