Skip to content

Commit 0e51356

Browse files
Added last parts
1 parent 3401348 commit 0e51356

10 files changed

+22
-19
lines changed
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading

content/hardware/10.mega/shields/giga-display-shield/tutorials/13.appwizard-guide/content.md

Lines changed: 22 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,7 @@ tags: [Display, appwizard, segger, GUI]
77

88
## Introduction
99

10-
Segger's app wizard is a graphical framework for building powerful UIs, and is fully compatible with the GIGA Display Shield. It allows you to build UIs, using pre-made widgets like buttons, images, loading bars, sliders, checkboxes, etc. It also allows you to fully customize the screenspace on the display. In this guide, we will go through some of the different components and interactions, so you can learn how to best implement it in your projects.
11-
12-
![Appwizard full demo running on the GIGA Display Shield](assets/)
10+
Segger's app wizard is a graphical framework for building powerful UIs, and is fully compatible with the GIGA Display Shield. It allows you to build UIs, using pre-made widgets like buttons, images, loading bars, sliders, checkboxes, etc. It also allows you to fully customize the screenspace on the display. In this guide, we will go through some of the different components and interactions, so you can learn how to best use AppWizard for your own projects.
1311

1412
## Hardware & Software Needed
1513

@@ -61,41 +59,45 @@ First add a textbox by clicking the **Text** box in the "Add objects" section. T
6159

6260
![Textbox added](assets/appwizard-text-box.png)
6361

64-
Next a variable is needed to keep track of the value. In the bottom left "Rescoureces" section press the **Open variables window** button. This will open a window where variables can be managed. Press **Add variable** and then rename the variable to something relevant so it is easier to keep track of later, here we will name it "ID_BUTTON_VAR".
62+
Next a variable is needed to keep track of the value. In the bottom left "Resources" section press the **Open variables window** button. This will open a window where variables can be managed. Press **Add variable** and then rename the variable to something relevant so it is easier to keep track of later, here we will name it "ID_BUTTON_VAR".
6563

66-
![Variables window highlighted in App Wizard](assets/appwizard-variable%20window.png)
64+
![Variables window highlighted in App Wizard](assets/appwizard-variable-window.png)
6765

6866
Now we need to add interactions for the button and text. Press the **+** button in the interactions box to add an interaction. Set the variable as the "Emitter", the signal should be "VALUE_CHANGED", job should be "SETVALUE" and the receiver should be the text box which here is "ID_TEXT_00". Now the text will be set to the same value as the variable.
6967

70-
To add the buttons interaction, set the emitter as the button, the signal should be "RELEASED", so that the value increses when the button is released. The job should be "ADDVALUE" and the receiver should be the variable, so the value gets added to the variable. In the window that pops up the increment of the value added to the variable, here we set it to "1". You can try out the interaction by pressing the **Start play mode** in the upper right corner of the "Editor" window.
68+
To add the buttons interaction, set the emitter as the button, the signal should be "RELEASED", so that the value increases when the button is released. The job should be "ADDVALUE" and the receiver should be the variable, so the value gets added to the variable. In the window that pops up the increment of the value added to the variable, here we set it to "1". You can try out the interaction by pressing the **Start play mode** in the upper right corner of the "Editor" window.
69+
70+
![Button interactions added](assets/appwizard-button-text-interactions.png)
7171

7272
### Progress Bar
7373

7474
Now lets try adding a progress bar to the previous interaction. Start by pressing the **progbar** button and set the initial value to "0". Set the min value to "0" and max value to "100". Now add an interaction with the emitter as the button variable, the signal to "VALUE_CHANGED", job as "SETVALUE" and the receiver as the progress bar. Now try it out in play mode and you will see the progress bar increase whenever the button is pressed.
7575

76+
![Progress bar and interactions](assets/appwizard-progbar-interactions.png)
77+
7678
### Slider And Gauge
7779

7880
Now let's try adding a slider and gauge to the project. Press the **Gauge** button in the top left menu. Set initial value to "0", the min value to "0" and max value to "100".
7981

82+
![Project with the gauge added](assets/appwizard-create-gauge.png)
83+
8084
Next create a slider by pressing the **Slider** button on the top left menu. You can configure the visual elements of the slider in the right "Properties" menu.
8185

82-
![Project with slider and guage]()
86+
![Project with slider and gauge](assets/appwizard-create-slider.png)
8387

8488
Now there needs to be a variable that will keep track of the value, press the **Open variables window** button in the bottom left.
8589

86-
![Variable window button highlighted]()
87-
8890
Press **Add variable** and then rename the variable to something relevant so it is easier to keep track of later, here we will name it "ID_SLIDER_VAR".
8991

90-
![Variable window]()
92+
![Variable window](assets/appwizard-variable-window-final.png)
9193

9294
Now to add the interaction that will fill the gauge when the slider is moved. First, create a new interaction, set the emitter as the slider variable, the signal should be "VALUE_CHANGED". The job should be "SETVALUE" and the receiver should be the gauge. Now create the interaction that makes the slider change the variable. Create a new interaction and set the emitter as the slider, the signal should be "VALUE_CHANGED". The job should be "SETVALUE" and the receiver should be the slider variable.
9395

94-
![Image of all the interactions]()
96+
![Image of all the interactions](assets/appwizard-final-project.png)
9597

9698
## Exporting the project
9799

98-
In AppWizard, go to **File -> Export & Save** in the upper left of the window. Now open the folder of the project. Create a new folder which we will put the exported files into, in this new folder create another folder named **src**. Now from the exported project folder, copy the content from the **Resource** and **Source** folders into the newly created **src** folder.
100+
In AppWizard, go to **File -> Export & Save** in the upper left of the window. Now open the folder of the project. Create a new folder which we will put the exported files into, in this new folder create another folder named **src**. Now from the exported project folder, copy the content from the **Resource** and **Source** folders into the newly created **src** folder. Take all the files out of the folders before putting them in the **src** folder, if you have any folders inside of the **src** folder it will not import into the Arduino IDE later.
99101

100102
![Folder structure](assets/appwizard-demo-folder-src.png)
101103

@@ -136,15 +138,16 @@ void loop() {
136138

137139
![Examples folder structure](assets/appwizard-examples-folder.gif)
138140

139-
Now all that is left is to import this whole folder as a library into the Arduino IDE.
141+
Now all that is left is to import this whole folder as a library into the Arduino IDE. First compress the folder into a .zip format. And then in the Arduino IDE go to **Sketch -> Include library -> Add .ZIP Library**. Then select the created .zip file and add it.
142+
143+
![Importing library in Arduino IDE](assets/appwizard-library-include.png)
140144

141-
## Conclusion
145+
Now the demo sketch should be accessible under the examples tab inside the library. The library will have the name given inside the **library.properties** file.
142146

143-
This guide went through the building blocks of the different components that can be implemented with emWin. To see these examples in a full running example sketch go to **File > Examples > Arduino_H7_Video > emWinDemo**.
147+
![Showing example sketch](assets/appwizard-library-example.png)
144148

145-
![Example in the IDE](assets/example-in-ide.png)
149+
Now select your board and upload the sketch. The GUI created in AppWizard should now display on the GIGA Display Shield!
146150

147-
This demo sketch will show the different components using a screen manager in a 2x2 grid.
151+
### Conclusion
148152

149-
## Next Step
150-
emWin is a comprehensive library and GUI framework that has a lot of customizability, if you are interested in playing around more with it, you can find many different examples and widgets on the official website for [Segger® emWin](https://wiki.segger.com/Main_Page). The code on the website can easily be adapted into a sketch for the GIGA Display Shield.
153+
Now you have an idea of how to use the basic features of AppWizard! With interactions and visual elements the possibilities of design solutions are endless. This tutorial also showed how easy it is to import your design to your Arduino board using the Arduino IDE. You are now ready to create your own design and play around with AppWizard!

0 commit comments

Comments
 (0)