Converting a frac32 Parameter into Hexadecimal


#1

Hello,

so this is my first post here and also my first time trying to programm an object in axoloti. I am trying to programm the axoloti as a controller for my Roland Alpha Juno 1 by sending a sysex message via MIDI. I use this two lines of code from the forum to send the message:

uint8_t sysexArray[10] = {0xF0, 0x41, 0x36, 0x00, 0x23, 0x20, 0x01, 0x10, 0x00, 0xF7};
sdWrite(&SDMIDI, sysexArray, 10);

This works just fine, but I want to be able to edit the parameters in real time using an encoder. So I need to convert the output of the encoder into hexadecimal, but as my coding skills are a little bit rusted I don't seem to find a good solution for this problem. Maybe someone here has some idea how to solve this problem?


Mattilyn Mattroe contributions
#2

hexadecimal is just a representation of a value, you can also write it in binary or decimal it does not matter to the program/compiler


#3

Thank you very much! I was searching for the error in the wrong place. I could fix my problem.


#4

Did you manage to get this to work, and if so would you mind uploading your object, as I would like to do the same and also would like to understand how you implemented it. Thank you in advance