Changes between Version 3 and Version 4 of Burt-Research/SystemOverview

Jan 17, 2018, 9:13:29 PM (14 months ago)



  • Burt-Research/SystemOverview

    v3 v4  
    1414CoAP communicates based on Representational State Transfer (REST) architecture and supports four modes of REST which are PUT, GET, POST, and DELETE. A client sends a request with any one of the four modes and the server will respond with a reply in accordance with the request. The CoAP supports two modes: reliable and non-reliable. For instance, we use the reliable mode for activating the robot and non-reliable mode for sending force data. Reliability in CoAP is handled by using Confirmable (CON) messages. For every CON message send to the server, this will be replied by Acknowledge (ACK) packages to the client. In essence, CoAP's job is to define the URI structure (a hierarchy of objects accessible by GET/POST); handle GET/POST requests; handle the ACKs for confirmable transmissions; deal with dropped, reordered, or duplicate packets. MessagePack's job is to encode/decode structured data without resorting to encoding numbers as text.
     16== BurtSharp Message Types ==
     18The mainboard control loop runs at 500 Hz, able to do math, send and receive messages in a stable and reliable way. BurtSharp subscribes to mainboard control loop messages. The BurtSharp-CoAP client runs in a separate thread “RunControlCycle()” and executes a callback to form the next control cycle output every time a message is received from the server “OnReceiveServerUpdate()”. This is higher reliable than having the replies be completely asynchronous from the mainboard control loop messages. BurtSharp sends one message (“RobotCommand”) per control cycle.
     20* The BurtSharp-CoAP client subscribes to observable resource group packages such as:
     21  * ServerUpdate
     22    * "position": [x, y, z]
     23    * "velocity": [x, y, z]
     24    * "joint_position": [j1, j2, j3]
     25    * "joint_velocities": [j1, j2, j3]
     26    * "timestamp": <u32>
     27  * RobotStatus
     28    * "handedness": u8
     29    * "Outerlink": u8
     30    * "Patient": u8
     31    * "Estop": u8
     33* The BurtSharp-CoAP client sends asynchronous NON-confirmable PUT requests to the mainboard-server through the “AsyncNonPutRequest” method. These requested messages can be one of the following control modes:
     34  * Cartesian Forces
     35  * Joint Torques
     36  * Cartesian Torques
     37  * Cartesian Forces + Joints Torques
     39* The BurtSharp-CoAP client subscribes at mainboard fault updates and to observable resource faults information such as:
     40  * MainBoardFault.NotReady
     41  * MainBoardFault.NoCanAtStartup
     42  * MainBoardFault.NoCoapAtStartup
     43  * MainBoardFault.OuterLinkDisconnected
     44  * MainBoardFault.HandednessUnknown
     45  * MainBoardFault.InvalidEepromCrc
     46  * MainBoardFault.EStopPressed
     47  * MainBoardFault.EStopLatched
     48  * MainBoardFault.InitFailed
     49  * MainBoardFault.TorqueLimitJ1
     50  * MainBoardFault.TorqueLimitJ2
     51  * MainBoardFault.TorqueLimitJ3
     52  * MainBoardFault.NotInHomingPositionAtStartup