Installation (Development)

The NanoFrazor project is self-contained and it is meant to be installed in its own directory. This is mainly because it needs some manual set up and configuration.

This section describes how to set up the NanoFrazor development framework.

Required drivers

  • See ...

Required packages

Documentation packages

  • Doxygen

  • OpenCV

  • Python related packages
    • Python 2.7
    • NumPy
    • Sphinx
    • sphinx_rtd_theme
    • Breathe
  • Latex related packages
    • Miktex
    • Texmaker
    • titlesec
    • framed
    • threeparttable
    • wrapfig
    • capt-of
    • multirow
    • eqparbox
    • environ
    • trimspaces
    • courier
    • collection-fontsrecommended
  • Gawk (http://gnuwin32.sourceforge.net/packages/gawk.htm)

GIT Setup

The NanoFrazor GIT repository is meant to be used in a centralized workflow. There is one central hub (i.e. Master) and every clone (i.e. Local) synchronizes to it. The repository has two branches: development and production. The HEAD is on the development branch. The production branch is the “blessed repository” in centralized_workflow.

centralized_workflow

Centralized workflow

The branches are not “special” from the technical perspective. The branch types are categorized simply by how we use them. They are of course plain GIT branches.

  • Create and set up the master repository:

    git config --global user.name "<user-full-name>"
    git config --global user.email "<user-email>"
    
    cd <master>/nanofrazor-pkg/
    
    git --git-dir=. --bare init
    git --git-dir=. --bare init --shared=group
    
    git config branch.master.rebase true
    git config --global branch.autosetuprebase=always
    
    | git config branch.master.remote origin
    | git config branch.master.merge master
    
  • Make an account on the internal GitLab instance and ask someone for access to the nanofrazor-dev repository

  • Create an ssh keypair with puttygen (http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html)

    • Choose a 4,096-bit RSA key
    • Export private key as OpenSSH key (Conversions -> Export OpenSSH key) to $HOME\.ssh\id_rsa
    • Save public key to $HOME\.ssh\id_rsa.pub
    • Copy the public key from the puttygen window into Gitlab (Profile Settings -> SSH Keys -> Add SSH Key). Make sure there are no newlines in the key
  • Clone the project in C:\SwissLitho with git clone git@sl-serv:nsuditu/nanofrazor-dev.git

  • Create and set up a clone repository:

    cd <local>/nanofrazor-pkg
    
    git clone <master>/nanofrazor-pkg .
    
    git config user.name "<user-full-name>"
    git config user.email "<user-email>"
    

CCS Setup

  • WIN-OS environment variables
SYSBIOS_ROOT = “C:ticss-5.4bios_6_35_01_29”
XDCROOT = “C:ticss-5.4xdctools_3_25_00_48”
IA_SDK_HOME = “C:tiam335x_sysbios_ind_sdk_1.0.0.8sdk”
AM335X_STARTERWARE_ROOT = “C:tiam335x_sysbios_ind_sdk_1.0.0.8sdkstarterware”
  • TI-CCS global path variables

Add in Window > Preferences > General > Workspace > Linked resources:

SYSBIOS_ROOT = “C:ticss-5.4bios_6_35_01_29”
XDCROOT = “C:ticss-5.4xdctools_3_25_00_48”
IA_SDK_HOME = “C:tiam335x_sysbios_ind_sdk_1.0.0.8sdk”
AM335X_STARTERWARE_ROOT = “C:tiam335x_sysbios_ind_sdk_1.0.0.8sdkstarterware”
  • TI-CCS insert spaces for tabs

Go in Window > Preferences > General > Editors > Text Editors:

Select “Insert spaces for tabs”

Go in Window > Preferences > C/C++ > Code Style > Formatter:

Create a new profile “K&R [spaces]”
Edit... Tab policy: “Spaces only”
  • VS-2010 insert spaces for tabs

Go in Tools > Options > Text Editors > All Languages > Tabs:

Select “Insert spaces”

Visual C++ Setup

  • Compile the C++ code:

    ./app/xop/VC12/NanoFrazor.sln
    

Igor Pro Setup

  • Go to the “Igor User Files”/”Igor Extensions” directory and create a soft-link for the file:

    ./app/xop/Win32/Debug/dll/NanoFrazor.xop
    
  • Go to the “Igor User Files”/”User Procedures” directory and create a soft-link for the directory:

    ./app/ipf
    
  • Go to the “Igor User Files”/”Igor Procedures” directory and create a soft-link for the file:

    ./app/ipf/NanoFrazorLoader.xop
    

Generate the installer

Follow the below steps to prepare the new installer:

  • Merge master branch to release branch on GIT.

  • Switch the GIT HEAD to the release branch.

  • Update the release version in the following files:

    ./extra/rename_version.py
    
  • Hide unfinished functionality

  • Compile device code in release mode

  • Compile host code in release mode

  • Update the NanoFrazor documentation

  • Compile the installer

  • Make the archive NanoFrazor-x.x.x.zip

  • Update ...

  • Update the last release version on the webpage

Generate the documentation

The project documentation is provided along with the archive:

./doc/html/
./doc/NanoFrazor.pdf

The documentation source files are provided as well:

./doc/doxygen-lib
./doc/doxygen-xop
./doc/doxygen-ipf
./doc/sphinx

The project documentation can be created as follows:

cd ./extra/
build_documentation.py

The Sphinx documentation takes as input the Doxygen documentation in XML format.

Build Boost C++ libraries

  1. Download Boost and unzip into:

    C:/vc/
    
  2. Build:

    cd ./extra/
    build_boost.py
    
  3. Setup:

    Add $PROJECT_ROOT_DIR to the project Include files
    Add $PROJECT_ROOT_DIR\stage\lib to the project Library files