Skip to content

Commit

Permalink
0.1.31
Browse files Browse the repository at this point in the history
  • Loading branch information
jacometoss committed Jan 2, 2024
1 parent d6e027c commit ff446e5
Show file tree
Hide file tree
Showing 8 changed files with 49 additions and 14 deletions.
2 changes: 2 additions & 0 deletions electricalwiresizes/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,5 @@
from .distributioncu import redbtcu
from .distributional import redbtal
from .changelog import changelog
from .exportcsv import list_to_csv

2 changes: 1 addition & 1 deletion electricalwiresizes/dbcircuit.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def dbcircuit(carga=None,view=None,conductor=None, output=None):
-------------------------------------------------------------
| Los parámetros no son correctos |
| para el módulo dbcircuit(Load,View,Conductor,Output) |
| para el módulo dbcircuit(Load,View,Conductor,Output) |
-------------------------------------------------------------''')
return

Expand Down
2 changes: 1 addition & 1 deletion electricalwiresizes/dbcircuitcd.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ def dbcircuitcd(carga=None,view=None):
if(carga==None or view==None):
t = time.localtime()
print('''
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
ElectricalWireSizes
Expand Down
4 changes: 2 additions & 2 deletions electricalwiresizes/distributional.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ def redbtal(network=None,conductors=None,view=None):
if(network==None or conductors==None or view==None):
t = time.localtime()
print('''
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
ElectricalWireSizes
Expand All @@ -22,7 +22,7 @@ def redbtal(network=None,conductors=None,view=None):
-------------------------------------------------------------
| Los parámetros no son correctos para el módulo |
| redbtal(network,conductors,view) |
| redbtal(network,conductors,view) |
-------------------------------------------------------------''')
return

Expand Down
4 changes: 2 additions & 2 deletions electricalwiresizes/distributioncu.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ def redbtcu(network=None,conductors=None,view=None):
if(network==None or conductors==None or view==None):
t = time.localtime()
print('''
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
ElectricalWireSizes
Expand All @@ -22,7 +22,7 @@ def redbtcu(network=None,conductors=None,view=None):
-------------------------------------------------------------
| Los parámetros no son correctos para el módulo |
| redbtcu(network,conductors,view) |
| redbtcu(network,conductors,view) |
-------------------------------------------------------------''')
return

Expand Down
33 changes: 33 additions & 0 deletions electricalwiresizes/exportcsv.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
import csv, time

def list_to_csv(name=None,data=None):

if((name==None or data==None)):
t = time.localtime()
print('''
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
ElectricalWireSizes
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
─▄▀─▄▀
──▀──▀
█▀▀▀▀▀█▄
█░░░░░█─█
▀▄▄▄▄▄▀▀
-------------------------------------------------------------
| Los parámetros no son correctos |
| para el módulo |
| list_to_csv(name,data) |
------------------------------------------------------------- ''')
return

headers = ['AWG/KCM', '1F/2H', '2F/3H', '3F/3H', '3F/4H', '60 ', '75 ' , '90' , ' %Vd/1F', '%Vd/2F', '%Vd/3F', '%Vd/3F', 'Nc', 'In', '60', '75','90', 'Op', 'ITM' ]
data_with_headers = [headers] + data

with open(name+'.csv', 'w', newline='') as archivo_csv:
escritor = csv.writer(archivo_csv)
escritor.writerows(data_with_headers)
print("Se creo el archivo "+ name +".csv")
2 changes: 1 addition & 1 deletion electricalwiresizes/mbtcu.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ def mbtcu(VF=None,VL=None,In=None,Nc=None,L=None,FA=None,Type=None,Ta=None,Vd=No
if(VF==None or VL==None or In==None or Nc==None or L==None or FA==None or Type==None or Ta==None or Vd==None or S==None or Fp==None or View==None or Fsc==None or To==None or Break==None or Fcond==None):
t = time.localtime()
print('''
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
ElectricalWireSizes
Expand Down
14 changes: 7 additions & 7 deletions electricalwiresizes/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@ def version():
print('''
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
─▄▀─▄▀")
──▀──▀")
█▀▀▀▀▀█▄")
█░░░░░█─█")
▀▄▄▄▄▄▀▀")
─▄▀─▄▀
──▀──▀
█▀▀▀▀▀█▄
█░░░░░█─█
▀▄▄▄▄▄▀▀
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
| Python ElectricalWireSizes, 20/02/2023 |
| Version : 0.1.30 |
| Python ElectricalWireSizes, 01/01/2024 |
| Version : 0.1.31 |
| Autor : Marco Polo Jacome Toss |
| License: GNU Affero General Public License v3 (GPL-3.0) |
| Requires: Python >=3.5 |
Expand Down

0 comments on commit ff446e5

Please sign in to comment.