Skip to content

Latest commit

 

History

History
50 lines (30 loc) · 1.74 KB

tutorial.md

File metadata and controls

50 lines (30 loc) · 1.74 KB

tosdb/ tutorial


This tutorial attempts to show example usage of the core tosdb package. Please refer to _win.py, _common.py and _init_.py for more details on the core package; _init_._doc_ for an explanation of the virtual layer; _main_.py for running the package outside of the interactive interpreter; intervalize/ohlc.py for fixed-time intervals(e.g OHLC); and cli_scripts/ for code built on top of the core package.

Comments inside the screen-shots help explain what we are doing and why.

IMPORTANT: Before using tosdb/ be sure to:

  1. build/install the backend C/C++ modules with the appropriate build(x86 vs. x64) for your version of python,
  2. start the TOSDataBridge Service(SC Start TOSDataBridge),
  3. have the TOS platform running, with the correct privileges (i.e if you run as admin you should have passed 'admin' to the tosdb-setup.bat script),
  4. install the tosdb/ package (python setup.py install)

Initialize the library with the init() call:

This loads the shared library into python and tries to automatically connect to the engine. Be sure to use the correct version of the tos-databridge DLL. If you are using branch/version v0.7 and 64-bit python, for instance, you should be using tos-databridge-0.7-x64.dll.

Topics and Items:

TOSDB_DataBlock:

Total Frame:

Topic / Item Frames:

Historical Data:

Historical Data (2):

Historical Data (3):

Miscellany & Clean-Up: