From 8719b84a95805d109e21c20f05a0164315e1b38a Mon Sep 17 00:00:00 2001 From: Vasilii Chernov Date: Wed, 2 Mar 2016 10:26:13 +0100 Subject: Move scripts handing code from py.c to Python wrap --- pyserver/api_server.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'pyserver') diff --git a/pyserver/api_server.py b/pyserver/api_server.py index 18ee1f8..c170a19 100644 --- a/pyserver/api_server.py +++ b/pyserver/api_server.py @@ -1,7 +1,7 @@ import os import sys -import pcipywrap +import pcilib import time import json @@ -471,7 +471,7 @@ class PcilibServerHandler(BaseHTTPRequestHandler): ' command: run_script - Run specified script\n' ' required fields\n' - ' script_name: - script name (with extension)\n' + ' script_name: - script name (without extension)\n' ' value: - input value in json format\n' '\n' @@ -503,9 +503,9 @@ class PcilibServerHandler(BaseHTTPRequestHandler): class ApiServer(MultiThreadedHTTPServer): def __init__(self, device='/dev/fpga0', model=None, adress=('0.0.0.0', 9000)): #redirect logs to exeption - pcipywrap.redirect_logs_to_exeption() + pcilib.redirect_logs_to_exeption() #pass Pcipywrap to to server handler - self.lib = pcipywrap.Pcipywrap(device, model) + self.lib = pcilib.Pcilib(device, model) def handler(*args): PcilibServerHandler(self.lib, *args) MultiThreadedHTTPServer.__init__(self, adress, handler) -- cgit v1.2.3