Wednesday 2 March 2016

Arcade emulation: AdvanceMame

This one will be very quick: just get AdvanceMame 1.2 and compile :-)

OK, I'll give more details! First of all, get the tarball right here: https://sourceforge.net/projects/advancemame/files/advancemame/1.2/

Compilation is straightforward (when you're used to the Linux world), just check the configure options to activate the proper flags. We want to display on the frame buffer, and use SDL for the rest, so:
 ./configure --prefix=/media/BBB/ --enable-sdl --enable-fb  
 make  
 make install  

The "toughest" part is to configure Mame to run and display the way you want. This is done by experimenting with the $HOME/.advance/advmame.rc file: specify the paths to your roms, the input mapping, the display settings, etc.

Here is mine, for information:
 debug_crash no  
 debug_rawsound no  
 debug_speedmark no  
 device_color_bgr15 yes  
 device_color_bgr16 yes  
 device_color_bgr24 yes  
 device_color_bgr32 yes  
 device_color_bgr8 yes  
 device_color_palette8 yes  
 device_color_yuy2 yes  
 device_joystick none  
 device_keyboard sdl  
 device_mouse none  
 device_raw_firstkeyhack no  
 device_raw_mousedev[0] auto  
 device_raw_mousedev[1] auto  
 device_raw_mousedev[2] auto  
 device_raw_mousedev[3] auto  
 device_raw_mousetype[0] pnp  
 device_raw_mousetype[1] pnp  
 device_raw_mousetype[2] pnp  
 device_raw_mousetype[3] pnp  
 device_sdl_samples 512  
 device_sound oss  
 device_video sdl  
 device_video_cursor auto  
 device_video_doublescan yes  
 device_video_fastchange no  
 device_video_interlace yes  
 device_video_output auto  
 device_video_overlaysize auto  
 device_video_singlescan yes  
 dir_artwork /root/.advance/artwork:/media/BBB/share/advance/artwork  
 dir_diff /root/.advance/diff  
 dir_hi /root/.advance/hi  
 dir_image /root/.advance/image:/media/BBB/share/advance/image  
 dir_inp /root/.advance/inp  
 dir_memcard /root/.advance/memcard  
 dir_nvram /root/.advance/nvram  
 dir_rom /root/.advance/rom:/media/BBB/share/advance/rom  
 dir_sample /root/.advance/sample:/media/BBB/share/advance/sample  
 dir_snap /root/.advance/snap  
 dir_sta /root/.advance/sta  
 display_adjust none  
 display_antialias no  
 display_artwork_backdrop yes  
 display_artwork_bezel no  
 display_artwork_crop yes  
 display_artwork_overlay yes  
 display_aspectx 16  
 display_aspecty 9  
 display_beam 1  
 display_brightness 1  
 display_buffer no  
 display_color auto  
 display_expand 1  
 display_flicker 0  
 display_flipx no  
 display_flipy no  
 display_frameskip auto  
 display_gamma 1  
 display_intensity 1.5  
 display_interlaceeffect none  
 display_magnify 1  
 display_magnifysize 640  
 display_mode auto  
 display_pausebrightness 1  
 display_resize fractional  
 display_resizeeffect auto  
 display_restore yes  
 display_rgbeffect none  
 display_rol no  
 display_ror no  
 display_scanlines no  
 display_skipcolumns auto  
 display_skiplines auto  
 display_translucency yes  
 display_vsync yes  
 include   
 input_hotkey yes  
 input_idleexit 0  
 input_steadykey no  
 lcd_server none  
 lcd_speed 4  
 lcd_timeout 500  
 misc_bios default  
 misc_cheat no  
 misc_cheatfile cheat.dat  
 misc_difficulty none  
 misc_eventdebug no  
 misc_eventfile event.dat  
 misc_freeplay no  
 misc_hiscorefile hiscore.dat  
 misc_lang none  
 misc_languagefile english.lng  
 misc_mutedemo no  
 misc_quiet yes  
 misc_safequit no  
 misc_smp no  
 misc_timetorun 0  
 record_sound yes  
 record_sound_time 15  
 record_video yes  
 record_video_interleave 2  
 record_video_time 15  
 script_coin1   
 script_coin2   
 script_coin3   
 script_coin4   
 script_emulation   
 script_event1   
 script_event10   
 script_event11   
 script_event12   
 script_event13   
 script_event14   
 script_event2   
 script_event3   
 script_event4   
 script_event5   
 script_event6   
 script_event7   
 script_event8   
 script_event9   
 script_led1 on(kdb, 0b1); wait(!event()); off(kdb, 0b1);  
 script_led2 on(kdb, 0b10); wait(!event()); off(kdb, 0b10);  
 script_led3   
 script_play   
 script_safequit   
 script_start1   
 script_start2   
 script_start3   
 script_start4   
 script_turbo while (event()) { toggle(kdb, 0b100); delay(100); } off(kdb, 0b100);  
 script_video wait(!event()); set(kdb, 0);  
 sound_adjust auto  
 sound_equalizer_highvolume 0  
 sound_equalizer_lowvolume 0  
 sound_equalizer_midvolume 0  
 sound_latency 0.05  
 sound_mode auto  
 sound_normalize yes  
 sound_samplerate 44100  
 sound_samples yes  
 sound_volume -3  
 sync_fps auto  
 sync_resample auto  
 sync_speed 1  
 sync_startuptime auto  
 sync_turbospeed 3  
 ui_color[help_other] 000000 808080  
 ui_color[help_p1] 000000 ffff00  
 ui_color[help_p2] 000000 00ff00  
 ui_color[help_p3] 000000 ff0000  
 ui_color[help_p4] 000000 00ffff  
 ui_color[interface] 000000 ffffff  
 ui_color[select] 000000 afffff  
 ui_color[tag] 247ef0 ffffff  
 ui_font auto  
 ui_fontsize auto  
 ui_helpimage auto  
 ui_translucency 0.8  
 input_map[p1_up] keyboard[0,up]  
 input_map[p1_left] keyboard[0,left]  
 input_map[p1_right] keyboard[0,right]  
 input_map[p1_down] keyboard[0,down]  
 input_map[p1_button1] keyboard[0,a]  
 input_map[p1_button2] keyboard[0,s]  
 input_map[p1_button3] keyboard[0,d]  
 input_map[p1_button4] keyboard[0,q]  
 input_map[p1_button5] keyboard[0,w]  
 input_map[p1_button6] keyboard[0,e]  
 input_map[p1_button7] keyboard[0,z]  
 input_map[p1_button8] keyboard[0,x]  
 input_map[p2_up] keyboard[0,i]  
 input_map[p2_left] keyboard[0,j]  
 input_map[p2_right] keyboard[0,l]  
 input_map[p2_down] keyboard[0,k]  
 input_map[p2_button1] keyboard[0,f]  
 input_map[p2_button2] keyboard[0,g]  
 input_map[p2_button3] keyboard[0,h]  
 input_map[p2_button4] keyboard[0,r]  
 input_map[p2_button5] keyboard[0,t]  
 input_map[p2_button6] keyboard[0,y]  
 input_map[p2_button7] keyboard[0,v]  
 input_map[p2_button8] keyboard[0,b]  

Starting a game is "easy" once your paths are properly configured:
 advmame game_name  

You just have to "guess" your game name, but it is generally the name of your ROM, or very close, and Mame offers you suggestions if it fails at recognizing the game.

No comments:

Post a Comment