Skip to content

Commit 3f4643f

Browse files
Release 2.0.48
1 parent c68aff4 commit 3f4643f

6 files changed

+100
-77
lines changed

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
<a href="../../../../pages/adoption/predix-machine-template-adapter-pi/javadocs/index.html" target="_blank" >
1+
<a href="http://predixdev.github.io/predix-machine-template-adapter-pi/javadocs/index.html" target="_blank" >
22
<img height="50px" width="100px" src="images/javadoc.png" alt="view javadoc"></a>
33
&nbsp;
4-
<a href="../../../../pages/adoption/predix-machine-template-adapter-pi" target="_blank">
4+
<a href="http://predixdev.github.io/predix-machine-template-adapter-pi" target="_blank">
55
<img height="50px" width="100px" src="images/pages.jpg" alt="view github pages">
66
</a>
77

@@ -13,4 +13,4 @@ The adapter reads the data from sensors using the GrovePi api for Raspberry Pi.
1313

1414
Additional info on the GrovePi apis can be found <a href="https://github.com/emoranchel/IoTDevices">here</a>
1515

16-
[![Analytics](https://ga-beacon.appspot.com/UA-82773213-1/predix-machine-template-adapter-pi/readme?pixel)](https://github.com/PredixDev)
16+
[![Analytics](https://predix-beacon.appspot.com/UA-82773213-1/predix-machine-template-adapter-pi/readme?pixel)](https://github.com/PredixDev)

config/com.ge.dspmicro.hoover.spillway-0.config

100755100644
File mode changed.

pom.xml

+56-53
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,23 @@
33
<modelVersion>4.0.0</modelVersion>
44
<groupId>com.ge.predix.solsvc</groupId>
55
<artifactId>predix-machine-template-adapter-pi</artifactId>
6-
<version>2.0.47</version>
6+
<version>2.0.48</version>
77
<packaging>bundle</packaging>
8-
8+
<name>Predix Machine Adapter for Grove Pi</name>
9+
910
<properties>
10-
<com.scireum.parsii.version>2.3</com.scireum.parsii.version>
11-
<!-- Project Properties -->
12-
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
11+
<com.scireum.parsii.version>2.3</com.scireum.parsii.version>
12+
<!-- Jackson -->
13+
<jackson.core-asl.version>1.9.13</jackson.core-asl.version>
14+
<jackson.jaxrs.version>1.9.13</jackson.jaxrs.version>
15+
<jackson.mapper-asl.version>1.9.13</jackson.mapper-asl.version>
16+
1317
<maven.compiler.source>1.8</maven.compiler.source>
14-
<maven.compiler.target>1.8</maven.compiler.target>
15-
16-
<!-- Maven Properties -->
18+
<maven.compiler.target>1.8</maven.compiler.target>
19+
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
20+
<maven.compiler.source.version>1.8</maven.compiler.source.version>
21+
<maven.compiler.target.version>1.8</maven.compiler.target.version>
22+
1723
<clover.bundle.import />
1824
<maven-dependency-plugin.version>2.10</maven-dependency-plugin.version>
1925
<maven.archetype.archetype-packaging.version>2.4</maven.archetype.archetype-packaging.version>
@@ -31,7 +37,7 @@
3137
<org.slf4j.version>1.7.21</org.slf4j.version>
3238

3339
<!-- This actually drives the BND used during compile time. The version of this plugin will map to a version of BND -->
34-
<org.apache.felix.maven-bundle-plugin.version>3.0.1</org.apache.felix.maven-bundle-plugin.version>
40+
<org.apache.felix.maven-bundle-plugin.version>3.5.0</org.apache.felix.maven-bundle-plugin.version>
3541

3642
<!-- 3rd Party Compile-Dependency Bundle versions -->
3743
<org.osgi.core.version>5.0.0</org.osgi.core.version>
@@ -135,7 +141,6 @@
135141

136142
<import.org.codehaus.jackson>"[1.9,2)"</import.org.codehaus.jackson>
137143
<import.org.codehaus.jackson.map>"[1.9,2)"</import.org.codehaus.jackson.map>
138-
<import.org.codehaus.jackson.type>"[1.9,2)"</import.org.codehaus.jackson.type>
139144
<import.org.codehaus.jackson.map.annotate>"[1.9,2)"</import.org.codehaus.jackson.map.annotate>
140145

141146
<import.com.prosyst.util.encode>"[2.1,3)"</import.com.prosyst.util.encode>
@@ -200,8 +205,14 @@
200205
<import.com.ge.predixmachine.datamodel.datacomm>"[1.0,2.0)"</import.com.ge.predixmachine.datamodel.datacomm>
201206
<import.com.ge.predixmachine.datamodel.defaultcomm>"[1.0,2.0)"</import.com.ge.predixmachine.datamodel.defaultcomm>
202207
<import.com.ge.predixmachine.datamodel.gateway>"[1.1,2.0)"</import.com.ge.predixmachine.datamodel.gateway>
203-
<import.com.ge.predixmachine.datamodel.event>"[1.0,2.0)"</import.com.ge.predixmachine.datamodel.event>
204-
</properties>
208+
<import.com.ge.predixmachine.datamodel.event>"[1.0,2.0)"</import.com.ge.predixmachine.datamodel.event>
209+
210+
211+
<import.org.codehaus.jackson>"[1.9,2)"</import.org.codehaus.jackson>
212+
<import.org.codehaus.jackson.map>"[1.9,2)"</import.org.codehaus.jackson.map>
213+
<import.org.codehaus.jackson.type>"[1.9,2)"</import.org.codehaus.jackson.type>
214+
<import.org.codehaus.jackson.map.annotate>"[1.9,2)"</import.org.codehaus.jackson.map.annotate>
215+
</properties>
205216
<dependencies>
206217

207218
<!-- OSGi -->
@@ -226,6 +237,18 @@
226237
<scope>provided</scope>
227238
</dependency>
228239

240+
<!-- Jackson apis -->
241+
<dependency>
242+
<groupId>org.codehaus.jackson</groupId>
243+
<artifactId>jackson-core-asl</artifactId>
244+
<version>${jackson.core-asl.version}</version>
245+
</dependency>
246+
<dependency>
247+
<groupId>org.codehaus.jackson</groupId>
248+
<artifactId>jackson-mapper-asl</artifactId>
249+
<version>${jackson.mapper-asl.version}</version>
250+
</dependency>
251+
229252
<!-- Predix Machine -->
230253
<dependency>
231254
<groupId>com.ge.dspmicro</groupId>
@@ -266,33 +289,15 @@
266289
<artifactId>protobuf-java-util</artifactId>
267290
<version>${com.google.protobuf.version}</version>
268291
</dependency>
292+
269293
<!-- DS Annotation Dependency -->
270294
<dependency>
271295
<groupId>biz.aQute.bnd</groupId>
272296
<artifactId>biz.aQute.bndlib</artifactId>
273297
<version>${biz.aQute.bndlib.version}</version>
274298
<scope>compile</scope>
275299
</dependency>
276-
277-
278-
<!-- Jackson apis -->
279-
<dependency>
280-
<groupId>org.codehaus.jackson</groupId>
281-
<artifactId>jackson-core-asl</artifactId>
282-
<version>${jackson.core-asl.version}</version>
283-
</dependency>
284-
<dependency>
285-
<groupId>org.codehaus.jackson</groupId>
286-
<artifactId>jackson-mapper-asl</artifactId>
287-
<version>${jackson.mapper-asl.version}</version>
288-
</dependency>
289-
290-
<dependency>
291-
<groupId>javax.ws.rs</groupId>
292-
<artifactId>javax.ws.rs-api</artifactId>
293-
<version>${javax.ws.rs.version}</version>
294-
</dependency>
295-
300+
296301
<!-- Pi Dependencies -->
297302
<dependency>
298303
<groupId>org.iot.raspberry</groupId>
@@ -342,17 +347,13 @@
342347
<plugin>
343348
<groupId>org.apache.felix</groupId>
344349
<artifactId>maven-bundle-plugin</artifactId>
350+
<version>${org.apache.felix.maven-bundle-plugin.version}</version>
345351
<extensions>true</extensions>
346352
<configuration>
347353
<instructions>
348354
<_noee>true</_noee>
349-
<Include-Resource>
350-
pi4j-core-1.1.jar
351-
</Include-Resource>
352355
<Bundle-SymbolicName>${project.groupId}.${project.artifactId}</Bundle-SymbolicName>
353356
<Bundle-Version>${project.version}</Bundle-Version>
354-
<Embed-Dependency></Embed-Dependency>
355-
<Bundle-Classpath></Bundle-Classpath>
356357
<Bundle-Classpath>
357358
.,pi4j-core-1.1.jar,
358359
GrovePi-spec-0.1.0.jar,
@@ -389,23 +390,25 @@
389390
</configuration>
390391
</plugin>
391392
<plugin>
392-
<groupId>org.apache.maven.plugins</groupId>
393-
<artifactId>maven-dependency-plugin</artifactId>
394-
<version>${maven-dependency-plugin.version}</version>
395-
<configuration>
396-
<artifactItems>
397-
<artifactItem>
398-
<groupId>${project.groupId}</groupId>
399-
<artifactId>${project.artifactId}</artifactId>
400-
<version>${project.version}</version>
401-
<overWrite>true</overWrite>
402-
<outputDirectory>${project.build.directory}</outputDirectory>
403-
</artifactItem>
404-
</artifactItems>
405-
</configuration>
406-
</plugin>
393+
<groupId>org.apache.maven.plugins</groupId>
394+
<artifactId>maven-compiler-plugin</artifactId>
395+
<version>${maven.plugins.maven-compiler-plugin.version}</version>
396+
<configuration>
397+
<source>${maven.compiler.source.version}</source>
398+
<target>${maven.compiler.target.version}</target>
399+
</configuration>
400+
</plugin>
401+
<plugin>
402+
<groupId>org.apache.maven.plugins</groupId>
403+
<artifactId>maven-assembly-plugin</artifactId>
404+
<version>${maven.plugins.maven-assembly-plugin.version}</version>
405+
</plugin>
406+
<plugin>
407+
<groupId>org.apache.maven.plugins</groupId>
408+
<artifactId>maven-jarsigner-plugin</artifactId>
409+
<version>${maven.plugins.maven-jarsigner-plugin.version}</version>
410+
</plugin>
407411
</plugins>
408412
</build>
409413

410-
411414
</project>

scripts/quickstart-machine-pi.bat

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ IF [!BRANCH!]==[] (
3131
EXIT /b 1
3232
)
3333

34-
SET IZON_BAT=https://raw.githubusercontent.com/PredixDev/izon/master/izon.bat
34+
SET IZON_BAT=https://raw.githubusercontent.com/PredixDev/izon/1.3.0/izon.bat
3535
SET TUTORIAL=https://www.predix.io/resources/tutorials/journey.html#1752
3636
SET REPO_NAME=predix-machine-template-adapter-pi
3737
SET SHELL_SCRIPT_NAME=quickstart-machine-pi.sh

scripts/quickstart-machine-pi.sh

+32-10
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
#!/bin/bash
22
set -e
3+
4+
SKIP_PREDIX_SERVICES=0
5+
36
function local_read_args() {
47
while (( "$#" )); do
58
opt="$1"
@@ -14,6 +17,9 @@ function local_read_args() {
1417
QUICKSTART_ARGS+=" $1 $2"
1518
shift
1619
;;
20+
-skip-predix-services|--skip-predix-services)
21+
SKIP_PREDIX_SERVICES=1
22+
;;
1723
-o|--override)
1824
QUICKSTART_ARGS=" $SCRIPT"
1925
;;
@@ -34,25 +40,37 @@ function local_read_args() {
3440
fi
3541
}
3642

43+
# default settings
3744
BRANCH="master"
3845
PRINT_USAGE=0
3946
SKIP_SETUP=false
47+
48+
IZON_SH="https://raw.githubusercontent.com/PredixDev/izon/1.1.0/izon2.sh"
4049
#ASSET_MODEL="-amrmd predix-ui-seed/server/sample-data/predix-asset/asset-model-metadata.json predix-ui-seed/server/sample-data/predix-asset/asset-model.json"
4150
SCRIPT="-script build-basic-app.sh -script-readargs build-basic-app-readargs.sh"
42-
QUICKSTART_ARGS="-ba -uaa -asset -ts -wd -nsts -mc $SCRIPT"
4351
REPO_NAME=predix-machine-template-adapter-pi
4452
VERSION_JSON="version.json"
4553
PREDIX_SCRIPTS=predix-scripts
4654
VERSION_JSON="version.json"
4755
APP_DIR="edge-raspberry-pi"
4856
APP_NAME="Edge Starter: Predix Machine for Raspberry Pi"
57+
SCRIPT_NAME="quickstart-machine-pi.sh"
58+
GITHUB_RAW="https://raw.githubusercontent.com/PredixDev"
4959
TOOLS="Cloud Foundry CLI, Git, Maven, Node.js, Predix CLI"
5060
TOOLS_SWITCHES="--cf --git --maven --nodejs --predixcli"
5161

62+
if [[ $SKIP_PREDIX_SERVICES == 1 ]]; then
63+
QUICKSTART_ARGS="-mc $SCRIPT"
64+
else
65+
QUICKSTART_ARGS="-uaa -asset -ts -wd -nsts -mc $SCRIPT"
66+
fi
67+
68+
# Process switches
5269
local_read_args $@
53-
IZON_SH="https://raw.githubusercontent.com/PredixDev/izon/$BRANCH/izon.sh"
54-
VERSION_JSON_URL=https://raw.githubusercontent.com/PredixDev/$REPO_NAME/$BRANCH/version.json
5570

71+
#variables after processing switches
72+
SCRIPT_LOC="$GITHUB_RAW/$REPO_NAME/$BRANCH/scripts/$SCRIPT_NAME"
73+
VERSION_JSON_URL="$GITHUB_RAW/$REPO_NAME/$BRANCH/version.json"
5674

5775
function check_internet() {
5876
set +e
@@ -75,19 +93,23 @@ function init() {
7593
echo 'Please launch the script from the root dir of the project'
7694
exit 1
7795
fi
78-
if [[ ! $currentDir == *"$REPO_NAME" ]]; then
79-
mkdir -p $APP_DIR
80-
cd $APP_DIR
81-
fi
8296

8397
check_internet
8498

8599
#get the script that reads version.json
100+
echo "ISON : $IZON_SH"
86101
eval "$(curl -s -L $IZON_SH)"
87102

88-
getVersionFile
89-
getLocalSetupFuncs
103+
#download script and cd
104+
getUsingCurl $SCRIPT_LOC
105+
chmod 755 $SCRIPT_NAME;
106+
if [[ ! $currentDir == *"$REPO_NAME" ]]; then
107+
mkdir -p $APP_DIR
108+
cd $APP_DIR
109+
fi
90110

111+
getVersionFile
112+
getLocalSetupFuncs $GITHUB_RAW
91113
}
92114

93115
if [[ $PRINT_USAGE == 1 ]]; then
@@ -143,7 +165,7 @@ echo "We installed some Intel API jar files that represent the Intel mraa and up
143165
echo "We built and deployed the Machine Adapter bundle which reads from the Intel API" >> "$SUMMARY_TEXTFILE"
144166
echo "" >> "$SUMMARY_TEXTFILE"
145167
echo "The Predix Machine is in 2 places. 1. where this script prepared the Predix Machine. 2. Where this script copied the compressed version to." >> "$SUMMARY_TEXTFILE"
146-
echo "You can go to location 2, back up any older copies of Predix Machine (if desired) and tar -xvzf Predix Machine and launch it there. " >> "$SUMMARY_TEXTFILE"
168+
echo "You can go to location 2, back up any older copies of Predix Machine and tar -xvzf Predix Machine and launch it there. " >> "$SUMMARY_TEXTFILE"
147169
echo "Or you can now start Machine at location 1 as follows" >> "$SUMMARY_TEXTFILE"
148170
echo "cd $PREDIX_MACHINE_HOME/machine/bin/predix" >> "$SUMMARY_TEXTFILE"
149171
echo "./start_container.sh clean" >> "$SUMMARY_TEXTFILE"

version.json

+8-10
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,15 @@
11
{
22
"name": "Predix Machine Adapter for Raspberry Pi",
3-
"version": "1.1.177",
3+
"version": "2.0.48",
44
"private": true,
55
"dependencies": {
6-
"local-setup": "https://github.com/PredixDev/local-setup#1.0.79",
7-
"Predix-HelloWorld-WebApp": "https://github.com/PredixDev/Predix-HelloWorld-WebApp#1.1.134",
8-
"predix-nodejs-starter": "https://github.com/PredixDev/predix-nodejs-starter#1.1.155",
9-
"predix-machine-container-url": "https://raw.githubusercontent.com/PredixDev/predix-machine-templates/master/PredixMachineDebug-16.4.2.zip#",
10-
"predix-machine-template-processor": "https://github.com/PredixDev/predix-machine-template-processor#2.2.13",
11-
"predix-machine-template-adapter-pi": "https://github.com/PredixDev/predix-machine-template-adapter-pi#",
12-
"predix-machine-templates": "https://github.com/PredixDev/predix-machine-templates#1.1.29",
13-
"predix-scripts": "https://github.com/PredixDev/predix-scripts#1.1.124",
14-
"winddata-timeseries-service": "https://github.com/PredixDev/winddata-timeseries-service#2.0.53"
6+
"local-setup": "https://github.com/PredixDev/local-setup#1.0.106",
7+
"Predix-HelloWorld-WebApp": "https://github.com/PredixDev/Predix-HelloWorld-WebApp#1.1.150",
8+
"predix-nodejs-starter": "https://github.com/PredixDev/predix-nodejs-starter#1.1.168",
9+
"predix-machine-template-processor": "https://github.com/PredixDev/predix-machine-template-processor#2.2.15",
10+
"predix-machine-template-adapter-pi": "https://github.com/PredixDev/predix-machine-template-adapter-pi#2.0.48",
11+
"predix-scripts": "https://github.com/PredixDev/predix-scripts#1.1.217",
12+
"winddata-timeseries-service": "https://github.com/PredixDev/winddata-timeseries-service#2.0.61"
1513
},
1614
"author": "rishabhtulsian,swapnavad,susheelchoudhari"
1715
}

0 commit comments

Comments
 (0)