I am new to arduino and i need your help
I want to use gsm and gsps with arduino and a shock circuit all together... how can use them all at the same time using a single relay and want to run them all by pressing a single button
You need to provide more information about what you want to do, and make sure to deal with these points
- What is "gsps" and what is "a shock circuit".
- What is the role of the relay?
- What exactly do you want to happen when you press the button.
If you have a circuit diagram please post it. See this Simple Image Guide
The only advice I can give you is to work on one thing at a time before you put everything together.
Work on your inputs & outputs separately. i.e. Test your button, GPS, and GSM separately. Use the serial monitor to "see" what your inputs are doing (look at the Analog Read Serial Example).
I'm guessing that you're also new to programming and electronics? This a BIG project for a beginner!
If you're new to programming - The two most important concepts in programming are conditional execution (if statements, etc.) and loops (doing something over-and-over, usually until some condition is reached).
And again... One LITTLE thing at a time! Don't try to write the whole program at once. That's the biggest mistake beginners make. Start with something like the Blink Example and add one or two lines of code at a time, test-compiling and test-running (and debugging) as you go... This is not as easy as it seems ... The compiler has to see a "complete program" (i.e. If you chip-off the last-half of a program it won't compile.) And, you need a way to test the program and "see" if it's doing what you expect... i.e. Activate an LED or relay, and send messages to the serial monitor, etc.
Maybe go check this out. Or google your description, “gsm and gps with arduino and a shock circuit”, with the ‘gsps’ typo corrected. It’s best to come here once you have the device you want to build already in mind.
ps, I’m just trying this kind of answer as an experiment. Please don’t hate me.