Closed chrostek closed 4 years ago
@chrostek Thx for your contribution :+1: ! I just had a look and the change really is quite minimal. Nice!
I do have two requests for your pull request before merging it:
You're using the length of the data to identify if we're talking to a normal sensor or to a ropot. Please move this check into a new function "is_ropot()" or something similar so that it's clear why you're doing this check and then use this function instead of the len(data)>24
check, where you need to check.
Please add a test case with some test data for a ropot so that we make sure this use case keeps working in case of future changes.
close/open to trigger a new build
I'm no python programmer, so i asked a friend to implement your request. unfortunately my ropot seems to be dead (no bt connection to app or miflora anymore), so i cannot test the new changes.
very basic implementation of ropot. gives back false for nonexistant value MI_LIGHT for ropot