Realtime Problem (School Project)

I have to make a graphic representation of a roboter (s. pic) which has many places to put Objects on them. till now, i got the connection between Server and Clien, and i can see which places are free and which of them are occupied.(see pic CYAN:free and Purple: occupied).

My problem is, when i put an object on a free place or take one from an occupied place, it should indicate that automatically on the graphic (Realtime), and the coulour must be changed without recompiling and rerunning the Program.

I would appreciate any Help !
Thx

I think you need to give us more information. Are you writing a program? A photon program? What do you mean by the connection between Server and Client? Is the roboter a client that you talk to via TCP/IP? Or do you mean you are writing programs that interact as server and client using message passing? When you say the colour must change without recompiling, do you mean that a user is going to pick his/her the colour? Or did you mean that you just want the program to change the colour for you when something is placed on the Robotor?

I got a Server Program, and i had to develop a graphic Client (Photon Program) to communicate with that Server.

  • Connection Between Client & Server(IPC): if there is a connection between them, the graphic should be displayed. (The graphic gives Information about which places are free and which are occupied) → plz see Pic above
    These Informations are sent from Robot through a PLC Module via FTP.

*do you mean you are writing programs that interact as server and client using message passing? YES

*I want the program to change the colour when something is placed on the Robotor ( and this without rerunning the programm) this change must happen in Realtime.

Example: The programm must be compiled and runned just one time, and when i put an element on a free place (CYAN Colour in the pic above), at the same time the programm should change the colour of that element to purple (occupied).

Have your program check for the file transfer via ftp at regular interval. Read the file and parse it. Depending on the content of the file set the color of the object as needed.

Thx mario.
this is not the problem, this part is working well. i can read all the Information from the FTP, and the setting of the colour is working too.
the problem is how to program a realtime change of that colour when a free place become occupied .

I’m sorry but I don’t understand what the problem is, you can read the file and get the information from it, you can change the color. What it is that you can’t do and how is it related to QNX6.

via FTP is no RealTime. You can poll the File itself quite often, but changes in your client will just appear as soon, the connection was opened, the file was read and parsed, your client has set the corresponding resources.

The longest on this list will be the polling/opening/closing of the connection/file. Why not having a persistant connection to your server via TCP/IP or just sending quick Datagrams with status changes.

If you wonder the file not changing at all as soon as you open it, you will have to redownload and reopen it… (reload…)

Is your question related to how to set colors of widgets in Photon? Have you tried PtSetResource ?