corona-warn-app / cwa-wishlist

Central repository to collect community feature requests and improvements. The CWA development ends on May 31, 2023. You still can warn other users until April 30, 2023. More information:
https://coronawarn.app/en/faq/#ramp_down
Apache License 2.0
105 stars 14 forks source link

Generating QR code Payload in C/C++ #485

Open dorianim opened 3 years ago

dorianim commented 3 years ago

What is missing

I would love to have an example on creating a QR code payload in C/C++. (I am planning to create a small cross-platform GUI using Qt around it for use in embedded systems)

Why should it be included

Creating the payload in C is much more light weight and would not require NodeJS.

Where should it be included

Maybe somewhere over here?


Internal Tracking-ID: EXPOSUREAPP-6746

dorianim commented 3 years ago

For others trying to achieve this: I was able to do it by using google protobuf library for C++ :)

jucktnich commented 3 years ago

Could you maybe publish it (if you want). Maybe it will make it to an official repo, so others can use it to...

dorianim commented 3 years ago

Yes, I would love to do so :) My plan is to create an open source OS for raspberrypis which does one thing only: Display a QR code for the CWA which is refreshed once a day.

jucktnich commented 3 years ago

Would you like to open a repo for the c++ file or only for the finished raspberryOS?

dorianim commented 3 years ago

I think it would make most sense to have two:

But they could be merged if you don't want to create two repos.

Ein-Tim commented 3 years ago

@CodeCrafter912

I suggest that you yourself create a repo linked to your GitHub Account. @dsarkar could then transfer this issue with a link to your repository to the developers and they can take a look. Does this sound good to you?

jucktnich commented 3 years ago

I think, you could open a repo in your own account and post a link here. The devs will probably (I'm not a dev) have a look on it and, if there are no bigger problems with it, merge it into an official repo.

dorianim commented 3 years ago

Hi @Ein-Tim Ok, sounds good :) I'll post a link to my repo here, once I got something basic to work with.

dorianim commented 3 years ago

I have published the code. It is very basic at the moment, however. https://github.com/CodeCrafter912/cwa-qr-code-generator

The part where the payload is built starts here: https://github.com/CodeCrafter912/cwa-qr-code-generator/blob/06bd54cb906c18b370bbf78f8699a7e365d270e9/sources/cwaqrcodegenerator.cpp#L79

I will now begin creating the Raspi OS based on buildroot.

heinezen commented 3 years ago

@fynngodau You could add this to https://github.com/corona-warn-app/cwa-wishlist/issues/474 :)


Corona-Warn-App Open Source Team

fynngodau commented 3 years ago

Thanks @heinezen, added to overview, and thanks @CodeCrafter912 for creating this tool. Cheers!

thomasaugsten commented 3 years ago

@CodeCrafter912 Can you please add the original poster template? https://github.com/corona-warn-app/cwa-website/pull/1130#issuecomment-824961991

dorianim commented 3 years ago

Hi @thomasaugsten

No Problem, I'll do that. Is there a landscape version as well?

thomasaugsten commented 3 years ago

There is no landscape version

dorianim commented 3 years ago

Done: https://github.com/CodeCrafter912/cwa-qr-code-generator/blob/main/resources/screenshots/portrait.png

heinezen commented 3 years ago

Hello everyone,

This feature request is now tracked iin our internal Jira (ticked ID: EXPOSUREAPP-6746). The developers and RKI will discuss the proposal. We will report back here on Github if we get any news about a possile implementation.


Corona-Warn-App Open Source Team

dorianim commented 3 years ago

Small update: I started creating the Raspi OS, its not finished yet, though: https://github.com/CodeCrafter912/cwa-qr-code-generator-os

As of now, it boots, reads the configuration from /boot/cwa-qr.conf and starts the cwa-qr-code-generator.

dorianim commented 3 years ago

Another update: I have published the first version as an image for the raspberry pi zero w. :) https://github.com/CodeCrafter912/cwa-qr-code-generator-os/releases/latest

fynngodau commented 3 years ago

@CodeCrafter912 Great news, added to overview.