Pages: [1]   Go Down
Author Topic: Data Visualized error with Proccessing  (Read 760 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 13
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello Massimo Banzi and everyone here!



I had an arduino board that was connected to the to a Intel Mac OS 10.4.10. I test 3 softwares: the Blink, the Button and the ap_DigitalRead. The three of them runs on the arduino board and have no problems at all. But when I try to use Arduino 09 + Procesing 125 something strange happen. The software in the board is still running ok the data previsualization software is running but the  there are no changes in the graphics. I mean the software processing software is running but it doesnt work.  
I download the firmware  for the version 08 and upload to the board and have no problems.

I try then with other arduino board and the samething happen

Do I miss somehting?

Please help me.

ignacio
Logged

Forum Administrator
Cambridge, MA
Offline Offline
Faraday Member
*****
Karma: 12
Posts: 3538
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

To use Processing with a serial port (USB connection) you need to run the macosx_setup.command in the libraries/serial (something like that) folder of Processing, then restart your computer.
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 13
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

i do wath you said in the terminal and restart the machine and try to test it again but the problem is the same
is other idea how i can resolve these problem?

thank you
in

Logged

Forum Administrator
Cambridge, MA
Offline Offline
Faraday Member
*****
Karma: 12
Posts: 3538
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

What if you upload the "Communication > Graph" example to the Arduino board?  Can you see any data with the Arduino serial monitor?  If you run the corresponding Processing, what do you see?  Does it run or do you get an error?
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 13
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Dear

I try Graph program in Arduino with a potentiometer in channel 0 put the monitor mode and it works fine values increase from 0 to 1000 aprox at 9600.

Then I close the monitor mode of Arduino, open Processing, put the code, establish the port

"/dev/tty.usbserial-A4OOOPEj"

and run then the data visualization window open, use the pontentiometer but doesnt happen nothing inthat window

and down in the processing window the only thing printed is

vailable serial ports:
Stable Library
=========================================
Native lib Version = RXTX-2.1-7
Java lib Version   = RXTX-2.1-7
  • "/dev/tty.usbserial-A4000PEj"
  • [1] "/dev/cu.usbserial-A4000PEj"
    [2] "/dev/tty.Sniffer-NokiaPCSuite-1"
    [3] "/dev/cu.Sniffer-NokiaPCSuite-1"
    [4] "/dev/tty.Bluetooth-PDA-Sync"
    [5] "/dev/cu.Bluetooth-PDA-Sync"
    [6] "/dev/tty.Sniffer-Dial-upnetworki-2"
    [7] "/dev/cu.Sniffer-Dial-upnetworki-2"
    [8] "/dev/tty.Bluetooth-Modem"
    [9] "/dev/cu.Bluetooth-Modem"

    But id doesnt work. Maybe it could have conflict wih other ports of the computer? Is strange but the Processing is reading a mobile phone. I like that, but I want to pass the basic steps before I try on mobile phones ; )

    IN  
Logged

Forum Administrator
Cambridge, MA
Offline Offline
Faraday Member
*****
Karma: 12
Posts: 3538
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Hmm..  You don't get any error messages?  That's strange.  Can you scroll the message window?

One other thing to try...  run Processing and open the Graph Processing code, but don't run it.  Hold down the reset button on the Arduino board and connect it to the computer.  Still holding down the reset button, run the Processing Graph sketch.  Once it starts, let go of the reset button.

Does anything happen?
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 13
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I can scroll the window in the message window of arduino

I reset like you said me in processing but nothing happen. But I discove something.

When I establish the port in Arduino:

port = new Serial(this, "/dev/tty.usbserial-A4OOOPEj", 9600);  //> the three are letter O in capitals  


proecessing runs a print all the ports like I said you before but when i write the same thing changing the the lettes o to ceros that is the name of the real port -looking at the list of ports printed in processing-:

port = new Serial(this, "/dev/tty.usbserial-A4000PEj", 9600);


[glow]AN ERROR OCCURS IN JAVA[/glow]

Available serial ports:
Stable Library
=========================================
Native lib Version = RXTX-2.1-7
Java lib Version   = RXTX-2.1-7
  • "/dev/tty.usbserial-A4000PEj"
  • [1] "/dev/cu.usbserial-A4000PEj"
    [2] "/dev/tty.Sniffer-NokiaPCSuite-1"
    [3] "/dev/cu.Sniffer-NokiaPCSuite-1"
    [4] "/dev/tty.Bluetooth-PDA-Sync"
    [5] "/dev/cu.Bluetooth-PDA-Sync"
    [6] "/dev/tty.Sniffer-Dial-upnetworki-2"
    [7] "/dev/cu.Sniffer-Dial-upnetworki-2"
    [8] "/dev/tty.Bluetooth-Modem"
    [9] "/dev/cu.Bluetooth-Modem"

    java.lang.StringIndexOutOfBoundsException: String index out of range: -1
          at java.lang.String.substring(String.java:1768)
          at Temporary_9620_5234.serialEvent(Temporary_9620_5234.java:57)

    java.lang.StringIndexOutOfBoundsException: String index out of range: -1
          at java.lang.String.substring(String.java:1768)
          at Temporary_9620_5234.serialEvent(Temporary_9620_5234.java:57)
          at Temporary_9620_5234.draw(Temporary_9620_5234.java:45)
          at processing.core.PApplet.handleDisplay(PApplet.java:1359)
          at processing.core.PGraphics.requestDisplay(PGraphics.java:680)
          at processing.core.PApplet.run(PApplet.java:1454)
          at java.lang.Thread.run(Thread.java:613)
          at Temporary_9620_5234.draw(Temporary_9620_5234.java:45)
          at processing.core.PApplet.handleDisplay(PApplet.java:1359)
          at processing.core.PGraphics.requestDisplay(PGraphics.java:680)
          at processing.core.PApplet.run(PApplet.java:1454)
          at java.lang.Thread.run(Thread.java:613)

Logged

Forum Administrator
Cambridge, MA
Offline Offline
Faraday Member
*****
Karma: 12
Posts: 3538
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I would try using the original Processing code that comes with the graph example.  That is, leave the line as:

  port = new Serial(this, Serial.list()[0], 9600);  

Since the Arduino is the first thing in the list, that should select it.
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 13
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks a lot Mellis. it works finally. In both Arduino under two Macintosh 10.10.
Greetings from Chile

 smiley-grin
IN
Logged

Pages: [1]   Go Up
Jump to: