Design Techniques for Log Based Closed-Loop Neurostimulation System-On-Chip.