Giter Club home page Giter Club logo

zxcounter's Introduction

ZX Counter

ZX Counter is an alternative software for the Arduino-based Geiger counter DIYGeigerCounter. The software uses the same pin layout as the default sketch, so it can be used without changing the hardware.

Features

  • Displays the average CPM and the equivalent radiation dose each second
  • Automatic and manual averaging interval
  • The automatic averaging interval depends on the current radiation level
  • Two custom averaging intervals can be set to: 1s, 5s, 10s, 30s, 1m, 5m and 10m
  • Analog bar emulation
  • Displays the total measuring time
  • Displays the total CPM and the accumulated equivalent radiation dose within the measuring time
  • Displays the maximal CPM and the maximal equivalent radiation dose reached within the measuring time
  • CPM, equivalent radiation dose, total measuring time auto-ranging
  • The equivalent radiation dose unit, the CPM to uSv/h ratio, the alarm threshold and the bar scale can be changed in settings
  • Settings stored in EEPROM
  • Debug info: the current CPU voltage and the available memory can be shown at startup
  • The current CPM, uSv/h, Vcc logging to serial each minute
  • Low battery check

Display Modes

The display mode can be switched forward by pressing the MODE button or backwards by pressing the ALT button:

Auto (default) -> Custom period 1 -> Custom period 2 -> ALL -> MAX -> DOSE

The following display modes are currently available:

Auto (default) - The automatic averaging interval. It is based on the current radiation level. Displays the average CPM, the equivalent radiation dose and the analog bar.

Custom period 1 - The custom averaging interval. It can be set to: 1s, 5s, 10s, 30s, 1m, 5m, 10m in the settings mode. Displays the average CPM, the equivalent radiation dose, the total measuring time, the current averaging interval.

Custom period 2 - See Custom period 1.

ALL - The averaging interval equals the total measuring time. Displays the average CPM, the equivalent radiation dose and the total measuring time.

MAX - Displays the maximal CPM, the maximal equivalent radiation dose reached within measuring time and the total measuring time.

DOSE - Displays the total CPM, the accumulated equivalent radiation dose and the total measuring time.

Auto averaging

In the auto mode the software uses the automatic averaging algorithm that depends on the average CPM within the last 5 seconds:

  • 1m if CPM < 60
  • 30s if CPM >= 60 and < 300
  • 10s if CPM >= 300 and < 1500
  • 5s if CPM >= 1500 and CPM < 7500
  • 1s if CPM >= 7500

The current equivalent radiation dose value is blinking while the total measuring time is less than the current averaging interval.

Settings

The following settings can be changed during startup:

  • The equivalent radiation dose unit: Sieverts "Sv" or Roentgens "R"
  • The alarm threshold: Off, from 0.1 to 100 uSv/h
  • The bar scale: from 0.5 to 100 uSv/h
  • The CPM to uSv/h conversion ratio: from 1 to 2000, defaults to 175 for the SBM-20 tube
  • Custom period 1 and Custom period 2: custom averaging intervals
  • Reset settings to defaults option

Use the MODE button to increase the value and the ALT button to decrease.

Debug info

If the MODE button or the ALT button was pressed while the startup banner is shown, the current CPU voltage and the available memory will be shown at the display.

Pin configuration

  • PIN 9 - not used (the tube switch in the default sketch)
  • PIN 10 - MODE button
  • PIN 11 - ALT button (optional)
  • PIN 15 - outputs HIGH (5v) when the alarm threshold is reached

Note: currently, the ALT button is optional. All features will be still available without the ALT button connected.

Change Log

1.7

  • print bar fixed

1.6

  • fast response analog bar

1.5

  • settings fixes

1.4

  • decreased number of display modes: removed 1s, 5s, 10s, 30s, 1m, 5m, 10m stats display modes
  • added two new display modes: custom period 1 and custom period 2
  • custom period 1 and custom period 2 intervals can be set to: 1s, 5s, 10s, 30s, 1m, 5m, 10m in the settings mode
  • added bar scale setting
  • added logging to serial
  • reset settings to defaults option
  • improvements and bug fix

1.31

  • debug info fixed

1.3

  • unit setting
  • ratio setting
  • settings mode
  • better button push feedback
  • low battery check
  • analog bar symbols changed
  • bug fix and improvements

1.2

  • debug info
  • ALT button support
  • alarm threshold setting
  • bug fix and improvements

1.1 The initial version with basic features

1.0 Test version

zxcounter's People

Contributors

andkom avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

zxcounter's Issues

Bug in Bar Graph

The bar graph over runs the end when creating a blank graph.
The last block is not erased when going from value =100 to 0.
Updated code attached.

// prints analog bar
void printBar(float value, float max, byte blocks) {
  if (value > max) {
    value = max;
  }

  float scaler = max / float(blocks * 5);
  byte bar_value = value / scaler;
  byte full_blocks = bar_value / 5;
  byte prtl_blocks = bar_value % 5;

  for (byte i = 0; i < full_blocks; i++) {
    lcd.write(5);
  }

  if(prtl_blocks)  //print any prtl blocks
    lcd.write(prtl_blocks);

  for (byte i = full_blocks + prtl_blocks; i < blocks; i++) {
    lcd.write(byte(0));
  }
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.