asic-pinout-drawer
asic-pinout-drawer copied to clipboard
Simple pin assignment generator for IC case
= ASIC Pinout Drawer Dmitry Murzinov [email protected] v1.0, 15.06.2016 :doctype: article :lang: en :stem: :grid: all :align: center :imagesdir: example :homepage: http://idoka.ru
This is simple IC-case drawer with proper pin assignment
NOTE: Russian description available here: http://idoka.ru/php-asic-pinout-generator/
== Intro
Simplifying diagram to explanation tool works:
AsciiDoc --> CSV --> JSON --> SVG --> PNG
table (optional) (optional)
== Dependencies
- bash tool: grep, sed, make
- PHP
==== Optional
- http://www.paratype.com/public/[PT fonts] - that awesome font family include Latin and Cyrillic characters and covers almost all minority languages of the Russian Federation. http://www.paratype.com/uni/public/PTSans.zip[Direct link to download PT Sans] that preffer use to SVG generate
- ImageMagick (for png generate)
- https://atom.io/[Atom] with https://atom.io/packages/asciidoc-preview[asciidoc-preview] plugin for comfortable creation and live-preview of asciidoc tables
== Features
== Usage
. Customize the IC case geometry by defining proper parameters ()
. Prepare table with IC pins definitions
. Run make
The first stage of conversion make json-container of pin description and might be useful for any custom purposes (input format for other tools).
In some cases you need to customize function DecidePinColour() in file DecidePinColour.php.
== Example
Click by link below for reveal step-by-step example of conversion from source doc to finish drawing:
https://github.com/iDoka/asic-pinout-drawer/blob/master/example/pinout.adoc[AsciiDoc table] or https://github.com/iDoka/asic-pinout-drawer/raw/master/example/pinout.adoc[AsciiDoc raw] -> https://github.com/iDoka/asic-pinout-drawer/raw/master/example/pinout.csv[CSV] -> https://github.com/iDoka/asic-pinout-drawer/raw/master/example/pinout.json[JSON] -> https://github.com/iDoka/asic-pinout-drawer/blob/master/example/pinout.svg[SVG] -> https://github.com/iDoka/asic-pinout-drawer/blob/master/example/pinout.png[PNG]
// .Example of result of tool works (SVG) // image::/example/pinout.svg?raw=true[width=50%]
.Example of result of tool works (PNG) image::/example/pinout.png?raw=true[]
CAUTION: Unfortunately Github don't support embed svg-image on README page. Do not yet?...
== ToDo
[options="readonly"]
- [x] Place the Partnumber on the top of chip
- [x] Add legend to output
- [ ] Add local link to every pin name for easy navigate into final doc
- [ ] Read config from JSON- or ini-file (prefferable)
- [ ] Case with BGA-matrix supporting: ** [ ] basic functionality for drawer ** [ ] supporting list of absent pins ** [ ] geometry pin-coding in additional to color coding (see the Xilinx FPGA pinout Documentation as Reference)
- [ ] Obvious idea for PHP-based tools: make this tool available as SaaS (online drawer)
== Useful link that helps me develop that tool
=== ASCIIDOC
- http://www.methods.co.nz/asciidoc/newtables.html[AsciiDoc table syntax]
- http://mrhaki.blogspot.ru/2014/11/awesome-asciidoctor-styling-columns-and.html[Advanced Syntax for Asciidoctor: Styling Cells in Tables]
=== sed
- http://ant0.ru/sed1line.html[one-line sed scripts (RU)]
=== PHP
- http://php.net/manual/ru/function.preg-match.php[Function preg_match]
- http://php.net/manual/ru/function.fgetcsv.php[Function fgetcsv]
- http://php.net/manual/ru/function.json-encode.php[Function json_encode]
- http://php.net/manual/ru/function.json-decode.php[Function json-decode]
- http://stackoverflow.com/questions/9612166/how-do-i-pass-parameters-into-a-php-script-through-a-webpage[How do I pass parameters into a PHP script?]
- http://www.php.su/articles/?cat=vars&page=014[Arrays by example (RU)]
=== SVG
- http://serganbus.github.io/d3tutorials/svg_primer.html[SVG basic usage by Examples (RU)]
- https://www.w3.org/TR/SVG/text.html[Chapter "Text" of SVG W3C Recommendation 16 August 2011 (Second Edition)]
- https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/transform[The SVG transform attribute]
- https://developer.mozilla.org/ru/docs/Web/SVG/Attribute/text-anchor[The SVG text-anchor attribute]
- http://apike.ca/prog_svg_text_style.html[Text in SVG (Font, Anchor, Alignment)]
== Tag cloud
asciidoc, json, verilog, asic, pinout, hdl, svg, csv, automated publishing