Commit graph

6 commits

Author SHA1 Message Date
Paulo Henrique Silva
820d8aa903 Allowance for weird case modifier with no zero after period 2015-04-07 13:25:53 -03:00
Paulo Henrique Silva
f6dbe87c03 Add support for unary minus operator on macro parsing 2015-03-06 15:00:16 -03:00
Paulo Henrique Silva
21fdb9cb57 More py3 fixes 2015-03-05 15:13:59 -03:00
Paulo Henrique Silva
adc1ff6d72 Fix for py3 2015-03-05 14:58:36 -03:00
Paulo Henrique Silva
a13b981c1c Fix tests for macros with no variables.
All AM*Primitive classes now handles float for all but the code
modifiers. This simplifies the reading/parsing.
2015-03-05 14:43:30 -03:00
Paulo Henrique Silva
670d3fbbd7 Add aperture macro parsing and evaluation.
Aperture macros can get complex with arithmetical operations,
variables and variables substitution.

Current pcb-tools code just read each macro block as an independent
unit, this cannot deal with variables that get changed after used.

This patch splits the task in two: first we parse all macro content
and creates a bytecode representation of all operations. This bytecode
representation will be executed when an AD command is issues passing
the required parameters.

Parsing is heavily based on gerbv using a Shunting Yard approach to
math parsing.

Integration with rs274x.py code is not finished as I need to figure out
how to integrate the final macro primitives with the graphical primitives
already in use.
2015-03-03 03:41:55 -03:00