-
Notifications
You must be signed in to change notification settings - Fork 47
Conversation
…temperaturSensorLogic
Co-Authored-By: Jonathan Wang <jonathanwangg@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just some small comments to address and it should be good to go
@@ -0,0 +1,13 @@ | |||
export interface ISliderProps { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this file is not being used anywhere. Has it been added by accident maybe ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes its an older version that I forgot to delete
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this pls
} | ||
|
||
self.pixels = Pixel(self.__state) | ||
self.__abs_path_to_code_file = '' | ||
|
||
|
||
@property | ||
def acceleration(self): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is the link of the library that's being used for acceleration on the device : https://github.com/adafruit/Adafruit_CircuitPython_LIS3DH/blob/master/adafruit_lis3dh.py
I think it's worth taking a look to make sure we're matching the logic in the library is providing for the physical device
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah the lines 83-84 are interesting! There using namedtuple for their return type!
# the named tuple returned by the class
AccelerationTuple = namedtuple("acceleration", ("x", "y", "z"))
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're both right it is an interesting reading I guess I can should use a named tuple. Appart from that @Christellah it conforms to this library and particularly it's uses in the cpx.express library who uses a particular case of the acceleration (fixed range =8_G). Thanks for the reminder
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested and seems to work
Please delete the file src/view/components/toolbar/Toolbar_ressources.tsx
before merging
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good other than the extra file
@@ -0,0 +1,13 @@ | |||
export interface ISliderProps { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this pls
Description:
This PR adds the API call for the motion sensor. New states have been added to the simulator and an acceleration function has been written in express.py.
Type of change
Limitations:
Testing:
Checklist: