-
Notifications
You must be signed in to change notification settings - Fork 19
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
Descriptions for undocumented characteristics #9
Comments
Ok, it also looks like the "XX" unknown field in the current readings GATT is actually a bitfield that describes the color of the current reading. If bit 1 is not set, it's either green, or unspecified (by bit zero). |
so, in decimal: ;) |
LMAO yes, maybe it's just an enum! You should see how they're parsing it in the aranet4 app... I'm tempted to post in their forum about it, but I don't want them to get worried about people reverse engineering their code and then start obfuscating it. They shouldn't, after all, it's a super simple react native app, and if people know how to use the protocol, of course, then more people might buy the device! |
Thanks! Docs have been updated. |
Ok, why not? So the funny thing about the "color" field, again is the way they decided to parse it. If it was intended to just be 1,2,3, why the heck would they do this?
Honestly, it is the most unintentionally obfuscated way to parse a bitfield that I've ever seen :D |
do you know what is the meaning of the data one gets back when passing a |
Which one is |
this: Aranet4-Python/aranet4/client.py Line 262 in 9e12cb7
when I was testing my Go driver (here), I noticed I could pass |
Ah, you're talking about what @Anrijs calls the "Set history parameter"? If you pass 6, what happens? I'm not quite good enough of a reverse engineer yet with the metro packer, but it looks like 0 and 5 are special, and refer to variables. There appear to be some bits in the calibration code that write "ts" somewhere? That characteristic seems to handle a lot of arbitrary things, like setting bluetooth range, |
And no, the firmware image for the device is encrypted, I've gone down that route. And I'm not yet going to rip mine apart to dump it. |
with |
I've figured how to retrieve and interpret the history data using First, you write a 4 byte value with the following layout to
Then you repeatedly read
When Some notes:
|
Hi Elyscape, I am trying to implement what you have explained here but things get over my head Here is my reference link FYI my ESP32 acts as Aranet4 device, sending data to the Aranet4 Home On the app when I hit the graph icon, I see this on Arduino's serial monitor
That means the app is asking for data history logs beloging to CO2 from the device, to which I reply with
The app shows a prompt "Loading 0%..." Then I keep receiving back Could you kindly correct my data structure in the response above ? and also correct it on how It should look like each time I receive Much Thanks in advance |
This is your mistake. The response should be empty, and the data you're sending back in the response is actually read from the
|
Hi Eli, Thansk for your input I am seeing a little success here here is my code snippet so far
as soon as I am seeing I set whenever the app reads from Here is what I am seeing on the app, "Loading Carbondioxide 10%" , "Loading Carbondioxide 20%" "Loading Carbondioxide 30%" Then It gets all the way past "Loading Carbondioxide 100%" going upto "Loading Carbondioxide 1620%" and gets stuck there the app keeps reading from I thought It is supposed to stop at 100% as soon as Thank You Again |
My guess is that there's an off-by-one error. Try setting |
FYI: |
As part of work on an app I run, I did some spelunking. I have figured out the purposes of the characteristics that are not yet documented:
I haven't written out the data layouts yet or wrote code to parse them, but thought I'd let you know!
The text was updated successfully, but these errors were encountered: