Mapping out the HEX codes of an IR remote with joysticks

Hello , I am a beginner and I am trying to make a IR controlled car with an Arduino UNO, L293D motor driver, IR receiver, 2 geared BO motors (6V), old RC helicopter remote (which has 3 channels, 4-5 buttons, 2 joysticks), a few LEDs, etc. I am having a problem in obtaining the HEX codes for each direction (as there are so many combinations of different positions of the joysticks, each with a separate HEX code) as 1 joystick controls the speed of the vehicle and 1 controls the direction of motion. I want to know if there is an easier method to map out every hex code so that I can implement the codes in my program and see it working.


// Current code 

#include <IRremote.h>

const int IR_PIN = 11;  // IR receiver connected to pin 11
IRrecv irrecv(IR_PIN);
decode_results results;

void setup() {
  Serial.begin(9600);
  irrecv.enableIRIn(); // Start the receiver
}

void loop() {
  if (irrecv.decode(&results)) {
    Serial.print("Code: 0x");
    Serial.println(results.value, HEX);
    irrecv.resume();  // Wait for next signal
  }
}


Welcome

Give some examples of the output when you move a joystick in one direction, another direction, when you press a button, and when you do both at the same time.

Also read this : GitHub - Arduino-IRremote/Arduino-IRremote: Infrared remote library for Arduino: send and receive infrared signals with multiple protocols

Try this code, it prints the received code in HEX.

#include <IRremote.hpp>
const int IRPin = 11;
IRrecv irrecv(IRPin); 
//-------------------------------------------------------------------
void setup() {
  Serial.begin(9600);
  irrecv.enableIRIn(); 
}
//-------------------------------------------------------------------
void loop() {
  if (IrReceiver.decode()) {
    Serial.println(IrReceiver.decodedIRData.decodedRawData, HEX);
    irrecv.resume();
  }
}