Skip to content

Commit 55caf38

Browse files
author
Daniel Igaz
committed
Fixed incorrect return value of _detect_available_configs function.
1 parent 8101cc4 commit 55caf38

1 file changed

Lines changed: 7 additions & 7 deletions

File tree

can/interfaces/systec/ucanbus.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -181,18 +181,18 @@ def send(self, msg, timeout=None):
181181

182182
@staticmethod
183183
def _detect_available_configs():
184-
configs = {}
184+
configs = []
185185
if Ucan is None:
186186
log.warning("The SYSTEC ucan library has not been initialized.")
187187
else:
188188
for index, is_used, hw_info_ex, init_info in Ucan.enumerate_hardware():
189-
configs += {'interface': 'systec',
190-
'channel': Channel.CHANNEL_CH0,
191-
'device_number': hw_info_ex.device_number}
189+
configs.append({'interface': 'systec',
190+
'channel': Channel.CHANNEL_CH0,
191+
'device_number': hw_info_ex.device_number})
192192
if Ucan.check_support_two_channel(hw_info_ex):
193-
configs += {'interface': 'systec',
194-
'channel': Channel.CHANNEL_CH1,
195-
'device_number': hw_info_ex.device_number}
193+
configs.append({'interface': 'systec',
194+
'channel': Channel.CHANNEL_CH1,
195+
'device_number': hw_info_ex.device_number})
196196
return configs
197197

198198
def _apply_filters(self, filters):

0 commit comments

Comments
 (0)