![]() |
Roboid Control for Python
|
A local participant is the local device which can communicate with other participants.
It manages all local things and communcation with other participants. Each application has a local participant which is usually explicit in the code. An participant can be isolated. In that case it is standalong and does not communicate with other participants.
Currently, only UDP communication is supported
Public Member Functions | |
__init__ (self, port=7681, ip_address="0.0.0.0", local_port=0) | |
Create a new participant with the given communcation info. | |
GetParticipant (self, ip_address, port) | |
AddParticipant (self, ip_address, port) | |
Update (self, currentTimeMs=None) | |
Update all things. | |
SendThingInfo (self, owner, thing, bool recursively=False) | |
Send (self, owner, msg) | |
Publish (self, msg) | |
Receiver (self) | |
ReceiveData (self, data, sender) | |
ProcessClientMsg (self, sender, ParticipantMsg msg) | |
ProcessNetworkIdMsg (self, sender, NetworkIdMsg msg) | |
ProcessInvestigateMsg (self, bytearray data) | |
ProcessThingMsg (self, ThingMsg msg) | |
ProcessNameMsg (self, NameMsg msg) | |
ProcessModelUrlMsg (self, ModelUrlMsg msg) | |
ProcessBinary (self, BinaryMsg msg) | |
Register (self, constructor, thing_type) | |
OnNewThing (self, event_handler) | |
OnNewThingType (self, thing_type, event_handler) | |
Public Attributes | |
local_port | |
isolated | |
True if the participant is running isolated. | |
remote_site | |
The remote site when this participant is connected to a site. | |
thing_msg_processors | |
new_thing_handlers | |
publishInterval | |
udp_socket | |
nextPublishMe | |
port | |
Static Public Attributes | |
buffer = None | |
network_id = None | |
The network ID of the participant. | |
int | nextPublishMe = 0 |
others = None | |
thread = None | |
str | name = "Participant" |
__init__ | ( | self, | |
ip_address = 7681 , |
|||
port = "0.0.0.0" , |
|||
local_port = 0 |
|||
) |
Create a new participant with the given communcation info.
Reimplemented from Participant.
Reimplemented in SiteServer.
Update | ( | self, | |
currentTimeMs = None |
|||
) |
Update all things.
Reimplemented from Participant.
isolated |
True if the participant is running isolated.
Isolated participants do not communicate with other participants