Coder Social home page Coder Social logo

Comments (11)

burnt-past avatar burnt-past commented on June 11, 2024 1

@zeeblaze , I am in a Windows environment. This is not applicable. If you would have looked at my original post, you would see that I am using the KiCad directory.

from kicad-jlcpcb-bom-plugin.

howardt12345 avatar howardt12345 commented on June 11, 2024

I have the exact same issue. Has this been resolved?

from kicad-jlcpcb-bom-plugin.

burnt-past avatar burnt-past commented on June 11, 2024

No, I have not found a solution.

from kicad-jlcpcb-bom-plugin.

zeeblaze avatar zeeblaze commented on June 11, 2024

I found a solution...open your kicad installation folder by right clicking on the kicad icon and select "open installation folder"...open "scripting" folder... you will see a "plugin" folder in it...open it and copy the files there...simple as that

from kicad-jlcpcb-bom-plugin.

zeeblaze avatar zeeblaze commented on June 11, 2024

Am also a windows user...and it worked for me ....try it..

from kicad-jlcpcb-bom-plugin.

zeeblaze avatar zeeblaze commented on June 11, 2024

Your kicad will be the problem then... because I see the kicad you are using is 5.1.X version...

Well I use the same...but the thing is ..5.1.x uses python 2...so it's the older version of this script that will work for you 🙂

from kicad-jlcpcb-bom-plugin.

burnt-past avatar burnt-past commented on June 11, 2024

That doesn't make sense, I have Python 3 installed and I'm using a higher version than what this plugin has been tested on.

from kicad-jlcpcb-bom-plugin.

matteocordray avatar matteocordray commented on June 11, 2024

Having the same issue...

from kicad-jlcpcb-bom-plugin.

matteocordray avatar matteocordray commented on June 11, 2024

@burnt-past The fix for me was to replace the [1] with a [0] in the code on line 48. Some designators are not in a folder and therefore only have one element

So line 48 should look like this:
out.writerow([c.getValue(),",".join(refs), c.getFootprint().split(":")[0]])

from kicad-jlcpcb-bom-plugin.

CorentinLemaitre avatar CorentinLemaitre commented on June 11, 2024

I am also windows user and manage to use python3 using the command py because python3 was not working for me.
py "C:\Program Files\KiCad\bin\scripting\plugins\bom_csv_jlcpcb.py" "%I" "%O.csv"

I get the same error :

Traceback (most recent call last):
  File "C:\Program Files\KiCad\bin\scripting\plugins\bom_csv_jlcpcb.py", line 48, in <module>
    out.writerow([c.getValue() + " " + c.getDescription(), ",".join(refs), c.getFootprint().split(':')[1],
IndexError: list index out of range

As @matteocordray have done I change the 1 to be 0 in line 48 and it worked !!! 🥳

Now it look like that : (line 48 and 49)

out.writerow([c.getValue() + " " + c.getDescription(), ",".join(refs), c.getFootprint().split(':')[0],
lcsc_pn])

from kicad-jlcpcb-bom-plugin.

burnt-past avatar burnt-past commented on June 11, 2024

That Removes the data that you would want in the BOM. It seems the issue with the footprint name not containing a referenced library.

This will correctly print the values and remove a library name if it exists.

if ':' in c.getFootprint():
   out.writerow([c.getValue(), ",".join(refs), c.getFootprint().split(':')[1],
   lcsc_pn])
else:
   out.writerow([c.getValue(), ",".join(refs), c.getFootprint().split(':')[0],
   lcsc_pn])

from kicad-jlcpcb-bom-plugin.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.