Hi Folks,
I have been using the cFP-2010 (I know it's superceded already) for a few months now, but only *recently* have began to use the RT side of things. Perhaps a deterministic approach isn't even neccessary for our needs. I have spoken with a local field engineer and worked through the RT tutorial on the Training Modules CD. However I'm still helplessly trying to come up with a good structure for this application.
Currently I am using the logos protocol to create a pseudo-bridge between the host application and a piece of lab equipment attached to the cFP. It works exceptionally well, but it was created with no true RT/deterministic approach. It simple waits for a command via logos, commands the piece of equipment, reads the data back, then pipes it over to the host. There's an atomic/bi-direction 'status' flag to trigger reads/writes. This happens maybe once ever 5minutes. I'll try to attach the VI's at the end.
FYI this is RT 8.5.1 (Devel) with a target of cFP-2010 and host is a WinXP machine.
What I'm getting hung up on is making the move to a more proper approach to integrate another serial-based piece of equipment. This device (a flow controller) *does* need to be polled constantly to read data for use/display on the host. The host needs to be able to write to it as well. I have VI's working for use on the host's local RS232 port, but I haven't 'ported' them over yet.
The approach I first took(a new project, ommiting the first piece of equipment) was to have a time-critical loop take care of the serial reads and writes for the flow controller. This was setup as a state machine. It communicated with a lower-priority thread to receive commands (state changes) from the host.
So time-critical to lower priority via a single-process enum
lower priority to host via network published enum.
Again I had to use an additional boolean network published to flag when states changed, because the timestamps are only updated when the var changes.
The use of network published variables seems 'bulky', for lack of better terms. Can you folks offer some advise to get me in the right direction? Maybe I should scrap the RT thought and just use what works?
Thanks for your time!
Jamie
PS - sorry for the lack of support files, I can't upload zips!(encrypted on my end).
v2009 devel. w/RT