Skip to content

Update getImage.py - #61

Open
SaleSlave wants to merge 1 commit into
brianrho:masterfrom
SaleSlave:master
Open

Update getImage.py#61
SaleSlave wants to merge 1 commit into
brianrho:masterfrom
SaleSlave:master

Conversation

@SaleSlave

Copy link
Copy Markdown

BMP resolution fix

BMP resolution fix
@hbegytrewqetyuiouytre

Copy link
Copy Markdown

I still have these errors
`❯ python main.py /dev/ttyACM0 57600 tests/9.bmp
IMAGE-TO-PC example
Found fingerprint sensor!
Capacity: 1000
Packet length: 128

Place a finger.
.
.
Image taken.
Starting image stream...
Read timed out.

elia@nixosaurus ~/esame/impronte  python v3.13.13 via  impure (nix-shell-env) took 11s
❯ file tests/9.bmp
tests/9.bmp: PC bitmap, Windows 3.x format, 256 x -288 x 8, image size 73728, resolution 2835 x 2835 px/m, cbSize 74806, bits offset 1078`

also i cant convert it

@SaleSlave

SaleSlave commented Jun 11, 2026

Copy link
Copy Markdown
Author

I still have these errors `❯ python main.py /dev/ttyACM0 57600 tests/9.bmp IMAGE-TO-PC example Found fingerprint sensor! Capacity: 1000 Packet length: 128

Place a finger. . . Image taken. Starting image stream... Read timed out.

elia@nixosaurus ~/esame/impronte  python v3.13.13 via  impure (nix-shell-env) took 11s ❯ file tests/9.bmp tests/9.bmp: PC bitmap, Windows 3.x format, 256 x -288 x 8, image size 73728, resolution 2835 x 2835 px/m, cbSize 74806, bits offset 1078`

also i cant convert it

I'm not creator of this script, just fixed a little part with quality loss, but was able to download BMP with it. I think you can't convert because of timeout. Did you try "image magick" for convertion? Can you open BMP in Windows photo?

@hbegytrewqetyuiouytre

Copy link
Copy Markdown

I still have these errors `❯ python main.py /dev/ttyACM0 57600 tests/9.bmp IMAGE-TO-PC example Found fingerprint sensor! Capacity: 1000 Packet length: 128

Place a finger. . . Image taken. Starting image stream... Read timed out.

elia@nixosaurus ~/esame/impronte  python v3.13.13 via  impure (nix-shell-env) took 11s ❯ file tests/9.bmp tests/9.bmp: PC bitmap, Windows 3.x format, 256 x -288 x 8, image size 73728, resolution 2835 x 2835 px/m, cbSize 74806, bits offset 1078`

also i cant convert it

I'm not creator of this script, just fixed a little part with quality loss, but was able to download BMP with it. I think you can't convert because of timeout. Did you try "image magick" for convertion? Can you open BMP in Windows photo?

I can open it in eye of gnome (photo viewer), like the bottom half is black
The header is broken because the sensor (r307s) produces a smaller image for some reason, i corrected this by dumping the raw data of the bmp to a .bin with dd and recomposed the file and was able to convert it (basically i fixed the header) but i think im losing data
Imagemagick is what convert and magick are, theyre both the same program
Im using an arduino uno and i connected the sensor correctly btw. 5v, gnd, d2 and d3, the remaining two pins (5-6) are just isolated with electrical tape and let there

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.

2 participants