Hi,
About the SIM PIN:
You should define you real PIN in the "gateway.setSimPin("0000");" call.
And, by reading your other thread, you should probably also use the
"gateway.setSimPin2();" method as well...
About the Gateway definition:
Use the string "Wavecom" as the manufacturer parameter, and empty ("") as
the modem.
2009/8/9 golfdude <[email protected]>
>
>
> Should I be setting something to the SimPin value of
> SerialModemGateway beside the default of "0000" ? Also the last 2
> parameters to the SerialModemGateway constructor - what should this be
> and how important is this ? ( my modem is a AG-GSM-2303U - wavecom
> chipset ).
>
> My SendMessage code is...
>
> public void doIt() throws Exception
> {
> Service srv;
> OutboundMessage msg;
> OutboundNotification outboundNotification = new
> OutboundNotification
> ();
> System.out.println("Example: Send message from a serial gsm
> modem.");
> System.out.println(Library.getLibraryDescription());
> System.out.println("Version: " +
> Library.getLibraryVersion());
> srv = new Service();
> SerialModemGateway gateway = new
> SerialModemGateway("modem.com9",
> "COM9", 9600, "wismo", "???");
> gateway.setInbound(true);
> gateway.setOutbound(true);
> gateway.setSimPin("0000");
> srv.setOutboundNotification(outboundNotification);
> srv.addGateway(gateway);
> srv.startService();
> System.out.println();
> System.out.println("Modem Information:");
> System.out.println(" Manufacturer: " +
> gateway.getManufacturer());
> System.out.println(" Model: " + gateway.getModel());
> System.out.println(" Serial No: " + gateway.getSerialNo());
> System.out.println(" SIM IMSI: " + gateway.getImsi());
> System.out.println(" Signal Level: " +
> gateway.getSignalLevel() +
> "%");
> System.out.println(" Battery Level: " +
> gateway.getBatteryLevel() +
> "%");
> System.out.println();
> // Send a message synchronously.
> msg = new OutboundMessage("+cellnum", "Hello from gd");
> srv.sendMessage(msg);
> System.out.println(msg);
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"SMSLib User Group" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/SMSLib?hl=en
-~----------~----~----~----~------~----~------~--~---