MSX with Nextor 2.11 : Batch file Error : Command too long

By Xrider

Supporter (2)

Xrider さんの画像

18-11-2021, 19:48

Hello everybody,

I have a SD MAPPER MegaRAM Card V2, and when i boot with SD CARD, i have this error :
Batch file Error : Command too long

When i say "N", i can run everything, include sofarun :)
SD card Format in FAT16, and all the file on my sd card come from the "SD" folder of the github :
https://github.com/fbelavenuto/msxsdmapperv2
Do you know what is this error please ?
How to fix it ?

Thanks

ログイン/登録して投稿

By Pencioner

Scribe (1523)

Pencioner さんの画像

18-11-2021, 21:05

i think the AUTOEXEC.BAT file you have put on your card has wrong endlines - they should be in DOS, not Unix or MacOS format. with wrong endlines your whole batch file is treated as one long command which exceeds the 255 chars length limit. i usually fix in the Vim file editor but if you didn't ever used it better google for some "Unix to DOS endline converter" or alike because Vim could be very confusing at the first use

By Grauw

Ascended (10578)

Grauw さんの画像

19-11-2021, 10:53

I concur. The line endings for MSX should be CR LF (carriage return, line feed) as is used by DOS and Windows, instead of just LF as is used by Unix based systems such as Linux or macOS.

Something must’ve gone wrong when either creating or cloning the Git repo, since these seem like they are files that should be already made for MSX and thus have the correct line endings. Perhaps an automatic line endings translation function in Git messed it up. Or else perhaps you edited the file on a Unix system, some editors like Nano like to automatically change line endings to Unix style.

When I need to change line endings I do so in Visual Studio Code, or with the command line tools dos2unix and unix2dos that I installed via the Homebrew package manager (I’m on macOS).

By Grauw

Ascended (10578)

Grauw さんの画像

19-11-2021, 11:01

Grauw wrote:

Something must’ve gone wrong when either creating or cloning the Git repo, since these seem like they are files that should be already made for MSX and thus have the correct line endings. Perhaps an automatic line endings translation function in Git messed it up.

Yup, that seems to be the case. When I clone the repo on macOS I’m getting LF line endings in AUTOEXEC.BAT as well, so it seems the repository was created on Windows with Git configured to automatically translate line endings. The core.autocrlf function mangled all text files in the repository to be unusable on MSX. I would contact the repository creator to see if he can fix it.

By retro69

Rookie (19)

retro69 さんの画像

28-11-2021, 13:15

I am relatively new to MSX. The mentioned SD Mapper MegaRAM looks interesting. If it uses Nextor then you should have good support for disk images and direct access to the SD card out of DOS and MSX-Basic. I also understand that it includes a RAM expansion which can also be used for running ROM images. This would mean that the basic functionality is similar to the Mega Flash Rom. At the same time it appears to be significantly less expensive. I would be interested to hear your experiences with this hardware.

By Grauw

Ascended (10578)

Grauw さんの画像

28-11-2021, 14:05

@retro69 The biggest issue is that the MegaRAM disables the Mapper RAM expansion, it is a selection between either the one or the other. Since Nextor DOS2 requires at least 128K (mapper) RAM, this means that on 64K machines you can not use Nextor DOS2 and the MegaRAM function simultaneously, and on 32K or 16K machines you can’t use DOS1 and MegaRAM either.

But this thread is about a particular error message and this is off-topic, so for further questions I recommend to either find a more suitable existing mapper megaram threads, or to start a new thread.