Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
D
domotikad
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
domotika
domotikad
Commits
06f49b04
Commit
06f49b04
authored
Sep 02, 2014
by
nextime
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added dmrv4 support module
parent
a6f4eef2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
61 additions
and
0 deletions
+61
-0
DMRv4.py
domotika/boards/modules/DMRv4.py
+61
-0
No files found.
domotika/boards/modules/DMRv4.py
0 → 100644
View file @
06f49b04
###########################################################################
# Copyright (c) 2011-2014 Unixmedia S.r.l. <info@unixmedia.it>
# Copyright (c) 2011-2014 Franco (nextime) Lanza <franco@unixmedia.it>
#
# Domotika System Controller Daemon "domotikad" [http://trac.unixmedia.it]
#
# This file is part of domotikad.
#
# domotikad is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from
domotika.boards
import
iboards
from
domotika.boards.boardtype
import
BaseBoard
,
ANABoard
,
INPBoard
,
OUTBoard
from
zope.interface
import
implements
from
twisted.plugin
import
IPlugin
try
:
import
hashlib
md5
=
hashlib
md5
.
new
=
hashlib
.
md5
sha1
=
hashlib
.
sha1
except
:
import
md5
import
sha1
class
DMBoard
(
INPBoard
,
ANABoard
,
OUTBoard
,
BaseBoard
):
hasAnalogs
=
True
hasOutputs
=
True
hasInputs
=
True
hasRelays
=
True
hasAmperometers
=
True
fwtype
=
'relaymaster'
firstAna
=
13
numAna
=
8
numInp
=
12
numOut
=
6
class
Board
(
object
):
implements
(
IPlugin
,
iboards
.
IDMBoards
)
def
getBoard
(
self
,
host
,
port
,
pwd
,
lang
):
return
DMBoard
(
self
.
core
,
host
,
port
,
pwd
,
lang
)
board
=
Board
()
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment