Author Topic: AS3595 not Detecting Strikes  (Read 27032 times)

0 Members and 1 Guest are viewing this topic.

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #25 on: June 18, 2014, 11:59:00 AM »
I'm in the midst of a storm at the moment. I'm getting very good detection rates from my AS3935 with the settings shown on the attached jpg.

The trick seems to be to enable "Outdoor" detection. Even the distances are looking realistic.

Don
WD9DMP

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #26 on: June 18, 2014, 01:30:36 PM »
Graphs of detections from the last round of storms, with the new settings:

http://projectmf.homelinux.com/as3935_stats.html

Don
WD9DMP

Offline miraculon

  • Sunrise Side Weather
  • Forecaster
  • *****
  • Posts: 3538
  • KE8DAF
    • Sunrise Side Weather in Rogers City MI USA
Re: AS3595 not Detecting Strikes
« Reply #27 on: June 18, 2014, 02:57:42 PM »
Outdoor. Hmmm....

I'll try it. The Acu-Rite recorded one strike at 4 miles away yesterday. There were more than that, but at least I have not been getting false strikes on it. The Acu-Rite also with AS3935 is a few inches away from the one interfaced to the RED controller.

Greg H.



Blitzortung Stations #706 and #1682
CoCoRaHS: MI-PI-1
CWOP: CW4114 and KE8DAF-13
WU: KMIROGER7
Amateur Radio Callsign: KE8DAF

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #28 on: June 18, 2014, 08:12:49 PM »
Getting hundreds of strikes registering on the AS3935 with the new settings mentioned above. Looking good!

Don
WD9DMP

Offline miraculon

  • Sunrise Side Weather
  • Forecaster
  • *****
  • Posts: 3538
  • KE8DAF
    • Sunrise Side Weather in Rogers City MI USA
Re: AS3595 not Detecting Strikes
« Reply #29 on: June 18, 2014, 08:49:43 PM »
I am now "Outdoors" on my settings. I'll let you know how it works. Who'da thunk it?

Greg H.


Blitzortung Stations #706 and #1682
CoCoRaHS: MI-PI-1
CWOP: CW4114 and KE8DAF-13
WU: KMIROGER7
Amateur Radio Callsign: KE8DAF

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #30 on: June 19, 2014, 10:26:31 AM »
My area was hit with a steady string of moderate thunderstorms last night from the stationary front over Northern Illinois. It turned out to be a good test of the AS3935.

I have to say, checking the "outdoor" setting really woke the board up. Checking the "outdoor" box is supposed to REDUCE the sensitivity of the chip by using a different set of noise floor thresholds, assuming if you are outdoors, the signals will be stronger. The opposite seems to be the case.

I logged rates up to 120 strikes/minute and estimated storm distances from 1 km to 31 km. The distance estimates decreased as the storms approached and increased as they left the area.

The indoor/outdoor setting was the only setting I had not really tried changing. I am guessing the firmware has the indoor/outdoor setting reversed somehow.

Again, http://projectmf.homelinux.com/as3935_stats.html shows the last storm cell that passed through. The data is updated in real-time, so may change by the time you check it. The log .csv log file is at http://projectmf.homelinux.com/as3935_log.txt. This file may be imported into Microsoft Excel for analysis.

Regards,

Don
WD9DMP
« Last Edit: June 19, 2014, 07:31:54 PM by dfroula »

Offline Dr Obbins

  • Forecaster
  • *****
  • Posts: 1148
Re: AS3595 not Detecting Strikes
« Reply #31 on: June 19, 2014, 02:04:20 PM »
I have changed my settings to match yours and hopefully some storms may pass through soon.

Is your "AS3935 Local Lightning Detection Module Statistics" page something easily implemented. How is the data collected?

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #32 on: June 19, 2014, 03:41:40 PM »
Hi, Dave,

Detailed instructions are in this thread. The file names may be slightly different. Change paths in the scripts to suit your installation:

http://forum.blitzortung.org/showthread.php?tid=98&pid=3896#pid3896

However, I have updated and improved the scripts some. The basic procedure is the same.

You can grab the new scripts directly from my web server:

http://projectmf.homelinux.com/log_as3935.php

http://projectmf.homelinux.com/as3935_distance.html

http://projectmf.homelinux.com/as3935_energy.html

http://projectmf.homelinux.com/as3935_rate.html

http://projectmf.homelinux.com/display_as3935_data.php

http://projectmf.homelinux.com/as3935_stats.html

http://projectmf.homelinux.com/as3935_icon.jpg

Regards,

Don
WD9DMP
« Last Edit: June 19, 2014, 03:44:04 PM by dfroula »

Offline miraculon

  • Sunrise Side Weather
  • Forecaster
  • *****
  • Posts: 3538
  • KE8DAF
    • Sunrise Side Weather in Rogers City MI USA
Re: AS3595 not Detecting Strikes
« Reply #33 on: June 19, 2014, 08:15:21 PM »
It seems that the old "auto calibration" might still be a source of noise. Whenever I ran the AS3935 in "auto cal" mode, there was a noise interrupt error message in the debug log.

However, if I looked at the log and picked the best value from the auto cal, then froze it with the numeric pick list, I no longer got the noise error message.

I am going to run this way for a while. Unfortunately, my cal sticker on the original foil envelope was lost in the move so this method will have to suffice for me.

Greg H.


Blitzortung Stations #706 and #1682
CoCoRaHS: MI-PI-1
CWOP: CW4114 and KE8DAF-13
WU: KMIROGER7
Amateur Radio Callsign: KE8DAF

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #34 on: June 19, 2014, 08:32:09 PM »
I found the cal value arrived at by the controller (turn on AS3935 logging to see the results) matched the number on my envelope.

Don
WD9DMP

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #35 on: June 19, 2014, 08:38:25 PM »
Storms closing in on my QTH - AS3935 staring to pick up lightning....

 http://projectmf.homelinux.com/as3935_stats.html

Don

Offline Dr Obbins

  • Forecaster
  • *****
  • Posts: 1148
Re: AS3595 not Detecting Strikes
« Reply #36 on: June 21, 2014, 12:05:36 PM »
We had many strikes well within 30 - 100 miles this morning. It detected only 1 strike. This strike happened to be detected while I was hitting the "save" button, so I don't know if it was the before or after settings or something in between during the save. (yellow circle is my house)

Offline Dr Obbins

  • Forecaster
  • *****
  • Posts: 1148
Re: AS3595 not Detecting Strikes
« Reply #37 on: June 21, 2014, 06:02:01 PM »
I take my lighter to create some sparks hoping that the chip will pick up some signals. However when I click he lighter the LCD screen turns on and with each of the following clicks, the LCD scrolls through the different screens.  :-k This is with the lighter with in 10" of the chip.

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #38 on: June 21, 2014, 06:28:33 PM »
If you have the external reset and LCD buttons installed, the leads pick up the impulse and can activate the LCD as though the button were pressed.

Picking up lots of strikes on the AS3935 now. A severe storm is about to pass through. See web site above to monitor real-time.

Don

Offline Dr Obbins

  • Forecaster
  • *****
  • Posts: 1148
Re: AS3595 not Detecting Strikes
« Reply #39 on: June 21, 2014, 06:45:09 PM »
Looks good! It has recorded 2 strikes now so that was enough to start getting the webpage going. Still working on the graphs.
http://www.cavecountryweather.com/lightning/as3935_stats.html

If I get another close storm, I will experiment more with the settings.
« Last Edit: June 21, 2014, 06:46:44 PM by Dr Obbins »

Offline Dr Obbins

  • Forecaster
  • *****
  • Posts: 1148
Re: AS3595 not Detecting Strikes
« Reply #40 on: June 21, 2014, 07:14:24 PM »
Don,
The http://projectmf.homelinux.com/log_as3935.php link returns an error message:

Warning: Division by zero in /volume1/web/log_as3935.php on line 18

Can you post the code?

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #41 on: June 21, 2014, 08:00:22 PM »
Yes, for the rate calculation, that happens as the first strike in a new event will show a duration of zero. I didn't bother to trap for it or add a conditional statement to fix it. It doesn't affect the graphs.

Here's the latest code:

Code: [Select]
<?php
$date 
date("m/d/Y");
$time date("G:i:s");
$datetime "$date $time";

# Retrieve all possible value names and values from Controller on strike event for testing and save to file.
# $file_test = fopen("/volume1/web/as3935_test.txt","w");
# foreach ($_GET as $key => $value)
# {
# fwrite($file_test,"$key:  $value\n");
# }
# fclose($file_test);

$strokes $_GET['strokes'];
$disturbers $_GET['disturbers'];
$duration $_GET['duration'];
#$rate = $strokes;
$rate round(($strokes/$duration*60),2);
$dist $_GET['dist'];
$dist_min $_GET['dist_min'];
$dist_max $_GET['dist_max'];
$energy $_GET['energy'];
$energy_min $_GET['energy_min'];
$energy_max $_GET['energy_max'];
$strokes_all $_GET['strokes_all'];
$disturbers_all $_GET['disturbers_all'];
$events $_GET['events'];

if (!
file_exists("/volume1/web/as3935_log.txt")) {
     
$file fopen("/volume1/web/as3935_log.txt","w");
     
fwrite($file,"Date,Time,Date-Time,Event Strokes,Event Disturbers,Event Duration,Event Strike Rate,Current Strike Distance,Event Min Distance,Event Max Distance,Current Strike Energy,Event Min Energy,Event Max Energy,All Strokes,All Disturbers,Events\n");
fclose($file);
     }

$file fopen("/volume1/web/as3935_log.txt","a");
fwrite($file,"$date,$time,$datetime,$strokes,$disturbers,$duration,$rate,$dist,$dist_min,$dist_max,$energy,$energy_min,$energy_max,$strokes_all,$disturbers_all,$events\n");
fclose($file);

$file2 fopen("/volume1/web/as3935_display.txt","w");
fwrite($file2,"\nLast Strike\n==== ======\nLatest Strike:.................$date $time\nLatest Strike Distance:........$dist KM\nLatest Strike Energy:..........$energy\n\nLast Event\n==== =====\nNumber of Strikes in Event:....$strokes\nLightning Event Duration:......$duration Seconds\nCurrent Event Strike Rate:.....$rate Strikes/Minute\nShortest Distance to Strike:...$dist_min KM\nLongest Distance to Strike:....$dist_max KM\nLowest Strike Intensity:.......$energy_min\nHighest Strike Intensity:......$energy_max\nTotal strikes since reboot:....$strokes_all\n");
fclose($file2);
?>
« Last Edit: June 21, 2014, 08:05:57 PM by dfroula »

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #42 on: June 21, 2014, 08:03:37 PM »
BTW, for the graphs, you need to download the jquery-1.11.0.min.js package in a local file. I have jquery.csv-0.71.js there as well. Not sure I am using that one. Include both in the three graphing programs to be safe. The Google Graphs .js can not be downloaded locally and must be referenced on the web.

Don
« Last Edit: June 21, 2014, 08:07:16 PM by dfroula »

Offline Dr Obbins

  • Forecaster
  • *****
  • Posts: 1148
Re: AS3595 not Detecting Strikes
« Reply #43 on: June 21, 2014, 08:08:05 PM »
Yea, I got the .js files and thanks for the script.
Now to wait for more storms.

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #44 on: June 21, 2014, 08:09:25 PM »
The table you have working needs a strike to generate the display file. However, the graphing programs read the last 300 lines of the log file. You can just copy mine for testing.

Don

Offline Dr Obbins

  • Forecaster
  • *****
  • Posts: 1148
Re: AS3595 not Detecting Strikes
« Reply #45 on: June 22, 2014, 09:22:06 AM »
Appreciate the help.
It logged 4 strikes today, although I don't think they are real as there are no storms in the area. At least it verified that the scripts, etc. are working.
http://www.cavecountryweather.com/AS3935lightning.php

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #46 on: June 22, 2014, 10:45:22 AM »
Looks good, Dave.

On that "divide by zero" error, on the first strike in an "event", the rate graph just plots a null rate. That way the start of a new event is clear from the graphs and all of the strikes align on the graphs.

I get the occasional false strike, but I have the signal threshold and spike rejection set very low. Set signal threshold to zero and you will see quite a few false detections for testing. Try setting it to 2 for better false strike rejection.

Don
WD9DMP

Glad you got it running.

Offline Jet

  • Member
  • *
  • Posts: 27
Re: AS3595 not Detecting Strikes
« Reply #47 on: June 22, 2014, 12:06:38 PM »
I've been playing with the Tautic board for a while and gave up on it last year as it wasn't detecting strikes reliably.
I revisited it this year and have designed a 3V Coin Cell powered board with LCD screen, similar functionality to the board in the eval kit, but
based around an Atmega328p, i.e. a low powered arduino, and now have it detecting reliably.  I.E. Indoor detection at indoor settings and the defaults
for everything (2/2/2).  I've correlated strikes out to 60km (AS3935 is 40km, but it occasionally gets the estimation wrong) with it and smaller internal cloud
discharges during storms, it's been more sensitive than blitzortung in my area (by about a factor of 10) and really does give accurate
advance warning of storms and also of clouds with developing potential when close.

However it's been a lesson in frustration to get to this point, here's what I found, some of it maybe useful to someone.

1. Despite all the software having a hookup to the computer for serial over USB, don't do it.  :-)  Interference from the computer
is coupled in and receiver ends up useless.

2. Don't ground AS3935.  Many USB connections are grounded to mains ground on the 0V, another reason not to connect to a computer.
The AS3935 doesn't detect when grounded to mains ground.

3. When everything is right, it really does work well at the default settings.

4. Battery powered is better.

5. Needs good ground plane management.  All processing components should have a ground plane underneath, the antenna circuitry for the AS3935
should not.

6. Sleep processor between strikes, cuts down on noise

7. Detecting disturbers doesn't equate to detecting lightning.  I.E. You need a real storm to know if it's gonna detect lightning or not.

8. Be careful of any EMI generating components.  I had a regular 3-5V piezo buzzer (with internal oscillator), that when a strike hit,
the action of the buzzer "buzzing" would keep generating repeat strikes.  Took an RC filter and location well away from the board to solve.

9. Put enough capacitance on the Vcc.  The datasheet specifies 1uF, many boards are using 0.1uF which is not enough.

10. Don't generate any signals on 500KHz, i.e. don't used SPI with a 500KHz clock.

11. Recalibrate after every AS3935 setting change

12. I timed my calibration against the DS3231 realtime clock to get an accurate measurement

I haven't connected the AS3935 up to my RED yet and also not grounding the AS3935, but grounding the RED is contradictory, so I don't know
how to tackle that one.  I think the next thing to test will be a AS3935 without INN connected to 0V might be something to try.
Station 1046: Calgary, Alberta, Canada

Offline miraculon

  • Sunrise Side Weather
  • Forecaster
  • *****
  • Posts: 3538
  • KE8DAF
    • Sunrise Side Weather in Rogers City MI USA
Re: AS3595 not Detecting Strikes
« Reply #48 on: June 22, 2014, 12:16:43 PM »
This might help explain why the Acu-Rite detector seems to be working better than the AS3935 interfaced to the RED. The Acu-Rite with AS3935 is battery operated and is isolated from ground, or host processors.

http://www.wxforum.net/index.php?topic=22235.msg219697#msg219697

Your observations about the 500KHz noise also fit with having better results with not allowing "auto" calibration and using a fixed calibration table setting.

It might be possible to have opto-isolators for the I2C lines, and float the AS3935 with a coin cell like you are suggesting, Jet.

I'll try some of your other ideas, they look reasonable to me.

Greg H.


Blitzortung Stations #706 and #1682
CoCoRaHS: MI-PI-1
CWOP: CW4114 and KE8DAF-13
WU: KMIROGER7
Amateur Radio Callsign: KE8DAF

Offline dfroula

  • Forecaster
  • *****
  • Posts: 543
Re: AS3595 not Detecting Strikes
« Reply #49 on: June 22, 2014, 12:44:56 PM »
There are a couple of "catch-22s" involved with the AS3935!

I noticed that grounding the controller seems to make the AS3935 deaf to lightning as well. However, I need a ground for my H-field antenna shields. The I2C bus needs the ground reference to the controller, so I can't see a way around that one.

Also, making the I2C leads longer than a few inches creates all kinds of bus errors, possibly related to the AS3935 periodic calibration routine putting the cal frequency on the IRQ line. This means that the board needs to be very near the controller, where noise pickup could be an issue. However, the auto noise threshold adjustment seems to select a fairly low value noise threshold, in indoor or outdoor modes. It may be due to the response of the AS3935 to certain kinds of noise, which do not generate an "excessive noise" interrupt but still are above the noise floor threshold. I think the reason that selecting "outdoor" helps detection is that is increases the noise floor threshold significantly, creating some immunity to impulse noise from the nearby controller.

We are stuck with the I2C bus on the controller - SPI is not supported.

Nice summary!

Regards,

Don

I've been playing with the Tautic board for a while and gave up on it last year as it wasn't detecting strikes reliably.
I revisited it this year and have designed a 3V Coin Cell powered board with LCD screen, similar functionality to the board in the eval kit, but
based around an Atmega328p, i.e. a low powered arduino, and now have it detecting reliably.  I.E. Indoor detection at indoor settings and the defaults
for everything (2/2/2).  I've correlated strikes out to 60km (AS3935 is 40km, but it occasionally gets the estimation wrong) with it and smaller internal cloud
discharges during storms, it's been more sensitive than blitzortung in my area (by about a factor of 10) and really does give accurate
advance warning of storms and also of clouds with developing potential when close.

However it's been a lesson in frustration to get to this point, here's what I found, some of it maybe useful to someone.

1. Despite all the software having a hookup to the computer for serial over USB, don't do it.  :-)  Interference from the computer
is coupled in and receiver ends up useless.

2. Don't ground AS3935.  Many USB connections are grounded to mains ground on the 0V, another reason not to connect to a computer.
The AS3935 doesn't detect when grounded to mains ground.

3. When everything is right, it really does work well at the default settings.

4. Battery powered is better.

5. Needs good ground plane management.  All processing components should have a ground plane underneath, the antenna circuitry for the AS3935
should not.

6. Sleep processor between strikes, cuts down on noise

7. Detecting disturbers doesn't equate to detecting lightning.  I.E. You need a real storm to know if it's gonna detect lightning or not.

8. Be careful of any EMI generating components.  I had a regular 3-5V piezo buzzer (with internal oscillator), that when a strike hit,
the action of the buzzer "buzzing" would keep generating repeat strikes.  Took an RC filter and location well away from the board to solve.

9. Put enough capacitance on the Vcc.  The datasheet specifies 1uF, many boards are using 0.1uF which is not enough.

10. Don't generate any signals on 500KHz, i.e. don't used SPI with a 500KHz clock.

11. Recalibrate after every AS3935 setting change

12. I timed my calibration against the DS3231 realtime clock to get an accurate measurement

I haven't connected the AS3935 up to my RED yet and also not grounding the AS3935, but grounding the RED is contradictory, so I don't know
how to tackle that one.  I think the next thing to test will be a AS3935 without INN connected to 0V might be something to try.

 

anything