Yifan M240 V4 Series User manual

M240 V4 Series IP MODEM User Manual
/ 35
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
1
M240 V4 Series IP MODEM
User Manual
This user manual is suitable for the following model:
Xiamen Yifan Communication Technology Co., Ltd.
Add:Floor 14th, No.370, Chengyi Street, Jimei District,
XiaMen, China Zip Code: 361000
Tel:+86 592-6101492
Fax: +86 592-5222813
http://www.yifanwireless.com
M240 V4 Series IP
MODEM User Manual
Version
V1.0.0
Product Name:M240 V4
Total
page36
Modem
Product Type
M240-G V4
GPRS IP MODEM
M240-L V4
CAT4 LTE IP MODEM
M240-L1 V4
Cat1 IP MODEM
M240-LG V4
GPS+LTE IP MODEM

M240 V4 Series IP MODEM User Manual
/ 35
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
2
Files Revised Record
Date
Version
Remark
Author
2021-07-30
V1.0.0
Original
ZDM

M240 V4 Series IP MODEM User Manual
/ 35
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
3
Copyright Notice
All contents in the files are protected by copyright law, and all copyrights are reserved by
Xiamen Yifan Communication Technology Co., Ltd.
Without written permission, all commercial use of the files from Yifan are forbidden, such
as copy, distribute, reproduce the files, etc., but non-commercial purpose, downloaded or
printed by individual (all files shall be not revised, and the copyright and other
proprietorship notice shall be reserved) are welcome.
Trademark Notice
Yifan and Yeacomm are all registered trademarks of Xiamen Yifan Communication
Technology Co., Ltd., illegal use of the name of Yifan, trademarks and other marks of
Yifan is forbidden, unless written permission is authorized in advance.

M240 V4 Series IP MODEM User Manual
/ 35
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
4
Note:There may be different components and interfaces in different model,please in kind prevail.

M240 V4 Series IP MODEM User Manual
/ 35
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
5
Contents
Chapter 1 Brief Introduction of Product.......................................................................................6
1.1General...............................................................................................................................6
1.2 Features and Benefits..........................................................................................................7
1.3 Working Principle.............................................................................................................8
1.4 Specifications ...................................................................................................................8
Chapter 2 Installation Introduction.............................................................................................10
2.1 General............................................................................................................................10
2.2 Encasement List ............................................................................................................10
2.3 Installation and Cable Connection..............................................................................10
2.4 Power...............................................................................................................................12
2.5 Indicator Lights Introduction.........................................................................................13
Chapter 3 Configuration..............................................................................................................14
3.1 Connection......................................................................................................................14
3.2 Configuration Introduction............................................................................................14
3.3 IP Modem’s Parameters Configuration ..........................................................................15
3.3.1 Run the Configure Tools ........................................................................................15
3.3.2 Re-Power IP Modem..............................................................................................16
3.3.3 Work Mode.............................................................................................................16
3.4 Data Service Center Settings.....................................................................................23
3.5 Serial port..................................................................................................................26
3.6 IO function................................................................................................................27
3.7 Dial............................................................................................................................28
3.8 Global Parameters.....................................................................................................30
3.9 Device Manage .........................................................................................................31
3.10 Operation.................................................................................................................32
Chapter 4 Application Case .........................................................................................................33
4.1 Modem connect to data center ..........................................................................................33
4.2 SMS to Configure Modem................................................................................................34

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
6/ 35
Chapter 1 Brief Introduction of Product
1.1General
M240 V4 Series IP MODEM is a kind of cellular terminal device that provides data transfer by
public cellular network.
It adopts high-powered industrial 32 bits CPU and embedded real time operating system. It
supports RS232 and RS485 port that can conveniently and transparently connect one device
to a cellular network, allowing you to connect to your existing serial devices with only basic
configuration. It has low power consumption design; provides 2 ADC, 3 I/O, be compatible
digital I/O channel, ADC, input pulse counter and pulse wave output function.
It has been widely used on M2M fields, such as intelligent transportation, smart grid, industrial
automation, telemetry, finance, POS, water supply, environment protection, post, weather, and
so on. Typical application topology is showed in Figure 1-1.
Figure 1-1 IP MODEM Application Topology

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
7/ 35
1.2 Features and Benefits
Design for Industrial Application
High-powered industrial cellular module
High-powered industrial 32 bits CPU
Support low power consumption mode, including multi-sleep and trigger modes to reduce
the power consumption
Housing: iron, providing IP30 protection.
Power range: DC 5~36V
Stability and Reliability
Support hardware and software WDT
Support auto recovery mechanism, including online detect, auto redial when offline to
make it always online
RS232/RS485 port: 15KV ESD protection
SIM/UIM port: 15KV ESD protection
Power port: reverse-voltage and overvoltage protection
Antenna port: lightning protection(optional)
Standard and Convenience
Adopt terminal block interface, convenient for industrial application
Support standard RS232 and RS485(RS422 optional) port that can connect to serial
devices directly
TTL logic level RS232 interface can be customized
Support intellectual mode, enter communication state automatically when powered
Provide management software for remote management
Support several work modes
Convenient configuration and maintenance interface
High-performance
Support TCP server and support multi TCP client connection(optional)
Support double data centers, one main and another backup
Supply 5 I/O channels, support 3 digital input/output(can customize to be pulse counting)
and 2 ADC channels (4~20mA current input, can customize to support voltage input).
Support multi data centers and it can support 5 data centers at the same time
Support multi online trigger ways, including SMS, ring and data
Support domain name and IP address as data center
Design with standard TCP/IP protocol stack
Support private APN

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
8/ 35
1.3 Working Principle
The principle chart of the IP MODEM is showed in Figure 1-2:
Figure 1-2 IP MODEM Principle Chart
1.4 Specifications
Hardware System
Item
Content
CPU
Industrial 32 bits CPU
FLASH
1MB
SRAM
256KB
ADC
12-bit
Interface
Item
Content
Serial
1 RS232 and 1 RS485, 15KV ESD protection.
Data bits: 5, 6 ,7, 8
Stop bits: 1, 1.5, 2
Parity: none, even, odd, space, mark
Baud rate: 1200~230400 bps
Indicator
"Power", "ACT", "Online"
Antenna
Cellular: Standard SMA female interface, 50 ohm
Lighting protection(optional)
SIM/UIM
Standard 3V/1.8V user card interface, 15KV ESD protection
Power
Terminal block interface, reverse-voltage and overvoltage protection
Cellular
Module
MCU
Antenna
SIM/UIM
Interface
Indicator
Lights
SRAM&
FLASH
WDT Module
RTC Module
User Interface
RS232/RS485/RS422
Module
Power Module

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
9/ 35
Note:There may be different components and interfaces in different model,please in kind
prevail.
Power Input
Item
Content
Standard
DC 12V/0.5A
Power Range
DC 5~36V
Power Consumption (Communication power consumption differs from different
modules)
Working Status
Power Consumption
Communication
20~80mA@12VDC
Standby
15~30 mA@12VDC
Sleep
1mA@12VDC
Physical Characteristics
Item
Content
Housing
Iron, providing IP30 protection
Size
91x58.5x22 mm (Antenna and Accessories are not included)
Weight
205g
Others
Item
Content
Operating
Temperature
-35~+75ºC (-22~+167℉)
Storage
Temperature
-40~+85ºC (-40~+185℉)
Operating
Humidity
95%( Non-condensing)

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
10 / 35
Chapter 2 Installation Introduction
2.1 General
The IP MODEM must be installed correctly to make it work properly.
Warning: Forbid to install the IP MODEM when powered!
2.2 Encasement List
Name
Quantity
Remark
IP MODEM host
1
Cellular Antenna
1
Power adapter
1
RS232 data cable
1
(Or RS485 cable)
Manual CD
1
Certification card
1
Maintenance card
1
2.3 Installation and Cable Connection
Dimension: (unit: mm)
Installation of SIM/UIM card
Firstly power off the IP MODEM, and press the button of the SIM/UIM card outlet with a needle
object. Then the SIM/UIM card sheath will flick out at once. Put SIM/UIM card into the card

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
11 / 35
sheath (Pay attention to put the side which has metal point outside), and insert card sheath
back to the SIM/UIM card outlet.
Warning: Forbid to install SIM/UIM card when powered!
Installation of antenna
Screw the SMA male pin of the antenna to the female SMA outlet of the IP MODEM tightly.
Warning: The antenna must be screwed tightly, or the signal quality of antenna will be
influenced!
User Interface Signal Definition
Pin NO.
Name
Function
Extensible Function
1
PWR
Power input
anode
N/A
2
GND
Power Ground
N/A
3
GND
System Ground
N/A
4
RX
RS232 RX
N/A
5
TX
RS232 TX
N/A
6
A
RS485 anode
N/A
7
B
RS485 cathode
N/A
8
IO1
GPIO
Reserved compatible pulse
wave input counter, ADC, and
pulse output
9
IO2
GPIO
Reserved compatible pulse
wave input counter, ADC, and
pulse output
10
IO3
GPIO
Reserved compatible pulse
wave input counter, ADC, and
pulse output
11
ADC1
ADC
N/A
12
ADC2
ADC
N/A

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
12 / 35
Installation of cable
M240 V4 adopts industrial terminal block interface, the recommendatory cable is 28-16AWG.
Adapter(Rating Output 12VDC/0.5A)
Cable Color
Power Output Polarity
Black&White
Anode
Black(with letters)
Cathode
RS232 Cable
Cable Color
DB9-M Pin Number
Brown
Pin 2
Blue
Pin 3
Black
Pin 5
RS485 Cable(optional)
Cable Color
Signal definition
Red
RS485(A)
Black
RS485(B)
Power adapter and communication cable connection
2.4 Power
The power range of the IP MODEM is DC 5~36V
We recommend user to use the standard DC 12V/0.5A power adaptor.
Warning: When we use other power, we should make sure that the power can supply power
above 6W.(Ripple is less than 300mV, and ensure that the instantaneous voltage does not
exceed 36V)
M240 V4
M240 V4
User(DB9
male)
User
1
2
3
4
5
6
7
8
9
10
11
12
RX
GND
TX
A
B
IO1
IO2
IO3
ADC1
PWR
GND
ADC2
1
2
3
4
5
6
7
8
9
GND
TX
RX
+Power +
-Power -
RX
111
11
1
2
3
4
5
6
7
8
9
10
11
12
RX
GND
TX
A
B
IO1
IO2
IO3
ADC1
PWR
GND
ADC2
+Power +
-Power -
A
B
RS232
RS485

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
13 / 35
2.5 Indicator Lights Introduction
The IP MODEM provides three indicator lights: “Power”, “ACT”, “Online”.
Indicator
Status
Introduction
Power
off
IP MODEM is powered off
on
IP MODEM is powered on
ACT
off
No data communication
Blink
Data is communicating
Online
off
IP MODEM hasn’t logged on network
on
IP MODEM has logged on network

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
14 / 35
Chapter 3 Configuration
3.1 Connection
Before configuration, It’s necessary to connect the IP MODEM with the PC by the shipped
RS232 or RS232-485 conversion cable as following.
3.2 Configuration Introduction
There are two ways to configure the IP MODEM:
Configuration software tool:
All the settings are configured through the shipped software tool.
It’s necessary to have one PC to run this tool.
Extended AT command:
All the settings are configured through AT command, so any device with serial port can
configure it.
Before configuration with extended AT command, you should make IP MODEM enter
configure state.
The steps how to make IP MODEM enter configure state, please refer to appendix.
The following describes how to configure IP MODEM with the configure software tool. At the
same time, it gives out the corresponding AT command of each configuration item.

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
15 / 35
3.3 IP Modem’s Parameters Configuration
There are data settings in HEX format in the parameters,
for the HEX format, the data must be hexadecimal characters, and the number of characters
cannot be an odd number.
For example, "12AB" is in the correct format
"12A" format error, the number of characters is odd
"12G" format error, non-hexadecimal character
3.3.1 Run the Configure Tools
The “Serial” area shows the current serial port settings.
To configure IP MODEM, please choose the correct serial port which connects to IP MODEM,
and the baud-rate is 115200 with no parity, then open the serial port. If the button text is“Close”,
it shows the serial port now has been opened.
If the text is “Open”, you should open the port first.
When the port opened, the “Output Info” column will display:
“Port(COM1) Has Opened,Please Re-Power the IP MODEM,
Waiting IP MODEM Enter Configure State...”

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
16 / 35
3.3.2 Re-Power IP Modem
After Re-power IP MODEM, The configure tool will make it enter configure state.
At the same time, the software will load current settings from IP MODEM and displays on the
right configure columns. It’s now ready to configure.
Note:To enter configure state for 4G device may need more time. It is about 40 seconds.
3.3.3 Work Mode
3.3.3.1 App protocol
The IP Modem can be configured many communication protocols to adapt for different
applications.
Note:The tool will show the reference parameters according to the communication protocols
setting.
PROT
It uses TCP Protocol to send or receive data. In this mode, ID and phone number MUST be
set.

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
17 / 35
Device ID
ID number for the device. 8 characters
Phone No.
Phone number
Character
Escapes
This item is only valid when the Work Mode is PROT. If this item is set
to No, IP MODEM will transfer meaning to 0xfd and 0xfe. To know detail
transfer meaning method, please refer “IP MODEM Transfer Meaning
Explanation In the PROT work mode”. If this item is set to Yes, all the
transmission is transparent.
DCTCP
This protocol is used in electric power field, with TCP protocol.
PhoneNo.
Phone number
DCUDP
This protocol is used in electric power field, with UDP protocol
PhoneNo.
Phone number
TRNS
The device work as MODEM for sending/receiving SMS, CSD and GPRS dialing.
SMSCLI
IP MODEM work as a SMS DTU. All data will send to binding phone number via SMS. The

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
18 / 35
SMS from the binding phone number will send to Serial port.
Pone No 1st Group
Pone No 2nd Group
Pone No 3rd Group
Pone No 4th Group
Pone No 5th Group
Bind phone number. Max phone number is 5 for one group
Show Phone Number
If send phone number to serial port or not
Hex To Text
If convert HEX data to ASCII data or not
Send SMS Hex
If send SMS with Hex format or not
SMSSER
IP MODEM work as a SMS DTU. All the data paced with special format send to any phone
number. The SMS from phone number will send to serial port.
Show Phone Number
If send phone number to serial port or not
Hex To Text
If convert HEX data to ASCII data or not
Send SMS Hex
If send data with Hex format or not
HTTP
When IP modem connected to the HTTP server address, serial port data will be packeted with
Http format and sent to server.

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
19 / 35
HTTP Request Mode
Can select GET and POST Mode
MTCP/MRTU
IP MODEM will convert data from Modbus TCP to modbus RTU when recieve data from
server,also will convert data from Modbus RTU to Modbus TCP when sending data to server
via the serial port in device.
Device ID
ID number for the device. 8 characters
Hex To Text
If convert HEX data to ASCII data or not
Send SMS Hex
This item is only valid when the Work Mode is PROT. If this item is
set to No, IP MODEM will transfer meaning to 0xfd and 0xfe. To
know detail transfer meaning method, please refer “IP MODEM
Transfer Meaning Explanation In the PROT work mode”. If this item
is set to Yes, all the transmission is transparent.
MQTT
IP MODEM will work as MQTT client,when configured and connected to MQTT server,it can
communicate with other MQTT client.(you can check the test guide in the appendix.)
Client ID
ID of MQTT client,can be Configured to the required string
User name and
The usename and password of server(if need)

M240 V4 Series IP MODEM User Manual
Add:Floor 14,A06 building, No.370,Chengyi Street,Jimei District, Xiamen,China.
Web: www.yifanwireless.com Hotline:+86 592 6101492 Fax:+86 592 5222813
20 / 35
password
Receive Topic
It should be configured with the send topic of another client
Send Topic
It should be configured with the recieve topic of another client
Custom protocol:Client mode
It support TCP and UDP protocol with custom heart and login packet.
Base Protocol
TCP or UDP
DeviceMode
Client Mode: the IP Modem work as a client.
Login&Heartbeat
Enable: custom login and heart packet
Disable: no login and heart packet. The flowing items can be
ignored.
Data Format
Text: the flowing items are Text format
Hex:the flowing items are Hex format
Login Packet
Login packet
Login Reply
Login packet respond
Heartbeat Packet
Heart packet
Heartbeat Reply
Heartbeat packet respond
Custom protocol:Server mode
It supports TCP and udp server.
Base Protocol
TCP or UDP
Listen Port
Listen port for service
3.3.3.2 Trigger mode
Normally, IP MODEM always keeps online and always be ready for data transmission. But in
some circumstances, it’s important to reduce wireless data flow. To realize this function, the
This manual suits for next models
4
Table of contents
Other Yifan Modem manuals