create soma1
access soma1

L = 20
diam = 20

v_init = -60
tstop = 3000
celsius = 23
forall Ra = 70

insert na1_gp
	gbar_na1_gp = 0.7
insert na6_gp
	gbar_na6_gp = 0.2

objref sc

sc = new SEClamp(0.5)
sc.dur1 = 3000


// *** Voltage Plot Panel ***

objref VoltagePlot
	VoltagePlot = new Graph(0)
	VoltagePlot.size(0,3000,-80,40)
	VoltagePlot.view(0,-80,3000,120,650,300,400,200)
	graphList[0].append(VoltagePlot)
	VoltagePlot.save_name("graphList[0].")
	VoltagePlot.addexpr("soma1.v",1,1,0.8,0.9,2)


// *** Availability Plot Panel ***

objref AvailabilityPlot
	AvailabilityPlot = new Graph(0)
	AvailabilityPlot.size(0,3000,0,1)
	AvailabilityPlot.view(0,0,3000,1,650,650,400,200)
	graphList[0].append(AvailabilityPlot)
	AvailabilityPlot.save_name("graphList[0].")
	AvailabilityPlot.addexpr("avail_na1_gp",2,1,0.8,0.9,2)
	AvailabilityPlot.addexpr("avail_na6_gp",3,1,0.8,0.9,2)


// *** Run Panel ***

		t = 0
		dt = 0.1
		realtime = 0

objref RunPanel
RunPanel = new HBox()
RunPanel.intercept(1)
	xpanel("")
		xbutton("Init & Run","run()")
		xbutton("Stop","stoprun=1")
		xlabel("")
		xlabel("DBS-like current pulse train")
		xlabel("Uses 'VectorPlay' to create train")
	xpanel()
	xpanel("")
		xvalue("t","t", 2 )
		xvalue("Real Time","realtime", 0,"", 0, 1 )
	xpanel()
RunPanel.intercept(0)
RunPanel.map("Run Panel",0,300,350,150)

load_file("vplay.ses")