Adding own widgets (cylinder with 6 temperature-feeds)

Hi,

is it possible, to add own widgets? Any HowTo for this?

Why I ask:

I have a waterboiler with 6 temp-sensors over the whole boiler. I found there is a cylinder-widget.
Therefore my thought: Copy the cylinder_render.js, modify it to hold all 6 temps, and give the 6 temps out on the graphic. Modifying the "cylinder_render.js" should not be the problem. But I do not know, how to tell emoncms, that there is a new widget.

The place, where i thought to add the new widget (widgetlist.js) there are only text and container-items.

As soon, as I add a new subfolder in "C:\wamp\www\emoncms\Modules\dashboard\Views\js" dashboard is working wrong :-(

 

BTW:
I changed this: (missing ° )

    ctx.fillText(cyl_top.toFixed(1)+"C",midx,top_pos);
    ctx.fillText(cyl_bot.toFixed(1)+"C",midx,bot_pos+15);

to

    ctx.fillText(cyl_top.toFixed(1)+"°C",midx,top_pos);
    ctx.fillText(cyl_bot.toFixed(1)+"°C",midx,bot_pos+15);

 

brutzler's picture

Re: Adding own widgets (cylinder with 6 temperature-feeds)

Hi,

found this from Trystan: http://openenergymonitor.org/emon/node/2491

With this "faq" I was able to create the widget, I need for my project.

I append a pic from my result:

- showing all 6 temperatures in the cylinder
- calculating the color for each temperature

If somebody wants to copy: Feel free to contact me.

sumnerboy's picture

Re: Adding own widgets (cylinder with 6 temperature-feeds)

I did something similar but only showing an extra temp in the middle, I.e. 3 in total. Sorry but away on holiday so can't send thru any pics or code just now.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.