PDF
AGVC SDK  0.8.0
agvc_interface::AgvcInterface Class Reference

#include <agvc_interface.h>

Inheritance diagram for agvc_interface::AgvcInterface:

Public Member Functions

 AgvcInterface ()
virtual ~AgvcInterface ()
int setSystemClock (const std::string &stamp)
 Sets the AGV system time.
AgvDetails getAgvDetails ()
 Queries current AGV information.
RunningInfo getRunningInfo ()
 Queries current AGV running information.
Pose2d getAgvCurrentPose ()
 Queries the current AGV pose.
std::vector< Point2dgetLaserPointCloud ()
 Queries the current laser point cloud data.
AsyncInterfaceResultStatus getAsyncInterfaceResultStatus ()
 Queries the running status of asynchronous APIs; this does not represent each API's own execution result.
std::vector< StationMarkgetAllStations ()
 Queries all station information on the current map.
std::vector< StationMarkgetAllStationsOfTargetMap (const Header &map_header)
 Queries all station information on the specified map.
int addStation (const StationMark &station)
 Adds or modifies one station.
int addStations (const std::vector< StationMark > &stations)
 Adds or modifies multiple stations.
int addCPStationUseChargingBoard (const Header &station_header, const double &dis_station_board=1.5)
 Adds a charging station by automatically recognizing the charging board pose.
int deleteStation (const Header &station_header)
 Deletes the specified station and its related paths.
int deleteStations (const std::vector< Header > &stations_header)
 Deletes multiple stations and their related paths.
std::vector< PathStationgetAllPaths ()
 Queries all path information on the current map.
std::vector< PathStationgetAllPathsOfTargetMap (const Header &map_header)
 Queries all path information on the specified map.
PathStation getCurrentPath ()
 Queries the path currently being tracked by the AGV.
int generatePath (const PathStation &path_station)
 Generates or modifies one path.
int generatePaths (const std::vector< PathStation > &paths_station)
 Generates or modifies multiple paths.
int deletePath (const Header &path_header)
 Deletes one path.
int deletePaths (const std::vector< Header > &paths_header)
 Deletes multiple paths.
std::vector< HeadergetMapList ()
 Gets the headers of all maps on the AGV.
Header getCurrentMapHeader ()
 Queries the header of the current AGV map.
OccupancyGridMap getGridMapFromAgv (const Header &map_header)
 Gets the specified occupancy grid map information.
Base64PngMap getBase64PngMapFromAgv (const Header &map_header)
 Gets Base64-encoded PNG map information.
Base64PngMap previewPngMapFromAgv (const Header &map_header, const int &image_width_px=0, const int &image_height_px=0)
 Gets a preview image with optional width and height.
int sendGridMapToAgv (const OccupancyGridMap &map)
 Sends occupancy grid map information to the AGV.
int sendBase64PngMapToAgv (const Base64PngMap &map)
 Sends a Base64-encoded PNG map to the AGV.
int saveMap (const Header &map_header)
 Saves the map after mapping is complete.
int switchMap (const Header &map_header)
 Switches to the specified map.
int deleteMap (const Header &map_header)
 Deletes one specified map.
int deleteMaps (const std::vector< Header > &map_headers)
 Deletes multiple specified maps.
std::vector< MapVirtualAreagetAllMapVirtualArea ()
 Queries virtual areas on the current map.
std::vector< MapVirtualAreagetAllMapVirtualAreaOfTargetMap (const Header &map_header)
 Queries virtual areas on the target map.
int addMapVirtualArea (const MapVirtualArea &map_virtual_area)
 Adds or modifies one virtual area.
int addMapVirtualAreas (const std::vector< MapVirtualArea > &map_virtual_areas)
 Adds or modifies multiple virtual areas.
int deleteMapVirtualArea (const Header &virtual_area_header)
 Deletes the specified virtual area.
int deleteMapVirtualAreas (const std::vector< Header > &virtual_areas_header)
 Deletes multiple specified virtual areas.
MapAllInfo getGridMapAllInfo (const Header &map_header)
 Gets occupancy grid map data, paths, stations, and virtual areas for the specified map.
MapAllInfo getPngMapAllInfo (const Header &map_header)
 Gets Base64 map data, paths, stations, and virtual areas for the specified map.
int setGridMapAllInfo (const MapAllInfo &map_all_info, const Header &command_header={ "99999", "99999", 1, "99999" })
 Sets occupancy grid map, path, station, and virtual area information.
int setPngMapAllInfo (const MapAllInfo &map_all_info, const Header &command_header={ "99999", "99999", 1, "99999" })
 Sets Base64 map, path, station, and virtual area information.
int deleteMapAllInfo (const Header &map_header)
 Deletes all information of the specified map, including map data, stations, paths, and virtual areas.
std::vector< std::string > getWifiList ()
 Gets the currently scanned WiFi list.
int connectWifi (const std::string &ssid, const std::string &password)
 Connects to the specified WiFi and automatically switches to WiFi mode.
int enableHotspot (const std::string &password)
 Enables hotspot mode and automatically switches to hotspot mode.
std::vector< IpAddressInfogetIpAddressList ()
 Gets all local IP addresses.
int changeRunningMode (const RunningMode &running_mode, const Header &command_header={ "99999", "99999", 1, "99999" })
 Switches the AGV running mode.
int setControlSpeed (const Speed &speed)
 Controls AGV motion.
int setNavGoal (const NavGoalType &target)
 Sends a navigation goal to the AGV.
NavInfo getNavInfo ()
 Gets current navigation information.
int pauseAgvSpeed ()
 Pauses AGV speed.
int resumeAgvSpeed ()
 Resumes AGV speed after a pause.
int cancelNavigation ()
 Cancels the navigation task.
int relocation (const Pose2d &init_pose, const Header &command_header={ "99999", "99999", 1, "99999" })
 Relocates the AGV.
std::string getAgvControllerParametersFile ()
 Gets the AGV controller parameter file.
int setAgvControllerParametersFile (const std::string &agv_parameters)
 Sets the AGV controller parameter file.
int refreshAgvControllerParametersFile ()
 Refreshes parameters on AGV nodes after the AGV controller parameter file is modified.
int resetAgvControllerParametersFile ()
 Restores the AGV controller parameter file to factory defaults.
int checkPowerAndAutoCharge (const Header &check_power_header={ "99999", "99999", 99999, "99999" }, const std::string &nav_board_charge_station_id="99999")
 Checks the current battery level and automatically docks for charging when the battery is low.
int setLeaveBoardTargetStation (const Header &leave_board_target_station_header)
 Sets the target station for automatic undocking.
Header getLeaveBoardTargetStation ()
 Gets the target station for automatic undocking.
int forcedAgvToChargingBoard (const Header &forced_charge_header={ "99999", "99999", 99999, "99999" }, const std::string &nav_board_charge_station_id="99999")
 Forces the AGV to dock for charging.
int forcedAgvLeaveChargingBoard (const Header &forced_leave_header={ "99999", "99999", 99999, "99999" }, const std::string &leave_board_target_station_id="99999")
 Forces the AGV to leave the charging board.
int sendAutoChargingCommand (const AutoChargingCommand &auto_charging_command)
 Sends an automatic charging command.
std::string getAgvLogMessage ()
 Gets AGV runtime log messages.
int updateSoftware (const std::string &upgrade_pack_path)
 Upgrades AGV software.
std::vector< std::string > getSoftwareVersionList ()
 Gets the AGV software version list.
int switchSoftwareVersion (const std::string &software_version)
 Switches the AGV software version.
int uninstallSoftware (const std::string &software_version)
 Uninstalls an AGV software version.
int updateFirmware (const FirmwareUpdateParam &update_firmware)
 Updates AGV firmware.
FirmwareUpdateProcessInfo getUpdateFirmwareProcess ()
 Gets firmware update process information.
int startCollectCalibrationData (const CalibrationType &type, const Header &command_header={ "99999", "99999", 1, "99999" })
 Starts collecting calibration data.
int cancelCollectCalibrationData (const CalibrationType &type, const Header &command_header={ "99999", "99999", 1, "99999" })
 Cancels calibration data collection.
int startCalibration (const CalibrationType &type, const Header &command_header={ "99999", "99999", 1, "99999" })
 Starts calibration.
CalibrationProcessInfo getCalibrationProcessInfo (const CalibrationType &type)
 Gets calibration information.
int restartAgv ()
 Restarts the AGV.
int setAgvName (const std::string &agv_name)
 Sets the AGV name.
int setPriority (const std::string &name, const std::string &ip="")
 Sets control priority.
int releasePriority ()
 Releases control priority.
int scriptPaused ()
 Pauses the script.
int scriptResume ()
 Resumes the script.
int scriptStop ()
 Stops the script.
ScriptRuntimeState getScriptStatus ()
 Gets the script runtime state.
int setScriptStatus (ScriptRuntimeState status)
 Sets the script runtime state.
std::string errorCodeDecoder (const int &error_code)
 Queries an error code.
std::vector< HeadergetCurrentErrorCodes ()
 Gets current error codes.
int soundLightPrompt ()
 Locates the AGV by automatically playing audio and flashing special lights.
bool isObstacleAhead (const double &detect_distance=1.0)
 Checks whether there is an obstacle in the AGV travel direction.
StationMark getNearestStation (const double &detect_distance=1.0)
 Gets the nearest station within the specified detection distance.
int autoAlignRailway (const Header &command_header={ "99999", "99999", 1, "99999" })
 Automatically aligns with the rail and boards the rail.

Detailed Description

Definition at line 98 of file agvc_interface.h.

Constructor & Destructor Documentation

◆ AgvcInterface()

agvc_interface::AgvcInterface::AgvcInterface ( )

◆ ~AgvcInterface()

virtual agvc_interface::AgvcInterface::~AgvcInterface ( )
virtual

The documentation for this class was generated from the following file: