My First Module

Well, not exactly a lot of activity here. Either this is going to be very easy, or very hard. :slight_smile:

I’m going to try to make a 3D Canvas component. I’m familiar with Eclipse, and have made a few Jython projects with it. I unzipped the sample projects into the workspace, and all seems good.

Now, some dumb questions:

  1. Everything I know about Java I have learned by programming Jython. I assume that these modules have to be programmed in Java? Or is Jython an option?

  2. Not knowing Java (at least as far as starting a project from scratch goes), would my best best be to use your sample project as a starting point and modify it to create the 3D canvas? Or are modules in general going to be so radically different that I should start from scratch?

  3. If I create a module and add it to the designer scope, do I need to add it to the client scope at all? Or is it added automatically when the Ignition project is compiled?

I’m really excited about this, and have an immediate need for the 3D canvas, and have a half dozen other modules in mind. I’ll put in the work to make it happen, but I don’t know where to begin.

Well, I can confidently say that it won’t be easy, but it won’t necessarily be “very hard” either. The SDK is still fairly new, and not many customers have the appetite for the technical skill that it demands.

  1. It must be programmed in Java, not Jython.

  2. You can take a look at the weather module, in particular the part where it adds a component. You’ll want to mimic that part. I’d start a new project from scratch, copying those parts of the same project you find useful.

  3. You’ll probably want to actually create 2 projects: one for your client-scoped resources (The 3D canvas itself) and one for the designer-scoped resources (The designer hook that adds the canvas component to the palette, the bean-info class for your component, any customizers you write). To re-iterate, you’ll end up with one module, that will probably have 2 jars in it, one scoped to be loaded in the client and the designer (“DC”), one scoped to designer (“D”).