How can I do modeling in reverse by parsing a C program and turning it in to a circuit diagram to be displayed.

How can I do modeling in reverse by parsing a C program and turning it in to a circuit diagram to be displayed.

Example

![alt text][1]


![alt text][2]

Except this is psedocode. 

  [1]: http://i.stack.imgur.com/gPeEF.png
  [2]: http://i.stack.imgur.com/re6tv.png
How can I do modeling in reverse by parsing a C program and turning it in to a circuit diagram to be displayed.
===


How can I do modeling in reverse by parsing a C program and turning it in to a circuit diagram to be displayed.

Example

![alt text][1]


![alt text][2]

Except this is psedocode. 

  [1]: http://i.stack.imgur.com/gPeEF.png
  [2]: http://i.stack.imgur.com/re6tv.png