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
Arduino
  • Products
  • More
Arduino
Blog BYOB Party #7 - Mrs YUN gets chatty with iot.eclipse.org and NRF24L01
  • Blog
  • Forum
  • Documents
  • Quiz
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Arduino to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: Robert Peter Oakes
  • Date Created: 29 Dec 2014 10:55 AM Date Created
  • Views 1441 views
  • Likes 3 likes
  • Comments 7 comments
  • iot_holidaylights
  • byob_party
Related
Recommended

BYOB Party #7 - Mrs YUN gets chatty with iot.eclipse.org and NRF24L01

Robert Peter Oakes
Robert Peter Oakes
29 Dec 2014

link back to primary post BYOB Party #1, "Bring you own Bulbs" - The Internet of Holiday Lights

 

In this episode I will demonstrate and provide all the code used to allow a browser / smartphone / tablet to adjust the colour of a light strip that is connected via an NRF24L01 2.5Ghz wireless link

 

In a previous episode I showed how to get Mosquitto server, pub and sub clients loaded into the YUN and how to use them

 

This post is extending on Benjamin Cabé's excellent demonstration and after finding all the scripts and getting the page hosted by the YUN itself I have a working demonstration that looks like the following

 

image

 

I can enter colours from either a subscription to the wheel ("theBreadBoard_Strip") being hosted at iot.elcipse.org or by entering colour selections directly at the YUN or the UNO via their serial terminals

 

Pay attention to case as the subscriptions are case sensitive

 

any changes via the wheel is almost instantly relayed to the UNO and subsequently displayed on the light strip,

 

The UNO is supporting a command interpreter to allow direct commands to be sent to it via any configured input mechanism (Serial or NRF at this time)

The YUN is supporting a simpler command structure at this time and simply relays the commands it receives onto the UNO via the NRF radio

 

A point to note is the YUN does not support the standard output pins for SPI, namely the MISO, MOSI and SCK lines do not exist on pins 11, 12, 13 and are only accessible via the programming header and the Infineon Shield needs stacking headers if your to add additional IO devices like a NRF24L01

 

Once all the pins where sorted out it was simply a matter of finding all the additional libraries for the web page to operate, the basic functionality required for talking to iot.elcipse.org of course comes from the PAHO js libraries but the colour wheel , Raphael and the boostrap all had to be found

 

Bootstrap · The world's most popular mobile-first and responsive front-end framework.

Raphaël—JavaScript Library

Color Wheel Demo

 

on the YUN you need to create a folder and sub folder in the root of a micro SD card "/arduino/www", once loaded into the YUN it immediately shows up at this location under the LINUX "/mnt/sda1/arduino/www" and a simpler path "/www/sd", from the home network it can be accessed as "http://arduino.local/sd/", it will automatically serve index.html


I have zipped up the SD card structure and attached for you to use


also the modified sketches for the YUN and the UNO with MQTT support and NRF24L01, there not cleaned up yet but they all work


I will be cleaning up the sketches as I add more functionality etc, I am getting close to full ram usage so it is essential before I continue much further


here is a quick video to show how it functions,

You don't have permission to edit metadata of this video.
Edit media
x
image
Upload Preview
image



Attachments:
XmasLight.zip
arduino.zip
  • Sign in to reply

Top Comments

  • Robert Peter Oakes
    Robert Peter Oakes over 10 years ago in reply to kartben +1
    that may be true in some cases and while I do have access to hosting pages on the net, not everyone does or would want to, the deployment of the page really is immaterial in the scheme of things, the more…
  • jdlui
    jdlui over 8 years ago +1
    Peter, Thanks again for helping me dive into this world of Arduino and embedded programming back in 2014! Doing my masters over in Vancouver right now and I'm still coming back to these posts and learning…
  • Robert Peter Oakes
    Robert Peter Oakes over 8 years ago in reply to jdlui +1
    You're more than welcome and if you want to directly chat you can email me peter@thebreadboard.ca and lets not forget my YouTube channel http://www.youtube.com/thebreadboardca
  • Robert Peter Oakes
    Robert Peter Oakes over 8 years ago in reply to jdlui

    You're more than welcome and if you want to directly chat you can email me peter@thebreadboard.ca and lets not forget my YouTube channel  http://www.youtube.com/thebreadboardca

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • jdlui
    jdlui over 8 years ago

    Peter,

    Thanks again for helping me dive into this world of Arduino and embedded programming back in 2014! Doing my masters over in Vancouver right now and I'm still coming back to these posts and learning more things image

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • DAB
    DAB over 10 years ago in reply to Robert Peter Oakes

    No I was just curious.

     

    If I can get my head clear I can setup a test rig to asses the spectral purity control of the LEDs.

    If I can get good color mixing, then there are some really cool things I can do playing with the light on various materials.

     

    Thanks

    DAB

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • Robert Peter Oakes
    Robert Peter Oakes over 10 years ago in reply to DAB

    no measurements done as I don't have a light meter but the colour wheel does output 24 bit colour as RGB 255 levels each, the colours are a bit off when shown on a LED strip like the one in the video, probably because there a constant voltage strip rather than constant current so the infineon is a bit off with the balance, nothing that given time and effort could not be compensated for in software though

     

    Is there anything I can test for you, just provide some details and i can give it a go

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • Robert Peter Oakes
    Robert Peter Oakes over 10 years ago in reply to kartben

    that may be true in some cases and while I do have access to hosting pages on the net, not everyone does or would want to, the deployment of the page really is immaterial in the scheme of things, the more important part of the post in my opinion is the collecting and re-distribution of the subscription data via secondary radio links for in house connectivity, this is far cheaper than trying to have WIFI on everything and also allows for the author to add a level of security if desired at a single point rather than every node. Only the one node is exposed to the internet and that does not directly control the hardware

     

    Atleast that my story and im sticking to it image

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
>
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