anyKode Marilou
|
DevicesGroup is a set (array) of devices with the same type (class). The network calls are centralized and parallelized.
class DevicesGroup;
ModaCpp.h
The group accesses the devices in a single network call instead of separately dialoguing with each device. It makes it possible to relieve the network (1 single call) and considerably accelerate the read/write operations from the user algorithm. For example, controlling servos motors : 1 single call is necessary to control all the articulations of a robot. Without group management, 1 call for each servos is required.
User can then create legs servo group, arm servo group and control directly the leg or the arm with a single network call. The devices can be part of several groups. The device can be called directly even if inside a group. A group only contains devices of the same type and created from the same Connection.
The number of devices per group is limited to _MODA_MAXGROUPDEVICES (65535 by default).
The group is created by used using C++ keyword new DeviceGroupxxxxxx, and released by deleting the object (delete).
The DevicesGroup class must not be directly instantiated: Typically we use the excess loads of groups such as DevicesGroupDistance or DevicesGroupMotor, which take charge of the capabilities specific to the type of device concerned.
DevicesGroupDistance, DevicesGroupMotor, DevicesGroupAccelGyro, DevicesGroupActuatingCylinder, DevicesGroupContact, DevicesGroupSurfaceMotion,DevicesGroupEmitterReceiver
Documentation v4.7 (18/01/2015), Copyright (c) 2015 anyKode. All rights reserved.
|
What do you think about this topic? Send feedback!
|