element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Merry Boxes & LEDs
  • Challenges & Projects
  • Project14
  • Merry Boxes & LEDs
  • More
  • Cancel
Merry Boxes & LEDs
Blog Trees! one with motion sickness...
  • Blog
  • Forum
  • Documents
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Merry Boxes & LEDs to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: ntewinkel
  • Date Created: 5 Jan 2019 6:45 AM Date Created
  • Views 1516 views
  • Likes 7 likes
  • Comments 6 comments
  • wifi
  • merryboxesledsch
  • xmas
  • motion
  • arduino
  • wemos
  • sensor
Related
Recommended

Trees! one with motion sickness...

ntewinkel
ntewinkel
5 Jan 2019

I'm getting closer!

 

I added some pull-down resistors for the motion sensors, and made a few tweaks to the software (there was too much of a wait time between sensor reads, for one; and I had the motion sensing levels backwards).

 

Tree number 2 seems to be working properly, detecting motion at the right time, sending and receiving messages, and lighting up all the right things. Hooray!

 

I thought I had it in the bag, because Tree 1 is just a copy really, with the numbers reversed.

 

But sadly, Tree 1 is rather trigger happy constantly sensing motion, even when I don't have the motion sensor disconnected at all. sigh.

So that'll need more work. I might try switching to a different GPIO, just in case I did something to this one. First step I'll probably switch the dev board to the one from the working tree, to rule out hardware issues with the tree wiring.

 

So close! so close!

 

Here is one of the trees:

image

 

Here are the two trees, both wired up to a Wemos, ready to be programmed:

image

 

And here is a closeup of the wires for one of them. I don't recall which is which, sorry:

image

 

It would have been much neater to have used perfboard, I think. For some reason the number of required connections expanded as I went on image

ps, you might have noticed that I bent the header pins on the dev boards to 90 degrees before I soldered them on, to keep the profile of the wemos board lower. Kind of like the old "pancake" engine in the Volkswagen Type-3s of the 60s and 70s. Remember those? I restored one circa 2000, I'm not THAT old to remember the 60s image

 

Here is a closeup of the green wire to the top RGB flasher LED:

image

The wire runs straight down the center of the tree and to the transistor, controlled by the Wemos board. I separated this from the other tree LEDs because I wanted something local to signal that motion had been detected. It is also timed so that it stays on as long as the remote tree is on.

Note that the transistors are on the gnd side of the load, which is why the green wire is soldered to the - side of the LED. I think it would have been fine, and much easier, to have skipped the transistor for the tree-top LED and just powered it straight from the GPIO pin.

 

This is how I wired the main tree. Basically the power to the tree is now supplied by the Wemos board. I did confuse myself for both boards at different times when I forgot to turn on the power switch. sigh. This was the easiest way to power it though - I suppose I could have wired it directly to the + and - at the base of the tree. I get a little reckless with the soldering iron at times - notice the melty bit on the J1 power connector? image

image

 

I keep thinking there might have been a nicer way to wire it, maybe having the main-tree transistor glued to the tree base plate and just running power and signal to it from the micro controller board.

 

So... next steps...

For one, I need to figure out why the one tree is so trigger happy. I might try making it "tree 2" to make sure it's not a silly software bug related to the tree numbering.

For the tree that's working, I'll paint on some finger nail polish to insulate the solder joints and make it look a little prettier. I hesitate to do that for the one that's not working before I figure out why.

I also need to figure out some way to tidy up the final package. My wife suggested adding a tree skirt image  she's brilliant. To hold the wires and such I might just use some standoffs and cardboard under it. Or maybe if I can find some super thin plywood.

 

I'm starting to think that instead of motion sensors I should have just given each of them a big button for the user to press to show the other side they are thinking of them!

 

Cheers,

-Nico

 

Previous posts:

Connected Christmas Trees

Assembling the Trees

Finally! Two Trees Assembled

Two Trees by a Tree

Connecting the Tree to the Internet

Motion Sensor on Wemos

 

Next posts:

Motion Sensor Issues, continued

The Connected Trees are Working!

Merry Boxes - A Project Within a Project

Connected Christmas Trees - Finished!

  • Sign in to reply

Top Comments

  • mcb1
    mcb1 over 6 years ago +4
    Kind of like the old "pancake" engine in the Volkswagen I'm sure Mr Porch would prefer the term 'horizontally opposed' just like the BMW bikes and early Subaru cars. Or maybe if I can find some super thin…
  • ntewinkel
    ntewinkel over 6 years ago in reply to mcb1 +3
    mcb1 wrote: Have I missed the schematic for your two transistors? From the code it looks like one drives the top LED and the other turns on the tree?. I haven't posted a schematic (yet, maybe?). I think…
  • ntewinkel
    ntewinkel over 6 years ago in reply to genebren +2
    Thanks Gene! Seems like this whole project has been full of hiccups and mishaps! All part of the challenge though, isn't it? -Nico
Parents
  • mcb1
    mcb1 over 6 years ago

    Kind of like the old "pancake" engine in the Volkswagen

    I'm sure Mr Porch would prefer the term 'horizontally opposed' just like the BMW bikes and early Subaru cars. image

     

    Or maybe if I can find some super thin plywood.

    I'm fairly sure someone has a CNC Router that could whip up a special piece ...

     

    Have I missed the schematic for your two transistors?

    From the code it looks like one drives the top LED and the other turns on the tree?.

     

    Mark

    • Cancel
    • Vote Up +4 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • Jan Cumps
    Jan Cumps over 6 years ago in reply to mcb1

    mcb1  wrote:

     

    Kind of like the old "pancake" engine in the Volkswagen

    I'm sure Mr Porch would prefer the term 'horizontally opposed' just like the BMW bikes and early Subaru cars. image ...

     

    Mark

    Boxer motor?

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • More
    • Cancel
Comment
  • Jan Cumps
    Jan Cumps over 6 years ago in reply to mcb1

    mcb1  wrote:

     

    Kind of like the old "pancake" engine in the Volkswagen

    I'm sure Mr Porch would prefer the term 'horizontally opposed' just like the BMW bikes and early Subaru cars. image ...

     

    Mark

    Boxer motor?

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • More
    • Cancel
Children
No Data
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube