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

New 'lf hitag pwmdemod' cmd decoding the reader messages from graph b… #1515

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

codeflakes0
Copy link

This new command is based on the 'data rawdemode' commands.
It is intended to be used on graph buffer data captured with a previous 'lf search'
Since the decode is done in variable bit range I've had to modify proxguiqt.cpp to take into account. Not sure
if this was the best way to deal with this problem.
There is a know bug when zooming and scrolling, the displayed demodulation bits are shifted and do not follow the signal.

@iceman1001
Copy link
Collaborator

hm.. interesting..
maybe it should have been under data pwm and not under hitag.
Not sure about the graph buffer doing.
the normal way is to copy it to your local array, put all demods into the demod array...
and thats it.

@codeflakes0
Copy link
Author

Yes I though of adding the feature to the data cmd too as it's a very generic command. You decide.
The graph buffer I added was necessary because with this type of decode the period is not constant so the demodulation was not displaying correctly of top of the signal. It was progressively pushed too far on the right. But it is entirely possible this was not necessary and I just did not understand the graph code enough.

@github-actions
Copy link

You are welcome to add an entry to the CHANGELOG.md as well

idx_max = idx;
}

uint32_t period = idx - last_wave_start;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would this work as a int32_t? As it currently stands, builds are failing under the Darwin compiler due to period being unsigned.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What happens if "period" and "last_wave_start" are made size_t (to match idx) rather then uint32_t ?
i.e. is size_t the same size as uint32_t ? (on some systems I believe size_t is 8 bytes, which would make it 64 bits, twice the size of a unit32_t.

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.

4 participants