<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Daniel Andrade</title>
	<atom:link href="http://danielandrade.net/feed/" rel="self" type="application/rss+xml" />
	<link>https://danielandrade.net</link>
	<description>Electronics, Web, Travel &#38; More</description>
	<lastBuildDate>Fri, 11 Dec 2020 14:34:22 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	
	<item>
		<title>Adding a DIY Hotspot to the Helium Blockchain</title>
		<link>https://danielandrade.net/2020/09/28/adding-a-diy-hotspot-to-the-helium-blockchain/</link>
					<comments>https://danielandrade.net/2020/09/28/adding-a-diy-hotspot-to-the-helium-blockchain/#comments</comments>
		
		<dc:creator><![CDATA[dansku]]></dc:creator>
		<pubDate>Mon, 28 Sep 2020 15:26:04 +0000</pubDate>
				<category><![CDATA[Engineering]]></category>
		<category><![CDATA[Helium]]></category>
		<guid isPermaLink="false">https://www.danielandrade.net/?p=3530</guid>

					<description><![CDATA[<p>If you got the invitation code to be part of the helium alpha program, I am showing how to use it to make your DIY hotspot "REAL"!</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2020/09/28/adding-a-diy-hotspot-to-the-helium-blockchain/">Adding a DIY Hotspot to the Helium Blockchain</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></description>
										<content:encoded><![CDATA[<div class="embed-responsive embed-responsive-16by9">
    <iframe class="embed-responsive-item"  src="https://www.youtube.com/embed/SzFWSv6UcIE"></iframe>
</div>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2020/09/28/adding-a-diy-hotspot-to-the-helium-blockchain/">Adding a DIY Hotspot to the Helium Blockchain</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://danielandrade.net/2020/09/28/adding-a-diy-hotspot-to-the-helium-blockchain/feed/</wfw:commentRss>
			<slash:comments>5</slash:comments>
		
		
			</item>
		<item>
		<title>Running a Helium Miner on DigitalOcean</title>
		<link>https://danielandrade.net/2020/08/23/running-a-helium-miner-on-digitalocean/</link>
					<comments>https://danielandrade.net/2020/08/23/running-a-helium-miner-on-digitalocean/#comments</comments>
		
		<dc:creator><![CDATA[dansku]]></dc:creator>
		<pubDate>Sun, 23 Aug 2020 17:53:36 +0000</pubDate>
				<category><![CDATA[Cryptocurrency]]></category>
		<category><![CDATA[Engineering]]></category>
		<category><![CDATA[Software]]></category>
		<guid isPermaLink="false">https://www.danielandrade.net/?p=3430</guid>

					<description><![CDATA[<p>In this tutorial, we are going to configure a brand new $5/month DigitalOcean server that will run one or multiple Helium miners. Note that by using the link above, you will be rewarded with a $100 credit bonus that is valid for two months, which is perfect to test the platform and also two months [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2020/08/23/running-a-helium-miner-on-digitalocean/">Running a Helium Miner on DigitalOcean</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><img src="https://www.danielandrade.net/wp-content/uploads/2020/08/title.jpg" /></p>
<p>In this tutorial, we are going to configure a brand new <strong><a href="https://bit.ly/2oTLFrG" rel="noopener noreferrer" target="_blank">$5/month DigitalOcean</a></strong> server that will run one or multiple Helium miners. <em>Note that by using the link above, you will be rewarded with a <strong>$100 credit bonus</strong> that is valid for two months, which is perfect to test the platform and also two months of free miner hosting!</em></p>
<p>I am not going to get into details about what <strong>Helium</strong> is and how to use it, but it&#8217;s an amazing project where people all around the world are getting together to build a HUGE LoraWAN mesh network to enable anyone to have access to an almost-free IoT network. To check more, go to <a href="https://www.helium.com" rel="noopener noreferrer" target="_blank">https://www.helium.com</a>.</p>
<p><span id="more-3430"></span></p>
<h3 style="margin-top:60px">This tutorial video</h3>
<p><iframe loading="lazy" width="560" height="315" src="https://www.youtube.com/embed/rR2Z0vOufLM" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></p>
<p>If this video helped you, please consider donating to:</p>
<ul>
<li>BuyMeACoffee &#8211; <a href="https://www.buymeacoffee.com/dspillere" rel="noopener noreferrer" target="_blank">https://www.buymeacoffee.com/dspillere</a></li>
<li>BTC &#8211; bc1qwn59fjhmz2wy376y6vltjj73a63j0nzaapu42f</li>
<li>ETH &#8211; 0x2b4d4a660CddaE942C26821a5512c32023719476</li>
<li>HNT &#8211; 14bnEtUmqPaCrXmjzQ8XasTJhz7hfyWY9gt2ByqUdvBJVVEczmr</li>
</ul>
<h3 style="margin-top:60px">Create a new DigitalOcean Server</h3>
<p>After creating your DigitalOcean account, log in, and create a new Droplet like the gif below:<br />
<img src="https://www.danielandrade.net/wp-content/uploads/2020/08/docker_image.gif"/></p>
<p>Once your droplet has finished provisioning, you will be able to connect to it using the provided IPv4 address and the password that you used on the previous step. For this tutorial, the server IPv4 is <b>104.131.116.132</b>, remember this as we will use it in many future steps.</p>
<p><img loading="lazy" src="https://www.danielandrade.net/wp-content/uploads/2020/08/img01.png" alt="" class="alignnone size-full wp-image-3441" width="973" height="431"/></p>
<p>Let&#8217;s connect to the server using the terminal. If you are on Mac you can use <a href="https://www.iterm2.com/" rel="noopener noreferrer" target="_blank">iTerm</a>, and if you are on Windows, I recommend checking out the <a href="https://github.com/microsoft/terminal" rel="noopener noreferrer" target="_blank">Windows Terminal</a>. If you have any questions, just fill out the comment form with your questions and I will do the best to help you out!</p>
<p>To connect to the server, on the terminal, type <code>ssh root@104.131.116.132</code> (change the IP to your own server address), type <b>yes</b> and the <b>password</b>.</p>
<p>If you see <b>root@helium-miner:~#</b>, this means that you are connected! Type <code>apt update &amp;&amp; apt upgrade</code> to make sure we have all programs running on the latest version!</p>
<p>Good job, let&#8217;s move on to the next steps.</p>
<p>Let&#8217;s check if docker is working by typing <code>docker ps</code>:<br />
<img loading="lazy" src="https://www.danielandrade.net/wp-content/uploads/2020/08/docker_test.png" alt="" class="alignnone size-full wp-image-3448" width="1076" height="99"/></p>
<h3 style="margin-top:60px">Opening Ports</h3>
<p>From the <a href="https://developer.helium.com/blockchain/run-your-own-miner" rel="noopener noreferrer" target="_blank">helium miner documentation</a>: <em>Before launching the Miner, you will want to configure ports on your network to forward two ports:</em></p>
<ul>
<li>44158/TCP: the Miner communicates to other Miners over this port. The networking logic knows how to get around a lack of forwarding here, but you will get better performance by forwarding the port.</li>
<li>1680/UDP: the radio connects to the Miner over this port. You will not be able to forward packets or participate in Proof of Coverage without this.</li>
</ul>
<p>
This means that for the miner, we need to open ports <strong>44158/TCP</strong> and <strong>1680/UDP</strong>, to do so, type <code>ufw allow 44158/tcp</code> and <code>ufw allow 1680/udp</code>.</p>
<p><img src="https://www.danielandrade.net/wp-content/uploads/2020/08/add_rules-1.png"/></p>
<hr />
<h3 style="margin-top:60px">Running your container</h3>
<p>It&#8217;s time to configure and install the miner. First of all, let&#8217;s create a folder where we will store all the miner files. On the terminal, type <code>mkdir ~/miner_data</code> to create an empty folder where all the miner data will resid.</p>
<p>Create a file caller <b>runMiner.sh</b> with <code>nano runMiner.sh</code> and type the following code block:</p>
<pre>docker run -d \
--env REGION_OVERRIDE=EU868 \
--restart always \
--publish 1680:1680/udp \
--publish 44158:44158/tcp \
--name miner \
--mount type=bind,source=/root/miner_data,target=/var/data \
quay.io/team-helium/miner:miner-amd64_2020.08.21.0_GA</pre>
<p>You need to change two lines on the block, the first is to make sure you are using the right <strong>REGION_OVERRIDE</strong> frequency to:</p>
<p><b>US915 | EU868 | EU433 | CN470 | CN779 | AU915 | AS923 | KR920 | IN865</b><br />
As I am in Europe, I am going with <strong>EU868</strong> (Europe, frequency 868Mhz).</p>
<p>The second part that you need to update is the last line, where you need to select the right docker image. You can get the latest version at <a href="https://quay.io/repository/team-helium/miner?tab=tags" rel="noopener noreferrer" target="_blank">https://quay.io/repository/team-helium/miner?tab=tags</a>. For this server, make sure to use an amd64 image such as <strong>miner-amd64_2020.08.21.0_GA</strong>, which is the latest one (at the time I am writing this).</p>
<p>At this point, everything is ready to go! All you need to do is to start the miner using <code>sh runMiner.sh</code> and it should start!!! The first thing docker will do is check if you have the images on your server, which you don&#8217;t, and download them. Then it will automatically start the miner, which will then start syncing with the blockchain!</p>
<p>To check if the image is running, type <code>docker ps</code>, and the result should be something similar to this:</p>
<p><img loading="lazy" src="https://www.danielandrade.net/wp-content/uploads/2020/08/running.png" alt="" class="alignnone size-full wp-image-3487" width="1596" height="54"/></p>
<p>On your gateway, point it to our server <b>104.131.116.132</b> and you will be good to go!</p>
<hr />
<h3 style="margin-top:60px">Extras</h3>
<h4>Backup your swarm key</h4>
<p>This step is extremely important! Once helium enables miners to actually mine HNT tokens, you will need to pay $50 to join the network, and if you lose the key, you will need to purchase a new one! </p>
<p>To back up the key, go to the miner folder <code>~/miner_data/miner</code>, and inside you will find a file called <strong>swarm_key</strong>. Make sure you save this somewhere safe for future use. (If something goes wrong with the server, this is the only file that will enable you to recover your miner!)</p>
<h4>Check if the blockchain is in sync</h4>
<p>The command <code>docker exec miner miner info height &amp;&amp; curl https://api.helium.io/v1/blocks/height</code> will compare the height of the blockchain we have on the server with the real one. Once the two numbers match, it means that our server is fully in sync and ready to roll!</p>
<p><img src="https://www.danielandrade.net/wp-content/uploads/2020/08/sync.png"/></p>
<p>As you can see in the image above, my server is yet not in sync as locally I have <strong>455760</strong> and the official block height is <strong>465893</strong>.</p>
<h4>Running multiple miners on the same server</h4>
<p>To run a second miner, you need to open two new ports, <strong>1681/udp</strong> and <strong>44159/tcp</strong> with <code>ufw allow 44159/tcp</code> and <code>ufw allow 1681/udp</code>.</p>
<p>Create a new folder for the miner data with <code>mkdir ~/miner_data2</code>, create a new <strong>runMiner2.sh</strong> and edit the file as suggested below:</p>
<pre>docker run -d \
--env REGION_OVERRIDE=EU868 \
--restart always \
--publish 1681:1680/udp \
--publish 44159:44158/tcp \
--name miner2 \
--mount type=bind,source=/root/miner_data2,target=/var/data \
quay.io/team-helium/miner:miner-amd64_2020.08.21.0_GA</pre>
<p>Then to run it, simply type <code>sh runMiner2.sh</code>.<br />
To test the block sync, use <code>docker exec miner2 miner info height &amp;&amp; curl https://api.helium.io/v1/blocks/height</code></p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2020/08/23/running-a-helium-miner-on-digitalocean/">Running a Helium Miner on DigitalOcean</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://danielandrade.net/2020/08/23/running-a-helium-miner-on-digitalocean/feed/</wfw:commentRss>
			<slash:comments>42</slash:comments>
		
		
			</item>
		<item>
		<title>My Overnight Sensation Speaker Build</title>
		<link>https://danielandrade.net/2020/02/21/my-overnight-sensation-speaker-build/</link>
					<comments>https://danielandrade.net/2020/02/21/my-overnight-sensation-speaker-build/#comments</comments>
		
		<dc:creator><![CDATA[dansku]]></dc:creator>
		<pubDate>Fri, 21 Feb 2020 21:12:27 +0000</pubDate>
				<category><![CDATA[Electronics]]></category>
		<category><![CDATA[Engineering]]></category>
		<category><![CDATA[Hardware]]></category>
		<guid isPermaLink="false">https://www.danielandrade.net/?p=3311</guid>

					<description><![CDATA[<p>When living in Berlin, back in 2016, I used to own a pair of M-Audio speaker monitors and I loved them, such an insane improvement from my computer or tv speakers. Unfortunately, I didn&#8217;t manage to take them with when I moved to Lisbon in early 2018. After a few months in the new city, [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2020/02/21/my-overnight-sensation-speaker-build/">My Overnight Sensation Speaker Build</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/header.jpg" alt="overnight sensation speaker build" /></p>
<p>When living in Berlin, back in 2016, I used to own a pair of <b><a href="//amzn.to/37InMax" target="_blank" rel="noopener noreferrer">M-Audio</a></b> speaker monitors and I loved them, such an insane improvement from my computer or tv speakers. </p>
<p>Unfortunately, I didn&#8217;t manage to take them with when I moved to Lisbon in early 2018. After a few months in the new city, I decided that instead of buying a new set of monitor speakers, I was going to build one myself. Even have used a known design, there were many things that I had to custom build, and this is why I am writing this blog post, to share the process that took me from concept until the end. And I have to say, it turned out much better than expected ðŸ¤ ! </p>
<p><span id="more-3311"></span></p>
<h2>The speaker</h2>
<p>The Overnight Sensation speaker was designed by <a href="//sites.google.com/site/undefinition/diy-overnightsensations" target="_blank" rel="noopener noreferrer">Paul Carmody</a> to be an easy speaker build with amazing sound quality, and by his own words: </p>
<p><i>The &#8220;Overnight Sensations&#8221; were designed to be just that: a quick, economical build that could put out a surprisingly-big sound in a small box. Could be a weekender project for an addict, a gift for a teenager (see above), or&#8211;in my case&#8211;a set of small, full-bodied monitors that I could listen to while I graded papers.  (Ironically, I have found that if the music sounds too good while I am trying to concentrate, I get distracted and get no work done.)</i></p>
<p><b></p>
<p style="text-align: center;">ðŸ¤˜ So let&#8217;s get started ðŸ¤˜</p>
<p></b></p>
<h3>Component list</h3>
<ul>
<li>2x Dayton Audio DNR-10 10 Ohm 10W Precision Audio Grade Resistor</li>
<li>2x Dayton Audio DNR-6.0 6 Ohm 10W Precision Audio Grade Resistor</li>
<li>2x Dayton Audio DMPC-0.22 0.22uF 250V Polypropylene Capacitor</li>
<li>2x Dayton Audio DMPC-1.5 1.5uF 250V Polypropylene Capacitor</li>
<li>2x Dayton Audio DMPC-2.2 2.2uF 250V Polypropylene Capacitor</li>
<li>2x Dayton Audio DMPC-6.8 6.8uF 250V Polypropylene Capacitor</li>
<li>2x Jantzen 1204 0.35mH 20 AWG Air Core Inductor</li>
<li>2x Jantzen 1078 1.1mH 18 AWG Air Core Inductor</li>
<li>2x Port Tube 1-3/8&#8243; ID Adjustable</li>
<li>2x Dayton Audio ND20FA-6 3/4&#8243; Neodymium Dome Tweeter</li>
<li>2x HiVi B4N 4&#8243; Aluminum Midbass Round Frame</li>
</ul>
<p><b>Note:</b> You can currently buy the kit from <a href="//www.parts-express.com/overnight-sensations-mt-speaker-kit-pair--300-706" target="_blank" rel="noopener noreferrer">parts-express</a>, which would make things easier, but as I am living in Europe, I had to find other places to buy the parts. Most parts came from <a href="//www.soundimports.eu">soundimports.eu</a> and <a href="//hificollective.co.uk" target="_blank" rel="noopener noreferrer">hificollective.co.uk</a>. (PS: Stay away from <em><b>loudspeakerfreaks</b></em> as they are scammers).</p>
<h3>Building the audio cabinet</h3>
<p>For the cabinet, I decided to go with an <b>18mm</b> pine-wood sheet, as it is sturdy and looks nice. In case you are going to completely paint the cabinet, you can also go with plywood, which is a bit cheaper. </p>
<p><img loading="lazy" src="//www.danielandrade.net/wp-content/uploads/2020/02/20200221_152738.png" alt="" width="1238" height="716" class="alignnone size-full wp-image-3377" /></p>
<p>To have a better understanding of the cabinet size, I based on the original designs and adapted to the 18mm sheet width and made a few modifications. The model was made using Autodesk&#8217;s Fusion 360, which you can download the 3D file <a href="//www.danielandrade.net/wp-content/uploads/2020/02/overnight_sensation_danielandrade.zip"><b>here</b></a>.</p>
<p>With all the sides carefully measured, I placed each side of the cabinet on a flat surface (the grey rectangle below represents the original full sheet) so that I could convert the files to be drilled using a CNC-machine. </p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/20200221_191021.png" alt="" /></p>
<p>Now it&#8217;s time to cut the wood, so I went to <a href="http://fablablisboa.pt/" target="_blank" rel="noopener noreferrer"><b>fablab lisboa</b></a> to use their machinery.</p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/cnc-min.gif" alt="" style="width:100%"/></p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/flat_sheets.jpg" alt=""  /></p>
<p>After having each single piece cut and sanded, it&#8217;s time to put our new speaker together with some <a href="//amzn.to/2uWwSn3" target="_blank" rel="noopener noreferrer">Wood Glue</a> and a couple <a href="//amzn.to/39UEXqS" target="_blank" rel="noopener noreferrer">straps</a>. I think the images are self-explanatory, but if you have any questions please let me know ðŸ˜…! </p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/glue.jpg" alt=""/></p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/glued.jpg" alt="" /></p>
<p>Wow, it&#8217;s not looking too bad ðŸ¤©!!! Time for a bit more sanding, and it is ready to be painted (in case that&#8217;s your goal). For me, I wanted to create a speaker that looks a bit rustic, so what I decided to do is to paint it black, but not too dark, and then sand it again after to add an extra &#8220;used&#8221; look.</p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/painted.jpg" alt="" /></p>
<p>It&#8217;s time to move to electronics ðŸ‘¨â€ðŸ­, my favorite part! </p>
<h3>The crossover</h3>
<p>In the crossover is where the magic happens, the circuit consists of two basic RLC filters, one high-pass filter that sends all high frequencies to the <b>Dayton tweeter</b> and a low-pass filter that sends the lower frequencies to the <b>HiVi B4N</b> speaker. If you want to know more about audio crossovers, you should check the <a href="//en.wikipedia.org/wiki/Audio_crossover" rel="noopener noreferrer" target="_blank">audio crossover Wikipedia</a> page for more information.</p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/schematics.png" alt="" /></p>
<p>When I was about to put the crossover together, I realized I didn&#8217;t have a perfboard or didn&#8217;t want to design a PCB and have to wait weeks for it to arrive. The solution was to design a 3D board with the holes in place so that I could easily solder the components in an accessible way and that could be easily attached to the interior of the cabinet.</p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/perf.png" alt="" /></p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/crossover.jpg" alt="" /></p>
<p>You can download the 3D file for the board from the <a href="3682403/" rel="noopener noreferrer" target="_blank"><b>thingiverse</b></a> website. The last step if to put it all together, the electronics following the schematics from Paul, screwing the speaker and tweeter to the front of the cabinet and closing the box.</p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/assembled.jpg" alt="" /></p>
<h3>The amplifier</h3>
<p>One thing you have to keep in mind is that we built a passive speaker, which means that we are still going to need a power amplifier to process the audio input signal and push it to the boxes. Initially, I got an <a href="//amzn.to/37TPHEQ" rel="noopener noreferrer" target="_blank">SMSL SA-36A </a> but quickly realized that the lack of a remote controller would be a huge pain in the ðŸ‘ as I intended to use the speaker mainly on the TV, and have to keep standing to adjust the volume wouldn&#8217;t work. That&#8217;s why I changed the amplifier to an <a href="//amzn.to/38URNFO" rel="noopener noreferrer" target="_blank">SMSL SA-50</a> and have been really happy ever since!</p>
<h3 style="text-align:center">ðŸ¥³ Celebrate and enjoy ðŸ¥³</h3>
<p><img src="//www.danielandrade.net/wp-content/uploads/2020/02/time-to.jpg" alt="" /></p>
<p style="text-align:center">
&#8220;<em>Ah, it&#8217;s time to relax.<br />
You know what that means.<br />
A glass of wine, your favorite easy chair,<br />
And of course, this compact disc<br />
Playing on your home stereo.<br />
So, go on, and indulge yourself!<br />
That&#8217;s right, kick off your shoes,<br />
Put your feet up!<br />
Lean back and just enjoy the melodies.<br />
After all, music soothes even the savage beast.</em>&#8221; &#8211; The Offspring</p>
<p style="text-align:center"><b>Thanks for reading ðŸ˜˜ !</b> </p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2020/02/21/my-overnight-sensation-speaker-build/">My Overnight Sensation Speaker Build</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://danielandrade.net/2020/02/21/my-overnight-sensation-speaker-build/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
		<item>
		<title>Accessing a FreeNAS Jail via SSH-Tunnel</title>
		<link>https://danielandrade.net/2019/06/22/accessing-a-freenas-jail-via-ssh-tunnel/</link>
					<comments>https://danielandrade.net/2019/06/22/accessing-a-freenas-jail-via-ssh-tunnel/#respond</comments>
		
		<dc:creator><![CDATA[dansku]]></dc:creator>
		<pubDate>Sat, 22 Jun 2019 21:56:01 +0000</pubDate>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[Tech]]></category>
		<guid isPermaLink="false">https://www.danielandrade.net/?p=3313</guid>

					<description><![CDATA[<p>If you ever need to remotely access an application running inside a FreeNAS jail, you can create an SSH Tunnel to the server and map the local IP Address and port of the jail with ssh -L JAIL-PORT:JAIL-IP:LOCAL-PORT user@host As an example, let&#8217;s say you can access your FreeNAS server via ssh with user@domain.com, the [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2019/06/22/accessing-a-freenas-jail-via-ssh-tunnel/">Accessing a FreeNAS Jail via SSH-Tunnel</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><img src="//www.danielandrade.net/wp-content/uploads/2019/06/ssh.png" alt="" class="img-responsive" style="margin:auto"/></p>
<p>If you ever need to remotely access an application running inside a FreeNAS jail, you can create an SSH Tunnel to the server and map the local IP Address and port of the jail with</p>
<p><code>ssh -L JAIL-PORT:JAIL-IP:LOCAL-PORT user@host</code></p>
<p>As an example, let&#8217;s say you can access your FreeNAS server via ssh with <b>user@domain.com</b>, the jail IP is <b>192.168.1.10</b> and it is running an application on port <strong>8080</strong>.</p>
<p>To create the tunnel, you would use</p>
<p><b>ssh -L 8080:192.168.1.10:8080 user@domain.com</b></p>
<p>Once the tunnel is up and running, you can access the service locally with <b>localhost:8080</b> ðŸŽ‰</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2019/06/22/accessing-a-freenas-jail-via-ssh-tunnel/">Accessing a FreeNAS Jail via SSH-Tunnel</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://danielandrade.net/2019/06/22/accessing-a-freenas-jail-via-ssh-tunnel/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Organizing your dropbox Camera Upload folder with Go</title>
		<link>https://danielandrade.net/2018/08/30/organizing-your-dropbox-camera-upload-folder-with-go/</link>
					<comments>https://danielandrade.net/2018/08/30/organizing-your-dropbox-camera-upload-folder-with-go/#comments</comments>
		
		<dc:creator><![CDATA[dansku]]></dc:creator>
		<pubDate>Thu, 30 Aug 2018 18:14:13 +0000</pubDate>
				<category><![CDATA[Automation]]></category>
		<category><![CDATA[Golang]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[automation]]></category>
		<category><![CDATA[dropbox]]></category>
		<category><![CDATA[golang]]></category>
		<category><![CDATA[photos]]></category>
		<category><![CDATA[scripts]]></category>
		<guid isPermaLink="false">https://www.danielandrade.net/?p=3226</guid>

					<description><![CDATA[<p>A few years ago I wrote a small Python script to organize the photos uploaded from your phone to Dropbox. Lately, I have been rewriting some of my python scripts to golang for practice and also performance. All photos are uploaded to Dropbox with a name pattern like 2018-08-01 05.56.40.jpg. What all it does is [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/08/30/organizing-your-dropbox-camera-upload-folder-with-go/">Organizing your dropbox Camera Upload folder with Go</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>A few years ago I wrote a small <a href="https://www.danielandrade.net/2014/02/16/script-to-organize-dropboxs-camera-upload-folder/">Python script</a> to organize the photos uploaded from your phone to Dropbox. Lately, I have been rewriting some of my <strong>python</strong> scripts to <strong><a href="http://golang.org/" rel="noopener" target="_blank">golang</a></strong> for practice and also performance.</p>
<p>All photos are uploaded to Dropbox with a name pattern like <em>2018-08-01 05.56.40.jpg</em>. What all it does is to parse the date and move it to the right place, for example, <strong>2018-08-01</strong> will move it to a folder called <strong>08-August</strong> inside <strong>2018</strong>. </p>
<p><img src="https://www.danielandrade.net/wp-content/uploads/2014/02/DropboxCameraUpload.jpg" alt="golang dropbox photo organizer" /></p>
<p><strong>Source code:</strong><br />
<script src="https://gist.github.com/dansku/0e707da68e67667c6e75393e6a122cc3.js"></script></p>
<p>You can also download the compiled file below, just make sure you make it executable with</p>
<pre>
chmod +x organize_photos
</pre>
<p>and run it with</p>
<pre>
./organize_photos
</pre>
<p><a href="https://www.danielandrade.net/wp-content/uploads/2018/08/organize_photos.zip">Download link.</a></p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/08/30/organizing-your-dropbox-camera-upload-folder-with-go/">Organizing your dropbox Camera Upload folder with Go</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://danielandrade.net/2018/08/30/organizing-your-dropbox-camera-upload-folder-with-go/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
		<item>
		<title>Automated door system</title>
		<link>https://danielandrade.net/2018/08/14/automated-door-system/</link>
					<comments>https://danielandrade.net/2018/08/14/automated-door-system/#comments</comments>
		
		<dc:creator><![CDATA[dansku]]></dc:creator>
		<pubDate>Tue, 14 Aug 2018 15:39:14 +0000</pubDate>
				<category><![CDATA[Electronics]]></category>
		<category><![CDATA[Engineering]]></category>
		<category><![CDATA[automation]]></category>
		<category><![CDATA[diy]]></category>
		<category><![CDATA[electronics]]></category>
		<category><![CDATA[hardware]]></category>
		<category><![CDATA[home-automation]]></category>
		<category><![CDATA[iot]]></category>
		<category><![CDATA[photon]]></category>
		<guid isPermaLink="false">https://www.danielandrade.net/?p=2540</guid>

					<description><![CDATA[<p>Earlier this year we moved from Berlin to Lisbon and found a nice apartment not too far from the city center. Our apartment building door, like most around Lisbon, is old and doesn&#8217;t work very well. And with many friends coming to visit this summer, I decided to automate the door so that me and [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/08/14/automated-door-system/">Automated door system</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Earlier this year we moved from Berlin to Lisbon and found a nice apartment not too far from the city center. </p>
<p>Our apartment building door, like most around Lisbon, is old and doesn&#8217;t work very well. And with many friends coming to visit this summer, I decided to automate the door so that me and my friends can open the door using our mobile phones instead of spending 5 minutes trying to jiggle the key in the lock to get it open.</p>
<div class="embed-responsive embed-responsive-16by9">
<iframe class="embed-responsive-item"  src="https://www.youtube.com/embed/4uBYM3xTTn0"></iframe>
</div>
<p><span id="more-2540"></span></p>
<hr />
<p>For this project, I am going to use a <strong><a href="https://www.particle.io/products/hardware/photon-wifi" rel="noopener" target="_blank">Photon</a></strong> board from <a href="https://www.particle.io/" rel="noopener" target="_blank"><strong>Particle.io</strong></a> and a Relay module I got from eBay.</p>
<p>I am a huge fan of Particle, their products are super solid and easy to use. (<em>this is not a sponsored post</em>).</p>
<div class="row">
<div class="col-md-6">
<h4 class="text-center">Particle Photon</h4>
<p>    <img src="//www.danielandrade.net/wp-content/uploads/2018/08/particle_photon.png" alt="particle photon" class="img-responsive" />
  </div>
<div class="col-md-6">
<h4 class="text-center">Relay Module</h4>
<p>    <img src="//www.danielandrade.net/wp-content/uploads/2018/08/relay_module-1.png" alt="relay model" class="img-responsive"/>
  </div>
</div>
<hr />
<h3>Hardware</h3>
<p>The hardware part of this project is very simple, I attached the relay to the intercom switch (this part may vary depending on your intercom system). As mine is very old, it was pretty straightforward to hack the wires from the switch to the relay.</p>
<p><img src="//www.danielandrade.net/wp-content/uploads/2018/08/door-01.jpg" alt="door circuit" class="img-responsive" /></p>
<p>When you press the switch, <strong>pin-1</strong> and <strong>pin-2</strong> are connected together, opening the door, and this will be the role of the relay in our project.</p>
<h4>Connection</h4>
<p>I am using a USB charger I had laying around the house to power the photon board. To control the relay you must connect three pins to the photon.</p>
<ul>
<li>VCC to 3V3</li>
<li>GND to GND</li>
<li>IN to D7</li>
</ul>
<div class="row">
<div class="col-md-6">
<p>    On the relay side, you just need to connect the wires on the middle and left or right side depending on your module.</p>
<p>    <img src="//www.danielandrade.net/wp-content/uploads/2018/08/relay_connection.png" alt="relay connection" class="img-responsive"/></p></div>
<div class="col-md-6">
    <img src="//www.danielandrade.net/wp-content/uploads/2018/08/particle-connection.jpg" alt="relay model" class="img-responsive"/>
  </div>
</div>
<hr />
<h3>Software</h3>
<p>On the software side, we need to find a way to send a signal to the photon board in order to close the circuit of the relay for a couple of seconds, opening the building door. When building this project, I came up with two possibilities, one faster that requires less coding and a more versatile version that requires a bit more coding.</p>
<h3>Blynk method</h3>
<p><a href="https://www.blynk.cc/" target="_blank" rel="noopener">Blynk</a> is a modular mobile app for IOT projects and it is pretty easy to integrate with the Particle boards.</p>
<p>You need to get the app for your phone, get the authentication key, and change the code below. You may need to fix the code to match your hardware configuration.</p>
<p><script src="https://gist.github.com/dansku/575029043b83df43b082f4d908392599.js"></script></p>
<div class="row">
<div class="col-md-6">
    <img src="//www.danielandrade.net/wp-content/uploads/2018/08/2018-08-12-19.41.57.png" alt="blynk" class="img-responsive"/>
  </div>
<div class="col-md-6">
    <img src="//www.danielandrade.net/wp-content/uploads/2018/08/2018-08-12-19.41.53.png" alt="blynk" class="img-responsive"/>
  </div>
</div>
<p>After connecting the Blynk app with the Particle board, you are ready to go!</p>
<h3 style="margin-top: 50px;">POST method</h3>
<p>The second method is the one I am currently using because you can have more control of the system and also integrate it with different applications.</p>
<p>Below is the code to put in your Photon:<br />
<script src="https://gist.github.com/dansku/f94dd3fcea21e2f43a9cf7f968974154.js"></script></p>
<p>You can see on the <strong>setup()</strong> function, we are creating an external-call named &#8220;open&#8221;, which will trigger the function <strong>openCall()</strong>.</p>
<p>To trigger the door-opening circuit, all you have to do is create a <strong>POST</strong> request to the following URL:</p>
<pre>
  https://api.spark.io/v1/devices/DEVICE_ID/open?access_token=ACCESS_TOKEN
</pre>
<p>Just change the <strong>DEVICE_ID</strong> and <strong>ACCESS_TOKEN</strong> for the one of your application.</p>
<p>In my case, I decided to create an <strong>.html</strong> file and I added a button. Once pressed, it will open the door. It&#8217;s as simple as that! This way all I need to do is to share the URL with friends and family and they can easily open the door when they come home.</p>
<p>Here is the code:<br />
<script src="https://gist.github.com/dansku/a4d2c1261ee83a076341a37c0a9ca33f.js"></script></p>
<p>From here you can use your creativity and improve the code, system, and much more.<br />
For example, if you have an Airbnb with many different people coming to your house, you can create the system in a way that it will only work with specific accounts for a set period.</p>
<p>Happy hacking!</p>
<p><img class="img-responsive" src="https://www.danielandrade.net/wp-content/uploads/2018/08/hackman.gif" alt="hackman"/></p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/08/14/automated-door-system/">Automated door system</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://danielandrade.net/2018/08/14/automated-door-system/feed/</wfw:commentRss>
			<slash:comments>6</slash:comments>
		
		
			</item>
		<item>
		<title>Fixing Hackernoon annoyance</title>
		<link>https://danielandrade.net/2018/07/23/fixing-hackernoon-annoyance/</link>
					<comments>https://danielandrade.net/2018/07/23/fixing-hackernoon-annoyance/#respond</comments>
		
		<dc:creator><![CDATA[dansku]]></dc:creator>
		<pubDate>Mon, 23 Jul 2018 14:57:27 +0000</pubDate>
				<category><![CDATA[Random]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[hackernoon]]></category>
		<category><![CDATA[scripts]]></category>
		<category><![CDATA[TamperMonkey]]></category>
		<guid isPermaLink="false">https://www.danielandrade.net/?p=2534</guid>

					<description><![CDATA[<p>I am a big fan or Hackernoon, but their sticky header and footer bars are too big and annoying. To fix that, I&#8217;ve written a quick TamperMonkey script to remove it. Before After</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/07/23/fixing-hackernoon-annoyance/">Fixing Hackernoon annoyance</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>I am a big fan or <a href="https://hackernoon.com/"  target="_blank">Hackernoon</a>, but their sticky header and footer bars are too big and annoying. To fix that, I&#8217;ve written a quick TamperMonkey script to remove it.</p>
<p><script src="https://gist.github.com/dansku/1a84de49a61f2a39eea334fa8efd9c6c.js"></script></p>
<h2>Before</h2>
<p><img loading="lazy" src="https://www.danielandrade.net/wp-content/uploads/2018/07/hackernoon_before-1024x560.png" alt="" width="640" height="350" class="img-responsive" /></p>
<h2>After</h2>
<p><img loading="lazy" src="https://www.danielandrade.net/wp-content/uploads/2018/07/hackernoon_after-1024x560.png" alt="" width="640" height="350" class="img-responsive" /></p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/07/23/fixing-hackernoon-annoyance/">Fixing Hackernoon annoyance</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://danielandrade.net/2018/07/23/fixing-hackernoon-annoyance/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>PHPUnit &#8211; Seeding inside your test methods</title>
		<link>https://danielandrade.net/2018/07/21/phpunit-seeding-inside-your-test-methods/</link>
					<comments>https://danielandrade.net/2018/07/21/phpunit-seeding-inside-your-test-methods/#comments</comments>
		
		<dc:creator><![CDATA[dansku]]></dc:creator>
		<pubDate>Sat, 21 Jul 2018 16:28:29 +0000</pubDate>
				<category><![CDATA[Laravel]]></category>
		<category><![CDATA[WebDev]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[phpunit]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[software]]></category>
		<guid isPermaLink="false">https://www.danielandrade.net/?p=2529</guid>

					<description><![CDATA[<p>If you want to run seeders before each test you can use the artisan command in each of your test methods. Running all seeders with: $this->artisan('db:seed'); Running only one specific seeder: $this->artisan('db:seed', ['--class' => 'RolesTableSeeder']);</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/07/21/phpunit-seeding-inside-your-test-methods/">PHPUnit &#8211; Seeding inside your test methods</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>If you want to run seeders before each test you can use the artisan command in each of your test methods.</p>
<p>Running all seeders with:</p>
<pre>
$this->artisan('db:seed');
</pre>
<p>Running only one specific seeder:</p>
<pre>
$this->artisan('db:seed', ['--class' => 'RolesTableSeeder']);
</pre>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/07/21/phpunit-seeding-inside-your-test-methods/">PHPUnit &#8211; Seeding inside your test methods</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://danielandrade.net/2018/07/21/phpunit-seeding-inside-your-test-methods/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
		<item>
		<title>pwdquery v2 is out!</title>
		<link>https://danielandrade.net/2018/05/05/pwdquery-v2-is-out/</link>
					<comments>https://danielandrade.net/2018/05/05/pwdquery-v2-is-out/#respond</comments>
		
		<dc:creator><![CDATA[dansku]]></dc:creator>
		<pubDate>Sat, 05 May 2018 22:31:37 +0000</pubDate>
				<category><![CDATA[Scripts]]></category>
		<category><![CDATA[WebDev]]></category>
		<category><![CDATA[infosec]]></category>
		<category><![CDATA[password]]></category>
		<category><![CDATA[projects]]></category>
		<category><![CDATA[pwdquery]]></category>
		<category><![CDATA[security]]></category>
		<guid isPermaLink="false">https://www.danielandrade.net/?p=2517</guid>

					<description><![CDATA[<p>Today I am releasing the second version of my side-project pwdquery. I have spent many hours playing and manipulating the 90GB+ database, creating new scrapers, improving scripts and automating the whole process. Remember, if you see any of your passwords in there, change immediately! Check it out at https://pwdquery.xyz</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/05/05/pwdquery-v2-is-out/">pwdquery v2 is out!</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><img src="https://www.danielandrade.net/wp-content/uploads/2018/05/pwdquery-1024x520.png" alt="pwdquery v2" class="img-responsive" /></p>
<p>Today I am releasing the second version of my side-project <strong>pwdquery</strong>. I have spent many hours playing and manipulating the 90GB+ database, creating new scrapers, improving scripts and automating the whole process.</p>
<p>Remember, if you see any of your passwords in there, change immediately!</p>
<h2>Check it out at <a href="https://pwdquery.xyz" rel="noopener noreferrer" target="_blank">https://pwdquery.xyz</a></h2>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/05/05/pwdquery-v2-is-out/">pwdquery v2 is out!</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://danielandrade.net/2018/05/05/pwdquery-v2-is-out/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>My VIM configuation</title>
		<link>https://danielandrade.net/2018/02/10/my-vim-configuation/</link>
					<comments>https://danielandrade.net/2018/02/10/my-vim-configuation/#comments</comments>
		
		<dc:creator><![CDATA[dansku]]></dc:creator>
		<pubDate>Sun, 11 Feb 2018 01:08:06 +0000</pubDate>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tech]]></category>
		<category><![CDATA[ide]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[vi]]></category>
		<category><![CDATA[vim]]></category>
		<guid isPermaLink="false">https://www.danielandrade.net/?p=2499</guid>

					<description><![CDATA[<p>Hey guys, just wanted to share my current VIM settings. Installation Copy the vimrc file to ~/.vimrc Install Vundle from https://github.com/VundleVim/Vundle.vim with: git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim Run vim +PluginInstall +qall Enjoy 😉 https://github.com/dansku/vimrc</p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/02/10/my-vim-configuation/">My VIM configuation</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Hey guys, just wanted to share my current VIM settings. </p>
<p><a rel="lightbox[vim]" href="//www.danielandrade.net/wp-content/uploads/2018/02/my_vimrc.png"><br />
<img src="//www.danielandrade.net/wp-content/uploads/2018/02/my_vimrc.png" alt="vim configuration" class="img-responsive"/><br />
</a></p>
<h2>Installation</h2>
<p>Copy the <strong>vimrc</strong> file to <strong>~/.vimrc</strong><br />
Install Vundle from <a href="https://github.com/VundleVim/Vundle.vim" rel="noopener" target="_blank">https://github.com/VundleVim/Vundle.vim</a> with:</p>
<pre>git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim</pre>
<p>Run vim <strong>+PluginInstall +qall</strong></p>
<p>Enjoy <img src="https://s.w.org/images/core/emoji/13.1.0/72x72/1f609.png" alt="😉" class="wp-smiley" style="height: 1em; max-height: 1em;" /><br />
<a href="https://github.com/dansku/vimrc" rel="noopener" target="_blank">https://github.com/dansku/vimrc</a></p>
<p>The post <a rel="nofollow" href="https://danielandrade.net/2018/02/10/my-vim-configuation/">My VIM configuation</a> appeared first on <a rel="nofollow" href="https://danielandrade.net">Daniel Andrade</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://danielandrade.net/2018/02/10/my-vim-configuation/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
	</channel>
</rss>
