Changes between Version 17 and Version 18 of DevelopGuide


Ignore:
Timestamp:
Sep 30, 2008, 8:02:27 AM (16 years ago)
Author:
Frédéric
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • DevelopGuide

    v17 v18  
    99  * [#View View]
    1010 * [#Distributing Distributing]
    11   * [#Makedebianpackage Make debian package]
    12   * [#Makemaemopackage Make maemo package]
     11  * [#Makedebianpackage Make Debian package]
     12  * [#Makemaemopackage Make Maemo package]
     13  * [#Makewindowsinstaller Make Windows installer]
    1314 * [#Thefuture The future]
    1415
     
    3334=== Model ===
    3435
    35 ==== Custom presets ====
    36 
    37 The current (1.0) version does not allow user to add its own presets, at least not from the GUI. But it is not very difficult to modify the code to do that. Just edit the:
    38 
    39 {{{<install_dir>/papywizard/common/config.py}}}
    40 
    41 file (you may need to become root), and add the new preset(s) in the '''PRESET_INDEX''' and '''PRESET''' vars. The first one is used by the GUI to build the list of presets (in a Combo Box), and contains a double-entry dict. The integer is the position of the preset in the GUI list. The second var contains the presets themselves. Note that the names must match in the 3 locations!
    42 
    43 A preset is just a python dict., where the key is its name (as listed in the GUI), and the value a list of tuples, where each tuple is the ''(yaw, pitch)'' position to shoot. Note that it is possible to use The {{{None}}} value as position; in this case, the given axis won't move, but rather stay at the previous position. This is mainly used for ''zenith'' and ''nadir'', where the ''yaw'' position does not matter. Example:
    44 
    45 {{{
    46 PRESET_INDEX = {'4@0 + Z + N': 0,
    47                 '3@-15 + Z': 1,
    48                 '6@-15 + 6@30 + N': 2,
    49                 '3 + 6 + 12 + 6 + 3 (28mm)': 3,
    50                 0: '4@0 + Z + N',
    51                 1: '3@-15 + Z',
    52                 2: '6@-15 + 6@30 + N',
    53                 3: '3 + 6 + 12 + 6 + 3 (28mm)'}
    54 
    55 
    56 PRESET = {'4@0 + Z + N': [(  0.,   0.), (90., 0.), (180., 0.), (270., 0.),
    57                           (None,  90.),
    58                           (None, -90.)],
    59           '3@-15 + Z': [(  0., -15.), (120., -15.), (240., -15.),
    60                         (None,  90.)],
    61           '6@-15 + 6@30 + N': [(  0., -15.), ( 60., -15.), (120., -15.), (180., -15.), (240., -15.), (300., -15.),
    62                                (300.,  30.), (240.,  30.), (180.,  30.), (120.,  30.), ( 60.,  30.), (  0.,  30.),
    63                                (None, -90.)],
    64           '3 + 6 + 12 + 6 + 3 (28mm)': [( 30.,  70.), (150.,  70.), (270.,  70.),
    65                                         (300.,  40.), (240.,  40.), (180.,  40.), (120.,  40.), ( 60.,  40.), (  0.,  40.),
    66                                         (  0.,  10.), ( 30., -10.), ( 60.,  10.), ( 90., -10.), (120.,  10.), (150., -10.), (180.,  10.), (210.,-10.), (240.,  10.), (270.,-10.), (300.,  10.), (330.,-10.),
    67                                         (300., -40.), (240., -40.), (180., -40.), (120., -40.), ( 60., -40.), (  0., -40.),
    68                                         ( 30., -70.), (150., -70.), (270., -70.)]}
    69 }}}
    70 
    71 To be more efficient, and avoid to much head moves, be carefull when entering positions; try to optimize the relative moves from one position to the other (do not come back to the begining of each row before shooting the next one, but rather shoot in the opposite direction).
    72 
    73 ''Put this in tips and tricks.''
    74 
    7536=== View ===
    7637
    7738== Distributing ==
    7839
    79 === Make debian package ===
     40=== Make Debian package ===
    8041
    8142Papywizard includes an distutils extension script to build debian package in a easy way:
     
    8748The package is build in the {{{dist/}}} directory.
    8849
    89 === Make maemo package ===
     50=== Make Maemo package ===
    9051
    9152Same for debian package:
     
    9556}}}
    9657
     58=== Make Windows installer ===
     59
     60This is a little bit tricky (as always on this plateform!).
     61
     62You first need to build the executable, by launching the windows setup script. The easier is to use [http://ipython.scipy.org Ipython]:
     63
     64{{{
     65In [1]: run windows/setup.py py2exe
     66}}}
     67
     68Then, run the script {{{windows/papywizard.nsi]] to build the installer itself.
    9769
    9870== The future ==