Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DDF Support? #334

Open
frokaikan opened this issue May 31, 2019 · 1 comment
Open

DDF Support? #334

frokaikan opened this issue May 31, 2019 · 1 comment

Comments

@frokaikan
Copy link

How to generate DDF C/ Java code? (Use CCodeGenerator/ JavaCodeGenerator)
Or, how to modify the SDF code to support DDF Director?

@cxbrooks
Copy link
Member

cxbrooks commented Jun 7, 2019

It would be fairly difficult to add support for DDF. The way to do it would be to mirror the classes used by the SDF facility and update them for DDF. For example

ptolemy/cg/adapter/generic/program/procedural/adapters/ptolemy/domains/sdf/kernel/SDFDirector.java

would be used to create

ptolemy/cg/adapter/generic/program/procedural/adapters/ptolemy/domains/ddf/kernel/DDFDirector.java

and
ptolemy/cg/adapter/generic/program/procedural/c/adapters/ptolemy/domains/sdf/kernel/SDFDirector.java

would be used to create
ptolemy/cg/adapter/generic/program/procedural/c/adapters/ptolemy/domains/ddf/kernel/DDFDirector.java

DDF-specific actors would go in

ptolemy/cg/adapter/generic/program/procedural/adapters/ptolemy/domains/ddf/lib/
and
ptolemy/cg/adapter/generic/program/procedural/c/adapters/ptolemy/domains/ddf/lib

Probably the easiest way to do this would be to

  1. create a small SDF model

  2. generate C code for it

  3. modify the SDF model to use the DDF director and a DDF actor or two

  4. Modify the C code by hand to support DDF.

  5. Modify the DDF code generator to generate DDF code based on the small DDF model

  6. Add support for other DDF actors.

  7. Update the code generator to generate code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants