Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can I get to the map? #8

Open
michaelkuzmin opened this issue May 2, 2018 · 10 comments
Open

How can I get to the map? #8

michaelkuzmin opened this issue May 2, 2018 · 10 comments
Labels

Comments

@michaelkuzmin
Copy link

It may be a very stupid question, but could you please describe how I can get my hands on the current map file? I really don't want to simply screenshot my android app screen, there must be a better way. Can I get access to the map without rooting the robot itself? I have the first version of the robot and I want to use it to create a floor plan of my house.
I think you mentioned that maps are stored in robot.db inside the device itself, but that file can only be accessed once the device via rooted, correct? Is there anything on the android device or on the cloud I can use?

@marcelrv
Copy link
Owner

marcelrv commented Nov 3, 2018

There is indeed no direct way to access the map data.
The 2 known solutions: 1) root your device 2) pull the files from the cloud.
For the latter, the way to access cloud files is not fully clear yet.

@michaelkuzmin
Copy link
Author

michaelkuzmin commented Nov 3, 2018

There is indeed no direct way to access the map data.
The 2 known solutions: 1) root your device 2) pull the files from the cloud.
For the latter, the way to access cloud files is not fully clear yet.

thanks. I ended up taking screenshots and stitching them together. like a caveman.

@cryptomilk
Copy link

How are maps uploaded? Can you tell it with an URL where to upload the map?

@FeatureExpert
Copy link

Yes you can. Roborock asks Xiaomi Cloud for pre-signed URL:

{'id': ##MESSAGE_ID##, 'method': '_sync.gen_presigned_url', 'params': {}}

Xiaomi response with URL. It will be used for upload map file:

{'id': ##MESSAGE_ID##, 'result': {'': {'url': 'http://awsde0.fds.api.xiaomi.com/robomap/2019/02/06/##SOME_UNKNOWN_NUMBERS_1##/##DEVICE_ID##_##SOME_UNKNOWN_NUMBERS_2##?Expires=1549420683543&GalaxyAccessKeyId=xxxxx&Signature=yyyyy', 'obj_name': '2019/02/06/##SAME_AS_UNKNOWN_NUMBERS_1##/##DEVICE_ID##_##SAME_AS_UNKNOWN_NUMBERS_2##', 'method': 'PUT', 'expires_time': 1549420656, 'ok': True, 'pwd': 'zzzzz'}, 'ok': True}}

@cryptomilk
Copy link

Ok, so we could implement in valtudo a service and tell the robot to drop the map there :-)

@FeatureExpert
Copy link

Basicaly yes, I'm using this method to store map files on my server for later usage. But I can intercept any message sent from/to roborock and even replace it or part of it on-the-fly. Not sure Valetudo can do similar tricks, as I don't know this software. Keep in mind, this is not an pure image file. Some info about file format can be found here.

@FeatureExpert
Copy link

I think so, but I'm not 100% sure. File format has been slightly changed couple of weeks ago probably due to 'software barrier' feature in roborock firmware.

@cryptomilk
Copy link

cryptomilk commented Apr 7, 2019

FYI: Valetudo has now a map upload feature. The robot uploads map to valetudo.

@snueffel88
Copy link

Hi, it seems to be possible to download the map from the xiaomi server now. However, unfortunately I did not manage to download the map with the xiaomi api URL and the roboroommap url. Can you please provide some details how this works?

@mwargan
Copy link

mwargan commented Sep 18, 2020

I've run into "object not found" on the "awsde0.fds.api.xiaomi.com" server - it seems to be the same when using the DE version of the url suggested in map_v1. Am I using the correct url? The path I'm using looks like "/app/home/roboroommap/xxx/0"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants