Modbus IP
-
I tested the modbus IP data source with Twido PLC. All data type points possible are not supported in twido so i tested the ones which are supported.(2 byte datatypes). So i can tell Telemecanique Twido is one supported HW.
Found a problem with Holding registers with binary data type. The data reading works well but setting such data point value there appears popup dialog with text "Error" (and nothing more). Could someone explaind what causing this or is there some bug?
-
Are you using version 1.7.0? If so, either turn on "report errors to Serotonin", or send any information/stack traces in the Tomcat console or log.
-
Thanks for such a fast reply. Yes I am using 1.7.0. Ill try with the error reporting mechanism. I also check the logs.
edit.
Hope you received the error report. The log is quite long. I restarted tomcat and copied all print after it...```19.10.2009 21:17:14 org.apache.catalina.core.StandardContext listenerStart
SEVERE: Exception sending context initialized event to listener instance of class com.serotonin.mango.MangoContextListener
org.springframework.jdbc.CannotGetJdbcConnectionException: Could not get JDBC Connection; nested exception is java.sql.SQLException: Failed to start database '/var/lib/tomcat6/webapps/mango/../../mangoDB', see the next exception for details.
at org.springframework.jdbc.datasource.DataSourceUtils.getConnection(DataSourceUtils.java:82)
at com.serotonin.mango.db.DerbyAccess.initializeImpl(DerbyAccess.java:77)
at com.serotonin.mango.db.DatabaseAccess.initialize(DatabaseAccess.java:82)
at com.serotonin.mango.MangoContextListener.databaseInitialize(MangoContextListener.java:248)
at com.serotonin.mango.MangoContextListener.contextInitialized(MangoContextListener.java:85)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4338)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:926)
at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:889)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:492)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1149)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at org.apache.catalina.core.StandardService.start(StandardService.java:516)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at org.apache.commons.daemon.support.DaemonLoader.start(DaemonLoader.java:177)
Caused by: java.sql.SQLException: Failed to start database '/var/lib/tomcat6/webapps/mango/../../mangoDB', see the next exception for details.
at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.Util.seeNextException(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedConnection.bootDatabase(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedConnection.<init>(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedConnection30.<init>(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedConnection40.<init>(Unknown Source)
at org.apache.derby.jdbc.Driver40.getNewEmbedConnection(Unknown Source)
at org.apache.derby.jdbc.InternalDriver.connect(Unknown Source)
at org.apache.derby.jdbc.EmbeddedDataSource.getConnection(Unknown Source)
at org.apache.derby.jdbc.EmbeddedDataSource.getConnection(Unknown Source)
at org.springframework.jdbc.datasource.DataSourceUtils.doGetConnection(DataSourceUtils.java:113)
at org.springframework.jdbc.datasource.DataSourceUtils.getConnection(DataSourceUtils.java:79)
... 32 more
Caused by: java.sql.SQLException: Failed to start database '/var/lib/tomcat6/webapps/mango/../../mangoDB', see the next exception for details.
at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(Unknown Source)
... 45 more
Caused by: java.sql.SQLException: Java exception: ': java.nio.channels.OverlappingFileLockException'.
at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(Unknown Source)
at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.Util.javaException(Unknown Source)
... 42 more
Caused by: java.nio.channels.OverlappingFileLockException
at sun.nio.ch.FileChannelImpl$SharedFileLockTable.checkList(FileChannelImpl.java:1215)
at sun.nio.ch.FileChannelImpl$SharedFileLockTable.add(FileChannelImpl.java:1117)
at sun.nio.ch.FileChannelImpl.tryLock(FileChannelImpl.java:923)
at java.nio.channels.FileChannel.tryLock(FileChannel.java:978)
at org.apache.derby.impl.io.DirFile4.getExclusiveFileLock(Unknown Source)
at org.apache.derby.impl.store.raw.data.BaseDataFileFactory.privGetJBMSLockOnDB(Unknown Source)
at org.apache.derby.impl.store.raw.data.BaseDataFileFactory.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at org.apache.derby.impl.store.raw.data.BaseDataFileFactory.getJBMSLockOnDB(Unknown Source)
at org.apache.derby.impl.store.raw.data.BaseDataFileFactory.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.TopService.bootModule(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.startModule(Unknown Source)
at org.apache.derby.iapi.services.monitor.Monitor.bootServiceModule(Unknown Source)
at org.apache.derby.impl.store.raw.RawStore.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.TopService.bootModule(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.startModule(Unknown Source)
at org.apache.derby.iapi.services.monitor.Monitor.bootServiceModule(Unknown Source)
at org.apache.derby.impl.store.access.RAMAccessManager.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.TopService.bootModule(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.startModule(Unknown Source)
at org.apache.derby.iapi.services.monitor.Monitor.bootServiceModule(Unknown Source)
at org.apache.derby.impl.db.BasicDatabase.bootStore(Unknown Source)
at org.apache.derby.impl.db.BasicDatabase.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.TopService.bootModule(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.bootService(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.startProviderService(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.findProviderAndStartService(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.startPersistentService(Unknown Source)
at org.apache.derby.iapi.services.monitor.Monitor.startPersistentService(Unknown Source)
... 42 more
19.10.2009 21:17:14 org.apache.catalina.core.ApplicationContext log
INFO: Closing Spring root WebApplicationContext -
I made some investigation in the source code. It seems to go into the WriteMaskRegisterRequest in ModbusMaster.java. I Analysed the network traffic and mango sends once Modbus function 22 message. Twido is not supporting the function so it responds "exception code 1 Illegal function". When trying to set some other value it does not send this message again. So the slaveprofile saving probably is ok.
In the code there is the "Hard way " option but that seems not reached. I assume there should be read request(F3) and write request(F6) sent.
Regards
Jokke -
If there's no WriteMaskRegisterRequest being made again, there's nowhere else to go than "the hard way". Did you manage to get a stack trace of the problem? (The stuff in your snippet all has to do with Mango not being able to find a database - definitely unrelated.)
-
I am testing with Ubuntu 9.04. After the first post I removed open java and installed sun java(if it has anything to do with anything). I repeated the test, stopped tomcat, removed logs and started again. This time i found out there is a og named mango.log :oops: i was just checkin catalina....log and localhost...log under tomcat logs folder.
mango.log content is ```
startup date [Wed Oct 21 18:44:04 EEST 2009]; root of context hierarchy
INFO 2009-10-21 18:50:50,155 (org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.destroySingletons:392) - Destroying singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@1742700: defining beans [CompoundEventsDwr,DataPointDetailsDwr,DataPointEditDwr,DataSourceEditDwr,DataSourceListDwr,EmportDwr,EventHandlersDwr,EventsDwr,MailingListsDwr,MiscDwr,PointHierarchyDwr,PublisherEditDwr,PublisherListDwr,ReportsDwr,ScheduledEventsDwr,SystemSettingsDwr,UsersDwr,ViewDwr,WatchListDwr,localeResolver,messageSource]; root of factory hierarchy
INFO 2009-10-21 18:52:06,155 (org.springframework.web.context.ContextLoader.initWebApplicationContext:189) - Root WebApplicationContext: initialization started
INFO 2009-10-21 18:52:06,568 (org.springframework.context.support.AbstractApplicationContext.prepareRefresh:412) - Refreshing org.springframework.web.context.support.XmlWebApplicationContext@ff2413: display name [Root WebApplicationContext]; startup date [Wed Oct 21 18:52:06 EEST 2009]; root of context hierarchy
INFO 2009-10-21 18:52:07,195 (org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions:323) - Loading XML bean definitions from ServletContext resource [/WEB-INF/applicationContext.xml]
INFO 2009-10-21 18:52:07,593 (org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory:427) - Bean factory for application context [org.springframework.web.context.support.XmlWebApplicationContext@ff2413]: org.springframework.beans.factory.support.DefaultListableBeanFactory@1de9ac4
INFO 2009-10-21 18:52:08,138 (org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons:414) - Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@1de9ac4: defining beans [CompoundEventsDwr,DataPointDetailsDwr,DataPointEditDwr,DataSourceEditDwr,DataSourceListDwr,EmportDwr,EventHandlersDwr,EventsDwr,MailingListsDwr,MiscDwr,PointHierarchyDwr,PublisherEditDwr,PublisherListDwr,ReportsDwr,ScheduledEventsDwr,SystemSettingsDwr,UsersDwr,ViewDwr,WatchListDwr,localeResolver,messageSource]; root of factory hierarchy
INFO 2009-10-21 18:52:08,678 (org.springframework.web.context.ContextLoader.initWebApplicationContext:209) - Root WebApplicationContext: initialization completed in 2446 ms
INFO 2009-10-21 18:52:08,681 (com.serotonin.mango.MangoContextListener.contextInitialized:73) - Mango context starting
INFO 2009-10-21 18:52:10,374 (com.serotonin.mango.db.DerbyAccess.initializeImpl:69) - Initializing derby connection manager
INFO 2009-10-21 18:52:17,157 (com.serotonin.mango.db.upgrade.DBUpgrade.checkUpgrade:76) - Starting instance with version 1.7.0
INFO 2009-10-21 18:52:20,505 (org.quartz.simpl.SimpleThreadPool.initialize:258) - Job execution threads will use class loader of thread: main
INFO 2009-10-21 18:52:20,628 (org.quartz.core.SchedulerSignalerImpl.<init>:63) - Initialized Scheduler Signaller of type: class org.quartz.core.SchedulerSignalerImpl
INFO 2009-10-21 18:52:20,630 (org.quartz.core.QuartzScheduler.<init>:215) - Quartz Scheduler v.1.6.3 created.
INFO 2009-10-21 18:52:20,645 (org.quartz.simpl.RAMJobStore.initialize:141) - RAMJobStore initialized.
INFO 2009-10-21 18:52:20,647 (org.quartz.impl.StdSchedulerFactory.instantiate:1224) - Quartz scheduler 'DefaultQuartzScheduler' initialized from default resource file in Quartz package: 'quartz.properties'
INFO 2009-10-21 18:52:20,649 (org.quartz.impl.StdSchedulerFactory.instantiate:1228) - Quartz scheduler version: 1.6.3
INFO 2009-10-21 18:52:20,656 (org.quartz.core.QuartzScheduler.start:461) - Scheduler DefaultQuartzScheduler_$_NON_CLUSTERED started.
INFO 2009-10-21 18:52:23,432 (com.serotonin.mango.rt.RuntimeManager.startDataSource:256) - Data source 'Systeemi' started
INFO 2009-10-21 18:52:25,250 (com.serotonin.mango.rt.RuntimeManager.startDataSource:256) - Data source 'Twido' started
INFO 2009-10-21 18:52:25,699 (com.serotonin.mango.rt.RuntimeManager.startDataSource:256) - Data source 'Virtuaali' started
INFO 2009-10-21 18:52:27,078 (com.serotonin.mango.MangoContextListener.contextInitialized:97) - Mango context started
INFO 2009-10-21 18:52:27,422 (org.springframework.web.servlet.FrameworkServlet.initServletBean:257) - FrameworkServlet 'springDispatcher': initialization started
INFO 2009-10-21 18:52:27,437 (org.springframework.context.support.AbstractApplicationContext.prepareRefresh:412) - Refreshing org.springframework.web.context.support.XmlWebApplicationContext@6adb31: display name [WebApplicationContext for namespace 'springDispatcher-servlet']; startup date [Wed Oct 21 18:52:27 EEST 2009]; parent: org.springframework.web.context.support.XmlWebApplicationContext@ff2413
INFO 2009-10-21 18:52:27,443 (org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions:323) - Loading XML bean definitions from ServletContext resource [/WEB-INF/springDispatcher-servlet.xml]
INFO 2009-10-21 18:52:27,624 (org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory:427) - Bean factory for application context [org.springframework.web.context.support.XmlWebApplicationContext@6adb31]: org.springframework.beans.factory.support.DefaultListableBeanFactory@1424b7b
INFO 2009-10-21 18:52:27,887 (org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons:414) - Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@1424b7b: defining beans [viewResolver,defaultMessageCodeResolver,publicUrlMappings,compoundEventsController,dataPointDetailsController,dataPointEditController,dataSourceEditController,dataSourceListController,emportController,eventHandlersController,eventsController,helpController,loginController,logoutController,mailingListsController,pointHierarchyController,publicViewController,publisherEditController,publisherListController,reportChartController,reportsController,scheduledEventsController,sqlController,systemSettingsController,usersController,viewsController,viewEditController,watchListController,webcamLiveFeedController,multipartResolver,commonData]; parent: org.springframework.beans.factory.support.DefaultListableBeanFactory@1de9ac4
INFO 2009-10-21 18:52:29,527 (org.springframework.web.servlet.FrameworkServlet.initServletBean:276) - FrameworkServlet 'springDispatcher': initialization completed in 2103 ms
INFO 2009-10-21 18:52:29,552 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - DWR Version 2.0.1 starting.
INFO 2009-10-21 18:52:29,568 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - - Servlet Engine: Apache Tomcat/6.0.18
INFO 2009-10-21 18:52:29,570 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - - Java Version: 1.6.0_16
INFO 2009-10-21 18:52:29,572 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - - Java Vendor: Sun Microsystems Inc.
INFO 2009-10-21 18:52:30,392 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Probably not an issue: org.jdom.Document is not available so the jdom converter will not load. This is only an problem if you wanted to use it.
INFO 2009-10-21 18:52:30,403 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Probably not an issue: org.jdom.Element is not available so the jdom converter will not load. This is only an problem if you wanted to use it.
INFO 2009-10-21 18:52:48,071 (com.serotonin.mango.web.filter.LoggedInFilter.doFilter:55) - Denying access to secure page for session id 0FFA1048778DC448535C0A58C3904EBB, uri=/watch_list.shtm
INFO 2009-10-21 18:52:50,642 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.terminateLongPoll()
INFO 2009-10-21 18:53:03,629 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.initializeLongPoll()
INFO 2009-10-21 18:53:03,675 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: WatchListDwr.init()
INFO 2009-10-21 18:53:03,720 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: WatchListDwr.getDateRangeDefaults()
INFO 2009-10-21 18:53:05,301 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.doLongPoll()
INFO 2009-10-21 18:53:10,845 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.resetWatchlistState()
INFO 2009-10-21 18:53:11,762 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.doLongPoll()
INFO 2009-10-21 18:53:12,591 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.doLongPoll()
INFO 2009-10-21 18:53:23,150 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.doLongPoll()
INFO 2009-10-21 18:53:25,915 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: WatchListDwr.setPoint()
ERROR 2009-10-21 18:53:26,059 (com.serotonin.web.dwr.ExceptionDetectionFilter.doFilter:29) - DWR invocation exception
com.serotonin.modbus4j.exception.IllegalDataTypeException: Only binary values can be read from Coil and Input ranges
at com.serotonin.modbus4j.ModbusLocator.validate(ModbusLocator.java:60)
at com.serotonin.modbus4j.ModbusLocator.<init>(ModbusLocator.java:23)
at com.serotonin.modbus4j.ModbusLocator.<init>(ModbusLocator.java:27)
at com.serotonin.modbus4j.ModbusMaster.getValue(ModbusMaster.java:66)
at com.serotonin.modbus4j.ModbusMaster.getValue(ModbusMaster.java:58)
at com.serotonin.modbus4j.ModbusMaster.setHoldingRegisterBit(ModbusMaster.java:388)
at com.serotonin.modbus4j.ModbusMaster.setValue(ModbusMaster.java:170)
at com.serotonin.mango.rt.dataSource.modbus.ModbusDataSource.setPointValue(ModbusDataSource.java:179)
at com.serotonin.mango.rt.RuntimeManager.setDataPointValue(RuntimeManager.java:399)
at com.serotonin.mango.rt.RuntimeManager.setDataPointValue(RuntimeManager.java:384)
at com.serotonin.mango.web.dwr.BaseDwr.setPointImpl(BaseDwr.java:176)
at com.serotonin.mango.web.dwr.BaseDwr.setPoint(BaseDwr.java:166)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.directwebremoting.impl.ExecuteAjaxFilter.doFilter(ExecuteAjaxFilter.java:34)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.mango.util.LocalizationFilter.doFilter(LocalizationFilter.java:52)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.web.dwr.ExceptionDetectionFilter.doFilter(ExceptionDetectionFilter.java:23)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.mango.web.dwr.util.LoggedInAjaxFilter.doFilter(LoggedInAjaxFilter.java:39)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at org.directwebremoting.impl.DefaultRemoter.execute(DefaultRemoter.java:431)
at org.directwebremoting.impl.DefaultRemoter.execute(DefaultRemoter.java:283)
at org.directwebremoting.servlet.PlainCallHandler.handle(PlainCallHandler.java:52)
at org.directwebremoting.servlet.UrlProcessor.handle(UrlProcessor.java:101)
at org.directwebremoting.servlet.DwrServlet.doPost(DwrServlet.java:146)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)
WARN 2009-10-21 18:53:26,089 (org.directwebremoting.util.CommonsLoggingOutput.warn:67) - Method execution failed:
com.serotonin.modbus4j.exception.IllegalDataTypeException: Only binary values can be read from Coil and Input ranges
at com.serotonin.modbus4j.ModbusLocator.validate(ModbusLocator.java:60)
at com.serotonin.modbus4j.ModbusLocator.<init>(ModbusLocator.java:23)
at com.serotonin.modbus4j.ModbusLocator.<init>(ModbusLocator.java:27)
at com.serotonin.modbus4j.ModbusMaster.getValue(ModbusMaster.java:66)
at com.serotonin.modbus4j.ModbusMaster.getValue(ModbusMaster.java:58)
at com.serotonin.modbus4j.ModbusMaster.setHoldingRegisterBit(ModbusMaster.java:388)
at com.serotonin.modbus4j.ModbusMaster.setValue(ModbusMaster.java:170)
at com.serotonin.mango.rt.dataSource.modbus.ModbusDataSource.setPointValue(ModbusDataSource.java:179)
at com.serotonin.mango.rt.RuntimeManager.setDataPointValue(RuntimeManager.java:399)
at com.serotonin.mango.rt.RuntimeManager.setDataPointValue(RuntimeManager.java:384)
at com.serotonin.mango.web.dwr.BaseDwr.setPointImpl(BaseDwr.java:176)
at com.serotonin.mango.web.dwr.BaseDwr.setPoint(BaseDwr.java:166)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.directwebremoting.impl.ExecuteAjaxFilter.doFilter(ExecuteAjaxFilter.java:34)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.mango.util.LocalizationFilter.doFilter(LocalizationFilter.java:52)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.web.dwr.ExceptionDetectionFilter.doFilter(ExceptionDetectionFilter.java:23)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.mango.web.dwr.util.LoggedInAjaxFilter.doFilter(LoggedInAjaxFilter.java:39)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at org.directwebremoting.impl.DefaultRemoter.execute(DefaultRemoter.java:431)
at org.directwebremoting.impl.DefaultRemoter.execute(DefaultRemoter.java:283)
at org.directwebremoting.servlet.PlainCallHandler.handle(PlainCallHandler.java:52)
at org.directwebremoting.servlet.UrlProcessor.handle(UrlProcessor.java:101)
at org.directwebremoting.servlet.DwrServlet.doPost(DwrServlet.java:146)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)
WARN 2009-10-21 18:53:26,101 (org.directwebremoting.util.CommonsLoggingOutput.warn:59) - --Erroring: batchId[8] message[com.serotonin.modbus4j.exception.IllegalDataTypeException: Only binary values can be read from Coil and Input ranges]
INFO 2009-10-21 18:53:27,545 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.doLongPoll()
INFO 2009-10-21 18:53:53,177 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.doLongPoll()
INFO 2009-10-21 18:53:56,648 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: WatchListDwr.setPoint()
ERROR 2009-10-21 18:53:56,667 (com.serotonin.web.dwr.ExceptionDetectionFilter.doFilter:29) - DWR invocation exception
com.serotonin.modbus4j.exception.IllegalDataTypeException: Only binary values can be read from Coil and Input ranges
at com.serotonin.modbus4j.ModbusLocator.validate(ModbusLocator.java:60)
at com.serotonin.modbus4j.ModbusLocator.<init>(ModbusLocator.java:23)
at com.serotonin.modbus4j.ModbusLocator.<init>(ModbusLocator.java:27)
at com.serotonin.modbus4j.ModbusMaster.getValue(ModbusMaster.java:66)
at com.serotonin.modbus4j.ModbusMaster.getValue(ModbusMaster.java:58)
at com.serotonin.modbus4j.ModbusMaster.setHoldingRegisterBit(ModbusMaster.java:388)
at com.serotonin.modbus4j.ModbusMaster.setValue(ModbusMaster.java:170)
at com.serotonin.mango.rt.dataSource.modbus.ModbusDataSource.setPointValue(ModbusDataSource.java:179)
at com.serotonin.mango.rt.RuntimeManager.setDataPointValue(RuntimeManager.java:399)
at com.serotonin.mango.rt.RuntimeManager.setDataPointValue(RuntimeManager.java:384)
at com.serotonin.mango.web.dwr.BaseDwr.setPointImpl(BaseDwr.java:176)
at com.serotonin.mango.web.dwr.BaseDwr.setPoint(BaseDwr.java:166)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.directwebremoting.impl.ExecuteAjaxFilter.doFilter(ExecuteAjaxFilter.java:34)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.mango.util.LocalizationFilter.doFilter(LocalizationFilter.java:52)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.web.dwr.ExceptionDetectionFilter.doFilter(ExceptionDetectionFilter.java:23)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.mango.web.dwr.util.LoggedInAjaxFilter.doFilter(LoggedInAjaxFilter.java:39)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at org.directwebremoting.impl.DefaultRemoter.execute(DefaultRemoter.java:431)
at org.directwebremoting.impl.DefaultRemoter.execute(DefaultRemoter.java:283)
at org.directwebremoting.servlet.PlainCallHandler.handle(PlainCallHandler.java:52)
at org.directwebremoting.servlet.UrlProcessor.handle(UrlProcessor.java:101)
at org.directwebremoting.servlet.DwrServlet.doPost(DwrServlet.java:146)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)
WARN 2009-10-21 18:53:56,680 (org.directwebremoting.util.CommonsLoggingOutput.warn:67) - Method execution failed:
com.serotonin.modbus4j.exception.IllegalDataTypeException: Only binary values can be read from Coil and Input ranges
at com.serotonin.modbus4j.ModbusLocator.validate(ModbusLocator.java:60)
at com.serotonin.modbus4j.ModbusLocator.<init>(ModbusLocator.java:23)
at com.serotonin.modbus4j.ModbusLocator.<init>(ModbusLocator.java:27)
at com.serotonin.modbus4j.ModbusMaster.getValue(ModbusMaster.java:66)
at com.serotonin.modbus4j.ModbusMaster.getValue(ModbusMaster.java:58)
at com.serotonin.modbus4j.ModbusMaster.setHoldingRegisterBit(ModbusMaster.java:388)
at com.serotonin.modbus4j.ModbusMaster.setValue(ModbusMaster.java:170)
at com.serotonin.mango.rt.dataSource.modbus.ModbusDataSource.setPointValue(ModbusDataSource.java:179)
at com.serotonin.mango.rt.RuntimeManager.setDataPointValue(RuntimeManager.java:399)
at com.serotonin.mango.rt.RuntimeManager.setDataPointValue(RuntimeManager.java:384)
at com.serotonin.mango.web.dwr.BaseDwr.setPointImpl(BaseDwr.java:176)
at com.serotonin.mango.web.dwr.BaseDwr.setPoint(BaseDwr.java:166)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.directwebremoting.impl.ExecuteAjaxFilter.doFilter(ExecuteAjaxFilter.java:34)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.mango.util.LocalizationFilter.doFilter(LocalizationFilter.java:52)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.web.dwr.ExceptionDetectionFilter.doFilter(ExceptionDetectionFilter.java:23)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at com.serotonin.mango.web.dwr.util.LoggedInAjaxFilter.doFilter(LoggedInAjaxFilter.java:39)
at org.directwebremoting.impl.DefaultRemoter$1.doFilter(DefaultRemoter.java:428)
at org.directwebremoting.impl.DefaultRemoter.execute(DefaultRemoter.java:431)
at org.directwebremoting.impl.DefaultRemoter.execute(DefaultRemoter.java:283)
at org.directwebremoting.servlet.PlainCallHandler.handle(PlainCallHandler.java:52)
at org.directwebremoting.servlet.UrlProcessor.handle(UrlProcessor.java:101)
at org.directwebremoting.servlet.DwrServlet.doPost(DwrServlet.java:146)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)
WARN 2009-10-21 18:53:56,685 (org.directwebremoting.util.CommonsLoggingOutput.warn:59) - --Erroring: batchId[11] message[com.serotonin.modbus4j.exception.IllegalDataTypeException: Only binary values can be read from Coil and Input ranges]
INFO 2009-10-21 18:53:57,637 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.doLongPoll()
INFO 2009-10-21 18:54:22,271 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.doLongPoll()
INFO 2009-10-21 18:54:26,571 (org.directwebremoting.util.CommonsLoggingOutput.info:51) - Exec: MiscDwr.doLongPoll()Regards Jokke
-
Nice catch. This was a bug in Modbus4J in the WriteMaskRegister failover. I've checked the fix into the CVS repo.