Control Chauvet Hurricane 1301 with external relay and arduino

I bought a Chauvet Hurricane 1301 for its massive smoke output: my aim is to build a low-cost but extremely effective security and anti theft smoke shield and fog bandit clone, by using nothing more than your average disco fog machine… well, at least a renowned powerful fog machine at that. The specs about the consumption are pretty much the same: 1200W nominal power, and about 50W average when turned on to keep the temperature of the liquid constant. What this system lacks, is the “stamina” that professional systems have, since it won’t fill a room with only the first burst of smoke, but it’s not that much delay between the first puff and the second, and you still get the surprise effect. Ideal for not-so-big rooms.

But you may want to use it to spray smoke when certain events happen, like music timed puffs, or pressure plates, you name it.

There is no immediate way to do it: the wired remote doesn’t provide simple short contacts: none of the pins get shorted when you press the “manual” button there, so it must be a powered remote that sends out powered signals.

Solution: catch the short contact given by the manual switch on the machine’s rear panel.

chauvet hurricane 1301 pcb switches cables
Open your Hurricane 1301 by removing the clearly visible screws on the sides and on top, this is the electronics board where the cables from the button and DIN plugs in the rear end; here I had plugged two jumper cables in the switch plug, I just pushed them on the side of the female connectors inside the plastic plug


chauvet hurricane 1301 manual switch derivation
Pull the cables behind the board to get them out from the tank housing.


chauvet hurricane 1301 tank housing
Here you see where I made the jumper cables come out from. Since that hole is where the tank’s bulge protrudes to stabilize it, you won’t be able to use large cables (not that you need to anyway) otherwise you won’t be able to fit the tank.


chauvet hurricane 1301 manual switch completed derivation
Since I had really short jumper cables, I ended up using 6 of them (!) plugged together, and placed a zip tie in the grill to fix them onto the chassis.


chauvet hurricane 1301 manual switch outet
After you close everything, you now have an outlet you can connect to a relay, regulaed for example by an arduino.


So what about my homemade smoke shield clone system? I just need to find an alarm sensor to wire up to an arduino, to which will be also wired a relay going to the Hurricane 1301.

Plastic bottle PET filament extrusion for 3d printer: experiments

This will not be a guide to build your own filament extruder, there’s already a very good guide by Ian McMill on instructables, which incidentally I followed to build my own version.

This is a report of my own experience with trying to obtain 3d-printer-worth filament out of plastic PET bottles.

I was enthusiastic of this video of the russian survivalist The Lawyer Egorov (who by the way has a supercool channel on youtube for you hardcore people):

who built a contraption to get a very strong string (pun not intended) out of scrap plastic bottles. This, I thought, would have been great fodder for my next to be PET filament machine.

Fast forward to yesterday night/this morning. I had been sourcing parts off the local shops and eletronics from foreign sellers on ebay, and in the spare time finally built this revision of my machine:

DIY filament extruder

DIY filament extruder, internal electronics
This is the electronics panel, where you can see a SSR, three switches, a PID, and a motor speed controller. The 12V power supply lies on the back.


Extruder motor with fan
This is the motor, taken from the electric window of a honda civic, off ebay, supercheap (I looked all around for it). Most of the metal parts were taken from a local shop. Fan is absolutely needed as the motor gets really hot after a while. You can also see the coupling, with a force breaker plate, and a couple of exagonal keys. I had to shape the coupler square rod myself out of a bigger square rod. Ugh never again.


Extruder tubular assembly
This is the point where the auger bit gets into the tubular assembly, I used several L shaped plates to keep the assembly strictly in place. You can see the push bearing in place, and a closeup of the T junction I used instead of cutting out a window in the metal pipe.


diy extuder nozzle thread
I had experimented with PET already the late evening before this shoot, at 260°C the plastic inside the nozzle became sort of essiccated and very brittle but did not really melt.


extruder SSR
The SSR controlling the heating band circuit


extruder PID
The 220V and 12V lines molex’s, and the PID, a supercheap REX C100 off ebay, chinese replica, SSR version, once and for all this is the pinout: 1-2 AC input to power up the PID, 4-5 the DC output to close the circuit with the SSR, 9-10 the pinout to the K thermocouple (mind the polarity, inverting it will give uncorrect readings)


DIY extruder motor controller
The motor controller, very easy to configure.


extruded PET
This is what was left in the nozzle from the night before, a solidified melted PET which had become grey in color, and was somewhat brittle.


solidified PET
The broken pieces of the stuff in the previous picture


glassy PET
There were also flakes of “glassy” unmelted PET which had become extremely brittle under the high temperature even if it didn’t melt (according to several sources, this is the crystallized form of PET, obtained by removing the water by heating to 80+°C for a certain amount of time, and this is exactly what happened the night before during my tests… this kind of pretreated PET should be the best kind for filament extrusion purposes).


melted PET inside extuder nozzle
Finally some melting was taking place after I raised the temperature to 270°C, the night before I only went up to 260°C (I started off thiking even maybe 190 would have done the trick, silly me!)


brown molten PET
I stuck a piece of PET string inside the pipe to scoop out some of the goo, and this is the result, a brown stuff solidified over the fresh PET.


After I noticed the PET inside the terminal part of the tube was melting, I started the motor, and this is what happened… not much as the pressure inside the tube was low, there wasn’t much material in the column, and since cutting BY HAND the PET string I had was superboring I didn’t really make the small flakes needed for them to be easily transported.

I increased the quantity of PET flakes in the intake, and pressed them down with a screwdriver handle, so the volume of melted mass on the front increased some.

At this point I decided to place the cap with the nozzle drilled in (1.5mm diameter) and in fact some goo started flowing out and quite rapidly solidifying; the quality of this solidified goo appeared “better”, as the surface was very shiny, but it soon stopped flowing out, and when later I unscrewed the cap I realized it was clogged, as a lot of melted material was idling back there and quickly blobbed outside.

extruded PET droplets
The “extruded filament” I got, a couple of little blobs of PET which quickly solidified and became grey from the brownish pulp it was before.

So this is the scenario that presented itself when I uncapped the tube:

molten PET flowout
The molten PET flowed right out of the tube as soon as I uncapped it, the nozzle had probably clogged giving this outcome. The material is soft-ish anyway, and doesn’t pose a big deal in being removed noteven from the threaded insides of the cap.

At this point I decided my adventure with PET had come to an end. Or rather, my experiments did, since I decided since the night before that I wouldn’t be making PET filament for my 3D printer out of plastic bottles: the processing required to this objective it WAY too much. You need to find a way to satisfactorily grind the plastic, after obviously you cleaned the bottles, and after that you should still dry the flakes at 80°+ degrees to avoid water buildup inside which would drasticaly decrease the final product quality. I would totally prefer spending 20€ per roll of cheap black PLA over this.

You also need to take into account the real life scenario, that is, PRINTING with said filament, because that’s the reason you’re doing it, apart from the fact that you’re just a hopeless nerd like me. A printer’s nozzle is SMALL, and nasty things, even if tiny, can clog it; if said nasty things are inside the filament, then no filament filter is going to hep you; they WILL pile up in the nozzle and sooner than later you’ll have to disassemble the nozzle assembly and do nasty things to take it out, like flaming the nozzle to melt the stuff inside and scooping it out with a piece of filament. Don’t trust the cold pull, it didn’t help me when I needed it. Flaming the nozzle instead, it did help me.
Finally, you have to get a decent diameter filament, AND getting that diameter the most constant possible, because if on one side you can change the extrusion rate in your slicing program to take into account the real filament size, on the other there’s nothing you can do to balance a poorly sized filament, and either you will get extruder skipping steps because of a too big filament, or an extruder skipping steps because the filament is too tiny.

In my brightest dreams I supposed I would be producing crystal clear filament out of plastic bottles, heck maybe even multicolored transparent filament since all bottles are slightly coloured.

failed plastic bottle PET filament extrusion experiment
The aftermath of the experiment. You can see the spare PET string I had previously made and originally intended to feed inside the tube.


Final tecnical considerations
By Ian’s own words, with which I agree, the downfall of this method is the feed system: PET can be a great material, yet a DIY extruder like this one does not allow for much leeway, you need to keep the material flowing forward, and for this you need a granulate which can progress easily in the pipe, and at the same time you also need a constant supply in the back.
So, first off, you need to have a ready made supply of flakes, and obviously cannot just improvise by cutting little piece by little piece on the fly like I did (I was desperate to try, I admit it), and even better you need proper sized pellets, not too large but sufficiently thick! Since PET flakes are flat, they easily adjust in the space between the auger bit and the pipe, and they do not progress further very well; also, if you use a string of PET, it will just roll around the auger in one place (where you feed it through) and not progress forward, but instead slowing down and loading heavily the motor by creating a thick wrap on the drill.
You MIGHT melt bottles whole as they are (how?), and use the obtained solidified blob to create smaller pellets, maybe by hammering the glass-like goo. Still, it will take time, and it’s a messy procedure. Unless you can devise a method to do it without much human intervention, it’s going to cost resources anyway, and you may reconsider the whole thing, and maybe just buy pre-made filament, or a commercial extruder plus finding a local supplier of ABS pellets (not your average ebay seller who asks outrageous sums for 3d printing pellets, but a local plastics industry which works with pellets to make for example injection molded items, where you would pay as low as 2€ per kg of granulate).


And now some resources:

  • HDPE filament from milk jugs extrusion test (middle part of a trilogy):



phpBB: set gravatar as default for new users

Self reference: edit /includes/function_user.php as follows:

'user_avatar'         => strtolower($user_row['user_email']),
 'user_avatar_type'      => 'avatar.driver.gravatar',
 'user_avatar_width'      => 60,
 'user_avatar_height'   => 60,

also edit /phpbb/avatar/driver/gravatar.php and change:

$url .= '?s=' . max($row['avatar_width'], $row['avatar_height']);


$url .= '?s=' . max($row['avatar_width']."&d=identicon", $row['avatar_height']);

so users who are not registered with gravatar get an automatically generated icon istead of mystery man.

Add custom social media share icon buttons in phpBB

Self reference article: how to add responsive social media share icons on your forum for each page.

HTML to add to /styles/stylename/template/over_header.html, right under <div id="page-header" class="page-width">

 <div id="socialshare" data-expendable="yes">
 <a class="twittersharebutton" href="{SOCIAL_URL}" target="_blank">t</a>
 <a class="facebooksharebutton" href="{SOCIAL_URL}" target="_blank">f</a>
 <a class="googlesharebutton" href="{SOCIAL_URL}" target="_blank">g</a>

CSS to add at the bottom of <head> section of same file:

 #socialshare {
a.twittersharebutton, a.facebooksharebutton, a.googlesharebutton {
 text-decoration: none;
a.twittersharebutton {
a.facebooksharebutton {
a.googlesharebutton {
 line-height:60% !important;
#socialshare a:hover {
@media (min-width: 1100px) {
 #socialshare {
#socialshare>div {
 width: 50px;
a.twittersharebutton, a.facebooksharebutton, a.googlesharebutton {
 #page-header {position:relative;}
@media (max-width:1099px) {
 #socialshare {
a.twittersharebutton, a.facebooksharebutton, a.googlesharebutton {

Code to add in /includes/functions.php, in the template variable assignment (look for LAST_VISIT_DATE)

'SOCIAL_URL' => urlencode(generate_board_url() . '/' . $user->page['page']),

Reload, all done!

Dominant color of image as background of DIV, all in CSS

I was trying to do something fancy, and have a grayscale image turned into colored mode on mouse hover, together with showing a popup… and I obviously wanted the popup background color to be related to the image that had just been coloured up.

There is a precise javascript function that does that, it’s the color thief plugin for jQuery. Other than needing javascript to achieve the result (which may be fine), it wasn’t viable in my situation because it cannot work cross-domain with images stored on a different website from the one calling the javascript.

My original idea was to have it all done in CSS anyway, so a bright idea popped into my mind: why not using the browser itself to find the dominant color? And when does the browser find the dominant color of an image? When you resize it to 1pixel x 1pixel.


background-size: 1px 1px;

that’s all for the basics.

If you want to make the colour stand out more, but only in non Internet Explorer browsers (thank you Microsoft) then to those declarations you can add:

-webkit-filter: saturate(5);
filter: saturate(5);

You obviously have to insert this code in the relevant place of your page… be it with hardcoded values (but if they were, wou wouldn’t be here asking how to DINAMICALLY find the dominant colour of an image) or with PHP or anything else in the backend directly inside a style="..." CSS statement inside the HTML tag.

The background colour may be too dark for black text, or too bright for white text depending on the image, so unless you want to apply an ugly text-shadow all around the characters to make them always readable (not so much actually, unless you’re using huge fonts), you may want to have a container DIV with a couple of DIVs inside, one holding the background, with half opacity, and the other containing the text, both with 100% width and height, and absolutely positioned to top:0;left:0; inside the container, maybe with a z-index:-1; on the background div.

Have fun!

403 Permission denied on Apache in Debian/Ubuntu with changed document root

I had just made a brand new installation of both Ubuntu trusty and vivid and Debian jessie (tried all of them) on my android phone with Linux Deplow, and installed the LAMP stack via SSH. I wanted Apache to serve files decrypted from an EncFS mount, so I found easier to move the DocumentRoot to a subfolder of my home (by editing /etc/apache2/sites-available/000-default.conf – by the way, this file has changed location quite a bit in the past, being called just default.conf, or being httpd.conf in older versions), and changed Apache’s username to my own (by editing /etc/apache2/envvars).

Well, what happened is that, no matter what I did, I was still getting a 403 Permission denied error, which had nothing to do with EncFS.

By pure chance, I went checking what was inside /etc/apache2/apache2.conf, and other than a reference to envvars for the username and group definitions for the user Apache is run as, scrolling further down there are folders definitions which were, in previous versions, located in the default.conf file. Changing in there the reference to /var/www into the new custom folder made it.

You obviously need to restart Apache after such changes.

AFWall+ and Linux Deploy, no internet access unless firewall is disabled

This is a personal reminder and also an easier-to-find heads up to those looking for a solution: if you installed linux on Android via Linux Deploy, and find that, no matter how you set rules on AFWall+ you can never get internet to the mounted linux image, unless you disable the firewall altogether (not recommendable since you installed a firewall in the first place), then here is the solution provided in this thread (it’s all due to DNS calls being blocked without a possibility to make them pass through in the vanilla AFWall+).

Under AFWall+ contextual menu, open the custom script editor, and inser these lines:


$IPTABLES -A afwall-wifi -m owner --uid-owner root -p udp --sport=67 --dport=68 -j RETURN
$IPTABLES -A afwall-wifi -m owner --uid-owner nobody -p udp --sport=67 --dport=68 -j RETURN
$IPTABLES -A afwall-wifi -m owner --uid-owner root -p udp --sport=53 -j RETURN
$IPTABLES -A afwall-wifi -m owner --uid-owner nobody -p udp --sport=53 -j RETURN
$IPTABLES -A afwall-wifi -m owner --uid-owner root -p tcp --sport=53 -j RETURN
$IPTABLES -A afwall-wifi -m owner --uid-owner nobody -p tcp --sport=53 -j RETURN
$IPTABLES -A afwall-3g -m owner --uid-owner root -p udp --dport=53 -j RETURN
$IPTABLES -A afwall-3g -m owner --uid-owner nobody -p udp --dport=53 -j RETURN
$IPTABLES -A afwall-3g -m owner --uid-owner root -p tcp --dport=53 -j RETURN
$IPTABLES -A afwall-3g -m owner --uid-owner nobody -p tcp --dport=53 -j RETURN

making sure you preserve the line return after each RETURN since pasting directly into the tiny textbox of AFWall+ may lose the carriage returns.

BAM you will have internet from your android linux without having to disable the firewall. Naturally, you will also have to enable internet access to “Applications running as root”.

Update: as per Peter’s suggestion in the comments (thank you Peter!) if you still get errors with this approach you may need to add a couple more lines, like so:

$IPTABLES -A afwall-wifi-wan -m owner –uid-owner 5000 -j RETURN
$IPTABLES -A afwall-wifi-lan -m owner –uid-owner 5000 -j RETURN

where “5000” is an id you have to customize to your needs, and you can get it either from AFWall’s errors logs, or by checking the /etc/passwd file for the current user’s entry.

Enable Dolby Digital Live Surround 5.1 in Far Cry 4 and Watchdogs

Self reference, and also a heads up for those people looking into listening to 5.1 surround sound in Far Cry 4 and Watchdogs which usually play no sound when Dolby Digital is enabled.

This was tested and works in my configuration using a Sound Blaster USB Surround Pro X-Fi, and doesn’t involve any patch or hack, but a simple linear procedure; the first step is to download the latest drivers from Creative website (may ’14), and then, as the good sir melgu said on steamcommunity:

  • Open Creative Entertainment Console
  • Click on the Dolby Digital Live icon
  • Check the second box (a warning will appear, read it to undestand what it does, then accept clicking Yes)
  • Open Change Sound Card Settings from Windows Start Menu, and set the entry Speaker (Sound Blaster blahblah) as the default peripheral
  • Test your games


Samba share connection doesn’t accept user:password login from Windows

This is mainly a self-reference for when I find myself reinstalling Samba on my home server, if something goes wrong and the previous system got corrupt, or if I am upgrading something.

It happens, ALWAYS, that I setup a share with a login, which is the same of the user on the server the share resides into, and when I insert that login info in the Windows dialogue that appears, it just gives me an access denied error, as if the password I inserted wasn’t correct.

What I forget to do, every single time, is to create first a samba user with

sudo smbpasswd -a username

and then using those credentials (which you can create as matching the linux user’s) in the windows dialogue.

Change the user Transmission Debian daemon runs under and avoid warning message

I am writing this post also for personal reference (and currently I am writing in bare HTML since my WordPress installation lacks an updated multilanguage plugin to be able to use the WYSIWYG editor).
I was moving my home server from a slow Raspberry PI to a way faster Cubieboard 2, and got to reinstall Transmission daemon. I needed to change its user tho, because I needed a certain folder to be accessible to it.
So I edited as SU the /etc/init.d/transmission-daemon file changing the transmission-debian value into the username I wanted to use, but I kept getting a (warning) message when trying to start the daemon.
Long story short, here are some tips you have to follow, but first credits where they’re due:
This is the page where I got started the first time:
And this is a heads up I got while trying to solve this problem:

So, back on track:
1) Make sure the transmission daemon is stopped, otherwise changes you make to configuration files will be reverted to original
2) Edit the init.d starting script changing the username to your wanted username
3) chown the default transmission-debian folders to the user you need:

sudo chown username:group /var/lib/transmission-daemon/info –R
sudo chown username:group /etc/transmission-daemon/ –R

4) If you are importing a settings.json file from a previous installation, make sure to copy it to both /etc/transmission-daemon/ and /var/lib/transmission-daemon/info/ so that both copies are identical
5) You can now start the daemon and everything should work as expected

The headquarters of Ephestione, online since 2001