@iggy:
Brian Wampler has two books that do exactly what you need. The first one explains in great detail all the building blocks of an effect and the second one gives you real world examples while modding real-world pedals.
Since the books are out of print, I understand that Brian has given permissions on FSB (I think) to freely download the copies. Here:
Wampler booksSome good stuff...