Re: Displaying Realtime Data
Re: Displaying Realtime Data
- Subject: Re: Displaying Realtime Data
- From: Daniel Todd Currie <email@hidden>
- Date: Mon, 27 Oct 2003 23:49:07 -0800
It depends on the stream... One easy way to do it is with delegation.
Every time a certain amount of data comes in, or is updated, or however
the stream works; a message is sent to the controller (the delegate, in
this case) containing whatever info you would like to display. The
controller then simply formats the data and updates the NSView or
whatever you have in mind.
If you are still uncertain how this would work, I can show you an
example that I happen to be working on right now.
// Daniel Currie
On 2003 Oct 27, at 23:06, Saul Iversen wrote:
Could someone please offer a recommendation regarding the best
approach in the Cocoa world for displaying an incoming stream of
realtime data from an instrument? I have developed some code which
correctly parses a serial stream of physiological data and prints body
temperature for instance to the console. But I want to be able to go
beyond simple printf's and open a separate window with the text
representing the temperature enlarged and continuously being updated.
Should I be using Interface Builder to set up some sort of NSView
variant of a text window? Would this require a separate backend
process running which converts the serial stream of data to a float
which I would then somehow NSPipe over to IB? Or should I include the
serial stream processing in the controller which is created to work
with IB? Somehow this last idea seems wrongheaded but then I am still
learning.
Many thanks for your patience and support...
Saul
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.