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

Missing Pi Model #26

Closed
axwaxw opened this issue Dec 2, 2020 · 2 comments
Closed

Missing Pi Model #26

axwaxw opened this issue Dec 2, 2020 · 2 comments

Comments

@axwaxw
Copy link

axwaxw commented Dec 2, 2020

My pi model was missing. I have added it to the list locally:

static async getJpegSignature() {
     const systemInfo = await si.system();
     switch (systemInfo.model) {
         case 'BCM2711':
         case 'BCM2835 - Pi 3 Model B':
         case 'BCM2835 - Pi 3 Model B+':
         case 'BCM2835 - Pi 4 Model B':
         case 'BCM2835 - Pi Zero':
         case 'BCM2835 - Pi Zero W':
         case 'Raspberry Pi 4 Model B Rev 1.1': // <-------------------------- HERE
             return Buffer.from([0xff, 0xd8, 0xff, 0xdb, 0x00, 0x84, 0x00]);
         default:
             throw new Error(`Could not determine JPEG signature. Unknown system model '${systemInfo.model}'`);
     }
 }
@hansnn
Copy link

hansnn commented Dec 5, 2020

Same here, except my version is 'Raspberry Pi 3 Model B Rev 1.2'

@gregnr
Copy link
Contributor

gregnr commented Dec 13, 2020

Hi @axwaxw, thanks for the issue. We have received a number of reports now about Pi model breaking.

As a fix we have decided to remove the Pi model check altogether, since so far every model appears to use the same JPEG signature. This makes the library less brittle to changes that are outside of our control.

More details can be found here: #23 (comment)

This change is available now on v0.3.4.

@gregnr gregnr closed this as completed Dec 13, 2020
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

No branches or pull requests

3 participants