{"id":276,"date":"2013-03-31T23:36:13","date_gmt":"2013-03-31T22:36:13","guid":{"rendered":"http:\/\/www.daqq.eu\/?p=276"},"modified":"2023-11-05T22:00:26","modified_gmt":"2023-11-05T21:00:26","slug":"the-sanity-nullifier","status":"publish","type":"post","link":"https:\/\/www.daqq.eu\/?p=276","title":{"rendered":"The Sanity nullifier"},"content":{"rendered":"<p>The purpose of this device is a bit evil. Oh well, sue me. I made it as a yoke for the first of april and many more days to come.<\/p>\n<p><strong>A brief description:<\/strong><\/p>\n<p>The device beeps a short beep of a very annoying frequency in random times. The time between beeps is anywhere within half an hour to nine hours.<\/p>\n<p>Point:<br \/>\nThe subject of your devious device has a flat\/house. Put the beeper inside the house, and when the first beep occurs, your victim will just wonder about that what was it. When it occurs again and again he will try to locate the source. After checking all cellphones, smokealarms, battery powered devices in general he will be clueless as to what is causing this. The beeping will be a mystery as long as the battery lives. Or it will drive him nuts.<\/p>\n<p>Instruction:<br \/>\n1. Activate the device<br \/>\n2. Hide the device<br \/>\n3. Don't stay around to watch the fun.<\/p>\n<p>It beeps in random. Where the time between beeps can be anything from 30minutes, to 9hours and 30minutes.<\/p>\n<h1>Hardware:<\/h1>\n<p>The hardware is boringly simple. One piezotransducer, one battery, one AVR. All packed like you choose it. Here's the schematic:<\/p>\n<p><a href=\"http:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_schematic.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-279\" src=\"http:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_schematic.png\" alt=\"sanity_nullifier_schematic\" width=\"631\" height=\"436\" srcset=\"https:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_schematic.png 631w, https:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_schematic-300x207.png 300w\" sizes=\"auto, (max-width: 631px) 100vw, 631px\" \/><\/a><\/p>\n<p>A sample of how you can make it is here:<\/p>\n<p><a href=\"http:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_photo.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-277\" src=\"http:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_photo.png\" alt=\"sanity_nullifier_photo\" width=\"450\" height=\"268\" srcset=\"https:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_photo.png 450w, https:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_photo-300x178.png 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<p>As you can see my main point is always functionality. Not decoration. But there's a gazilion other ways you can make the device.<\/p>\n<h1>Firmware:<\/h1>\n<p>I release the firmware under GNU. In the project folder, which you can download on the bottom of the page is a precompiled hex file which worked for me.<\/p>\n<pre>\/*\n Copyright David Gustafik, 2007\n\n This program is free software; you can redistribute it and\/or modify\n it under the terms of the GNU General Public License as published by\n the Free Software Foundation; either version 2 of the License, or\n (at your option) any later version.\n\n This program is distributed in the hope that it will be useful,\n but WITHOUT ANY WARRANTY; without even the implied warranty of\n MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n GNU General Public License for more details.\n\n You should have received a copy of the GNU General Public License\n along with this program; if not, write to the Free Software\n Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA\n\n *\/\n\n #include &lt;avr\/io.h&gt;\n #include &lt;avr\/interrupt.h&gt;\n #include &lt;compat\/deprecated.h&gt;\n #include &lt;stdlib.h&gt;\n\n \/*\n (to be used on first of april, or whenever in an evil mood (for me 24\/7))\n\n by David 'daqq' Gustafik\n\n The Beeper of Madness:\n\n Beeps a short beep of very annoying frequency in random times.\n Beeps occur randomly within half an hour to nine and a half hour.\n Instruction: \n 1. Activate the device\n 2. Hide the device\n 3. Don't stay around to watch the fun. \n\n Point:\n The subject of your devious device has a flat\/house. Put the beeper\n inside the house, and when the first beep occurs, your victim will\n just wonder about that what was it. When it occurs again and again\n he will try to locate the source. After checking all cellphones,\n smokealarms, battery powered devices in general he will be clueless\n as to what is causing this. The beeping will be a mystery as long \n as the battery lives. Or it will drive him nuts. \n\n WARNING: This software is provided as is without any waranties at all.\n The author is not responsible for any injuries\/material damage that may\n arise from the usage of this software\/device\n\n README:\n The hex file you received with the zip file that contained this file\n is calibrated for a ATTiny2313 running on the internal oscilator @ 4MHz\n and with the CKDIV8 fuse enabled. Therefore the processor is running at \n 500kHz. \n *\/\n\n #define SERIAL_NUMBER 1\n \/\/this is the seed for the random number generator. you may either use my\n \/\/serial number (1) or recompile it (unadvised) with your own. \n\n \/\/defs\n #define BUZZER1() {sbi(PORTB,0);cbi(PORTB,1);}\n #define BUZZER0() {cbi(PORTB,0);sbi(PORTB,1);}\n #define BEEP_INTERVAL 0.08\n #define BEEP_LENGTH 2500\n #define nop() asm volatile (\"nop;\")\n\n \/\/globals\n volatile unsigned int rand_cond=0;\n volatile unsigned int rand_box=0;\n\n \/\/functions\n void beep(void);\n void wait(unsigned int a);\n #define _ms(x) x*45\n\n \/\/timer overflow interrupt. occurs each 0.5seconds. \n\n ISR(TIMER0_OVF_vect)\n {\n  rand_box++;\n  return;\n }\n\n int main(void)\n {\n  DDRD = 0x00;\n  DDRB = _BV(1) | _BV(0);\n\n  ACSR=0x80;\/\/disable power to the analog comparator\n  TCCR0B=0x05;\n  TIMSK = 0x02;\n\n  srand(SERIAL_NUMBER);\n\n  wait(_ms(100));\n  beep();\n  sei();\n  while(1)\n  {\n   if(rand_box==rand_cond)\n   {\n    rand_box=0;\n    rand_cond=rand()%(0xFFFF-1000)+1000;\n    beep();\n   }\n  }\n }\n\n void beep()\n {\n  unsigned int temp;\n  for(temp=0;temp!=BEEP_LENGTH;temp++)\/\/does the beeping on the piezo.\n  {\n   BUZZER0();\n   wait(_ms(BEEP_INTERVAL));\n   BUZZER1();\n   wait(_ms(BEEP_INTERVAL));\n  }\n  return;\n }\n\n void wait(unsigned int a)\n { \n  unsigned int b,c;\n  for(b=0;b!= a; b++)for(c=0;c!= 5;c++) nop();\n  return;\n }<\/pre>\n<p>The code is boringly simple. You'll need an AVR running @ 4MHz with the CKDIV8 fuse enabled. This way, the device eats only 200uA (microamps) and can last long out of a lithium battery, like the one on the pictures.This is the configuration of your fuses to run this:<\/p>\n<p><a href=\"http:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_ponyprog.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-278\" src=\"http:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_ponyprog.png\" alt=\"sanity_nullifier_ponyprog\" width=\"589\" height=\"302\" srcset=\"https:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_ponyprog.png 589w, https:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_ponyprog-300x153.png 300w\" sizes=\"auto, (max-width: 589px) 100vw, 589px\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<h1>Download:<\/h1>\n<p>Download the project folder here:<\/p>\n<div class='w3eden'><!-- WPDM Link Template: Default Template -->\n\n<div class=\"link-template-default card mb-2\">\n    <div class=\"card-body\">\n        <div class=\"media\">\n            <div class=\"mr-3 img-48\"><img decoding=\"async\" class=\"wpdm_icon\" alt=\"Icon\" src=\"https:\/\/www.daqq.eu\/wp-content\/plugins\/download-manager\/assets\/file-type-icons\/zip.svg\" \/><\/div>\n            <div class=\"media-body\">\n                <h3 class=\"package-title\"><a href='https:\/\/www.daqq.eu\/?wpdmpro=sanity-nullifier-project-folder'>Sanity nullifier project folder<\/a><\/h3>\n                <div class=\"text-muted text-small\"><i class=\"fas fa-copy\"><\/i> 1 file(s) <i class=\"fas fa-hdd ml-3\"><\/i> 157.63 KB<\/div>\n            <\/div>\n            <div class=\"ml-3\">\n                <a class='wpdm-download-link download-on-click btn btn-primary ' rel='nofollow' href='#' data-downloadurl=\"https:\/\/www.daqq.eu\/?wpdmpro=sanity-nullifier-project-folder&wpdmdl=1227&refresh=6a2cb594577b41781314964\">Download<\/a>\n            <\/div>\n        <\/div>\n    <\/div>\n<\/div>\n\n<\/div>\n<p><strong>NOTE:<\/strong> If you make this device I ask nothing in return, just PLEASE take a photo of it and post it into my forum. That's all I ask.<\/p>\n<h1>Mods<\/h1>\n<p>A number of people built this device. Macsek, a fine guy from Hungary improved my original device by using a smaller AVR (Tiny13) and made smaller version, easier to conceal.<\/p>\n<p>Here's the photo and the source:<\/p>\n<p><a href=\"http:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_macsek.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-280\" src=\"http:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_macsek.jpg\" alt=\"sanity_nullifier_macsek\" width=\"450\" height=\"338\" srcset=\"https:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_macsek.jpg 450w, https:\/\/www.daqq.eu\/wp-content\/uploads\/2013\/03\/sanity_nullifier_macsek-300x225.jpg 300w\" sizes=\"auto, (max-width: 450px) 100vw, 450px\" \/><\/a><\/p>\n<pre>\/*\n Copyright David Gustafik, 2007\n\n This program is free software; you can redistribute it and\/or modify\n it under the terms of the GNU General Public License as published by\n the Free Software Foundation; either version 2 of the License, or\n (at your option) any later version.\n\n This program is distributed in the hope that it will be useful,\n but WITHOUT ANY WARRANTY; without even the implied warranty of\n MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n GNU General Public License for more details.\n\n You should have received a copy of the GNU General Public License\n along with this program; if not, write to the Free Software\n Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA\n\n date modified by change\n ---------- -------------------------- ----------------------------\n 2007.03.27 Macsek mmx233@gmail.com Added Tiny13 support\n\n *\/\n\n #include &lt;avr\/io.h&gt;\n #include &lt;avr\/interrupt.h&gt;\n #include &lt;compat\/deprecated.h&gt;\n #include &lt;stdlib.h&gt;\n\n \/*\n (to be used on first of april, or whenever in an evil mood (for me 24\/7))\n\n by David 'daqq' Gustafik\n\n The Beeper of Madness:\n\n Beeps a short beep of very annoying frequency in random times.\n Beeps occur randomly within half an hour to nine and a half hour.\n Instruction:\n 1. Activate the device\n 2. Hide the device\n 3. Don't stay around to watch the fun.\n\n Point:\n The subject of your devious device has a flat\/house. Put the beeper\n inside the house, and when the first beep occurs, your victim will\n just wonder about that what was it. When it occurs again and again\n he will try to locate the source. After checking all cellphones,\n smokealarms, battery powered devices in general he will be clueless\n as to what is causing this. The beeping will be a mystery as long\n as the battery lives. Or it will drive him nuts.\n\n WARNING: This software is provided as is without any waranties at all.\n The author is not responsible for any injuries\/material damage that may\n arise from the usage of this software\/device\n\n README:\n The hex file you received with the zip file that contained this file\n is calibrated for a ATTiny2313 running on the internal oscilator @ 4MHz\n and with the CKDIV8 fuse enabled. Therefore the processor is running at\n 500kHz.\n *\/\n\n \/\/#define DEBUG\n #ifdef DEBUG\n \/\/ can be enabled only if DEBUG is set\n #define DEBUG_ONSCREEN\n #endif\n\n #define SERIAL_NUMBER 1\n \/\/this is the seed for the random number generator. you may either use my\n \/\/serial number (1) or recompile it (unadvised) with your own.\n\n \/\/defs\n\n #ifdef __AVR_ATtiny13__\n #define BUZZER1() {sbi(PORTB,3);cbi(PORTB,4);}\n #define BUZZER0() {cbi(PORTB,3);sbi(PORTB,4);}\n #elif defined __AVR_ATtiny2313__\n #define BUZZER1() {sbi(PORTB,0);cbi(PORTB,1);}\n #define BUZZER0() {cbi(PORTB,0);sbi(PORTB,1);}\n #endif\n #define BEEP_INTERVAL 0.08\n #define BEEP_LENGTH 2500\n #define nop() asm volatile (\"nop;\")\n\n \/\/globals\n volatile unsigned int rand_cond=0;\n volatile unsigned int rand_box=0;\n\n \/\/function prototypes\n void beep(void);\n void wait(unsigned int);\n void tone(unsigned int, unsigned int);\n\n #define _ms(x) x*45\n\n \/\/timer overflow interrupt. occurs each 0.5seconds.\n\n #ifdef __AVR_ATtiny13__\n ISR(TIM0_OVF_vect)\n #elif defined __AVR_ATtiny2313__\n ISR(TIMER0_OVF_vect)\n #endif\n {\n rand_box++;\n #ifdef __AVR_ATtiny13__\n \/\/ alive flashing led on timerIT\n if(rand_box&amp;1) sbi(PORTB,0); else cbi(PORTB,0);\n #endif\n return;\n }\n\n int main(void)\n {\n\n #ifdef __AVR_ATtiny13__\n DDRB = _BV(3) | _BV(4)|_BV(0); \/\/ output on pin 2&amp;3 so no interaction w\/SPI nor RESET\n\n ACSR = _BV(ACD); \/\/disable power to the analog comparator\n TCCR0B=_BV(CS02) | _BV(CS00); \/\/ CLK_IO\/1024\n TIMSK0 = _BV(TOIE0); \/\/ Timer 0 Overflow Interrupt Enable\n\n #elif defined __AVR_ATtiny2313__\n DDRD = 0x00;\n DDRB = _BV(1) | _BV(0);\n\n ACSR=0x80;\/\/disable power to the analog comparator\n TCCR0B=0x05;\n TIMSK = 0x02;\n #else\n \/\/ other types could be tested here\n DDRD = 0x00;\n DDRB = _BV(1) | _BV(0);\n\n ACSR = _BV(ACD); \/\/disable power to the analog comparator\n TCCR0B=_BV(CS02) | _BV(CS00); \/\/ CLK_IO\/1024\n TIMSK = _BV(TOIE0); \/\/ Timer 0 Overflow Interrupt Enable\n #endif\n\n srand(SERIAL_NUMBER);\n\n \/\/ wait(_ms(100));\n beep();\n wait(_ms(1000U));\n\n int i,j;\n \/\/for(i=)\n\n BEEP_INTERVAL 0.08\n #define BEEP_LENGTH 2500\n\n sei();\n while(1)\n {\n if(rand_box==rand_cond)\n {\n rand_box=0;\n #ifdef DEBUG\n rand_cond=rand_box+60; \/\/30sec\n #else\n rand_cond=rand()%(0xFFFF-1000)+1000;\n #endif\n beep();\n }\n }\n }\n\n void beep()\n {\n unsigned int temp;\n for(temp=0;temp!=BEEP_LENGTH;temp++)\/\/does the beeping on the piezo.\n {\n BUZZER0();\n wait(_ms(BEEP_INTERVAL));\n BUZZER1();\n wait(_ms(BEEP_INTERVAL));\n }\n return;\n }\n\n void tone(unsigned int freq, unsigned int len)\n {\n\n while(len--)\n {\n BUZZER0();\n wait(_ms(len));\n BUZZER1();\n wait(_ms(len));\n }\n }\n\n void wait(unsigned int a)\n {\n unsigned int b,c;\n\n #ifndef DEBUG_ONSCREEN\n for(b=0;b!= a; b++)\n for(c=0;c!= 5;c++)\n nop();\n #endif\n\n return;\n }<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>The purpose of this device is a bit evil. Oh well, sue me. I made it as a yoke for the first of april and many more days to come. A brief description: The device beeps a short beep of &hellip; <a href=\"https:\/\/www.daqq.eu\/?p=276\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8,19],"tags":[10],"class_list":["post-276","post","type-post","status-publish","format-standard","hentry","category-projects","category-simple-mcu-stuff","tag-avr"],"_links":{"self":[{"href":"https:\/\/www.daqq.eu\/index.php?rest_route=\/wp\/v2\/posts\/276","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.daqq.eu\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.daqq.eu\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.daqq.eu\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.daqq.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=276"}],"version-history":[{"count":5,"href":"https:\/\/www.daqq.eu\/index.php?rest_route=\/wp\/v2\/posts\/276\/revisions"}],"predecessor-version":[{"id":1788,"href":"https:\/\/www.daqq.eu\/index.php?rest_route=\/wp\/v2\/posts\/276\/revisions\/1788"}],"wp:attachment":[{"href":"https:\/\/www.daqq.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=276"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.daqq.eu\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=276"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.daqq.eu\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=276"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}