So, if i want to really create(or modify the current library) where should i start?
With an explicit statement of, and justification for, the requirements.
Think about this, though. The doorbell rings. You (the callback) need to answer the door. What do you need to know this time (the argument) that is different from last time?
If that information is known when the code is compiled, so that you can supply it to the callback declaration function, why can't the information simply be declared in the callback function?