j2me GPS读取框架

时间:2013-05-31 04:55:24
【文件属性】:

文件名称:j2me GPS读取框架

文件大小:40KB

文件格式:RAR

更新时间:2013-05-31 04:55:24

j2me,jsr179,gps,定位

jsr179读取卫星定位数据,可以设置读取间隔时间, 文件包括:使用说明文档,源码。 范例: GPSManager gps=new GPSManager(10); Thread GPSThread = new Thread(gps); GPSCanvas gpsreadListener =new GPSCanvas(); gps.setGPSReadListener(gpsreadListener) if(!gps.isRun()) { GPSThread.start(); } public GPSCanvas extends Canas implements GPSreadListener { double Lat=0.0; double Lng=0.0; protected void paint(Graphics g) { g.setColor(0); g.drawRect(0,0,getWidth(),getHeight()) g.setColor(255,255,255); g.drawString("Lat: "+Lat,5,5,0); g.drawString("Lng: "+Lng,5,25,0); } public void ReadPosition(double Lat, double Lng, float Alt){ this.Lat=Lat; this.Lng=Lng; repaint(); } public void GPSDevicesState(int stat){}; public void closeDevices(){ System.gc(); } }


【文件预览】:
j2me gps读取框架
----src()
--------location()
----GPSdoc()
--------resources()
--------stylesheet.css(1KB)
--------allclasses-noframe.html(992B)
--------allclasses-frame.html(1KB)
--------com()
--------overview-tree.html(6KB)
--------constant-values.html(5KB)
--------index-files()
--------package-list(23B)
--------help-doc.html(8KB)
--------deprecated-list.html(5KB)
--------index.html(1KB)

网友评论