Skip to content

Mast3rChief/QStation_Demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

#Q Station C Demo

This is a litte Belleds Q Station demo program written in C. It connects your Belleds Q Station with your Adafruit.io interface. You can turn one of your bulbs on / off (for now). You need to add an on / off switch wich is connected to a feed named "qstation" in your Adafruit.io interaface.

##Instructions

Build System

  1. Install build depencies (See https://wiki.openwrt.org/doc/howto/buildroot.exigence for more information)

    sudo apt-get install git-core subversion mercurial build-essential libssl-dev libncurses5-dev unzip gawk
  2. Clone OpenWRT from github (Do the following things as non root user!)

    git clone -b attitude_adjustment https://github.com/openwrt/openwrt.git
  3. Enter OpenWRT dir

    cd openwrt
  4. Update and install packages

    ./scripts/feeds update -a
    ./scripts/feeds install -a
  5. Check prerequisites and prepare toolchain buidling (prereq will show you missing depencies)

    make defconfig
    make prereq
    make menuconfig
  6. Now check the system and build toolchain options in menuconfig

    Target System: Atheros (AR7xx/AR9xx)
    [*] Build the OpenWRT based Toolchain
    
  7. Build the toolchain (this will take up to three hours!)

    make V=99
  8. Back to your user dir

    cd ..
  9. Clone the source code from github with git

    git clone https://github.com/Mast3rChief/QStation_Demo.git
  10. Enter QStation Demo dir

    cd QStation_Demo
  11. Compile everything

    make main
  12. Check file information of the compilied main program

    file main
  13. The output should look something like this:

    main: ELF 32-bit MSB executable, MIPS, MIPS32 rel2 version 1...

Belleds Q Station

  1. Copy the program to your QStation and create the config.ini with your Adafruit.io API key. For example download it from your webserver. We use the tmp dir for testing only!

    cd /tmp
    mkdir QStation_Demo
    cd QStation_Demo
    scp user@ip:/home/user/QStation_Demo/* .
    vim config.ini
    # press i for insert mode
    # paste your AIO API Key (No spaces)
    # press escape and :wq to exit vim
  2. Run the program and have fun

    ./main MD1AC44200003128

##Screenshots

Screenshot of the running program

##Credits

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published