i don't know if this will help you, but i found this long time ago here (either here in the forum or on the discord chat, i do not remember):
"the best way to use n64 controller with USB adapter is to switch to libretro_mupen64plus core (best emu for n64). Then use core overwrite to configure your controllers.
In EmulationStation you need to setup your N64 like this: cbuttons map to : A,B,X,Y. A,B to map to: select,R2. Z trigger map to: L2.
Map hotkey to L1 or R1. Rest (dpad, analog L1,R1) map to default. In retroarch load n64 game and go to quickmenu>controllers. Now swith layout so that A,B,X,Y (ES) map to C1,C2,C3,C4.
Map select and R2 to A and B. Save core override, and presto. This way you can use your N64 controller for other cores like mame,snes,nes,genesis,dreamcast etc."
i have just copied this text from someone else (like i said, he posted this a while ago either in the forum or on the discord), because i thought, that this could be helpful someday (if someone like you asks, how to configure a N64 controller).