RAK19713 WisLink RAK4630 Quick Start Guide
This section will show you how to install, configure, and start using the RAK19713 WisLink RAK4630 with your device. You will also find links to more in-depth documentation about the AT command set and the custom firmware flashing procedure.
Prerequisites
The following two sections will provide a list of the components and tools you need to get started with the development board. Some of those are included in the package, others you need to provide yourself.
Hardware Tools
- RAK19713 WisLink RAK4630 Module
- Raspberry Pi 3/4 or a Linux PC with USB ports
Software Tools
- RAKPiOS
- picocom for serial communication
- SSH client
Assembly
Follow these simple steps to install the RAK19713 on your host device:
- Power off the host device. Do not change the hardware of the device while on.
- Localte an available Mini PCIe slot with USB interface. On the RAK7391/RAK7393 all 3 Mini PCIe slots have USB interface. A Raspberry Pi hat with MiniPCIe slot does not support USB unless it is also connected via an external USB cable.
- Place the RAK19713 on the slot at a 45 degrees angle and lay it flat while pushing slightly towards the connector. Secure the module in pleace with two screws.
- Connect the antennas pigtails (LoRa and/or BLE) to the module (notice the signals where each antenna should go) and the antenna itself. Use pigtails with the same polarity as the antennas (ether SMA or RP-SMA) and antennas of the right frequency (8XX or 9XX MHz for the LoRa connector, 2.4GHz for the BLE connector).
- Power on the host device and proceed with the next sections on how to configure and use the RAK19713.
Identify the Board
The RAK19713 may not always appear on the same port (for example, /dev/ttyACM0) because Linux enumerates USB devices dynamically on RAKPiOS. To make it easier to identify and access the module, you can create a udev rule that maps the assigned port to a fixed name such as /dev/rak19713 and sets read/write permissions for all users.
- Open a terminal on RAKPiOS (or connect via SSH from another computer) and create a udev rules file by entering the following commands:
cat << EOF > 99-rak19713.rules
ACTION=="add", SUBSYSTEMS=="usb", ATTRS{idVendor}=="239a", ATTRS{idProduct}=="8029", SYMLINK+="rak19713", MODE:="0666"
ACTION=="add", SUBSYSTEMS=="usb", ATTRS{idVendor}=="1915", ATTRS{idProduct}=="521f", SYMLINK+="rak19713", MODE:="0666"
EOF
- Move the newly created file to the udev rules directory with the command:
sudo mv 99-rak19713.rules /etc/udev/rules.d/
- Reload the udev rules and apply them immediately by running:
sudo udevadm control --reload-rules && sudo udevadm trigger
After completing these steps, the RAK19713 will always appear as /dev/rak19713 with read/write permissions for all users.
AT Command Set
By default, the RAK19713 includes RUI3 AT Command Set firmware. It provides a simple serial interface for sending AT commands. These commands configure LoRa P2P and LoRaWAN parameters. AT commands are accessible via USB and BLE.
A complete list of commands is available in the RUI3 AT Command Manual.
Communicate with the Device
Picocom (sudo apt install picocom) can be used to connect to the device, though any serial monitor will work.
The output of the commands below will depend on the actual version of the firmware and might change over time.
Click to view the commands
rak@rakpios:~ $ picocom -b 115200 /dev/rak19713
picocom v3.1
(...)
Type [C-a] [C-h] to see available commands
Terminal ready
AT+VER=RUI_4.2.1_RAK4631
OK
AT+CLIVER=1.5.13
OK
AT+APIVER=3.2.10
OK
AT?
AT+<CMD>?: help on <CMD>
AT+<CMD>: run <CMD>
AT+<CMD>=<value>: set the value
AT+<CMD>=?: get the value
AT+BOOT,R: enter bootloader mode for firmware upgrade
AT+BOOTVER,R: get the version of RUI Bootloader
ATZ,R: triggers a reset of the MCU
ATR,R: restore default parameters
AT+DEBUG,RW: set debug log
ATE,R: show or hide the AT command input
AT+SN,R: get the serial number of the device (max 18 char)
AT+BAT,R: get the battery level (volt)
AT+BUILDTIME,R: get the build time of the firmware
AT+REPOINFO,R: get the commit ID of the firmware
AT+VER,R: get the version of the firmware
AT+FIRMWAREVER,R: get the Customized version of the firmware
AT+CLIVER,R: get the version of the AT command
AT+APIVER,R: get the version of the RUI API
AT+HWMODEL,R: get the string of the hardware model
AT+HWID,R: get the string of the hardware id
AT+ALIAS,RW: add an alias name to the device
AT+SYSV,R: get the System Voltage
AT+BLEMAC,RW: get or set the BLE Mac address
AT+BLEDTM,RW: BLE DTM
AT+SLEEP,W: enter sleep mode for a period of time (ms)
AT+LPM,RW: get or set the low power mode (0 = off, 1 = on)
AT+LPMLVL,RW: get or set the low power mode level
AT+LOCK,R: lock the serial port
AT+PWORD,RW: set the serial port locking password (max 8 char)
AT+BAUD,RW: get or set the serial port baudrate
AT+ATM,R: switch to AT command mode
AT+APPEUI,RW: get or set the application EUI (8 bytes in hex)
AT+APPKEY,RW: get or set the application key (16 bytes in hex)
AT+APPSKEY,RW: get or set the application session key (16 bytes in hex)
AT+DEVADDR,RW: get or set the device address (4 bytes in hex)
AT+DEVEUI,RW: get or set the device EUI (8 bytes in hex)
AT+NETID,RW: get the network identifier (NetID) (3 bytes in hex)
AT+NWKSKEY,RW: get or set the network session key (16 bytes in hex)
AT+MCROOTKEY,RW: get the Mc Root key (16 bytes in hex)
AT+CFM,RW: get or set the confirm mode (0 = off, 1 = on)
AT+CFS,R: get the confirmation status of the last AT+SEND (0 = failure, 1 = success)
AT+JOIN,RW: join network
AT+NJM,RW: get or set the network join mode (0 = ABP, 1 = OTAA)
AT+NJS,R: get the join status (0 = not joined, 1 = joined)
AT+RECV,R: print the last received data in hex format
AT+SEND,W: send data along with the application port
AT+LPSEND,W: send long packet data (max 1000 bytes)
AT+RETY,RW: get or set the number of retransmission of confirm packet data
AT+ADR,RW: get or set the adaptive data rate setting (0 = off, 1 = on)
AT+CLASS,RW: get or set the device class (A = class A, B = class B, C = class C)
AT+DCS,RW: get the ETSI duty cycle setting (0 = disabled, 1 = enabled)
AT+DR,RW: get or set the data rate
AT+JN1DL,RW: get or set the join accept delay between the end of TX and the join RX window 1 in seconds
AT+JN2DL,RW: get or set the join accept delay between the end of TX and the join RX window 2 in seconds
AT+PNM,RW: get or set the public network mode (0 = off, 1 = on)
AT+RX1DL,RW: get or set the delay between the end of TX and the RX window 1 in seconds (1-15)
AT+RX2DL,RW: get or set the delay between the end of TX and the RX window 2 in seconds (2-16)
AT+RX2DR,RW: get or set the RX2 window data rate
AT+RX2FQ,RW: get the RX2 window frequency (Hz)
AT+TXP,RW: get or set the transmitting power
AT+LINKCHECK,RW: get or set the link check setting (0 = disabled, 1 = once, 2 = everytime)
AT+TIMEREQ,RW: request the current date and time (0 = disabled, 1 = enabled)
AT+LBT,RW: get or set the LoRaWAN LBT (support Korea Japan)
AT+LBTRSSI,RW: get or set the LoRaWAN LBT rssi (support Korea Japan)
AT+LBTSCANTIME,RW: get or set the LoRaWAN LBT scantime (support Korea Japan)
AT+PGSLOT,RW: get or set the unicast ping slot periodicity (0-7)
AT+BFREQ,R: get the data rate and beacon frequency (MHz)
AT+BTIME,R: get the beacon time (seconds since GPS Epoch time)
AT+BGW,R: get the gateway GPS coordinate, NetID and GwID
AT+LTIME,R: get the local time
AT+RSSI,R: get the RSSI of the last received packet
AT+ARSSI,R: access all open channel RSSI
AT+SNR,R: get the SNR of the last received packet
AT+MASK,RW: get or set the channel mask to close or open the channel (only for US915, AU915, CN470)
AT+CHE,RW: get or set eight channels mode (only for US915 AU915 CN470)
AT+CHS,RW: get or set single channels mode (only for US915 AU915 CN470)
AT+BAND,RW: get or set the active region (0 = EU433, 1 = CN470, 2 = RU864, 3 = IN865, 4 = EU868, 5 = US915, 6 = AU915, 7 = KR920, 8 = AS923-1 , 9 = AS923-2 , 10 = AS923-3 , 11 = AS923-4 , 12 = LA915)
AT+ADDMULC,W: add a new multicast group
AT+RMVMULC,W: delete a multicast group
AT+LSTMULC,R: view multicast group information
AT+TRSSI,RW: start RF RSSI tone test
AT+TTONE,RW: start RF tone test
AT+TTX,RW: set number of packets to be sent for PER RF TX test
AT+TRX,RW: set number of packets to be received for PER RF RX test
AT+TCONF,RW: configure LoRa RF test
AT+TTH,RW: start RF TX hopping test from Fstart to Fstop, with Fdelta steps
AT+TRTH,RW: start RF TX hopping test from Fstart to Fstop, with Fdelta interval in random sequence
AT+TOFF,RW: stop ongoing RF test
AT+CERTIF,RW: set the module in LoraWAN certification mode (0 = normal mode, 1 = certification mode)
AT+CW,RW: start continuous wave
AT+NWM,RW: get or set the network working mode (0 = P2P_LORA, 1 = LoRaWAN, 2 = P2P_FSK)
AT+PFREQ,RW: configure P2P Frequency (Note:This command will be deleted in the future)
AT+PSF,RW: configure P2P Spreading Factor (5-12)(Note:This command will be deleted in the future)
AT+PBW,RW: configure P2P Bandwidth(LORA: 0 = 125, 1 = 250, 2 = 500, 3 = 7.8, 4 = 10.4, 5 = 15.63, 6 = 20.83, 7 = 31.25, 8 = 41.67, 9 = 62.5 FSK:4800-467000)(Note:This command will be deleted in the future)
AT+PCR,RW: configure P2P Code Rate(0=4/5, 1=4/6, 2=4/7, 3=4/8)(Note:This command will be deleted in the future)
AT+PPL,RW: configure P2P Preamble Length (5-65535)(Note:This command will be deleted in the future)
AT+PTP,RW: configure P2P TX Power(5-22)(Note:This command will be deleted in the future)
AT+PSEND,W: send data in P2P mode
AT+PRECV,RW: enter P2P RX mode for a period of time (ms)
AT+ENCRY,RW: get or set the encryption status of P2P mode
AT+CAD,RW: get or set the Channel Activity Detection status of P2P mode
AT+ENCKEY,RW: get or set the encryption key of P2P mode (16 bytes in hex)
AT+CRYPIV,RW: get or set the encryption IV of P2P mode (16 bytes in hex)
AT+P2P,RW: get or set all P2P parameters
AT+PBR,RW: get or set the P2P FSK modem bitrate (600-300000 b/s)
AT+PFDEV,RW: get or set the P2P FSK modem frequency deviation (600-200000 hz)
AT+IQINVER,RW: get or set P2P IQ inversion (1 = on, 0 = off)
AT+SYNCWORD,RW: get or set P2P syncword (0x0000 - 0xffff)
AT+RFFREQUENCY,RW: get or set P2P Frequency
AT+TXOUTPUTPOWER,RW: get or set P2P Tx Power(5-22)
AT+BANDWIDTH,RW: get or set P2P Bandwidth(LORA: 0 = 125, 1 = 250, 2 = 500, 3 = 7.8, 4 = 10.4, 5 = 15.63, 6 = 20.83, 7 = 31.25, 8 = 41.67, 9 = 62.5 FSK:4800-467000)
AT+SPREADINGFACTOR,RW: get or set P2P Spreading Factor (5-12)
AT+CODINGRATE,RW: get or set P2P Code Rate(0=4/5, 1=4/6, 2=4/7, 3=4/8)
AT+PREAMBLELENGTH,RW: get or set P2P Preamble Length (5-65535)
AT+SYMBOLTIMEOUT,RW: get or set P2P symbolTimeout (0-248)
AT+FIXLENGTHPAYLOAD,RW: get or set P2P fix length payload on/off ( 1 = on, 0 = off)
OK
Flash the New Firmware
Flashing new firmware on the RAK19713 follows the same steps are doing it on a RAK4630. Refer to the RAK19713 Firmware & Flashing guide for the available methods.
Troubleshooting
Device Detection Failure
There are several things you can check if the device is not detected:
- Ensure the device is properly inserted into the slot. Insert it at an angle, then press it flat into the connector. Secure it with screws to keep it in place.
- Verify the system detects the device. If not detected, the issue may be with the slot (no USB interface) or the device.
> sudo dmesg -w
...
[140523.363323] usb 1-1.1: USB disconnect, device number 12
[140527.658064] usb 1-1.1: new full-speed USB device number 13 using xhci_hcd
[140527.782157] usb 1-1.1: New USB device found, idVendor=239a, idProduct=8029, bcdDevice= 1.00
[140527.782170] usb 1-1.1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[140527.782177] usb 1-1.1: Product: WisCore RAK4631 Board
[140527.782182] usb 1-1.1: Manufacturer: RAKwireless
[140527.782187] usb 1-1.1: SerialNumber: 5B6C816B55A14444
[140527.830054] cdc_acm 1-1.1:1.0: ttyACM0: USB ACM device
...
Press [Ctrl+C] to exit the log stream.
Permission Error
If the udev rules are configured correctly, permissions should be set to 0x0666. This allows all users to access the device.
Check if the device appears in the USB subsystem. Look for RAK4631 and take note of its VID and PID values.
rak@rakpios:~ $ lsusb | grep RAK4631
Bus 001 Device 013: ID 239a:8029 Adafruit WisCore RAK4631 Board
If the VID and PID differ, update the udev rules accordingly.
No AT Command Response
The RAK19713 uses default firmware with an AT command interface. If the device is not new or the firmware was changed, reflash the original firmware to restore this feature. Refer to the RAK19713 Firmware & Flashing guide for detailed instructions.
Frequently Asked Questions (FAQs)
How to find the device port?
With udev rules configured, the device appears as /dev/rak19713 in the filesystem.
This file is a symbolic link to the actual device node (for example, /dev/ttyACM0).
Why use udev rules?
udev rules map the device port to a stable identifier such as /dev/rak19713 and configure access permissions.
Without udev rules:
- The device may appear as
/dev/ttyACM0(which can change between reboots) - Access may require membership in the
dialoutgroup
How to send AT commands?
Once the device is ready and the port is known, use a serial terminal at 115200 baud.
Example: picocom -b 115200 /dev/rak19713
Refer to the RUI3 AT Command Manual
