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

installation uvr1611 / database #6

Open
oopskoule opened this issue Feb 22, 2015 · 6 comments
Open

installation uvr1611 / database #6

oopskoule opened this issue Feb 22, 2015 · 6 comments
Assignees
Labels

Comments

@oopskoule
Copy link

Hi,
first many thanks for this great work!
Unfortunatelly I fail importing the tables usign the script:

Using the sample data, structure.sql was running fine.
When I use table-migration.sql afterwards, I get an error:
ERROR 1054 (42S22): Unknown column 'name_id' in 't_names_of_charts'

I tried to add the column: alter table t_names_of_charts add name_id char(50);

Then the script is running until:
Can't DROP 'chart_id'; check that column/key exists.

Even data-migration.sql does fail:
ERROR 1146 (42S02): Table 'uvr1611.t_datasets' doesn't exist

Sorry, but I am an abolutely noob in mysql....
Many thanks, Peter

@berwinter
Copy link
Owner

Hi Peter,

the migration scripts are only necessary if you have used an old version of the datalogger before. For new installations you are done after importing the structue.sql and the example data.

Bertram

@oopskoule
Copy link
Author

Hi Bertram,
thanks for this hint, it solved my problem! :-)

I still have some questions:

  1. In my "Hauptmenü -> Schema, I do not get an entry fpr "MISCHER_AUF" or "MISCHER_ZU".
    in t_schema.sql I definers:
    INSERT INTO t_schema (id,path,frame,type,format) VALUES (26,'#Mischer_Hzkr2_auf > tspan','frame1','digital10','MISCHER_AUF(#)');
    INSERT INTO t_schema (id,path,frame,type,format) VALUES (27,'#Mischer_Hzkr2_zu > tspan','frame1','digital11','MISCHER_ZU(#)');

In schema.svg, the field "Bezeichner" has been defined with: "#Mischer_Hzkr2_auf".

  1. When choosing "Erträge" in "Haupütmenü" I get an error: "Not enough columns given to draw the requested chart.×"
    "Erträge" have been defined in t_menu with:
    INSERT INTO t_menu (id,name,unit,type,order,schema) VALUES (8,'Erträge','#.# kWh','energy',7,NULL);

any idea?
many thanks for help!
best regards,
Peter

@berwinter
Copy link
Owner

You are welcome ;)

The problem with the "MISCHER" (mixer) is that their values are only displayed when the valve is moving. E.g. when it's opening or closing. The reason for this is, that usually there is no information about the exact position of the mixer.

If you have a normal valve, you could use instead the function VENTIL(#) to display the states "open" and "closed".

For the second problem, you have to look into the table ´t_names_of_charts´ for the entries with ´chart_id´ 8. There you should have defined the lines for the chart. Eg:
INSERT INTO t_names_of_charts (chart_id,type,frame,order) VALUES (8,'energy1','frame1',1);
INSERT INTO t_names_of_charts (chart_id,type,frame,order) VALUES (8,'energy2','frame1',2);

BR Bertram

@oopskoule
Copy link
Author

Hi Bertram,

you are right: Of course the status "AUF"/ "ZU" can only appear, when the mixer is running / changing its position.
I could see this now for a short time! :-)
The energy chart is displayed properly now - there was a mismatch in the table.

Is there a possibility to display digital values too?
(for example when are my pumps running...)

BR,
Peter

@berwinter
Copy link
Owner

Hi Peter,

yes, you can display digital values too. For the schema you have to use the function DIGITAL(#) which display then 'EIN' or 'AUS'. For the charts you can add the digital lines just like the analog ones. They will be shown in a separated chart above the analog chart.

BR Bertram

@berwinter berwinter self-assigned this Mar 3, 2015
@oopskoule
Copy link
Author

Bertram,
I assumed this, so I tried to implement digital values in charts, but I do not succeed, for example:

in t_menu is defined:
| 6 | Pumpen | # | line | 5 | NULL |

in t_schema I defined:
| 17 | #Pumpe_Solar > tspan | frame1 | digital1 | DIGITAL(#) |

in t_names_of_charts its defined:
| 4 | digital1 | frame1 | 4 |

So there should be a chart of this pump digital 1 in chart 4 (at the 4th position) ?
In my schema, this pump is shown properly with on/off.
I cant detect the error, unfortunately there a no digital values used in your examples... :-).

Many thanks,
cheers,
Peter

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

No branches or pull requests

2 participants