This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class DevicerecordResource(ModelResource): | |
device = fields.ForeignKey(DeviceResource, 'device',full=True) | |
class Meta: | |
queryset = DeviceRecord.objects.all() | |
resource_name = 'devicerecord' | |
allowed_methods = ['get','put','post'] | |
authentication = ApiKeyAuthentication() | |
authorization = Authorization() | |
~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[6/24/2014 7:06:22 AM] (41.90.62.219:62885/TZone/tcp) Disconnect | |
[6/24/2014 7:06:22 AM] (41.90.62.219:62885/TZone/tcp) Error: Could not parse $$BA860041024247929|AA$GPRMC,070619.000,A,0114.9180,S,03647.9184,E,1.11,24.75,240614,,,A*4C[0x0D][0x0A] | |
[6/24/2014 7:06:22 AM] (41.90.62.219:62885/TZone/tcp) Client: $$BA860041024247929|AA$GPRMC,070619.000,A,0114.9180,S,03647.9184,E,1.11,24.75,240614,,,A*4C[0x0D][0x0A]|01.4|00.7|01.2|000001000000|20140624070619|14152819|04000000|0003109E|0000|0.2613|0747||D875[0x0D][0x0A] | |
[6/24/2014 7:04:20 AM] (41.90.62.219:62885/TZone/tcp) Report: (36.79713, -1.24810166666667, 0) (9.45, 120.61) (6/24/2014 7:04:17 AM)(Low Battery=False x)(SOS=False x)(Fuel level=25.8575)(CellID=263.76 x)(OdometerAcc=1253.9)(Speed=9.45 x) | |
[6/24/2014 7:04:20 AM] (41.90.62.219:62885/TZone/tcp) Client: $$BA860041024247929|AA$GPRMC,070417.000,A,0114.8861,S,03647.8278,E,18.37,120.61,240614,,,A*4A|01.4|00.7|01.2|000001000000|20140624070417|14152859|04510000|00030479|0000|1.2539|0746||8414[0x0D][0x0A] | |
[6/24/20 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
07-10 18:03:55.084: E/dalvikvm(2479): Could not find class 'org.mapsforge.map.android.view.MapView', referenced from method com.mapjack.BasicMapViewer.createLayerManagers | |
07-10 18:03:55.084: W/dalvikvm(2479): VFY: unable to resolve check-cast 107 (Lorg/mapsforge/map/android/view/MapView;) in Lcom/mapjack/BasicMapViewer; | |
07-10 18:03:55.084: D/dalvikvm(2479): VFY: replacing opcode 0x1f at 0x0011 | |
07-10 18:03:55.085: E/dalvikvm(2479): Could not find class 'org.mapsforge.map.model.MapViewPosition', referenced from method com.mapjack.BasicMapViewer.createLayers | |
07-10 18:03:55.085: W/dalvikvm(2479): VFY: unable to resolve check-cast 117 (Lorg/mapsforge/map/model/MapViewPosition;) in Lcom/mapjack/BasicMapViewer; | |
07-10 18:03:55.085: D/dalvikvm(2479): VFY: replacing opcode 0x1f at 0x0009 | |
07-10 18:03:55.085: E/dalvikvm(2479): Could not find class 'org.mapsforge.map.android.view.MapView', referenced from method com.mapjack.BasicMapViewer.createMapViewPositions | |
07-10 18:03:55.085: W/dalvikvm(2479): VFY: unable to resolve |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.File; | |
import java.util.ArrayList; | |
import org.mapsforge.core.model.LatLong; | |
import org.mapsforge.core.model.MapPosition; | |
import org.mapsforge.map.android.AndroidPreferences; | |
import org.mapsforge.map.android.graphics.AndroidGraphicFactory; | |
import org.mapsforge.map.android.graphics.AndroidSvgBitmapStore; | |
import org.mapsforge.map.android.util.AndroidUtil; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[2014-07-11 09:16:18 - Dex Loader] Unable to execute dex: Multiple dex files define Lorg/mapsforge/core/graphics/Align; | |
[2014-07-11 09:16:18 - Mapjack] Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define Lorg/mapsforge/core/graphics/Align; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.mapper; | |
import android.support.v7.app.ActionBarActivity; | |
import android.os.Bundle; | |
import android.view.Menu; | |
import android.view.MenuItem; | |
public class MainActivity extends ActionBarActivity { | |
@Override |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
#this is a series of scripts to help in testing ODK Aggregate requests | |
print "Beggining of processing" | |
#we begin testing to see if we can get odk forms | |
url = 'http://localhost:8080/ODKAggregate/formUpload' | |
files = {'form_def_file': open('/Downloads/Birds.xml', 'rb'),'test': 'test'} | |
r = requests.post(url, files=files) | |
import pdb;pdb.set_trace() | |
print r.status_code | |
~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Jul 21, 2014 1:00:50 PM org.opendatakit.common.persistence.engine.mysql.DatastoreImpl deleteEntity | |
INFO: Executing DELETE FROM `odk_prod`.`_task_lock` WHERE `_URI` = ? with key e791d825-0f10-494f-abdc-34eb9714f6e9 by user anonymousUser | |
Jul 21, 2014 1:00:50 PM org.apache.catalina.core.StandardWrapperValve invoke | |
SEVERE: Servlet.service() for servlet upload threw exception | |
java.lang.IllegalArgumentException: unexpected null values passed into method | |
at org.opendatakit.common.datamodel.BinaryContentManipulator.setValueFromByteArray(BinaryContentManipulator.java:536) | |
at org.opendatakit.aggregate.form.Form.setXFormMediaFile(Form.java:671) | |
at org.opendatakit.aggregate.parser.FormParserForJavaRosa.guardedInitHelper(FormParserForJavaRosa.java:444) | |
at org.opendatakit.aggregate.parser.FormParserForJavaRosa.initHelper(FormParserForJavaRosa.java:236) | |
at org.opendatakit.aggregate.parser.FormParserForJavaRosa.<init>(FormParserForJavaRosa.java:148) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
from requests.auth import HTTPDigestAuth | |
#this is a series of scripts to help in testing ODK Aggregate requests | |
print "Beggining of processing" | |
#we begin testing to see if we can get odk forms | |
r = requests.get('https://promisetracker.appspot.com/formList') | |
#lets perfom and ODK authentication | |
#url = 'http://localhost:8080/ODKAggregate/formUpload' | |
url = 'https://promisetracker.appspot.com/formUpload' | |
files = {'form_def_file': open('/Users/jude/Downloads/Birds.xml', 'rb')} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def addSubmissions(submission_data,media_files) | |
submission_post_url = URI.join(@url,"submission") | |
#params = { :xml_submission_file => File.open(submission_data), :datafile => media_files.select { |f| File.file?(f) }.map { |f| File.open(f) }} | |
#params = {:xml_submission_file => File.open(submission_data)} | |
mediafiles = [] | |
x = Hash.new{|hsh,key| hsh[key] = [] } | |
#media_files.each { |file| mediafiles[:datafile] = File.open(file) } | |
media_files.each do|file| | |
#x['datafile'].push File.open(file) | |
#mediafiles.push(File.open(file)) |