Comments: SparkFun AS3935 Lightning Detector Hookup Guide (v20)
Looking for answers to technical questions?
We welcome your comments and suggestions below. However, if you are looking for solutions to technical questions please see our Technical Assistance page.
I2C didn't work reliably; there is also a note on our Ding & Dent. There are also a few posts in our forum regarding the issue.
https://cdn.sparkfun.com/assets/2/0/7/d/6/Qwiic_AS3935_Lightning_Detector-v20.pdf appears to have more information if you wanted to make some use of it - reliable or otherwise.... if that is what you were looking for?
Any pointers to getting this to work with a Particle Photon or Argon? In Particles IDE, there is a SparkFun_AS3935_Lightning_Detector_Arduino_Library; however, it won't even compile. I think the hookup to a particle is trivial (It has an SPI bus), but the code is not.
I wanted an audible warning when the AS3935 detected something, so I hooked up a mini 8 ohm speaker salvaged from an old computer and used the Tone( ) function from the Arduino standard library to make different tones for the different events (noise, disturber, lightning). Whenever the tone buzzed I got a continuous string of disturber events until I unplugged the speaker. Is it possible the Tone( ) function generates noise that the detector doesn't like?
Hi there, it sounds like you are looking for technical assistance. Please use the link in the banner above, to get started with posting a topic in our forums. Our technical support team will do their best to assist you.
That being said... possibly??? I believe we use the antenna recommended in the datasheet, which has a resonant frequency at 500 kHz.
Member #415430 - It would appear there is a lot of this going around. I have just got around to wiring this into my weather station, and SPI is not viable.
I just sat down to wire mine into a project seeing that it clearly states I2C on it although no clear SDA/SCL - to find it "didnt work reliably". What is the "not reliably" - and what are the pin outs if the required parts are there - as currently its either not working reliably OR an overly light paperweight : /
I too am attempting to add this sensor to my weather station on a Raspberry Pi 3A+. I'm running into the issue that if i have the BME280 sensor attached (via I2C) and the AS3935 attached via SPI using CE1, the lightning sensor fails to connect (and if it is already attached it generates endless interrupts with no type associated with it). The MCP3008 ADC is not having any issues (using CE0) and the lightning sensor works perfectly when the BME280 is not connected. Is there some known interference between I2C and SPI using CE1? I took me a while to figure out why the lightning sensor would work in testing but would fail to connect when I put it all together.
SPI is working for me... I2C is not. Luckily it's a rainy day here so there is better testing opportunity!
It turns out the AS3935 IC manufacturer implements I2C in a non standard way that is not compatible with the Arduino Wire library and that eventually causes communication on the I2C bus to fail. This link might get you pointed in the right direction for a replacement for the built in Arduino Wire library but we haven't tested it with our board. (it should work, but we can't support it.)
Thank you CF, that's the kind of clarity and direction I was hoping for!
If you've found an issue with this tutorial content, please send us your feedback!
Can the Sparkfun guys elaborate on the specific reasons why support of I2C for the AS3935 was dropped? A little detail of what you ran into, or how the chip behaved would be very educational for those of us who have never looked deeply enough into a chip to consider whether it should be used for a specific scenario which was listed in the documentation.
Even 5 minutes of ramblings from who ever handled it would be really insightful!