16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-19 14:39:18 +02:00

(uart, debug) add UART debug panel with connection information

This commit is contained in:
Marcin Nowak
2021-10-16 02:16:17 +02:00
parent 0c1bcdcadf
commit a0153b1d7b
7 changed files with 93 additions and 10 deletions

View File

@@ -140,7 +140,7 @@ driver_mode::drivermode_input::command_fallback( user_command const Command ) co
if( lookup == commandfallbacks.end() ) {
return { user_command::none, user_command::none };
}
return lookup->second;
}
@@ -600,7 +600,7 @@ driver_mode::update_camera( double const Deltatime ) {
// debug camera
DebugCamera.Update();
}
// reset window state, it'll be set again if applicable in a check below
Global.CabWindowOpen = false;
@@ -801,7 +801,7 @@ driver_mode::OnKeyDown(int cKey) {
switch (cKey) {
case GLFW_KEY_F4: {
if( Global.shiftState ) { ExternalView(); } // with Shift, cycle through external views
if( Global.shiftState ) { ExternalView(); } // with Shift, cycle through external views
else { InOutKey(); } // without, step out of the cab or return to it
break;
}
@@ -826,7 +826,7 @@ driver_mode::OnKeyDown(int cKey) {
}
case GLFW_KEY_F6: {
// przyspieszenie symulacji do testowania scenerii... uwaga na FPS!
if( DebugModeFlag ) {
if( DebugModeFlag ) {
if( Global.ctrlState ) { Global.fTimeSpeed = ( Global.shiftState ? 60.0 : 20.0 ); }
else { Global.fTimeSpeed = ( Global.shiftState ? 5.0 : Global.default_timespeed ); }
@@ -883,7 +883,7 @@ driver_mode::DistantView( bool const Near ) {
( simulation::Train != nullptr ) ?
simulation::Train->Dynamic() :
pDynamicNearest ) };
if( vehicle == nullptr ) { return; }
auto const cab =
@@ -1049,7 +1049,7 @@ driver_mode::CabView() {
m_externalview = false;
// likwidacja obrotów - patrzy horyzontalnie na południe
Camera.Reset();
Camera.Reset();
// bind camera with the vehicle
Camera.m_owner = train->Dynamic();