Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] remotes

My random thoughts about remotes (aka target, connection, remote connection, launch target)
I thought about it when we were trying to re-write our target stuff few years ago (unsuccessfully)
and it just adds to our discussion that we had on the cdt call on Tuesday

We do need an object to represent where you launching your program. And this object
is strongly related to the object that represent platform you compile for, but they
are not the same. Problem is there is very blurry line between them.
Lets say we call specific device you launching on IDevice and connection to this device IConnection. Connection types can be lets say JTag, Serial and TCP/IP but they all lead
to the save IDevice. There maybe multiple of similar devices which are instances of IDeviceType.

Now how can truly know if multiple connections lead to the same device?
What if we load another OS on the same device, so one day it is os 1.0 and another day it it is 2.0,
is this the same? Or even better today it is linux and tomorrow it is qnx...
Is there hardware id on device?
And reverse: if we connect device to usb, and it creates TCP/IP connection with same IP address, but today it is one device, and tomorrow its different. Is it the same IDevice because it has same IConnection?

So we really need to know what is important and for what and not over-engineer this thing.
For me IDevice does not exists on its own, it just artefact of connection and ideally created by connection, but when connection is down it should probably remember it's last IDeviceType info so we use this info for build. And IDevice should never exists on its own, if there is no real software connection it should be fake "ManualConnection" (aka take sd card insert in my desktop, copy files, eject, insert in remote device ... type of connection)
s
Properties of IDeviceType that we need
os.arch (or device.arch?)
os.name
os.version (maybe)
Properties of IDevice
device.id (what is it?)
Properties of IConnection
connection.is.up
connection.name (derived?)
Properties of IConnectionTcpIp
connection.port
connection.host
...

So I think current ILaunchTarget with bag of properties treated as IConnection rather then IDevice
should do what need. If o.e.remote wants to create such an interface for us, and Doug contribute his Common Navigator based target view for that object to o.e.remote, I think it would totally suffice. Then anybody else can extend it to show any sort of bells and whistles in this view (i.e. remote file system, or process lists or hardware tree or what not)
 
Thoughts?

Back to the top