Skip to content

Commit 3e09ebf

Browse files
committed
Merge remote-tracking branch 'origin/master'
2 parents 83af0aa + b4d35d8 commit 3e09ebf

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,10 @@ async def main():
6161
sphere = cloud.spheres.find('awesomeSphere')
6262
for crownstone in sphere.crownstones:
6363
await crownstone.turn_on()
64+
65+
# close session
66+
# required when ran as standalone program, optional if ran in integration.
67+
await cloud.close_session()
6468

6569
asyncio.run(main())
6670
```
@@ -77,6 +81,10 @@ cloud.initialize_sync()
7781
# get a crownstone and turn it on
7882
crownstone = cloud.get_crownstone('awesomeCrownstone')
7983
crownstone.turn_on_sync()
84+
85+
# close session
86+
# required when ran as standalone program, optional if ran in integration.
87+
cloud.close_session_sync()
8088
```
8189

8290
### Initialization

0 commit comments

Comments
 (0)