Skip to content

Latest commit

 

History

History
 
 

acquisition

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

These instructions refer to the active acquisition server, refer to passive acquisition tutorial if you wish to monitor a directory for newly acquired data passively.

Installing development dependencies

cd <tomviz_repo>/acquisition
pip install -r requirements-dev.txt

Starting the server

cd <tomviz_repo>/acquisition
python -m tomviz.acquisition.cli

This will start the server using a mock API for testing.

Acquistion JSON-RPC interface

Describe

This method returns a description of the parameters that a particular method supports for the currently loaded adapter.

Request

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "method": "describe",
  "params": ["<methodName>"]
}

Response

Returns the parameter description.

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "result": [{...}]
}

Connect

Connect to the instrument

Request

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "method": "connect",
  "params": {...}
}

Response

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "result": {...}
}

Disconnect

Disconnect from the instrument

Request

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "method": "disconnect",
  "params": {...}
}

Response

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "result": {...}
}

## Setting tilt parameters

### Request

```json
{
  "jsonrpc": "2.0",
  "id": "<id>",
  "method": "tilt_params",
  "params": {...}
}

Reponse

Return the current title parameters

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "result": {...}
}

acquisition_params

Request

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "method": "acquisition_params",
  "params": {...}
}

Reponse

Return the current acquisition parameters

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "result": {...}
}

Preview scan

Request

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "method": "preview_scan"
}

Reponse

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "result": "<url>"
}

Where url is URL that can be used to fetch th 2D TIFF

STEM accquire

Request

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "method": "stem_acquire"
}

Reponse

{
  "jsonrpc": "2.0",
  "id": "<id>",
  "result": "<url>"
}

Where url is URL that can be used to fetch th 2D TIFF