[SOLVED] Embedding CMD window into Qt GUI (PyQt5)

salm2s

Honorable
Jul 21, 2017
266
6
10,815
Hi there,
So i have been recently developing a gui miner for a cryptocurrency. I have made it so that when the user inputs all the required info, the miner application starts.
However, i wanted to know how i could implement the cmd window into the gui, like a little widget inside of the gui.

Thanks,
salm2s
 
Solution
@salm2s,

Software development is not just blind copy/paste from Stackoverflow. You have to read the documentation for your "miner", and see what you can get from your TCP / UDP connection to that 4048 port. If you can "telnet 127.0.0.1 4048", and obtain whatever you need with some command string, then you can replicate that in your "GUI". I am not (and I suppose, @null_dev neither) going to install any app just to see how it works and to explain it to you.
However, i wanted to know how i could implement the cmd window into the gui, like a little widget inside of the gui.
I'm still not sure, and I think you got some terms wrong. If you like to just show text input and output of a program, so there is no need to have such embedded CMD, a simple text area could help you about this.

You have to pipeline with target app, to send and receive text over STDOUT and STDIN.

Read about process pipe-lining, threading, and IO. You need all of them in your parent app.
 
I'm still not sure, and I think you got some terms wrong. If you like to just show text input and output of a program, so there is no need to have such embedded CMD, a simple text area could help you about this.

You have to pipeline with target app, to send and receive text over STDOUT and STDIN.

Read about process pipe-lining, threading, and IO. You need all of them in your parent app.
Ok then don't worry about it. If that is not possible, is there a way to get the hashrate of the miner and show is on the gui?
 
Ok then don't worry about it. If that is not possible
It's actually possible, the way you are trying to do is not stable and legit.

is there a way to get the hashrate of the miner and show is on the gui?
Depends, check if the target app/device has an API for that or not? or simple maybe a terminal app(as what you are trying to figure out)

Have some study over subjects I mentioned, then you will make it very easy
 
It's actually possible, the way you are trying to do is not stable and legit.


Depends, check if the target app/device has an API for that or not? or simple maybe a terminal app(as what you are trying to figure out)

Have some study over subjects I mentioned, then you will make it very easy
It is not necessarily a terminal app. Remember my issue i had the last time, with the command prompt? I fixed it by just putting the cpuminer into a folder with the miner and ran in the code, so the gui and the cmd works. I also think there is a way to bind the miner to an API. If i bind to an api, how can i get the hashrate
 
It is not necessarily a terminal app. Remember my issue i had the last time, with the command prompt? I fixed it by just putting the cpuminer into a folder with the miner and ran in the code, so the gui and the cmd works. I also think there is a way to bind the miner to an API. If i bind to an api, how can i get the hashrate
Hey so i still did not get any response. I binded the miner to 127.0.0.1:4048. What can i do next to get the hashrate?
 
@salm2s,

Software development is not just blind copy/paste from Stackoverflow. You have to read the documentation for your "miner", and see what you can get from your TCP / UDP connection to that 4048 port. If you can "telnet 127.0.0.1 4048", and obtain whatever you need with some command string, then you can replicate that in your "GUI". I am not (and I suppose, @null_dev neither) going to install any app just to see how it works and to explain it to you.
 
Solution
@salm2s,

Software development is not just blind copy/paste from Stackoverflow. You have to read the documentation for your "miner", and see what you can get from your TCP / UDP connection to that 4048 port. If you can "telnet 127.0.0.1 4048", and obtain whatever you need with some command string, then you can replicate that in your "GUI". I am not (and I suppose, @null_dev neither) going to install any app just to see how it works and to explain it to you.
Ok i will see what i can find. Thanks for the help