Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

menu revision #651

Merged
merged 15 commits into from
Nov 25, 2018
Merged

menu revision #651

merged 15 commits into from
Nov 25, 2018

Conversation

tehn
Copy link
Member

@tehn tehn commented Nov 21, 2018

overhaul of the primary menu system.

ENC1 now changes pages:

levels - tape - HOME - params

levels

KEY2 to toggle active level editing with ENC2/ENC3 (highlight shows edit position)

tape

KEY2 to toggle between PLAY AND REC

PLAY: KEY3 to select file. KEY3 again to play. KEY3 again to stop. autostop implemented at EOF
REC: KEY3 to arm. KEY3 again to start. KEY3 again to stop. files names by incrementing counter, saved in dust/data/system.lua

home

KEY2 to toggle minimal vs. stats view

params

same as before. KEY2 unused, but can be allocated to other functionality with forthcoming params revision


other

  • tape output has a level (thanks @antonhornquist )
  • encoder sensitivity rewritten (massively improved)
  • util function s_to_hms (sec to hour:minute:second string format)

@tehn
Copy link
Member Author

tehn commented Nov 21, 2018

fixes #223
fixes #422
fixes #374
fixes #373

@ngwese
Copy link
Member

ngwese commented Nov 22, 2018

looking pretty fancy. need to test more. very much liking the new encoder feel.

my one (totally subjective) comment is that personally i think it would be more intuitive to order the four pages as:

  1. home
  2. parameters
  3. levels
  4. tape

i realize the current order is playing off the previous layout in order to retain familiarity.

the new tape ui looks very nice. i was able to figure out how to play an existing file (took a bit to discover the file selection ui) but i wasn't able to figure out how to start recording. looking in maiden i saw a handful of errors which appear to be related to me trying to use the tape ui:


lua: /home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: /home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: 
/home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: /home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: /home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: /home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
invalid metro index, not added. max count of metros is 33
lua: 
/home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: 
/home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: 
/home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: /home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: /home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: /home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>
lua: 
/home/we/norns/lua/menu.lua:1602: attempt to index a nil value (upvalue 'p_tape_rec')
stack traceback:
	/home/we/norns/lua/menu.lua:1602: in function 'fileselect.key_restore'
	/home/we/norns/lua/menu.lua:167: in function </home/we/norns/lua/menu.lua:144>

@ngwese
Copy link
Member

ngwese commented Nov 22, 2018

one additional suggestion. at the risk of adding too many pages i think it would cleaner if the SYSTEM > AUDIO ui was moved up to be a page:

  1. home
  2. parameters
  3. audio
  4. levels
  5. tape

if audio was a page then pages are were one would find all of the controls that pertain to the signal chain. the home + menu system becomes where all the settings/configuration for non-audio stuff goes.

@ngwese
Copy link
Member

ngwese commented Nov 22, 2018

one final note. not sure if this is intentional or not. when powering up the device the previously selected script isn't being loaded so i get a black screen (after the sparkles). pressing KEY1 brings me to the home page where:

  • the selected script is always NONE
  • the page selector ui isn't drawn, turning ENC1 causes it to draw

@tehn
Copy link
Member Author

tehn commented Nov 22, 2018

thanks for testing!

sounds like you need to re-run ./waf as there are some matron changes (the errors above are because the metro isn't allocated)

more comments in a bit.

@tehn
Copy link
Member Author

tehn commented Nov 23, 2018

re: panel ordering.

AUDIO is going to be removed from SYSTEM and made a fixed section of the PARAMS menu. see #491 for more design

while i agree that the location of HOME seems weird, i tried to order the panels based on usage. to me the top used/needed panels are PARAMS and LEVELS. it followed that these made sense to be at the edges, so a quick flick of ENC1 gets you somewhere you want to be.

@ngwese
Copy link
Member

ngwese commented Nov 23, 2018

i've rebuilt matron and indeed the errors i was seeing disappeared, so...

  • page ui now disappears when not in use, draws when ENC1 is turned
  • last used script loads

re: audio page becoming part of the parameters 👍

re: ordering. i definitely get it - it is easier to hit those pages if they are at the edges and i agree that they are pages most frequented. i tried to quickly navigate just one page but it was difficult to be consistent w/o tactile feedback. the configuration you have now makes the most sense from a performance standpoint 👍

@ngwese
Copy link
Member

ngwese commented Nov 23, 2018

hmmm. i've rebuilt matron and reinstalled the sc stuff (via norns/sc/install.sh) but the tape record functionality doesn't work as expected.

symptoms:

  • clean reboot w/ molly_the_polly loaded
  • go to tape page KEY2 for REC, KEY3, check counter 0005, KEY3 to start recording
  • play keyboard for ~15 seconds (staying on tape page)
  • KEY3 to stop record
  • KEY2 to move to play control, KEY3 to select, choose 0005.wav, KEY3 to confirm
  • verify length of wav file is expected ~15 seconds
  • KEY3 to play, silence for duration of tape, "tape is over!" appears in maiden repl, tape play UI goes back to just a bar, now i hear the ~15 seconds i've just recorded

i don't know enough about the sc code to debug. looking at the sc repl i see the following output:

starting poll...
tape player state: fileopened
tape player filename: "/home/we/dust/audio/tape/0005.wav"
tape player state: playing
tape player state: paused

...curiously tape player state: paused appears before i hear the file playback (but ~15 seconds after tape player state: playing is printed).

@tehn
Copy link
Member Author

tehn commented Nov 23, 2018

hmm. i'll double-check the here and make sure i have all of the files sync'd correctly with git.

is tape level turned up?

@ngwese
Copy link
Member

ngwese commented Nov 23, 2018

is tape level turned up?

yes. it is cranked. to be clear i do hear the recording eventually. there is just a bunch of silence at the beginning of the recording, almost like the buffer written out to the file is 2x the record length with the first half as silence... it is weird.

@tehn
Copy link
Member Author

tehn commented Nov 23, 2018

oh wow, that's bizarre. i'll investigate. might need some debugging help from @antonhornquist

@ngwese
Copy link
Member

ngwese commented Nov 24, 2018

fyi. i tried to repo the weird tape behavior after hacking on all the wifi stuff. sort of good news was that i couldn’t repo it !?!

i’m going to chalk it up to supernova weirdness.

Copy link
Member

@ngwese ngwese left a comment

Choose a reason for hiding this comment

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

lgtm based on testing. i took a quick read of the code and nothing stuck out.

@ngwese
Copy link
Member

ngwese commented Nov 25, 2018

@tehn minor note - i just noticed that if one is down in one of the sub-menus; say HOME > SYSTEM, and ENC1 is used to change pages when coming back to the menu page one is reset to HOME (instead of the submenu they had selected). not sure if that is the intended/desired behavior.

@tehn
Copy link
Member Author

tehn commented Nov 25, 2018

this wasn't designed intentionally, but i've gotten used to it and think it's preferable. ie, if you're deep in a DEVICE selection submenu, it's totally confusing to page back into. arriving at HOME means you know where you are.

so i'd prefer to keep it as-is, but am willing to hear differing opinions

@ngwese
Copy link
Member

ngwese commented Nov 25, 2018

i don’t have a strong opinion on that behavior. i just noticed it due to the excessive amount of time i’ve been spending in the WIFI menu 😉

@tehn tehn merged commit 39afbf7 into master Nov 25, 2018
@tehn tehn deleted the menu_revision branch November 25, 2018 22:19
@okyeron
Copy link
Contributor

okyeron commented Dec 6, 2018

Just now having a chance to play with the new menu. (I was pretty confused about parameters being gone, so I had to come find this page to figure out what was up).

page ui now disappears when not in use, draws when ENC1 is turned

from a "I have no idea what's happening here" perspective, I'd like to see the "page indicator" bar at the top stay active all the time (rather than disappear when you let go of the encoder) - except maybe for when you're in the "app" section of HOME.

@tehn
Copy link
Member Author

tehn commented Dec 6, 2018

it's certainly understandable to pull master without seeing a changelog, and we've been only doing those for releases.

i'd try using the menu for a few days and see how you feel about the indicator. i highly prefer it disappearing -- to me it is visual clutter and detracts from the readability of the rest of the UI. it does its job, then goes away.

@okyeron
Copy link
Contributor

okyeron commented Dec 6, 2018

My initial concern was a lack of visual cue that I was on the parameters page. Or a "quick glance at the screen tells me what page I'm on" situation. I suppose the parameters page looks different enough so its obviously not one of the others.

Mostly thought it would be confusing for users transitioning to the new menu (as it was for me).

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.

None yet

3 participants