PROGRAM GENERATING APPARATUS AND BLOCK DIAGRAM GENERATING APPARATUS
First Claim
1. A program generating apparatus comprising:
- a block diagram storing unit configured to store a block diagram including an input block element, a calculation block element, an output block element, data lines indicating data flows between the input block element, the calculation block element and the output block element, and a branch point that branches at least one of the data lines;
a block diagram dividing unit configured to divide the block diagram into an input side piece and one or more output side pieces at the branch point and connect a branch point block element to one end of each of data lines which have been connected to the branch point in the input side piece and the one or more output side pieces to generate a plurality of block diagram pieces each of which includes the input side piece or one of the one or more output side pieces;
a program instruction generator configured to generate program instructions for performing processing on a respective one of the block diagram pieces;
an execution sequence determining unit configured to determine an execution sequence of the generated program instructions so that the program instruction of the block diagram piece including the input side piece are executed before program instructions of the block diagram pieces including the one or more output side pieces;
a structural information generator configured to generate structural information of a respective one of the block diagram pieces; and
a program generator configured to arrange the generated program instructions according to the execution sequence, write structural information of each of the block diagram pieces into a comment line of each of the program instructions corresponding to each of the block diagram pieces and thereby generate a program,wherein the structural information generator generates structural information of each of the block diagram pieces so that a block element at an end of each of the plurality of block diagram pieces is assigned to a child node of a root node of a tree structure, the block element being one of the input block element, the calculation block element, the output block element and the branch point block element, and a block element to be processed immediately before a block element assigned to a parent node different from the root node is assigned to a child node of the parent node, the former block element and the latter block element each being one of the input block element, the calculation block element, the output block element and the branch point block element.
1 Assignment
0 Petitions
Accused Products
Abstract
The apparatus of the present invention includes a block diagram dividing unit that divides a block diagram into a plurality of pieces at a branch point, connects a branch point block element to one end of a data line which has been connected to the branch point at each divided piece and thereby generates a plurality of block diagram pieces, a program instruction generator that generates program instructions for performing processing on each block diagram piece, an execution sequence determining unit that determines an execution sequence of generated program instructions, a structural information generator that generates structural information of each of the block diagram pieces and a program generator that arranges the program instructions according to the execution sequence, writes structural information of each block diagram piece into a comment line of each of the program instructions corresponding to each of the block diagram pieces and thereby generates a program.
-
Citations
7 Claims
-
1. A program generating apparatus comprising:
-
a block diagram storing unit configured to store a block diagram including an input block element, a calculation block element, an output block element, data lines indicating data flows between the input block element, the calculation block element and the output block element, and a branch point that branches at least one of the data lines; a block diagram dividing unit configured to divide the block diagram into an input side piece and one or more output side pieces at the branch point and connect a branch point block element to one end of each of data lines which have been connected to the branch point in the input side piece and the one or more output side pieces to generate a plurality of block diagram pieces each of which includes the input side piece or one of the one or more output side pieces; a program instruction generator configured to generate program instructions for performing processing on a respective one of the block diagram pieces; an execution sequence determining unit configured to determine an execution sequence of the generated program instructions so that the program instruction of the block diagram piece including the input side piece are executed before program instructions of the block diagram pieces including the one or more output side pieces; a structural information generator configured to generate structural information of a respective one of the block diagram pieces; and a program generator configured to arrange the generated program instructions according to the execution sequence, write structural information of each of the block diagram pieces into a comment line of each of the program instructions corresponding to each of the block diagram pieces and thereby generate a program, wherein the structural information generator generates structural information of each of the block diagram pieces so that a block element at an end of each of the plurality of block diagram pieces is assigned to a child node of a root node of a tree structure, the block element being one of the input block element, the calculation block element, the output block element and the branch point block element, and a block element to be processed immediately before a block element assigned to a parent node different from the root node is assigned to a child node of the parent node, the former block element and the latter block element each being one of the input block element, the calculation block element, the output block element and the branch point block element. - View Dependent Claims (2)
-
-
3. A program generating apparatus comprising:
-
a multilayer block diagram storing unit configured to store a multilayered block diagram including; at least an input block element and an output block element out of the input block element, a calculation block element and the output block element; a subsystem block; data lines indicating data flows between at least the input block element, the output block element and the subsystem block out of the input block element, the calculation block element, the output block element and the subsystem block; and a subblock diagram of the subsystem block, which includes an input subblock element, a calculation subblock element, an output subblock element and data lines indicating data flows between the input subblock element, the calculation subblock element and the output subblock element; a single layer block diagram generator configured to substitute the subblock diagram for the subsystem block in the multilayered block diagram, connect a data line connected to an input of the subsystem block to an input of the input subblock element, connect a data line connected to an output of the subsystem block to an output of the output subblock element and thereby generate a single layer block diagram; a structural information generator configured to generate structural information of the single layer block diagram; a program instruction generator configured to generate program instructions for performing processing on the single layer block diagram; and a program generator configured to arrange the program instructions, write structural information of the single layer block diagram into a comment line of the program instructions and thereby generate a program. - View Dependent Claims (4)
-
-
5. A block diagram generating apparatus comprising:
-
a data reading unit configured to read data of a tree structure from a comment line of a program, the tree structure including an input block element, a calculation block element, an output block element and branch point block elements each of which indicates a branch of a data line, wherein each of the input block element, the calculation block element, the output block element and the branch point block elements has a block identifier and is assigned to a node different from a root node in the tree structure and; a block diagram piece generator configured to generate a plurality of block diagram pieces by sequentially connecting a data line from a block element assigned to a child node to a block element assigned to a parent node of the child node starting from each child node of the root node toward each leaf node in the tree structure, the former block element and the latter block element each being one of the input block element, the calculation block element, the output block element and the branch point block elements; and a combination unit configured to generate a block diagram to which the block diagram pieces are combined, by integrating branch point block elements having identical block identifiers among different block diagram pieces into a branch point. - View Dependent Claims (6)
-
-
7. A block diagram generating apparatus comprising:
-
a tree structure reading unit configured to read data of a tree structure in which block elements are assigned to nodes different from a root node, from a comment line of a program, the block elements including at least an input block element and an output block element out of the input block element, the output block element and a calculation block element, a calculation subblock element, a first input subblock element that receives data from a source element of the first input subblock element, a second input subblock element that sends out data received by the first input subblock element, a first output subblock element that receives data from a source element of the first output subblock element and a second output block element that outputs the data received by the first output subblock element; a block diagram piece generator configured to generate a plurality of block diagram pieces by sequentially connecting an element assigned to a child node to an element assigned to a parent node of the child node with a data line, starting from each leaf node in the tree structure toward each child node of the root node, the former element and the latter element each being one of the input block element, the output block element, the calculation block element, the calculation subblock element, the first input subblock element, the second input subblock element, the first output subblock element and the second output block element; a single layer block diagram generator configured to generate a single layer block diagram into which the block diagram pieces are combined by integrating the first and second input subblock elements between different block diagram pieces into a single input subblock element and integrating the first and second output subblock elements between different block diagram pieces into a single output subblock element; and a multilayered block diagram generator configured to specify a subblock diagram in the single layer block diagram, the subblock diagram being formed by the single input subblock element, the calculation subblock element, the output subblock element and data lines connecting between the single input subblock element, the calculation subblock element and the output subblock element, substitute a subsystem block for the subblock diagram, connect a data line which has been connected to the input of the single input subblock element to the input of the subsystem block, connect a data line which has been connected to the output of the single output subblock element to the output of the subsystem block and thereby generate a block diagram, and generate and output a multilayered block diagram including both of the subblock diagram and the block diagram.
-
Specification