Unified API Format – Overview

Robo Assistant Configuration Documentation

Camera Calibration Procedures

There are three types of camera position detection modes:

Calibration Phases

  1. Set up a chessboard in the center of the camera's view.
  2. Call the calibration process and wait for the signal.
  3. Set up a clear view (no robots/humans) to define the background.
  4. Define tolerance points and range limits.

Commands

$calibration "image_name.jpg" --background
$calibration "image_name.jpg"

Configuration File: map.xml

<?xml version="1.0" ?>
<Data>
    <area width="0" height="0" deep="0" name="office"/>
    <Sensors>
       <Camera id="1" type="CCTV_analog" frequency="30" fi="110" x="0" y="0" z="0">
           <calibration file="file1.jpg"/>
           <calibration file="file2.jpg"/>
           <background file="file3.jpg"/>
           <background file="file4.jpg"/>
       </Camera>
       <Camera id="2" type="CCTV_analog" frequency="30" fi="110" x="0" y="0" z="0"/>
    </Sensors>
    <Robots />
    <Objects />
    <Blockers />
</Data>

QR codes help detect and position objects, assigning IDs for 3D mapping.

Optional Add-On: A mash-up radio position detector for tracking out-of-camera movements.


Creating Applications

Applications connect command logic and devices with interfaces (GUI, Text, Voice). Commands are like libraries, complex commands are macros.

C++ Example

class HomeManagement {
private:
    Host host;
public:
    HomeManagement() {
        host = new Host("127.0.0.1");
    }
    void load();
    void viewCommandList();
    void viewListOfDevices();
    void showCommand();
};

void HomeManagement::load() {
    if (this->host.getPath() == "api/commands") viewCommandList();
    if (this->host.getPath() == "api/devices") viewListOfDevices();
    if (this->host.getPath() == "api/shell") showCommand();
}

Creating Commands

Commands manage machine scenarios and actions. Below is an example that displays text on all connected displays.

Java Example

public class DisplayCommand implements CommandInterface {
    private String string;

    public void setString(String string) {
        this.string = string;
    }

    public void run() throws CommandException {
        Vector<Display> displays = Loader.getDisplays();
        for (Display display : displays) {
            display.getObject().setText(this.string);
            display.getObject().setTime(60);
            display.load();
        }
    }

    public Vector<Requirement> getRequirement() {
        Vector<Requirement> requirements = new Vector<>();
        requirements.add(new DisplayRequirement());
        return requirements;
    }
}

C++ Example

class DisplayCommand : public CommandInterface {
private:
    std::wstring string;
public:
    void setString(const std::wstring &string);
    void run() override;
    std::vector<Requirement*> getRequirement() override;
    std::wstring getName() override;
};

void DisplayCommand::run() {
    auto displays = Loader::getDisplays();
    for (auto display : displays) {
        display->getObject()->setText(this->string);
        display->load();
    }
}

Interface Definitions

public interface CommandInterface {
    void run() throws CommandException;
    Vector<Requirement> getRequirement();
}
public interface Requirement {
    String getName();
    boolean isMeet();
    boolean isOptional();
    Vector<Requirement> depends();
}

Java Requirement Example

public class DisplayRequirement implements Requirement {
    public boolean isMeet() {
        return !Loader.getDisplays().isEmpty();
    }
}

Robots

The Robot Identifier

Chooses the closest free robot capable of performing the task. Encoded channels combine location and robot type identifiers.

Robot Signal Processor Variants

Setup is done via local site or Central API by loading options and pairing receivers.