File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -111,24 +111,24 @@ def close(self):
111
111
if self .fd > 0 :
112
112
os .close (self .fd )
113
113
114
- def read (self , size = 1 ):
114
+ def readDevice (self , size = 1 ):
115
115
if self .fd > 0 :
116
116
return os .read (self .fd , size )
117
117
raise Exception ("Device %s not open" % self .device )
118
118
119
119
def readBytes (self , size = 1 ):
120
- return bytearray (self .read (size ))
120
+ return bytearray (self .readDevice (size ))
121
121
122
122
def readByte (self ):
123
123
return self .readBytes ()[0 ]
124
124
125
- def write (self , string ):
125
+ def writeDevice (self , string ):
126
126
if self .fd > 0 :
127
127
return os .write (self .fd , string )
128
128
raise Exception ("Device %s not open" % self .device )
129
129
130
130
def writeBytes (self , data ):
131
- return self .write (bytearray (data ))
131
+ return self .writeDevice (bytearray (data ))
132
132
133
133
def writeByte (self , value ):
134
134
self .writeBytes ([value ])
You can’t perform that action at this time.
0 commit comments