RAK7393 WisGate Connect Outdoor Quick Start Guide
Powering on the Device
The RAK7393 can be powered via 9-36 VDC or PoE (802.3at) through the 1 GB Ethernet port.
Use only one power source (either DC or PoE) at a time. Do not use both simultaneously.
Figure 1: RAK7393 interfacesThe DC connector is a Kway K20-T4, which carries both power and RS485 signals.
Figure 1: Kway K20Flashing the OS
The recommended operating system for the RAK7393 is RAKPiOS. For detailed instructions on flashing and booting the OS, refer to the RAKPiOS documentation.
To set the device in USB Mass Storage mode, move the flash switch to the right (away from the USB Type-C port), then power on the device. Connect the host computer that will be use to flash the binary from to the Flash USB Type C port, and follow the flashing steps described in the documentation. See the image below.
Figure 1: Type-C port and flash switch locationNetwork Connectivity
Connectivity management for the RAK7393 is handled through the NetworkManager tool suite. NetworkManager provides flexible configuration options for Ethernet, Wi-Fi, and Cellular interfaces. It allows creation, editing, activation, and management of network connections either through configuration files or the nmcli command-line tool.
The NetworkManager configuration file must be owned by root, and only root should have read access. Set the permissions using the following commands:
sudo chmod -R 600
/etc/NetworkManager/system-connections/MyConnection.nmconnection
sudo chown -R root:root
/etc/NetworkManager/system-connections/MyConnection.nmconnection
The OS must be rebooted or the gateway power cycled for the configuration changes to take effect.
Ethernet
The gateway features a 1 Gb Ethernet port (eth0). DHCP client is enabled by default on RAKPiOS, so no additional configuration is needed. The assigned IP address can be retrieved via the router interface.
To assign a static IP to the Ethernet interface, create a new connection file named ethernet-eth0.nmconnection in the /etc/NetworkManager/system-connections/ folder with the following contents:
[connection]
id=ethernet-eth0
type=ethernet
interface-name=eth0
[ipv4]
address1=192.168.1.111/24,192.168.1.1
dns=8.8.8.8
method=manual
[ipv6]
addr-gen-mode=stable-privacy
method=auto
Key points:
interface-name=eth0: specifies the network interface to use;eth0(Ethernet) is used in this example.address1=192.168.1.111/24,192.168.1.1: defines the static IP address (192.168.1.111) and gateway (192.168.1.1).dns=8.8.8.8: sets the DNS server (Google’s in this example).
To configure the same using nmcli, run:
sudo nmcli con add type ethernet autoconnect yes ifname eth0 ipv4.addr 192.168.1.111/24 ipv4.gateway 192.168.1.1 ipv4.dns 8.8.8.8 ipv4.method manual
WiFi (WiFi 5)
If the CM4/CM5 module used has built-in Wi-Fi, it supports speeds up to Wi-Fi 5 (IEEE 802.11 b/g/n/ac). Connecting to Wi-Fi is similar to configuring a manual Ethernet connection.
For example, to connect to a hotspot named RAK, create a new connection file named RAK.nmconnection in the /etc/NetworkManager/system-connections/ folder with the following contents:
[connection]
id=RAK
type=wifi
interface-name=wlan0
[wifi]
ssid=RAK
[wifi-security]
auth-alg=open
key-mgmt=wpa-psk
psk=rak20140629
[ipv4]
method=auto
route-metric=100
[ipv6]
addr-gen-mode=stable-privacy
method=auto
interface-name=wlan0: The built-in Wi-Fi interface iswlan0.ssid=RAK: The SSID of the network, in this case, it isRAK.key-mgmt=wpa-psk: Type of authentication, in this casewpa-psk.psk=rak20220922: Password, in this caserak20220922.
Apply and activate the configuration using the following commands:
sudo chown -R root:root /etc/NetworkManager/system-connections/RAK.nmconnection
sudo chmod -R 600 /etc/NetworkManager/system-connections/RAK.nmconnection
sudo nmcli con reload
sudo nmcli con up RAK
Or use the one-line nmcli command:
sudo nmcli device wifi connect RAK if name wlan0 password rak20220922
Cellular
The RAK7393 supports cellular connectivity when paired with the RAK8213 WisLink Cellular mPCIe, a multi-band LTE Cat 4 module. The RAK8213 is based on the Quectel EG95 and features a standard PCI Express® (mPCIe) form factor.
Hardware Setup
Insert the RAK8213 module into the mPCIe #3 on the RAK7393 board. Insert a SIM card that supports Cat 4 or EGPRS into the external SIM slot. Alternatively, some RAK8213 versions include an onboard SIM slot, allowing installation in any mPCIe slot.
Cellular Configuration
Connection File
Create a cellular connection file named gsm.nmconnection in the /etc/NetworkManager/system-connections/ folder with the following contents:
[connection]
id=gsm
uuid=55e9c95e-5947-4dad-9a92-9d409449ba4d
type=gsm
interface-name=cdc-wdm0
permissions=
[gsm]
apn=iot.1nce.net
[ipv4]
dns-search=
method=auto
[ipv6]
addr-gen-mode=stable-privacy
dns-search=
method=auto
[proxy]
Key details:
apn=cmnet: specifies the Access Point Name (APN) for your SIM card's network provider.- After configuration, reboot your board, and the
wwan0interface will obtain an IP address, making it ready for internet connectivity.
interface-name=cdc-wdm0: indicates the interface used.uuid=55e9c95e-5947-4dad-9a92-9d409449ba4d: The UUID, should be provided with the SIM card.apn=iot.1nce.net: Every provider has a specific one, you need to obtain it via their online portal, for example, 1nce is used, which has the APNiot.1nce.net.
After creating the configuration file, reboot or power cycle the gateway for the changes to take effect. If the connection is established successfully, the wwan0 interface will obtain an IP address, which can be verified on the OLED display.
RS485 interface
The RAK7393 includes an external RS485 interface using the DC power connector. This is compatible with RAK's Battery Plus solution, allowing the gateway to monitor battery charging status and capacity.
The interface connects to an internal USB hub using:
- TP8485E (RS485 transceiver)
- CH341 (serial-to-USB converter)
It appears as a USB device, typically mapped to /dev/ttyUSB0. Because Linux USB enumeration is non-deterministic, the port number may vary depending on connected devices.
To help identify the correct port, RAKPiOS creates a symlink at /dev/ttyWB0, but if using a different system we recommend checking the dmesg:
rak@rakpios:~ $ dmesg | grep ch341 | grep attached
[ 5.803708] usb 1-1.4: ch341-uart converter now attached to ttyUSB0
Once you have the port, the battery can be monitored using a simple Python script. Start from this example: https://github.com/RAKWireless/wisblock-python/tree/master/power-supply/rak9155.
