Skip to content

jacktreg/wire-bender

Repository files navigation

WireBender

Set up paper.js:

  • cd into /WireBender or whatever you named your top level project directory
  • If you don't have node.js and NPM installed, visit http://blog.teamtreehouse.com/install-node-js-npm-mac to get those set up.
  • Once you have node.js and NPM installed, type npm install paper
  • paper.js make Cross-Origin requests, so the scripts can't run properly unless you run the project on a local server. I've found this one incredibly simple to set up and use https://www.npmjs.com/package/http-server
  • However you decide to serve the code, run the server!
  • You should be able to draw now! Try visiting localhost:[your_port]/drawing_form.html to see if it works properly.

Welcome to your project!

Every new Particle project is composed of 3 important elements that you'll see have been created in your project directory for WireBender.

/src folder:

This is the source folder that contains the firmware files for your project. It should not be renamed. Anything that is in this folder when you compile your project will be sent to our compile service and compiled into a firmware binary for the Particle device that you have targeted.

If your application contains multiple files, they should all be included in the src folder. If your firmware depends on Particle libraries, those dependencies are specified in the project.properties file referenced below.

.ino file:

This file is the firmware that will run as the primary application on your Particle device. It contains a setup() and loop() function, and can be written in Wiring or C/C++. For more information about using the Particle firmware API to create firmware for your Particle device, refer to the Firmware Reference section of the Particle documentation.

Adding additional files to your project

Projects with multiple sources

If you would like add additional files to your application, they should be added to the /src folder. All files in the /src folder will be sent to the Particle Cloud to produce a compiled binary.

Projects with external libraries

If your project includes a library that has not been registered in the Particle libraries system, you should create a new folder named /lib/<libraryname>/src under /<project dir> and add the .h and .cpp files for your library there. All contents of the /lib folder and subfolders will also be sent to the Cloud for compilation.

Compiling your project

When you're ready to compile your project, make sure you have the correct Particle device target selected and run particle compile <platform> in the CLI or click the Compile button in the Desktop IDE. The following files in your project folder will be sent to the compile service:

  • Everything in the /src folder, including your .ino application file
  • The project.properties file for your project
  • Any libraries stored under lib/<libraryname>/src

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published