Use: python3 QET_TB_maker_v0.21.py
126 2016-08-15 19:17:34
Re: Terminal block generator cross-platform (131 replies, posted in Terminal block generator)
127 2016-08-15 19:06:45
Re: Terminal block generator cross-platform (131 replies, posted in Terminal block generator)
Hi,
From python IDE works for me, but in the terminal raise the same error that you. I've checked and the problem is the version of python.
Try with: python3 QET_TB_maker_v0.2.py.
Galexis, GUI for select projects is a good idea, but I thinks there are 2 problems:
- maybe not everyone have all dependencies
- is slower than press a number. The first time you use a new project make copy/paste and later only you ned to press a number; and if recalculate the last project, with an Enter is enough. Check, and if you consider GUI is bether, I'll do.
Galexis, fails to me on linux:
raul@pb:~/Descargas/a$ python QET_TB_maker_v0.2\ \(1\).py
<< Terminal Block maker for QET 0.2 - by Raul Roda >>
Remember the next conditions:
* Terminal elements must be 'terminal' as type in the Element Editor.
* If terminal elements has more than one textfield, the first one is considered.
* Name of terminals must be in form 'x:a'. x = Terminal Block name; a = Terminal name./home/raul/.qet/elements/temp_tb/
Traceback (most recent call last):
File "QET_TB_maker_v0.2 (1).py", line 369, in <module>
from tkinter.filedialog import *
ImportError: No module named tkinter.filedialog
I post the sample project I used.
128 2016-08-15 08:10:14
Re: Terminal block generator cross-platform (131 replies, posted in Terminal block generator)
Hi, I introduce the version 0.2. Change log:
- Now is not necessary to run with the QET project file path as argument. It can run directly. The program autodetect the path of QET collection dependig the OS, but ask for the path if is not correct. If the past is correct, only a Enter is needed.
- Saves recent proyects used at 'recent.his' file for easy selection of the lastest projects and print on screen. By default, pressing Enter uses the last project, but you can enter a number of the list of type once a new project. I thought to access to the QET database for this purpose, but it implies the install dependencies to python default instalation.
- Creates the collection temp directory for terminal blocks if not exist.
- Now respect case. Be careful, now becasue 'X1' is different than 'x1' and will make 2 different Terminal Blocks.
- The form of then name in collection for the element created is : Project X1(<from_teminal>-<to terminal>). It's easy to select the correct if have a lot.
- Fix XRef calc. The problem was that the grid top and left labels are 25px width. I considered this size to calc XRef.
129 2016-08-13 21:07:49
Re: Terminal block generator cross-platform (131 replies, posted in Terminal block generator)
Thanks !!.
I made a To Do list. When it have enough things to fix, I'll do.
About reserve of terminal: the terminals could have numeric or no numeric label: X1:3, X2:R1, X2:S1,... The program place first no numeric terminals and later numeric terminals. So I don't know if reserve of terminals it's a good idea.
Maybe we can place alphanumeric terminals, and when start the numeric terminals I can make reserve if no consecutive numbers.
Please, you check too terminals with the same name, and test I bridge line is ok.
If you schema have diferent terminal blocks names ( X1:1, X2:4,...) it will create differents terminal blocks for every one.
At the start of the program you can specify whats the max length for a terminal block. If it's longer, generates various elements to put in differents folios.
130 2016-08-13 19:23:43
Re: Terminal block generator cross-platform (131 replies, posted in Terminal block generator)
Hi, edit the QET_TB_maker.py and write the path where are your QET collection in the line started by USER_COLLECTION_PATH. Normaly will be something like "/home/<you user name here>/.qet/elements/<folder where terminals blocks will save>/". Don't forget to write de last / symbol !!
Later at the command line write:
python QET_TB_maker.py <your QET schematic.qet>
You need python 3. When finish, reload the library in QET and appears at the bottom the terminals blocks created.
When you run the program print on screen some usefull info.
This is a first version. Later we autodetect collection qet folder and more details to do it more usefull.
131 2016-08-13 17:05:11
Topic: Terminal block generator cross-platform (131 replies, posted in Terminal block generator)
Hi, I finished a python program to make terminal block based on the previous bash script. I think it works well and fast. I've only tested it on linux, maybe some changes are needed to work in windows.
This version drwa a libe (bridge) between near terminals with same cable numbers.
If someone can test and improve it will be good for QElectroTech users !!
(sorry for my english)
132 2016-08-10 18:12:13
Re: Crasch Qelectrotech (20 replies, posted in EN : Help, suggestions, discussions, ...)
Thanks. I'll try.
Now I am doing a python script to make bornes automatic like the bash script in this forum. It will be easy to use for windows users.
When I finish it, I'll post.
133 2016-08-06 22:34:58
Re: Crasch Qelectrotech (20 replies, posted in EN : Help, suggestions, discussions, ...)
Hi, I have the same ploblem as Calypso: random crashes.
My personal computer uses Xubuntu 16.04 and at work I use windows 7. In both machines are random crashes, but never the project file has been corrupted.
Can I enable some verbose mode and when crashes post the log?
Regards.