Closed gabopushups closed 3 years ago
I found a workaround that required modifying the code.
I went to openhantek/src/docks/ and then modified the file "HorizontalDock.cpp" by adding the function show()
under the loadSettings function.
void HorizontalDock::loadSettings( DsoSettingsScope *scope ) {
show(); // Show the missing dock
// Set values
setSamplerate( scope->horizontal.samplerate );
setTimebase( scope->horizontal.timebase );
setFormat( scope->horizontal.format );
setCalfreq( scope->horizontal.calfreq );
}
And then had of course to rebuild the program. It's not the most elegant solution, but it worked for me.
I've never encountered this issue or heard about it. You have two easy solutions without programming:
Oscilloscope/Settings/Scope
and tick the entry
[X] Apply default settings after next restart
Exit the program and start again.~/.config/OpenHantek/DSO-6022BE_XXXXXXXXXXXX.conf
(where XXX.. is the hex serial number of your device) and delete in section [window]
the line state=@ByteArray(...
Start the program again.
I suppose that you are using Linux, under Windows delete the state settings in the registry Computer\HKEY_CURRENT_USER\SOFTWARE\OpenHantek\DSO-6022BE_XXXXXXXXXXXX\window
, dunno where to look under MacOS.If this issue shows up more often, here's a belt-and-suspender solution:
--- a/openhantek/src/mainwindow.cpp
+++ b/openhantek/src/mainwindow.cpp
@@ -162,6 +162,11 @@ MainWindow::MainWindow( HantekDsoControl *dsoControl, DsoSettings *settings, Exp
restoreGeometry( dsoSettings->mainWindowGeometry );
restoreState( dsoSettings->mainWindowState );
+ voltageDock->show(); // enable this dock regardless of state
+ horizontalDock->show(); // enable this dock regardless of state
+ triggerDock->show(); // enable this dock regardless of state
+ spectrumDock->show(); // enable this dock regardless of state
+
// Central oszilloscope widget
dsoWidget = new DsoWidget( &dsoSettings->scope, &dsoSettings->view, spec );
setCentralWidget( dsoWidget );
Describe your problem
Just until last night the program was running fine, but now the "Horizontal" menu has disappeared, and I can't find any way to enable it. I've tried restarting the program, removing and re-installing it, but it still does not appear anywhere.
By right clicking the menu, all options are greyed out, and I can't tick the "Horizontal" option