mozaic_tips_and_tricks

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revisionBoth sides next revision
mozaic_tips_and_tricks [2021/02/13 07:49] – [Store two positive Values into a single Variable] add parens for clarity andMIDIByte example espiegel123mozaic_tips_and_tricks [2021/04/12 17:35] – Remove/add array entries (part I) _ki
Line 18: Line 18:
   * [[#Use a Knob to toggle 16 Pads View to HELP View]]   * [[#Use a Knob to toggle 16 Pads View to HELP View]]
   * [[#Knob double-tap Support]]   * [[#Knob double-tap Support]]
 +  * [[#Remove or add an entry inside an array]]
   * [[#Using Logic Operators in Expressions instead of IF cases]]   * [[#Using Logic Operators in Expressions instead of IF cases]]
   * [[#Using Inc and Dec in Expressions]]   * [[#Using Inc and Dec in Expressions]]
Line 147: Line 148:
   f = Div n, 10   f = Div n, 10
   r = (n-f*10) % 10   r = (n-f*10) % 10
-  if number>=0+  if value >=0
     LabelKnob 1, {N: +},f,{.},r     LabelKnob 1, {N: +},f,{.},r
   else   else
-    LabelKnob 1, {N: +},f,{.},r+    LabelKnob 1, {N: },f,{.},r
   endif   endif
 </code> </code>
Line 384: Line 385:
  
  
 +\\ 
 +=====  Remove or add an entry inside an array ===== 
 +<html><p align = "right"><small><i>From -ki</i></small></p></html>
 +Instead of running through an array with a FOR loop to shift entries to either insert or remove an  intermedeate enry, it is way faster to use the CopyArray Mozaic function.
  
 +<code> CopyArray source, dest, size</code>
 \\  \\ 
 =====  Using Logic Operators in Expressions instead of IF cases =====  =====  Using Logic Operators in Expressions instead of IF cases ===== 
  • mozaic_tips_and_tricks.txt
  • Last modified: 2024/04/23 19:07
  • by _ki