Skip to content
Permalink
Browse files

Fixes for 2.6.1

Changes to test files for Turbos to test low kph.
  • Loading branch information
davidzof committed Nov 13, 2015
1 parent 3545f49 commit 96f34aa7dbbfdc4d6e5f0b4be9641daf7612ac66
Showing with 387 additions and 217 deletions.
  1. +2 −2 build-osx.xml
  2. +1 −0 properties/MessageBundle_de.properties
  3. +1 −2 properties/MessageBundle_en.properties
  4. +1 −0 properties/MessageBundle_es.properties
  5. +1 −0 properties/MessageBundle_fr.properties
  6. +1 −0 properties/MessageBundle_hu.properties
  7. +1 −2 properties/MessageBundle_nl.properties
  8. +7 −7 properties/log4j.properties
  9. +17 −0 runmac.sh
  10. +11 −0 src/com/wattzap/Main.java
  11. +2 −2 src/com/wattzap/MenuBar.java
  12. +15 −22 src/com/wattzap/model/RLVReader.java
  13. +62 −56 src/com/wattzap/model/TTSReader.java
  14. +13 −3 src/com/wattzap/model/UserPreferences.java
  15. +20 −18 src/com/wattzap/model/ant/DummySpeedCadenceListener.java
  16. +0 −3 src/com/wattzap/model/ant/PowerListener.java
  17. +2 −2 src/com/wattzap/model/power/CyclopsFluid2.java
  18. +68 −0 src/com/wattzap/model/power/TacxGeniusSmart.java
  19. +61 −56 src/com/wattzap/view/MainFrame.java
  20. +2 −1 src/com/wattzap/view/Odometer.java
  21. +5 −5 src/com/wattzap/view/prefs/TurboPanel.java
  22. +1 −1 test/com/wattzap/model/power/AscentFluidTest.java
  23. +2 −2 test/com/wattzap/model/power/BlackburnFluidTest.java
  24. +2 −2 test/com/wattzap/model/power/CascadeFluidProTest.java
  25. +2 −2 test/com/wattzap/model/power/CatEyeCS1000Test.java
  26. +2 −2 test/com/wattzap/model/power/CyclopsFluid2Test.java
  27. +2 −2 test/com/wattzap/model/power/CyclopsJetFluidProTest.java
  28. +2 −2 test/com/wattzap/model/power/EliteChronoHydroMagTest.java
  29. +2 −2 test/com/wattzap/model/power/EliteQuboFluidTest.java
  30. +2 −2 test/com/wattzap/model/power/KineticRoadMachineTest.java
  31. +2 −2 test/com/wattzap/model/power/SportCraftersOmniumTest.java
  32. +58 −0 test/com/wattzap/model/power/TacxGeniusSmartTest.java
  33. +1 −1 test/com/wattzap/utils/StringXORerTest.java
  34. +16 −16 trainings/SufferFest/Fight Club.pwr
@@ -6,8 +6,8 @@
<property name="src" location="src"/>
<property name="build" location="dist-mac/bin"/>
<property name="dist" location="dist-mac"/>
<!-- ***** Change this to point to your JDK ***** -->
<property name="javadir" location="/home/david/bin/jdk1.6.0_45"/>
<!-- changed to likely location of Java 1.6 on OSX -->
<property name="javadir" location="/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home"/>

<path id="master-classpath">
<fileset dir="lib">
@@ -83,6 +83,7 @@ qpow=Kraft quadratische
quadAnal=Analyse quadratische
quit=Abbrechen
reanal=Neu analysieren
reset=Factory Reset
recover=Retten
resistance=Widerstände
rideSum=Fahrt Zusammenfassung
@@ -1,5 +1,3 @@


1minftp=One minute estimated FTP
1minpow=One Minute Power
20minftp=Twenty minute estimated FTP
@@ -70,6 +68,7 @@ qpow=Quadratic Power
quadAnal=Quadrant Analysis
quit=Quit
reanal=Reanalyze
reset=Factory Reset
recover=Recover
resistance=Resistance
rideSum=Ride Summary
@@ -71,6 +71,7 @@ quadAnal=Quadrant Analysis
quit=Quit
reanal=Reanalyze
recover=Recover
reset=Factory Reset
resistance=Resistance
rideSum=Ride Summary
route=Route
@@ -69,6 +69,7 @@ quadAnal=Analyse quadratique
quit=Quitter
reanal=Analyser à nouveau
recover=Récupérer
reset=Réinitialisation
resistance=Résistance
rideSum=Recaputalif d'entraînement
route=Parcours
@@ -71,6 +71,7 @@ quadAnal=Quadrant Analysis
quit=Quit
reanal=Reanalyze
recover=Recover
reset=Reset
resistance=Resistance
rideSum=Ride Summary
route=Route
@@ -1,5 +1,3 @@


1minftp=One minute estimated FTP
1minpow=One Minute Power
20minftp=Twenty minute estimated FTP
@@ -71,6 +69,7 @@ quadAnal=Quadrant Analysis
quit=Quit
reanal=Reanalyze
recover=Recover
reset=Reset
resistance=Resistance
rideSum=Ride Summary
route=Route
@@ -2,16 +2,16 @@
#define repository wide threshold

#define root logger
#log4j.rootLogger=DEBUG,A1
log4j.rootLogger=ERROR,console
log4j.rootLogger=DEBUG,A1
#log4j.rootLogger=ERROR,console

#define Appenders
#log4j.appender.A1=com.omniscient.log4jcontrib.swingappender.SwingAppender
#log4j.appender.A1.layout=org.apache.log4j.PatternLayout
#log4j.appender.A1.layout.ConversionPattern=%r [%t] %p %c %x %m%n
log4j.appender.A1=com.omniscient.log4jcontrib.swingappender.SwingAppender
log4j.appender.A1.layout=org.apache.log4j.PatternLayout
log4j.appender.A1.layout.ConversionPattern=%r [%t] %p %c %x %m%n

#define any non root loggers

# Define Console Appender
log4j.appender.console=org.apache.log4j.ConsoleAppender
log4j.appender.console.layout=org.apache.log4j.PatternLayout
#log4j.appender.console=org.apache.log4j.ConsoleAppender
#log4j.appender.console.layout=org.apache.log4j.PatternLayout
@@ -0,0 +1,17 @@
#!/bin/bash
#
# WattzAp Linux Startup File
# 6th May 2015
#
SEP=":"
LIBS=$(find lib -maxdepth 1 -name "*.jar" -print | tr '\n' ':')
LIBS="lib:properties:$LIBS"
JAVABIN="/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/bin/java"

export VLC_PLUGIN_PATH=/Applications/VLC.app/Contents/MacOS/plugins

#echo $LIBS

$JAVABIN -Djna.library.path=/Applications/VLC.app/Contents/MacOS/lib -cp $LIBS -Dlog4j.logger.level=INFO com.wattzap.Main
#java -Djna.library.path=/Applications/VLC.app/Contents/MacOS/lib -cp $LIBS com.wattzap.Main

@@ -19,6 +19,7 @@
import java.awt.Container;
import java.awt.Dimension;
import java.awt.EventQueue;
import java.awt.Rectangle;
import java.awt.Toolkit;
import java.io.IOException;
import java.util.HashMap;
@@ -88,6 +89,16 @@ public static void main(String[] args) {
// TODO Auto-generated catch block
e1.printStackTrace();
} // create appender


if (args.length > 0) {
for (String s: args) {
if ("-R".equals(s)) {
UserPreferences.INSTANCE.factoryReset();
}
}
}


// Turn on Debug window
if (userPrefs.isDebug()) {
@@ -43,7 +43,7 @@
* Externalize menu setup to this class. Registers for Locale change messages so
* we can reinitialize text when language changes.
*
* (c) 2014 David George / Wattzap.com
* (c) 2014-2015 David George / Wattzap.com
*
* @author David George
* @date 25 November 2014
@@ -87,7 +87,7 @@ public MenuBar(MainFrame frame) {
// TODO - choose between OS and non OS edtion
AboutPanel about = new AboutPanel();
aboutMenuItem.addActionListener(about);

quitMenuItem = new JMenuItem();
quitMenuItem.setAccelerator(KeyStroke.getKeyStroke('Q', Toolkit
.getDefaultToolkit().getMenuShortcutKeyMask(), false));
@@ -457,20 +457,12 @@ public void close() {
}

private final ArrayList<Point> readPGMF(String fileName) {

ArrayList<Point> p = new ArrayList<Point>();
maxPower = 0f;
DataInputStream din = null;

try {
// create FileInputStream object
FileInputStream fin = new FileInputStream(fileName);

/*
* To create DataInputStream object, use DataInputStream(InputStream
* in) constructor.
*/

DataInputStream din = new DataInputStream(fin);
din = new DataInputStream(new FileInputStream(fileName));

/*
* To read a Java short primitive from file, use byte readShort()
@@ -514,6 +506,14 @@ public void close() {
throw new RuntimeException("No PGMF file found for ");
} catch (IOException ioe) {
logger.error("IOException : " + ioe);
} finally {
try {
if (din != null) {
din.close();
}
} catch (IOException e) {
logger.error("IOException : " + e);
}
}

return p;
@@ -700,15 +700,7 @@ private void readPGMFInfo(DataInputStream din) throws IOException {
DataInputStream din = null;

try {
// create FileInputStream object
FileInputStream fin = new FileInputStream(file);

/*
* To create DataInputStream object, use DataInputStream(InputStream
* in) constructor.
*/

din = new DataInputStream(fin);
din = new DataInputStream(new FileInputStream(file));

/*
* To read a Java short primitive from file, use byte readShort()
@@ -756,10 +748,11 @@ private void readPGMFInfo(DataInputStream din) throws IOException {
logger.error("IOException : " + ioe);
} finally {
try {
din.close();
if (din != null) {
din.close();
}
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
logger.error("IOException : " + e);
}
}

0 comments on commit 96f34aa

Please sign in to comment.
You can’t perform that action at this time.