Home

BBCapeGPSGPRS User Manual

image

Contents

1. N S INDICATOR token strtok NULL comma memcpy location N S indicator token strlen token location N S indicator strlen token 6 LONGITUDE token strtok NULL comma memcpy location Long token strlen token location Long strlen token 9 W INDICATOR token strtok NULL comma memcpy location E W indicator token strlen token location E IN indicator strlen token 9 token strtok NULL comma EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 31 of 31 User Manual copy vel token gjera kaki ANGLE gt gt k ak akak ak k ak akk k KK kk k kkk k KK token strtok NULL comma memcpy location gt angle token strlen token location angle strlen token 6 DATE token strtok NULL comma memcpy location gt Date token strlen token location Date strlen token 9 TIME 8 kok kok token_time strtok copy_time point memcpy location gt Time token time strlen token time location Time strlen token time VELOCITY FEKKKKKKKKKAKKKKKKKKKKK token vel strtok copy vel point vel atof
2. Assert a pulse on the GPS ON OFF input every second until GPS starts indicating a high on GPS WAKEUP output or generating serial messages on ttyO1 The GPS starts after asserting a rising edge pulse on GPS ON OFF input and when high level persists for at least three cycles of RTC clock To start receiving GPS messages the user only needs to turn on the GPS part of the module by running the script init GPS supplied Finally configure ttyOl UART to work as e Data rate 4800bps e Data bits 8 e Parity None e Stop bits 1 e Flow control None After this you should be able to see GPS messages on ttyO1 8 1 3 GPS Shutdown When GPS is working a pulse on the GPS ON OFF input triggers GPS shutdown sequence This process may take from 10ms up to 900ms depending on operation in progress To shutdown the GPS part of the module the user can also run init GPS script EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 26 of 31 User Manual 8 2 Automatic Process on Boot To setup user BeagleBone to start automatically GPRS and GPS parts the user has to follow the procedure described above 1 Follow Chapter 6 and confirm that everything works 2 Insert script initcape into etc init d folder 3 In console execute the following command to create a new service to be run at startup update rc d initcape defaults 4 Reboot BeagleBone and check if cape has been ena
3. BBCapeGPSGPRS User Manual 2 RELATED DOCUMENTS 2 1 Reference Websites Version Date Page 1 0 20 12 2014 12 of 31 1 PPPD Linux man page Online Available http linux die net man 8 pppd Accessed 06 2013 2 2 Reference documents Table 2 1 specifies which reference documents should be considered when following this document Table 2 1 Related Documents Reference Title Version Date RD 1 BeagleBone White System Reference Manual Rev A5 02 2012 RD 2 BeagleBone Black System Reference Manual Rev A52 04 2013 RD 3 GE864 GPS Hardware User Guide Rev 10 24 04 2012 EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 13 of 31 User Manual 3 POWER SUPPLY When BB BONE GPS GPRS cape is connected in your beaglebone the USB connection is not enough to supply both boards so is advisable to use an generic charger with 5V with a minimum current of 1A EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 14 of 31 User Manual 4 BEAGLEBONE BLACK COMPATIBILITY The BB BONE GPS GPRS is compatible with BeagleBone Black however HDMI needs to be disabled due to hardware resource conflicts It is possible to disable HDMI on boot through editing uEnv txt file present on BeagleBone Black file system when it is plugged in on computer USB port To do it simply add the following information into file optargs quiet cape
4. 21 of 31 User Manual Inside this directory you will need to create a directory named peers mkdir etc ppp peers Inside this directory you should place the ppp start file supplied with the cape After that copy the files gprs connect chat and init_modem to etc ppp directory To conclude configuration process etc ppp options file has to be edited and some options changed according with the following dev ttyO5 57600 lock crtscts noauth defaultroute user your user name password your password connect usr sbin chat V e t 90 f etc ppp gprs connect chat noipdefault usepeerdns noccp debug logfile var log ppp log user your ISP user name password your ISP login password Please note that debug and logfile options are not mandatory you may use it for debug purposes by tailing ppp log file For example tail f var log ppp log Press CTRL C to exit This file probably won t exist on the specified directory If you want to use the debug feature you need to create it EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 22 of 31 User Manual The options suggested are the minimum for module s correct functioning however users may add more options according with the application scenario Please refer to 1 for more information on PPPD options IMPORTANT NOTE It is recommend that the SIM card used in your cape has its PIN
5. AX CONNECTING SOLUTIONS Beaglebone cape GPS GPRS BBCapeGPSGPRS User Manual Code BBCapeGPSGPRS MANUAL EACH 1 0 Version Date 20 12 2014 BBCapeGPSGPRS Version 1 0 User Manual Date 20 12 2014 Page 2 of 31 Page intentionally left blank EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 3 of 31 User Manual Warranty Warnings and Disclaimers This evaluation board kit is intended for use for ENGINEERING DEVELOPMENT DEMONSTRATION OR EVALUATION PURPOSES ONLY and is not considered by EXPLOITSYS to be a finished end product fit for general consumer use Persons handling the product s must have electronics training and observe good engineering practice standards As such the goods being provided are not intended to be complete in terms of required design marketing and or manufacturing related protective considerations including product safety and environmental measures typically found in end products that incorporate such semiconductor components or circuit boards This evaluation board kit does not fall within the scope of the European Union directives regarding electromagnetic compatibility restricted substances ROHS and therefore may not meet the technical requirements of these directives or other related directives Please read the User Manual and specifically the Warnings and Restrictions notice in the Systems Reference Manual of the BeagleBone you are using prior to handlin
6. EACH Lda BBCapeGPSGPRS Version 1 0 User Manual Date 20 12 2014 Page 7 of 31 Table of Contents 11 imm E M 11 1 2 Acronyms and Abbreviations eee eese eee ee ee eene seen eee tE seta sese eas tape esos e seen aee e ce ve nese vene c ece sece 11 2 Related DOG ime rts e M 12 2 1 Reference 12 2 2 Reference documents esee esee eee seta stet enne tastes sone tastes senatu sets sesso seta sees sse secececeme eee sesese 12 3 BeagleBone Black Compatibility soon eee eere ee eere ee ee eee ee eene eese esee ee eoo e ees tete oe 13 4 Pin DescriptlODi casia indare doren vide h na Co dae 15 A PEL V LED 17 4 2 PWRMON 18 4 3 65M ON OEE 18 4 4 GPS ON OBF and GPS W AIC UP je sdi desert 18 OU P veli prev u ERE PAPER EE Ev PvE EP MR o 18 5 Interacting with GPIO S enge QUEE Oa DER PNE 19 LO TUNG S LUP oc c M 20 LU Cape leri plor cede E nse 20 An sssbecdansonacassusdobedonssesasse sassocsonsonssassusdeaspsasenssnsevansosaoeedssosdsane 20 6 3 GPRS Communication protocol esesoessesoossessossessossosesesocssesoossesoosseseossossoesocssesoossessossessossosssssseseose 20
7. SM PEST IU EM 20 7 Interacting with Cap ns n sit FERAE IY 23 7 1 Manual Process every time BB boots up cete eee eee etes veseve ce ce cececececececesecesecesesesese 23 7 1 1 GPS Communication Only for version with 25 T2242 GPS BOWwers p tre bee ER ae tees e eni r t 25 halide GPS SUA OWT squat Gic EA Eoo e ae UR vias ee st SS o edu cap A Cc a V s isses EE te 25 7 2 Automatic Process on BOO ae m s cobeevectosesece bsvatesesosoeacecsosessceosees 26 8 Use case I ERREUR sissi Co E To AREE kae 27 8 1 Us Case revise 27 8 2 Required configuration setup one time use always anccccccccccccccccsecesecececececececececesecesecesece nese seseessocese 27 8 3 Simple Application v n vras cose 27 EACH Lda BBCapeGPSGPRS Version 1 0 User Manual Date 20 12 2014 8 of 31 Page intentionally left blank EACH Lda BBCapeGPSGPRS Version 1 0 User Manual Date 20 12 2014 Page 9 of 31 List of Figures Fig 4 1 P8 Pin location on BeagleBone White aaa aaa aaa aaa eee nenen eee nene ever even eee veren 16 Fig 4 2 P8 Pin location on Beagle Bone Black eee ee vere vene 16 Fig 4 3 P9 Pin location in BeagleBone White and Black anes eee ee eneve venes
8. code disabled Some users reported problems when using PPPD with the SIM card PIN code active so for correct functioning your SIM card should have its PIN code disabled To start interacting with BB BONE GPS GPRS please refer to chapter 8 EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 23 of 31 User Manual 8 INTERACTING WITH CAPE IMPORTANT NOTE Please be aware that beaglebone might take some seconds about 60s to start when BB BONE GPS GPRS is plugged in due to EEPROM read so do not be worried when that happens 8 1 Manual Process every time BB boots up gt Enable cape echo BB BONE GPS GPRS gt sys devices bone capemgr slots After the cape is enabled on user BeagleBone and ready to be used To validate that the operations has succeeded you can type cat sys devices bone capemgr slots If the cape firmware is correctly loaded the cape name is shown gt Initialize GPRS Modem Due to cape design when it is powered GPRS part is automatically turned on so the led present on cape should start blinking as soon the cape starts Starting PPPD After setup is completed you are able to start running PPPD using the following command letc ppp peers ppp start This command will start the process that will connect your BB to this module and consequently to the Internet EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 24
9. of 31 User Manual gt Testing PPPD connection If the process finished successfully when you execute the ifconfig command you should see a new interface called on your networks interface list To test if everything is correctly running you can attempt to ping an IP address that is expected to respond gt Stopping PPPD optional To stop PPPD process you can simply run the following commands 1 To remove ppp interface killall pppd To remove the lock process that has been made to ttyO5 rm var lock LCK ttyO5 After these two commands you can check that interface pppO has been removed from your network connections list Stopping GPRS Modem To stop GPRS part of cape the user only needs to run script init modem letc ppp init modem This script will stop GPRS part and to ensure that it have been stopped led present on cape should stop blinking EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 25 of 31 User Manual 8 1 1 GPS Communication Only for version with GPS Communication with GPS module simply needs to turn on the module and NMEA message starts appearing in ttyOT 8 1 2 GPS Power up To switch ON the GPS a pulse is required at the input pin GPS ON OFF In order to know when the GPS is ready to accept the pulse the application in the host controller can either Wait for a fixed interval Monitor a pulse on GPS VAKEUP output
10. token vel vel vel 1 852 sprintf location Speed vel location Speed strlen token vel j Jj Sends position information to a specified server SH void sendInfoToServer char message system message Builds link to use in the call of server info update according with the specified format p void buildLink struct Location location char address strcpy address curl your Link strcat address location Lat strcat address strcat address location N S indicator strcat address strcat address location Long strcat address strcat address location E IN indicator strcat address strcat address location Date strcat address strcat address location Time strcat address strcat address location Speed strcat address strcat address 0 EACH Lda
11. 17 List of Tables Table 2 L Related DOCume nts 12 Table 4 2 PS Header pin Usage reete ee ete RE i Eee n 15 Table 4 3 P9 Header pin usage e Re Dele oett er eere le 15 Table 4 4 STAT LED pin eee enen even ettet eren 17 EACH Lda BBCapeGPSGPRS Version 1 0 User Manual Date 20 12 2014 Page 10 of 31 Page intentionally left blank EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 11 of 31 User Manual 1 INTRODUCTION The BeagleBone Cape described in this document adds GPS and GSM capabilities to the BeagleBone making it suitable for tracking and M2M scenarios The cape uses Telit GE864 a high quality module with proven performance and reliability This cape supports the Quad band GSM GPRS 850 MHz 900MHz 1800MHz and 1900MHz 1 1 Scope This document describes the cape s behaviors and features and also how to interact with it 1 2 Acronyms and Abbreviations The acronyms and abbreviations used in the present document are Acronym Description BB BeagleBone BBB BeagleBone Black GPRS General Packet Radio Service GPS Global Positioning System IO Input Output PPPD Point to Point Protocol Daemon RD Reference Document BB BONE GPS GPRS Wen U A iie a functionality enable by telit module GE864 The EACH Lda
12. TSN UARTS TXD UART5 RXD GPIO2 12 GPIO2 13 GPIO2 10 GPIO2 11 LCD DE LCD DATA14 LCD DATA15 LCD DATAS LCD DATAS LCD DATAS LCD DATAT LCD DATA4 LCD DATAS Fig 5 2 P8 Pin location on BeagleBone Black EACH Lda BBCapeGPSGPRS Version 1 0 User Manual Date 20 12 2014 Page 17 of 31 DGND 5 DGND VDD 3V3EXP VDD 5V GPIO1 28 UART1_TXD UART1_RXD FEMALE HEADER 2x23 DGND DGND Fig 5 3 P9 Pin location in BeagleBone White and Black 5 1 STAT LED This output pin provides information regarding the status of the GSM operating mode This pin has three different behaviors enumerated in the next table Table 5 4 STAT LED pin behaviour Pin Behavior Led Device status Permanently off Device off Net search not registered turning off ON OFF with period of 35 Registered full service ON OFF with period of 1s This pin is informational only and its usage is optional and the led present in the cape is connected to this pin so the user can easily understand the behavior of the cape EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 18 of 31 User Manual 5 2 PWRMON This output pin can be used to check if the device is turned on After the module has been switched on this pin will be raised up after a delay of 1000ms if the power up sequence is successful This pin goes low when the device is powered off 5 3 GSM_ON_OFF This output pi
13. bled and GPRS and GPS have been correctly started If user needs to remove the service created to cape can simply run the following command update rc d f initcape remove EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 27 of 31 User Manual 9 USE CASE EXAMPLE 9 1 Use case description The use case presented shows how to configure BeagleBone to use BB BONE GPS GPRS cape in a continuous mode to send GPS position through GPRS connection to a server link every 5 min configurable 9 2 Required configuration setup one time use always Set your script to run at boot Please make sure that e SIM card is connected to cape with PIN code disabled e GPS and GPRS antennas are connected 9 3 Simple Application code J CECI A AR ACA ACR ACR CK A AK k GPS TEST CAPE SCRIPT Created on Aug 06 2013 Author dcarona KIJ include stdio h include stdlib h include fcntl h include termios h Hinclude string h include unistd h define TRUE 1 define FALSE int fd char buffer 8 struct Location char Time 8 char status 2 char Lat 10 char N S indicator 2 char Long 11 char E W indicator 2 char Speed 9 char angle 7 char Date 7 EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 28 of 31 User Manual int readLine char result void parseMSG char msg struct Location location int size void sendInfoToServer cha
14. ddress printf Address s n address sendInfoToServer address tcflush fd TCIFLUSH Reads one complete line from GPS serial port int readLine char result int lineFeedFound FALSE int crfound FALSE int i 0 char c while lineFeedFound FALSE amp amp i 128 if read fd amp c 1 gt result it c if c 10 result i 0 lineFeedFound TRUE return i i EACH Lda 1 0 20 12 2014 29 of 31 BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 30 of 31 User Manual ee Separates each message into several fields and afects location struct if void parseMSG char msg struct Location location int size GPRMC 090446 000 3845 5509 00906 9152 0 00 129 54 080813 79 char comma 2 char point 2 char copy time copy vel char token char token time token vel float vel printf Msg s n msg token strtok msg comma token strtok NULL comma copy time token token strtok NULL comma if token A STATUS memcpy location status token strlen token INSERT 0 IN THE END OF STRING SO SYSTEM CAN DETECT ITS END location gt status strlen token 0 jt LATITUDE tt re token strtok NULL comma memcpy location Lat token strlen token location Lat strlen token
15. g the product This notice contains important safety information about temperatures and voltages No license is granted under any patent right or other intellectual property right of Supplier covering or relating to any machine process or combination in which such Supplier products or services might be or are used The Supplier currently deals with a variety of customers for products and therefore our arrangement with the user is not exclusive The Supplier assumes no liability for applications assistance customer product design software performance or infringement of patents or services described herein The BB BONE GPS GPRS as purchased is warranted against defects in materials and workmanship for a period of 90 days from purchase This warranty does not cover any problems occurring as a result of improper use modifications exposure to water excessive voltages abuse or accidents All boards will be returned via standard mail if an issue is found If no issue is found or express return is needed the customer will pay all shipping costs EACH Lda BBCapeGPSGPRS Version 1 0 User Manual Date 20 12 2014 Page 4 of 31 Page intentionally left blank EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 Page 5 of 31 User Manual Revision History Document creation 17 06 2013 EACH Lda BBCapeGPSGPRS Version 1 0 User Manual Date 20 12 2014 6 of 31 Page intentionally left blank
16. in is set to work as output the procedure is the same but in direction file should be echoed out instead of in and to affect the pin 1 or 0 should be echoed to value file EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 20 of 31 User Manual 7 INITIAL SETUP Before plug in BB BONE GPS GPRS cape into user beaglebone for the first time some steps need to be followed 7 1 Cape Firmware Insert the file cape bone gps gprs 00A0 dtbo supplied with the cape into the firmware folder cp cape bone gps gprs 00A0 dtbo lib firmware 7 2 Antennas The cape has two connectors for antennas where J1 corresponds to GSM antenna and J2 to GPS active antenna 7 3 GPRS Communication protocol 7 3 1 Setup In order to start communicating through a GPRS connection it is mandatory to make sure that the PPPD application is installed on the BeagleBone If you are using Angstrom Linux the PPP package can be installed with the following command opkg install ppp BeagleBone requires internet access Ethernet cable or other to download and install this application through the command described above If it is already installed a message reporting that your version is up to date is shown on the user console After the correct installation of PPPD a new directory called ppp is created on etc directory EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014
17. megr disable_partno BB BONELT HDMI BB BONELT HDMIN After adding this line save the file and reboot the BB Black EACH Lda BBCapeGPSGPRS User Manual 15 of 31 5 PIN DESCRIPTION Version Date Page 1 0 20 12 2014 This cape has been developed to be fully compatible with both versions of BeagleBone therefore based on RD 1 and RD 2 the pin map from BB perspective I O for both versions is the following Table 5 2 P8 Header pin usage Pin Name on Cape Name on BBW Name on BBB E Mode Direction P8 39 STAT_LED GPIO2_12 LCD_DATA6 76 7 1 P8 40 PWRMON GPIO2 13 LCD DATAT TT 7 1 P8 41 GSM ON OFF GPIO2 10 LCD DATA4 74 7 O P8 30 GPS ON OFF GPIO2 25 LCD DE 89 7 P8 31 GSM CTS UARTS CTSN LCD DATAI4 6 I 8 32 GSM RTS UARTS RTSN LCD DATAI5 6 O P8 37 GSM TXD UARTS TXD LCD DATAS 4 O P8 38 GSM RXD UART5 RXD LCD DATA9 4 I P8 42 GPS_WAKEUP GPIO2_11 LCD DATAS 75 7 1 Table 5 3 P9 Header pin usage Pin Name on Cape Name on BB Name on BBB EON Mode Direction P9 12 PWR_ON_OFF GPIO1_28 GPIO1_28 60 O p9 24 GPS TX UARTI TXD UARTI TXD O p9 26 GPS RX UARTI RXD UARTI RXD I Only for version with GPS otherwise consider it free to be used as generic GPIO by BeagleBone EACH Lda BBCapeGPSGPRS Version 1 0 User Manual Date 20 12 2014 Page 16 of 31 GPIO2 25 UARTS CTSN UARTS_R
18. n is used to turn on and off the GSM functionality An active low pulse with duration of at least 1 second toggles the state of the GSM 5 4 GPS_ON_OFF and GPS_WAKEUP These two pins are used to control the power of the GPS part of the module only for version with GPS 5 5 PWR_ON OFF This pin is active low and controls the power supply of the entire cape When this is low the cape is ON and when asserted the cape is set to OFF IMPORTANT NOTE Due to conflicts with boot pins the cape is by default set to OFF so to start interacting the user must set PWR ON OFF pin to zero through the process described in chapter 6 or running the script init cape supplied with the board EACH Lda BBCapeGPSGPRS Version 1 0 Date 20 12 2014 19 of 31 User Manual 6 INTERACTING WITH GPIO S To interact with BB GPIO s it is required to export the pin so the user can have access to it In order to know the pin number that corresponds to a certain GPIO the following formula can be used GPIOx y 32 y Example GPIO1_6 1 32 6 38 The pin that has to be exported is pin 38 After discovering pin number the following procedure should be adopted 1 Select the folder that controls GPIO s a cd sys class gpio 2 Choose which pin to export a echo38 export 3 Select the exported pin file a cd sys class gpio gpio38 4 Set pin direction a echo in gt direction 5 Read pin a cat value If p
19. r message void buildLink struct Location location char addr int main 1 int size struct termios opts struct Location location char line 128 char address 256 int test send FALSE Attempt to open the serial port if fd open dev ttyO1 O RDWR O NOCTTY O NDELAY 1 printf Unable to open serial device error d n fd Configure serial port tcgetattr fd amp opts opts c cflag opts c cflag amp CSIZE CS8 8 bit chars opts c iflag amp IGNBRK ignore break signal opts c lflag 0 no signaling chars no echo no canonical processing opts c oflag 0 no remapping no delays opts c cc VMIN 6 read doesn t block opts c cc VTIME 5 0 5 seconds read timeout opts c iflag amp IXON IXOFF IXANY shut off xon xoff ctrl opts c cflag CLOCAL CREAD ignore modem controls enable reading opts c cflag amp PARENB PARODD shut off parity opts c cflag 6 opts c cflag amp CSTOPB opts c cflag amp CRTSCTS cfsetispeed amp opts B4800 tcsetattr fd TCSANOW amp opts EACH Lda BBCapeGPSGPRS Version Date Page User Manual for Delay if test_send TRUE sleep 1800 Delay of 30min 1800s test send FALSE size readLine line if strstr line GPRMC test_send TRUE parseMSG line amp location size buildLink amp location a

Download Pdf Manuals

image

Related Search

Related Contents

UltraNova Editor & Librarian User Guide  PreSonus DigiMax D8  Samsung UD46C-B User Manual  Télécharger le fichier  必要資料リスト  Typhoon Acoustic 5.1 Amplified Speaker System  Manual de Usuario - Set-FX  Samsung QM105D Brugervejledning  Changement de l`orientation du micro Réglage de la largeur  maxurethane 2c  

Copyright © All rights reserved.
Failed to retrieve file