-
Choosing a LoRaWAN module
12/08/2021 at 10:20 • 0 commentsIf your electronics projects needs to talk to other devices, but you don't have access to WiFi, LoRaWAN is a great alternative. The Things Network (TTN) is a global collaborative Internet of Things ecosystem which allows devices to use the network for free. No payment or SIM cards are required like with NB-IoT or Helium, you just need to keep to the usage limits.
The problem is that there are very limited options for LoRaWAN modules, given the current global chip shortage. As I'm based in the UK, I'm looking specifically for 868MHz modules to use with the OpenAirMonitor.
The RN2483 LoRaWAN module from Microchip used to be the de facto option when you don't want to run a LoRaWAN stack on your microcontroller. Unfortunately they are out of stock until 2022 or later. Luckily there are other options, so let's have a look at what's out there.
RAK3172
RAK Wireless has a range of LoRaWAN modules where different microcontrollers are combined with LoRa chips. The RAK3172 is their first module that uses the STM32WL, combining a microcontroller and LoRa on the same chip. It comes preinstalled with a LoRaWAN stack, so you can use it with your own microcontroller over a UART interface.LoRa-E5
Seeed Studio's LoRa-E5 module also uses the STM32WL chip, and is also controlled over a UART interface if you use the preinstalled stack.Unfortunately both the RAK and Seeed modules suffer from a high transmit power consumption bug, which look like it may not be able to fix in firmware without reducing the range significantly.
Ra-07H
Ai-Thinker's Ra-07H uses the ASR6501 chipset which also combines a LoRa transceiver with a microcontroller, and can also be controlled over a UART interface.E78
Ebyte's E78 module is also based on the ASR6501 chipset. It appears that both the Ra-07H and E78 modules are compatible with TTN v3.There are other LoRaWAN modules out there, like Move Solutions' STM32WL-based MAWLE-C1, but the ones above are ones that were actually in stock at the time of writing.
In the end I went with Seeed Studio's LoRa-E5 module, as they have a range of different promotions going on at the moment and I intended to make use of their Fusion PCB Assembly Service. I bought my first batch of LoRa-E5 modules directly from their web shop, and they arrived relatively quickly.
For my first prototype PCB I used JLCPCB's assembly service, but had to solder the LoRa-E5 module and the MDBT42Q module myself, as they're not in JLCPCB's SMT parts library. For my second prototype revision I used Seeed's Fusion assembly service, as they currently have an offer for two free PCBA boards if it contains a LoRa-E5. I thought it was too good to be true, but I literally didn't have to pay anything to get the two prototype boards, including all the components.
During the design check they even found a footprint issue that wasn't discovered during the first prototype run, and where parts were out of stock they worked with me to find suitable alternatives. The only part that we couldn't find an alternative for was the MDBT42Q, for which there was no stock in the entire mainland of China. Luckily I had modules on hand, so had the board manufactured without the module and soldered it on myself.
-
Working on the enclosure
10/26/2021 at 13:02 • 0 commentsThe enclosure design is slowly coming to an end. Who knew that it would be so much work making a plastic box to put something in? The idea is that this enclosure will be mounted on the bottom of the solar panel, so that only the solar panel itself (on a mounting plate) needs to be connected to a lamp post.
-
Choosing a battery charger chip
10/22/2021 at 09:00 • 0 commentsWith the current global chip shortage it can be challenging to find the right chip for your project that's actually in stock. I want to share some of my own challenges and what the options are. First up: What LiPo battery charger chips can be used with solar panels?
BQ24074
I first came across Texas Instrument's BQ24074 while looking at Adafruit's Universal USB / DC / Solar LiPo charger, which replaced their earlier MCP73781-based charger. It's relatively inexpensive ($0.81) and has an input voltage of up to 10V. Unfortunately this chip was out of stock when I ordered my board for SMT assembly, so I had to consider alternatives.
LT3652
Analog Device's LT3652 is used in Sparkfun's Sunny Buddy (MPPT Solar Charger), but it's a lot more expensive (around $5) than other chips and was also out of stock at the time of ordering.
CN3065 / CN3063
Consonance Electronic's CN3065 is used in Seeed Studio's LiPo Rider boards, as well as many low-cost solar battery charger boards on eBay. It's even cheaper than the BQ24074 at around $0.50, and it was available in its SOP8 package version CN3063 at JLCPCB when I placed my order. While it has been working great so far, it only has an input voltage of 6V, which could cause issues if you get high peak voltages on your solar panel over an extended period of time.
-
Completed PCB design, working on the enclosure
10/15/2021 at 10:53 • 0 commentsSo what's the current state of the OpenAirMonitor? I've completed the hardware design and schematics, manufactured a rev 1 of the PCB with JLCPCB, and then made the following fixes:
- a floating pin on the LDO that's now grounded
- replaced the LDO with a AZ1117CR2 as the HT7333-A is underpowered.
- I've also changed the STEMMA pins as rev 1's pins are also used for NFC
- moved the PMS7003 connector as it wasn't correctly aligned with the sensor location
I haven't yet ordered a rev 2, as it was easy enough to fix the rev 1 PCBs by replacing the LDO and putting a bodge wire to ground. I also found a way to use pins D9 and D10 on the MDBT42Q module by disabling NFC in the Espruino CLI:
NRF.disconnect(); setTimeout(function() { NRF.restart(function(){ LED.set();poke32(0x4001e504,1); while(!peek32(0x4001e400)); // enable flash writing poke32(0x1000120c,0xfffffffe); while(!peek32(0x4001e400)); // NFC pins as GPIO poke32(0x4001e504, 0);while(!peek32(0x4001e400)); // disable flash writing }); }, 1000);
You can check if NFC is enabled on the Espruino module using:
peek32(0x1000120c).toString(16) == "fffffffe"
Right now I'm working on the enclosure design. You can download the OpenSCAD file from Files, but note that it's not quite yet ready for prime time. What still needs to be done:
- adjusting the zip tie holes for holding the battery
- making sure there's enough space for the o-ring in the lid
- making sure there's enough space for the hex nut holes
- checking the solar panel fit