How do I start? - Total newbie

I have some programming experience in Java, Delphi and Python(and many many years ago C).
A friend brought me some Particle Electrons and asked me to write the code for it. I’ve never worked with Particle products or anything similar. Could someone point me in the direction of tutorials to learn how to connect and program the electron. Where should I start? In the end I need to measure water levels in soil and send notifications to a mobile phone.

I am willing to learn just need a roadmap of how to get to my destination.

1 Like

Hey there, and welcome to the community.

There are many projects around Hackster, for instance.
This is the search I ran.

These are two that use photon, and the code might work as is for an Electron:

There are a bunch of others if you want to read a bit.
In case of trouble, just keep asking.
Good luck.


Hello and welcome!

I second Gus’s suggestion to take a look at projects in Hackster- in my experience the best way to approach your first project is to look at what other’s have done and learn from their example. Both projects Gus linked would be good reference points for you.

Let’s break this project down into a few steps.

For your materials you’ll need a soil moisture sensor, some jumper wires, a resistor and a breadboard. And the Electron. Have you set up your electron yet? If not you can set it up here, with this docs tool. OR you can beta test a new setup tool and I can send you a free device as thanks.

You’ll also need to pick an IDE to work with. There are two options here- the web IDE or Particle Workbench, which is our VS Code extension. I’m partial to Workbench and suggest it if you already use VS Code. If not, the web IDE is a good option too.

Then you’ll need to familiarize yourself with the general code structure. Particle devices(and most microcontrollers) are coded with Wiring which is basically an offshoot of C but with a bunch of cool libraries. The main thing to know is that each project must contain a setup function and a loop function. If you use the web IDE there are some great code examples there that explain it further.

Next you’ll need to connect the soil moisture sensor and read the data. For that I’d refer to one of the tutorials Gus linked, as both are great examples of this.

Lastly you’ll need to send that data in a message. I would use webhooks for this and connect with either Zapier (paid but fast) or IFTTT (free but less fast) to do this since it greatly lowers the amount of code you’d need to write. Both pieces of documentation linked there are pretty thorough.

Have fun with your first project! If you have any questions or issues please reach out to me.


Oh wait! this morning I remembered an article that blew my mind years ago, YOU HAVE TO READ IT:

We have to thank @jvanier for posting it. :mechanical_arm:


Thanks this is exactly what I was looking for!!

1 Like