Tell us if this application works or not

2007-08-21
2013-05-02
<< < 1 2 3 4 > >> (Page 2 of 4)
  • Levien van Zon

    Levien van Zon - 2007-10-16

    I *finally* managed to get BT747 to work on a Mac over USB.

    I used the CP2101 USB serial driver for MacOS X from this site:
    http://www.silabs.com/tgwWebApp/public/web_content/products/Microcontrollers/USB/en/mcu_vcp.htm

    Before it works, you need to create a lock-file directory, and make it world-writable. Open a shell, and type:

    sudo mkdir /var/lock
    sudo chmod 777 /var/lock

    I downloaded the BT747 distribution, and copied BT747_rxtx.jar to /Applications/gps, the RXTX lib and binaries for MacOS to /Applications/gps/rxtx, the superwaba stuff to /Applications/gps/webstart, and created a shell script to launch the program. My folder /Applications/gps now contains these files:

    BT747_rxtx.jar
    bt747.command
    rxtx/librxtxSerial.jnilib
    rxtx/README
    rxtx/RXTXcomm.jar
    webstart/comm.jar
    webstart/RXTXcomm.jar
    webstart/Waba_only.jar

    The script "bt747.command" can be created using TextEdit, and looks like this:

    #!/bin/bash
    cd /Applications/gps
    CLASSPATH=rxtx/RXTXcomm.jar:webstart/Waba_only.jar:BT747_rxtx.jar:.:$CLASSPATH
    export CLASSPATH
    java -Djava.library.path=rxtx/ -Dbt747_port="/dev/cu.SLAB_USBtoUART" waba.applet.Applet /w 400 /h 400 /scale 1 /bpp 8 BT747

    Double-clicking on bt747.command from Finder now starts BT747, and everything seems to work just fine! (with the usual download-quirks etc, but no worse than under Windows or Linux)

    -Levien

     
    • Mario De Weerd

      Mario De Weerd - 2007-10-16

      Thanks for the feedback - glad to know that it does work on mac!

      No I need to add a sample script and something in the readme.  I updated the wiki to point to your post.

       
    • Mario De Weerd

      Mario De Weerd - 2007-11-18

      Another MacOS user has some trouble (slow responsiveness of the application V1.12) on a Mac machine:

      Could have something to do with his setup being different????  Would it be possible to compare with this:

      MacBook OS 10.4.11
      java version "1.5.0_06"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_06-112)
      Java HotSpot(TM) Client VM (build 1.5.0_06-64, mixed mode, sharing)

       
      • Dirk Haase

        Dirk Haase - 2007-11-18

        I have also a Mac now, with MacOS 10.4.11, i will test it next week. Tell the user that (s)he should try the web-version from the Wiki. I have get good results with this way under windows. If there are missing java-files, the web-version will install them.

         
        • Dirk Haase

          Dirk Haase - 2007-11-25

          First, i don't get it work bt747. Or better i don't know wich serial port i should select. I installed the driver for usb-serial-interface. Under Windows i can look into the device manager to see wich com-port is used for the interface. Until now i don't found this information under MacOS 10.4.11.

          But i can confirm that the Ui of bt747 react very slowly under MacOS 10.4.11. I try it in VMWare Fusion with XP Home - normal using is possible.

           
          • Mario De Weerd

            Mario De Weerd - 2007-11-25

            It is very annoying that it is slow on some MacOS systems.

            I've found a way that may help us to find out why.

            On windows, I can launch the application as follows and get information on CPU usage for each function.

            java -agentlib:hprof=cpu=samples,interval=5,lineno=y,file=java.hprof.txt waba.applet.Applet  /w 320 /h 320 /scale 1 /bpp 8 BT74

            If you could do this and then send me the log, I might get some idea about the problem.  To study the interface problem, a log without connecting, but while doing several interface operations is best.

            Concerning the serial port.  Normally it should be the one described in the 'README' and in the bt747_macosX.command file: /dev/cu.SLAB_USBtoUART .  In principle, you could try a tail or cat this device.  If you get NMEA strings, then this is correct.

             
            • Mario De Weerd

              Mario De Weerd - 2007-11-25

              For your information, here is part of my profiling result on a windows system:

              With connection:

              rank   self  accum   count trace method
                 1 46.81% 46.81%    4902 300485 sun.awt.windows.WToolkit.eventLoop
                 2 44.64% 91.45%    4675 300634 gnu.io.RXTXPort.eventLoop
                 3  2.26% 93.72%     237 300609 sun.java2d.windows.GDIRenderer.doDrawLine
                 4  0.81% 94.53%      85 300626 sun.awt.windows.WGlobalCursorManager.findHeavyweightUnderCursor
                 5  0.46% 94.99%      48 300627 sun.awt.windows.WComponentPeer.nativeHandleEvent
                 6  0.39% 95.38%      41 300640 waba.applet.Queue.push
                 7  0.32% 95.70%      34 300641 java.lang.Thread.currentThread
                 8  0.28% 95.98%      29 300648 sun.awt.windows.WGlobalCursorManager.setCursor
                 9  0.25% 96.23%      26 300643 waba.applet.Queue.push
                10  0.15% 96.38%      16 300716 sun.awt.windows.WToolkit.shutdown
                11  0.14% 96.52%      15 300697 java.io.RandomAccessFile.readBytes
                12  0.13% 96.66%      14 300632 gnu.io.RXTXCommDriver.testRead
                13  0.13% 96.79%      14 300636 java.lang.Object.notify
                14  0.12% 96.92%      13 300650 waba.applet.Queue.push
                15  0.11% 97.03%      12 300684 java.io.WinNTFileSystem.getBooleanAttributes
                16  0.11% 97.14%      12 300633 gnu.io.RXTXPort.open
                17  0.11% 97.25%      11 300647 gnu.io.RXTXPort.nativeavailable
                18  0.11% 97.35%      11 300642 java.lang.Object.notify
                19  0.10% 97.45%      10 300465 sun.awt.windows.WToolkit.init
                20  0.09% 97.54%       9 300696 java.io.RandomAccessFile.open

              Without connection (and clicking inside the GUI):
              rank   self  accum   count trace method
                 1 80.51% 80.51%    1578 300490 sun.awt.windows.WToolkit.eventLoop
                 2  4.54% 85.05%      89 300620 sun.java2d.windows.GDIRenderer.doDrawLine
                 3  2.35% 87.40%      46 300640 sun.awt.windows.WGlobalCursorManager.findHeavyweightUnderCursor
                 4  1.63% 89.03%      32 300639 sun.awt.windows.WComponentPeer.nativeHandleEvent
                 5  0.97% 90.00%      19 300642 sun.awt.windows.WGlobalCursorManager.setCursor
                 6  0.82% 90.82%      16 300670 sun.awt.windows.WToolkit.shutdown
                 7  0.56% 91.38%      11 300633 waba.applet.Queue.push
                 8  0.51% 91.89%      10 300470 sun.awt.windows.WToolkit.init
                 9  0.41% 92.30%       8 300676 java.lang.Shutdown.halt0
                10  0.20% 92.50%       4 300641 java.lang.Object.notify
                11  0.15% 92.65%       3 300634 java.lang.System.currentTimeMillis
                12  0.15% 92.81%       3 300539 sun.awt.windows.WComponentPeer.pShow
                13  0.15% 92.96%       3 300249 java.lang.ClassLoader.defineClass1
                14  0.15% 93.11%       3 300545 sun.awt.windows.WComponentPeer.nativeHandleEvent
                15  0.10% 93.21%       2 300250 java.lang.ClassLoader.findBootstrapClass
                16  0.10% 93.32%       2 300431 sun.awt.Win32GraphicsEnvironment.initDisplay
                17  0.10% 93.42%       2 300653 waba.applet.Queue.push
                18  0.10% 93.52%       2 300652 java.lang.Thread.interrupt0
                19  0.10% 93.62%       2 300491 sun.awt.windows.WFramePeer.createAwtFrame
                20  0.10% 93.72%       2 300542 sun.awt.windows.WComponentPeer.hide
                21  0.10% 93.83%       2 300591 sun.reflect.Reflection.getClassAccessFlags
                22  0.10% 93.93%       2 300649 waba.ui.Label.onPaint
                23  0.10% 94.03%       2 300599 java.math.BigInteger.mulAdd
                24  0.10% 94.13%       2 300349 java.lang.Class.getDeclaredMethods0
                25  0.10% 94.23%       2 300638 java.lang.System.currentTimeMillis
                26  0.10% 94.34%       2 300646 java.lang.System.currentTimeMillis
                27  0.10% 94.44%       2 300645 java.awt.KeyboardFocusManager.getGlobalFocusedWindow
                28  0.10% 94.54%       2 300644 java.awt.KeyboardFocusManager.getCurrentKeyboardFocusManager
                29  0.05% 94.59%       1 300643 sun.awt.AWTAutoShutdown.setToolkitBusy
                30  0.05% 94.64%       1 300013 sun.misc.URLClassPath$JarLoader.parseExtensionsDependencies
                31  0.05% 94.69%       1 300656 java.lang.Object.getClass
                32  0.05% 94.74%       1 300657 java.lang.Object.notifyAll
                33  0.05% 94.80%       1 300658 sun.awt.SunToolkit.wakeupEventQueue
                34  0.05% 94.85%       1 300647 waba.applet.WinTimer.run
                35  0.05% 94.90%       1 300659 waba.ui.Container.paintChildren
                36  0.05% 94.95%       1 300035 sun.misc.Resource.getByteBuffer
                37  0.05% 95.00%       1 300660 java.lang.String.toCharArray
                38  0.05% 95.05%       1 300632 waba.sys.Convert.tokenizeString

               
              • Dirk Haase

                Dirk Haase - 2007-11-25

                Here my result:

                --------

                THREAD START (obj=50000114, id = 200004, name="Signal Dispatcher", group="system")
                THREAD START (obj=50000114, id = 200001, name="main", group="main")
                THREAD END (id = 200001)
                TRACE 300008:
                    java.util.zip.ZipFile.initDBBConstructor(ZipFile.java:124)
                    java.util.zip.ZipFile.newMappedByteBuffer(ZipFile.java:152)
                    java.util.zip.ZipFile.<init>(ZipFile.java:214)
                    java.util.jar.JarFile.<init>(JarFile.java:132)
                TRACE 300029:
                    sun.nio.cs.UTF_8$Decoder.decodeArrayLoop(UTF_8.java:127)
                    sun.nio.cs.UTF_8$Decoder.decodeLoop(UTF_8.java:416)
                    java.nio.charset.CharsetDecoder.decode(CharsetDecoder.java:544)
                    sun.nio.cs.StreamDecoder$CharsetSD.implRead(StreamDecoder.java:445)
                TRACE 300009:
                    java.lang.Class.forName0(Class.java:Unknown line)
                    java.lang.Class.forName(Class.java:164)
                    java.util.zip.ZipFile$1.run(ZipFile.java:127)
                    java.security.AccessController.doPrivileged(AccessController.java:Unknown line)
                TRACE 300022:
                    java.io.InputStreamReader.<init>(InputStreamReader.java:83)
                    sun.misc.JarIndex.read(JarIndex.java:233)
                    sun.misc.JarIndex.<init>(JarIndex.java:67)
                    sun.misc.JarIndex.getJarIndex(JarIndex.java:92)
                TRACE 300019:
                    java.util.zip.Inflater.init(Inflater.java:Unknown line)
                    java.util.zip.Inflater.<init>(Inflater.java:75)
                    java.util.zip.ZipFile.getInflater(ZipFile.java:375)
                    java.util.zip.ZipFile.getInputStream(ZipFile.java:320)
                TRACE 300028:
                    java.util.LinkedList.<init>(LinkedList.java:78)
                    sun.misc.JarIndex.addToList(JarIndex.java:111)
                    sun.misc.JarIndex.read(JarIndex.java:253)
                    sun.misc.JarIndex.<init>(JarIndex.java:67)
                TRACE 300045:
                    sun.misc.Unsafe.defineClass(Unsafe.java:Unknown line)
                    sun.reflect.ClassDefiner.defineClass(ClassDefiner.java:45)
                    sun.reflect.MethodAccessorGenerator$1.run(MethodAccessorGenerator.java:381)
                    java.security.AccessController.doPrivileged(AccessController.java:Unknown line)
                TRACE 300032:
                    java.io.UnixFileSystem.normalize(UnixFileSystem.java:69)
                    java.io.File.<init>(File.java:196)
                    sun.misc.FileURLMapper.exists(FileURLMapper.java:60)
                    sun.misc.URLClassPath$JarLoader.getJarFile(URLClassPath.java:576)
                TRACE 300033:
                    sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:30)
                    sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
                    java.lang.reflect.Constructor.newInstance(Constructor.java:494)
                    java.util.zip.ZipFile.newMappedByteBuffer(ZipFile.java:154)
                TRACE 300006:
                    java.util.jar.JarFile.<clinit>(JarFile.java:52)
                    sun.misc.URLClassPath$JarLoader.getJarFile(URLClassPath.java:579)
                    sun.misc.URLClassPath$JarLoader.<init>(URLClassPath.java:546)
                    sun.misc.URLClassPath$3.run(URLClassPath.java:324)
                CPU SAMPLES BEGIN (total = 21) Sun Nov 25 20:24:35 2007
                rank   self  accum   count trace method
                   1 23.81% 23.81%       5 300008 java.util.zip.ZipFile.initDBBConstructor
                   2 23.81% 47.62%       5 300029 sun.nio.cs.UTF_8$Decoder.decodeArrayLoop
                   3 14.29% 61.90%       3 300009 java.lang.Class.forName0
                   4  9.52% 71.43%       2 300022 java.io.InputStreamReader.<init>
                   5  4.76% 76.19%       1 300019 java.util.zip.Inflater.init
                   6  4.76% 80.95%       1 300028 java.util.LinkedList.<init>
                   7  4.76% 85.71%       1 300045 sun.misc.Unsafe.defineClass
                   8  4.76% 90.48%       1 300032 java.io.UnixFileSystem.normalize
                   9  4.76% 95.24%       1 300033 sun.reflect.NativeConstructorAccessorImpl.newInstance
                  10  4.76% 100.00%       1 300006 java.util.jar.JarFile.<clinit>
                CPU SAMPLES END

                 
                • Mario De Weerd

                  Mario De Weerd - 2007-11-25

                  Hello

                  After analyzing the log, I am not sure that your really launched bt747.  Did the application pop up during profiling?  It should have!

                  If you did start the application, I am somewhat puzzled that zip functionality is called upon.  The only reason that I see for that is that the 'jar' file is really a zip and that the system unzips that.

                  So, if that is true, I would suggest avoiding that by unzipping the 'jar' files up-front.  Here is an example for the core BT747_rxtx.jar file, but you could do the same for waba_only.jar and the RXTXcomm.jar.
                  According to me, this should not have an effect on performance, but it rules out a first parameter.  You can unzip all the jars to the same directory that must be referenced in the CLASSPATH.

                  mkdir bt_unzip
                  cd bt_unzip
                  unzip ..\dist\BT747_rxtx.jar
                  cd ..
                  set CLASSPATH=%RXTXPATH%\RXTXcomm.jar;webstart\waba_only.jar;bt_unzip;.;%CLASSPATH

                   
                  • Dirk Haase

                    Dirk Haase - 2007-11-26

                    Hello.

                    The unzipping helps! Now bt747 is realy fast, similar to windows. I send the long log to your sourceforge-email-adress. Its to long for the forum i think. If you don't get it, tell it me.

                    You are right, the bt747-appliction did't pop up. Ever i get a error message, then i unzip all three files und it works fine. I'am sure it this the solution. I will check it in next days with a clean installation of MacOS.

                     
                    • Mario De Weerd

                      Mario De Weerd - 2007-11-26

                      Good news!  The fact that the unzipping helps is still (partially) puzzling.

                      Anyway, if unzipping changes the behaviour, then it is unlikely that changing the application helps unless it is due to a repeated access to the jar database that is implemented in java on the MacOS.

                       
                    • Mario De Weerd

                      Mario De Weerd - 2007-11-26

                      I've uploaded a new version 1.15.  While trying to implement another method of reading the serial link, I kind of reproduced a slow interface on windows.
                      From this, combined with the 'fast' profile report from MacOS, I made some changes that should improve responsiveness (on MacOS & others).

                       
                      • Dirk Haase

                        Dirk Haase - 2007-12-01

                        to version 1.18:

                        I test it under MacOS 10.4.11 and under Windows XP Home: i get in both a immediately feedback if i select an option. No flicker. But (sorry) it flicker at the read waring-windows (erase and confirm), About... under MacOS - but this no real problem. How often we see this read windows? Under Windows this point is ok.

                        Can you add please a "Finish message" after erasing the device? Or use the progress-bar from downloading to show the erasing-process. Thanks.

                         
                        • Mario De Weerd

                          Mario De Weerd - 2007-12-01

                          Hello Dirk

                          Thank you for your feedback.

                          However, it puzzles me,  I do not get flicker on my windows system which is logical as the "solution" is only valid on MacOS (I validate what system I am on before doing extra 'paint' calls).

                          As I wrote to you, the feature can be controlled explicitelly from the java command line:

                          To enable:
                          java -Dbt747_Mac_solvelag=1 <other parameters>

                          To disable:
                          -Dbt747_Mac_solvelag=0 <other parameters>

                          The first method should solve the lag issue on MacOS, but would introduce flicker in popups on Windows (and probably MacOS too).
                          The second method should disable the solution and maintain behaviour as before both on windows a

                           
                          • Mario De Weerd

                            Mario De Weerd - 2007-12-01

                            Hello Dirk

                            Thank you for your feedback.

                            However, it puzzles me, I do not get flicker on my windows system which is logical as the "solution" is only valid on MacOS (I validate what system I am on before doing extra 'paint' calls).

                            As I wrote to you, the feature can be controlled explicitelly from the java command line:

                            To enable:
                            java -Dbt747_Mac_solvelag=1 <other parameters>

                            To disable:
                            -Dbt747_Mac_solvelag=0 <other parameters>

                            The first method should solve the lag issue on MacOS, but would introduce flicker in popups on Windows (and probably MacOS too).
                            The second method should disable the solution and maintain behaviour as before both on windows and on MacOS (i.e.: normal operation on windows, lag problem on MacOS).

                            So if on windows you get flicker, I do not understand that and I would benefit from knowing the results when you add the above options.

                             
                        • Dirk Haase

                          Dirk Haase - 2007-12-01

                          Flicker under MacOS only! And i personaly can live with this.

                           
                          • Mario De Weerd

                            Mario De Weerd - 2007-12-01

                            OK, then I consider this as a success!

                            I've implemented the functionality regarding the erase in V1.19.  It is something I wanted to do since quite a while and I found a way to do it 'properly'.

                             
            • Dirk Haase

              Dirk Haase - 2007-11-25

              I will create the log later, at time i compile Trolltechs Qt4 on my Mac, so the results would not be correct.

               
  • grondhal

    grondhal - 2007-10-27

    Hi!

    I struggled a while with gnu.io.NoSuchPortException when opening the port, but finally got it to run.

    Connecting and binding the gps unit was done like this:
    hcitool cc 00:xx:xx:xx:xx:xx
    rfcomm bind /dev/rfcomm0 00:xx:xx:xx:xx:xx

    My run_rxtx.sh looks like this:
    -----------------------
    MYROOTPATH=.

    SERPORT=/dev/rfcomm0

    RXTXLIBPATH=${MYROOTPATH}/rxtx-2.1-7-bins-r2/Linux/i686-unknown-linux-gnu
    export CLASSPATH=webstart/Waba_only.jar:dist/BT747_rxtx.jar:rxtx-2.1-7-bins-r2/RXTXcomm.jar

    java -Dgnu.io.rxtx.SerialPorts=${SERPORT} -Dbt747_port=${SERPORT} -Djava.library.path=${RXTXLIBPATH} waba.applet.Applet /w 320 /h 320 /scale 1 /bpp 8 BT747
    -----------------------

    I had to add the '-Dgnu.io.rxtx.SerialPorts=${SERPORT}' to get rid of the NoSuchPortException, but now it works.

    Thanks for the software!

     
    • Mario De Weerd

      Mario De Weerd - 2007-10-27

      Thanks for your feedback and instructions - I added them in the readme so they will be in the pacakge in V1.06+ releases.

       
  • sawman

    sawman - 2007-10-27

    I thought I was in over my head reading some of these postings but I finally got it to work, albeit with usb to pc xp pro. May have to try the hardware hack, I used to put heathkits together with my dad when I was a kid. Wish I'd grasped how big electronics would become back then. Thanks for the much more functional software.

     
    • Mario De Weerd

      Mario De Weerd - 2007-10-27

      Getting it to work on PC should be almost a nobrainer - unzip the SW and run 'run_rxtx.bat (click on it).

      If more operations were neede, please let me know which ones so that I can see if I can somehow integrate it in the package.

       
  • Niccolo Rigacci

    Niccolo Rigacci - 2007-11-20

    I run the program on GNU/Linux Debian Testing (Lenny). I had to install the non-free package sun-java6-jre.

    Please note: you must fix the run_rxtx.sh script, changing the end-of-line to the Unix standard (new-line) instead of Windows (new-line, carriage-return). Otherwise the script does not run.

     
  • Mario De Weerd

    Mario De Weerd - 2007-11-25

    Hello

    I also just discovered that somebody release a MacOS specific application here:

    http://www.versiontracker.com/dyn/moreinfo/macosx/33508

     
    • Mario De Weerd

      Mario De Weerd - 2007-11-25

      A pity though that this new application is shareware and not open source even though the author seems to have used at least in part the application here on sourceforge to build his application.

      I conclude this in part due to the functionality provided, but also that some (earlier) mistakes seem to be copied in the code.

       
<< < 1 2 3 4 > >> (Page 2 of 4)

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks