All rights reserved. No part of this publication may be reproduced in any form or by any means without permission in
writing from the publisher.
Specifications are subject to change without prior notice.
All products and company names mentioned in this manual are trademarks or registered trademarks of their
respective holders.
Page 3
Update
Version Date Detail
1.0 March, 2009 First Release
2.0 July, 2009 Added “Operating Precautions”
Modified following parameters of functions.
- GetSIMPINPUKCounter
- SetNecessarySIMPIN
- SetRadioBand
- GetOperatorInfo
- SendSMS
3.0 September, 2009 Added “1. Programing”
Page 4
Introduction
This reference manual is intended for software developers using VB.NET or C# to develop software applications using
GPRS(EDGE) functions for the BHT-700.
Operating Precautions
When you develop software applications using GPRS(EDGE) functions, you need to copy GPRSLIB.dll supplied with
GPRS Class Library to a Windows folder of BHT-700.
Otherwise the applications you developed can’t operate properly.
Related Manuals
Please refer to the following related manuals for further information.
• BHT-700-WM Class Library Reference Manual
Contacts
Please forward any opinions or questions that you may have regarding this manual to the address below or contact us
by telephone.
DENSO WAVE INCORPORATED
MT Bldg. Hall No.2, 4-2-12,Toranomon, Minato-ku, Tokyo, 105-0001 Japan
Tel: +81-3-5472-0477
Latest Information
Please access our Web site using the following URL for the latest information on this manual and our full range of
products.
http://www.denso-wave.com/
More detailed information is available for product owners at our dedicated Web site (QBNet) for registered users.
Please access the above URL for user registration and details on QBNet.
3. SMS information structure........................................................................................................................................................31
4. Operator list structure................................................................................................................................................................ 35
6. Time structure................................................................................................................................................................................37
Step2 : Power on GPRS module.
use "PowerOn" method
Step3 : Open COM port to send a control command to the GPRS module.
use "OpenCom" method
Step4 : Check the authentication status of SIM PIN authentication.
use "GetSIMPINStatus" method
Step5 : Input PIN code If PIN code is necessary at 4.
use "SetSIMPIN" method
Step6 : Set a radio frequency band.
use "SetRadioBand" method
Step7 : After within around 60 sec, GPRS complete to connect to a base station. (Notes)
(Notes) It is long time to connect to a base station at the first time.
- 1 -
Page 7
2. GPRS class
Constructor
There is no need to create an instance because all the members are static members
Methods
Method Name Description
PowerOnTurn ON GPRS module
PowerOffTurn OFF GPRS module
OpenComOpen GPRS COM port
CloseComClose GPRS COM port
GetSIMPINStatusGet the SIM PIN authentication status
GetSIMPINPUKCounterGet the number of attempts still available for entering the
PIN/PUK code
SetSIMPINSet the SIM PIN for GSM network registration
ChangeSIMPINChange SIM PIN for GSM network registration
SetNecessarySIMPINSelect whether SIM PIN is necessary or not
SetSIMPUKSet the SIM PUK to unlock the PIN-lock issue and assign a
new PIN code for next registration
SetRadioBandSelect radio frequency band
GetSignalStrengthGet the RSSI
GetModuleVersionGet the firmware version of module
GetAllOperatorCntAcquire the number of total operator
GetAllOperatorInfoAcquire all the operator name
GetOperatorListCntAcquire the number of visible operator
GetOperatorListInfoAcquire all the visible operator name
GetOperatorInfoGet the operator name
SetSMSStorageDestSpecify destination storing received short message
DeleteSMSDelete short message
ReadSMSRead short message
SendSMSSend short message
WriteSMSToMemWrite short message into the memory
SendSMSFromMemSend short message stored in the memory
GetSMSListCntAcquire the number of SMS stored in the memory or UIM
Enumeration
Enumeration Name Description
EN_SIMSTATUS SIM authentication state
EN_RADIOBANDRadio band
EN_STORAGESMSStorage area to save short message
- 2 -
Page 8
PowerOn
Turn the power of GPRS module on.
■ Syntax
[VB]
PublicSharedFunctionPowerOn() As UInt32
[C#]
public static UInt32 PowerOn();
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 3 -
Page 9
PowerOff
Turn the power of GPRS module off.
■ Syntax
[VB]
PublicSharedFunctionPowerOff() As UInt32
[C#]
public static UInt32 PowerOff();
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 4 -
Page 10
OpenCom
Open the COM port for GPRS function.
■ Syntax
[VB]
PublicSharedFunctionOpenCom() As UInt32
[C#]
public static UInt32 OpenCom();
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 5 -
Page 11
CloseCom
Close the COM port of GPRS.
■ Syntax
[VB]
PublicSharedFunctionCloseCom() As UInt32
[C#]
public static UInt32 CloseCom();
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 6 -
Page 12
GetSIMPINStatus
Get the SIM PIN authentication state.
■ Syntax
[VB]
PublicSharedFunctionGetSimPINStatus( _
ByRef status As EN_SIMSTATUS) As UInt32
[C#]
public static UInt32 GetSimPINStatus(out EN_SIMSTATUS staus);
■ Parameters
status
[out] Authentication state
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 7 -
Page 13
GetSIMPINPUKCounter
Get the number of attempts still available for entering the PIN/PUK code.
■ Syntax
[VB]
PublicSharedFunctionGetSIMPINPUKCounter( _
ByRef PINCount As UInt32, _
ByRef PUKCount As UInt32) As UInt32
[C#]
public static UInt32 GetSIMPINPUKCounter(
out UInt32 PINCount, out UInt32 PUKCount);
■ Parameters
PINCount
[out] available attempts number for entering the PIN code
PUKCount
[out] available attempts number for entering the PUK code
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 8 -
Page 14
SetSIMPIN
Set the SIM PIN for GSM network registration.
■ Syntax
[VB]
PublicSharedFunctionSetSIMPIN(ByVal PIN As String) As UInt32
[C#]
public static UInt32 SetSIMPIN(string PIN);
■ Parameters
PIN
[in ] SIM PIN
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 9 -
Page 15
ChangeSIMPIN
Change SIM PIN for GSM network registration.
■ Syntax
[VB]
Public Shared Function ChangeSIMPIN _
(ByVal PIN As String, ByVal newPIN As String) As UInt32
[C#]
public static UInt32ChangeSIMPIN(string PIN, string newPIN);
■ Parameters
PIN
[in ] (old)PIN
newPIN
[in ] new PIN
Settable value : string which length is from 4 digits to 8 digits.
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 10 -
Page 16
SetNecessarySIMPIN
Select whether SIM PIN is necessary or not.
■ Syntax
[VB]
Public Shared Function SetNecessarySIMPIN _
(ByVal req As Boolean, ByVal PIN As String) As UInt32
[C#]
public static UInt32 SetNecessarySIMPIN(bool req, string PIN);
■ Parameters
req
[in ] PIN is necessary(=true) or unncessary(=false)
PIN
[in ] SIM PIN
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 11 -
Page 17
SetSIMPUK
Set the SIM PUK to unlock the PIN-lock issue and assign a new PIN code for next registration.
■ Syntax
[VB]
PublicSharedFunctionSetSIMPUK( _
ByVal puk As String, ByVal pin As String) As UInt32
[C#]
public static UInt32 SetSIMPUK(string puk, string pin);
■ Parameters
puk
[in ] PUK code
pin
[in ] new SIM PIN code
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 12 -
Page 18
SetRadioBand
Select radio frequency band.
■ Syntax
[VB]
PublicSharedFunctionSetRadioBand( _
ByVal prefBand As EN_RADIOBAND, _
ByVal enableBand As EN_RADIOBAND) As UInt32
[C#]
public static UInt32 SetRadioBand(
EN_RADIOBAND prefBand, EN_RADIOBAND enableBand);
■ Parameters
prefBand
[in ] preference band selection.
The selectable band is as following table.
enableBand
[in ] permitted band selection.
The selectable band is as following table.
band specification
GSM900 GSM900MHz
GSM1800 GSM1800MHz
GSM900 + GSM1800 GSM900MHz and GSM1800MHz
GSM1900 GSM1900MHz
GSM900 + GSM1900 GSM900MHz and GSM1900MHz
GSM850 GSM850MHz
GSM850 + GSM1800 GSM850MHz and GSM1800MHz
GSM850 + GSM1900 GSM850MHz and GSM1900MHz
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 13 -
Page 19
GetSignalStrength
Get the signal strength.
■ Syntax
[VB]
PublicSharedFunctionGetSignalStrength( _
ByRef RSSI As UInt32, ByRef BER As UInt32) As UInt32
[C#]
public static UInt32 GetSignalStrength( out UInt32 RSSI, out UInt32 BER);
■ Parameters
RSSI
[out] signal strength
rssi specification
0 -113 dBm or less
1 -111 dBm
2…30 -109…-53 dBm
31 -51 dBm or greater
99 Not known or not detectable
BER
[in ] Bit Error Rate
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 14 -
Page 20
GetModuleVersion
Get the firmware version of module.
■ Syntax
[VB]
PublicSharedFunctionGetModuleVersion( _
ByVal version As System.Text.StringBuilder) As UInt32
[C#]
public static UInt32 GetModuleVersion( System.Text.StringBuilder version);
■ Parameters
version
[out] F/W version
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 15 -
Page 21
GetAllOperatorCnt
Acquire the number of total operator.
■ Syntax
[VB]
PublicSharedFunctionGetAllOperatorCnt( _
ByRef opeCount As UInt32) As UInt32
[C#]
public static UInt32 GetAllOperatorCnt(out UInt32 opeCount);
■ Parameters
opeCount
[out] the number of operator
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 16 -
Page 22
GetAllOperatorInfo
Acquire all the operator name.
■ Syntax
[VB]
PublicSharedFunctionGetAllOperatorInfo( _
ByVal opeInfo As OperatorInfo()) As UInt32
[C#]
public static UInt32 GetAllOperatorInfo(OperatorInfo[] opeInfo);
■ Parameters
opeInfo
[out] array storing operator information (refer to
5. Operator structure)
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
■ note
Element count of opeInfo should be equal to or larger than the number of operator. Call
GetAlloperatorCnt method before calling this method to acquire the number of operator.
- 17 -
Page 23
GetOperatorListCnt
Acquire the number of visible operator.
■ Syntax
[VB]
PublicSharedFunctionGetOperatorListCnt( _
ByRef listCnt As UInt32) As UInt32
[C#]
public static UInt32 GetOperatorListCnt(out UInt32 listCnt);
■ Parameters
listCnt
[out] the number of operator
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 18 -
Page 24
GetOperatorListInfo
Acquire all the visible operator name.
■ Syntax
[VB]
PublicSharedFunctionGetOperatorListInfo( _
ByVal opeInfo As OperatorListInfo()) As UInt32
[C#]
public static UInt32 GetOperatorListInfo(
OperatorListInfo[] opeInfo);
■ Parameters
opeInfo
[out] array storing operator information (refer to
4. Operator list structure)
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
■ note
Element count of opeInfo should be equal to or larger than the number of visible operator.
Call GetOperatorListCnt method before calling this method to acquire the number of visible
operator.
- 19 -
Page 25
GetOperatorInfo
Get the operator name.
■ Syntax
[VB]
PublicSharedFunctionGetOperatorInfo( _
ByVal opeInfo As System.Text.StringBuilder) As UInt32
[C#]
public static UInt32 GetOperatorInfo( System.Text.StringBuilder opeInfo);
■ Parameters
opeInfo
[out] operator name
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 20 -
Page 26
SetSMSStorageDest
Specify the destination storing received short message.
■ Syntax
[VB]
PublicSharedFunctionSetSMSStorageDest( _
ByVal store As EN_STORAGESMS) As UInt32
[C#]
public static UInt32 SetSMSStorageDest(EN_STORAGESMS store);
■ Parameters
store
[in ] destination
Settable value : One of EN_STORAGESMS member
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 21 -
Page 27
DeleteSMS
Delete a short message.
■ Syntax
[VB]
PublicSharedFunctionDeleteSMS( _
ByVal storeDelSMS As EN_STORAGESMS, _
ByVal index As UInt32) As UInt32
[C#]
public static UInt32 DeleteSMS
(EN_STORAGESMS storeDelSMS, UInt32 index);
■ Parameters
storeDelSMS
[in ] storage area storing delting SMS
Settable value : one of EN_STORAGESMS member
index
[in ] index of SMS
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 22 -
Page 28
ReadSMS
Read out a short message.
■ Syntax
[VB]
PublicSharedFunctionReadSMS( _
ByVal SMSDest As EN_STORAGESMS, _
ByVal index As UInt32, ByRef info As SMSInfo) As UInt32
[C#]
public static UInt32 ReadSMS
(EN_STORAGESMS SMSDest, UInt32 index, out SMSInfo info);
■ Parameters
SMSDest
[in ] destination storing short message
settable value : one of EN_STORAGESMS member
index
[in ] index of short message
info
[out] read SMS information
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 23 -
Page 29
SendSMS
Send a short message.
■ Syntax
[VB]
Public Shared Function SendSMS( _
ByVal SMSDest As String, ByVal SMSText As String, _
ByRef msgRef As UInt32) As UInt32
[C#]
public static UInt32 SendSMS
(string SMSDest, string SMSText, out UInt32 msgRef);
■ Parameters
SMSDest
[in ] destination of short message
SMSText
[in ] contents of short message
msgRef
[out] SMS reference
■ Return value
error code
0 : Normal end
Other than 0 : Abnormal end. For more detail, refer to
7. error code.
- 24 -
Page 30
WriteSMSToMem
Write short message into the memory.
■ Syntax
[VB]
PublicSharedFunctionWriteSMSToMem( _
ByVal SMSDestStorage As EN_STORAGESMS, _
ByVal SMSDestAddr As String, ByVal SMSText As String, _
ByRef index As UInt32) As UInt32