-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from urmil404/urmil
Urmil
- Loading branch information
Showing
13 changed files
with
505 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
from J import Ui_MainWindow | ||
from PyQt5 import QtCore, QtGui, QtWidgets | ||
from PyQt5.QtCore import * | ||
from PyQt5.QtGui import QMovie | ||
from PyQt5.QtGui import * | ||
from PyQt5.QtWidgets import * | ||
from PyQt5.QtCore import Qt, QTimer, QTime, QDate | ||
from PyQt5.uic import loadUi | ||
import sys | ||
import time | ||
from Jarvis_old import JARVIS | ||
from Task import wishMe | ||
from Listen import Suno | ||
from Speak import Bol | ||
|
||
|
||
class MainThread(QThread): | ||
def __init__(self): | ||
super(MainThread, self).__init__() | ||
|
||
# def run(self): | ||
# j = JARVIS() | ||
# j.PROCESS_() | ||
|
||
|
||
startExe = MainThread() | ||
|
||
|
||
class GUI_MOVIE(QMainWindow): | ||
def __init__(self): | ||
super().__init__() | ||
self.gui = Ui_MainWindow() | ||
self.gui.setupUi(self) | ||
|
||
# self.gui.btn_start.clicked(self.startTask) | ||
self.gui.btn_start.clicked.connect(self.startTask) | ||
self.gui.btn_stop.clicked.connect(self.close) | ||
|
||
def startTask(self): | ||
self.gui.label1 = QtGui.QMovie("public//initial.gif") | ||
self.gui.gif_1.setMovie(self.gui.label1) | ||
self.gui.label1.start() | ||
|
||
self.gui.label2 = QtGui.QMovie("public//live.gif") | ||
self.gui.gif_2.setMovie(self.gui.label2) | ||
self.gui.label2.start() | ||
|
||
self.gui.label4 = QtGui.QMovie("public//ring.gif") | ||
self.gui.gif_4.setMovie(self.gui.label4) | ||
self.gui.label4.start() | ||
|
||
# wishMe() | ||
|
||
timer = QTimer(self) | ||
timer.timeout.connect(self.showTime) | ||
timer.start(10) | ||
startExe.start() | ||
|
||
while True: | ||
sentence = Suno() | ||
# result = str(sentence) | ||
if sentence == "bye": | ||
exit() | ||
else: | ||
self.gui.txt_final.setText(sentence) | ||
|
||
def showTime(self): | ||
current_time = QTime.currentTime() | ||
current_date = QDate.currentDate() | ||
label_time = current_time.toString("hh:mm:ss") | ||
label_date = current_date.toString(Qt.ISODate) | ||
self.gui.ojb_t1.setText(label_date) | ||
self.gui.obj_t2.setText(label_time) | ||
|
||
|
||
GUIApp = QApplication(sys.argv) | ||
jarvis_GUI = GUI_MOVIE() | ||
jarvis_GUI.show() | ||
exit(GUIApp.exec_()) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.