2022-03-04 03:26 PM
Help! I'm new to ST development tools. All I'm trying to do right now is generate an MC Workbench example project. Any example project.
MC Workbench GENERATION always reports the following error:
"The ST intranet updater server is unknown: mcucrossselector.codex.cro.st.com"
Any suggestions greatly appreciated.
-----
Details:
MotorControl Workbench 5.Y.4 (en.X-CUBE-MCSDK_5.Y.4_v5.5.4.zip)
STM32CubeMX 6.4.0 (en.stm32cubemx-win_v6.4.0.zip)
STM32CubeIDE 1.7.0 (st-stm32cubeide_1.7.0_10852_20210715_0634_x86_64.exe)
(All downloaded and installed yesterday.)
It does generate a CubeMX project, which generates a CubeIDE project, but that source code is has a massive number of undefined symbols. I have not changed any config or preferences settings. It's all "fresh out of the box", and I'm just following the provided instructions.
((Context: I have 2 new B-G431B-ESC1 boards, and started out trying to build the example projects for that board. When that failed, I started trying other examples, and it looks like the problem is a very basic one with MC Workbench, not related to the examples for my specific board.))
Solved! Go to Solution.
2022-04-06 12:24 PM
Hello @hwa,
sorry I focused on the project generation issue.
Could you attach the gcc log generated by cubeIDE ?
Regards
Cedric
2022-04-06 01:20 PM
I just went through the workbench->cubeMX->cubeIDE sequence again to get fresh log files. In workbench I clicked "Update" instead of "generate". There was no longer any reported error. cubeMX then generated the cubeIDE project, produced the attached build log. The error here is different than a month ago when I reported the original problem.
The file "attach" function seems to only allow 1 attachment per post, so I will follow up with posts to attach the log from MC workbench and cubeMX, in case that helps.
2022-04-06 01:20 PM
2022-04-06 01:21 PM
2022-04-06 06:08 PM
Hi @cedric H ,
Cannot open it by double clicking, it doesn't show any suggested IDE icon.
Should i re install again??
2022-04-07 01:29 AM
Hello @hwa,
It looks like your project is corrupted with some files missing.
There are two things possible with the ESC board.
Two examples are provided, one to make use of potentiometer, one to control the speed from a PWM Timer input (basically used by flight controller)
If you want to start from the example, you must select it from the "Example projects" list proposed at the first window. You shall not open the example from the stmcx file. The example flow requires you click on update button at the generation phase.
If you start from a new project an select the ESC board from the inverter list, you will be able to generate your project with "generate" button only. You will be able to control your motor with MC Pilot and start/stop button only.
May I ask you to start from scratch two new projects :
Both projects must compile and successfully.
Hope it helps
Cedric
2022-04-07 09:49 AM
Hello @cedric H
You said:
"If you want to start from the example, you must select it from the "Example projects" list proposed at the first window. You shall not open the example from the stmcx file. The example flow requires you click on update button at the generation phase."
This is what I have done (over and over). The log files I attached are from doing exactly that for the Potentiometer example.
Can you confirm that the two B-G431B-ESC1 example projects do ACTUALLY build successfully? using the most recent versions of the tools (what I listed in original post)? Not just that they "should" build, but verified that they build?
I suspect the example projects have not been updated propertly to work with the current toolset. The "readme" file that MC workbench pops up for the example project is a confusing mish-mash referring at different times to different hardware, and gives contradictory information.
I will try your suggestion to build a new project targeting the B-G431B-ESC1. But even if that works I still need some working examples to get started.
More detail:
The log files I attached at your request are from the Potentiometer example. I have even tried uninstalling the entire toolchain, deleting my working folder, then reinstalling and starting from scratch again. To be specific: open MC workbench, click to select the B-G431B-ESC1 Potentiometer example, "Save As" to make a copy of the example project in my own workspace, click generate menu item, on pop-up dialog click "update". You see the result in the log file I attached. It reports tons of errors, but still makes a cubeMX project, which makes a cubeIDE project (both logs attached earlier), but of course it doesn't build.
2022-04-07 12:37 PM
I've just made a new project using the board selector, and using the settings you suggested. That does indeed produce a cubeIDE project that builds successfully (which I think means that my toolchain is properly installed). However the MC workbench log still shows a huge number of errors - the same kind of errors that show when trying to build the example projects. Attached here is the MC workbench log;
So what's the next step to investigate why the 2 examples won't build?
2022-04-08 08:48 AM
Hello @hwa,
The attached GenericLowVoltage-workbench-ESC-G4 is actually cubeMX generation log and as long as you end-up with a generated project, in your case, the presence of a .cproject file in your STM32CubeIDE folder then you can consider that the generation is successful..
Regarding the 2 examples, you are right, they are broken in the 5.Y.4.
I attach to this comment a zip file with two files : .project and parameters_conversion_g4xx.h
To fix the Potentiometer example, you have to replace the .project file located here: (this default path has to be modified according to your installation folder) :
C:\Program Files (x86)\STMicroelectronics\MC_SDK_5.Y.4\Projects\B-G431B-ESC1\Demonstration\Potentiometer_ESC-G4\STM32CubeIDE\.project by the one included in the zip file.
To fix the ElectronicSpeedControl example, you have to replace the parameters_conversion_g4xx.h file located here (to be modified according to your installation folder):
C:\Program Files (x86)\STMicroelectronics\MC_SDK_5.Y.4\Projects\B-G431B-ESC1\Demonstration\ElectronicSpeedControl_ESC-G4\Inc\parameters_conversion_g4xx.h by the one included in the zip file.
When those files are copied, you can generate and compile NEW projects successfully.
Sorry for these issues
Regards
Cedric
2022-04-09 05:24 PM
Brilliant. Thank you @cedric H
There were some hiccups:
A.
MC_SDK_5.Y.4 does not make STM32CubeIDE folders for the B-G431B-ESC1 demo projects, so there are no .project files to replace. Instead, for the potentiometer project I just created a folder with that name and put your .project file in it, then went through the MCworkbench->CubeMX->CubeIDE tool chain to generate new projects, and it worked like a charm.
B.
For the ElectronicSpeedControl project I replaced the header file as you instructed. The resultant CubeIDE project fails to build, but the problem is pretty obvious. The project is missing a required source file (esc.c). I assumed this was the same kind of problem as potentiometer.c missing from that project, so I did the following:
After making those changes the tool chain generated a CubeIDE project that does build.
I've attached my version of the fixes, which includes the missing directories and both project files, as well as the header file, in case anyone else is trying to generate and build these projects (and of course assuming Cedric says this is the right thing to do!)
So: success for both demo projects! However I'd really appreciate it @cedric H if you could confirm that what I've done was the right thing - or tell me where I went wrong. It's true the code builds now, but I don't want to smoke my new boards by running something incorrectly configured for them.