opentcs icon indicating copy to clipboard operation
opentcs copied to clipboard

A new Web API Wanted

Open 1180300601 opened this issue 1 year ago • 3 comments

I hope to add a web api, which can set the location of the vehicle according to the vehicle name: [POST] /vehicles/{NAME}

NAME(required): The name of the vehicle to be created. newValue: The position name of the vehicle started.

The Web API function is the same as the Vehicle driver window in the open-TCSKernelControlCenter, whick can set the loopback options of vehicle position. However my java is so poor that i cannot make the API. Plz give me a hand.

1180300601 avatar Dec 07 '23 06:12 1180300601

Maybe I am wrong about what i am saying above:

the API should be [POST] /vehicles/{NAME}/commAdapter/position

NAME(required): The name of the vehicle to be created. newValue: The position name of the vehicle started.

1180300601 avatar Dec 07 '23 06:12 1180300601

image with this API can only make a web app full

1180300601 avatar Dec 07 '23 07:12 1180300601

@1180300601 I agree that it may be useful to have an endpoint for that in the web API. After all, the Java API also provides a method for that (via VehicleService.sendCommAdapterCommand() and an instance of InitPositionCommand). So we'd basically need a way to send adapter commands via the web API. No promises about when that will be implemented, though.

In the meantime: You can automatically initialize a virtual vehicle on a specific point in the model. See the User's Guide about this. Maybe this is an alternative for you?

swltr avatar Dec 18 '23 15:12 swltr