nhaudio Posted December 16, 2006 Report Share Posted December 16, 2006 Hi,I'm looking for some help,I'm building a sid with external filter. I've build everything ok, but when rebuilding the software (main.asm) after modification (MIDIbox SID users: open the "main.asm" file of the application and set the "ENABLE_AOUT" switch to 2. Thereafter rebuild the project and upload the new .hex file to the core.) I get an error. I posted this message in the sid forum too, didn't know where it really belong. if anyone can help. thanksI on mac os x and using gputils. I've read in the forum that with gputils they're some limitation. I've tried to run the script from the wiki (http://www.midibox.org/dokuwiki/doku.php?id=compiling_the_midibox_source_on_linux) but no luck (I get a no command found). can't seem to make it running. it's been 2 days that I'm trying to do this little change and I'm getting really frustrated, so my question is more a favor, does someone did the modification and can send me the hex file (main.asm in hex)?my email is nh[at]nhaudio.com.thanks for the help and this great forum,cheers,Nicolas Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 16, 2006 Report Share Posted December 16, 2006 hi nicolas,in case you don't know, crossposting is not the most welcome thing you can do on a forum ;)it would be helpful if you write what you have done and the errormessage you get. have you fixed gpasm.sh to replace the macros?regards,Michael Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 16, 2006 Author Report Share Posted December 16, 2006 hi nicolas,in case you don't know, crossposting is not the most welcome thing you can do on a forum ;)it would be helpful if you write what you have done and the errormessage you get. have you fixed gpasm.sh to replace the macros?regards,Michaelsorry about it, but for my defense i stated it ;).I did it just because as a sid forum user I never checked the assembler forum, and since the topics could belong on both...tried to remove but wont let me do...so admin if you can remove the topic in the sid forum...On the real topic now, yes that's what I'm trying to do, to fix gpasm, but when I try to run the ./fix-gpasm.sh or it gives me a permission denied, so went with the $sodu ./fix-gpasm.sh then it gives me a command not found, I even tried logged in root but no luck either.when I try to run the ./fix-gpasm.sh I'm in the midibox_sid_v1_7303b folder where all the files are located. (I copied the script from the wiki, made 2 files with a txt editor, one called fix-gpasm.sh and the other replace-macros.sed then put everything in the midibox_sid_v1_7303b folder)can you help? ??? Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 16, 2006 Report Share Posted December 16, 2006 can you help?I'll try to ;)But I won't compile it for you, because I'm very busy and if you ever want to compile another app (like the seq), the same problem occurs.besides this issue, what you're going to learn is valid for hundrets of other cases on osx, so you won't regret having heard about it!when I try to run the ./fix-gpasm.sh or it gives me a permission deniedyou can set the right permissions by typing[tt]chmod -R 777[/tt] then drag the file(s) into the terminal window, so the line says:[tt]chmod -R 777 thePath/to/myFile.ext[/tt]the relevant permission here is that you can execute the script. not sure if sudo helps in this case...if you don't like the terminal, you could also start any ftp-application that supports setting permissions and check "execute" in the file props (instead of typing chmod...).now you should be able to execute the .sh-script.then it gives me a command not foundwhen you get this command, it tells you something is not found. now it would be interesting what is not found. can you look it up and guess why it's not found?try setting the current workpath before calling anything by typing:[tt]cd [/tt] and drag the folder into the terminal window, so you'll see[tt]cd path/to/myFolder/[/tt]cd stands for "change directory"if you still got "command not found" tell us the exact first error message, and we'll see how to continue...cheers,Michael Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 16, 2006 Author Report Share Posted December 16, 2006 I'll try to ;)But I won't compile it for you, because I'm very busy and if you ever want to compile another app (like the seq), the same problem occurs.besides this issue, what you're going to learn is valid for hundrets of other cases on osx, so you won't regret having heard about it!you can set the right permissions by typing[tt]chmod -R 777[/tt] then drag the file(s) into the terminal window, so the line says:[tt]chmod -R 777 thePath/to/myFile.ext[/tt]the relevant permission here is that you can execute the script. not sure if sudo helps in this case...if you don't like the terminal, you could also start any ftp-application that supports setting permissions and check "execute" in the file props (instead of typing chmod...).now you should be able to execute the .sh-script.when you get this command, it tells you something is not found. now it would be interesting what is not found. can you look it up and guess why it's not found?try setting the current workpath before calling anything by typing:[tt]cd [/tt] and drag the folder into the terminal window, so you'll see[tt]cd path/to/myFolder/[/tt]cd stands for "change directory"if you still got "command not found" tell us the exact first error message, and we'll see how to continue...cheers,Michaelhi michael thanks for the help,we made some progress, here's what I get[:~/Desktop/midibox_sid_v1_7303b] nicolash% ./fix-gpasm.sh./fix-gpasm.sh: line 4: src/*.inc: No such file or directory./fix-gpasm.sh: line 4: src/*.inc_: No such file or directory./fix-gpasm.sh: line 4: src/*.asm: No such file or directory./fix-gpasm.sh: line 4: src/*.asm_: No such file or directory./fix-gpasm.sh: line 4: src/*.h: No such file or directory./fix-gpasm.sh: line 4: src/*.h_: No such file or directory Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 16, 2006 Report Share Posted December 16, 2006 okay,now look at the second line in the sh script:[tt]for i in src/*.inc src/*.asm src/*.h;[/tt]that's a loop and says {do something} in all files in the sub-directory src with the file-ending *.inc.Now remember, that this script has been written to change the macros for the MIOS-sourcecode itself. You are using it for something else.The error sais, that it can't find a subfolder src.Can you solve that by yourself? :)another hint: the same applies for files with the ending .h (header files) and the ending .asmcheers,Michael Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 16, 2006 Author Report Share Posted December 16, 2006 okay,now look at the second line in the sh script:[tt]for i in src/*.inc src/*.asm src/*.h;[/tt]that's a loop and says {do something} in all files in the sub-directory src with the file-ending *.inc.Now remember, that this script has been written to change the macros for the MIOS-sourcecode itself. You are using it for something else.The error sais, that it can't find a subfolder src.Can you solve that by yourself? :)another hint: the same applies for files with the ending .h (header files) and the ending .asmcheers,Michaelok removed "src/*" in the scriptgot this (I hope it's ok?):~/Desktop/midibox_sid_v1_7303b] nicolash% ./fix-gpasm.shsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by textsed: 1: replace-macros.sed: command i expects \ followed by text[nicolas-hermansens-powerbook-g4-12:~/Desktop/midibox_sid_v1_7303b] nicolash% Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 16, 2006 Report Share Posted December 16, 2006 Hi Nicolas,you must not remove src/* but only the path src/*.inc searches for {anyfile}.incand forget about all errors, no need to get afraid by a long listing, just look at the very first error!it sais "command i expects" something. That means you gave something to it that was not expected, in other words it can't deal with it!Now when you look at the line of the bash script you wrote:"for i in *.asm..." (your faulty version should say "for i in .asm"...)you see that after "i" is "in", we can ignore that cause it's part of the for loop statement. Then comes ".asm" and that's why it's complaining. So by reading the error message right, you are able to look up where the problem is by yourself!(I'm now away from the computer the next hours, so don't wonder if I'm not answering right away :), but I'll be back...Cheers,Michael Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 16, 2006 Author Report Share Posted December 16, 2006 Hi Nicolas,you must not remove src/* but only the path src/*.inc searches for {anyfile}.incand forget about all errors, no need to get afraid by a long listing, just look at the very first error!it sais "command i expects" something. That means you gave something to it that was not expected, in other words it can't deal with it!Now when you look at the line of the bash script you wrote:"for i in *.asm..." (your faulty version should say "for i in .asm"...)you see that after "i" is "in", we can ignore that cause it's part of the for loop statement. Then comes ".asm" and that's why it's complaining. So by reading the error message right, you are able to look up where the problem is by yourself!(I'm now away from the computer the next hours, so don't wonder if I'm not answering right away :), but I'll be back...Cheers,Michaelhey michael I did a typo, I had only removed src/ so the fault is not coming from there...but...I feel a bit stupid but this time I don't get it. ;-(let me know when you have some spare time,cheers,nicolas Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 16, 2006 Report Share Posted December 16, 2006 I tried this and found out that it should work if you write [tt]\'*.asm'[/tt]The error message itself gave this hint:command i expects \ followed by textnow I'm not sure if the sh script will work that way on OSX. I'll check that later. Maybe it already works this way for you?cheers,Michaelps: no reason to feed stupid, one cannot know this if you're not used to programming :) Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 16, 2006 Author Report Share Posted December 16, 2006 I tried this and found out that it should work if you write [tt]\'*.asm'[/tt]The error message itself gave this hint:now I'm not sure if the sh script will work that way on OSX. I'll check that later. Maybe it already works this way for you?cheers,Michaelps: no reason to feed stupid, one cannot know this if you're not used to programming :) :'(not yet ;)i did try a few things first like this:#!/bin/shfor i in \'*.inc' \'*.asm' \'*.h';do tr -d '\r' < $i|sed -f replace-macros.sed >${i}_ && mv ${i}_ $idonegot that:~/Desktop/midibox_sid_v1_7303b] nicolash% ./fix-gpasm.sh./fix-gpasm.sh: line 4: unexpected EOF while looking for matching `''./fix-gpasm.sh: line 6: syntax error: unexpected end of filethen like this#!/bin/shfor i in '\*.inc' '\*.asm' '\*.h';do tr -d '\r' < $i|sed -f replace-macros.sed >${i}_ && mv ${i}_ $idoneand got that~/Desktop/midibox_sid_v1_7303b] nicolash% ./fix-gpasm.sh./fix-gpasm.sh: line 3: unexpected EOF while looking for matching `''./fix-gpasm.sh: line 5: syntax error: unexpected end of filethen like this#!/bin/shfor i in '\*.inc' '\*.asm' '\*.h';do tr -d '\r' < $i|sed -f replace-macros.sed >${i}_ && mv ${i}_ $idoneand got that~/Desktop/midibox_sid_v1_7303b] nicolash% ./fix-gpasm.sh./fix-gpasm.sh: line 3: \*.inc: No such file or directorysed: 1: replace-macros.sed: command i expects \ followed by text./fix-gpasm.sh: line 3: \*.asm: No such file or directorysed: 1: replace-macros.sed: command i expects \ followed by text./fix-gpasm.sh: line 3: \*.h: No such file or directorysed: 1: replace-macros.sed: command i expects \ followed by textthen last one like this#!/bin/shfor i in \'*.inc' \'*.asm' \'*.h';do tr -d '\r' < $i|sed -f replace-macros.sed >${i}_ && mv ${i}_ $idoneand got that:~/Desktop/midibox_sid_v1_7303b] nicolash% ./fix-gpasm.sh./fix-gpasm.sh: line 3: unexpected EOF while looking for matching `''./fix-gpasm.sh: line 5: syntax error: unexpected end of filethanks agan for the help,cheers,Nicolas Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 17, 2006 Report Share Posted December 17, 2006 #!/bin/shfor i in \'*.inc' \'*.asm' \'*.h';do tr -d '\r' < $i|sed -f replace-macros.sed >${i}_ && mv ${i}_ $idonegot that:~/Desktop/midibox_sid_v1_7303b] nicolash% ./fix-gpasm.sh./fix-gpasm.sh: line 4: unexpected EOF while looking for matching `''./fix-gpasm.sh: line 6: syntax error: unexpected end of filethe first one is right.You can see your success in the change of the errormessages ;DNow it finds the files, but there's still an error in the shell script => unexpected EOF (= End of File), that means that the syntax or the file encoding is not correct. Maybe it runs fine on Linux... As I'm no bash-crack either, I have to look this up by myself: I will check this tomorrow and come back with an update, if your patience is still there :)Regards,Michael Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 17, 2006 Author Report Share Posted December 17, 2006 much respect 8)if you ever come to italy, I owe a couple of beer...at least Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 17, 2006 Report Share Posted December 17, 2006 hey, don't cheer too soon :)could you try the following; I succeeded in calling, but I don't know if it replaces everything like expected:#!/bin/sh -xfor i in \src/*.asm \src/*.h \src/*.inc; do tr -d '\r' < $i | sed -f replace-macros.sed > ${i}_ && mv ${i}_ $idoneI put all files in src/ but you may leave that out' date=' so the line should read: "for i in \*.asm"... and so on.The EOF error occurs when ' or " are used, so obviously we just need the backslash for OSX compatibility...then there's been a problem with the sed-file. it seems, that comments are not recognized if they don't start at the line's beginning. And I have no clue what the first line is there for; it definitely produces an error. I simply commented it out, but it may be that I broke the functionality...#1i;hey emacs, this is -*- asm -*-#skip commented line/^[ \t]*;/b#skip macro definitions/^\s*\w*\s*MACRO/b s/\<BIFSET\s*\([^,]*\)\s*,\s*\([^,]*\),\s*\([^,]*\)\s*,\s*\(.*\)/btfsc \1, \2, \3\n\t\4/gs/\<BIFCLR\s*\([^,]*\)\s*,\s*\([^,]*\),\s*\([^,]*\)\s*,\s*\(.*\)/btfss \1, \2, \3\n\t\4/gs/\<IFSET\s*\([^,]*\)\s*,\s*\([^,]*\),\s*\(.*\)/btfsc \1, \2\n\t\3/gs/\<IFCLR\s*\([^,]*\)\s*,\s*\([^,]*\),\s*\(.*\)/btfss \1, \2\n\t\3/gs/\<IFNEQ\s*\([^,]*\)\s*,\s*\([^,]*\),\s*\(.*\)/cpfseq \1, \2\n\t\3/gs/\<IFLEQ\s*\([^,]*\)\s*,\s*\([^,]*\),\s*\(.*\)/cpfsgt \1, \2\n\t\3/gs/\<IFGEQ\s*\([^,]*\)\s*,\s*\([^,]*\),\s*\(.*\)/cpfslt \1, \2\n\t\3/gs/\<rgoto\>/bra/gLet's see if we get one step further :)regards,Michael Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 17, 2006 Author Report Share Posted December 17, 2006 well I think we're getting there...here is what I got:/Desktop/midibox_sid_v1_7303b] nicolash% ./fix-gpasm.sh+ tr -d '\r'./fix-gpasm.sh: line 4: *.asm: No such file or directory+ sed -f replace-macros.sed+ mv '*.asm_' '\*.asm_' main.asm_ setup_6581.asm_ setup_6581_without_cs.asm_ setup_8580.asm_ setup_8580_without_cs.asm_ main.asm setup_6581.asm setup_6581_without_cs.asm setup_8580.asm setup_8580_without_cs.asmusage: mv [-f | -i | -n] [-v] source target mv [-f | -i | -n] [-v] source ... directory+ tr -d '\r'./fix-gpasm.sh: line 4: *.h: No such file or directory+ sed -f replace-macros.sed+ mv '*.h_' '\*.h_' app_defines.h_ macros.h_ mios.h_ app_defines.h macros.h mios.husage: mv [-f | -i | -n] [-v] source target mv [-f | -i | -n] [-v] source ... directory+ tr -d '\r'./fix-gpasm.sh: line 4: *.inc: No such file or directory+ sed -f replace-macros.sed+ mv '*.inc_' '\*.inc_' app_lcd.inc_ cs_menu.inc_ cs_menu_bank.inc_ cs_menu_buttons.inc_ cs_menu_cc_table.inc_ cs_menu_enc.inc_ cs_menu_enc_table.inc_ cs_menu_exec.inc_ cs_menu_io_tables.inc_ cs_menu_leds.inc_ cs_menu_matrix.inc_ cs_menu_ms.inc_ cs_menu_p2r_r2p.inc_ cs_menu_print.inc_ cs_menu_tables.inc_ cs_menu_tables_struct.inc_ cs_menu_timer.inc_ j5_dout.inc_ math_mul16_16.inc_ midi_rxtx.inc_ mios_tables.inc_ mios_vectors.inc_ p18f452.inc_ p18f4520.inc_ p18f4620.inc_ sid_aout.inc_ sid_aout_lc.inc_ sid_bank.inc_ sid_cc_table.inc_ sid_ccin.inc_ sid_ccout.inc_ sid_depth_table.inc_ sid_env_table.inc_ sid_frq_table.inc_ sid_lcd.inc_ sid_lfo_table.inc_ sid_midi.inc_ sid_note_table.inc_ sid_patch.inc_ sid_presets.inc_ sid_sin_table.inc_ sid_sr.inc_ sid_sw.inc_ sid_sysex.inc_ sid_sysex_table.inc_ sid_tune.inc_ sid_wt.inc_ special_characters.inc_ user_vectors.inc_ app_lcd.inc cs_menu.inc cs_menu_bank.inc cs_menu_buttons.inc cs_menu_cc_table.inc cs_menu_enc.inc cs_menu_enc_table.inc cs_menu_exec.inc cs_menu_io_tables.inc cs_menu_leds.inc cs_menu_matrix.inc cs_menu_ms.inc cs_menu_p2r_r2p.inc cs_menu_print.inc cs_menu_tables.inc cs_menu_tables_struct.inc cs_menu_timer.inc j5_dout.inc math_mul16_16.inc midi_rxtx.inc mios_tables.inc mios_vectors.inc p18f452.inc p18f4520.inc p18f4620.inc sid_aout.inc sid_aout_lc.inc sid_bank.inc sid_cc_table.inc sid_ccin.inc sid_ccout.inc sid_depth_table.inc sid_env_table.inc sid_frq_table.inc sid_lcd.inc sid_lfo_table.inc sid_midi.inc sid_note_table.inc sid_patch.inc sid_presets.inc sid_sin_table.inc sid_sr.inc sid_sw.inc sid_sysex.inc sid_sysex_table.inc sid_tune.inc sid_wt.inc special_characters.inc user_vectors.incusage: mv [-f | -i | -n] [-v] source target mv [-f | -i | -n] [-v] source ... directory Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 17, 2006 Report Share Posted December 17, 2006 could you try it moving all the sources in a subdirectory src/ and use the folder? because when I tested this, I got no error "*.h file not found". at least there are .h, .asm and .inc files, so you should not see this error...regards, michael Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 17, 2006 Author Report Share Posted December 17, 2006 could you try it moving all the sources in a subdirectory src/ and use the folder? because when I tested this, I got no error "*.h file not found". at least there are .h, .asm and .inc files, so you should not see this error...regards, michaelgot this, I think it's good...~/Desktop/midibox_sid_v1_7303b] nicolash% ./fix-gpasm.sh+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/main.asm_ src/main.asm+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/setup_6581.asm_ src/setup_6581.asm+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/setup_6581_without_cs.asm_ src/setup_6581_without_cs.asm+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/setup_8580.asm_ src/setup_8580.asm+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/setup_8580_without_cs.asm_ src/setup_8580_without_cs.asm+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/app_defines.h_ src/app_defines.h+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/macros.h_ src/macros.h+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/mios.h_ src/mios.h+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/app_lcd.inc_ src/app_lcd.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu.inc_ src/cs_menu.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_bank.inc_ src/cs_menu_bank.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_buttons.inc_ src/cs_menu_buttons.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_cc_table.inc_ src/cs_menu_cc_table.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_enc.inc_ src/cs_menu_enc.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_enc_table.inc_ src/cs_menu_enc_table.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_exec.inc_ src/cs_menu_exec.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_io_tables.inc_ src/cs_menu_io_tables.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_leds.inc_ src/cs_menu_leds.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_matrix.inc_ src/cs_menu_matrix.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_ms.inc_ src/cs_menu_ms.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_p2r_r2p.inc_ src/cs_menu_p2r_r2p.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_print.inc_ src/cs_menu_print.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_tables.inc_ src/cs_menu_tables.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_tables_struct.inc_ src/cs_menu_tables_struct.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/cs_menu_timer.inc_ src/cs_menu_timer.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/j5_dout.inc_ src/j5_dout.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/math_mul16_16.inc_ src/math_mul16_16.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/midi_rxtx.inc_ src/midi_rxtx.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/mios_tables.inc_ src/mios_tables.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/mios_vectors.inc_ src/mios_vectors.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/p18f452.inc_ src/p18f452.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/p18f4520.inc_ src/p18f4520.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/p18f4620.inc_ src/p18f4620.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_aout.inc_ src/sid_aout.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_aout_lc.inc_ src/sid_aout_lc.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_bank.inc_ src/sid_bank.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_cc_table.inc_ src/sid_cc_table.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_ccin.inc_ src/sid_ccin.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_ccout.inc_ src/sid_ccout.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_depth_table.inc_ src/sid_depth_table.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_env_table.inc_ src/sid_env_table.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_frq_table.inc_ src/sid_frq_table.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_lcd.inc_ src/sid_lcd.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_lfo_table.inc_ src/sid_lfo_table.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_midi.inc_ src/sid_midi.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_note_table.inc_ src/sid_note_table.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_patch.inc_ src/sid_patch.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_presets.inc_ src/sid_presets.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_sin_table.inc_ src/sid_sin_table.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_sr.inc_ src/sid_sr.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_sw.inc_ src/sid_sw.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_sysex.inc_ src/sid_sysex.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_sysex_table.inc_ src/sid_sysex_table.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_tune.inc_ src/sid_tune.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/sid_wt.inc_ src/sid_wt.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/special_characters.inc_ src/special_characters.inc+ tr -d '\r'+ sed -f replace-macros.sed+ mv src/user_vectors.inc_ src/user_vectors.inc Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 17, 2006 Report Share Posted December 17, 2006 all right, no more errors. :Dyou should check the contents if the problematic mpasm stuff is gone.what happens if you compile it with gpasm?if it's working, is the new compiled hex-file identical to the original one? Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 17, 2006 Author Report Share Posted December 17, 2006 all right, no more errors. :Dyou should check the contents if the problematic mpasm stuff is gone.what happens if you compile it with gpasm?if it's working, is the new compiled hex-file identical to the original one? >:( I still get this if I try to compile~/Desktop/midibox_sid_v1_7303b/src] nicolash% gpasm main.asmsid_sin_table.inc:34:Error [103] syntax errormain.asm:520:Error [103] syntax errorcs_menu_io_tables.inc:35:Warning [202] Argument out of range. Least significant bits used.cs_menu_io_tables.inc:35:Warning [202] Argument out of range. Least significant bits used.cs_menu_io_tables.inc:35:Warning [202] Argument out of range. Least significant bits used.cs_menu_io_tables.inc:35:Warning [202] Argument out of range. Least significant bits used.cs_menu_io_tables.inc:35:Warning [202] Argument out of range. Least significant bits used.cs_menu_buttons.inc:100:Error [103] syntax errorcs_menu_buttons.inc:102:Error [103] syntax errorcs_menu_buttons.inc:104:Error [103] syntax errorcs_menu_buttons.inc:106:Error [103] syntax errorthe syntax error goes on for a while Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 17, 2006 Report Share Posted December 17, 2006 yes, but you really need to go through it logically:-> if the error is the same as before: have you checked if the script really works and actually modifies the sources? you have not answered this.-> if the sources get modified by the script: weren't you the one who also tried to compile the seq application? will this work? Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 17, 2006 Author Report Share Posted December 17, 2006 yes, but you really need to go through it logically:-> if the error is the same as before: have you checked if the script really works and actually modifies the sources? you have not answered this.-> if the sources get modified by the script: weren't you the one who also tried to compile the seq application? will this work?well in theory it should work, it's from the wiki so I gess (i hope) people did try before me.no it wasn't me who tried to do the seq. I'll redo everything to see if it changes something. For what should I look in theory?thanks againnico Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 17, 2006 Report Share Posted December 17, 2006 okay.the wiki page sais it quite clear, but I'm going to repeat it:there are macros used in the asm sources that are related to microchip's MPASM compiler and will therefore only work if you compile the source with MPASM! If you try to compile it with GPASM it will fail. Of course. That's the syntax error you get when you try to compile.This bash-script tries to identify these MPASM macros and convert them by search-and-replace, so that the sources will become (eventually) GPASM compatible.Before compiling again and again, you should make sure, that the bash-script actually works and really exchanged the problematic macros. The wiki entry has been written for Linux and you're on a Mac. And the Wiki is no professional book, it's written by people like you and me to help others, so this does not mean that everything is gold and the absolute truth.And don't forget: the script is not only for Linux, it's also for MIOS sources! So I don't know if there are any Macros in the SID sources that are not covered by this script.In other words: you should backup the original files for future reference, add the script (of course the adapted one for the mac), run the script and compare the freshly modified files agains the original ones to see if the script works!If the script works, you can try to compile with GPASM. The resulting hex-file should also be compared against the original hex-file (of course without having modified anything else!) to see, if it contains the same code.If the script does not work, we have to see how to make it work.If you're in hurry you should install MPASM for Windows and compile it on your PC. If you'd like to do it on OSX, we can continue this, but I can't guarantee anything... and I surely don't interspect all SID sources for problematic macros...regards,Michael Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 17, 2006 Author Report Share Posted December 17, 2006 The top part I knew, though true that it's for mios and not sid app. ok I've checked one file, and at least in the main.asm there's no change before and after running the script.I need to check the oher files.So maybe the script doesn't work with os X? or with the sid application.I really don't know...but if it works with linux should it work with os x too? I guess you half answered the question already. If you have a clue of where to go from here, we can try and continue to work on it, but I understand that it might be time consuming for you. your call. It would be a great plus for os x users.in the short run I think the easiest way for me is to try to find a friend with a pc and do it at his house. while we can continue to try and find a script that works. again, thank you for your time,cheers,Nicolas Quote Link to comment Share on other sites More sharing options...
audiocommander Posted December 17, 2006 Report Share Posted December 17, 2006 yes, that sounds great.I'm also interested in getting this going. remember I disabled the first line of the script, so I think this may be the reason why it's not working.But you're right, I'm currently very short on time – but I'll give my best to continue on this, even if I may not answer immediately ;)cheers!Michael Quote Link to comment Share on other sites More sharing options...
nhaudio Posted December 17, 2006 Author Report Share Posted December 17, 2006 hey, I saw your other forum post:But there's one thing I couldn't get done on my mac: burning the PIC. There's no serial Port and all USB-Adaptors have never worked relyable and / or there were no drivers available. So after all, if you want to burn MIOS into a chip, you'll need a PC. (Don't know if this changes with MBHP-Burner, I used JDM).I saw this article, maybe you didn't know about it and I think it's related:http://www.mactech.com/articles/mactech/Vol.20/20.02/PICMicrocontroller/index.htmldo you think the jal could work for our purpose? I'm going to try anyway.cheers,Nicolas Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.