1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 <2016> 2017 2018 2019 2020 2021 2022 2023 2024 2025 | Index | 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 <2016> 2017 2018 2019 2020 2021 2022 2023 2024 2025 |
<== Date ==> | <== Thread ==> |
---|
Subject: | RE: Question about the connection refused |
From: | lzfneu <[email protected]> |
To: | "[email protected]" <[email protected]>, "[email protected]" <[email protected]> |
Date: | Fri, 25 Mar 2016 04:22:29 +0000 |
Hi Mark, Actually, I need to read the dose rate from a radiation monitor counter by using epics. I installed the asyn4-29 and modbusR2-8 packages. As a new user in epics, I edited the modbus ioc example in iocTest folder and the file named Koyo1.cmd: I changed the IPaddress to the actual IPaddress of radiation monitor counter. drvAsynIPPortConfigure ("Koyo1","192.168.1.125:502",0,0,1) after starting the ioc: > $ modbusApp Koyo1.cmd the first error occurs in command: # write 32 bits (Y0-Y37). Function code = 5 drvModbusAsynConfigure("K1_Yn_Out_Bit", "Koyo1", 0, 5, 04000, 040, 0, 1, "Koyo") 2016/03/25 11:33:29.067 drvModbusAsyn::doModbusIO port K1_Yn_Out_Bit error calling writeRead, error =192.168.1.235:502 timeout: Resource temporarily unavailable, nwrite=6/6, nread=0 and the sequenct errors were: # Write 8 words (128 bits). Function code=6. drvModbusAsynConfigure("K1_Yn_Out_Word", "Koyo1", 0, 6, 040500, 010, 0, 100, "koyo") drvModbusAsyn 2016/03/25 11:33:34.073 drvModbusAsyn::doModbusIO port K1_Xn_Bit error calling writeRead, error=192.168.1.125:502 timeout: Resource temporarily unavailable, nwrite=6/6, nread=0 2016/03/25 11:33:39.078 drvModbusAsyn::doModbusIO port K1_Xn_Word error calling writeRead, error=192.168.1.125:502 timeout: Resource temporarily unavailable, nwrite=6/6, nread=0 2016/03/25 11:33:44.084 drvModbusAsyn::doModbusIO port K1_Yn_In_Bit error calling writeRead, error=192.168.1.125:502 timeout: Resource temporarily unavailable, nwrite=6/6, nread=0 I have to stop the output in the terminal window. I performed the ping 192.168.1.125:502 command and found that the computer and radiation monitor counter connected well. It seems the read and write error occurs when they communicate with each other. I am confused and really don't know how to do next. Could you plesase help me and thanks in advance. Best regards, Zhefu > From: [email protected] > To: [email protected]; [email protected] > Subject: RE: Question about the softioc connection refused ? > Date: Sat, 19 Mar 2016 12:55:02 +0000 > > Hi Zhefu > > > I edited the Koyo1.cmd file to change the ip address in function with two conditions: > > 1) drvAsynIPPortConfigure("Koyo1","127.0.0.1:5065",0,0,1) > > where 127.0.0.1:5065 is my localhost ip address. > > This is not correct. You have specified port 5065 for the drvAsynIPPort driver that is supposed to connect to a Modbus server. Port 5065 is not used for Modbus, it is used for EPICS channel access. > > You cannot run the test application in the Modbus directory unless you actually have a Modbus server that you can connect to. Do you actually have a Modbus server? If so, then you specify its IP address and port 502 in the drvAsynIPPortConfigure command. > > Mark > > > ________________________________ > From: [email protected] [[email protected]] on behalf of lzfneu [[email protected]] > Sent: Saturday, March 19, 2016 7:26 AM > To: [email protected] > Subject: Question about the softioc connection refused ? > > hi, > > I have encountered another softioc connection problem: > > I have insatlled modbus-R2-8, and want to run test example (file named Koyo1.cmd) in the iocTest folder. > > I edited the Koyo1.cmd file to change the ip address in function with two conditions: > > 1) drvAsynIPPortConfigure("Koyo1","127.0.0.1:5065",0,0,1) > where 127.0.0.1:5065 is my localhost ip address. > > 2) drvAsynIPPortConfigure("Koyo1","192.168.1.255:5065",0,0,1) > where 192.168.1.255:5065 is my broadcast ip address that obtained by command ifconfig. > > after starting the ioc: > $ modbusApp Koyo1.cmd > > the results are both two ip address cannot connect the Koyo1, the error messages are shown below: > > 1) drvAsynIPPortConfigure("Koyo1","127.0.0.1:5065",0,0,1) > 2016/03/19 19:40:19.158 Can't connect to 127.0.0.1:5065: Connection refused Koyo1 -1 autoConnect could not connect > > 2) drvAsynIPPortConfigure("Koyo1","192.168.1.255:5065",0,0,1) > 2016/03/19 20:19:49.083 Can't connect to 192.168.1.255:5065: Network is unreachable Koyo1 -1 autoConnect could not connect > > I am new in epics, could you plesase help me and thanks in advance. > > Best regards > > Zhefu > |