Skip to content

Conversation

mochipon
Copy link
Owner

@mochipon mochipon commented Jul 26, 2021

Thanks to @Chabiichi-san, I was able to get one SESAME bot. His offer is very much appreciated.

This PR is the initial try to support SESAME bot. This should work anyway but I am still checking the stability.

I have two concerns at this point.

  1. Looking at the class reference, I noticed that there are some pretty big differences between the iOS and Android SDKs. That is, in some classes, the implementation of the Android SDK directly holds byte data without using an easy-to-understand class. For instance, focusing on CHSesameBotMechSettings, the Android SDK implementation does not use CHSesameBotLockSecondsConfiguration.
    Although the main reference for me is reverse engineering of the Android SDK, I have implemented some iOS-only classes (e.g., CHSesameBotLockSecondsConfiguration) to organize the data easily for users.
  2. In the official app, SESAME bot can only perform click operations and cannot be used to make complex parameter adjustments. However, according to the class reference, SESAME bot appears to be capable of a variety of actions and tuning (e.g., CHSesameBotUserPreDir, CHSesameBotLockSecondsConfiguration).
    Unfortunately, in reality, those parameters do not seem to be reflected in the actual operation. For instance, in the factory default settings, lockSeconds and unlockSeconds are set to 10 seconds each, but the arm is actually running for less than 10 seconds. For now, I leave it anyway and wait for the firmware updates!

solves #13

@mochipon mochipon changed the title Support SESAME bot [WIP] Support SESAME bot Jul 26, 2021
@codecov
Copy link

codecov bot commented Jul 26, 2021

Codecov Report

Merging #15 (c72999b) into main (d9eb117) will decrease coverage by 1.72%.
The diff coverage is 90.36%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main      #15      +/-   ##
==========================================
- Coverage   95.63%   93.90%   -1.73%     
==========================================
  Files           7        8       +1     
  Lines         824     1132     +308     
==========================================
+ Hits          788     1063     +275     
- Misses         36       69      +33     
Impacted Files Coverage Δ
pysesameos2/chsesamebot.py 84.25% <84.25%> (ø)
pysesameos2/ble.py 99.45% <100.00%> (-0.04%) ⬇️
pysesameos2/chsesame2.py 83.96% <100.00%> (+1.55%) ⬆️
pysesameos2/helper.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d9eb117...c72999b. Read the comment docs.

@mochipon mochipon changed the title [WIP] Support SESAME bot Support SESAME bot Jul 27, 2021
@mochipon mochipon merged commit e1a6dd7 into main Jul 27, 2021
@mochipon mochipon deleted the feat/bot branch September 24, 2021 03:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant