Example #1
0
bool
CAI302::UploadFileBinary(Port &port, unsigned i, FileBinary &data,
                         OperationEnvironment &env)
{
  assert(i < 64);

  char cmd[16];
  snprintf(cmd, sizeof(cmd), "B %u\r", 256 + i);
  return UploadLarge(port, cmd, &data, sizeof(data), env) == sizeof(data);
}
Example #2
0
bool
CAI302::UploadFileSignatureASCII(Port &port, FileSignatureASCII &data,
                                 OperationEnvironment &env)
{
  return UploadLarge(port, "B S\r", &data, sizeof(data), env) == sizeof(data);
}
Example #3
0
int
CAI302::UploadFileData(Port &port, bool next, void *data, unsigned length,
                       OperationEnvironment &env)
{
  return UploadLarge(port, next ? "B N\r" : "B R\r", data, length, env, 15000);
}