JvanKatwijk / eti-stuff

experimental software for creating and interpreting eti frames
GNU General Public License v2.0
21 stars 12 forks source link

repeat after EOF for xml broken #59

Closed andimik closed 1 year ago

andimik commented 1 year ago

Whereas eti-cmdline-rawfiles and eti-cmdline-wavfiles play a file from the beginning after reaching EOF, the eti-cmdline-xml does not.

bool    xml_fileReader::restartReader (int32_t freq) {
    (void)freq;
    if (theReader != nullptr)
       return true;ifnot
    theReader   = new xml_Reader (theFile,
                                      theDescriptor,
                                      5000,
                                      &_I_Buffer,
                                      continue_on_eof);
    return true;
}

I guess it has to do as you need to skip some bytes.

JvanKatwijk commented 1 year ago

It took a while, but I had a look. continuous playing of an xml file is switched off by default. By touching the continuous button ot worked file. I changed the layout of the control widget, and had the continuousbutton indicate whether or not the mode "continuous" is on

Op wo 18 jan. 2023 om 20:03 schreef andimik @.***>:

Whereas eti-cmdline-rawfiles and eti-cmdline-wavfiles play a file from the beginning after reaching EOF, the eti-cmdline-xml does not.

bool xml_fileReader::restartReader (int32_t freq) { (void)freq; if (theReader != nullptr) return true;ifnot theReader = new xml_Reader (theFile, theDescriptor, 5000, &_I_Buffer, continue_on_eof); return true; }

I guess it has to do as you need to skip some bytes.

— Reply to this email directly, view it on GitHub https://github.com/JvanKatwijk/eti-stuff/issues/59, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCPHQF7Q5CMTFXADMBVHF3WTA47LANCNFSM6AAAAAAT7OGTSY . You are receiving this because you are subscribed to this thread.Message ID: @.***>

-- Jan van Katwijk

andimik commented 1 year ago

Jan, I was talking about eti-cmdline-xml, not Qt-DAB... 😁

JvanKatwijk commented 1 year ago

I am too busy apparently to look good. Few remarks on xml files in eti The text in the main program clearly states

elif HAVE_XML_FILES

include "xml-filereader.h" // does not work yet

endif

However, your mods seem to have worked. There was one thing in the code that was missing: Saving the "continue_on_eof" flag from the xml-filereader, i.e. the interfacehandler, so an uninitialized "continue_on"eof" was passed on to xml-reader, i.e. the worker So, after adding a line "this -> continue_on_eof = continue_on_eof" fixed that

There is one issue though and I'll try to handle that one of these days and

Op za 28 jan. 2023 om 20:00 schreef andimik @.***>:

Jan, I was talking about eti-cmdline-xml, not Qt-DAB... 😁

— Reply to this email directly, view it on GitHub https://github.com/JvanKatwijk/eti-stuff/issues/59#issuecomment-1407464110, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCPHQAIXSQ6IWTQTWYJXZTWUVUDTANCNFSM6AAAAAAT7OGTSY . You are receiving this because you commented.Message ID: @.***>

-- Jan van Katwijk

andimik commented 1 year ago

Fixed in 60eb2d2, thanks!