Home
IEM製品版3Gシールドの概要
Contents
1. b 27 Copyright c 2012 3G alliance All Rights Reserved TABrain 93922 2 onSMSReceived SMS handler SIBI 0 0 Arduino D3 INT0 LOW handler handler 3G void ledOn void digitalWrite LED PIN HIGH ledStatus HIGH void setup if a3gs start 0 amp amp a3gs begin 0 1 a3gs onSMSReceived ledOn b 28 Copyright c 2012 3G allianc
2. 9 V1 3A USB 12 12 3G Facebook gt J Vin GND 2 0 NR IEEE ed P y DIGITAL PWM E X USBESJRIa ERES YY axem ARDUINO m rn 7 lt c UB
3. gO T EN A e TA Brain int getServices int amp status status OUT a3gsSRV_NO 20 a3gsSRV PS 21 a3gsSRV CS 2 SMS a3gsSRV BOTH 23 SMS DEM 0 status int status SIM if a3gs getServices status 0 Serial printin status b 37 Copyright c 2012 3G alliance All Rights Reserved TABrain EE 5 getRsSr Int getRSSI int amp rssi 3G RSSI rssi OUT dBm lt 1 128 gt 0 0 rssi
4. if a3gs getTime date time 0 RED Serial print Serial println time 1980 1 5 16 00 00 16 39 Copyright c 2012 3G alliance AllRightsReserved TABrain aga 5 IBN COTUSBEDBISA getTIME2 int getTime2 uint32 t amp seconds 1970 1 1 UNIX seconds OUT nA 0 0 date time dim getTime
5. 8 Arduino a3gs gt PN A AETR Et Web HTTP GET POST TCP IP connect disconnect read write GPS GPS Standalone AGPS SMS send receive check onReceived APN IMEI LED 3G a3gs Arduino SoftwareSerial INT0 0 SMS 3G 3 Copyright c 2012 3G alliance e All Rights Reserved TABrain 9 1 1 2 3G GPS TEM 3G IS ME 3G W CDMA Brew 2100 1900 850MHz gw3g Brew lt
6. close 46 BEEN V UO Copyright c 2012 3G alliance All Rights Reserved TABrain aga 6 TCP TIP write e 1 int write uint8 t c TCP 1 c 1 30 close 1 0 close P 47 Copyright c 2012 3G alliance All Rights Reserved TABrain aga e 2 int write const char str TCP
7. 1 end TCP TCP C ce 44 Copyright c 2012 3G alliance All Rights Reserved TABrain aga 6 TCP TIP read e 1 uint8 t read void 1 0 close 1 30 1 char svr www googl co jp void hadleResponse void 1 if a3gs connectTCP svr 80 0 1 char c GET Request for google site while c a3gs read eof a3gs write GET HTTP 1 0 n c a3gs write HOST Y a3gs write svr a3gs write n n handleResponse j else 1 Seria
8. 3G X Arduino GSM GPRS http arduino tweet appspot com Q Copyright c 2012 3G alliance All Rights Reserved TABrain 93972 2 a3gs OAR D e e X Arduino GSM GPRS l 9 Copyright c 2012 3G alliance All Rig hts Reserved TA Brain 2 a3gs 3G a3gs h GET POST M a3gsMAX HOST LENGTH a3gsMAX_DATA_LENGTH a3gsMAX PROFILE NUMBER 1 ATmega328 32U Uno
9. SIM APN IEM SIM a3gs arduino 3G shield Arduino 3g APN Access Point Name MNVO GPS Global Positioning System 2 Km GPS gw3g GateWay to 3G IEM BrewMP IDE IEM TInternet of Everything Module IMEI I
10. 2 IEM gw3g 3G ON end dm end SoftwareSerial begin setBaudrate if a3gs begin 0 9600 0 Seria bam O 2257 16 Copyright c 2012 3G alliance All Rights Reserved TABrain 93922 end int end void HE S eo O OOOO 0 0 SoftwareSerial end
11. gt 17 Copyright c 2012 3G alliance AOTS Reserved TABrain 23 S 3 int restart char pin 3G pin 0 0 IEM 10 IEM 40 end begin if a3gs restart 0 Serial println Restarting a3gs end if a3gs begin 0 Serial println I m OK else Serial printIn Restart Failed b 18 Copyright c 2012 3G alliance All Rights Reserved TABrain 93922 1 start int start char pin 3G ON pin 0 ON 0 ON
12. read write Copyright c 2012 3G alliance All Rights Reserved TA Brain 6 TCP T1IP connectTcp int connectTCP const char server int port EXEUJEU JV amp W ESNAULT TCPIT ZZ 3 lix d D server IP port 0 0 1 30 server IP x x x x char svr www googl co jp if a3gs connectTCP svr 80 0 4 GET Request for google site a3gs write GET HTTP 1 0 n a3gs write HOST a3gs write svr a3gs write n n Get resopnse else 1 Serial println Error can t connect b 43 Copyright c 2012 3G alliance All Rights Reserved TABrain ags 6 TCP TIP disconnectTCP int disconnectTCP void TCP 0 0
13. http POST port 80 result OUT resultlength IN OUT result 0 POST pO 8 0 POST b 31 Copyright c 2012 3G alliance All Rights Reserved TABrain ags 3 Web httpPOST int httpPOST const char server uint16 t port const char path const char header const char body char result int resultlength header Content Length body server IP 1 lt 20 resultlength cT result 0 XFI Rd 9 JWVDW CAKCGE S S
14. MERCIER 3G SIM IIJ SIM IIJmio 1 serlal prin n Failed SIM m mom SIM Serial println Failed 3G TIIJmio void loop 4 72 Copyright c 2012 3G alliance All Rights Reserved TA Brain aga 13 blink led ino LED gt 3G LED1 ON OFF define INTERVAL 1000 Blink interval A3GS sample skech 13 setLED oid set zinclude lt SoftwareSerial h gt Vol up include a3gs h Serial begin 9600 delay 3000 Wait for Start Serial Monitor Serial println Ready retry Serial print Initializing if a3gs start 0 amp amp a3gs begin 0 Serial println Succeeded else 1 Serial println Failed Serial println Shutdown a3gs end a3gs shutdown delay 30000 goto retry Repeat Serial println Blinking void loop
15. 40 3G begin if a3gs start 0 amp amp a3gs begin 1 Serial println Succeeded else Serial printIn Restart Failed b 19 Copyright c 2012 3G alliance All Rights Reserved TABrain ags 1 shutdown int shutdown void 15 ON start 3G a3gs end a3gs shutdown b 20 Copyright c 2012 3G alliance All Rights Reserved TABrain aga getrMEr int getIMEI char imei 3G7 1IEM IMEI m imei IMEI a3gsIMEI SIZE 0 0 IMEI 3G
16. SIM setDefaultProfile b 50 Copyright c 2012 3G alliance All Rights Reserved TABrain 7 setDefaultProfile int setDefaultProfile int profileNum profileNum 1 a3gsMAX PROFILE NUMBER 0 0 IEM ROM OFF IEM 3G Ver 1 0 No 1 docomo mopera net No 2 II iijmio gt 51 Copyright c 2012 3G alliance
17. Arduino GSM GPRS e TCP IP v4 e Web e e 30 e read1 write connectTCP e TCP IP SIM e SIM 80 e 1 read write
18. Ready Aus IMEI 63 Copyright c 2012 3G alliance All Rights Reserved TABrain 2 get location Ino GPS A3GS sample sketch 5 getLocation Zinclude lt SoftwareSerial h gt include a3gs h void setuD Serial begin 9600 delay 3000 Wait for start serial monitor Serial printlIn Ready Serial print Initializing if a3gs start 0 amp amp a3gs begin 0 d Serial DrintlIn Succeeded It maybe takes several minutes char lat 15 Ing 15 if a3gs getLocation a39gsMPBASED lat Ing 0 1 Serial print OK Serial printtlat Serial print Serial printin Ing else Serial printIn I don t know this location else Serial println Failed Serial printIn Shutdown a3gs end a3gs shutdown void loop 3 GPS Ready E F E
19. str 0 1 0 close 1 30 close char svr www googl co jp if a3gs connectTCP svr 80 0 4 GET Request for google site a3gs write GET HTTP 1 0 n a3gs write HOST a3gs write svr a3gs write n n Get resopnse Copyright c 2012 3G alliance All Rights Reserved TABrain 93922 EM LSU Elisa o RR e 3 int write const uint8 t buffer size_t sz TCP buffer
20. 2038 X 2038 ISO 1970 1 1 C 32 2038 1 19 3 14 7 UTC int Copyright c 2012 3G alliance All Rights Reserved TABrain 993922 5 getVersion int getVersion char version 3G IEM gw3g version OUT 9 9 0 0 version begin 3G 41 Copyright c 2012 3G alliance All Rights Reserved TABrain aga 6 TCP 42
21. a3gsMAX_SMS_LENGTH encode a3gsCS_ ASCII 0 0 SMS SIM getServices a3gsSRV_CS a3gsSRV_BOTH SMS UNICODE Arduino UTF 8 UNICODE 16 If a3gs setBaudrate 9600 0 Serial printIn Baudrate was changed Serial printIn Please reset me now 25 Copyright c 2012 3G alliance All Rights Reserved TABrain 93922 2 availableSMS boolean availableSMS void SMS BR true SMS false SMS 3G
22. Copyright c 2012 3G alliance AL NOS Reserved TABrain 9327 4 GPS getLocation int getLocation int method char latitude char longitude method a3gsMPBASED a3gsMPASSISTED a3gsMPSTANDALONE latitude OUT 9 99999 longitude OUT 0 mom j 0 latitude longitude 3 AGPS 3G Ver1 0 Google b 35 Copyright c 2012 3G alliance All Rights Reserved TABrain 93922 S MNTONMNDSE annm 3G
23. 33 Copyright c 2012 3G alli ance All Rig htsReserved TABrain 93922 4 GPS gt IEM GPS 3G a3gsMPBASED GPS GPS 3G a3gsMPASSISTED 3G a3gsMPSTANDALONE 3 GPS 34 IIJmio 3G GPS a3gsMPSTANDALONE S1IM GPS
24. sz 1 0 close 2 0 1 30 close HUS OB char svr 192 168 1 1 uint8 t binaryData 4 0xO 0x1 0x2 0x3 if a3gs connectTCP svr 8080 0 4 a3gs write binaryData sizeof binaryData 49 Copyright c 2012 3G alliance All Rights Reserved TABrain 93922 7 gt
25. UART baudrate 2400 4800 79600 19200 38400 57600 0 0 3G 4800 bps IEM begin begin if a3gs setBaudrate 9600 0 Serial println Baudrate was changed Serial printIn Please reset me now 23 Copyright c 2012 3G alliance All Rights Reserv
26. POST Twitter TCP TCP GPS 3G gw3g _ Copyright c 2012 3G alliance All Rights Reserved 1 TABrain gs K vr 4E 2 tweet http arduino tweet appspot com A http arduino tweet appspot oom X f Tweet Library for Arduino x F E V A T H Google Web me Ka dw http twitter com oauth authorize osut JO X Tweet for Ardu y Twitter x um F ESE V A T H X Google Step 1 Get a token to post a message using OAuth Step 2 Add some Libraries to your Arduino IDE Authorize Arduino to use your accoun
27. gt 54 ERE CPP H drivers examples hardware java lib libraries reference tools 3o KB 78 6 KB 64 2 KB 72 _ Copyright c 2 2012 3G alliance All Rights Reserved TA Brain agi libraries d ColorLCDShield j EEPROM Ethernet di Firmata Ji LiquidCrystal Rte Pcf8563 SD Ji Servo i SoftwareSerial Ji SPI hi Stepper Wire a3gs zip X zip 2 a3gs zip V EE example a3gs cpp a3gs h keywords txt Yblink ledYXblink led ino p 73 Ycheck rssiXcheck rssi ino p 58 Ycheck serviceXcheck service ino p 59 Ycosm sampleYcosm sample ino p 60 YXget imeiYget imei ino p 63 YXget locationXget location ino p 64 Yget statusYget s
28. 59 Copyright c 2012 3G alliance All Rights Reserved TA Brain aga 3 cosm Sam1Dle inO f COSM ID PW ID Feed ID Key ID 3 LM618BIZ A0 GND A1 Vout A2 Vs LM618BIZ dh 3G mu UI bOTEUY 60 Copyright c 2012 3G alliance All Rights Reserved TABrain aga 3 cosm sample ino2 cosm sample ino Feed TID Key A3GS
29. P75 V IDE Arduino 1 0 1 1 check rssi ino Arduino 3G 3G check rssi ino A3GS sample sketch 1 getRSST Zinclude lt SoftwareSerial h gt include a3gs h void setuD 1 Serial begin 9600 delay 3000 Wait for Start Serial Monitor Serial printIn Ready Ready Initializing Succeeded RSSI 75 dBm Shutdown 75 Serial print Initializing if a3gs start 0 amp amp a3gs begin 0 1 Serial printIn Succeeded int rssi T Em if a3gs getRSSI rssi 0 rssi Serial print RSSI Serial print rssi Serial println dBm else Serial printin Failed Serial printlIn Shutdown a3gs end a3gs shutdown 0 void loop
30. 0 3G 3 G 125dBm 68dBm int rssi if a3gs getRSSI rssi 0 Serial DrintIn rssi b 38 Copyright c 2012 3G alliance All Rights Reserved TABrain aga S AIN C UNON GATIME int getTime char date char time Bier date OUT YYYY MM DD time OUT HH MM SS 0 0 date time 3G JST 24h
31. F WE V A T H x Goegle cosm com IL x cosm About Howitworks Support API Sea Q i gt w FA Connect to your world N temp last updated Sun 08 28 25 0900 o YOUR FEED ID HERE 3 min v vshowtiggers T Feed ID Feed Formats eator JSON XML CSV e Tags arduino test 2012 16 17 58 0900 Followers 0 V BATAL 96005 b 62 Copyright c 2012 3G alliance All Rights Reserved TA Brain 4 get imel Ino IEM Wm AK SRI E 5 HR i IEM ID IMEI get time ino A3GS sample sketch 4 getIMEI include lt SoftwareSerial h gt include a3gs h void setuD x Serial begin 9600 delay 3000 Wait for Start Serial Monitor Serial printIn Ready Serial print Initializing if a3gs start 0 amp amp a3gs begin 0 1 Serial println Succeeded char imei a3gsIMEI SIZE if a3gs getIMEI imei 0 Serial print IMEI IMEDBEAS ESSA Serial println imei else Serial println Failed Serial printin Shutdown a3gs end a3gs shutdown void loop
32. ON 40 OFF 15 setBaudrate 13 Copyright c 2012 3G alliance All Rights Reserved TABrain EE EOD EST EA getStatus int getStatus void ag Re A3GS ERROR A3GS IDLE A3GS READY A3GS TCPCONNECTEDCLIENT TCP int status status a3gs getStatus Serial print Status is switch status 1 c case A3GS ERROR Serial println ERROR break Status is IDLE case A3GS IDLE Serial println IDLE break case A3GS READY Serial println READY break case A3GS TCPCONNECTEDCLIENT Serial println TCPCONNECTEDCLIENT break default Serial println Unknown break gt 14 Copyright c 2012 3G alliance All Rights Reserved TABrain aga begin e 1 int begin char pin Din 0
33. IEM ID imei a3gsIMET_STIZE 16 char imei a3gsIMEI SIZE if a3gs begin 0 1 a3gs getIEI imei Serial printin imei IMEI IEM ID KAESE b 21 Copyright c 2012 3G alliance All Rights Reserved TABrain agio 1 setLEp int setLED boolean sw 3G LED1 sw ON TRUE OFF FALSE 0 0 LED1 LED 3G if aFlag 1 a3gs setL ED TRUE led1 status TRUE Serial println LED1 is turned on b 22 Copyright c 2012 3G alliance All Rights Reserved TABrain aga setBaudrate int setBaudrate int baudrate Arduino 3G
34. 1 TEM gw3g 3G ON end end SoftwareSerial begin if a3gs begin 0 Serial printIn Succeeded b 15 Copyright c 2012 3G alliance All Rights Reserved TABrain 93922 _begin e 2 int begin char pin uint32 t baudrate pin baudrate 1200 2400 4800 9600 19200 38400 57600 115200 O 1
35. D 24 Web D 29 GPS D 34 D 36 TCP IP p 42 D 50 3G a3gs R1 0 Arduino GSM GPRS 1 gt 1 3G 0000000000000 begn end retat 3G 0 0 00 0 000 Contro star 3G ON 0000000000000 Shutdown 3G OFF 000000000000 getIMEI IMEI setLED LED1I ONVOFF 0 0 X Arduino GSM GPRS IEM 3G ON OFF IMEI LED1 ON OFF UART
36. header body t TAB Ox09 r CR OxOd n NL OxOa xhh Xhh 16 hh 0xhh b 32 Copyright c 2012 3G alliance All Rights Reserved TABrain EE int tweet const char token const char msg Twitter token msg a3gsMAX_TWEET_LENGTH 0 E 0 tweet http arduino tweet appspot com DS
37. Arduino SRAM ATmega2560 1280 Mega ADK 2 read write a3gsMAX TWEET LENGTH gt Jr 10 Copyright c 2012 3G alliance All Rights Reserved TABrain 83222 3 DI gt InClude a3gs h void setuD x if a3gs start 0 3G ON j dJ a3gs if a3gs begin 0 r j 3G Copyright c 2012 3G alliance All Rights MT TAB ra i n 23 Ao 3 OU RO HE D 13
38. Tweet E SIM gt IEM Arduino Copyright c 2012 3G alliance All Rights Reserved 1 TABrain TY 3 a3gs a3gs Arduino IDE File sketch_auq02a arduino 1 0 1 EL elm m Ctrl N Ctrl O Hl 01 Basics m Ctrl W 02 Digital Ctr s 03 Analog Ctrl Shift S 04 Communication x Ctrl U 05 Control k Ctrl Shi U 06 Sensors Orghtip PSY EN Lh Ctrl P adds uf EN PM 08 USB Leonardo e Ctrl Comma ArduinoISP g Ctrl Q 3 It TTT A check rssi b
39. V A T H X Google 35 64153135 139 6036148 takamoto mig Play YouTube Gmail Google 3564153135 139 6036148 Le VEL SEE Dr 5 ARATE PRZE UFJ HH 5 TUER Wa o Google amp lae V N S V 1 O T m IE9 B IE9 M rx b 0 M Copyright c 2012 3G alliance All Rights Reserved TA Brain 6 get time Ino 1 IEM get time ino A3GS sample sketch 6 getTime Zinclude lt SoftwareSerial h gt zZinclude a3gs h void setup Serial begin 9600 delay 3000 Wait for Start Serial Monitor Serial printlIn Ready Serial print Initializing
40. j void loop 4 68 Copyright c 2012 3G alliance All Rights Reserved TABrain agg 10 tweet sample ino D tweet 3G Twitter X CdS tweet sample ino A3GS sample skech 10 tweet sample include SoftwareSerial h include a3gs h WM Cds char message 3 GShield Twect start Note can t tweet same message continuously const int AnaogSensor Pin 0 IC 0 8 X Twtter J ENDIS tweet sample ino void setup void loop 1 static uint16 t prevLx O0 Serial begin 9600 uintl6 t Ix analogRead AnaogSensor Pin delay 3000 Wait for Start Serial Monitor Serial print Ix Serial print lx Serial println Ready if Ix prevLx 1 Serial print Initializing sprintf message 3GShield Sensor Value 9od Ix if a3gs start 0 amp amp a3gs begin 0 d prevLx Ix Serial println Succeeded Serial print tweet requesting Serial print tweet requesting Serial print lx if a3gs tweet token message 0 Serial print Serial
41. Brew MP Profiles 3G UART Power Arduino UNO Leonardo Pro Mega Arduino E Arduino lt a3gs gt SoftwareSerial Arduino INTO TABrain TY UW N e IEM Internet of Everything Module p 06 a3gs D 07 D 11 I 3G Arduino GSM GPRS 1 IEM Internet of Everything Module gt 3G gt AnyDATA DTW400 W JATE TELEC Qualcomm QSC6240 gt 21mm x 22mm x 4 5mm 4 5g DTW400 W 100 DTW400 W UMTS _ 850 1900 2100 MHz EDGE GPRS GSM 850 900 1800 1900 MHz GPS Standalone GPS AGPS 6 Copyright c 2012 3G alliance All Rights Recarved TA Brain 2 g DN 2 a3gs 3
42. Colori CD5Shield check service EEPROM E Di mple a3 gs H F J Ethernet gt get imei Firmata E getlocation AU WT Liquidcrystal 6 gettme Rte_Pdes63 X gettm SD http get Servo E send sms SoftwareSerial i tweet_sample oe i m EPPP ETE Stepper Wire 56 Copyright c 2012 3G alliance All Rights Reserved TABrain check_rssi ino 3G 7 check_service ino SIM cosm sample ino get imei ino IEM get location ino get time ino 1 get time ino 2 http_get ino send_sms ino 10 tweet _sample ino tO CO Ov osi COO NU RW OO CO 11 tweet sample2 ino p 71 12 set defaultprofile ino p 72 13 blink_led ino LED P73 14 on_sms ino SMS P 74 15 sample_TCPIPino TCP IP
43. SMS 1 1 2 SMS char msgla3gsMAX_SMS_LENGTH 1 1 msn a3gsMAX MSN SIZE 1 void loop 1 if a3gs availablesMS 1 int msgLen sizeof msg int msnLen sizeof msn a3gs readSMS msg msgLen msn msnLen SMS delay 1000 b 26 Copyright c 2012 3G alliance All Rights Reserved TABrain agio 2 readSMS boolean readSMS char msg int msglength char number int nlength SMS msg OUT a3gsMAX_ SMS LENGTH msglength msg number OUT SMS nlength number a3gsMAX_MSN_LENGTH true false SMS SMS msg number 0 ASCII UNICODE sendSMS
44. aGshield Sensor Value aGshield Sensor Value aGshield Sensor Value b 71 Copyright c 2012 3G alliance All Rights Reserved TABrain gd 12 set defaultprofile ino SIM NTT 21 IIJ IIJmio 2 void setuD A3GS sample skech 12 setDefaultProfile and getDefaultProfile Serial begin 9600 delay 3000 Wait for Start Serial Monitor Serial printIn Ready include SoftwareSerial h include a3gs h Serial print Initializing if a3gs start 0 amp amp a3gs begin 0 lt Serial println Succeeded int no if a3gs getDefaultProfile amp no 0 1 Serial print Default Profile Number is Serial printin no Po Bs else no 1 if a3gs setDefaultProfile no 0 Serial print Set Default Profile Number as Serial println no SIM MVNO SIM
45. Serial printin Shutdown Title a3gs end a3gs shutdown delay 15000 goto redo Repeat Serial begin 9600 delay 3000 Wait for Start Serial Monitor Serial printIn Ready redo Serial print Initializing if a3gs start 0 amp amp a3gs begin 0 1 Serial printin connectTCP can t connect goto end j end while 1 void loop 4 TCP IP 75 Copyright c 2012 3G alliance All Rights Reserved TA Brain aga 15 sample TCPIP ino TcP rP boolean getTitle char p char title zi Bi WISIS CFD if ptt P Ready continue skip not tag UN P if strncmp const char p title gt 6 Initializing Succeeded continue skip not title tag www arduino cc Page title is Arduino title tag found HomePage Shutdown 4 while p Y0 amp amp p 1 lt ttle gt p p 0 Serial print server lt title gt Serial print Page title is X Serial print title Serial printIn Y return true return false a Copyright c 2012 3G alliance All Rights Reserved TA Brain UST ESI 1 AS TESI
46. o FE 3G xU Aspen Vin 84 Copyright c 2012 3G alliance All Rights Reserved TA Brain
47. 5g Copyright c 2012 3G alliance All Rights Reserved TABrain aga 2 check service ino SIM SIM check_sercvce ino A3GS sample sketch 2 getServices if a3gs start 0 amp amp a3gs begin 0 lt zinclude SoftwareSerial h Serial DrintlIn Succeeded include a3gs h int rstatus if a3gs getServices status 0 lt void setup switch status 1 case a3gsSRV NO Serial begin 9600 Serial println No Service break delay 3000 Wait for Start Serial Monitor case a3gsSRV PS Serial Drintln Ready Serial println Packet Service Only break case a3gsSRV CS Serial print Initializing Serial println Voice Service Only break also SMS case a3gsSRV BOTH Serial println Packet And Voice Services break default break j Ready Serial printIn Failed Initializing Succeeded Packet And Voice Services Serlal printInCShutdown 7 a3gs end Shutdown a3gs shutdown j void loop a3gsSRV NO 20 a3gsSRV PS 21 a3gsSRV CS 22 SMS a3gsSRV_BOTH 23 SMS
48. A T H a3gsa y 3GShield Sensor Value 454 a3gsa g 3GShield Sensor Value 659 I 23952 3GShleid Sensor Value 832 e e e e e e e E s i 8 8 8 8 8 X9 TENTE LA 11 tweet sample2 ino gt tweet_sample gt tweet http arduino tweet appspot com text 1 Twitter a9 li ca e http twansform a O B X F REE V A Xx Google v Yeza xus Mir ipia ie ensor Value m 3GShield Sensor Value Twitter aGshield Sensor Value PER Em e aGshield Sensor Value FAS aGshield Sensor Value aGshield Sensor Value aGshield Sensor Value aGshield Sensor Value aGshield Sensor Value aGshield Sensor Value aGshield Sensor Value amp H55299 GShield Tweet
49. i a3gs setL ED true delay INTERVAL LED On Off a3gs setLED false delay INTERVAL j 73 Copyright c 2012 3G alliance All Rights Reserved TA Brain 14 On sms ino SMS SMS lenOn E a loop void setup A3GS sample skech 14 onSMSReceived Serial begin 9600 delay 3000 Wait for Start Serial Monitor Serial println Ready pinMode ledPin OUTPUT digitalWrite ledPin LOW LED off Serial print Initializing if a3gs start 0 amp amp a3gs begin 0 Zinclude SoftwareSerial h include a3gs h const int ledPin 13 volatile boolean received false char msg a39gsMAX SMS LENGTH 1 1 msn a3gsMAX MSN LENGTH 1 SMS l E MM SR DO A R Serial printin Failed digitalWrite ledPin HIGH LED on received true void loop If received 1 a Serial println SMS was received if a3gs readSMS msg sizeof msg msn sizeof msn 0 d Serial print MSN Serial println msn Serial print SMS Serial println msg Ready Initializing Succeede
50. if a3gs start 0 amp amp a3gs begin 0 Serial println Succeeded char date a3gsDATE SIZE time a3gsTIME SIZE if a3gs getTime date time 0 Serial print date Serial print ET ZIIBU28 Serial println time TAB J else Serial printIn Failed Serial printIn Shutdown a3gs end a3gs shutdown void loop lt Ready Initializing Succeeded 2012 10 05 07 29 00 Shutdown IEM 1980 1 5 16 00 16 65 Copyright c 2012 3G alliance All Rights Reserved TA Brain aga 7 get _tIme2 InO 2 gt IEM 1970 1 1 get time2 ino A3GS sample sketch 7 getTime2 Zinclude lt SoftwareSerial h gt include a3gs h void setuD Serial begin 9600 delay 3000 Wait for Start Se
51. All Rights Reserved TABrain EE 7 getDefaultProfile int getDefaultProfile int profileNum 1 E profileNum OUT 1 a3gsMAX PROFILE NUMBER 0 0 BE O O int pfNum if a3gs getDefaultProfile amp pfNum 0 Serial print Default Profile No is switch pfNum 1 Case 1 Serial printin docomo mopera Case 2 Serial printin IIJmio default Serial printin unknown profile b 52 Copyright c 2012 3G alliance All Rights Reserved TABrain aga 1 a3gs zip D 54 2 a3gs zip D 55 3 a3ds D 56 IV a3gs 1 a3gs zip 3G N a3gs zip Ay zip Arduino OIDE libraries ArduinolDE arduino 1 0 1 windows
52. 2 AS TESI 3 AS TESI 4 AST ESRI 5 a3gs h tweet COSM P 78 p 79 P 83 P 84 1 a3gs h Arduino GSM GPRS 18 SMS Web TCP getStatus begin end restart start shutdown getIMET setBaudrate setLED1 sehdSMS qavallableSMS readSMS onSMSReceived httpGET httpPOST tweet connectTCP disconnectTCP GPS getLocation getServices getRSSI getTime getTime2 getVersion http arduino tweet appspot com CDM s _3G BG IL AE 3G ON 3G OFF IMEI LED1 ON OFF SMS SMS SMS SMS _ GET
53. G getStatus 3G begin end restart 3G contin start 3G ON shutdown 3G OFF getIMEI IMEI ID SetLED LED1 ON OFF setBaudrate UART 4800bps _ SendSMS SMS ge 7 availablesMS SMS SMS amp readSMS SMS onSMSReceived SMS X Arduino GSM GPRS SIM 7 Copyright c 2012 3G alliance All Rights Reserved TABrain 93972 2 a3gs 3G httpGET Web httpPOST tweet GSP getLocation getServices getRSSI E getTime2 getVersion GET POST Twitter GPS
54. IEMSSanh FH 3G Aruino a3gs IEMZinah3G JVHh Ver o1 2012 12 01 3G 5959 TA Drain I IEM 3G 1 9 2 3G If 3G 1 IEM Internet of Everything Module 2 a3gs 3 I 3G Web GPS TCP IP IV a3gs 1 a3gs zip 2 a3gs zip 3 a3gs V oO NO check rssi ino 3G check service ino SIM cosm_sample ino get imei ino IEM
55. ar result int resultlength http GET server port 80 _path URL result OUT resultlength result 0 GET 0 GET server IP 1 20 resultlength e CTS resut 0 b 30 Copyright c 2012 3G alliance All Rights Reserved TABrain aga 3 Web httpposT int httpPOST const char server uint16_t port const char path const char header const char body char result int resultlength
56. begin 0 Serial println Succeeded else 1 Serial println Failed while 1 STOP TA Brain aga 3 cosm samDle inO Cosm_sample e C amp https cosm com users D amp cox F SEE V A T H X Cos OSr1 About Howitworks Support API Q 1 A a Connect to your world pe EXE pem Ecom conco gt LE gt httpPOST requesting YOUR FEED ID HERE 25 8 Succeeded gt Respanse gt httpPOST requesting 77 YOUR FEED ID HERE 25 8 Succeeded gt Respanse gt httpPOST requesting 78 YOUR FEED ID HERE 25 4 Succeeded Response gt httpPOST requesting 78 YOUR FEED ID HERE 25 4 Succeeded Response gt httpPOST requesting 80 YOUR FEED ID HERE 25 4 Succeeded gt Respanse gt httpPOST requesting 81 YOUR FEED ID HERE 25 4 Succeeded Response gt httpPOST requesting 82 YOUR FEED ID HERE 25 8 Succeeded gt Respanse gt httpPOST requesting 83 YOUR FEED ID HERE 25 8 Succeeded gt Respanse gt httpPOST requesting 84 YOUR FEED ID HERE 26 4 Succeeded Response gt httpPOST requesting 85 YOUR FEED ID HERE 26 9 Succeeded gt Respanse My Console ss b https cosm com feecs t P amp C X S Cosm temp x i bom
57. d SMS was received digitalWrite ledPin LOW LED off received false a3gs onSMSReceived ledOn Re set handler SMS SMS 100 74 Copyright c 2012 3G alliance All Rights Reserved 1 TABrain 93222 15 sample TCPIP ino D TcP rP TCP IP http Arduino title Send GET request a3gs write GET HTTP 1 0 n a3gs write HOST a3gs write server a3gs write n n Receive response do A3GS sample skech 15 connectTCP disconnectTCP read Atitle is extracted from a homepage Zinclude lt SoftwareSerial h gt include a3gs h const char server www arduino cc URL to extract a title const int port 80 char res 200 if nbytes a3gs read res sizeof res 1 lt 0 1 1 _ Serial printIn read faled break boolean getTitle char res res nbytes X0 void setup y while getTitle res i else Serial printin Failed
58. e a3gs h char resla3gsMAX_RESULT_LENGTH 1 1 Int len Ready Initializing Succeeded httpGET requesting OK lt DOCTYPE html PUBLIC W3C DTD XHTML 1 0 Transitional EN http www w3 org TR xhtml1 DTD xhtml1 transitional dtd html head title Arduino HomePage lt title gt lt link rel2 shortcut icon type image x icon href http arduino cc en favicon Shutdown 67 TABrain aga void setuD Serial begin 9600 delay 3000 Wait for Start Serial Monitor Serial printlIn Ready Serial print Initializing if a3gs start 0 amp amp a3gs begin 0 lt Serial println Succeeded Serial print httpGET requesting len sizeof res if a3gs httpGET server port path res amp len 0 Serial println OK Serial print Serial print res Serial println else Serial println NG else Serial printIn Failed Serial printIn Shutdown a3gs end a3gs shutdown void loop 1 Copyright c 2012 3G alliance All Rights Reserved 9 send sms ino A3GS sample sketch 9 sendSMS Japanease message
59. e All Rights Reserved TABrain 93922 3 Web X Arduino GSM GPRS http arduino tweet appspot com Twitter gt http GET POST Web 30 tweet o http arduino tweet appspot com 3G SIM 3G http 29 Copyright c 2012 3G alliance All Rights Reserved TA Brain 3 Web httpGET int httpGET const char server uint16 t port const char path ch
60. ed TABrain 93922 2 RRRRSIIIU 1 3G SMS Short Message Service 100 SMS SIM SMS SMS SMS SMS SMS P N DADNE 7777 270 TOT rT TO 97 MEER ERE TA Brain 2 sendSMS int sendSMS const char to const char msg int encode SMS to 10 msg
61. get location ino get time ino 1 get time ino 2 http_get ino send_sms ino 10 tweet _sample ino 11 tweet_sample2 ino 12 set_defaultprofile ino 13 blink led ino LEDD Ex 14 on_sms ino SMS 15 sample_TCPIP ino TCP IP DAS TESRI 1 UST ESHI 2 US TESI 3 UST ESI 4 USA TESI 5 a3gs h tweet COSM Copyright c 2012 3G alliance All Rights Reserved 559 TA Brain OO NONU RW OW 0 p 02 D 05 D 12 p 53 p 57 P 78 P 79 P 80 P 83 P 84 1 3G D 03 2 3G p 04 I IEM 3G 1 3G Arduino 3G IEM FOMA NTTdocomo MVNO IIJmio DTI SIM USB USB
62. iis INCISA Titae ud Ii Twitter Twitter SXJOWMEC3S P 79 Copyright c 2012 3G alliance AII R A CR mM 3 COSM COSM F E V A T H cosm com x Google osm About How it works X Support API a3gsaa Connect to your world Console Apps TAI nttps cosm com D acx 274A4F E V A T H ez Ra G3 cosm About How it works Support APIl Q Connect to your world Cosm Internet of Thin x Keys Settings My Console Debug Logout ordi COSM Get Started w Success Thanks for activating your account Try clicking one of the links below to start using d ar Activity Where the Internet of Things or is being built Started Connect devices and apps on the Cosm platform exchange data and ideas with developers and bring Start byiadding your device or feed Are you happy with Cosm F E V A T H osm About Howitworks Support API Connect to your world How can we help This part of our cosm is where
63. l println Error can t connect b 45 Copyright c 2012 3G alliance All Rights Reserved TABrain ags 6 TCP 1P read lt lt lt lt e 2 int read cha TCP resultlengoth r result int resultlength result OUT resultlength 1 0 close E 1 30 resultlength
64. nternational Mobile Subscriber Identity IEM IMEI 3G IEM MVNO Mobile Virtual Network Operator PHS Oo RSSI Received Signal Strength Indicator UNICODE UTF 8 UCS UNICODE 8 Copyright c 2012 3G alliance All Rights Reserved 83 pyright c i mE TABrain 3 DRAERS 3G 200mA gt 600mA PC USB 5 V500mA
65. println OK if a3gs tweet token message else Serial println OK Serial println NG else Serial println NG else j Serial printIn Failed delay 30000 30 j 69 Copyright c 2012 3G alliance All Rights Reserved TABrain aga 10 ea 30 X JE D CdS Initializing tweet requesting x x x x x x x 432t weet 428t weet 832t weet 8659t weet 454tweet AT2tweet 35ltweet ouccesseded NG request ing 432 request ing 428 request ing 832 request ing B59 request ing 454 request ing 472 request ing 351 lt 9600bps w Tweet aogsa a3gsa 3GShield Sensor Value 351 aogsa a3gsa 3GShield Sensor Value 472 aogsa a3gsa 3GsSshield Sensor Value 454 lt F WEE aogsa a3gsa 3GShield Sensor Value 659 New Tool Eliminates Ug Craigslist Ads Happy Friendship Day qc gs Juan Direction F SNL Sofa Vergara Thaeme e Thiago a gsa 3GShield Sensor Value 832 aegsa a3gsa 3GShield Sensor Value 432 V
66. rial Monitor Serial printIn Ready Serial print Initializing if a3gs start 0 amp amp a3gs begin 0 Serial println Succeeded unit32 t seconds if a3gs getTime2 seconds 0 4 Serial print seconds Serial printIn Sec E else Serial printin Failed Serial printIn Shutdown a3gs end a3gs shutdown void loop 1 66 Ready Initializing Succeeded 1344179843 Sec Shutdown IEM 1980 1 5 16 00 16 Copyright c 2012 3G alliance All Rights Reserved 8 http get ino google http get ino A3GS sample sketch 8 httpGET Arduino const char server www arduino cc const char path i int port 80 Zinclude SoftwareSerial h includ
67. sample sketch 1 httpPOST Use Cosm com Colud Service Cosm Com 9 include lt SoftwareSerial h gt 3 include a3gs h define LM61BIZ_Pin 1 LM61BIZ output pin A1 Feed ID const char server api cosm com int getTemp void const char header2 X ApiKey E F3 X Y Xx YerenContent Type text csv r n int port 80 int mV analogRead LM61BIZ Pin 4 88 return mV 600 char res 30 Qe H char body 20 int len Feed ID Key cosm com 3 void setup void loop pinMode 14 OUTPUT AO LM61BIZ GND digitalWrite 14 LOW pinMode 16 OUTPUT A2 LM61BIZ VSS digitalWrite 16 HIGH static int Count 1 Serial Drint gt httpDPOST requesting Serial println Count4 DEC len sizeof res int temp getTemp sprintf body YOUR FEED ID HERE 96d 96d temp 10 temp90o10 if a3gs httpPOST server port path header body res amp len 0 lt Serial println Succeeded Serial print gt Response httpPOST Serial print res Serial println jr else Serial println Failed delay 30000 take an interval Serial begin 9600 delay 3000 Wait for Start Serial Monitor Serial printIn Ready Serial print Initializing if a3gs start 0 amp amp a3gs
68. t Step 3 Run a sample sketch to tweet F EE V A xX Google T H Sez gt gt am A b Notice The library uses this site as a proxy server for OAuth stu Please avoid sending more than 1 request per minute Twitter seems to reject repeated tweets with the same cor Reference ARNS 1136700536 mDsv n3pJOc re xe CMPGCqBXUEPI See Arduino Playground ID PW Twitter Twitter T de cn Too R YSm a Lb mi pata
69. tatus ino get timeYXget time ino p 65 Yget time2Yget time2 ino p 66 Yhttp getYhttp get ino p 67 Yon smsYon sms ino p 74 Ysample TCPIPYsample TCPIP ino p 75 Ysend smsYsend sms ino p 68 Yset baudrateYset baudrate ino Yset defaultprofieYset defaultprofie ino p 78 Ytweet sampleYtweet sample ino p 69 a3gs a3gs a3gs SIM LED COSM IEM ID getStatus 70 1 1 httpGET SMS TCP IP lt gt APN
70. test CdS Sensor Vlue ADD A NEW DATASTR Location Map General C No I will push data to Cosm Yes Cosm will pull data Public Website Click on the map to set location marker Remove marker B d j 5 2r S er mm g Feed Information 7d n weetm x 4 Tags Description 3G shield for Cf bn 3 Arduino arduino e e 3 2072 ZENRIN r8 https cosm com fesds 70094 F WEE V A X Google osm About How it works X Support API Connect to your world J a3gsa Feed Formats JSON XML 49 Tags 3G shield for Ard Created Sun 05 Aug 2012 iin 07 15 43 0000 arduino Followers 0 F WEE X Googk osm About How it works Support API Q j asgsaa Connect to your world Console Apps V A T H API Keys ii ica Key for Arduwrfo feed 70094 2012 Cosm Ltd a LogMe f d D keys Settings HowitWorks Press Events Jobs Terms of Service Privacy Policy Contact 4 Arduino Arduino
71. the Adafruit Ethemet shield either one will work as long as it s got a Wiznet Ethernet module on board Current Cost NetSmart Arduino Ethernet or using Ethernet D THO directly to Shield This example has been updated to use version 2 0 of the Cosm com API To make it work create a feed with a datastream and give it the ID sensor1 Or change the code below to match your feed ANC Twitter Stats Create a test feed by adding your Twitter stats r ia https cosm com users as3gsae P X F E V A T H ok Create Sm m m m m m m ii Create your new feed PR b 81 Copyright c 2012 3G alliance All Rights Reserved TABrain 3 COSM e sS B https cosm com users ssgss O C X i sz Twitter cue F EE V A T H X Google I tan cosm About How it works Support API CRI p a39sa A Console Apps My Console w Success You have created a new Cosm feed a3gsa There are no datastreams yet for this feed Datastream Are you happy with x es Tvittor liat mos rE hk n Google IEMmodule
72. version PLEASE REPLACE msn WITH CORRECT TELEPHONE NUMBER BEFORE UPLOAD THIS SKETCH Zinclude SoftwareSerial h include a3gs h SMS POEM UNICODE char msn 4 09012345678 77 Replace your phone namber char msd TEST MESSAGE HELLO ASCII String f char msg 4 0x53 0x30 0x8c 0x30 0x6f 0x30 0xc6 0x30 Oxb9 0x30 0xc8 0x30 0x67 0x30 0x59 0x30 0x00 Japanease written in UNICODE m setup Ready Initializing Succeeded Serial begin 9600 delay 3000 Wait for Start Serial Monitor C Serial printIn Ready Serial print Initializing if a3gs start 0 amp amp a3gs begin 0 1 SMS Serial DrintlIn Succeeded z Serial print SMS Sending UN if a3gs sendSMS msn msg a3gsCS_UNICODE Serial printIn OK else 1 SMS SIM Serial printIn Cant send SMS 7 SMS Sending OK Shutdown else Serial println Failed 2 UNICODE Serial printIn Shutdown a3gs end a3gs shutdown
73. you can dig in to the documentation find hardware libraries and examples of devices that already work with Cosm or get in touch with us or other members of the Cosm community Web N Thank you for signing up with Cosh https cosm com activation code 11 9 1 Xekekekeleleleleleeelelelelekeleleleled 95 7a86 3f 1 eb068b0054e527506b l If you have any problems with the activation process or any other questions or comments please get in touch with us at support cosm com B 2 ID cosm com Where the Internet of Things is being built MPWWIMN 100 b 80 Copyright c 2012 3G alliance All Rights Reserved TABrain 3 COSM X Google Your new feed ID is 70094 Paste this code into a new sketch to get started See this tutorial for more details i 274MP E V A T H X Googie Arduino Sketch Pr Cosm sensor client This sketch connects an analog sensor to Cosm http www cosm com using a Wiznet Ethernet shield You can use the Arduino Ethernet shield or
Download Pdf Manuals
Related Search
Related Contents
Spire Bliss 9 Pro+ 8GB White MB QUART Quart Mobil PSC 216 User's Manual Anleitung - Billiger.de HeartSine® HeartSine® Video Ski Goggles HD1 - produktinfo.conrad.com 8T0 054 630 A MA PDC Audi A4 + A5 Sportback.fm Gated Mode - Electrocomponents UM10736 LPC15xx User manual - ARM DS 取扱説明書 - ブルーマチックジャパン Copyright © All rights reserved.
Failed to retrieve file