Commit 8baee562 authored by Martin Drechsler's avatar Martin Drechsler

added propsbase file which was needed in windows

parent cfd576ca
from __future__ import absolute_import, division, print_function
from builtins import * # @UnusedWildImport
from mcculw import ul
class Props(object):
"""The base class for classes that provide hardware information for the
library examples. Subclasses of this class may change hardware values.
It is recommended that the values provided by these classes be
hard-coded in production code.
"""
def __init__(self, params): pass
def get_config_array(self, info_type, board_num, count_item, value_item,
wrapper_type=None):
result = []
count = ul.get_config(info_type, board_num, 0, count_item)
for item_num in range(count):
config_value = ul.get_config(
info_type, board_num, item_num, value_item)
if wrapper_type == None:
result.append(config_value)
else:
result.append(wrapper_type(config_value))
return result
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment