cancel
Showing results for 
Search instead for 
Did you mean: 

Touchgfx change complete screen during run time and customized widget creation

Hello, I and using Touchgfx in my project. I want to implement below.

1) During run time , I want to to turn off complete screen.

2) During run time , I want to change complete screen.

3) I want to generate QR code dynamically and also want to clear it sometimes during run time. I got github link and added those files in my project. Still I am not sure how to call it. You have mentioned to call qrCode.setXY(0,0) , qrCode.setQRCode(&code), qrCode.setScale(4) , add(qrCode) methods but I am unable to find it.

Can any one please help ?

50 REPLIES 50

Hello, I found answers of few question. Please help me with below few questions:

1) Whats is the correct way of passing value of QR pixel ? Should I pass similar to below highlighted code from some QR pixel array generated by some library.

0693W000000WgzAQAS.jpg

2) Suppose I want to draw one circle ( this shape may differ based of some logic, Circle is just for example), so i m planing to use same QR widget class as during that time QR code will not be used. I want that background should not change, just wann put shape. How can I achieve this while remaining background as same. Any support from touchgfx on this ?

 Thanks

@Martin KJELDSEN​  Hi, did u get the chance to check ?

I don't know why calling code->at(x... would be slow. it's just looking up a value for some position of the QR code.

/Martn

Ok but i was asking for my above message which I posted around 2 hours before.

@Martin KJELDSEN​  Hi did u get the chance to check? I have below questons.

- Suppose I want to draw one circle ( this shape may differ based of some logic, Circle is just for example), so i m planing to use same QR widget class as during that time QR code will not be used. I want that background should not change, just wann put shape. How can I achieve this while remaining background as same. Any support from touchgfx on this ?

-We was discussing on turning OFF/ON display during run/time. You said its hardware thing. Can you suggest how to do that ?

Thanks

@Martin KJELDSEN​  Any updates? My development is blocked due to this.

1) Whats is the correct way of passing value of QR pixel ? Should I pass similar to above highlighted code from some QR pixel array generated by some library.

There's no correct way. The QR code is just some C++ code. I'm not sure how this all fits into your application. The QR code we supply is just a sample - it auto-generates the entries. If you have some tool to generate for you, you have to figure out how you can "port" the format to our QR code example, or come up with your own way. It's up to you.

2) During Run time if i want to update QR code, How should i make touchgfx to do it ?

Again, i'm not really sure what the structure of your project is. And i'm not really sure what "update QR code" means. Can you be more specific?

3) If I want to clean QR code during run time, how should i do ? Post QR erase , it should go back as background color/image.

Again, i'm not sure what this means. Do you mean, when you're looking at the QR code, the program should wipe it? And be able to receive new values on the fly?

4) Suppose I want to draw one circle ( this shape may differ based of some logic, Circle is just for example), so i m planing to use same QR widget class as during that time QR code will not be used. I want that background should not change, just wann put shape. How can I achieve this while remaining background as same. Any support from touchgfx on this ?

You just want to put a shape on top? Did you check out the shapes available from the designer?

U can ignore 1 to 3 questions, I am looking for answer for below questions.

- Suppose I want to draw one circle ( this shape may differ based of some logic, Circle is just for example), so i m planing to use same QR widget class as during that time QR code will not be used. I want that background should not change, just wann put shape. How can I achieve this while remaining background as same. Any support from touchgfx on this ?

: That shape will be vary so i need to create customized widget similar QR. I can take care of that part. but i want to add image without removing background.

For example I want to put below image. I can generate code and using customize widget but if i put this image , it will have background as white but i want below pixel should go on top background.

In below image , Which all places pixel are white, it should remain as earlier background color.

0693W000000Wqu0QAC.png

Hope its clear

-We was discussing on turning OFF/ON display during run/time. You said its hardware thing. Can you suggest how to do that ?

Re: on/off - You need to check the datasheet/reference manual for your display. Typically you can turn it on and off by sending a specific command.

Just put a shape on top of the background - If the image covers the background, then that image must have full alpha for each pixel in order to be transparent. TouchGFX will handle the rest.

/Martin

Re: on/off - You need to check the datasheet/reference manual for your display. Typically you can turn it on and off by sending a specific command.

Ok but something i need to do for for STM also like LTDC should be OFF, it should not send refresh packet to display etc, Do we have any support on same from STM or should i write ?

Just put a shape on top of the background - If the image covers the background, then that image must have full alpha for each pixel in order to be transparent. TouchGFX will handle the rest.

I am using 16bit color format RRB565 so can't set alpha.