<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Naomi Pentrel on Medium]]></title>
        <description><![CDATA[Stories by Naomi Pentrel on Medium]]></description>
        <link>https://medium.com/@naomi_pen?source=rss-7f528864f148------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*aN5D6pLYFLKHQu1B.</url>
            <title>Stories by Naomi Pentrel on Medium</title>
            <link>https://medium.com/@naomi_pen?source=rss-7f528864f148------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 18 Nov 2026 19:22:42 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@naomi_pen/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Print, Paint, and Program a Guardian to Track Humans and Dogs Using a Pi, Camera, and Servo]]></title>
            <link>https://medium.com/better-programming/print-paint-and-program-a-guardian-to-track-humans-and-dogs-using-a-pi-camera-and-servo-30b6465b6138?source=rss-7f528864f148------2</link>
            <guid isPermaLink="false">https://medium.com/p/30b6465b6138</guid>
            <category><![CDATA[raspberry-pi]]></category>
            <category><![CDATA[servo]]></category>
            <category><![CDATA[zelda]]></category>
            <category><![CDATA[dogs]]></category>
            <category><![CDATA[robotics]]></category>
            <dc:creator><![CDATA[Naomi Pentrel]]></dc:creator>
            <pubDate>Wed, 09 Aug 2023 10:58:41 GMT</pubDate>
            <atom:updated>2023-08-11T18:21:45.343Z</atom:updated>
            <cc:license>https://creativecommons.org/licenses/by-sa/4.0/</cc:license>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/600/1*9B27KuXtJJWGTTwP9avx0g.gif" /><figcaption>A Guardian that Tracks Pets using a Pi, Camera, and Servo</figcaption></figure><p>In the run-up to the new Zelda release, I realized you can build a stationary guardian robot with a servo and a camera. Adding a bit of <a href="https://docs.viam.com/services/ml/">machine learning</a>, you can then make the guardian detect objects or people or pets and follow them around by rotating its head. Luckily, I am not the first one to have the idea to build a guardian, and there was already a <a href="https://www.thingiverse.com/thing:2391826">brilliant guardian 3D model</a> on Thingiverse with space for LEDs and a servo.</p><p>In this tutorial, I will walk you through the steps to build your own functional guardian with a <a href="https://docs.viam.com/components/servo">servo</a>, a <a href="https://docs.viam.com/components/camera">camera</a>, some LEDs, and the <a href="https://docs.viam.com/services/ml">ML Model service</a> and <a href="https://docs.viam.com/services/vision">Vision Service</a>.</p><h3>Hardware requirements</h3><p>To build your own guardian robot, you need the following hardware:</p><ul><li>Raspberry Pi + power cable: $60</li><li>Raspberry Pi Camera v1.3 + 50cm ribbon cable: The default 15cm ribbon cable is not long enough: $15</li><li>180-degree SG90 servo: Because of the camera ribbon, I restricted the servo to only 180 degrees: $4</li><li>3x 10mm RGB LEDs with common cathode: $4</li><li>Cables: $5</li><li>4x M2 screws to attach the camera: $2</li><li>Speaker: Optional - if you want music. I used a 4Ω 2W speaker with a connected aux-in. You can use any speaker you can connect to your Pi.</li></ul><p>Print or order the following printed 3D parts:</p><ul><li><a href="https://www.thingiverse.com/thing:6027280">this head</a> fits the camera</li><li>the decorations for the head from <a href="https://www.thingiverse.com/thing:2387723">this Guardian Robot model</a></li><li>the body, base cover, claws, and leg segments from the <a href="https://www.thingiverse.com/thing:2391826">Guardian Robot, Hackable</a></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/0*k6Ts0GyLV1LolBYC.jpg" /><figcaption>3D printed parts</figcaption></figure><p>To make the guardian’s lights shine through its body, use filament that allows the light to shine through and paint the parts that shouldn’t allow light to shine through.</p><p>Optionally, if you want to decorate your guardian, I recommend the following materials:</p><ul><li>primer: Vallego Surface Primer Grey or another brand.</li><li>acrylic paint: I ordered armour modelling paint but found that mixing my own colors from a regular acrylic paint set worked best for me.</li><li>modelling grass, stones, and glue: The Army Painter makes a Battlefields Basing Set with all of this.</li><li>a base for the guardian: I used a wooden disk with a hole cut in the middle and a box with a hole underneath the top.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/0*G8QZd8IDNyN5UskM.jpg" /><figcaption>Wooden guardian base</figcaption></figure><ul><li>ground texture: If you want the base to look more natural, you can use Vallejo Ground Texture Acrylic or something similar to create patches that look like stone.</li><li>wire: To position the legs better, you can thread wire through them.</li></ul><h3>Software Requirements</h3><p>You will use the following software in this tutorial:</p><ul><li><a href="https://www.python.org/downloads/">Python 3</a></li><li><a href="https://docs.viam.com/installation/#install-viam-server">viam-server</a>: Follow the <a href="https://docs.viam.com/installation/#install-viam-server">installation instructions</a> to install viam-server on your Raspberry Pi.</li></ul><h3>Assemble the Robot</h3><p>You can view a timelapse of the robot assembly here:</p><p><a href="https://imgur.com/gallery/3sCrNh4">Printed, painted, and programmed a Guardian to track humans and dogs using a Pi, camera, and servo</a></p><h3>Assemble for Testing</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/300/0*EmuNMZaRWALc01FG.png" /><figcaption>Head with camera attachment</figcaption></figure><p>To assemble the guardian, start with the head and use four M2 screws to screw the camera with the attached ribbon cable to the front half of the head. Optionally, if the camera&#39;s green is visible from the outside, use a marker to color the camera board. Then put both parts of the head together.</p><p>Your servo probably came with mounting screws and a plastic horn for the gear. Use the screws to attach the horn to the base of the head.</p><p>Next, get your Raspberry Pi and your servo and connect the servo to the Raspberry Pi by connecting the PWM wire to pin 12, the power wire to pin 2, and the ground wire to pin 8.</p><blockquote><em>Tip</em>:<em> To make it easier for you to see which pin is which, you can print out </em><a href="https://docs.viam.com/try-viam/viam-raspberry-leaf-8.5x11.pdf"><em>this Raspberry Pi Leaf</em></a><em> which has labels for the pins and carefully push it onto the pins or fold or cut it so you can hold it up to the Raspberry Pi pins. If you use A4 paper, use this </em><a href="https://docs.viam.com/try-viam/viam-raspberry-leaf-A4.pdf"><em>this Raspberry Pi Leaf</em></a><em> instead.</em></blockquote><blockquote><em>If you are having trouble punching the pins through, you can pre-punch the pin holes with a pen. Only attach the paper when the Pi is unplugged. To make attaching the paper easier, use a credit card or a small screwdriver.</em></blockquote><p>Then attach the head to the servo.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Vc9effgpXxivLfZP.png" /><figcaption>A Raspberry Pi connected to an FS90R servo. The yellow PWM wire is attached to pin twelve on the raspberry pi. The red five-volt wire is attached to pin two. The black ground wire is attached to pin eight</figcaption></figure><p>Next, get the three 10 mm RGB LEDs ready. Attach the common cathode of each LED to a <a href="https://pinout.xyz/pinout/ground">ground pin</a> on your Raspberry Pi. Attach the wires for the red and blue LEDs to the <a href="https://pinout.xyz/pinout/wiringpi">GPIO pins</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/0*mTUy-2HlehDflsT9.jpg" /><figcaption>Components assembled for testing</figcaption></figure><p>Before continuing with assembly, you should test your components work as expected. To be able to test the components, you need to install viam-server and configure your components.</p><h3>Install viam-server and Connect to Your Robot</h3><p>Go to the <a href="https://app.viam.com/">Viam app</a> and create a new robot called guardian.</p><p>Go to the Setup tab of your new robot’s page and follow the steps <a href="https://docs.viam.com/installation/">to install </a><a href="https://docs.viam.com/installation/">viam-server on your computer</a>.</p><p>Navigate to the Config tab of your robot’s page in <a href="https://app.viam.com/">the Viam app</a>. Click on the Components subtab and navigate to the Create component menu.</p><ol><li>Add the board<br>Enter local for the name for your <a href="https://docs.viam.com/components/board/">board component</a>, select the type board, and select the pi model. Then click Create component.</li><li>Add the camera<br>Create a <a href="https://docs.viam.com/components/camera/">camera component</a> with the name cam, the type camera and the model webcam. Click Create Component to add the camera. In the new camera panel, click the Video Path field to reveal a drop-down populated with camera paths identified on your machine. Select mmal service 16.1 (platform:bcm2835_v4l2-0).</li><li>Add the servo<br>Create a <a href="https://docs.viam.com/components/servo/">servo component</a> with the name servo, the type servo and the model pi. Click Create Component to add the servo. Configure the attributes by adding the name of your board, local, and the <a href="https://docs.viam.com/appendix/glossary/#term-pin-number">pin number</a> of the pin on local that you connected your servo PWM wire to, 12:</li></ol><pre>{<br>    &quot;pin&quot;: &quot;12&quot;,<br>    &quot;board&quot;: &quot;local&quot;<br>}</pre><p>Click Save config in the bottom left corner of the screen.</p><h3>Test the Components</h3><p>Navigate to your <a href="https://docs.viam.com/manage/fleet/robots/#control">robot’s Control tab</a> to test your components.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/0*StVrqD3p5YH4yNqD.png" /><figcaption>The control tab</figcaption></figure><p>Click on the servo panel to increase or decrease the servo angle to test the servo&#39;s moves.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/0*ahVOQaPOS6im5wFl.png" /><figcaption>The control tab servo panel</figcaption></figure><p>Next, click on the board panel. The board panel allows you to get and set pin states. Set the pin states for the pins your LEDs are connected to to high to test that they light up.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/0*zi9kdGx8_ZHaXUqB.png" /><figcaption>The control tab board panel</figcaption></figure><p>Next, click on the camera panel and toggle the camera to test if you get video from your camera.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/0*RXRBLCipsK9spBUt.jpg" /><figcaption>The control tab camera panel</figcaption></figure><h3>Assemble and Decorate</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/300/0*QG9F0qBkoBfQ3BS4.jpg" /><figcaption>Fully assembled guardian</figcaption></figure><p>Now that you have tested your components, you can disconnect them again, paint and decorate your guardian, and then assemble the rest. Remove the servo horn, and place one LED in the back of the Guardian&#39;s head, leaving the wires hanging out behind the ribbon camera.</p><p>Then place the servo inside the Guardian&#39;s body and attach the horn on the head to the servo’s gear. Carefully place the remaining two LEDs in opposite directions inside the body. Thread all the cables through the hole in the lid for the base of the guardian, and close the lid.</p><p>Use a suitable base with a hole, like a box with a hole cut into the top, to place your guardian on top of and reconnect all the wires to the Raspberry Pi.</p><p>At this point, also connect the speaker to your Raspberry Pi.</p><p>Then test the components on the <a href="https://docs.viam.com/manage/fleet/robots/#control">robot’s Control tab</a> again to ensure everything still works.</p><h3>Detect People and Pets</h3><p>For the guardian to be able to detect living beings, you can use <a href="https://github.com/viam-labs/devrel-demos/raw/main/Light%20up%20bot/effdet0.tflite">this Machine Learning model</a>. The model can detect a variety of things which you can see in the associated <a href="https://github.com/viam-labs/devrel-demos/raw/main/Light%20up%20bot/labels.txt">labels.txt</a> file.</p><p>You can also <a href="https://docs.viam.com/manage/ml/train-model/">train your own custom model</a> based on images from your robot, but the provided machine learning model is a good one to start with.</p><p>To use the provided machine learning model, copy the <a href="https://github.com/viam-labs/devrel-demos/raw/main/Light%20up%20bot/effdet0.tflite">effdet0.tflite</a> file and the <a href="https://github.com/viam-labs/devrel-demos/raw/main/Light%20up%20bot/labels.txt">labels.txt</a> to your Raspberry Pi:</p><pre>scp effdet0.tflite pi@guardian.local:/home/pi/effdet0.tflite<br>scp labels.txt pi@guardian.local:/home/pi/labels.txt</pre><p>Next, navigate to the Config tab of your robot’s page in <a href="https://app.viam.com/">the Viam app</a>. Click on the Services subtab and navigate to the Create service menu.</p><ol><li>Add an ML model service<br>The <a href="https://docs.viam.com/services/ml/">ML model service</a> allows you to deploy the provided machine learning model to your robot. Create an ML model with the name mlmodel, the type mlmodel, and the model tflite_cpu. Then click Create Service.<br>In the new ML Model panel, select Path to Existing Model On Robot for the Deployment.<br>Then specify the absolute Model Path as /home/pi/effdet0.tflite and the Label Path as /home/pi/labels.txt.</li><li>Add a vision service<br>Next, add a <a href="https://docs.viam.com/services/vision/detection/">detector</a> as a vision service to make use of the ML model. Create a vision service with the name detector, the type vision and the model mlmodel. Then click Create Service.<br>In the new detector panel, select the mlmodel you configured in the previous step.<br>Click Save config in the bottom left corner of the screen.</li><li>Add a transform camera<br>To test that the vision service is working, add a transform camera that will add bounding boxes and labels around the objects the service detects.<br>Click on the Components subtab and navigate to the Create component menu. Create a <a href="https://docs.viam.com/components/camera/transform/">transform camera</a> with the name transform_cam, the type camera, and the model transform.<br>Replace the attributes JSON object with the following object, which specifies the camera source the transform camera will be using and defining a pipeline that adds the defined detector:</li></ol><pre>{<br>&quot;source&quot;: &quot;cam&quot;,<br>&quot;pipeline&quot;: [<br>    {<br>    &quot;type&quot;: &quot;detections&quot;,<br>    &quot;attributes&quot;: {<br>        &quot;detector_name&quot;: &quot;detector&quot;,<br>        &quot;confidence_threshold&quot;: 0.6<br>    }<br>    }<br>]<br>}</pre><p>Click Save config in the bottom left corner of the screen.</p><p>Navigate to your <a href="https://docs.viam.com/manage/fleet/robots/#control">robot’s Control tab</a> to test the transform camera. Click on the transform camera panel and toggle the camera on, then point your camera at a person or pet to test if the vision service detects them. You should see bounding boxes with labels around different objects.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/0*SG3-tf4oAWcLbhR4.jpg" /><figcaption>The control tab transform camera panel</figcaption></figure><h3>Program the Guardian</h3><p>With the guardian completely configured and the configuration tested, it’s time to make the robot guardian behave like a “real” guardian by programming the person and pet detection, lights, music, and movement.</p><p>The full code is available at <a href="https://docs.viam.com/tutorials/projects/guardian/#full-code">the end of the tutorials</a>.</p><h3>Set up the Python Environment</h3><p>We will use Virtualenv to set up a virtual environment for this project to isolate the dependencies of this project from other projects. Run the following commands in your command line to install virtualenv, set up an environment venv, and activate it:</p><pre>python3 -m pip install --user virtualenv<br>python3 -m venv env<br>source env/bin/activate</pre><p>Now, install the Python Viam SDK and the VLC module:</p><pre>pip3 install viam-sdk python-vlc</pre><h3>Connect</h3><p>Next, go to the Code sample tab on your robot page, select Python, then click Copy.</p><p>This code snippet imports all the necessary packages and sets up a connection with the Viam app in the cloud.</p><p>Next, create a file named main.py and paste the boilerplate code from the Code sample tab of the Viam app into your file. Then, save your file.</p><p>Run the code to verify that the Viam SDK is properly installed and that the viam-server instance on your robot is live.</p><p>You can run your code by typing the following into your terminal:</p><pre>python3 main.py</pre><p>The program prints a list of robot resources.</p><p>On top of the packages that the code sample snippet imports, add the random and the vlc package to the imports. The top of your code should now look like this:</p><pre>import asyncio<br>import random<br>import vlc<br><br>from viam.robot.client import RobotClient<br>from viam.rpc.dial import Credentials, DialOptions<br>from viam.components.board import Board<br>from viam.components.camera import Camera<br>from viam.components.servo import Servo<br>from viam.services.vision import VisionClient<br><br>async def connect():<br>    creds = Credentials(<br>        type=&#39;robot-location-secret&#39;,<br>        payload=&#39;LOCATION SECRET FROM THE VIAM APP&#39;)<br>    opts = RobotClient.Options(<br>        refresh_interval=0,<br>        dial_options=DialOptions(credentials=creds)<br>    )<br>    return await RobotClient.at_address(&#39;ADDRESS FROM THE VIAM APP&#39;, opts)</pre><p>You will update the main() method later.</p><h3>Lighting</h3><p>Next, you’ll write the code to manage the LEDs. Underneath the connect() function, add the following class, which allows you to create groups of LEDs that you can then turn on and off with one method call:</p><pre>class LedGroup:<br>    def __init__(self, group):<br>        print(&quot;group&quot;)<br>        self.group = group<br><br>    async def led_state(self, on):<br>        for pin in self.group:<br>            await pin.set(on)</pre><p>If you want to test this code, change your main() method to:</p><pre>async def main():<br>    robot = await connect()<br>    local = Board.from_robot(robot, &#39;local&#39;)<br>    red_leds = LedGroup([<br>        await local.gpio_pin_by_name(&#39;22&#39;),<br>        await local.gpio_pin_by_name(&#39;24&#39;),<br>        await local.gpio_pin_by_name(&#39;26&#39;)<br>    ])<br>    blue_leds = LedGroup([<br>        await local.gpio_pin_by_name(&#39;11&#39;),<br>        await local.gpio_pin_by_name(&#39;13&#39;),<br>        await local.gpio_pin_by_name(&#39;15&#39;)<br>    ])<br><br>    await blue_leds.led_state(True)</pre><p>You can test the code by running the following:</p><pre>python3 main.py</pre><p>Your Guardian lights up blue.</p><h3>Detections</h3><p>Now, you’ll add the code for the Guardian to detect people and pets. If you are building it for people, cats, or dogs, you’ll want to use Person, Dog, Cat, and if you have a particularly teddy-bear-like dog, Teddy bear. You can also specify different ones based on the available labels in <a href="https://github.com/viam-labs/devrel-demos/raw/main/Light%20up%20bot/labels.txt">labels.txt</a>.</p><p>Above the connect() method, add the following variable; it will define the labels that you want to look for in detections:</p><pre>LIVING_OBECTS = [&quot;Person&quot;, &quot;Dog&quot;, &quot;Cat&quot;, &quot;Teddy bear&quot;]</pre><p>Then, above the main() method add the following function, which checks detections for living creatures as they are defined in the LIVING_OBJECTS variable.</p><pre>async def check_for_living_creatures(detections):<br>    for d in detections:<br>        if d.confidence &gt; 0.6 and d.class_name in LIVING_OBECTS:<br>            print(&quot;detected&quot;)<br>            return d</pre><h3>Idling</h3><p>Underneath the check_for_living_creatures() function, add the following function that gets images from the Guardian’s camera and checks them for living creatures. If none are detected, it will move the servo randomly. If a creature is detected, the red LEDs will light up, and music will play.</p><pre>async def idle_and_check_for_living_creatures(cam, detector, servo, blue_leds, red_leds, music_player):<br>    living_creature = None<br>    while True:<br>        random_number_checks = random.randint(0, 5)<br>        if music_player.is_playing():<br>            random_number_checks = 15<br>        for i in range(random_number_checks):<br>            img = await cam.get_image()<br>            detections = await detector.get_detections(img)<br>            living_creature = await check_for_living_creatures(detections)<br>            if living_creature:<br>                await red_leds.led_state(True)<br>                await blue_leds.led_state(False)<br>                if not music_player.is_playing():<br>                    music_player.play()<br>                return living_creature<br>        print(&quot;START IDLE&quot;)<br>        await blue_leds.led_state(True)<br>        await red_leds.led_state(False)<br>        if music_player.is_playing():<br>            music_player.stop()<br>        await servo.move(random.randint(0, 180))</pre><h3>Focus</h3><p>There is one last function that you need to add before you can write the full main() function, and that is a function to focus on a given creature. The function calculates the center of the detected object and then checks if that center is close to the middle of the image. If it is not near the middle of the entire image, the function moves the servo to the left or right to attempt to center the object.</p><p>Add the following function above your main() function:</p><pre>async def focus_on_creature(creature, width, servo):<br>    creature_midpoint = (creature.x_max + creature.x_min)/2<br>    image_midpoint = width/2<br>    center_min = image_midpoint - 0.2*image_midpoint<br>    center_max = image_midpoint + 0.2*image_midpoint<br><br>    movement = (image_midpoint - creature_midpoint)/image_midpoint<br>    angular_scale = 20<br>    print(&quot;MOVE BY: &quot;)<br>    print(int(angular_scale*movement))<br><br>    servo_angle = await servo.get_position()<br>    if (creature_midpoint &lt; center_min or creature_midpoint &gt; center_max):<br>        servo_angle = servo_angle + int(angular_scale*movement)<br>        if servo_angle &gt; 180:<br>            servo_angle = 180<br>        if servo_angle &lt; 0:<br>            servo_angle = 0<br><br>        if servo_angle &gt;= 0 and servo_angle &lt;= 180:<br>            await servo.move(servo_angle)<br><br>    servo_return_value = await servo.get_position()<br>    print(f&quot;servo get_position return value: {servo_return_value}&quot;)</pre><h3>Main Logic</h3><p>The main logic for the guardian robot:</p><ul><li>initializes all the variables</li><li>turns all LEDs blue</li><li>loads a music file guardian.mp3</li><li>runs an infinite loop where it calls the idle_and_check_for_living_creatures() function, and when a creature is found calls the focus_on_creature() function</li></ul><p>Please copy a suitable music file to the directory where your code is running and name it guardian.mp3.</p><p>Replace your main() function with the following code:</p><pre>async def main():<br>    robot = await connect()<br>    local = Board.from_robot(robot, &#39;local&#39;)<br>    cam = Camera.from_robot(robot, &quot;cam&quot;)<br>    img = await cam.get_image()<br>    servo = Servo.from_robot(robot, &quot;servo&quot;)<br>    red_leds = LedGroup([<br>        await local.gpio_pin_by_name(&#39;22&#39;),<br>        await local.gpio_pin_by_name(&#39;24&#39;),<br>        await local.gpio_pin_by_name(&#39;26&#39;)<br>    ])<br>    blue_leds = LedGroup([<br>        await local.gpio_pin_by_name(&#39;11&#39;),<br>        await local.gpio_pin_by_name(&#39;13&#39;),<br>        await local.gpio_pin_by_name(&#39;15&#39;)<br>    ])<br><br>await blue_leds.led_state(True)<br>    music_player = vlc.MediaPlayer(&quot;guardian.mp3&quot;)<br>    # grab Viam&#39;s vision service for the detector<br>    detector = VisionClient.from_robot(robot, &quot;detector&quot;)<br>    while True:<br>        # move head periodically left and right until movement is spotted.<br>        living_creature = await idle_and_check_for_living_creatures(cam, detector, servo, blue_leds, red_leds, music_player)<br>        await focus_on_creature(living_creature, img.width, servo)<br>    # Don&#39;t forget to close the robot when you&#39;re done!<br>    await robot.close()<br><br>if __name__ == &#39;__main__&#39;:<br>    asyncio.run(main())</pre><p>Now, run the code:</p><pre>python3 main.py</pre><p>If everything works, your guardian should now start to idle. When it detects humans, dogs, or cats, it will turn red, start music, and focus on the detected being.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fplayer.vimeo.com%2Fvideo%2F852973061%3Fapp_id%3D122963&amp;dntp=1&amp;display_name=Vimeo&amp;url=https%3A%2F%2Fvimeo.com%2F852973061&amp;image=https%3A%2F%2Fi.vimeocdn.com%2Fvideo%2F1708322171-cf197bbf6bcdf80528e45a7af734373a2b8d4f1bc6c54c22834fba32b358c3a9-d_1280&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=vimeo" width="1920" height="1080" frameborder="0" scrolling="no"><a href="https://medium.com/media/d27cb054f79517cffa57c39f0add1e66/href">https://medium.com/media/d27cb054f79517cffa57c39f0add1e66/href</a></iframe><h3>Step 4: Run the Program Automatically</h3><p>One more thing. You have to run the code manually every time you want your guardian to work. You can also configure Viam to automatically run your code as a <a href="https://docs.viam.com/manage/configuration/#processes">process</a>.</p><p>To run the Python script from your Raspberry Pi, you need to install the Python SDK on your Raspberry Pi and copy your code onto the Raspberry Pi.</p><p><a href="https://docs.viam.com/installation/prepare/rpi-setup/#connect-with-ssh">ssh into your Pi</a> and install pip:</p><pre>sudo apt install python3-pip</pre><p>Create a folder guardian inside your home directory:</p><pre>mkdir guardian</pre><p>Then install the Viam Python SDK and the VLC module into that folder:</p><pre>pip3 install --target=guardian viam-sdk python-vlc</pre><p>Exit out of your connection to your Pi and use scp to copy your code to your Pi into your new folder. Your hostname may be different, as you can see in the code:</p><pre>scp main.py pi@guardian.local:/home/pi/guardian/main.py</pre><p>Also, you can copy your music file over with this command:</p><pre>scp guardian.mp3 pi@guardian.local:/home/pi/guardian/guardian.mp3</pre><p>Now navigate to the Config tab of your robot’s page in <a href="https://app.viam.com/">the Viam app</a>. Click on the Processes subtab and navigate to the Create process menu.</p><p>Enter main as the process name and click Create process.</p><p>In the new process panel, enter python3 as the executable, main.py as the argument, and the working directory of your Raspberry Pi as /home/pi/guardian. Click on Add argument.</p><p>Click Save config in the bottom left corner of the screen.</p><p>Now your guardian starts behaving like a guardian automatically once booted!</p><h3>Step 5: Next Steps</h3><p>You now have a functioning guardian robot to monitor your pets or people. Or you can use it to greet you when you get back to your desk.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fplayer.vimeo.com%2Fvideo%2F852971649%3Fapp_id%3D122963&amp;dntp=1&amp;display_name=Vimeo&amp;url=https%3A%2F%2Fvimeo.com%2F852971649&amp;image=https%3A%2F%2Fi.vimeocdn.com%2Fvideo%2F1708320355-cecbbdf0588cbac6a6fa3f09d7b312bdb3ffb113568e6c1e9bb1797a496cdf92-d_1280&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=vimeo" width="1606" height="1080" frameborder="0" scrolling="no"><a href="https://medium.com/media/f2a4e7a8f7792f308ab78b1fa67d9bd4/href">https://medium.com/media/f2a4e7a8f7792f308ab78b1fa67d9bd4/href</a></iframe><p>Of course, you’re free to adapt the code to make it do something else, add more LEDs, or even <a href="https://docs.viam.com/manage/ml/train-model/">train your own custom model</a> to use.</p><p>The full code is available at <a href="https://docs.viam.com/tutorials/projects/guardian/#full-code">this viam documentation space</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=30b6465b6138" width="1" height="1" alt=""><hr><p><a href="https://medium.com/better-programming/print-paint-and-program-a-guardian-to-track-humans-and-dogs-using-a-pi-camera-and-servo-30b6465b6138">Print, Paint, and Program a Guardian to Track Humans and Dogs Using a Pi, Camera, and Servo</a> was originally published in <a href="https://betterprogramming.pub/">Better Programming</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A blog post about blog posts]]></title>
            <link>https://medium.com/@naomi_pen/a-blog-post-about-blog-posts-4bb6a6ce0772?source=rss-7f528864f148------2</link>
            <guid isPermaLink="false">https://medium.com/p/4bb6a6ce0772</guid>
            <category><![CDATA[tech-blogging]]></category>
            <category><![CDATA[technical-writing]]></category>
            <category><![CDATA[writing-tips]]></category>
            <category><![CDATA[blogging]]></category>
            <category><![CDATA[blog-posts]]></category>
            <dc:creator><![CDATA[Naomi Pentrel]]></dc:creator>
            <pubDate>Thu, 01 Feb 2018 15:43:32 GMT</pubDate>
            <atom:updated>2018-02-01T21:04:33.496Z</atom:updated>
            <content:encoded><![CDATA[<p>Blog posts are everywhere — you’re reading one. This particular blog post gets meta and focuses on whether to, why to, when to, about what to, and finally how to write technical <em>blog posts</em> ✨. Whether you’ve written before or not, this blog post is designed to equip you with useful skills for writing blog posts. You don’t need any special knowledge or equipment to follow along. First we will set the scene by discussing the ramp up to writing blog posts and then we will explore every step of the writing process from start to finish. So without further adieu, let’s dive right in.</p><h3>Who writes a blog post</h3><p>Virtually anyone. The internet is a big space. You essentially cannot escape people telling you what they think. So don’t let people escape you when you have something to share and could help others with what you know. Anyone can cook and anyone can write a blog post.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/245/0*DKz__yISppVZUO9W." /><figcaption>Ratatouille’s Remi thinking about cooking</figcaption></figure><h3>Why write a blog post</h3><p>So now that it’s clear that you can write, let’s consider 10 good reasons to write (this is a non-exhaustive list):</p><h4>1. It’s fun</h4><p>I like writing, always have. If you enjoy writing as much as I do, why not try doing it with a bit of technical content.</p><h4>2. You learn new things</h4><p>Have you heard of talk driven development? That is when people sign up to speak at conferences about something they don’t know yet! These people use writing as an opportunity to make themselves learn something new. Blog posts function in a similar way. If you’re deadline driven, all you need to do is to announce that you will publish a blog post 😉.</p><h4>3. You learn things more deeply</h4><p>Working on projects is a great way of learning. However it is very easy to skip some of the learning. At least I definitely find myself copy pasting things and if they work, it’s less pressing for me to figure out why they work. So writing about my projects makes sure I actually understand them better.</p><p>When I was in university my professors used to say that you don’t really know something until you’ve had to teach it. That is because having to teach something makes people learn every bit of what they’re teaching, either in advance or when their audience starts to ask questions.</p><h4>4. You retain more of what you learn</h4><p>This one is a simple benefit of repetition. If you repeat something more often you’re more likely to remember it.</p><h4>5. You share your knowledge</h4><p>You get to help people learn and grow which is incredibly rewarding. That by itself is a great reason to write. Whether it’s for beginners or advanced techies.</p><h4>6. People see your blog posts 👀</h4><p>This is sort of the instagram reason of writing and links closely with the next reason.</p><h4>7. It can help your career</h4><p>If you put yourself out there, people will see you and that has advantages. Technical writing is required of almost any software engineer to some degree because every team needs some level of documentation around their tools and code. With your writing, future employers can get an indication of how you think and how you explain things which gives you a chance to shine. Having your writing out there may also result in interesting positions finding you.</p><h4>8. Good for developing your personal network</h4><p>If people see you writing blog posts, they’ll start to know your name as a subject expert, follow you on Twitter, etc.</p><h4>9. It is an alternative to public speaking</h4><p>If you would like to share your knowledge but are afraid of the stage or still working towards taking the stage (which is both totally valid), blog posts are a similar way of sharing but without you seeing your audience directly. They will still get to meet you and learn from you through your writing. An additional advantage is that they can learn from you when it’s most convenient and relevant to them and they can always come back if they want to.</p><h4>10. Opportunities for some extra 💰</h4><p>There are companies that will pay you for your writing. If you’re a student and are looking for some extra cash on the side, this could be a job that allows you to do something relevant to your degree while earning some money 🙌.</p><h3>When to write a blog post</h3><p>Write when it suits you to write. Many people don’t write blog posts until they’re looking for a job. That doesn’t have to be you. It’s your free time and your knowledge, you set the rules. You can write when you’ve learned about something or when you want to learn about something. You don’t need to already know about a subject in order to write about it — it’s perfectly valid to learn while writing. In fact this gives you the opportunity to write down all the questions you have and answer them in your writing. If you know a subject already you may be more biased in assuming that some parts are ‘obvious’ and you will have to work harder to ensure you cover everything. So anytime you have time and want to write is a good time really.</p><h3>What to write a blog post about</h3><p>Have you found something people don’t seem to know about or don’t find obvious? Help them on a broader scale. If you find yourself repeating advice or explanations a lot, this is a good indicator that you could write about it (that way you can also afterwards just share a link whenever someone asks).</p><p>If not that, ask yourself what younger you from a year (or a month) ago would have liked to read a blog post about.</p><p>Don’t get discouraged if someone else already wrote about the same thing or a closely related thing. Maybe that blog post isn’t as detailed, or maybe it’s aimed at someone else. It’s always good to have multiple resources about the same topic out there! Some people will prefer your style of writing over another’s.</p><p>Lastly, just write about something you care about or would like to learn.</p><h3>How to write a blog post</h3><p>Finally. Let’s talk about what you really came here for and if you didn’t come here for this and got convinced by the above that’s also 👌. We will assume you’ve chosen your topic and now want to get writing. Let’s go!</p><p>Note: This is one way of writing blog posts. It is not the only way you can choose to write. It is merely a helping hand if you don’t know how to start. Feel free to ignore it, tear it apart and put the parts together differently, or use it as is — totally up to you.</p><h4>1. Your writing environment</h4><p>It is your choice whether to start with 📜, 📱, 🖥, 💻, or another platform. You do you! Don’t let anyone tell you where to write.</p><p>I personally like writing on trains where I have no internet. My first draft is often in plain text or Markdown which I like to write on <a href="https://atom.io/">Atom</a> with my two favorite packages:</p><ul><li><a href="https://github.com/npentrel/octoclippy">Octoclippy</a>, a friendly Octocat or Hubot that keeps you company and does funny animations when you save your document.</li><li><a href="https://atom.io/packages/activate-power-mode">Activate Power Mode</a>, a package that counts your writing streaks and gives you encouragements as you write.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/530/0*wt1CJiahjr2tpvI9." /><figcaption>My atom setup with the packages Octoclippy and Activate Power Mode</figcaption></figure><p>However, my favorite editor doesn’t have to be yours. Spend a bit of time making your writing environment what you want it to be. It will be worth it.</p><h4>2. Don’t start with a blank editor/page!</h4><p>If you start with a blank page it will probably be harder for you to write because it feels like you have no idea how to go from nothing to this great piece of writing you envision. Instead, try one of the following approaches:</p><p>Use a blog post wireframe like this one:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1208c4da5206735b2452149e1752ef1c/href">https://medium.com/media/1208c4da5206735b2452149e1752ef1c/href</a></iframe><p>Or:</p><ul><li>write down random bullet points of things you would like to mention in your post</li><li>start by drafting an outline</li><li>write down a list of the questions you get asked about the topic or would have once asked yourself</li></ul><p>If you start in these ways you will have something to guide you while writing and a place to keep to-do’s — would recommend. After this brainstorming session you should have some assembly of thoughts written down.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*1EpwV7rBcSIUS36o." /><figcaption>A screenshot of the outline and thoughts that were the beginning of this post</figcaption></figure><h4>3. Starting to write</h4><p>Trick headline. If you followed step 2, you already started to write! You’re doing so well! 💯🔥</p><p>Depending on how you chose to start you will either have a random assortment of thoughts about things you will want to mention or you will have a nicely structured first outline. The next step is to create an outline with bullet points/random thoughts about what should be in each section, including code snippets (if applicable).</p><p>Don’t feel like you need to stick to your outline at any point, if you feel you need to change anything, change it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*P82fXTyXKfukGziG." /><figcaption>A screenshot of this blog post at the stage of it being a structured outline with notes</figcaption></figure><p>At this point you have a structure and some ideas for each section which means you are at about 20%-30% of the blog post process — well done! Now (or potentially after the next section on <em>targeting</em>) is a great time to show your thoughts on the structure of your blog post and the concepts you will cover to a first reviewer. They can give you feedback on whether the basic structure makes sense to them and whether you are covering the right bits.</p><h4>4. Targeting your writing</h4><p>While writing, you should always keep your audience in mind. In the intro you will want to mention your target audience so that readers are aware whether they are in the right place! Knowing you’re in the right place is very important for an audience that just committed to reading your work — nobody likes spending time reading a post just to find out it wasn’t the right thing for them.</p><p>Throughout your post your knowledge of the audience will inform your style of writing, as well as the level of detail you choose to incorporate. If you’re writing for students, you will likely use a different style than if you are writing for bankers. Similarly you will likely want to go into more details on setup and give more information on steps if your audience has <em>less experience</em>.</p><p>Less experience. This is a difficult concept. It’s very hard to establish a common ground of technical knowledge between everyone in your potential audience. My rocket science could be your walk in the park — so you shouldn’t assume people will be familiar with the technologies you are. Again, it will pay off to mention in the beginning what level of experience and which tools you will expect people to know to be able to follow along.</p><p>When in doubt, it is always better to include too much rather than too little detail. If the content is well structured, people can skip the bits they know. On the other hand, people who don’t know these details can read them and not struggle and give up because of an assumption that ‘everyone knows X’. Later in this post, we’ll talk about GIFs and Screenshots which are an especially great way of packaging a lot of setup information in a nice, clear way. They are easy to skip, yet will help people with less experience a lot.</p><p>So for now, think of how you want to write and decide on an audience and outline this audience in your intro while setting the expectations as to which knowledge and tech stack is required to follow along. If needed, add a section below your intro for requirements.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VofbO5mtddLTnGspAtX7HQ.png" /><figcaption>A screenshot of the beginning of this blogpost with the emphasis on the third sentence where the target audience is described</figcaption></figure><p>As you continue, keep this audience in mind and try to put yourself into their shoes.</p><h4>5. Voice</h4><p>Your blog post can be as formal or informal as you want it to be. This is your voice you’re using to explain a topic and your way of writing is part of how you choose to portray yourself. Whether you include memes, emojis, etc. is up to you — or up to the company’s voice guide if you’re writing for a company. Generally it seems to me that people prefer to read less formal writing, meaning shorter sentences and not the type of words you’d use to impress your former (or current) teachers. People should focus on understanding the technical contents of your blog posts — not your language.</p><p>Other things to consider:</p><p><strong>Active Voice.</strong> <a href="https://freelance-writing-articles.knoji.com/technical-writing-basics-using-the-active-voice/">Use <em>active voice</em> as opposed to passive voice</a>, i.e. “Nexmo sends a request to our webserver” rather than “a request is received”. Active voice ensures that the actors are identified and it generally leaves less open questions. The exception is if you want to emphasize the object of the sentence.</p><p><strong>We all know</strong> that we don’t know everything. Using phrases like ‘Obviously…’ or ‘As I am sure we all know…’ can make people uncomfortable if they don’t know the thing that you claim is obvious, especially in a technical context. These phrases don’t add anything to your content — so try to exclude them.</p><p><strong>s/he/they/g.</strong> This is an expression that will replace occurrences of <em>he</em> with <em>they </em>if used in a text editor like <em>vim</em>. Try to be inclusive and mix up genders. If you use ‘he’, mix it up and use ‘she’ as well (or better even: use the <a href="http://iheartsingularthey.com/">singular <em>they</em></a> which is gender neutral). Apply the same to words like <em>guys</em> (e.g. <em>engineering guys</em>). Replace them with neutral words like <em>programmers</em>, or <em>folks</em>, or <em>humans</em>. If you need inspiration or more information about this, check out <a href="http://inclusivewords.com/">inclusivewords.com</a>. Try to also vary your examples: maybe the CEO in your blog post could be Jenny and not Steve or just an ambiguous name like René. The reason this is important is because you’re speaking to a broader audience whose way of thinking you will influence whether you’re aware of it or not. So give the language you use a thought.</p><p>Try and come up with a small style and voice guide for yourself and then stick to it while you continue writing your blog post. If you want more inspiration, consider the <a href="https://styleguide.mailchimp.com/">Mailchimp Content Style Guide</a> and the <a href="https://content-guide.18f.gov/inclusive-language/">18F Content Guide</a>. They are great assets to read further into.</p><p><strong>6. Filling in the gaps</strong></p><p>By now each section of your writing should have bullet points and code snippets on what it should contain. In this step you will take your bullet points and turn them into text. Ideally, you will want to wrap your whole blog post into a story or timeline. This allows readers to follow your content more easily. The blog post you’re reading is trying to show you how to write a blog post, after hopefully convincing you that you are the right person to write.</p><p>As you transform your bullet points and code into a complete text, you will want to research bits that you don’t know and think about how to make it easy for the reader to understand. Focus on what you want the reader to learn and what information will help them most. When giving readers code, try to explain difficult logic or concepts and what each bit of code does. This will be easier if you have broken the code up.</p><p>While wrapping your content into a story you may find yourself talking about your achievements more than giving actionable advice. If that happens, try to get to the bottom of how you achieved these achievements and break this process down, then focus on the process more than on your personal achievement. You can, of course, mention your own story elements if they fit — which will depend on the context. If your blog post has a more autobiographical nature, then ignore my comments. However in my experience most technical blog posts will not be of autobiographical nature.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-wcxCCtHqb-i6DhjCMN7rA.png" /><figcaption>A screenshot of this post as it has become text and is nearing the finish line.</figcaption></figure><p>With all the actionable instructions and advice you’re giving, you will want to make sure that as people carry out each action/step, they stay engaged and can ideally tell that they are doing it right. You can do that by making the steps small and the goal very clear and, if in code, by giving people tests of what they should be able to do after each step. This will ensure that people know how to tell if they have achieved what they were supposed to in each step and it will give them a wonderful feeling of having accomplished something good. These ‘oh it’s working’-moments will encourage people to continue and reassure them that they’ve got this. For people that get lost or confused, it’s great if you offer the full code for each section.</p><p>Did you notice that we jumped right into the writing bit and started explaining how everything worked? We shouldn’t forget to document our setup! Are you using Python2 or Python3? What frameworks are you using? Which APIs? How do people sign up and install everything? You will want to make sure to document your setup clearly. Here GIFs will work absolute wonders as they can show long processes without a wall of text. The gif below shows the relatively lengthy process of creating keys for a Microsoft API. We will go through how to create these GIFs later. However, you should already know that GIFs should always come with good alternative texts that fulfil the same purpose as the GIFs to ensure maximum accessibility.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*n4EYzegOuLNkH7Qm." /><figcaption>An illustration of a long sign up process for a Microsoft API</figcaption></figure><p>After you document your entire setup, it is a good idea to start from scratch and follow your own instructions to make sure that everything works (if you can, try to consider different environments in your instructions or try to give people an online environment, like <a href="https://glitch.com/">glitch</a>, that will work the same for everyone).</p><p>After working through this section you should have a complete text with actionable advice and instructions using small steps and clear goals with plenty of ‘yay it’s working’ moments. You should also have a clearly outlined setup. Great work!</p><h4>7. Polishing</h4><p>Now that you’ve written your blog post almost completely, it’s time to polish off any rough edges. Read over it a few times and put on the hat of a reader. While doing so, ask yourself:</p><ul><li><strong>Am I telling a coherent story?</strong> Your post will be easier to follow if you tell one story and fit your content along that story line. Explain where you’re starting from and what the problem you’re addressing is. Use this background as a narrative to structure your content. The story will allow you to make sure that every step brings your audience closer to a goal.</li><li><strong>Do I introduce hacks?</strong> If you know something you are doing is a hack — try hard to avoid this hack. Describing somewhere in a side note that what you’re doing shouldn’t be done on production is a start but the chances that people will not see the note or ignore it are high. If you have to introduce hacks point them out within the code and give the reader an idea of how to fix it or add links that inform people how to fix it.</li><li><strong>Am I missing steps?</strong> Follow your entire process once more and test it to see whether you missed something. It’s hard to notice this until you actually force yourself to follow all your steps as written down.</li><li><strong>Is my beginning catchy and concise?</strong> The beginning paragraph is where your readers will decide whether to navigate away or whether to give you their undivided attention. You will want to make clear who your audience is and what you’re offering the reader. Additionally, you’ll want to keep it brief, otherwise you run the risk of people not reading everything and instead just glancing at bits.</li><li><strong>Does my ending have a call to action?</strong> What do you want people to do after they read your blog post? Reach out to you with questions? Read other blog posts? Work further on the contents of the blog post? These are some options of what you may want as an outcome, but for each of them you should give the reader a slight nudge into the direction you’d like them to go. You can do this in several ways, for example by giving your contact details, linking to other content, or giving ideas on possible extensions of the project.</li></ul><p>During this polishing stage don’t worry if you find yourself going through some of the previous steps again — that is perfectly normal. When I write I tend to have a todo list at the end of my post and work on that as I am progressing.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/0*avhfB42_MaOwF0KS." /><figcaption>A graphic that illustrates that you can move from any step back to any previous step</figcaption></figure><h4>8. Tips and tricks and throughts</h4><h4>Code Snippets</h4><p>Make sure to include code snippets when you’re doing a technical blog post that requires them! Ideally with syntax highlighting. Break your code up and explain each section. Doing so will make it easier for people to follow. If possible also provide a link to the full code for people so that they can see how the pieces fit together.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/bd3189aaa3841f1a9c2ca349a7455e22/href">https://medium.com/media/bd3189aaa3841f1a9c2ca349a7455e22/href</a></iframe><h4>Screenshots 📸</h4><p>Use screenshots! They’re great to break up huge chunks of text and to help your audience follow along. As you do this, it’s a great improvement for <a href="https://styleguide.mailchimp.com/writing-for-accessibility/">accessibility</a> if you provide good alternative texts for your screenshots and GIFs, so that people who cannot see the images can get the same information.</p><h4>Use GIFS</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/0*Fo1XhcxoIAbV8Mes." /><figcaption>An illustration of the usage of GIFs</figcaption></figure><p>But how I hear you ask! First, I used the preinstalled QuickTime on my Mac (if you’re on a different platform please Google what the best option is as I am not an expert in how to do it elsewhere 🤫).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/914/0*6N_3R9WDLNL7MEVQ." /><figcaption>A screenshot of the QuickTime menu for making screen recordings</figcaption></figure><p>Unfortunately the only thing it won’t let me record is how to use it. So if you want to see how to do that watch this video <a href="https://www.youtube.com/watch?v=m4s7YF7OEBY">here</a>.</p><p>QuickTime will output a video of your screen recording which you will then have to convert into a gif. I would recommend using <a href="https://ezgif.com/">ezgif.com</a> for this. See below the entire process of converting it and speeding it up! The speeding it up is mostly so that I don’t have to bore you with my slow typing and menu interactions. It may also be because I am a little concerned with how slow I am…</p><p>However, while GIFs can be great, <a href="https://styleguide.mailchimp.com/writing-for-accessibility/">please create alternative text</a> so that people who cannot benefit from the GIFs are also able to follow the steps.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/0*9-fu8vH9tw-2kfYr." /><figcaption>A GIF that shows the upload process for a video, which is then converted into a GIF and sped up</figcaption></figure><h4>To link or not to link</h4><p>Experienced blog post folks say that every link in your blog post can mean people leave your post and never come back. A way to avoid people going down rabbit holes in your post and not coming back is to have very few links and to ideally place them at the end.</p><p>It can however be helpful to link to tutorials that cover bits that you don’t cover which helps out beginners in particular — so it’s a difficult choice. As you see in this post I try to have few but helpful links where I consider them needed.</p><h4>Teachable Moments/Tips</h4><p>You very likely have workflows that quite a few people around you don’t have and would love to hear about. Maybe you use a tool called <a href="https://textexpander.com/">TextExpander</a> to turn small commands like <em>addr;</em> into your address or maybe you have a copy-paste-clipboard manager that allows you to reuse and search through things you previously copy-pasted. Each of the people who introduced me to these things thought of it as completely normal and commonplace. Yet both suggestions helped my productivity immensely! The same goes for coding and terminal usage (did you, for example, know that ctrl-u deletes from your cursor to the beginning of the line in a terminal?). So if you use productivity apps or shortcuts while creating your blogpost — give them a quick shout out. <a href="https://medium.com/@emckean">Erin McKean</a> calls these moments in talks <em>teachable moments</em>, i.e. unplanned/natural opportunities that offer an ideal chance to offer insight to an audience.</p><h3>After you write your blog post</h3><h4>1. Reviews</h4><p>Whether you do or don’t want a review is entirely up to you and depends on your situation. If you choose to have reviewers then you should provide then with a good reviewing environment. Your reviewers should have an easy time writing comments and fixing typos. The by far easiest method I know for this is Google Docs. Within Google Docs select to share your document with the option <em>can comment</em>. This allows reviewers to add suggestions and comments. You can then accept or reject these suggestions and you can comment on issues to discuss them further.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*JGO0RbxNvbkmmO32." /><figcaption>A screenshot of the Google Docs sharing dialogue</figcaption></figure><p>When writing blog posts for companies, they will generally be reviewed by the companies themselves of course. If you’re writing professional blog post without a company, you will probably want someone to scan it for typos and grammar mistakes (spell check is also a good friend but not perfect). You may also want someone to proofread your technical content.</p><p>Let’s start with typos and grammar. Since everyone reads, everyone who has a good sense of language can give you a bit of feedback. So ask your friends, co-workers, siblings etc. for help! One person is probably enough. Be sure to pay for their coffee next time you see them or otherwise show them your thankfulness ;).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/0*akO8W9HjglvSDaie." /><figcaption>An illustration of the amount of comments left on the final draft of this blog post</figcaption></figure><p>For a technical review, you will want to look at someone from your target audience and potentially someone who knows about it already. If your target audience is beginners then asking someone less techy would be a great idea. Thus you can gather their feedback on things that are unclear to them and work on those to make it even better — meanwhile they will gain skills by going through it (it’s a win win!). Asking someone who knows the topic will also be helpful as they will be able to point out things you can improve or maybe explained wrong. You may or may not need both types of review. It really depends on your situation and you will have to be the judge of that.</p><p>Don’t feel like you have to get a review if you don’t want to. You may find that people will try to change the voice of your blog post to a way they would do it. Don’t feel obliged to take this feedback. In fact, don’t feel obliged to take any feedback. However, if you find you’re not getting feedback you want to work on you should probably ask someone else next time. Asking for feedback and then ignoring it wastes both your and your reviewer’s time.</p><h4>2. Publishing and Promoting!</h4><p>With your blog post reviewed and ready, the next question is how to get <em>everyone</em> to read it. There are multiple platforms you can choose to publish your blog posts on such as <a href="https://medium.com/">medium</a>, Wordpress, etc.. Medium is very easy to use and if you’re just getting started it is probably the right choice. Alternatively you could consider making your own blog. If you’re interested in starting a blog, check out <a href="https://pawlean.com/2018/01/17/starting-a-blog/">Pauline Narvas’s post</a> about her starting her’s.</p><p>Once published, you get to share your work on Twitter, Facebook, Instagram, LinkedIn, and all your other Social Media. I must say this isn’t what I am an expert on. If you’d like to read more, Pauline’s post about starting her blog has a good section on <a href="https://pawlean.com/2018/01/17/starting-a-blog/#five">promoting your blog post</a>.</p><h4>3. Feedback</h4><p>First of all: CELEBRATE! You’ve done it, you’ve written a blogpost. <a href="http://larahogan.me/">Lara Hogan</a> says that whenever you achieve something great, you should celebrate this with your own little indulgence. That will make sure that you take the time to appreciate and reflect on your achievements. Her ritual is getting herself a fancy donut. So go get your version of a 🍩!</p><p>After you come back you may encounter that the first few people read your blogpost. They can react well or not so well. People can come up with a variety of reasons for not liking your writing. Don’t take it too harshly. If you want to read through the comments, try to filter the constructive bits out. If it’s not constructive feedback, ignore it and don’t engage. You can’t please everyone. I can guarantee you some people will tell me off for writing this blog post because I’ve only written X blog posts. But hey, I never claimed I was an expert. I just hope someone will find this useful. If just one person finds this helpful — it’s a win. Also:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/245/0*hz_iq8J0B1u1AWtY." /><figcaption>Haters gonna hate</figcaption></figure><p>BUT it’s not all horrible — there is also the positive feedback! People who say that they found your writing helpful. That is much more important than any negative feedback. If you can and want to, go ahead and engage with people that comment and answer their questions if you know the answers. Connect with them too! Also if you’re keen, then turn your blog post into a talk and apply to conferences with it. There is also a talk version of this post which which I created for <a href="https://www.meetup.com/en-AU/Women-In-Tech-Nottingham/events/246837596/">Women in Tech Nottingham</a>.</p><h3>Conclusion</h3><p>I hope you enjoyed reading this and have learned something useful. If you have any questions please reach out to me on <a href="https://twitter.com/naomi_pen">@naomi_pen</a> or at <a href="http://naomi.codes/">naomi.codes</a>.</p><p>Also if you do end up writing a blog post after seeing this. Please let me know — I promise to share it for you in return 💖 (and it will make my day).</p><p>PS: If you’re a student, have a look at <a href="https://education.github.com/experts">GitHub’s Campus Expert Program</a> — they have great resources to learn technical writing and other skills!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4bb6a6ce0772" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A Hacker’s Guide to a US Internship]]></title>
            <link>https://medium.com/@naomi_pen/a-hackers-guide-to-a-us-internship-1510a69ad3db?source=rss-7f528864f148------2</link>
            <guid isPermaLink="false">https://medium.com/p/1510a69ad3db</guid>
            <category><![CDATA[silicon-valley]]></category>
            <category><![CDATA[hacker]]></category>
            <category><![CDATA[united-states]]></category>
            <category><![CDATA[internships]]></category>
            <category><![CDATA[programming]]></category>
            <dc:creator><![CDATA[Naomi Pentrel]]></dc:creator>
            <pubDate>Sun, 03 Jul 2016 16:12:16 GMT</pubDate>
            <atom:updated>2016-07-05T22:23:54.870Z</atom:updated>
            <content:encoded><![CDATA[<h3>An International Hacker’s Guide to a US Internship</h3><p>Throughout the past few weeks a few of my friends went to the US to do an internship. One ended up spending $12 on two packs of cookies thinking he would spend $5 because there was a discount. He also ended up paying $50 per month on a phone plan (and could have gotten the same for $25). Common traps for interns. This is why I put together a list of some tips that will help you to earn some extra money and to avoid additional costs.</p><p><strong>BANK ACCOUNTS. </strong>A lot of banks in the US charge a <strong>monthly maintenance fee </strong>(e.g. Bank of America charges $12 per month if you have a balance below $1500). There are some that do not and I’d highly recommend seeking those out if you are intent on keeping your American bank account after you leave.</p><p>As an additional perk: Some banks give you a <strong>bonus of up to $300</strong> for opening a bank account and receiving a salary for at least 3 months in a row. <a href="https://www.nerdwallet.com/blog/banking/checking-account-promotions/">Check some online comparisons.</a> Note that for some banks you will need a SSN so get yours as soon as possible.</p><p>Some banks also have accounts that are free while you are a student but they may not be available to you if you do not study in the US so make sure to ask.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2FSsTcO55LJDBsI%2Ftwitter%2Fiframe&amp;src_secure=1&amp;url=http%3A%2F%2Fgiphy.com%2Fgifs%2Fspongebob-squarepants-money-squidward-SsTcO55LJDBsI&amp;image=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2FSsTcO55LJDBsI%2Fgiphy.gif&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="326" frameborder="0" scrolling="no"><a href="https://medium.com/media/7a23bc437fd6c2407186aad67d36d404/href">https://medium.com/media/7a23bc437fd6c2407186aad67d36d404/href</a></iframe><p><strong>PHONE PLANS. </strong>Phone plans in the US are expensive. If you go to T-Mobile or O2 you will likely end up paying at least $50 month. There’s <a href="http://www.walmart.com/ip/T-Mobile-Complete-SIM-Kit/39081494">one plan though that you can get at <strong><em>Walmart</em></strong></a> which gives you <strong>all you need for half</strong> that. You buy the package for $34.82 which includes the first month after that it’s $25 a month (5GB data, 100 minutes, unlimited texting). A plan that is more customizable is <a href="https://ting.com/rates"><strong><em>Ting</em></strong></a> (e.g. for 500MB of data you would pay $18/month, for 100MB of data only $9). Both can be cancelled at any time.</p><p>If you are from the UK, you can get <a href="http://www.three.co.uk/Store/SIM/Pay_As_You_Go"><strong><em>Three</em></strong></a><strong><em> </em></strong>for 20 GBP/per mont (12GB data, 300 minutes, 3000 texts). The internet can be used abroad!</p><p><strong>SUPERMARKETS. </strong><em>It’s a traaaaap! — No really</em>. Most discounts are not going to be applied on your shopping <strong>unless </strong>you have a <strong>loyalty card</strong>. They tend to be free so get one <strong>before</strong> you go shopping. There are even some stores like Costco you can’t buy from without a membership card.</p><p>If you don’t want to carry the card some supermarkets let you put your phone number in instead. This means if you can get someone else phone number you don’t need to sign up…</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/816/1*4KPS0BvJqIqxgUJ3Rmav6w.png" /><figcaption><strong>Note the “Club Price”.</strong></figcaption></figure><p><strong>AMAZON. </strong>If you’re a student sign up for the<strong> </strong><a href="https://www.amazon.com/gp/student/signup/info"><strong><em>free prime</em></strong> student version</a>. Set a reminder to cancel it though. If not you can get a one month trial!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/451/1*3jd5OtWBtZEWUtujUpk0xg.jpeg" /></figure><p><strong>TRANSFERRING MONEY ABROAD. </strong>Banks will give you a horrible exchange rate. <a href="https://transferwise.com/u/6e8d4"><strong><em>Transferwise</em></strong></a> is one of your best options to get money abroad. Example: If you send $1000 to the Euro zone. A bank can alter the exchange rate and charge for the conversion making the transfer cost up to $80. Transferwise will charge 1% (i.e. $10).</p><p><em>Use this ref link to get the first transfer free: </em><a href="https://transferwise.com/u/6e8d4">https://transferwise.com/u/6e8d4</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1012/1*XWzzUUdlZLpdVQJv_X6wZw.png" /></figure><p><strong>FACEBOOK GROUPS. </strong>If you are in the valley there is a Facebook group with lots of other interns and relevant events:</p><ul><li><a href="https://www.facebook.com/groups/2016bayareasummerinterns/">Bay Area Summer Interns 2016</a></li><li><a href="https://www.facebook.com/groups/nycinterns2016/">New York Interns 2016</a></li></ul><p>There’s probably one in your region too! If not you could always start one.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2F148mZ6HjOfNHc4%2Ftwitter%2Fiframe&amp;src_secure=1&amp;url=http%3A%2F%2Fgiphy.com%2Fgifs%2Fdownton-abbey-tv-shows-148mZ6HjOfNHc4&amp;image=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2F148mZ6HjOfNHc4%2Fgiphy.gif&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="452" frameborder="0" scrolling="no"><a href="https://medium.com/media/d149abaf1e83248b45122617645d3100/href">https://medium.com/media/d149abaf1e83248b45122617645d3100/href</a></iframe><p><strong>CAR RENTALS. </strong><a href="http://www.zipcar.com/"><strong><em>ZipCar</em></strong></a> has a lot of great feedback and you can rent cars for as little as an hour. If you have the option of a rental car, generally you should take it (or share it with roommates). In places like Seattle or the valley you can get by with Uber-like service, biking, and public transport but even then a car can be useful. Overall it is very difficult, if not impossible to get around without a car in most parts of the US.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2F13t2Pg48YCJSb6%2Ftwitter%2Fiframe&amp;src_secure=1&amp;url=http%3A%2F%2Fgiphy.com%2Fgifs%2Fcar-cars-gif-13t2Pg48YCJSb6&amp;image=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2F13t2Pg48YCJSb6%2Fgiphy.gif&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="244" frameborder="0" scrolling="no"><a href="https://medium.com/media/c52d8b7406d51bf56432aade436ec9c0/href">https://medium.com/media/c52d8b7406d51bf56432aade436ec9c0/href</a></iframe><p><strong>GETTING A LICENSE. </strong>If you happen to be in a state like Washington and don’t have a driver’s license, it would be inexpensive to get one here and get it transferred. If you are in California transferring is not easily possible. These things of course depend on where you are from and where you want your license to be valid.</p><p><strong>TRAVELLING. </strong>If you do not have a car you can get to different cities with <a href="http://us.megabus.com/"><strong><em>Megabus</em></strong></a>.</p><p><strong>LAUNDRY. </strong>If you’re in New York <a href="http://flycleaners.com/"><strong><em>Fly Cleaners</em></strong></a><strong> </strong>is an easy app that allows you to schedule for someone to come get your laundry and bring it back fresh and clean. There are similar services elsewhere and they save you time especially if you don’t have laundry facilities in your accommodation.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2FK2LOoIMgzJq7u%2Ftwitter%2Fiframe&amp;src_secure=1&amp;url=http%3A%2F%2Fgiphy.com%2Fgifs%2Fvideo-siz-wombats-K2LOoIMgzJq7u&amp;image=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2FK2LOoIMgzJq7u%2F200.gif&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="244" frameborder="0" scrolling="no"><a href="https://medium.com/media/ff4e6eeb3280d09868028af2944af7ae/href">https://medium.com/media/ff4e6eeb3280d09868028af2944af7ae/href</a></iframe><p><strong>COUPONS. </strong>America has tons of these. If you order something online it’s always a good idea to google “Store Name + voucher” and see what comes up. The <a href="https://chrome.google.com/webstore/detail/honey/bmnlcjabgnpnenekpadlanbbkooimhnj">chrome extension <strong><em>honey</em></strong></a> can do some of this automatically. There’s lots of hype around <a href="https://www.groupon.com/"><strong><em>Groupon</em></strong></a> too.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2F3oEjHVJtaC1T1w4Be8%2Ftwitter%2Fiframe&amp;src_secure=1&amp;url=http%3A%2F%2Fgiphy.com%2Fgifs%2Fmichaelbruno-music-video-justin-timberlake-cantstopthefeeling-3oEjHVJtaC1T1w4Be8&amp;image=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2F3oEjHVJtaC1T1w4Be8%2Fgiphy.gif&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="310" frameborder="0" scrolling="no"><a href="https://medium.com/media/f9a99b1f7dbbe9bd7337c1406e652d9c/href">https://medium.com/media/f9a99b1f7dbbe9bd7337c1406e652d9c/href</a></iframe><p><strong>FOOD/GROCERY DELIVERY. </strong>If you’re not into cooking ordering takeout is easy from <a href="https://postmates.com/"><strong><em>Postmates</em></strong></a> or <a href="https://www.doordash.com/"><strong><em>DoorDash</em></strong></a> or <a href="http://eat24hours.com/"><strong><em>Eat24</em></strong></a>. Having groceries delivered works with <a href="https://www.instacart.com/"><strong><em>Instacart</em></strong></a><strong><em> </em></strong>or <a href="http://www.freshdirect.com/"><strong><em>FreshDirect</em></strong></a><strong><em>. </em></strong>When I was there ordering my food from <a href="https://play.google.com/store/apps/details?id=com.safeway.shop&amp;hl=en"><strong><em>Safeway</em></strong></a> was <em>cheaper </em>and a lot easier. #AmericanDream</p><p><strong>USEFUL APPS (which you might not know yet):</strong></p><ul><li><a href="https://venmo.com/"><strong><em>Venmo</em></strong></a><strong><em> &amp; </em></strong><a href="https://cash.me/"><strong><em>Square Cash</em></strong></a><strong><em> &amp; </em></strong><a href="https://www.facebook.com/help/messenger-app/750020781733477/"><strong><em>Facebook</em></strong></a><strong><em>.</em></strong><em> Easily send money to your friends. Like </em><a href="https://joinverse.com/en/"><strong><em>Verse</em></strong></a><em> in Europe.</em></li><li><a href="https://www.mint.com/"><strong><em>Mint</em></strong></a><strong><em>. </em></strong><em>Money managing and budgeting app.</em></li><li><a href="https://www.uber.com/"><strong><em>Uber</em></strong></a><strong><em> &amp; </em></strong><a href="https://www.lyft.com/"><strong><em>Lyft</em></strong></a><strong><em> &amp; other local equivalents.</em></strong><em> There is a lot of them by now and they usually come with a free first ride. Wherever you live check Google for the Uber alternatives.</em></li><li><a href="https://www.taskrabbit.com/"><strong><em>TaskRabbit</em></strong></a><strong><em>. </em></strong><em>If you want someone else to do your chores this is your app.</em></li><li><a href="https://www.robinhood.com/"><strong><em>Robinhood</em></strong></a>. <em>Free stock trading. Only usable in the US with a SSN.</em></li></ul><p>PS: These are just some of my tips that will hopefully help you getting settled a bit better in the US and fully enjoy your internship!</p><p>PPS: Have something to add? Let me know on <a href="https://twitter.com/naomi_pen">Twitter</a> or at <a href="http://naomi.codes/">naomi.codes</a> !</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1510a69ad3db" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>