SlideShare une entreprise Scribd logo
1  sur  38
Using Open Source Tools
for Document Automation


Neale Morison
May 2012
Who Am I?
           • Various jobs
                  •   Technical writer
                  •   Journalist
                  •   Editor
                  •   Web developer
                  •   Software developer
                  •   Electronic technician

           • Various employers
                  • Startups – hardware and software
                  • IBM, Cisco, Microsoft, Fujitsu…
                  • Today, CSIRO:
                    Commonwealth Scientific and Industrial
                    Research Organisation

CSIRO. Using Open Source Tools for Document Automation       2
What is ASKAP?

• Australian SKA
 Precursor
  • CSIRO radio telescope
       36 antennas in Western
       Australia
   •    World’s fastest survey
       radio telescope
       at 0.7-1.8 GHz
   •    The system will process
       2Tb/s from each antenna
   •    Processed data then                                • What will it do?
       shipped via fibre to a Perth                        • Discover millions of new galaxies
       supercomputer - exascale
                                                           • Investigate dark matter, dark energy
   •    Similar issues to LHC
       (Large Hadron Collider)
  CSIRO. Using Open Source Tools for Document Automation                                   3
What is ASKAP?




CSIRO. Using Open Source Tools for Document Automation   4
Who Are You?
• Technical Writers
• Experience with:
    • Web development
    • Software development
    • Hardware development
    • System administration
    • HTML
    • XML
    • JavaScript
    • Python
 CSIRO. Using Open Source Tools for Document Automation   5
What am I Talking About?
    • Automation
         Any kind of software or system that assists in
        technical communication


    • Open Source Tools
        Broadly defined:
         • Software: with an Open Source License
         • Standards: non-proprietary or open
           e.g. PDF, open since June 2008
         • Languages: Python, JavaScript
           (ECMAscript), HTML, XML,
         • Apps: Apache HTTP server, MySQL


    • Free Tools
        Free (as in beer) apps – e.g. web browsers
CSIRO. Using Open Source Tools for Document Automation    6
Prologue - Fairlight 1985
                                                              • Fairlight CMI
                                                               (Computer Musical Instrument)
                                                               Series III
                                                              • Manual manual
                                                                literally cut and paste
                                                              • Index created automatically
                                                              • Simple algorithm

sample index.txt:                                             sample output:
using code 32                                                 a blog, writing 128
making an index 42                                            an index, making 42
writing a blog 128                                            blog, writing a 128
                                                              code, using 32
                                                              index, making an 42
                                                              making an index 42
                                                              using code 32
                                                              writing a blog 128
     CSIRO. Using Open Source Tools for Document Automation                                    7
CSIRO ASKAP Antenna IDs – Problem

• Two different
 identification systems
   • Manufacturer: CETC54 ID
   • ASKAP pad ID
   • Tests refer to both

• Almost insoluble
   • Which one to use?
   • Why not both?
   • Create a table showing the
       correspondence



  CSIRO. Using Open Source Tools for Document Automation   8
CSIRO ASKAP Antenna IDs

• Requirements
  • Show ID correspondence
  • Sort by either ID
  • Link to test directories
  • Show other useful information
  • Portable – all contained in a
       single small file
   •    Easy to update – antenna data
       keeps changing




  CSIRO. Using Open Source Tools for Document Automation   9
CSIRO ASKAP Antenna IDs - Solution

• Dynamic Document
     • Fixed (static) HTML:
       more maintenance
     • Better to write JavaScript that writes the
       HTML for you
     • You have to maintain only the data:

tableRows = [
{'cetc54':1, 'askap':29,                    'testDir':'ASKAP29_C01', 'FAT':'Y', 'SAT':'Y', 'MRO':'Y',},
{'cetc54':2, 'askap':3,                     'testDir':'ASKAP03_C02', 'FAT':'Y', 'SAT':'Y', 'MRO':'Y',},
…
]


       •   Responds to user requirements
       •   Smaller than static HTML
       •   ASKAP Antenna Table
       •   Filtered ASKAP Antenna Table

CSIRO. Using Open Source Tools for Document Automation                                            10
CSIRO ASKAP Antenna IDs - Solution

• Dynamic Document
     • Fixed (static) HTML:
       more maintenance
     • Better to write JavaScript that writes the
       HTML for you
     • You have to maintain only the data:

tableRows = [
{'cetc54':1, 'askap':29,                    'testDir':'ASKAP29_C01', 'FAT':'Y', 'SAT':'Y', 'MRO':'Y',},
{'cetc54':2, 'askap':3,                     'testDir':'ASKAP03_C02', 'FAT':'Y', 'SAT':'Y', 'MRO':'Y',},
…
]


       •   Responds to user requirements
       •   Smaller than static HTML
       •   ASKAP Antenna Table
       •   Filtered ASKAP Antenna Table

CSIRO. Using Open Source Tools for Document Automation                                            11
Principles of Open Information
           • Open
                Store information in an open format
           • Terse
                Provide only the necessary information
           • DRY
                Don’t Repeat Yourself - Single Source [3]
           • Accessible
                Easy to find, easy to use
           • Free
                As in speech, love, beer – technology, IP
           • Re-usable
           • Maintainable
           • Simple
CSIRO. Using Open Source Tools for Document Automation      12
Cisco Radiata Group

• WiFi on a chip

• Hardware startup exploiting:
  • wireless invention
    by John O’Sullivan and CSIRO radiophysics team
  • analog IC design innovations

• Sold to Cisco in 1999 for unheard of sum
  (around $400 million)




  CSIRO. Using Open Source Tools for Document Automation   13
Cisco Radiata Register Docs – Problem

• Not really a problem – an opportunity

• Developers used a single source register description
   in a Python script:
       • generate XML register description
       • generate Verilog code from which IC is built

• Required – a document generated from XML




CSIRO. Using Open Source Tools for Document Automation   14
Cisco Radiata Register Docs - Solution

• XML can be reformatted using XSLT and XSL/FO
 (Extensible Stylesheet Language / Formatting Objects)


• Processed with Java tools, e.g. Saxon, Xalan

• Various outputs:
   •   HTML
   •   Postscript -> PDF
   •   LaTeX
   •   FrameMaker - MIF


• Result: a 100 page register reference manual
  in seconds
• Register document example
  CSIRO. Using Open Source Tools for Document Automation   15
Cisco Radiata Register Docs - Principles
• Open XML
• Terse          Describes only the registers

• DRY        One XML file stores all information

• Accessible                   one pdf

• Free        common, available technology:
   • Adobe Reader, Web browsers
   • XML / XSLT
   • HTML

• Re-usable                use for next chip

• Maintainable
 change only if XML format changes

• Simple           for the users


  CSIRO. Using Open Source Tools for Document Automation   16
Cisco Radiata Test Data – Problem

• Tests run on chip simulation

• Result: large quantity of numerical data

• Difficult to determine how data fits
 specification

• Provided visualisation facilities do not
 meet requirement




CSIRO. Using Open Source Tools for Document Automation   17
Cisco Radiata Test Data - Solution

• Process the data to
 produce a customised
 visualisation

• Tools used:
   • Perl
   • Lisp-like script
   • Gnuplot

• Many tables, plots,
 in HTML document
• Test data
  visualisation example
  CSIRO. Using Open Source Tools for Document Automation   18
Cisco Radiata Test Data - Principles
• Open          Proprietary, but documented

• Terse          No repeated data

• DRY    Everything generated
 from single set of data

• Accessible
 HTML presentation

• Free
 common, available technology:
   • Web browsers
   • Perl, HTML
   • GnuPlot

• Re-usable               use for next tests

• Maintainable
• Simple           for the users
  CSIRO. Using Open Source Tools for Document Automation   19
VaST XML Reports
• Software models of embedded systems, system-on-chip
  (SoC)

• Used by developers of cell phones, automotive systems,
  handheld devices to model the chips they were designing

• Low-level, cycle-accurate model that ran at speeds
  comparable to the chip, sometimes faster

• Huge savings in time and money – chip developers could
  write the firmware and software for the chip before
  fabrication

• Integrated Development Environment (IDE) ran on
  Windows, now also Linux.

• Acquired by Synopsys in 2010
   CSIRO. Using Open Source Tools for Document Automation   20
VaST XML Reports – Problem

• Models shown as a hierarchy
   obscures connections


• Item details hidden
   multiple clicks, right clicks required

• No way to print full details
   or to view as a whole




CSIRO. Using Open Source Tools for Document Automation
VaST XML Reports - Solution

• Data stored in XML

• XML can be:
   • transformed using XSLT
   • output as HTML in a browser


• With a single button
 click, a full model report
 can be instantly
 generated:
 PMX report example



  CSIRO. Using Open Source Tools for Document Automation
VaST XML Reports – Good News,, Bad News
• Tricky
    to get it to work - XLST

• Co-operation required
    from GUI developers

• You only have to do it once

• Works when you’re not around,
    for the customer’s models


• Maintenance: infrequent
    when model storage format changes


•   Value permanently added
    CSIRO. Using Open Source Tools for Document Automation   23
VaST XML Reports - Principles
• Open           XML

• Terse          Describes only the model

• DRY            One XML file stores all information

• Accessible                   one click

• Free        common, available technology:
   • Web browsers
   • XML / XSLT
   • HTML

• Re-usable
• Maintainable
• Simple    for the users;
 for the developer, not so much


  CSIRO. Using Open Source Tools for Document Automation
CSIRO ASKAP Repositories – Problem

• SharePoint
   • Corporate choice

• Subversion
   • Developer choice


• Other repositories in use

• Don’t want to discourage or confuse

• Don’t want to introduce yet another system

  CSIRO. Using Open Source Tools for Document Automation   25
CSIRO ASKAP Repositories - Solution
• Document Database
  • Python CGI SQL app

  • Scans repositories

  • Can enter manually

  • Captures metadata

  • Single central site

  • Searchable

  • Links to issue tracker

  • ASKAP Document
    Database




  CSIRO. Using Open Source Tools for Document Automation   26
CSIRO ASKAP Repositories - Principles
• Open         SQL

• Terse         normal form db

• DRY       Single SQL db

• Accessible    standard
 web presentation, form fill

• Free
   • Web browsers
   • Python
   • SQL


• Re-usable – other databases use same code
• Maintainable – some issues - complex to scan repositories. Code is documented.
• Simple – for users; but can I pass this on to another maintainer?

  CSIRO. Using Open Source Tools for Document Automation                27
CSIRO ASKAP Document Management – Problem

• Want to track:
                                                                          ?
    • Review                                                      History Tracking

    • Approval                                                ?                      ?
    • History
                                                                              Document
                                                          Repositories
                                                                              Database
• Tie in to repositories
• Tie in to document database                                            ?

• Complex and costly to program into database -
 violates simplicity rule




 CSIRO. Using Open Source Tools for Document Automation                                  28
CSIRO ASKAP Document Management – Solution

• Use issue tracking system
  Redmine, Bugzilla…                                               Redmine Issue &
                                                                   History Tracking
• Perform review and approval in
                                                             URL                      ID
 issue tracker

• Capture history in issue                                 Repositories
                                                                               Document
                                                                               Database
• Link to repositories                                                    ID
  via document URL

• Link from document database via document ID
• Link back to document database via document ID
• Requires procedures, training – document in wiki
  CSIRO. Using Open Source Tools for Document Automation                                   29
CSIRO ADE Diagrams – Problem

• How Engineers
  think:


• Requirements
  • Hierarchy of
    clickable diagrams

  • Links from diagrams
    to sub-diagrams


  • Document for every block in diagram

  • Links from diagrams to documents

  CSIRO. Using Open Source Tools for Document Automation   30
CSIRO ADE Diagrams – Problem

• SVG
 No – IE, XP

• HTML5
 No – IE, XP

• PDF
 Maybe, but
 awkward to add links
 clunky browser display

• Graphviz
 Good range of outputs
 Gets busy quickly: A B C
 Not the style wanted
 Links only in SVG output

   CSIRO. Using Open Source Tools for Document Automation   31
CSIRO ADE Diagrams – Solution A

• Use hierarchy, not diagrams
• Procedure:
  • Go through diagrams and
    manually transfer nodes, links
    to custom data format
  • Use Python to read data and output JSON
  • Use JavaScript to generate a hierarchy map from JSON
  • Add document names, responsibilities, metadata
  • Generate documents using PowerShell, COM objects 
  • ADE Hierarchy
 CSIRO. Using Open Source Tools for Document Automation   32
CSIRO ADE Diagrams – Solution B

• Do the diagrams
 HTML Image Map, JavaScript

• Procedure:
  • Create diagrams as simple graphics – PPT
  • Save as individual images
  • Create image maps – free program
  • JavaScript code transforms simple image
    map
  • JavaScript links to the hierarchy page
  • ADE System Block Diagrams
 CSIRO. Using Open Source Tools for Document Automation   33
CSIRO ADE Diagrams - Principles
• Open   Python, HTML, JavaScript
 Doc creation not open, but free: PowerShell

• Terse         Only data

• DRY       One source

• Accessible                standard web presentation

• Free
   • Web browsers
   • Python
   • JavaScript
   • PowerShell

• Re-usable
• Maintainable
• Simple
  CSIRO. Using Open Source Tools for Document Automation   34
Conclusion
• Coding is there to be learned
   • HTML, XML, JavaScript, C, Java, Perl, Python, SQL, LaTeX …
   • Excellent online resources

• You have to learn something
 – either a proprietary system, or open tools

• Advantages of open tools
   • Skill Transfer
   • Embody general principles
   • Expert and helpful community

• You can solve otherwise intractable problems
• Free
 The only cost is time

  CSIRO. Using Open Source Tools for Document Automation          35
Glossary
•   ASKAP              Australian SKA Pathfinder
•   CGI                Common Gateway Interface
•   DRY                Don’t Repeat Yourself
•   DRY                Don’t Repeat Yourself
•   FAT                Factory Acceptance Test
•   GNU                GNU is Not Unix
•   HTML               HyperText Markup Language
•   ID                 Identifier
•   Recursion          see Recursion
•   SKA                 Square Kilometre Array
•   SAT                Site Acceptance Test
•   SQL                 Structured Query Language
•   SVG                 Scaleable Vector Graphics
•   URL                Uniform Resource Locator
•   XML                eXtensible Markup Language
•   XSLT               eXtensible Stylesheet Language Transformations
•   XSL/FO              eXtensible Stylesheet Language /Formatting Objects

CSIRO. Using Open Source Tools for Document Automation                       36
References
• 1. Open Source Initiative
  http://www.opensource.org
• 2. Fairlight Instruments Web site
  fairlightinstruments.com.au
• 3. DRY – Don’t Repeat Yourself
  The Pragmatic Programmer: From Journeyman to Master
  by Andrew Hunt and David Thomas
  http://pragprog.com/the-pragmatic-programmer
• 4. ASKAP
• http://www.atnf.csiro.au/projects/askap/
• 5. CSIRO
  http://www.csiro.au/
• 6. CSIRO Wireless LAN patent




CSIRO. Using Open Source Tools for Document Automation
CSIRO Astronomy and Space Science
Neale Morison
ASKAP Documentation Manager

Phone: 02 9372 4726
Email: neale.morison@csiro.au
Web: www.csiro.au/org/cass




Thank you
                                                    Contact Us
                       Phone: 1300 363 400 or +61 3 9545 2176
                    Email: enquiries@csiro.au Web: www.csiro.au

Contenu connexe

En vedette

2016 Future of Open Source Study
2016 Future of Open Source Study2016 Future of Open Source Study
2016 Future of Open Source Study
North Bridge
 

En vedette (12)

7 Common Mistakes in Go (2015)
7 Common Mistakes in Go (2015)7 Common Mistakes in Go (2015)
7 Common Mistakes in Go (2015)
 
The Trouble with Open Source Software
The Trouble with Open Source SoftwareThe Trouble with Open Source Software
The Trouble with Open Source Software
 
2014 Future of Open Source Survey Results
2014 Future of Open Source Survey Results2014 Future of Open Source Survey Results
2014 Future of Open Source Survey Results
 
Open Source in the Cloud Computing Era
Open Source in the Cloud Computing EraOpen Source in the Cloud Computing Era
Open Source in the Cloud Computing Era
 
Moving to Open-Source Tools - How to Increase Performance Test Coverage Throu...
Moving to Open-Source Tools - How to Increase Performance Test Coverage Throu...Moving to Open-Source Tools - How to Increase Performance Test Coverage Throu...
Moving to Open-Source Tools - How to Increase Performance Test Coverage Throu...
 
2016 Future of Open Source Study
2016 Future of Open Source Study2016 Future of Open Source Study
2016 Future of Open Source Study
 
Internet-enabled GIS Using Free and Open Source Tools
Internet-enabled GIS Using Free and Open Source ToolsInternet-enabled GIS Using Free and Open Source Tools
Internet-enabled GIS Using Free and Open Source Tools
 
2015 Future of Open Source Survey Results
2015 Future of Open Source Survey Results2015 Future of Open Source Survey Results
2015 Future of Open Source Survey Results
 
OPEN SOURCE SEMINAR PRESENTATION
OPEN SOURCE SEMINAR PRESENTATIONOPEN SOURCE SEMINAR PRESENTATION
OPEN SOURCE SEMINAR PRESENTATION
 
2016 Future of Open Source Survey Results
2016 Future of Open Source Survey Results2016 Future of Open Source Survey Results
2016 Future of Open Source Survey Results
 
Open Source Creativity
Open Source CreativityOpen Source Creativity
Open Source Creativity
 
BUD17-TR01: Philosophy of Open Source
BUD17-TR01: Philosophy of Open SourceBUD17-TR01: Philosophy of Open Source
BUD17-TR01: Philosophy of Open Source
 

Similaire à Open Source Automated Documentation in a Development Environment

ch4-Software is Everywhere
ch4-Software is Everywherech4-Software is Everywhere
ch4-Software is Everywhere
ssuser06ea42
 
Reverse Engineering.pptx
Reverse Engineering.pptxReverse Engineering.pptx
Reverse Engineering.pptx
Sameer Sapra
 
Cincom smalltalk roadmap 2015 draft2
Cincom smalltalk roadmap 2015 draft2Cincom smalltalk roadmap 2015 draft2
Cincom smalltalk roadmap 2015 draft2
ArdenCST
 
NetWork - 15.10.2011 - Applied code generation in .NET
NetWork - 15.10.2011 - Applied code generation in .NET NetWork - 15.10.2011 - Applied code generation in .NET
NetWork - 15.10.2011 - Applied code generation in .NET
Dmytro Mindra
 

Similaire à Open Source Automated Documentation in a Development Environment (20)

ch4-Software is Everywhere
ch4-Software is Everywherech4-Software is Everywhere
ch4-Software is Everywhere
 
Reverse Engineering.pptx
Reverse Engineering.pptxReverse Engineering.pptx
Reverse Engineering.pptx
 
[2011 CodeEngn Conference 05] Deok9 - DBI(Dynamic Binary Instrumentation)를 이용...
[2011 CodeEngn Conference 05] Deok9 - DBI(Dynamic Binary Instrumentation)를 이용...[2011 CodeEngn Conference 05] Deok9 - DBI(Dynamic Binary Instrumentation)를 이용...
[2011 CodeEngn Conference 05] Deok9 - DBI(Dynamic Binary Instrumentation)를 이용...
 
Python Applications
Python ApplicationsPython Applications
Python Applications
 
Advanced Internet of Things firmware engineering with Thingsquare and Contiki...
Advanced Internet of Things firmware engineering with Thingsquare and Contiki...Advanced Internet of Things firmware engineering with Thingsquare and Contiki...
Advanced Internet of Things firmware engineering with Thingsquare and Contiki...
 
Avogadro, Open Chemistry and Semantics
Avogadro, Open Chemistry and SemanticsAvogadro, Open Chemistry and Semantics
Avogadro, Open Chemistry and Semantics
 
embedded-systems-for-beginners
embedded-systems-for-beginnersembedded-systems-for-beginners
embedded-systems-for-beginners
 
AI & Machine Learning Pipelines with Knative
AI & Machine Learning Pipelines with KnativeAI & Machine Learning Pipelines with Knative
AI & Machine Learning Pipelines with Knative
 
Silicon Valley Code Camp 2016 - MongoDB in production
Silicon Valley Code Camp 2016 - MongoDB in productionSilicon Valley Code Camp 2016 - MongoDB in production
Silicon Valley Code Camp 2016 - MongoDB in production
 
Cincom smalltalk roadmap 2015 draft2
Cincom smalltalk roadmap 2015 draft2Cincom smalltalk roadmap 2015 draft2
Cincom smalltalk roadmap 2015 draft2
 
Internet of Things, Mobility & .Net Micro Framework SydMobNet March 2014
Internet of Things, Mobility & .Net Micro Framework SydMobNet March 2014Internet of Things, Mobility & .Net Micro Framework SydMobNet March 2014
Internet of Things, Mobility & .Net Micro Framework SydMobNet March 2014
 
Informix on ARM and informix Timeseries - producing an Internet-of-Things sol...
Informix on ARM and informix Timeseries - producing an Internet-of-Things sol...Informix on ARM and informix Timeseries - producing an Internet-of-Things sol...
Informix on ARM and informix Timeseries - producing an Internet-of-Things sol...
 
NetWork - 15.10.2011 - Applied code generation in .NET
NetWork - 15.10.2011 - Applied code generation in .NET NetWork - 15.10.2011 - Applied code generation in .NET
NetWork - 15.10.2011 - Applied code generation in .NET
 
Defcon 22-wesley-mc grew-instrumenting-point-of-sale-malware
Defcon 22-wesley-mc grew-instrumenting-point-of-sale-malwareDefcon 22-wesley-mc grew-instrumenting-point-of-sale-malware
Defcon 22-wesley-mc grew-instrumenting-point-of-sale-malware
 
Code PaLOUsa Azure IoT Workshop
Code PaLOUsa Azure IoT WorkshopCode PaLOUsa Azure IoT Workshop
Code PaLOUsa Azure IoT Workshop
 
The Python in the Apple
The Python in the AppleThe Python in the Apple
The Python in the Apple
 
Lessons learned while building Omroep.nl
Lessons learned while building Omroep.nlLessons learned while building Omroep.nl
Lessons learned while building Omroep.nl
 
I can haz cake: Benefits of working with MITRE on ATT&CK
I can haz cake: Benefits of working with MITRE on ATT&CKI can haz cake: Benefits of working with MITRE on ATT&CK
I can haz cake: Benefits of working with MITRE on ATT&CK
 
DEF CON 27 - CHRISTOPHER ROBERTS - firmware slap
DEF CON 27 - CHRISTOPHER ROBERTS - firmware slapDEF CON 27 - CHRISTOPHER ROBERTS - firmware slap
DEF CON 27 - CHRISTOPHER ROBERTS - firmware slap
 
Intro to Machine Learning with H2O and AWS
Intro to Machine Learning with H2O and AWSIntro to Machine Learning with H2O and AWS
Intro to Machine Learning with H2O and AWS
 

Dernier

Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
kauryashika82
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
QucHHunhnh
 

Dernier (20)

Food Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-II
Food Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-IIFood Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-II
Food Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-II
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot Graph
 
Role Of Transgenic Animal In Target Validation-1.pptx
Role Of Transgenic Animal In Target Validation-1.pptxRole Of Transgenic Animal In Target Validation-1.pptx
Role Of Transgenic Animal In Target Validation-1.pptx
 
Micro-Scholarship, What it is, How can it help me.pdf
Micro-Scholarship, What it is, How can it help me.pdfMicro-Scholarship, What it is, How can it help me.pdf
Micro-Scholarship, What it is, How can it help me.pdf
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.
 
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
 
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
 
Asian American Pacific Islander Month DDSD 2024.pptx
Asian American Pacific Islander Month DDSD 2024.pptxAsian American Pacific Islander Month DDSD 2024.pptx
Asian American Pacific Islander Month DDSD 2024.pptx
 
PROCESS RECORDING FORMAT.docx
PROCESS      RECORDING        FORMAT.docxPROCESS      RECORDING        FORMAT.docx
PROCESS RECORDING FORMAT.docx
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...
 
Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docx
 
Unit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxUnit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptx
 
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptx
 

Open Source Automated Documentation in a Development Environment

  • 1. Using Open Source Tools for Document Automation Neale Morison May 2012
  • 2. Who Am I? • Various jobs • Technical writer • Journalist • Editor • Web developer • Software developer • Electronic technician • Various employers • Startups – hardware and software • IBM, Cisco, Microsoft, Fujitsu… • Today, CSIRO: Commonwealth Scientific and Industrial Research Organisation CSIRO. Using Open Source Tools for Document Automation 2
  • 3. What is ASKAP? • Australian SKA Precursor • CSIRO radio telescope 36 antennas in Western Australia • World’s fastest survey radio telescope at 0.7-1.8 GHz • The system will process 2Tb/s from each antenna • Processed data then • What will it do? shipped via fibre to a Perth • Discover millions of new galaxies supercomputer - exascale • Investigate dark matter, dark energy • Similar issues to LHC (Large Hadron Collider) CSIRO. Using Open Source Tools for Document Automation 3
  • 4. What is ASKAP? CSIRO. Using Open Source Tools for Document Automation 4
  • 5. Who Are You? • Technical Writers • Experience with: • Web development • Software development • Hardware development • System administration • HTML • XML • JavaScript • Python CSIRO. Using Open Source Tools for Document Automation 5
  • 6. What am I Talking About? • Automation Any kind of software or system that assists in technical communication • Open Source Tools Broadly defined: • Software: with an Open Source License • Standards: non-proprietary or open e.g. PDF, open since June 2008 • Languages: Python, JavaScript (ECMAscript), HTML, XML, • Apps: Apache HTTP server, MySQL • Free Tools Free (as in beer) apps – e.g. web browsers CSIRO. Using Open Source Tools for Document Automation 6
  • 7. Prologue - Fairlight 1985 • Fairlight CMI (Computer Musical Instrument) Series III • Manual manual literally cut and paste • Index created automatically • Simple algorithm sample index.txt: sample output: using code 32 a blog, writing 128 making an index 42 an index, making 42 writing a blog 128 blog, writing a 128 code, using 32 index, making an 42 making an index 42 using code 32 writing a blog 128 CSIRO. Using Open Source Tools for Document Automation 7
  • 8. CSIRO ASKAP Antenna IDs – Problem • Two different identification systems • Manufacturer: CETC54 ID • ASKAP pad ID • Tests refer to both • Almost insoluble • Which one to use? • Why not both? • Create a table showing the correspondence CSIRO. Using Open Source Tools for Document Automation 8
  • 9. CSIRO ASKAP Antenna IDs • Requirements • Show ID correspondence • Sort by either ID • Link to test directories • Show other useful information • Portable – all contained in a single small file • Easy to update – antenna data keeps changing CSIRO. Using Open Source Tools for Document Automation 9
  • 10. CSIRO ASKAP Antenna IDs - Solution • Dynamic Document • Fixed (static) HTML: more maintenance • Better to write JavaScript that writes the HTML for you • You have to maintain only the data: tableRows = [ {'cetc54':1, 'askap':29, 'testDir':'ASKAP29_C01', 'FAT':'Y', 'SAT':'Y', 'MRO':'Y',}, {'cetc54':2, 'askap':3, 'testDir':'ASKAP03_C02', 'FAT':'Y', 'SAT':'Y', 'MRO':'Y',}, … ] • Responds to user requirements • Smaller than static HTML • ASKAP Antenna Table • Filtered ASKAP Antenna Table CSIRO. Using Open Source Tools for Document Automation 10
  • 11. CSIRO ASKAP Antenna IDs - Solution • Dynamic Document • Fixed (static) HTML: more maintenance • Better to write JavaScript that writes the HTML for you • You have to maintain only the data: tableRows = [ {'cetc54':1, 'askap':29, 'testDir':'ASKAP29_C01', 'FAT':'Y', 'SAT':'Y', 'MRO':'Y',}, {'cetc54':2, 'askap':3, 'testDir':'ASKAP03_C02', 'FAT':'Y', 'SAT':'Y', 'MRO':'Y',}, … ] • Responds to user requirements • Smaller than static HTML • ASKAP Antenna Table • Filtered ASKAP Antenna Table CSIRO. Using Open Source Tools for Document Automation 11
  • 12. Principles of Open Information • Open Store information in an open format • Terse Provide only the necessary information • DRY Don’t Repeat Yourself - Single Source [3] • Accessible Easy to find, easy to use • Free As in speech, love, beer – technology, IP • Re-usable • Maintainable • Simple CSIRO. Using Open Source Tools for Document Automation 12
  • 13. Cisco Radiata Group • WiFi on a chip • Hardware startup exploiting: • wireless invention by John O’Sullivan and CSIRO radiophysics team • analog IC design innovations • Sold to Cisco in 1999 for unheard of sum (around $400 million) CSIRO. Using Open Source Tools for Document Automation 13
  • 14. Cisco Radiata Register Docs – Problem • Not really a problem – an opportunity • Developers used a single source register description in a Python script: • generate XML register description • generate Verilog code from which IC is built • Required – a document generated from XML CSIRO. Using Open Source Tools for Document Automation 14
  • 15. Cisco Radiata Register Docs - Solution • XML can be reformatted using XSLT and XSL/FO (Extensible Stylesheet Language / Formatting Objects) • Processed with Java tools, e.g. Saxon, Xalan • Various outputs: • HTML • Postscript -> PDF • LaTeX • FrameMaker - MIF • Result: a 100 page register reference manual in seconds • Register document example CSIRO. Using Open Source Tools for Document Automation 15
  • 16. Cisco Radiata Register Docs - Principles • Open XML • Terse Describes only the registers • DRY One XML file stores all information • Accessible one pdf • Free common, available technology: • Adobe Reader, Web browsers • XML / XSLT • HTML • Re-usable use for next chip • Maintainable change only if XML format changes • Simple for the users CSIRO. Using Open Source Tools for Document Automation 16
  • 17. Cisco Radiata Test Data – Problem • Tests run on chip simulation • Result: large quantity of numerical data • Difficult to determine how data fits specification • Provided visualisation facilities do not meet requirement CSIRO. Using Open Source Tools for Document Automation 17
  • 18. Cisco Radiata Test Data - Solution • Process the data to produce a customised visualisation • Tools used: • Perl • Lisp-like script • Gnuplot • Many tables, plots, in HTML document • Test data visualisation example CSIRO. Using Open Source Tools for Document Automation 18
  • 19. Cisco Radiata Test Data - Principles • Open Proprietary, but documented • Terse No repeated data • DRY Everything generated from single set of data • Accessible HTML presentation • Free common, available technology: • Web browsers • Perl, HTML • GnuPlot • Re-usable use for next tests • Maintainable • Simple for the users CSIRO. Using Open Source Tools for Document Automation 19
  • 20. VaST XML Reports • Software models of embedded systems, system-on-chip (SoC) • Used by developers of cell phones, automotive systems, handheld devices to model the chips they were designing • Low-level, cycle-accurate model that ran at speeds comparable to the chip, sometimes faster • Huge savings in time and money – chip developers could write the firmware and software for the chip before fabrication • Integrated Development Environment (IDE) ran on Windows, now also Linux. • Acquired by Synopsys in 2010 CSIRO. Using Open Source Tools for Document Automation 20
  • 21. VaST XML Reports – Problem • Models shown as a hierarchy obscures connections • Item details hidden multiple clicks, right clicks required • No way to print full details or to view as a whole CSIRO. Using Open Source Tools for Document Automation
  • 22. VaST XML Reports - Solution • Data stored in XML • XML can be: • transformed using XSLT • output as HTML in a browser • With a single button click, a full model report can be instantly generated: PMX report example CSIRO. Using Open Source Tools for Document Automation
  • 23. VaST XML Reports – Good News,, Bad News • Tricky to get it to work - XLST • Co-operation required from GUI developers • You only have to do it once • Works when you’re not around, for the customer’s models • Maintenance: infrequent when model storage format changes • Value permanently added CSIRO. Using Open Source Tools for Document Automation 23
  • 24. VaST XML Reports - Principles • Open XML • Terse Describes only the model • DRY One XML file stores all information • Accessible one click • Free common, available technology: • Web browsers • XML / XSLT • HTML • Re-usable • Maintainable • Simple for the users; for the developer, not so much CSIRO. Using Open Source Tools for Document Automation
  • 25. CSIRO ASKAP Repositories – Problem • SharePoint • Corporate choice • Subversion • Developer choice • Other repositories in use • Don’t want to discourage or confuse • Don’t want to introduce yet another system CSIRO. Using Open Source Tools for Document Automation 25
  • 26. CSIRO ASKAP Repositories - Solution • Document Database • Python CGI SQL app • Scans repositories • Can enter manually • Captures metadata • Single central site • Searchable • Links to issue tracker • ASKAP Document Database CSIRO. Using Open Source Tools for Document Automation 26
  • 27. CSIRO ASKAP Repositories - Principles • Open SQL • Terse normal form db • DRY Single SQL db • Accessible standard web presentation, form fill • Free • Web browsers • Python • SQL • Re-usable – other databases use same code • Maintainable – some issues - complex to scan repositories. Code is documented. • Simple – for users; but can I pass this on to another maintainer? CSIRO. Using Open Source Tools for Document Automation 27
  • 28. CSIRO ASKAP Document Management – Problem • Want to track: ? • Review History Tracking • Approval ? ? • History Document Repositories Database • Tie in to repositories • Tie in to document database ? • Complex and costly to program into database - violates simplicity rule CSIRO. Using Open Source Tools for Document Automation 28
  • 29. CSIRO ASKAP Document Management – Solution • Use issue tracking system Redmine, Bugzilla… Redmine Issue & History Tracking • Perform review and approval in URL ID issue tracker • Capture history in issue Repositories Document Database • Link to repositories ID via document URL • Link from document database via document ID • Link back to document database via document ID • Requires procedures, training – document in wiki CSIRO. Using Open Source Tools for Document Automation 29
  • 30. CSIRO ADE Diagrams – Problem • How Engineers think: • Requirements • Hierarchy of clickable diagrams • Links from diagrams to sub-diagrams • Document for every block in diagram • Links from diagrams to documents CSIRO. Using Open Source Tools for Document Automation 30
  • 31. CSIRO ADE Diagrams – Problem • SVG No – IE, XP • HTML5 No – IE, XP • PDF Maybe, but awkward to add links clunky browser display • Graphviz Good range of outputs Gets busy quickly: A B C Not the style wanted Links only in SVG output CSIRO. Using Open Source Tools for Document Automation 31
  • 32. CSIRO ADE Diagrams – Solution A • Use hierarchy, not diagrams • Procedure: • Go through diagrams and manually transfer nodes, links to custom data format • Use Python to read data and output JSON • Use JavaScript to generate a hierarchy map from JSON • Add document names, responsibilities, metadata • Generate documents using PowerShell, COM objects  • ADE Hierarchy CSIRO. Using Open Source Tools for Document Automation 32
  • 33. CSIRO ADE Diagrams – Solution B • Do the diagrams HTML Image Map, JavaScript • Procedure: • Create diagrams as simple graphics – PPT • Save as individual images • Create image maps – free program • JavaScript code transforms simple image map • JavaScript links to the hierarchy page • ADE System Block Diagrams CSIRO. Using Open Source Tools for Document Automation 33
  • 34. CSIRO ADE Diagrams - Principles • Open Python, HTML, JavaScript Doc creation not open, but free: PowerShell • Terse Only data • DRY One source • Accessible standard web presentation • Free • Web browsers • Python • JavaScript • PowerShell • Re-usable • Maintainable • Simple CSIRO. Using Open Source Tools for Document Automation 34
  • 35. Conclusion • Coding is there to be learned • HTML, XML, JavaScript, C, Java, Perl, Python, SQL, LaTeX … • Excellent online resources • You have to learn something – either a proprietary system, or open tools • Advantages of open tools • Skill Transfer • Embody general principles • Expert and helpful community • You can solve otherwise intractable problems • Free The only cost is time CSIRO. Using Open Source Tools for Document Automation 35
  • 36. Glossary • ASKAP Australian SKA Pathfinder • CGI Common Gateway Interface • DRY Don’t Repeat Yourself • DRY Don’t Repeat Yourself • FAT Factory Acceptance Test • GNU GNU is Not Unix • HTML HyperText Markup Language • ID Identifier • Recursion see Recursion • SKA Square Kilometre Array • SAT Site Acceptance Test • SQL Structured Query Language • SVG Scaleable Vector Graphics • URL Uniform Resource Locator • XML eXtensible Markup Language • XSLT eXtensible Stylesheet Language Transformations • XSL/FO eXtensible Stylesheet Language /Formatting Objects CSIRO. Using Open Source Tools for Document Automation 36
  • 37. References • 1. Open Source Initiative http://www.opensource.org • 2. Fairlight Instruments Web site fairlightinstruments.com.au • 3. DRY – Don’t Repeat Yourself The Pragmatic Programmer: From Journeyman to Master by Andrew Hunt and David Thomas http://pragprog.com/the-pragmatic-programmer • 4. ASKAP • http://www.atnf.csiro.au/projects/askap/ • 5. CSIRO http://www.csiro.au/ • 6. CSIRO Wireless LAN patent CSIRO. Using Open Source Tools for Document Automation
  • 38. CSIRO Astronomy and Space Science Neale Morison ASKAP Documentation Manager Phone: 02 9372 4726 Email: neale.morison@csiro.au Web: www.csiro.au/org/cass Thank you Contact Us Phone: 1300 363 400 or +61 3 9545 2176 Email: enquiries@csiro.au Web: www.csiro.au