• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Python eyeplot.graph函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Python中expeyes.eyeplot.graph函数的典型用法代码示例。如果您正苦于以下问题:Python graph函数的具体用法?Python graph怎么用?Python graph使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了graph函数的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Python代码示例。

示例1: clear

		msg.config(text = s)

def clear():
	global history, trial, running
	if running == True:
		return
	g.delete_lines()
	history = []
	trial = 0

p = eyes.open()
p.loadall_calib()
p.disable_actions()
root = Tk()
Canvas(root, width = WIDTH, height = 5).pack(side=TOP)  # Some space at the top
g = eyeplot.graph(root, width=WIDTH, height=HEIGHT)	# make plot objects using draw.disp
g.setWorld(MINX, MINY, MAXX, MAXY,_('V'),_('mA'))

cf = Frame(root, width = WIDTH, height = 10)
cf.pack(side=TOP,  fill = BOTH, expand = 1)

ZEN = IntVar()
cb0 = Checkbutton(cf,text =_('ZENER'), variable=ZEN, fg = 'black')
cb0.pack(side=LEFT, anchor = SW)
b1 = Button(cf, text = _('START'), command = start)
b1.pack(side = LEFT, anchor = N)
b3 = Button(cf, text = _('SAVE to'), command = save)
b3.pack(side = LEFT, anchor = N)
filename = StringVar()
e1 =Entry(cf, width=15, bg = 'white', textvariable = filename)
filename.set('diode_iv.dat')
开发者ID:ArunJayan,项目名称:expeyes-programs,代码行数:31,代码来源:diode_iv.py


示例2: msg

		self.msg(_('Cleared Data and Trace'))

	def msg(self,s, col = 'blue'):
		msgwin.config(text=s, fg=col)

	def quit(self):
		p.set_state(10,0)
		sys.exit()

p = eyes.open()
p.disable_actions()

root = Tk()
Canvas(root, width = WIDTH, height = 5).pack(side=TOP)  

g = eyeplot.graph(root, width=WIDTH, height=HEIGHT, bip=False)
pt = LM35()

cf = Frame(root, width = WIDTH, height = 10)
cf.pack(side=TOP,  fill = BOTH, expand = 1)

b3 = Label(cf, text = _('Read Every'))
b3.pack(side = LEFT, anchor = SW)
TGAP = StringVar()
Dur =Entry(cf, width=5, bg = 'white', textvariable = TGAP)
TGAP.set('1000')
Dur.pack(side = LEFT, anchor = SW)
b3 = Label(cf, text = _('mS,'))
b3.pack(side = LEFT, anchor = SW)
b3 = Label(cf, text = _('for total'))
b3.pack(side = LEFT, anchor = SW)
开发者ID:fossasia,项目名称:Pocket-Science-Lab,代码行数:31,代码来源:temp-LM35-GUI.py


示例3: _

			Xc = 0.0
		dphi = math.atan( (Xc-Xl)/R)*180./math.pi
		s = _('XC = %5.1f   XL = %5.1f\nDphi = %5.1f degree') %(Xc, Xl, dphi)
		Calc2.config(text = s, fg='blue')
	except:
		Calc2.config(text = _('Wrong Input'), fg='red')

#=============================== main program starts here ===================================
p = eyes.open()
if p == None: sys.exit()

p.set_trigger(2048)
root = Tk()    
f = Frame(root)
f.pack(side=LEFT)
g = eyeplot.graph(f, width=WIDTH, height=HEIGHT)	# make plot objects using draw.disp
g.setWorld(0, -5, 20, 5,_('mS'),_('V'))

f1 = Frame(f)
f1.pack(side=TOP,  fill = BOTH, expand = 1)
Label(f1,text = _('mSec/div')).pack(side=LEFT, anchor = SW)		# Sliders for Adjusting Axes
timebase = Scale(f1,command = set_timebase, orient=HORIZONTAL, length=LPWIDTH, showvalue=False,\
	from_ = 0, to=9, resolution=1)
timebase.pack(side=LEFT, anchor = SW)
timebase.set(3)

Label(f1,text = _('Volt/div')).pack(side=LEFT, anchor = SW)
Vpd = Scale(f1,command = set_vertical, orient=HORIZONTAL, length=LPWIDTH, showvalue=False,\
	from_ = 0, to=3, resolution=1)
Vpd.pack(side=LEFT, anchor = SW)
Vpd.set(1)
开发者ID:abdul,项目名称:expeyes-programs,代码行数:31,代码来源:ac-circuit.py


示例4: range

#-----------------------------main program starts here-----------------------------
for k in range(10):		# Test the hardware availability by by running another program.
	stat,out = commands.getstatusoutput('python '+ eyeplot.abs_path() + 'hwtest.py')
	if stat == 0:
		break

pe = eyes.open()			# Try several times to make a connection
root = Tk()

left = Frame(root)			# Divide root window into Left and Right
left.pack(side=LEFT, anchor = S)
right = Frame(root)
right.pack(side = LEFT, anchor = S, fill = Y),

w=eyePanel(left, pe, WIDTH, HEIGHT)		# Panel photograph to the Left Panel
g = eyeplot.graph(right, WIDTH*1.05, HEIGHT*2./3,color = 'white', labels=False)  # Plot window 
g.setWorld(0,-5*VPERDIV, NP * delay * 0.001, 5*VPERDIV,_('mS'),'V')

cf = Frame(right)						# Command Frame, inside the right frame, below plot window
cf.pack(side=TOP, anchor = NW)
l = Label(cf, text=_('mS/div'))
l.pack(side=LEFT, anchor = SW )
timebase = Scale(cf,command = set_timebase, orient=HORIZONTAL, length=50, showvalue=False,\
	from_ = 0, to=9, resolution=1)
timebase.pack(side=LEFT, anchor = SW)
timebase.set(2)

'''
l = Label(text = 'Volt/div')
vpd = Scale(cf,command = set_vertical, orient=HORIZONTAL, length=50, showvalue=False,\
	from_ = 0, to=2, resolution=1)
开发者ID:raviola,项目名称:expeyes,代码行数:31,代码来源:explore.py


示例5: _

            Xc = 0.0
        dphi = math.atan( (Xc-Xl)/R)*180./math.pi
        s = _('XC = %5.1f   XL = %5.1f\nDphi = %5.1f degree') %(Xc, Xl, dphi)
        Calc2.config(text = s, fg='blue')
    except:
        Calc2.config(text = _('Wrong Input'), fg='red')

#===================== main program starts here ===========================
p = eyes.open()
if p == None: sys.exit()

p.set_trigger(2048)
root = Tk()    
f = Frame(root)
f.pack(side=LEFT)
g = eyeplot.graph(f, width=WIDTH, height=HEIGHT)
# make plot objects using draw.disp
g.setWorld(0, -5, 20, 5,_('mS'),_('V'))

f1 = Frame(f)
f1.pack(side=TOP,  fill = BOTH, expand = 1)
Label(f1,text = _('mSec/div')).pack(side=LEFT, anchor = SW)
# Sliders for Adjusting Axes
timebase = Scale(f1,command = set_timebase, orient=HORIZONTAL,
                 length=LPWIDTH, showvalue=False,
                 from_ = 0, to=9, resolution=1)
timebase.pack(side=LEFT, anchor = SW)
timebase.set(3)

Label(f1,text = _('Volt/div')).pack(side=LEFT, anchor = SW)
Vpd = Scale(f1,command = set_vertical, orient=HORIZONTAL,
开发者ID:ArunJayan,项目名称:expeyes-programs,代码行数:31,代码来源:ac-circuit.py



注:本文中的expeyes.eyeplot.graph函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Python eyeplot.pop_image函数代码示例发布时间:2022-05-24
下一篇:
Python utils.participant函数代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap