Author Topic: Add new Software State value should not change default value [implemented]  (Read 10508 times)

Offline Hermu

  • Jr. Member
  • **
  • Posts: 53
problem: unwanted new default values after adding new values to Software States

first i have defined a layout with 2 Banks with value 1 and 2 and default value is 1.
after adding a new value for a 3rd Bank, new default value is 3, but should be 1 again!
adding a new Software State value results in a new unexpected default value, because new added values are added on begin of defined values.
but adding new Software States values should not change default value.
« Last Edit: September 23, 2015, 05:42:14 PM by azslow3 »

Offline azslow3

  • Administrator
  • Hero Member
  • *****
  • Posts: 1791
Re: Add new Software State value should not change default value
« Reply #1 on: May 22, 2015, 03:29:22 PM »
Well, it is stated everywhere in the docs/examples that the first state in the list is the default. And you do not really want to change that logic, since the last state will be always default then (since the first created and you do not want to change it after...).

But at one point you are right, it is about time to make the definition user friendly. Download test version to get "Append" and "Append 10" options.

Offline Hermu

  • Jr. Member
  • **
  • Posts: 53
Re: Add new Software State value should not change default value
« Reply #2 on: May 22, 2015, 04:59:36 PM »
Thanks, for <Append> option modifications.

<Append> adds now a new entered value after last configured value.
<Append 10> adds now 10 values increasing from last defined value, but value field must be empty.

Question to <Append 10>:
Now i have Software States values 1,2,3, but after i enter 4, i would expect to get 10 increasing values:
4,5,6,7,8,9,10,11,12,13 but i get 44,45,46,47,49,49,410,411,412,413.
Or should be imput field for <Append 10> inactive?

Offline azslow3

  • Administrator
  • Hero Member
  • *****
  • Posts: 1791
Re: Add new Software State value should not change default value
« Reply #3 on: May 22, 2015, 05:50:57 PM »
If you enter something, it is a prefix (as string) to the generated numbers (as written in the documentation...).

Offline Hermu

  • Jr. Member
  • **
  • Posts: 53
Re: Add new Software State value should not change default value
« Reply #4 on: May 22, 2015, 06:41:16 PM »
But if i have value 1,2 and now i want also to have B1..B10, i can't get this with <Append 10>, because i get only B3..B12.
If i define 'B1' with <Append State>, then i get with <Append 10> 'B' only B4..B13.
This means, if i have value 1,2 i never can get B1..B10 for 'B' with <Append 10>, only B3..B12 and for 'C' i will get only C13..C22.

if i want also to have B1..B10 i can do this only with <Append State> ?

Offline azslow3

  • Administrator
  • Hero Member
  • *****
  • Posts: 1791
Re: Add new Software State value should not change default value
« Reply #5 on: May 22, 2015, 07:26:27 PM »
Yes, you should Append states one by one then. I do not have (and will not) have additional programming language interpreter, just to add A1, A2, A5, B33, B32, B27, CWhat, Does, Such78, State99, Set1, Means???  :o

The idea was just to add 1,2,3...127 (or x1,x2,x3...) fast.

Offline Hermu

  • Jr. Member
  • **
  • Posts: 53
Re: Add new Software State value should not change default value
« Reply #6 on: May 22, 2015, 08:01:41 PM »
No problem, because <Append State> solve the headline problem.

Thanks!  :)

Offline MarKo

  • Power user
  • Full Member
  • *
  • Posts: 249
Re: Add new Software State value should not change default value
« Reply #7 on: May 22, 2015, 08:07:51 PM »
i think it´s ok, it´s helpful and better than before (i did that with just editing the values and "save" button, but i´ve never had more than 2 states to change)
And i can´t think of situations where you want much more values for one SW-state. I´ve found it simpler to use several seperate SW-states, because the conditions become clearer and you have no additional work for remembering previous states.

E.g. i had before an sw-state "mode" with 4 values: Track/Bus/SelTrack/ACT
Switching between track/bus was ok. But if you switch to ACT or SelTrack - to which state do you return? Track or Bus? It should be possible to remember previous states, but i find it simpler to have just an additional sw-state "ACT" with 1/0 or "SelTrack" with 1/0.
This way it´s easier for me to switch from any mode to ACT by setting state "ACT" to 1, and by setting it to 0 again, it automatically returns to previous mode - "remembering" is done automatically by seperating the states.
Perhaps this is useful...

Offline azslow3

  • Administrator
  • Hero Member
  • *****
  • Posts: 1791
Re: Add new Software State value should not change default value
« Reply #8 on: May 22, 2015, 08:30:22 PM »
Many states are used for "remembering" current parameter inside plug-in (some of them have hundreds). Creating them one by one is a nightmare  :)

Offline MarKo

  • Power user
  • Full Member
  • *
  • Posts: 249
Re: Add new Software State value should not change default value
« Reply #9 on: May 22, 2015, 08:37:36 PM »
Hundreds of values for 1 state???

Offline azslow3

  • Administrator
  • Hero Member
  • *****
  • Posts: 1791
Re: Add new Software State value should not change default value
« Reply #10 on: May 22, 2015, 09:20:34 PM »
Hundreds of values for 1 state???
Look inside "MCU" preset  on OffPlugTrS for example ;)