How to get started with Riverdi STM32 Embedded Displays using TouchGFX

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
foreign [Music] Tech [Music] we have covered so many displays in the past which includes the cheap SBI based displays intelligent HMI displays and the ones embedded by SD on their boards every display has its own advantages and disadvantages cheap displays are cheap but it's very hard to program them and find a compatible Library HMI displays are a bit costlier and it's easier to interface them but most of them are missing a solid designer platform then the SD provides everything you need a decent display a solid designer software and it comes with a price tag but again they don't provide higher resolution displays and also the form factor of the board is quite large so a practical application is very hard today I have another display with me which is manufactured by the company called rivety they are specialized in manufacturing different kinds of displays and yes it includes the one based on stm32 MCU also here you can check the stm32 embedded displays they generally provide the 7-inch and 10.1 inch stm32 based displays rivety has sent me one test unit which is this one right here it is a 10.1 inch TFT display with a resolution of 1280x800 pixels it is based on the stm32h747mcu with 2 megabytes of internal Flash and one megabyte of RAM other than that it also has the 64 megabytes of quad SPI and 8 megabytes of sdram and the best thing about this is that it has the official support from the touch gfx this is how the controller board at the back of the display looks like you can see it has the ports for different peripherals like FD can rs-232 485 and one for the USB this here is the power port to power the display it also has a Rebus connector to connect other Rebus displays manufactured by the rivety here is the swd port to debug the MCU or to load the program into it there is one expansion connector which gives us access to other peripherals like I squared c u art SPI pwm ADC Etc before we go ahead with interfacing the display let's see the unboxing first hello my name is Camille I'm CEO and founder of riverdie and today we will be unboxing our latest stm32 embedded display uh in a size 10.1 inch which is already available on our webshop and through our distribution Network so let's see uh when you will buy a module from Liberty on our Distributors you will buy it in the single package module like this one that I have here and I will I'm gonna show you what you will get inside what is included in the package and what is not included that you may need also to use this display so first when you open the box you will see the package with the cables and the jumpers so let me show you what we what we have here we have two cables one is a power cable and one is a programming cable which is pretty important so let's start first with the power cable so we have a Molex a five pin and in the second version of the display it will be six pin power connector uh which on the both sides has a Molex connector but in most cases you will need to cut this cable and connect it to the power supply uh to to connect the power to the display but the Molex cable for the board is included and the second connector and the second cable we have here is a Molex to IDC connector which is a programming cable and it's already prepared for a Stelling programmer version 2 which is the most common step programmer right now on the market that is not included of course into the display package but you can use this cable connected directly to the STM programmer and then use this small Molex connector and connect to the board and start programming the display which we will show in another video how to start are programming the display okay so let's have a look into the box what else do we have of course we will find the display there so let me take out this one and see what is in there uh the display that I have here is the most sophisticated one which is equipped with a touch screen that is optically bonded to the display so it's like fully equipped version so with the board with stm32 H7 microcontroller all the memories all the iOS connectors and the touchscreen that you can see here so I have a display right now and I will connect it because the display that you will receive from us is already of course tested and programmed with the demo application to show you how does it work so here I have the cable that I already prepared with the power supply I took a typical 12 volt power supply but the power voltage on the connector is is pretty wide it's from 6 to 30 volts so you can check this in detail in the data sheet of course but I use the 12 volt which is very typical power supply that I have I have a connector here and I will connect it right now and what what we should see is a demo application that I mentioned is already programmed so as you see I already have it and of course then we can use the touchscreen as well it's programmed and it's ready to to play with so you can receive this display and immediately check its performance uh and of course to touch performance as well so uh this is all for today you you you know already and now and what to expect when you will buy a single module a display from us with stm32 so as I mentioned you will have the power cable and you will have the programming cable um in the Box included so your start to work with our display should be very fast and easy okay so I wish you a fantastic projects with our displays and please order them from our website on or from our Distributors Network okay thank you very much for today uh bye bye this is the back of the display and here you can see the controller board this here is the power port and this one is the swd we have the USB port the rs-485 and rs-232 there are two Imports a coin battery connector and the Rebus connector you can also see the three buttons on the top left corner the two buttons are user buttons and the third one is to reset the board there is also a Micro SD card connector and lastly we have the expansion connector to connect other devices or to use the i o pins let's see the documents provided by them for this display we have the datasheet the drawing and a 3D viewer file there is an option to customize the order and a getting started page in the customization page you can customize the order as per your need one important point I want to show here is that you can customize the cover glass even up to six millimeters and more so it allows to use the display even outdoor the getting started guide focuses on touch gfx and how to program the display using it since that's what I am covering in this video Let's close it for now we will see the data sheet in a while this 3D file I downloaded earlier I have a b viewer installed to see it this is how it looks in the a b viewer basically you can see the details of all the components used in the display well this could be extremely useful for designers and for mechanical engineers in the designing process let's check the data sheet now here you can see the naming Convention of the display this includes the company name the display standard the screen size resolution Etc here as per the electrical characteristics the display can work with wide range of voltages typically ranging from 12 to 36 volts I am using a 12 volt 1 ampere adapter for it all right now let's talk about the ports first we have the power port if you see here the pins are numbered on the ports and Below we have the details of the pins in the power port we basically need to connect two pins one for the power supply and another to the ground this pin number four can be used to enable or disable the power supply but by default this pin is enabled if you want to turn off the display you simply need to connect it to the ground I am going to leave this pin open as it is anyway internally connected to the vdd you can see the pin outs for other ports here for now I am interested in swd here you can see the connections for six pins and we need to connect them to the exact same pins on the SD link here you can see my power connector I have only connected two pins one to the VCC and another to the ground this is the connection to the SD link here I have connected all six pins to the respective pins on the SD link now we will simply connect the SD link to the swd port and power connector to the power port next is the Rebus connector just in case if you need to connect another display to it then comes the backlight setting you can connect external display via the Rebus connector and select its backlight power source it can be internal 5 volts or the main power supply for details please check the documentation here is the pin out for the expansion connector and these are all the peripherals you can access with it there are two user push buttons connected to pc6 and pv0 also there is a user LED connected to pj10 that is all the information there is in the datasheet let's start the touch gfx and design an application I am going to design a simple application just to show you how to get started with it for the rest you can use all the touch gfx features as mentioned in my other videos make sure you use the new version at least 4.20 onwards here click on create new and search rivety you can click on the result and read about the display on the right this is the 10.1 inch display that I have let's give some name to the project and click create first of all I am going to add a background image here I already have a ping image of the same resolution let's add this image to the project next I am adding a slider and a gauge to this screen slider can have values from 0 to 100. configure the widgets as per your need now we will add one interaction to this screen which will be called when the slider value has changed this will basically call a new function slider updated which we will later write in our IDE the idea here is that the gauge should move as we change the slider to do that we will write a small code in the IDE the designing part is finished so generate the code you can also run the simulator to see if everything is as per your design right now the slider is not changing because we haven't programmed it yet now go to the files here in the main project folder open the cube ID folder now open the project file in the cube ID all right the project has been loaded our entire project will be in the cortex M7 here you can see the main.c file notice that the script already initializes all the peripherals whether you use them or not we are not working with the main file right now so go to generated and open the screen one view base here you will see the function which we defined in the interaction go to the definition of this function and copy it now go to the GUI folder and open the screen 1 View we need to First Define the function in the header file so paste it here now we will call our function in the screen 1 view class this will be basically called whenever the slider value changes and here we will update the gauge with the same value to do that we will call the gauge.set value and pass the value of the slider to it now invalidate the gauge so that new value can take effect this is it let's build the code now let's first check in the simulator if it is working or not you can see the gauge is updating as per the slider value so we are good to go now comes the important part about how to load the program into the display as per I have been told there are two ways to do it you cannot load it via the cube ID you can directly load it via the touch gfx or use the cube programmer to do it but even before that we first need to copy the external loader into the cube programmer directory if you see here in the project structure there is a s t l d r folder it contains the external loader we need so open this folder and copy the loader now go to the directory where the cube programmer is installed in my case it is in C program files SD microelectronics stm32 Cube stm32 Cube programmer here go inside the bin and then external loader now paste the loader here I already have it so I will just replace that one you just need to do it for the first project now I am going to load the project using the touch gfx but we need to restart it first or else it will not see the loader all right let's load our project now click the Run Target to load it to the display it takes a lot of time to build and load the project all right it's finally done now you have to press the reset button at the back to reset the display here we have our project let's see it in action you can see the gauge is responding according to the movement of the slider the slider and gauge both are very responsive in their movement so this is working very well you only need to load the project once from the touch gfx let's say you modified the code and rebuilt the project loading it from touch gfx takes a lot of time so now we will see how to load it via the cube programmer here you go to the debug folder this file flash dot bin is generated whenever you build the project so now we can just load this file and it will not take as much time as with the touch gfx open the cube programmer connect the SD link now go to this download section make sure the address is 0 8 million hexa browse the flash.bin file we just saw and click start programming to program the board remember that this will only load the code to the internal flash so the qspi is unaffected from it I just showed you a very simple application for this display but as I said you can use everything that I have covered in the touch gfx playlist now one very important thing you have to keep in mind even though they provide the ioc file it is not advised to generate the project from it you can refer to it for the pin connections but do not generate the project from it or else it simply won't work as I mentioned in the beginning the script they use pretty much initializes all the peripherals and components so you just have to directly call the functions provided in the library like here is the SD card driver and you already have the function like init right blocks read blocks Etc or here you can see all the files for SD card LED buttons flash Etc so you just have to analyze this project structure and use the functions provided to you this is just like how SD provides the examples in the Repository before we wrap up this video Let's see the demo project for this display go to touch gfx and create a new project select demos and click Port specific demos here are the demos for the rivety boards click create to create the demo project here the demo project has been created now just run the Target from here to load it on the display here you can see the project is running well on the display so I hope you understood how to get started with the rivety stm32 based displays the advantage you can have with it is that there already is a solid designer software available for free and we already know the capabilities of using stm32 as the controller you can purchase the display from rivity website and there is no minimal order requirements so you can order even a single piece the displays are also available in offer from the biggest Distributors like Mouser the link to the website is in the description below the link to download the code is in the description too this is it for this video keep watching and have a nice day ahead [Music]
Info
Channel: ControllersTech
Views: 9,067
Rating: undefined out of 5
Keywords: stm32, stm32f4, f103, discovery, nucleo, stm32f7, stm32G, cubeIDE, sensor, module, tutorial, example, can, i2c, spi, uart, learn, tutorials, touchgfx, gfx, button, display, stm32h7, riverdi, embedded, getting, started, custom, board, slider, gauge
Id: vxGxt4A8V3Y
Channel Id: undefined
Length: 23min 37sec (1417 seconds)
Published: Tue Jan 24 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.