BB1: full E40 S16F11 body — MF, PRRECIPEMETHOD, RCPVARS, PRPROCESSPARAMS
Replaces the simplified <L,3 PRJOBID PPID MTRLOUTSPEC> demo body with
the full SEMI E40-0705 §10.2 shape:
<L,5 PRJOBID MF PRRECIPEMETHOD
<L,2 PPID <L,n <L,2 RCPPARNM RCPPARVAL>>>
<L,n MTRLOUTSPEC>
<L,n <L,2 PARAMNAME PARAMVAL>>>
ProcessJob now carries the extra fields (MaterialFlag, ProcessRecipeMethod,
RcpVar[], ProcessParam[]) so a tool's recipe engine can later consume
the recipe-variable overrides and per-job process parameters. Server
S16F11 dispatch populates them via the new ProcessJobStore::set_e40_extras
helper after a successful create.
MaterialFlag + ProcessRecipeMethod enums live in their own tiny header
(`e40_constants.hpp`) so process_jobs.hpp (the store) can use them
without dragging in messages_helpers.hpp (which would create a circular
include via data_model.hpp).
The simplified 3-arg HostHandler::send_create_process_job convenience
remains; it constructs a sensible-default PRJobCreateRequest internally.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
+20
-2
@@ -1049,7 +1049,7 @@ int main(int argc, char** argv) {
|
||||
auto req = gem::parse_s16f11(msg);
|
||||
if (!req) return gem::s16f12_pr_job_create_ack(gem::HostCmdAck::ParameterInvalid);
|
||||
auto r = model->process_jobs.create(
|
||||
req->prjobid, req->ppid, req->mtrloutspec,
|
||||
req->prjobid, req->rcpspec.ppid, req->mtrloutspec,
|
||||
[model](const std::string& ppid) {
|
||||
return model->recipes.get(ppid).has_value();
|
||||
});
|
||||
@@ -1061,7 +1061,25 @@ int main(int argc, char** argv) {
|
||||
case gem::ProcessJobStore::CreateResult::Denied_InvalidPpid:
|
||||
ack = gem::HostCmdAck::ParameterInvalid; break;
|
||||
}
|
||||
logfn("S16F11 PJ=" + req->prjobid + " PPID=" + req->ppid +
|
||||
if (ack == gem::HostCmdAck::Accept) {
|
||||
// Persist the optional E40-0705 trailers (MF / recipe-method /
|
||||
// recipe variables / process parameters) on the freshly created PJ.
|
||||
std::vector<gem::RcpVar> rcpvars;
|
||||
rcpvars.reserve(req->rcpspec.rcpvars.size());
|
||||
for (auto& v : req->rcpspec.rcpvars) rcpvars.push_back({v.name, v.value});
|
||||
std::vector<gem::ProcessParam> params;
|
||||
params.reserve(req->prprocessparams.size());
|
||||
for (auto& p : req->prprocessparams) params.push_back({p.name, p.value});
|
||||
model->process_jobs.set_e40_extras(req->prjobid, req->mf,
|
||||
req->prrecipemethod,
|
||||
std::move(rcpvars),
|
||||
std::move(params));
|
||||
}
|
||||
logfn("S16F11 PJ=" + req->prjobid + " PPID=" + req->rcpspec.ppid +
|
||||
" MF=" + std::to_string(static_cast<int>(req->mf)) +
|
||||
" RM=" + std::to_string(static_cast<int>(req->prrecipemethod)) +
|
||||
" rcpvars=" + std::to_string(req->rcpspec.rcpvars.size()) +
|
||||
" params=" + std::to_string(req->prprocessparams.size()) +
|
||||
" -> S16F12 HCACK=" + std::to_string(static_cast<int>(ack)));
|
||||
return gem::s16f12_pr_job_create_ack(ack);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user