Arduino GSM Shield
Arduino Uno + GSM Shield upload data to Hosted MYSQL database
Topic: Arduino Uno + GSM Shield upload data to Hosted MYSQL database
(Read 20956 times)
Re: Arduino Uno + GSM Shield upload data to Hosted MYSQL database
May 25, 2016, 10:39 am
I see this post is old - but I looked into your code and - it does not make sense, you can not use this code. You can't simply send a SQL query to a webserver on port 80. Your question has allready been answered - make a HTTP GET request. You wll have your value in a variable in the PHP script then. Let the PHP handle the insert into MYSQL. Of course you can talk to MYSQL directly, too - but as mentioned in the docs, it's possible the GSM provider will block such connections. The HTTP GET / PHP solution is the most practical I can think of.
Also the IP-Addresses you can not use them .... they will not be routed in the internet (192.168.xx.xx). But I recall you connect via a server name.
And I also wonder - SyamsulHasri - I mean this is one of the first infos when you look at the GSM shield pages. It is all documented. YES and NOT.