-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathtemporary.txt
62 lines (51 loc) · 2.42 KB
/
temporary.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
Ionic Starter App
================================================================================
cordova-plugin-geolocation
https://github.com/apache/cordova-plugin-geolocation
ionic platform add android
ionic serve browser
ionic run browser
export ANDROID_HOME=/home/sergio/Android/Sdk
export JAVA_HOME=/usr/lib64/jvm/java-1.8.0-openjdk-1.8.0/
$ ionic build android
chrome://inspect/#devices
Error: No emulator images (avds) found.
1. Download desired System Image by running: /home/sergio/Android/Sdk/tools/android sdk
2. Create an AVD by running: /home/sergio/Android/Sdk/tools/android avd
HINT: For a faster emulator, use an Intel System Image and install the HAXM device driver
$ ionic emulate android
$ ionic run android -l
~/Android/Sdk/platform-tools $ ./adb logcat chromium:D *:S
~/Android/Sdk/platform-tools $ ./adb logcat CordovaLog:D *:S
# MQTT Section (Mosquitto.org)
================================================================================
Publish: $ mosquitto_pub -h test.mosquitto.org -r -t jagt/u1 -m "{\"lat\": 37.422, \"lng\": -122.084}" -q 1
Subscribe: $ mosquitto_sub -h test.mosquitto.org -t "jagt/#" -v
Subscribe: $ mosquitto_sub -h test.mosquitto.org -t "#" -v
Subscribe: $ mosquitto_sub -h broker.hivemq.com -t "#" -v
cryptico library (Private and Public keys)
================================================================================
https://www.npmjs.com/package/cryptico
sudo zypper in nodejs npm
sudo npm install -g cordova ionic [bower] <- bower not necessary for now
cordova telemetry on <- to avoid an error in the future
ionic start jagt sidemenu --v1
ionic platform add android
ionic platform add browser <- not necessary. All the dev tests using android device
ionic run browser <- test if ok
cordova plugin add cordova-plugin-mqtt
bower install ngCordova <- not necessary
index.html
<script src="lib/ngCordova/dist/ng-cordova.js"></script>
<script src="cordova.js"></script>
app.js
angular.module('starter', ['ionic', 'ngCordova'])
cordova plugin add cordova-plugin-geolocation <- not necessary
cordova plugin add cordova-plugin-mauron85-background-geolocation
index.html
<script src="js/app.js"></script>
<script src="http://maps.google.com/maps/api/js?key=YOUR_API_KEY_GOES_HERE&sensor=true"></script> <- not necessary API key
<script src="http://maps.google.com/maps/api/js"></script>
style.css
.scroll { height: 100%; }
#map { width: 100%; height: 100%; }