2022-04-07 12:44 AM
Hi,
I am using STM32F469I-DISCO with touchGFX on it, and I would like to reduce power consumption. I managed to set the brightness of LCD to lowest when no user activity for more than 30sec.
I am resetting brightness as soon as the user touch the screen.
I would like to know if it is possible to use sleep or stop mode for reducing power consumption as much as possible. My concern is about how to wake up the system, since I need to check if user has touched the screen?
Second, is using an ammeter on IDD (by removing the jumper) the right way to measure power consumption?
Thanks for any help,
Best regards.
Clément Devevey
2022-04-08 04:40 AM
Update: removing jumper and replacing it with ammeter (it displays 500 uA) makes the code not executed anymore.
Any hint about this issu?
2022-04-12 05:05 AM
Hi Clement,
I've spent quite a bit of time with that DISCO board, trying to enter STOP mode and exit using the touchscreen. See this post. I am not using SLEEP mode, because I didn't want to deal with FreeRTOS tickless idle mode just yet.
I have no idea why your inline IDD meter causes a problem. I have my digital multimeter connected inline, and it works fine. That measurement provides the current drawn by the microcontroller itself, (VDD_MCU) and nothing else.
I am curious as to how you were able to reduce current to 500uA at IDD. I could not get it to go that low with the DISCO board in STOP mode. I could only get down to ~4mA. Please keep us updated with your progress.
BTW, I changed my AHB Prescaler in Clock Configuration to /4, and that made a huge difference in power consumption while still having acceptable TouchGFX performance for animations.
2022-04-14 01:17 AM
Hi sorry I can't login to my other account anymore. It says to clear my browser cookies.. but here I am.
I was using an ammeter with µA scope that's why it showed 500 µA (the max it could measure) and didn't worked.
Now I found an ammeter with mA scope and it shows 100mA. But setting brightness to 0 doesn't affect the power consumption, seems weird.
Thanks for the tips, I will try those.
2022-04-14 05:12 AM
Sorry, I didn't quite comprehend what you said in your earlier post. Yes, your current-limited ammeter was causing a voltage drop, so the MCU could not run. Also, setting the brightness to 0 will not affect the IDD measurement because you are only affecting the 5V BL_VDD power supply (see schematic). You would need to measure the 5V supply to see a change. Also, the IDD jumper is used to isolate just the MCU current, so it will not see any change in current resulting from changes to the brightness.
My recommendation to you if you are working on power consumption issues is to monitor IDD for the MCU, but also you need to monitor your total power consumption if you are supplying E5V to the board. In my case, I wanted to see if the backlight would run directly off a battery and also monitor the 5V current, so I removed SB8 and SB2, and I have one variable supply connected to 5V (pin 5 on CN6), and another 3V supply on 3V3 (Pin 4 of CN6), with no jumpers attached at JP2. You can get a much better picture of how your system is using power.
Also, with respect to your PM about using the touchscreen for wakeup, you need to read the reference guide and learn about events vs interrupts. I am setting up the pin LCD_INT to generate an event on its falling edge (you can do this in CubeMx by configuring JP5's GPIO mode to External Event Mode with Fallng edge trigger detection. Because I am using this purely as a wakeup from STOP mode, I wanted it to be an event rather than an interrupt. The Reference Manual for the MCU will give you more details about all of this.
2022-04-14 07:40 AM
Ok so first thanks for not giving me the answer away. It made me search answers on the Reference Manual. I understand better NVIC - EXTI + Event/Interrupt.
I also found the LCD_INT pin on the schematic: (by the way, why schematics for this board are not on the official datasheet from ST? I found them on userwiki manual website.
I guess you meant PJ5 GPIO.
Let me sum up, so the idea is so to set the LCD_INT as an external Event, falling edge trigger. With this config, even if LCD is sleeping, and LCD display is off, it will still trigger and wakeup from stop mode?
I still don't get how anyone can find that LCD_INT is the pin that is lowered when user touch screen? The LCD_INT occurs 0 time on LCD datasheet neither on Reference Manual.
Finally I'm curious to know how did you remove Solder Bridge? I saw on youtube a guy doing tin solder on it.
Anyway, thanks for the help, I really appreciate it.
Best regards
2022-04-14 08:05 AM
The touchscreen is always powered on the DISCO board. You can easily monitor the LCD_INT signal with an O-scope at R36 on the connector side while interacting with the touchscreen to see its behavior. If you want to learn more about the touchscreen controller, download the datasheet for the FT6x06 series of touch controllers here.
The entire schematic and Altium board layout for the DISCO board can be found on ST's web site. If I recall, you have to find the STM32F469i-DISCO and it should be one of the documentation items you can download.
LCD_INT is just ST's net name for the signal, so you would not find it on a datasheet, and the touch panel is not a part of the LCD, it is a separate component that gets attached.
On my board, SB2 and SB8 were 0 ohm resistors, so I just used by solder station with a tweezer attachment. If it's just a solder blob, you can get desoldering braid and suck it up with a soldering iron.
I'm getting the impression you're not too familiar with electronics and hardware, so I admire your bravery in tackling this ;)
You are right, it is hard to find information, so you need to dig deep. In the CubeIde project, I found driver files called otm8009a.c and ftx606.c (they are BSP components in the project tree), and from there searched the web for datasheets for the LCD display controller and the touchscreen controller. All of that was needed to investigate low power mode entry. Knowledge is power.
2022-04-14 09:04 AM
Ok so update:
I end up as you mentionned in your post: It seems that sometimes VSYNC doesn't have enough time to start.
I added some HAL_DELAY like everywhere. It seems to work.
I will try to figure it out tomorow, which method need more time.
Regards
2022-04-14 09:17 AM
I spent a great deal of time with that (days), and in my latest post about the VSYNC I have added the correct delays in the DSI command sequence based on the OTM8009A datasheet. That seems to be the missing link. If you follow that routine exactly, it should work. I recommend also searching for the OTM8009A datasheet and reading up on the timing diagrams, which is where I discovered the problem.
Also be careful, because it might work MOST of the time ;) With the last sequence I posted, I put my screen on one with a continuous animation, and repeatedly entered and exited STOP mode (100+ times) using the blue button and the touchscreen wakeup, and everything worked. Doesn't mean it'll always work, I tried many different scenarios using Delays and/or reordering the sequence of operations in which it could work 30+ times in a row, then fail.
Again, be careful, because if you are just checking a static screen, it may look like it worked, but then when you try to change screens, nothing happens. Don't forget that in the debugger options, you can enable debug in low power mode if you need to see what's going on. Just don't forget to turn it back off when you're taking power measurements, because it does add power.
2022-04-14 09:23 AM
I am hoping @Martin KJELDSEN will be able to put some definitive tutorial together about low power mode as he mentioned in the VSYNC post, but we don't have anything yet, so for know I'm sticking with my approach, and if I ever have a failure will post an update.