[Logo] Mango Community
  [Search] Search   [Recent Topics] Recent Topics   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
Controlling Hardware using Mango  XML
Forum Index » Mango M2M 1.12.5 and Earlier general discussion
Author Message
mlohbihler

Master
[Avatar]

Joined: 01/03/2007 22:48:52
Messages: 1850
Offline

Hello Gia,

We do not ship the build scripts with the source code, but it is pretty simply a matter of compiling the Java source, and deploying it with the other application assets to the Tomcat server. All required jar files for referencing during compilation can be found in the WEB-INF/lib directory.

Best regards,
Matthew Lohbihler
gia

Initiate

Joined: 25/10/2007 05:33:17
Messages: 19
Offline

Thanks for the reply.

I am able to compile the Mango src 9.2 with jdk1.6. To get time stamp i have modified the code in PointValueDao.java. Its also compiled successfully. Its working perfectly and getting time stamp from my DB.

There are few problems which i faced are as follow:

1. My relay points are not working.
Desc: If my relay is off and i want to turn it ON. and select ON button then i get error message. Due to which i am not able to operate on my relay. In error message error is displayed.

2. After getting error from previous problem i compiled the original source code as it is without any modification and replaced my PointValueDao.class with original PointValueDao.class. I found the same error.

3. After getting second problem i have checked my pointValueDao.class file size. I found the size is not same. Original class file size is 10.5 K and my compiled file size is 10.1 k.

Please do let me know the reason for this.
mlohbihler

Master
[Avatar]

Joined: 01/03/2007 22:48:52
Messages: 1850
Offline

Hi Gia,

I'm not sure about the class file sizes (could simply be a matter of different compilers), but there is something you can check.

It was discovered that the SQL DS point editing is too permissive (a problem corrected for the next version), in that it allows users to change the data type of a point. You should not alter the data type of a point since it will cause a conflict with any saved readings, resulting in many problems.

If you suspect that this may be the problem you are having, you should determine the point id of the changed point and delete all its entries from the DataPointValues table.

Hope this helps.

Best regards,
Matthew Lohbihler
gia

Initiate

Joined: 25/10/2007 05:33:17
Messages: 19
Offline

Thanks for the reply.
I have checked the data type of the points and I am not changing it.

I have done another testing i.e:

Without any modification in source file that I ahave downloaded I have compiled the Mango src 9.2 but after replacing the pointValueDao.class at the installed path(i.e /mango/WEB-INF/classes/com/serotonin/mango/db/dao) from the compiled path(i.e com/serotonin/mango/db/dao I am not able to run mango as it was running previously without changing the class.

This shows that either source given by you is not matching with the classes in the installer or I am doing some mistakes.

Please help to compile the source code in such a manner that if I change the installed classes with the newly compiled classes there should not be any error.

FYI:
I am using eclipse 3.1.2 with jdk 1.6 to compile the mango src and i have included all the jar files that are provided in lib directory.

Thanks and Regards
Gia

mlohbihler

Master
[Avatar]

Joined: 01/03/2007 22:48:52
Messages: 1850
Offline

Note that PointValueDao contains at least two inner classes which are created as separate files when compiled. Can you describe the error you receive?

Best regards,
Matthew Lohbihler
gia

Initiate

Joined: 25/10/2007 05:33:17
Messages: 19
Offline

Hi,

As per your suggestion I found that the class PointValueDao.class depends two more classes i.e. PointValueDao$1.class and PointValueDao$PointValueRowMapper.class I have replaced these classes also from the installed path with the newly compiled class but still I am facing the same problem.

To create that error scenario at your end you can configure mango as per my previous posts at http://mango.serotoninsoftware.com/forum/posts/list/52.page. And the compile the mango src 0.9.2 and replace the old classes with the newly compiled classes ( PointValueDao.class PointValueDao$1.class and PointValueDao$PointValueRowMapper.class).

When you'll try to ON or OFF the relays (i.e internally for the mysql database we are firing update statement from mango UI Update statement : update gateway1 set status = ? where relayno = "relay2" at this time a pop up window appears saying !Error and on its title bar it was written "The page at http://10.10.1.136:8080 says:".


As per my understanding with mysql database we have two way communication from mango UI one is the select statement which takes the value of points from mysql database n displays it on mango UI. The other is the update statement which is used to save any data from mango UI to the mysql database like ON-OFF of relays. My select statement is working fine but when I try to run the update statement using the ON - OFF radio buttons I am getting Error.


Please help me to run the mango from the compiled classes.


Thanks and Regards
Gia
mlohbihler

Master
[Avatar]

Joined: 01/03/2007 22:48:52
Messages: 1850
Offline

Hi Gia,

You are apparently receiving this error:


You will need to recompile all of the source code with your changes to resolve this issue.

Best regards,
Matthew Lohbihler
gia

Initiate

Joined: 25/10/2007 05:33:17
Messages: 19
Offline

Hello

Thanks for your quick reply.

I am not getting any such error message at compile time nor at the runtime.

Main problem is that when I compile the Mango source code that I have downloaded from this link http://mango.serotoninsoftware.com/download.jsp , at that time I get no error message. But when I replace my compiled java code with class files in the WEBINF folder then I am not able to make my relay ON/OFF.

I am not able to catch this problem because I haven't changed the src code that I have downloaded , then why my relay point stoped working after replacing the class files????????

If you are not facing any such problem then please let me know your compile procedure so that I can follow same steps and I can check where the actual problem is..

regards
gia



gia

Initiate

Joined: 25/10/2007 05:33:17
Messages: 19
Offline

Hi

I have got the mentioned error.
Actually by default my eclipse was using jdk1.5 to compile the mango source code.

I have now compiled the source with jdk1.6 n hurray! mango is working fine now by replacing the old classes in the WEB-INF folder with the newly compiled classes.

Things are ok now.


Thanks and Regards
Gia
 
Forum Index » Mango M2M 1.12.5 and Earlier general discussion
Go to:   
Powered by JForum 2.1.9 © JForum Team