Go Down

Topic: How to send commands from Android app to Arduino And vice versa (Read 355 times) previous topic - next topic

Kernel

Hi all

I'm new to Arduino, I want to know the possible ways to send commands from Android app to Arduino And vice versa


I mean how to control the Arduino using two different networks


and if you have any tutorials or article that will help I will be appreciated

Robin2

You have not told us how you want to communicate between the Android device and the Arduino - WiFi or Bluetooth?

If using Bluetooth then for receiving data in the Arduino have a look at Serial Input Basics - simple reliable ways to receive data.

...R
Two or three hours spent thinking and reading documentation solves most programming problems.

Kernel

You have not told us how you want to communicate between the Android device and the Arduino - WiFi or Bluetooth?

If using Bluetooth then for receiving data in the Arduino have a look at Serial Input Basics - simple reliable ways to receive data.

...R
Thanks Robin for your replay

I meant to control the arduino using Android by WiFi

but is there a way to send commands but with different networks ?

for example if the android phone connect to network 1 and  arduino connect to network 2
is that possible?

Robin2

I don't know enough about WiFi networks to offer advice.

...R
Two or three hours spent thinking and reading documentation solves most programming problems.

srnet

but is there a way to send commands but with different networks ?
It may be possible, or maybe not.

It depends on the networks, their routers and firewalls.

If your question was can you expect to always be able to connect two devices in the way you describe across any two networks then the answer is no. 
$50SAT is now Silent (but probably still running)
http://www.50dollarsat.info/
http://www.loratracker.uk/

Nick_Pyner

You need to be a lot more forthcoming about what you really want to do. At the moment it is just vague hypotheses for a result that is probably nonsense.

You can control Arduino by a raft of different means - wireless, wired, bluetooth, Ethernet, WiFi, phone, internet. anything you can think of, including smoke signals, and yes two different ones - at the same time even.

Kernel

You need to be a lot more forthcoming about what you really want to do. At the moment it is just vague hypotheses for a result that is probably nonsense.

You can control Arduino by a raft of different means - wireless, wired, bluetooth, Ethernet, WiFi, phone, internet. anything you can think of, including smoke signals, and yes two different ones - at the same time even.
the idea is that I want to turn On/Off light bulb using the android app not just light bulb a lot of device (Home AUTOMATION )

so I saw some projects doing that using Bluetooth , WiFi shield but all of these solutions you have to be in close range in Bluetooth shield or connect to same network in WiFi shield


Thank you

Robin2

or connect to same network in WiFi shield
What you can or can't do on a WiFi network has little or nothing to do with the specifics of an Arduino or an Android device. I think you need to learn how things connect to the internet and there must be thousands of online web pages about that.

I reckon it is easier to learn how to do network things using a PC because most of the examples will be about using a PC. When you know how to do it with a PC it should be straightforward to transfer your knowledge to the Arduino / Android problem.

...R
Two or three hours spent thinking and reading documentation solves most programming problems.

noiasca

start reading here:
https://github.com/arendst/Sonoff-Tasmota/wiki

you will find prebuild hardware, flash software of the community, and you will be able to switch on/off something with your smarthphone.

One day, when you are experienced enough, you can write your own software (even with the Arduino IDE).
DE: Wie man Fragen postet:
1. was hat man (Sketch und Hardware)
2. was SOLL es machen
3. was macht es: IST (Fehlverhalten, Fehlermeldungen, Serial.Output ...)
4. Eine Frage stellen bzw. erklären was man erwartet

Go Up