Skip to content

#REQUEST 902 - Automatically load the last open/saved song or user-defined template at startup - #1272

Merged
seangoodvibes merged 23 commits into
SynthstromAudible:communityfrom
joxihan:902_STARTUPSONG
Feb 25, 2024
Merged

#REQUEST 902 - Automatically load the last open/saved song or user-defined template at startup#1272
seangoodvibes merged 23 commits into
SynthstromAudible:communityfrom
joxihan:902_STARTUPSONG

Conversation

@joxihan

@joxihan joxihan commented Feb 20, 2024

Copy link
Copy Markdown
Contributor

NEW SONG : Same behavior as current firmware, boot up on blank song.
TEMPLATE SONG: The current default behavior where a new project is initialized for you.
LAST USED SONG: The last project you loaded on the Deluge.
LAST MODIFIED SONG: The last project you saved on the Deluge.

@m-m-adams

Copy link
Copy Markdown
Collaborator

For formatting you can run ./dbt format to get the exact format config used by our CI

If you're using VSCode and install the advanced formatters extension (should be in our suggested extensions) it'll do it on save for you

@joxihan

joxihan commented Feb 20, 2024

Copy link
Copy Markdown
Contributor Author

For formatting you can run ./dbt format to get the exact format config used by our CI

If you're using VSCode and install the advanced formatters extension (should be in our suggested extensions) it'll do it on save for you

Thanks Mark, i didn't know that, just run dbt format and checked in

Comment thread src/definitions_cxx.hpp Outdated
Comment thread src/deluge/deluge.cpp Outdated
Comment thread src/definitions_cxx.hpp Outdated
@joxihan

joxihan commented Feb 21, 2024

Copy link
Copy Markdown
Contributor Author

updated PR following shapphire-arches comments

@soymonitus

Copy link
Copy Markdown
Collaborator

When booting the Deluge in the default template song.. when wanting to save the song it will show name "DEFAULT 2". It would be better if the Default song, when loaded, its name or file path is wiped, so it behaves like a blank song, where clicking Save will show you the next available song slot. Say your last song is named SONG34.xml, then the Deluge should suggest you the name "SONG35"

@soymonitus soymonitus left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A change to make the Template feature work as intended

Comment thread src/deluge/deluge.cpp
@soymonitus

Copy link
Copy Markdown
Collaborator

It doesn't work with booting from songs loaded/saved inside a subfolder. Dir name or path should also be taken into account.

@joxihan

joxihan commented Feb 22, 2024

Copy link
Copy Markdown
Contributor Author

It doesn't work with booting from songs loaded/saved inside a subfolder. Dir name or path should also be taken into account.

Good catch I'll write the subfolder support tonight hk time thx for the review

@soymonitus

Copy link
Copy Markdown
Collaborator

Now it looks good. But i have no permissions to approve so an admin dev should take a look at it 😀
Thanks a lot for this feature, really useful

Comment thread src/deluge/deluge.cpp

@soymonitus soymonitus left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some label changes

Comment thread src/deluge/gui/l10n/seven_segment.cpp Outdated
Comment thread src/deluge/gui/l10n/seven_segment.cpp Outdated
@seangoodvibes

seangoodvibes commented Feb 24, 2024

Copy link
Copy Markdown
Collaborator

@joxihan could you add documentation for this feature to these documents please?

  1. Community Features document: https://github.com/SynthstromAudible/DelugeFirmware/blob/community/docs/community_features.md

I would recommend added section 3.12 to the document under Section 3. General Improvements

  1. Change Log Document: https://github.com/SynthstromAudible/DelugeFirmware/blob/community/CHANGELOG.md

Add a brief description of your change under section c1.2.0

Thanks!

…at startup. - minor adaptation + documentation
@joxihan joxihan changed the title #REQUEST 902 - On power on, automatically load the last open/saved song or template #REQUEST 902 - Automatically load the last open/saved song or user-defined template at startup Feb 24, 2024
@joxihan

joxihan commented Feb 24, 2024

Copy link
Copy Markdown
Contributor Author

@joxihan could you add documentation for this feature to these documents please?

  1. Community Features document: https://github.com/SynthstromAudible/DelugeFirmware/blob/community/docs/community_features.md

I would recommend added section 3.12 to the document under Section 3. General Improvements

  1. Change Log Document: https://github.com/SynthstromAudible/DelugeFirmware/blob/community/CHANGELOG.md

Add a brief description of your change under section c1.2.0

Thanks!

Documentation added :)

Comment thread src/deluge/model/song/song.cpp Outdated
Comment thread src/deluge/model/song/song.cpp Outdated
Comment thread src/deluge/deluge.cpp Outdated
Comment thread src/deluge/deluge.cpp Outdated
Comment thread src/deluge/deluge.cpp Outdated
Comment thread src/deluge/deluge.cpp
Comment thread src/deluge/gui/l10n/seven_segment.cpp Outdated

@sapphire-arches sapphire-arches left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - I think we should add some safety check so if the default song load crashes we fall back to an init song, but that can be future work. Thanks for the contribution!

@sapphire-arches sapphire-arches added cherry-pick Commit to cherry pick to release branch and removed cherry-pick Commit to cherry pick to release branch labels Feb 25, 2024
@joxihan

joxihan commented Feb 25, 2024

Copy link
Copy Markdown
Contributor Author

LGTM - I think we should add some safety check so if the default song load crashes we fall back to an init song, but that can be future work. Thanks for the contribution!

Thanks, really my pleasure. I did some sanity check it seems to fallback pretty well in case of issue loading the song, (non existing or faulty file).
What is the next step before merging it ?

@seangoodvibes
seangoodvibes added this pull request to the merge queue Feb 25, 2024
@seangoodvibes

Copy link
Copy Markdown
Collaborator

LGTM - I think we should add some safety check so if the default song load crashes we fall back to an init song, but that can be future work. Thanks for the contribution!

Thanks, really my pleasure. I did some sanity check it seems to fallback pretty well in case of issue loading the song, (non existing or faulty file). What is the next step before merging it ?

Merging now :)! Welcome to the team :D

Merged via the queue into SynthstromAudible:community with commit 5ba3bce Feb 25, 2024
tastycode pushed a commit to tastycode/DelugeFirmware that referenced this pull request Jul 3, 2024
…fined template at startup (SynthstromAudible#1272)

* On power on, automatically load the last open/saved song or template

* On power on, automatically load the last open/saved song or template - fix format

* On power on, automatically load the last open/saved song or template - fix format - minor changes

* On power on, automatically load the last open/saved song or template - following requested rework

* On power on, automatically load the last open/saved song or template - minor changes

* Automatically load the last open/saved song or user-defined template at startup. - minor adaptation + documentation

* Update community_features.md

* Automatically load the last open/saved song or user-defined template at startup. - minor changes

* Automatically load the last open/saved song or user-defined template at startup. - minor fix

* Automatically load the last open/saved song or user-defined template at startup. - minor changes SynthstromAudible#9

* fix build

* fix format

* Shorten 7seg string

---------

Co-authored-by: Reed Koser <srkoser+GitHub@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants