Category: Uncategorized

  • KonamiRickroll: Add a rickroll to your site via Konami code

    Ever wanted to have a little easter egg in your website? I sure did! With my new JavaScript script, you can now add an easteregg rickroll to your website (more…)

  • Running a public website on an Arduino

    Hey!

    I just got a public website running on a NodeMCU microcontroller. There were a few obsticles that I had to tackle before finishing, and let’s get started!
    (more…)

  • Running an Arduino directly off of solar panels… (PART 1: Planning)

    A little background…

    At school, we are currently doing a unit in which we make a vehicle that goes exactly 5 meters but is not powered by any chemical source. This may sound easy, but “chemical source” also means no gas and NO BATTERIES. I could do the “easy” method and use a spring and rubber band or something, but if I learned anything, it’s that when I have a problem, the answer is an Arduino board.

    The idea

    I am thinking of using an Arduino Nano-like board, as it uses .4 to .8 volts, and I expect that power will be of concern because I only have 5 volts to work with. I may add another 5 volts via a second solar panel, but I don’t know. My idea is to have a 3-wheel vehicle. One wheel will have a motor, which is attached to a relay, which is attached to an Arduino that turns it on in short one meter shots so it will be able to go very close to 5 meters without any fancy lego contraptions to stop it from moving. I feel like I can fix any problem in software, as long as I have a good vehicle. My team and I decided what we’ll use foam to keep the machine light, as we have to carry two “passengers” (a roll of 50 pennies), which weigh about 250 grams. This is why weight is a problem. The motor NEEDS to be able to move with the load, and do it FAST.

    Code

    Here’s the current code I have

    /*
      Low power car.  Code by Damien Boisvert.
      
      This program is licensed under MIT.
    
    Copyright (c) 2023 Damien Boisvert (AlphaGameDeveloper)
    
    Permission is hereby granted, free of charge, to any person obtaining a copy
    of this software and associated documentation files (the "Software"), to deal
    in the Software without restriction, including without limitation the rights
    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
    copies of the Software, and to permit persons to whom the Software is
    furnished to do so, subject to the following conditions:
    
    The above copyright notice and this permission notice shall be included in all
    copies or substantial portions of the Software.
    
    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
    SOFTWARE.
    */
    
    // Options variables.
    // set number of meters to go.
    const int meters = 1
    // set amount of time per meter.  Get this via
    // tests and some cool shit
    const long meterTime = 5
    
    // unneeded lmao
    const float betweenMeterDelay = .5
    // -----------------------------
    // |     NERD SHIT ALERT!!!    |
    // -----------------------------
    
    // initalize pin numbers.
    const int motor = 5 // motor relay mounted at pin 5.
    const int button = 6// button mounted at pin 6
    bool iCanHasInitalized = false
    
    void setup() {
      Serial.begin(9600
      pinMode(motor, OUTPUT
      pinMode(button, INPUT
      Serial.print("Waiting for button to be pressed"
    }
    
    void loop() {
        // wait for the button to be pressed
        // in order to start the machine
        int m_isPressed = digitalRead(button
        if (m_isPressed == LOW) {
          // nope, button is not pressed.  Do nothing.
          Serial.print("."
          return
        }
        // if it reaches here, the button HAS to have been
        // pressed because of the variable m_isPressed, right?
        Serial.println("nYES OH MY GOD THE BUTTON WAS FINALLY PRESSED!!!!!"
        Serial.println("Startin' da plan, BOSS!"
        
        for (int i = 0 i &lt meters i++) {
          Serial.print("debug: Starting new meter..."
          digitalWrite(motor, HIGH
          delay(meterTime
          digitalWrite(motor, LOW
          Serial.println("done."
          delay(betweenMeterDelay
          
        }
    }
    

    This code waits for a button, and moves it in one meter bursts, with a meter time from testing. I know that I’ll change it, but this is what I got.

    Cheers,

    • Damien Boisvert
  • Download this Website!

    If you are like me, you want to do stuff because you can and why not. One of these things is recursive website downloading.

    What the junk does that mean?

    Before I explain, let me explain web crawlers, like Google’s Googlebot. Their job is to search the internet ALL DAY, EVERY DAY!
    They will go to a website, and check for links, like this.

    • Download the site
    • Scrape it for links
      • If a link is found, download the linked page and repeat.
      • If no, go crawl another link

    Using the way that lots of Internet sites link to each other, this lets you index lots (if not all) of a website.
    You can do this yourself to secure yourself an offline copy of a static website (like this one.)

    TEACH ME THIS POWER!!1!!1

    Here’s what you need

    • A computer (windows is ok but Linux is preferred)
    • The wget command (link for Windows to download is here
    • A target (you can use this website–I don’t mind!)

    Now, it’s finally time to download. Run this command wget --recursive -l inf https://alphagame.dev/

    Let’s explain what that command did. The first option, --recursive, told wget to download a page and keep going deeper by
    finding links. The -l inf tag told it to download infinite layers, like if you have to go deep to find a page. Or, you
    can do -l 2 to find only the main links from the page you chose. If you ran this command, you will see a new folder, alphagame.dev
    (or whatever site you downloaded). It will have lots of files, that you can open in your web browser, or host locally and look. I
    will point out that this mostly only works on static web pages as others may use the internet AFTER the page is loaded which defeats the
    purpose.

    Be responsible

    While this is a cool trick, be careful how you use this, as it can lead to you spamming the server and you being blacklisted.
    An example is in Wikipedia’s robots.txt file. You can see that they blocked wget because
    it was too hard for their servers to respond to all requests. Also, be sure to obey the robots.txt requests when writing software.
    It is a way for site owners to choose that sites they don’t want in search results, so please respect their wishes.

    Cheers,

    • Damien Boisvert (AlphaGameDeveloper)
  • BulletBoard is online!

    Hey-

    I just set up a school forum for my high school. The purpose of this was to see what it would be like if high-schoolers were given a mostly unmoderated, minimal-rules forum for them to trash on. Now, it's finally online and ready to be tortured to lengths the software (and server) most likely were not meant to be pushed.

    I can't wait! (nervous laughter)

    (more…)
  • YouTube: OH YEAH, THIS IS HAPPENING!

    As the great philosopher Sonic The Hedgehog once said, "Oh, yeah! This is happening!"

    MattKC, LEGO Island decomp #1
    (more…)
  • Site growth (Thank you!)

    Hey!

    We have reached a large milestone from Google Search (Site Kit). I want to thank all of you for how much this site has grown ever since I started it in Febuary as just a wannabe hobby project. I cannot thank all of you enough for how much support I have recieved for this site since I started it. (more…)

  • Jekyll, the New Way to Website?

    Static web pages — We know them, we love them. (Most of us.). If you have used GitHub pages, some file server like the ones at universities, you've (most likely) used one. (more…)

  • The data behind Minecraft servers!

    Hey-

    I created an "extension" for my Discord bot, that constantly (~5 minutes) pings Minecraft servers, and logs their response (more…)