I am doing a project for my school where we have a automated fishhooking mechanism. My job in this project is to use the Particle Electron to send an SMS message whenever a fish is hooked. We are using a loadcell amplifier to measure tension on the fishing line. Basically, I want the Electron to notify the user with an SMS message telling them that a fish has been hooked when the loadcell amplifier reads a certain force. I have made a Twilio account and set up the webhook on the particle IDE.
Here is the code I got off an example:
int sendMessage(String command);
void setup()
{
Particle.function("sendMessage", sendMessage);
}
int sendMessage(String command)
{
Particle.publish("twilio", "Your fish has been hooked! This is a message sent from your Particle device!", 60, PRIVATE);
}
Any advice on how I should go about doing this?