Exemple #1
0
	def __init__(self, parent):
		super(UltimakerCheckupPage, self).__init__(parent, "Ultimaker Checkup")

		self.checkBitmap = toolbarUtil.getBitmapImage('checkmark.png')
		self.crossBitmap = toolbarUtil.getBitmapImage('cross.png')
		self.unknownBitmap = toolbarUtil.getBitmapImage('question.png')
		self.endStopNoneBitmap = toolbarUtil.getBitmapImage('endstop_none.png')
		self.endStopXMinBitmap = toolbarUtil.getBitmapImage('endstop_xmin.png')
		self.endStopXMaxBitmap = toolbarUtil.getBitmapImage('endstop_xmax.png')
		self.endStopYMinBitmap = toolbarUtil.getBitmapImage('endstop_ymin.png')
		self.endStopYMaxBitmap = toolbarUtil.getBitmapImage('endstop_ymax.png')
		self.endStopZMinBitmap = toolbarUtil.getBitmapImage('endstop_zmin.png')
		self.endStopZMaxBitmap = toolbarUtil.getBitmapImage('endstop_zmax.png')

		self.AddText('It is a good idea to do a few sanity checks now on your Ultimaker.\nYou can skip these if you know your machine is functional.')
		b1, b2 = self.AddDualButton('Run checks', 'Skip checks')
		b1.Bind(wx.EVT_BUTTON, self.OnCheckClick)
		b2.Bind(wx.EVT_BUTTON, self.OnSkipClick)
		self.AddSeperator()
		self.commState = self.AddCheckmark('Communication:', self.unknownBitmap)
		self.tempState = self.AddCheckmark('Temperature:', self.unknownBitmap)
		self.stopState = self.AddCheckmark('Endstops:', self.unknownBitmap)
		self.AddSeperator()
		self.infoBox = self.AddInfoBox()
		self.machineState = self.AddText('')
		self.temperatureLabel = self.AddText('')
		self.AddSeperator()
		self.endstopBitmap = self.AddBitmap(self.endStopNoneBitmap)
		self.comm = None
		self.xMinStop = False
		self.xMaxStop = False
		self.yMinStop = False
		self.yMaxStop = False
		self.zMinStop = False
		self.zMaxStop = False
Exemple #2
0
	def __init__(self):
		self._cam = None
		self._overlayImage = toolbarUtil.getBitmapImage("cura-overlay.png")
		self._overlayUltimaker = toolbarUtil.getBitmapImage("ultimaker-overlay.png")
		if cv != None:
			self._cam = highgui.cvCreateCameraCapture(-1)
		elif win32vidcap != None:
			try:
				self._cam = win32vidcap.new_Dev(0, False)
			except:
				pass
		
		self._doTimelaps = False
		self._bitmap = None
Exemple #3
0
    def __init__(self):
        self._cam = None
        self._overlayImage = toolbarUtil.getBitmapImage("cura-overlay.png")
        self._overlayUltimaker = toolbarUtil.getBitmapImage(
            "ultimaker-overlay.png")
        if cv != None:
            self._cam = highgui.cvCreateCameraCapture(-1)
        elif win32vidcap != None:
            try:
                self._cam = win32vidcap.new_Dev(0, False)
            except:
                pass

        self._doTimelaps = False
        self._bitmap = None
Exemple #4
0
    def __init__(self, parent):
        super(InfoBox, self).__init__(parent)
        self.SetBackgroundColour('#FFFF80')

        self.sizer = wx.GridBagSizer(5, 5)
        self.SetSizer(self.sizer)

        self.attentionBitmap = toolbarUtil.getBitmapImage('attention.png')
        self.errorBitmap = toolbarUtil.getBitmapImage('error.png')
        self.readyBitmap = toolbarUtil.getBitmapImage('ready.png')
        self.busyBitmap = [
            toolbarUtil.getBitmapImage('busy-0.png'),
            toolbarUtil.getBitmapImage('busy-1.png'),
            toolbarUtil.getBitmapImage('busy-2.png'),
            toolbarUtil.getBitmapImage('busy-3.png')
        ]

        self.bitmap = wx.StaticBitmap(
            self, -1,
            wx.EmptyBitmapRGBA(24, 24, red=255, green=255, blue=255, alpha=1))
        self.text = wx.StaticText(self, -1, '')
        self.sizer.Add(self.bitmap, pos=(0, 0), flag=wx.ALL, border=5)
        self.sizer.Add(self.text,
                       pos=(0, 1),
                       flag=wx.TOP | wx.BOTTOM | wx.ALIGN_CENTER_VERTICAL,
                       border=5)

        self.busyState = None
        self.timer = wx.Timer(self)
        self.Bind(wx.EVT_TIMER, self.doBusyUpdate, self.timer)
        self.timer.Start(100)
Exemple #5
0
	def __init__(self, parent, commandList, bitmapFilename, size=(20,20)):
		self.bitmap = toolbarUtil.getBitmapImage(bitmapFilename)
		super(PrintCommandButton, self).__init__(parent.directControlPanel, -1, self.bitmap, size=size)

		self.commandList = commandList
		self.parent = parent

		self.SetBezelWidth(1)
		self.SetUseFocusIndicator(False)

		self.Bind(wx.EVT_BUTTON, self.OnClick)
Exemple #6
0
	def __init__(self, parent, commandList, bitmapFilename, size=(20,20)):
		self.bitmap = toolbarUtil.getBitmapImage(bitmapFilename)
		super(PrintCommandButton, self).__init__(parent.directControlPanel, -1, self.bitmap, size=size)

		self.commandList = commandList
		self.parent = parent

		self.SetBezelWidth(1)
		self.SetUseFocusIndicator(False)

		self.Bind(wx.EVT_BUTTON, self.OnClick)
Exemple #7
0
	def __init__(self, parent):
		super(InfoBox, self).__init__(parent)
		self.SetBackgroundColour('#FFFF80')
		
		self.sizer = wx.GridBagSizer(5, 5)
		self.SetSizer(self.sizer)
		
		self.attentionBitmap = toolbarUtil.getBitmapImage('attention.png')
		self.errorBitmap = toolbarUtil.getBitmapImage('error.png')
		self.readyBitmap = toolbarUtil.getBitmapImage('ready.png')
		self.busyBitmap = [toolbarUtil.getBitmapImage('busy-0.png'), toolbarUtil.getBitmapImage('busy-1.png'), toolbarUtil.getBitmapImage('busy-2.png'), toolbarUtil.getBitmapImage('busy-3.png')]
		
		self.bitmap = wx.StaticBitmap(self, -1, wx.EmptyBitmapRGBA(24, 24, red=255, green=255, blue=255, alpha=1))
		self.text = wx.StaticText(self, -1, '')
		self.sizer.Add(self.bitmap, pos=(0,0), flag=wx.ALL, border=5)
		self.sizer.Add(self.text, pos=(0,1), flag=wx.TOP|wx.BOTTOM|wx.ALIGN_CENTER_VERTICAL, border=5)
		
		self.busyState = None
		self.timer = wx.Timer(self)
		self.Bind(wx.EVT_TIMER, self.doBusyUpdate, self.timer)
		self.timer.Start(100)
Exemple #8
0
    def __init__(self, parent):
        super(UltimakerCheckupPage, self).__init__(parent, "Ultimaker Checkup")

        self.checkBitmap = toolbarUtil.getBitmapImage('checkmark.png')
        self.crossBitmap = toolbarUtil.getBitmapImage('cross.png')
        self.unknownBitmap = toolbarUtil.getBitmapImage('question.png')
        self.endStopNoneBitmap = toolbarUtil.getBitmapImage('endstop_none.png')
        self.endStopXMinBitmap = toolbarUtil.getBitmapImage('endstop_xmin.png')
        self.endStopXMaxBitmap = toolbarUtil.getBitmapImage('endstop_xmax.png')
        self.endStopYMinBitmap = toolbarUtil.getBitmapImage('endstop_ymin.png')
        self.endStopYMaxBitmap = toolbarUtil.getBitmapImage('endstop_ymax.png')
        self.endStopZMinBitmap = toolbarUtil.getBitmapImage('endstop_zmin.png')
        self.endStopZMaxBitmap = toolbarUtil.getBitmapImage('endstop_zmax.png')

        self.AddText(
            'It is a good idea to do a few sanity checks now on your Ultimaker.\nYou can skip these if you know your machine is functional.'
        )
        b1, b2 = self.AddDualButton('Run checks', 'Skip checks')
        b1.Bind(wx.EVT_BUTTON, self.OnCheckClick)
        b2.Bind(wx.EVT_BUTTON, self.OnSkipClick)
        self.AddSeperator()
        self.commState = self.AddCheckmark('Communication:',
                                           self.unknownBitmap)
        self.tempState = self.AddCheckmark('Temperature:', self.unknownBitmap)
        self.stopState = self.AddCheckmark('Endstops:', self.unknownBitmap)
        self.AddSeperator()
        self.infoBox = self.AddInfoBox()
        self.machineState = self.AddText('')
        self.temperatureLabel = self.AddText('')
        self.AddSeperator()
        self.endstopBitmap = self.AddBitmap(self.endStopNoneBitmap)
        self.comm = None
        self.xMinStop = False
        self.xMaxStop = False
        self.yMinStop = False
        self.yMaxStop = False
        self.zMinStop = False
        self.zMaxStop = False