gmc320_QuickCPM_Reader

Forums:

Visit the QuickCPM Forum for more..
quickCPM provides a very small and lightweight monitor for your GMC-320 Plus geiger counter (left). Chances are it will work with other models but you will need to test for yourself. A few users have also used QuickCPM to upload their stats to the world radiation map. Track the radiation levels around your house, you may be surprised.
Here is an actual working copy using the new upload feature:
quickCPM.py basically loops a call to the gmc320 and displays it to the screen. Each pass then writes/updates the CMB and Temp record to a file for storage in the format gmc_YYYYMMDD_cmb.csv, temperature scvfile ending with _temp (see below) . It then combines the results into two linked html files that you can view in a browser locally or display from a web server using the new ftp upload feature.
Future:
  • (Completed qcpmmonthstats.py) iframe: Analysis Overview of data.
  • File Reader
  • Graph
  • button: Set Unit Date Stamp
  • button: GeoMap (??)
Topo
+ Bat -
>
GMC-320+
<->
Pi Zero
<->
quickCPM
<->
Apache
->
Dsply/Ctrl
Updates
  • 2018Aug25- Created yearly log analysis script qcpmyearstats.py. You can run this with the month stats and it will compile all of the month stats into a year overview. I have not included it in the zip file yet, you will have to download it seperately.
  • 2018June24- Created monthly log analysis script qcpmmonthstats.py. You should now see it as an iframe in the bottom of both bar and graph html files. Download
  • 2018Apr08- Uploaded ftp version. You must set ftp variables in beginning of script or turn off ftpOn variable.
  • 2018Apr07- Added upload library. Allows upload to website. (above) Upload cycle variable, above set to upload every 90 cycles.
  • 2018Mar11- Updated gauges to use scripting over static html. Added bar/gauge button on each page to switch between the two.
  • 2018Mar10- I have added a new output file that is gauges only. The file is called simply gauges.html. It uses gauges.min.js file from https://canvas-gauges.com which appears to be an awesome gauge set and fairly simple to set up. Image is below. This will come in handy for small devices like pi zero.
  • 2018Mar07-Updated to use a log dir. You must create the dir before using.. just /logs where you run the app from. I will do a dir create on the next update. I also updated the html output.
  • 2018Mar06-Added meta auto refresh index.html creation to display results. (see pic)
  • 2018Mar05-Changed date format in csv. Now registers temperature in seperate temp.csv file. Changed output to include peak monitor.
  • 2018Mar04- Added CRs to csv output.Csv file should be in correct format now.
Raspberry Pi Instructions Download quickCPM.zip below on your Raspberry Pi. Unzip to your preferred directory Create a /logs directory in this location if it does not exist (included in zip file) I believe the serial library comes with raspian base install, if not you will have to google search install. I will try it with a fresh Raspian install and update this post. Run the app by entering: python quickcpm.py 60 Where 60 is the refresh cycle time in seconds. If you omit this, it will use 300 which is 5 minutes. Your files will appear under the logs directory and the index.html will be built in the location you launched the program from.
Example Output
Headless quickCPM display with Chromium (See PIC) I was able to create a semi-headless (no menu) version with Chromium by finding the Chromium desktop configuration file, copy it to the desktop and then set the following settings on the desktop file: (right click on the chromium icon, properties to find the path) Once you have the desktop file on your desktop, right click on the desktop file and select properties. Set Name to QuickCPM under General (or something cool) Under Desktop Entry tab I set the command to: chromium-browser %U --app=file:///home/pi/bin/quickcpm/gauges.html --window-size=400,400 (where --app=path from your browser to the index.html file or gauge file) Set working directory to that same directory path (not sure if required). Set the description and Tooltip to something cool like quickcpm rules! If you want, put it in your boot up to open when machine boots.
crontab Here is an example of the crontab on my pi zero device crontab -e 0 0 * * * /home/pi/bin/quickcpm/qcpmM.sh 2 0 * * * /home/pi/bin/quickcpm/qcpmY.sh 0 1 * * * sudo service qcpm.sh stop 1 1 * * * sudo service qcpm.sh start
Pics: 
quickcpm gmc-32 capture
QuickCPM Python App for GMC-320
File Directory for quickCPM
Auto creates monitor page index.html
chromium headless example