Monday, October 26, 2015

Sword for The Spider Ninja!



A new attraction is opening up at Winterground Fairlands! "The Adventures of the Spider Ninja"  It's an exciting attraction with Spider Ninjas, and various challenges and action and probably a lot of running around with swords.  This attraction required costuming to create something all new for the cast members.  Shown in the picture is Jasper with his uniform.  The ninja mask and spider outfit were created by Pam the Costumer specifically for Jasper's small frame.


The new swords were built using various corrugated cardboard products.

The blade was made by rubber-cementing three layers of cardboard together, with their "grain" going in different directions for strength.  The blade actually continues through the hilt and into the handle, much like a real metal sword.


The handle is just a piece of thick cardboard tubing originally from wrapping paper.  It has a smaller diameter and is stronger than paper towel tubing to accommodate the cast member's smaller hands.

The hilt was a paper towel tube, with a round hole on one side to accept the handle, and a rectangular hole on the other side to accept the top portion of the blade.



Once the blade is pushed through the hilt and into the handle, everything fit very snugly, and didn't need any additional adhesives... but just in case, and for extra strength, the hilt was loaded up with lots of hot glue, and additional glue was added around the joints from the outside.

A couple coats of plain 'ol black spray paint and then the fine detail work could be done.  Jasper added some spiders he made out of Perler beads and the sword was completed!

Monday, October 19, 2015

Major Blog Announcement!

Hi and welcome to the new readers!

Just to let you all know, this blog will be slightly changing over the upcoming months.  The focus will still be on projects that we're working on/have worked on... but for a new venue

!I've recently picked up and moved to Sklarsville, Maine and am working full time at the world famous Winterground Fairlands Park and Adventurefun Center!!!

The wonderful part of this whole thing is that being hired as the head of the "Funmagineering Gang", I am able to make posts about the various projects we're working on for the park and in our skunkworks in general. There may even be some great blue-sky projects we'll be able to share with you!

So sit back, and "Enjoy the Adventurefun!"TM

Tuesday, October 13, 2015

Nintendo DS Lite case mod



Many years ago, I bought a white Nintendo DS Lite.  I loved the form factor, the look of it and the games I could play on it.  There were a lot of games for it, and for the GameBoy Advance which I already had which I'd love to play on it.

Over time, I've gotten a R4DS card so I could play homebrew (yeah, let's go with that) and use it as a kind of PDA type of thing. I also got an EZFlash V for the same reasons. For homebrew. Because that's still a thing, right?  (The screenshot above shows the R4DS interface, which I've re-skinned to like AmigaDOS 1.3 because that's something I do.

Anyway, at some point, I got a completely transparent shell for it, which was really neat for a while.  It was a pain to move the guts over to that shell, but it looked neat for a while.  Then The upper screen failed and the touch scanner failed on the bottom.  So I replaced those.  Then the right shoulder button failed, so I replaced that... which never really worked well, as the button broke off of the main board. There just wasn't enough structure there to support it.

Fast forward a few years, and I picked up a European black DS Lite in a trade for some old GBA stuff I didn't want anymore.  That one worked GREAT, except that the screen hinge was completely destroyed.  I used that for a while, but ended up shelving it.

For a while I've been meaning to take the best parts of all of this and put together one fully functional DS Lite.


I had planned to take the top screen from the black unit, but the ribbon cable broke while I was removing it from that unit.


What I ended up with was this:
  • Case enclosures - White
  • Top and shoulder buttons, switch cover plastics - Black
  • Upper Screen - White (replacement, colors aren't perfect on it, but it's good)
  • Lower Screen - Black
  • Motherboard - Black
  • Battery - Black
  • Wifi Antenna - Black (The cable was broken on the white one)
  • Rubber feet, screw covers - Black
  • Stylus - White (Black one is on order)
I think the final form here is pretty sharp.  Best of all, it's fully functional again! Yay!

Monday, October 5, 2015

Arduino Ethernet Library Modification

I was recently working on a piece of test/demo code running on an Arduino that talked through a Seeed Studio Ethernet shield.  The standard Ethernet library will not acknowledge a connection back to the host code until it receives something from the client.  For most things, this works out just fine (HTTP, chat servers, etc) but in some cases, like for RFB/VNC servers, it must first send out something itself to the client.  The as-shipped library does not allow for this, so it required a minor hack to the library code to make this option available.

in (Libraries)/Ethernet/src/EthernetServer.cpp, we can see the following code:
  01 EthernetClient EthernetServer::available()
  02 {
  03   accept();
  04   for (int sock = 0; sock < MAX_SOCK_NUM; sock++) {
  05     EthernetClient client(sock);
  06     if (EthernetClass::_server_port[sock] == _port) {
  07       uint8_t s = client.status();
  08       if (s == SnSR::ESTABLISHED || s == SnSR::CLOSE_WAIT) {
  09         if (client.available()) {
  10         return client;
  11         }
  12       }
  13     }
  14   }
  15   return EthernetClient(MAX_SOCK_NUM);
  16 }

As you can see, it checks to see if there is a connection established (line 08), then it checks to see if there's any content available from the client (bolded line 09), and only then will it return the handle to the newly connected client. This will be called in your Arduino code like this (from the WebServer example, packed with the Ethernet library)
void loop() {
  // listen for incoming clients
  EthernetClient client = server.available();
  if (client) {
    Serial.println("new client");
    // do stuff here...
    client.stop();
    Serial.println("client disconnected");
  }
}

This loop will only make and break connections if the client is actually connected AND it has data available. For most servers, this is sufficient.  However, if you want to allow for clients that connect and then just listen, you need to do the following...

In EthernetServer.cpp, create a copy of the ::available() method, eliminating lines 9 and 11 above. I call this function ::connectionEstablished(), plopped right into the EthernetServer.cpp file, just after the ::available() method, and it is implemented as follows:

EthernetClient EthernetServer::connectionEstablished()
{
  accept();
  for (int sock = 0; sock < MAX_SOCK_NUM; sock++) {
    EthernetClient client(sock);
    if (EthernetClass::_server_port[sock] == _port) {
      uint8_t s = client.status();
      if (s == SnSR::ESTABLISHED || s == SnSR::CLOSE_WAIT) {
        // "if" statement removed
        return client;
      }
    }
  }
  return EthernetClient(MAX_SOCK_NUM);
}

Next, you need to add the method to the header file, EthernetServer.h, as seen in this snippet
class EthernetServer :
  public Server {
    private: 
    uint16_t _port;
    void accept();
  public: 
    EthernetServer(uint16_t); 
    EthernetClient connectionEstablished();
    EthernetClient available();
    virtual void begin();
    virtual size_t write(uint8_t);
    virtual size_t write(const uint8_t *buf, size_t size);
    using Print::write;
};


Now, you can call this new method like this:
void loop() {
  // listen for incoming clients
  EthernetClient client = server.connectionEstablished();
  if (client) {
    Serial.println("new client has connected");
    // do stuff here...
    client.println( "Hello, goodbye!" ); 
    client.stop();
    Serial.println("client disconnected");
  }
}