Jump to content

Stuck with programming midibox


Guest echelon
 Share

Recommended Posts

Guest echelon

Hello,

Can someone help me with solving the following problem when pogramming my midibox?

I've managed to upload the bootstrap and the MIOS-OS. No complaints @ all.

Now I'm trying get upload my application to test if all of my 16 endless rotary encoders are working.

I've made the following changes in the mios.tables.inc

     ;; encoder entry structure

ENC_ENTRY MACRO sr, din_0, mode

     dw      (mode << 8) | (din_0 + 8*(sr-1))

     ENDM      

ENC_EOT      MACRO

     dw      0xffff

     ENDM

MIOS_ENC_PIN_TABLE

     ;; encoders 1-16

     ;;        SR  Pin  Mode

     ENC_ENTRY  1,  0,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 1

     ENC_ENTRY  1,  2,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 2

     ENC_ENTRY  1,  4,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 3

     ENC_ENTRY  1,  6,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 4

     ENC_ENTRY  2,  0  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 5

     ENC_ENTRY  2,  2,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 6

     ENC_ENTRY  2,  4,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 7

     ENC_ENTRY  2,  6,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 8

     ENC_ENTRY  3,  0,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 9

     ENC_ENTRY  3,  2,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 10

     ENC_ENTRY  3,  4,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 11

     ENC_ENTRY  3,  6,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 12

     ENC_ENTRY  4,  0,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 13

     ENC_ENTRY  4,  2,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 14

     ENC_ENTRY  4,  4,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 15

     ENC_ENTRY  4,  6,  MIOS_ENC_MODE_NON_DETENTED      ; V-Pot 16

     ;; encoders 17-32

     ENC_EOT

     ENC_EOT

Now only the first encoder gives a signal in MIOS but the other 15 don't.

I've got a DIN module right @ the CORE @ pin 9 with 16 ALPS encoder to it.

I think my code isn't ok but I can't find the problem.

My final design contains 96 buttons, 16 encoders, 17 sliders and 38 leds. Which example from the ucapps-site should I use to re-write.

Is somebody help me programming this thingie?

thanx

echelon

Link to comment
Share on other sites

Guest echelon

Thanx Thorsten,

I just re-edited the 'mios_tables.inc' from the encoder1 example but didn't read the info in the 'main.asm.'

I'll have a look @ it and will try it again... :D

Link to comment
Share on other sites

  • 1 month later...

Hi,

WHere can i get more infomation for editing the mios_tables.inc file?

With trial and error i only concluded that

MT_ENTRY      0x90, 0x00 - is a note &

MT_ENTRY      0xb0, 0x00 - is a controller.

Is there some where that lists out what the rest like 0x00,0x01... are used to patch to?

Cheers. :)

Link to comment
Share on other sites

Hi,

Just fire up Google and search for "midi specification"...

What you are looking for:

8 = Note Off

9 = Note On

A = AfterTouch (ie, key pressure)

B = Control Change

C = Program (patch) change

D = Channel Pressure

E = Pitch Wheel

The lower Nibble (4 Bits) is the MIDI-Chanel:

0x92 means Note On, Channel 2

0x8F means Note Off, Channel 16

Hope this helps

Raphael

Link to comment
Share on other sites

Thanks for the list.

I've getting some problems. I connected 8 pots to a AIN4X. I'm using the MIOS AIN64 DIN128 DIO128 app.

In the mios_table, i put "MT_EOT" for the pots section. THen for the first eight i placed :MT_ENTRY 0xb0, 0x10-18.

The problem is, when i open one of 2 certain pots, i get lots of random data. When all closed, i can only work 4 pots. But each of this pot sends 2 sets of sysex eg B0-14 and B0-15 or B0-13 and B0-17 for another pot.

What's went wrong?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...