Marvell Consultants now has a great deal of experience designing with the RAK4260. This neat little 15mm-square screened module incorporates Atmel/Microchip's SAMR34J18B SiP. The R34 SiP in turn comprises an ATSAML21J18B ultra-low-power CotexM0+ processor plus a LoRa compatible UHF transceiver. This part offers an unbeatable combination of low-power, low-cost, small-size & high-performance currently available for the heart of any LoRaWAN node. Unfortunately it has a couple of drawbacks: it's available only in BGA packaging and there's a significant amount of external RF circuitry required around the antenna. Both these issues are swept away by RAK's excellent 4260 module which embeds the SAMR34, all its associated RF circuitry and two XTAL oscillators.
Sadly RAK did not adopt the same GPIO usage as on Atmel/Microchip's SAMR34 Xplained board. This means that none of the example software on Microchip's SAMR34 web-site will work out-of-the-box - check-out PB03, PA28, and PA09. RAK's one piece of example code is a copy of Microchip's but with some quick and dirty modifications to fix the incompatibilities. It's available to clone from github via a link on their 'Quick-Start' -> 'Burning the Firmware' guide and runs on their 4260 eval board, see below. Documentation for RAK's evaluation board is currently rather sketchy. Here's a random list of some of the things I've learned so far:
UPDATE:Feb2021: Microchip have recently launched their own very similar SAMR34-based radio module, the WLR089U0 - same price-level, performance and dimensions - available at MicrochipDirect from March 2021
J-link pin Signal J4 pin RAK4260 pin ---------- ------- ------ ----------- 7 SWDATA 2 31 9 SWDCLK 3 30 1 Vdd 1 11,12 4,6,8 etc GND 4 10,18,28,36 etc 15 RESET 5* 29 * Older modules may not have a J4p5, in which case wire direct to Module pin 29 Alternatively see our J-link adapter board below
#define FEATURES_SUPPORTED_EU (DUTY_CYCLE_SUPPORT | PA_SUPPORT)
In file: APPS_ENDDEVICE_DEMO1\src\ASF\thirdparty\wireless\lorawan\hal\src\radio_driver_hal.c edit these two existing functions like so: void HAL_TCXOPowerOn(void) { port_pin_set_output_level(TCXO_PWR_PIN, TCXO_PWR_ACTIVE); port_pin_set_output_level(RFSW_PWR_PIN, RFSW_PWR_ACTIVE); // also enable RF switch delay_ms(RADIO_CLK_STABILITATION_DELAY); } void HAL_TCXOPowerOff(void) { port_pin_set_output_level(TCXO_PWR_PIN, TCXO_PWR_INACTIVE); port_pin_set_output_level(RFSW_PWR_PIN, RFSW_PWR_INACTIVE); // also disable RF switch }
For some time I struggled with down-link reliability - from gateway to node.
Some correspondents also see this but others do not.
It becomes especially troublesome when using CONFIRMED mode transmission because many re-trys can be consumed
trying to get the confirmation packet through - this of course eats away at the node's energy budget.
The problem has been solved by:
The up-side being that it all lead to the development of very robust node-side application code (see below).
We designed this little board to facilitate in-system programming of RAK4260 modules without the need for any on-board JTAG/SWD support. With this board up your sleeve you'll be able to make super-small nodes with no SWD connector or infrastructure. The board uses a 20-pin pin-header to connect to an old-style J-link box and 9 pogo pins to locate onto the 4260 module. Four links are provided for enabling pull-up resistors on the signal pins as required. Eg the datasheet states that a 1K pull up is mandatory on SWCLOCK. Design files available below. Pins: Multicomp p/n P50-B-120-G, Farnell:1568260.
We now have a design for a LoRa node that interfaces to any 4-20mA sensor unit eg water depth, IR temperature etc. Featuring:
Contact us for details.
Gerber file pack for our J-link to RAK4260 adapter PCB We highly recommend JLCPCB.com PCB manufacturer. RAK Store RAK's 4260 Schematics etc RAK's 4260 'Datasheet' RAK's 4260 Quick start RAK's 4260 GitHub Atmel/Microchip SAMR34 pages Check out our LoRa Gateway project here Download our open-source Studio7 example project for the Node20mA here Download our open-hardware Node20mA node hardware: Gerber_files, BOM, Schematic