Thales' cellular IoT products business is now part of Telit Cinterion, find out more.

You are here

RS 232 connected on ASC1 | Telit Cinterion IoT Developer Community

May 23, 2014 - 12:04pm, 9611 views

Hello, I have connected one power meter on ASC1 port using RS 232. I write code below to connect meter and read data over using Modbus protocol. String strCOM = "comm:COM1;baudrate=9600;bitsperchar=8;stopbits=1;parity=none;blocking=off;autocts=off;autorts=off"; commConn = (CommConnection)Connector.open(strCOM); inStream = commConn.openInputStream(); outStream = commConn.openOutputStream(); byte[] buffer = new byte[]{}; byte[] frame1 = "here Modbus request"; outStream.write(frame1); outStream.flush(); int available1 = inStream.available(); System.out.println("inStream Available : "+inStream.available()); readBytes = inStream.read(buffer); System.out.println("Read Integer : "+readBytes +" and Bytes size : "+buffer.length); While I run application on ESH6 module then Always get response 0 byte. so My question is how to know meter is connected on ASC1 or not? I mean there is any command to know ASC1 connected to meter. I want to check my code to send request to meter or not. So I can figer out my code is wrong or module not request to meter. I have read java_user_guide pdf file. I have write command AT^SCFG? but i can not understand response. see below response. at^scfg? ^SCFG: "Call/ECC","0" ^SCFG: "GPRS/AutoAttach","enabled" ^SCFG: "Gpio/mode/ASC1","std" ^SCFG: "Gpio/mode/DAI","gpio" ^SCFG: "Gpio/mode/DCD0","std" ^SCFG: "Gpio/mode/DSR0","std" ^SCFG: "Gpio/mode/DTR0","std" ^SCFG: "Gpio/mode/FSR","gpio" ^SCFG: "Gpio/mode/HSIC","rsv" ^SCFG: "Gpio/mode/PULSE","gpio" ^SCFG: "Gpio/mode/PWM","gpio" ^SCFG: "Gpio/mode/RING0","std" ^SCFG: "Gpio/mode/SPI","rsv" ^SCFG: "Gpio/mode/SYNC","gpio" ^SCFG: "Ident/Manufacturer","Cinterion" ^SCFG: "Ident/Product","EHS6" ^SCFG: "MEShutdown/Fso","0" ^SCFG: "MEopMode/SoR","off" ^SCFG: "Radio/Band","511" ^SCFG: "Radio/OutputPowerReduction","4" ^SCFG: "Serial/Interface/Allocation","1","1" ^SCFG: "Serial/USB/DDD","0","0","0409","1E2D","0058","Cinterion Wireless Modules","EHx","" ^SCFG: "Tcp/IRT","3" ^SCFG: "Tcp/MR","10" ^SCFG: "Tcp/OT","6000" ^SCFG: "Tcp/WithURCs","on" ^SCFG: "Trace/Syslog/Otap","0" ^SCFG: "URC/Ringline","local" ^SCFG: "URC/Ringline/ActiveTime","2" ^SCFG: "Userware/Autostart","1" ^SCFG: "Userware/Autostart/Delay","0" ^SCFG: "Userware/DebugInterface","0.0.0.0","0.0.0.0","0" ^SCFG: "Userware/DebugMode","on" ^SCFG: "Userware/Passwd", ^SCFG: "Userware/Stdout","null",,,,"off" ^SCFG: "Userware/Watchdog","0" Help me Please. Thank you