Implantable, flexible, wireless chip for in vivo recording and stimulation of the brain