User's Manual
Table Of Contents
- Introduction
- The Integrator’s Task
- Installing the Modem
- Using the Modem Test Jig
- Testing
- Desense
- Application Development
- Message Routing and Migration
- Appendix A - NCL Interface
- Appendix B - Software Development Kit
- SDK Contents
- System Requirements
- SDK Software Architecture
- NCL Application Programmer’s Interface
- Implementation
- Logical Architecture
- Application Interface
- Opening a Session
- Close Session
- Send Data to a Radio Host
- Receive Data From RPM
- Get RPM Status Information
- Set Configuration ITEMS Within the RPM
- Reset RPM
- Register Event Callback Function
- Enable / Disable Events
- Get Error Description
- Register Wakeup Application
- Deregister Wakeup Application
- Switch RPM On/Off
- Send Generic NCL Command To RPM
- Get Software Version
- SCR Application Programmer’s Interface
- A
- Appendix C – Sample programs
- Appendix D - Wavenet Application Loader
- Appendix E - Numeric Conversion Chart
- Appendix F - Specifications
- Appendix H - Glossary
Boomer II User Manual & Integrator’s Guide ______________________________________________ SDK SCRAPI
BM210012WT27 157 Wavenet Technology
error
Return value > 0 Operation was successful .and the decoded message is returned
in l_msg.
Example
#include <scrapi.h>
{
SCRMsg lmsg; /* SCR message struct
*/
byte lbuffer[SCR_MAX_LEN];/*buffer for received SCR msg
*/
int llen; /* length of received SCR msg
*/
int lused; /* return code from scr_Decode
*/
. . .
/* receive data into lbuffer */
llen = x25recv( . . . lbuffer, . . .);
. . .
lused = scr_Decode(llen, lbuffer, &lmsg);
if (lused > 0) {
/* process message */
. . .
scr_FreeDecoding(lmsg); /* free decoded message */
}
else if (lused == 0) {
/* incomplete message received */
}
else {
/* report an.error */
. . .
}
}
scr_FreeDecoding()
Prototype:
void scr_FreeDecoding(SCRMsg *l_msg)
Description
This routine is used to free any memory allocated inside an SCRMsg
structure by a successful call to scr_Decode(). All calls to scr_Decode()
that return a successfully decoded SCR message (the return value is a
positive value) must be followed by a call to scr_FreeDecoding(), after
the caller has fully processed the decoded message. If
scr_FreeDecoding() is not called, memory leaks will occur.
Note: The SCRMsg structure itself is not freed. Only allocated memory
within this structure is freed. After scr_FreeDecoding() has been
called, all pointers within the SCRMsg structure will be invalid.
Input: