I'm trying to do something pretty basic: I'd like the NetCon source to be a variable from a distributed mechanism in the presynaptic cell rather than its voltage, as is usually the case. Python doesnt pass references around, and HOC appears to complain about the variable not being a reference. Here is what I'm seeing.
Code: Select all
>>> pre = h.Section() >>> pre.L = 10 >>> pre.diam = 10 >>> pre.insert('IAF') #Inserting distributed mechanism here <nrn.Section object at 0x7faae24375a8> >>> post = h.Section() >>> post.L = 10 >>> post.diam = 10 >>> post.insert('IAF') <nrn.Section object at 0x7faae2437760> >>> ss = h.Syn(post(0.5)) #Custom synapse (point process) >>> nc = h.NetCon(pre.spike_IAF,ss) bad stack access: expecting (double *); really (double) NEURON: interpreter stack type error near line 0 objref hoc_obj_ ^ NetCon(0, ...) Traceback (most recent call last): File "<stdin>", line 1, in <module> RuntimeError: hoc error