If the remote has been connected via bluetoothctl, then no further Bluetooth coding is required. The OS makes the incoming data available via a file. On my system it is /dev/input/event5 - but it will be one of the "event" files. Just open this file and read the data. Your only problem is the data that the OS passes through as the keyboard input that you have seen.
See inputs as buttons are pressed from the command line via
hd /dev/input/event5
OR C code
FILE *stream;
int c;
stream = fopen("/dev/input/event5","rb");
c = fgetc(stream); // reads one byte
// but should come in blocks of 16 bytes for every button press