It sounds like you’ve connected switches and encoders to the DIN inputs and not changed the pin assignments in the .asm file to match. So your encoder is connected to the default pin assignments for the SID 1,2,3,4 buttons.
How have you connected the switches, encoder (and LEDs, if any) to the DIN/DOUT pins?
The “setup_8580.asm” (preferred starting point for you, I think) will be using the default pin assignments as show here: (see PDFs at bottom of this page):
http://www.ucapps.de/midibox_sid_manual_hw.html
You should modify this file and change:
#define CS_MENU_DISPLAYED_ITEMS 5
to
#define CS_MENU_DISPLAYED_ITEMS 10
Ignore:
;; NOTE: if CS_MENU_DISPLAYED_ITEMS > 5, you have to adapt the DIN settings
;; in cs_menu_io_tables.inc
[/code]
as you now configure it in the setup_8580.asm file.
Scroll down to:
[code]
CS\_MENU\_DIN\_TABLE
;; Function name SR# Pin#
DIN\_ENTRY CS\_MENU\_BUTTON\_Dec, 1, 0 ; only valid if rotary encoder not assigned to these pins
DIN\_ENTRY CS\_MENU\_BUTTON\_Inc, 1, 1 ; (see mios\_tables.inc) and CS\_MENU\_USE\_INCDEC\_BUTTONS == 1
DIN\_ENTRY CS\_MENU\_BUTTON\_Exec, 1, 2
DIN\_ENTRY CS\_MENU\_BUTTON\_Sel1, 1, 7
DIN\_ENTRY CS\_MENU\_BUTTON\_Sel2, 1, 6
DIN\_ENTRY CS\_MENU\_BUTTON\_Sel3, 1, 5
DIN\_ENTRY CS\_MENU\_BUTTON\_Sel4, 1, 4
DIN\_ENTRY CS\_MENU\_BUTTON\_Sel5, 1, 3
DIN\_ENTRY CS\_MENU\_BUTTON\_Sel6, 0, 0 ; define this if CS\_MENU\_DISPLAYED\_ITEMS \> 5
DIN\_ENTRY CS\_MENU\_BUTTON\_Sel7, 0, 0 ; define this if CS\_MENU\_DISPLAYED\_ITEMS \> 5
DIN\_ENTRY CS\_MENU\_BUTTON\_Sel8, 0, 0 ; define this if CS\_MENU\_DISPLAYED\_ITEMS \> 5
DIN\_ENTRY CS\_MENU\_BUTTON\_Sel9, 0, 0 ; define this if CS\_MENU\_DISPLAYED\_ITEMS \> 5
DIN\_ENTRY CS\_MENU\_BUTTON\_Sel10, 0, 0 ; define this if CS\_MENU\_DISPLAYED\_ITEMS \> 5
...
and change the “SR#” and “Pin” to match your pin assignments. You can compare how these match the default DIN assignments in the PDF (i.e. to understand how “SH#” and “Pin” relates to a pin on the DIN module). For buttons you don’t have connected (i.e. perhaps “SID 1” and others in the rest of the table), set SR# and Pin to 0 each (like the default for CS_MENU_BUTTON_Sel6). Now scroll down further:
MIOS_ENC_PIN_TABLE
;; SR Pin Mode
#if CS_MENU_USE_INCDEC_BUTTONS == 0
ENC_ENTRY 1, 0, MIOS_ENC_MODE_DETENTED2 ; menu encoder
#endif
;; additional CS encoders
;; SR Pin Mode
ENC_ENTRY 3, 0, MIOS_ENC_MODE_DETENTED2 ; Osc delay/transpose/assign #1
ENC_ENTRY 3, 2, MIOS_ENC_MODE_DETENTED2 ; Osc attack/finetune/assign #2
ENC_ENTRY 3, 4, MIOS_ENC_MODE_DETENTED2 ; Osc decay/portamento/assign #3
ENC_ENTRY 3, 6, MIOS_ENC_MODE_DETENTED2 ; Osc sustain/release/assign #4
ENC_ENTRY 3, 8, MIOS_ENC_MODE_DETENTED2 ; Osc release/pulsewidth/assign #5
ENC_ENTRY 4, 6, MIOS_ENC_MODE_DETENTED2 ; LFO rate
ENC_ENTRY 5, 0, MIOS_ENC_MODE_DETENTED2 ; LFO depth
ENC_ENTRY 5, 4, MIOS_ENC_MODE_DETENTED2 ; Filter CutOff
ENC_ENTRY 5, 6, MIOS_ENC_MODE_DETENTED2 ; Filter Resonance
ENC_ENTRY 6, 0, MIOS_ENC_MODE_DETENTED2 ; Env depth/assign #1
ENC_ENTRY 6, 2, MIOS_ENC_MODE_DETENTED2 ; Env attack/assign #2
ENC_ENTRY 6, 4, MIOS_ENC_MODE_DETENTED2 ; Env decay/assign #3
ENC_ENTRY 6, 6, MIOS_ENC_MODE_DETENTED2 ; Env sustain/assign #4
ENC_ENTRY 7, 0, MIOS_ENC_MODE_DETENTED2 ; Env release/assign #5
;; don't remove this "end-of-table" entry!
ENC_EOT
[/code]
This is where encoders are mapped to DIN pins.
Change the first one's SR and pin numbers:
[code]
#if CS\_MENU\_USE\_INCDEC\_BUTTONS == 0
ENC\_ENTRY 1, 0, MIOS\_ENC\_MODE\_DETENTED2 ; menu encoder
#endif
to match where you’ve connected the menu encoder.
I’m assuming you can do the same trick and assign SR=0, Pin=0 to the other ones which you are not using, in case you’re using a 3rd DIN shift register (i.e. J7,J8,J9,J10 on a DINX4 module) for switches. You don’t want the app to think you’ve got an encoder there when there are really switches.
And just in case you don’t know, you’ll have to rebuild the setup_8580.asm into a new setup_8580.hex file. Learn how to do this here:
http://www.ucapps.de/howto_tools_gpasm.html