Comments (4)
Hi @mikaelnousiainen, thanks for providing a detailed report along with captures. I'll try to find some time this weekend to look into your issue. In the meantime, can you confirm that you're using implicit header mode?
The resampler and rotator are there to channelize the signal. I typically capture with the signal offset from the center frequency to avoid the SDR's DC spike. The rotator "shifts" the band so that the signal is centered and the DC spike is offset, and then the resampler reduces the sample rate to match the bandwidth of the LoRa signal -- effectively discarding whatever is outside of said bandwidth. This leaves you with a neatly channelized signal, which is what the LoRa demodulator expects.
Try using Baudline or an FFT/Waterfall sink to visualize each stage of this transformation and you'll see it in action.
from gr-lora.
I was using explicit header in the IQ sample. I just noticed that it isn't supported yet by gr-lora. I'll do another IQ recording with implicit header mode next week (once I'm back at where I have the hardware) and see how it works. One question though: how does the demodulator/decoder know the packet length with implicit header mode? Isn't the packet length what is left out when not using the header?
Is there something in particular blocking the decoding of explicit headers?
Thanks explaining how the GR components are used. I assumed something like that, but wasn't sure.
from gr-lora.
Packet framing:
The demodulator uses a squelch to find the end of the frame. Check it out here: https://github.com/BastilleResearch/gr-lora/blob/master/lib/demod_impl.cc#L392
Why it doesn't do explicit headers:
Explicit header decoding is blocked by not having been able to fully derive the whitening sequence that applies to said header. This gets into some of the weedy details of LoRa. Here's an abridged explanation:
One of the operations within the LoRa modulation is whitening, where your outgoing frame is XORed against the a predetermined pseudorandom string. LoRa's demodulation performs the same operation, XORing the incoming frame against said predetermined pseudorandom string, which returns the outgoing frame because XOR is its own inverse.
I was able to derive the implicit whitening sequences because I have control of every bit within the frame, including bits that would otherwise be used by the explicit header. Thus, I can zero them out and exploit XOR to get an off the shelf LoRa module to tell me what it's whitening sequence is.
My initial assumption was that implicit and explicit header mode would share the same whitening sequence (because why wouldn't they?) but empirically I found this wasn't the case. Additionally, under explicit mode I do not have control of the header bits, meaning I cannot force their value to 0. Thus I cannot derive the whitening bits that apply to the header.
The good news is that I've made good progress on mapping out a few whitened values within the header format. Thus I'll be able to implement some of the explicit header fields and functionality. Perhaps if I can guess their unwhitened values I'll be able to take a whack at the PHY header's CRC as well (the header has its own CRC).
Explicit header mode is being tracked in issues #3 and #4.
tl;dr some explicit mode support is coming soon™
from gr-lora.
Ok, yes, that makes sense (for the explicit headers). Thanks for the detailed explanation!
I made another two test captures with the same data and settings as described above, but with implicit header enabled. This time I gr-lora (nor rpp0's gr-lora) couldn't really decode any of the data. Anyway, here are the recordings in case they are useful to you.
The first one was recorded with the SDR dongle antenna (for 434MHz) a bit further away, so I decided to bring it very close (30cm) to see if it makes a difference.
https://expirebox.com/download/d36c3e50fe65efaff49885d1fbf4a612.html
https://expirebox.com/download/c0ce4cf6561bccaa6236b51fa02d8ad6.html
Again, the links expire in 48h.
from gr-lora.
Related Issues (20)
- about the gray coding HOT 1
- tr_usrp.grc not transmitting via usrp HOT 8
- B200 HOT 1
- SX1272 - SF6, Implicit header, CR4/5, LDR enabled HOT 1
- Receive incorrect data on Pycom LoPy LoRa
- low data rate opt set to 0 will not work
- Error in the modulator block
- Error on tx_usrp example
- Dragino setup > no documentation
- UDP stream
- Can this code run in 2.4GHz? HOT 1
- Import LoRa Error
- Ettus E313 SDR module' object has no attribute ‘demod' HOT 1
- Decode data from RN2483 HOT 2
- Issue with Decoding!! HOT 7
- Deinterleaved codewords incorrect order
- Port gr-lora from GR3.7 to GR3.8
- the ralationship between spread factor and header?
- Can the decoded data packet be sent to the network server intact HOT 1
- Camke error HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gr-lora.