FAQ
Cover
This is the archive Discourse for the Processing (ALPHA) software.
Please visit the new Processing forum for current information.

   Processing 1.0 _ALPHA_
   Programming Questions & Help
   Syntax
(Moderators: fry, REAS)
   obtain several information on the PC
« Previous topic | Next topic »

Pages: 1 
   Author  Topic: obtain several information on the PC  (Read 374 times)
Z3r0Fr0z3


obtain several information on the PC
« on: Nov 21st, 2004, 1:53pm »

Hi.  
There is a way in witch i could obtain this information in processig?  CPU Temperature, HardDriwe free and used space, my IP address, Net in and out...
 
st33d

WWW Email
Re: obtain several information on the PC
« Reply #1 on: Nov 27th, 2004, 3:46am »

http://forum.java.sun.com/thread.jspa?forumID=31&threadID=372168
 
http://javaalmanac.com/egs/java.net/ResolveHostname.html
 
Try a different language? Maybe one a little similar?
 

I could murder a pint.
fjen

WWW
Re: obtain several information on the PC
« Reply #2 on: Nov 27th, 2004, 4:19am »

Quote:
Try a different language? Maybe one a little similar?

 
what's that supposed to say?
 
Z3r0Fr0z3


iRe: obtain several information on the PC
« Reply #3 on: Nov 27th, 2004, 1:37pm »

Hi.
thanks for the reply.  
So in order to use this information in processing,i have to write a program in java that read this information, and the pass it to Processing for the graphical visualization.
 
 
st33d

WWW Email
Re: obtain several information on the PC
« Reply #4 on: Nov 27th, 2004, 5:04pm »

Sorry, I was being a little silly.
 
Does Processing sit on top of Java? Is it possible to reach down through it and access Java? I haven't tackled Java yet and keep finding ways to do what I want in Processing so I never get round to learning it. I've only imagined this possiblity owing to the reference section being hyper-appendicized by the forum. Java terms get mentioned but the level of accessibility doesn't seem to be carved out in concrete.
 

I could murder a pint.
Z3r0Fr0z3


UnfortunatRe: obtain several information on the PC
« Reply #5 on: Dec 1st, 2004, 6:34pm »

Unfortunately i don't know java , i started programing with processing only a month ago.
So at now i can't do this.
Anyway tanks for the reply.
 
fjen

WWW
Re: obtain several information on the PC
« Reply #6 on: Dec 2nd, 2004, 12:49am »

check here:
http://processing.org/reference/compare/java.html
 
to give you an example how to use the code from st33d's link:
Code:

void setup()
{
  size(200,200);
}
 
void draw()
{
  println( getIP("processing.org") );
}
 
// http://javaalmanac.com/egs/java.net/ResolveHostname.html
 
String getIP( String _addr )
{
  String ipAddrStr = "";
  try {
   InetAddress addr = InetAddress.getByName(_addr);
   byte[] ipAddr = addr.getAddress();
     
   // Convert to dot representation
   for (int i=0; i<ipAddr.length; i++) {
  if (i > 0) {
      ipAddrStr += ".";
  }
  ipAddrStr += ipAddr[i]&0xFF;
   }
    } catch (UnknownHostException e) {
    }
  return ipAddrStr;
}

 
/F
 
Z3r0Fr0z3


Re: obtain several information on the PC
« Reply #7 on: Dec 3rd, 2004, 8:49pm »

Thank you fjen, now i have  to study it.
 
Pages: 1 

« Previous topic | Next topic »