2023-05-02 11:51 PM
please give me sample (i am using :
https://os.mbed.com/platforms/ST-Nucleo-L496ZG-P/#board-pinout
with this manual
)
HAL_GPIO_TogglePin(GPIOB, GPIO_PIN_7|GPIO_PIN_14);
2023-05-03 02:08 AM
Hello @CG3 ,
I am afraid your question is not very clear! what do you exactly need to know about STM32L496?
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2023-05-07 08:40 PM
Dear @Sarra.S I mean "firmware contain board related symbols for easy coding"
please check this one :
https://drive.google.com/file/d/1ThkFi8jhlzwvJCnx4GLaK2KT4z-GQbSt/view?usp=share_link
time 1:54
thank you for helping
2023-05-08 02:14 AM
Hello again @CG3,
Here are some references that you can refer to:
Hope that helps!
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2023-05-08 06:56 PM
The user pins and many setup variables are contained in the main.h file. They are referred to by the main.c setup routines.
2023-05-09 05:46 PM
Dear @Harvey White yes it is correct and as I understand there must be some simple ones referred each input/out put like video , how can i found them ? it is not include in main.h file
Additionally for last step in video for monitoring , i guess i miss something please recommend me any video or article for checking , thank you so much
2023-05-09 05:47 PM
for last step in video , i can not monitor it, i guess something lost , please recommend me , thank you
2023-05-09 06:27 PM
I'm not sure what you do know, and don't.
Let me try to at least point out some of the basics. Apologies if you already know this:
I use CubeMXIDE with the built in compiler.
the IOC editor allows you to assign pins, subsystems, and set up parameters.
It generates code to set up all of the hardware subsystems, display (if any), serial, SPI, I2C..... and so on. The definitions you set for pins are in main.h.
Main.c takes the system from zero, sets up the clock, initializes all of the subsystems you've enabled (via the IOC file). If you use some interrupts (mainly the timer interrupts), there's code added to allow you to put your own code in to do something about it.
If you use FreeRTOS (which is all I use, can't talk about other systems), the task scheduler is called, and at the bottom of the main.c file, there's a loop that allows you to put your own code in, executed periodically.
If you don't, there's an equivalent part that doesn't call FreeRTOS, but just slides through into a do forever loop.
Remember that all programs do the following, with an exception:
1) set up the hardware and data structures
2) execute the program
3) clean up afterwards and go to the main (calling/operating system) program.
IF THERE IS NO OPERATING SYSTEM FOR THIS PROGRAM, (which is usual, working from no program at all), then there cannot be a step 3, the overall program (at the root level) does NOT exist.
so if there's not an application you're running (like under the OS of a cell phone), then all you have
1) set up the hardware and data structures
2) execute the program, loop executing the program, and NEVER return to an operating system. Why? No operating system to return to.
SO:
given this, you need to see if you're working on an ST MICRO board (nucleo, or discovery), or on hardware you design. I've done all three.
How you manage this is a very different matter depending on how your hardware works.
NUCLEO: Hardware exists, enable the hardware with using the IOC part of the program to provide basic drivers. Tell the IOC program that you're using a specific Nucleo board.
DISCOVERY: This is more complicated. You'll have to go into the example programs to find a demonstration program that uses the features you want to use. Run this program. Look to see (for instance) how they control the display. Understand the mechanism they use to control the display.
The setups contain a complete driver having no relationship to any other driver. Generally, the routines at the highest level will write to mapped memory, which then shows up on the display.
At this point, you can either use their software (as shown in the example), or write your own, which simply writes to an area of memory (it's an array), to put dots on the screen. Your choice.
You might want to investigate TouchGFX, which gives you a graphics framework. Be advised that the project set up is not necessarily what you think.
If you are familiar with an Arduino, it is not the same.
IF you're doing programming on your own hardware, you start with IOC files, set up the hardware, and pretty much write your own. That can get involved.
SO the first thing to consider is what hardware you're using.
secondly, how much of the ST Micro software framework you will be living in
thirdly, are you using an operating system?
and fourthly, which has not been addressed, are you programming in C or C++?
Hope this gives you a few questions to think of
It can all be done, but part of the question is what do you want? the other part is "how much do you want to put into this?"