Simulator issues

It's all about the code!
Post Reply
pt_dreamer
Posts: 6
Joined: Tue Jan 09, 2024 10:54 am
Github Username: PTDreamer

Simulator issues

Post by pt_dreamer »

Hi all,

New to this project and trying to get my feet wet by using the simulator.
Using compiled binaries (rusefi.master.mre_f4 ) under Win10 (pristine VM) I get a "not connected" message on the UI and the following message on the logs:

Code: Select all

[ECU Communication Executor1] ConnectionWatchdog - ConnectionWatchdog.reconnectTimer restarting: 1000
[ECU Communication Executor1] LinkManager - restart isPortAvailableAgain=false
Windows 10 and later x64 NEW-2024-01-09-10-39-20.png
Windows 10 and later x64 NEW-2024-01-09-10-39-20.png (82.43 KiB) Viewed 48172 times
This happens with both OpenJDK21U-jre_x64_windows_hotspot_21.0.1_12 and OpenJDK17U-jre_x64_windows_hotspot_17.0.7_7.

Under Linux and building from source (latest master), and after going trough some hurdles (like console looking for a simulator ".exe") I do get it working but some information appears to be missing like the injector output under "engine sniffer".
rus.png
rus.png (59.49 KiB) Viewed 48172 times
I do have a discoveryF4 board but I would prefer a more portable setup to get familiar with the code base.

Any help or guidance please?

Thanks,
Jose
User avatar
AndreyB
Site Admin
Posts: 14334
Joined: Wed Aug 28, 2013 1:28 am
Location: Jersey City
Github Username: rusefillc
Slack: Andrey B

Re: Simulator issues

Post by AndreyB »

On windows could it be some sort of a firewall issue? try launching .exe manually and see if you can telnet I think it's port 29001 or something.

Probably zero priority to include linux binaries into the bundles, console is actually supposed to discover already-running simulator as long as you compile and launch it manually. Also your screenshot looks pretty legit, what are you missing? injectors? I see you have VVT configured? We've only added cam simulation recently, (simulation, not decoding) so who knows.

You mention discovery but I am not sure what is the questions about real firmware?
image.png
image.png (20.29 KiB) Viewed 48129 times
Very limited telepathic abilities - please post logs & tunes where appropriate - http://rusefi.com/s/questions

Always looking for C/C++/Java/PHP developers! Please help us see https://rusefi.com/s/howtocontribute
pt_dreamer
Posts: 6
Joined: Tue Jan 09, 2024 10:54 am
Github Username: PTDreamer

Re: Simulator issues

Post by pt_dreamer »

AndreyB wrote:
Tue Jan 09, 2024 3:13 pm
On windows could it be some sort of a firewall issue? try launching .exe manually and see if you can telnet I think it's port 29001 or something.
Hi, tried it with firewall disabled and same issue. Also running as admin gives similar results. I can telnet to 29001 and 29002 with no issues.
AndreyB wrote:
Tue Jan 09, 2024 3:13 pm
Probably zero priority to include linux binaries into the bundles
I'm not interested on binaries and I'm pretty used to develop sw and fw under linux, it is just a matter of figuring out how it all works together, console, sim, ini files, config files, etc, because there is no top level makefile where I can just "make all".
AndreyB wrote:
Tue Jan 09, 2024 3:13 pm
Also your screenshot looks pretty legit, what are you missing? injectors? I see you have VVT configured? We've only added cam simulation recently, (simulation, not decoding) so who knows.
Yes I'm looking for injector output, I haven't configured anything I just built everything and tried copying some configuration files around to where the binaries where looking for them.
AndreyB wrote:
Tue Jan 09, 2024 3:13 pm
You mention discovery but I am not sure what is the questions about real firmware?
The statement about the discovery was just to say that I can use "real" hw if I have to, but would prefer using the simulator since it makes for a more portable development platform.

My main goal is to get acquainted with the code base and possibly contribute in someway.
User avatar
AndreyB
Site Admin
Posts: 14334
Joined: Wed Aug 28, 2013 1:28 am
Location: Jersey City
Github Username: rusefillc
Slack: Andrey B

Re: Simulator issues

Post by AndreyB »

You mention compiled mre_f4 and then screen shot says discovery. Are you mixing artifacts between bundle and local compilation? You cannot mix. Please start with everything f407-discovery
pt_dreamer wrote:
Tue Jan 09, 2024 4:05 pm
My main goal is to get acquainted with the code base and possibly contribute in someway.
if in fact you are hitting the issue in the area of meta information mismatch between bundles and console maybe that's the place to contribute first :)

it's a large codebase with history and technical debt. I hear you, not sure what's the best way. Maybe please take a step back and forget about mre for now unless you plan to focus on real hardware mre?
Very limited telepathic abilities - please post logs & tunes where appropriate - http://rusefi.com/s/questions

Always looking for C/C++/Java/PHP developers! Please help us see https://rusefi.com/s/howtocontribute
User avatar
AndreyB
Site Admin
Posts: 14334
Joined: Wed Aug 28, 2013 1:28 am
Location: Jersey City
Github Username: rusefillc
Slack: Andrey B

Re: Simulator issues

Post by AndreyB »

Very limited telepathic abilities - please post logs & tunes where appropriate - http://rusefi.com/s/questions

Always looking for C/C++/Java/PHP developers! Please help us see https://rusefi.com/s/howtocontribute
pt_dreamer
Posts: 6
Joined: Tue Jan 09, 2024 10:54 am
Github Username: PTDreamer

Re: Simulator issues

Post by pt_dreamer »

AndreyB wrote:
Tue Jan 09, 2024 5:12 pm
You mention compiled mre_f4 and then screen shot says discovery. Are you mixing artifacts between bundle and local compilation? You cannot mix. Please start with everything f407-discovery
pt_dreamer wrote:
Tue Jan 09, 2024 4:05 pm
My main goal is to get acquainted with the code base and possibly contribute in someway.
if in fact you are hitting the issue in the area of meta information mismatch between bundles and console maybe that's the place to contribute first :)

it's a large codebase with history and technical debt. I hear you, not sure what's the best way. Maybe please take a step back and forget about mre for now unless you plan to focus on real hardware mre?
The screenshots are from different systems. The first is in fact mre precompiled binaries running on a windows VM. Running the discovery binaries there produce the same "not connected" issue and also doesn't show the injector output traces.

The second are Linux compiled binaries (from master HEAD) which share no artifacts with the windows VM. There everything seems to work and I can connect to TS, the only issue is that I can't see the injector output trace.
pt_dreamer
Posts: 6
Joined: Tue Jan 09, 2024 10:54 am
Github Username: PTDreamer

Re: Simulator issues

Post by pt_dreamer »

AndreyB wrote:
Tue Jan 09, 2024 5:12 pm
if in fact you are hitting the issue in the area of meta information mismatch between bundles and console maybe that's the place to contribute first :)
I can hack something in java (in which the console is written) but I'm mainly a desktop/embedded C/C++ developer. I normally work with Qt for desktop and mobile applications and STMs HAL and FreeRTOS for embedded although I have some experience with Chibios.
User avatar
AndreyB
Site Admin
Posts: 14334
Joined: Wed Aug 28, 2013 1:28 am
Location: Jersey City
Github Username: rusefillc
Slack: Andrey B

Re: Simulator issues

Post by AndreyB »

rusEFI console is very important for a very few very special use-cases. Please use rusefi_simulator with TS but realistically it all depends on what's your more specific area of interest.
Very limited telepathic abilities - please post logs & tunes where appropriate - http://rusefi.com/s/questions

Always looking for C/C++/Java/PHP developers! Please help us see https://rusefi.com/s/howtocontribute
pt_dreamer
Posts: 6
Joined: Tue Jan 09, 2024 10:54 am
Github Username: PTDreamer

Re: Simulator issues

Post by pt_dreamer »

AndreyB wrote:
Tue Jan 09, 2024 6:16 pm
rusEFI console is very important for a very few very special use-cases. Please use rusefi_simulator with TS but realistically it all depends on what's your more specific area of interest.
I'm interested in open source projects in general and also like sport vehicles as an hobby but am not that familiar with the tunning scene. A friend told me about rusefi and his desire to have staged injection added to it so that is where I would like to start.
For that having injector output traces would be great for debugging and POC. Can I have that on TS with simulated stimulus?
User avatar
AndreyB
Site Admin
Posts: 14334
Joined: Wed Aug 28, 2013 1:28 am
Location: Jersey City
Github Username: rusefillc
Slack: Andrey B

Re: Simulator issues

Post by AndreyB »

pt_dreamer wrote:
Tue Jan 09, 2024 6:26 pm
A friend told me about rusefi and his desire to have staged injection added to it so that is where I would like to start.
https://github.com/rusefi/rusefi/issues/5247 was closed a couple of days ago.

There is limited documentation and tons of information in the logs, the rest of the answers are in the source code unfortunately.
Very limited telepathic abilities - please post logs & tunes where appropriate - http://rusefi.com/s/questions

Always looking for C/C++/Java/PHP developers! Please help us see https://rusefi.com/s/howtocontribute
pt_dreamer
Posts: 6
Joined: Tue Jan 09, 2024 10:54 am
Github Username: PTDreamer

Re: Simulator issues

Post by pt_dreamer »

Lol Nice, thanks for the heads up. About adding the injector output trace to the console or TS how can I do that?
Post Reply