Difference between revisions of "Using dcload-ip with Linux"

From dreamcast.wiki
Jump to navigation Jump to search
Line 1: Line 1:
{{MARKDOWN}}
+
==Linux: using dcload-ip with the BBA==
## Linux : using dcload-ip with the BBA
 
 
This tutorial has been tested on a new Linux Mint 19.1 install and Windows Subsystem for Linux (WSL). My Dreamcast is connected directly to my computer, no router in between, using dcload-ip with a hardcoded static IP address.
 
This tutorial has been tested on a new Linux Mint 19.1 install and Windows Subsystem for Linux (WSL). My Dreamcast is connected directly to my computer, no router in between, using dcload-ip with a hardcoded static IP address.
  
### Dreamcast side
+
===Dreamcast side===
Get a selfbooting version of [dc-load-ip (in the "Releases" section)](https://github.com/Moopthehedgehog/dcload-ip). I've burned this with [imgburn](https://www.instructables.com/id/Dreamcast-Burn-Games-with-ImgBurn/) without any problem.
+
Get a selfbooting version of [https://github.com/Moopthehedgehog/dcload-ip dc-load-ip (in the "Releases" section)]. I've burned this with [https://www.instructables.com/id/Dreamcast-Burn-Games-with-ImgBurn/ imgburn] without any problem.
  
Next, boot **dc-load-ip** in your Dreamcast and make sure your BBA is connected in order to get your BBA mac address.
+
Next, boot '''dc-load-ip''' in your Dreamcast and make sure your BBA is connected in order to get your BBA mac address.
  
Once the green screen appears, note down your MAC address. It should look something like : `10:04:5d:2b:0f:4d`
+
Once the green screen appears, note down your MAC address. It should look something like: <code>10:04:5d:2b:0f:4d</code>
  
### Computer side (not necessary if using pre-built DHCP version)
+
===Computer side (not necessary if using pre-built DHCP version)===
 
We'll use the arp fonction to get your computer to "give" an IP address to your Dreamcast based on its mac address. In a terminal, enter:
 
We'll use the arp fonction to get your computer to "give" an IP address to your Dreamcast based on its mac address. In a terminal, enter:
 +
<syntaxhighlight lang="bash">sudo arp -s [IP address] [MAC address]</syntaxhighlight>
 +
*<code>[IP address]</code> is any valid IP address that you want to assign to your Dreamcast
 +
*<code>[MAC address]</code> is your dreamcast's MAC address, look at step 2.
  
` sudo arp -s [local IP address] [MAC address]`
+
The IP address should be in the same range as your local network. In my setup, my ethernet port is set on port 192.168.5.100 and my <code>[IP address]</code> is 192.168.5.99. If you don't know your network range, you can use <code>ifconfig</code> in a terminal to find out. I won't cover this here.
 
 
`[local IP address]` is any valid IP address that you want to assign to your Dreamcast
 
 
 
`[MAC address]` is your dreamcast's MAC address, look at step 2.
 
 
 
the local IP address should be in the same range as your network. In my setup, my ethernet port is set on port 192.168.5.100 and my `[local IP address]` is 192.168.5.99. If you don't know your network range, you can use `ifconfig` in a terminal to find out. I wont cover this here.
 
  
 
At this point, you should be able to see if your Dreamcast is connected.
 
At this point, you should be able to see if your Dreamcast is connected.
Line 25: Line 21:
 
A simple ping command should do the job.
 
A simple ping command should do the job.
  
`ping [local IP address]`
+
<syntaxhighlight lang="bash">ping [IP address]</syntaxhighlight>
 
 
you should get a message like : 64 byte from [local IP address] .... blabla ... time=xx ms
 
  
### Testing your code
+
You should get a message like: ''64 byte from [IP address] .... blabla ... time=xx ms''
You can now use the dc-tool-ip program to send your file to the DC. Make sure your Dreamcast is running **dc-load-ip**.
 
  
`dc-tool-ip -t [local IP address] -x /path/to/your/.bin/or/.elf/file`
+
===Testing your code===
 +
You can now use the dc-tool-ip program to send your file to the DC. Make sure your Dreamcast is running '''dc-load-ip'''.
 +
<syntaxhighlight>dc-tool-ip -t [IP address] -x /path/to/your/.bin/or/.elf/file</syntaxhighlight>
  
 
You can always run dc-tool-ip without any command to get some info on how to run it.
 
You can always run dc-tool-ip without any command to get some info on how to run it.
The -c option is useful if you need to use files that are located on your pc. You can use them with the `/pc` path.
+
The -c option is useful if you need to use files that are located on your pc. You can use them with the '/pc' path.
  
### Notes (for non-DHCP use)
+
===Notes (for non-DHCP use)===
#### arp
+
====arp====
The arp command used on step 3 will need to be entered every time you re log/shut down the dreamcast. I've added it to my `environ.sh` script.
+
The arp command used on step 3 will need to be entered every time you re log/shut down the dreamcast. I've added it to my <code>environ.sh</code> script.
  
#### Adding a host name
+
====Adding a host name====
 
Also, you can add a line to your host file in order to replace [local IP address] to a more friendly name.
 
Also, you can add a line to your host file in order to replace [local IP address] to a more friendly name.
 +
<syntaxhighlight lang="bash">sudo nano /etc/hosts</syntaxhighlight>
 +
then adding the line:
 +
<code>dreamcast [IP address]</code>
  
`sudo nano /etc/hosts`
+
You can now refer to <code>dreamcast</code> instead of your usual <code>[IP address]</code>
then adding the line :
 
`dreamcast [local IP address]`
 
 
 
You can now refer do `dreamcast` instead of your usual `[local IP adress]`
 
 
 
_Other info at [CubicVR](https://github.com/cjcliffe/CubicVR/wiki/Dreamcast:-dc-load-ip)_
 

Revision as of 14:10, 30 May 2020

Linux: using dcload-ip with the BBA

This tutorial has been tested on a new Linux Mint 19.1 install and Windows Subsystem for Linux (WSL). My Dreamcast is connected directly to my computer, no router in between, using dcload-ip with a hardcoded static IP address.

Dreamcast side

Get a selfbooting version of dc-load-ip (in the "Releases" section). I've burned this with imgburn without any problem.

Next, boot dc-load-ip in your Dreamcast and make sure your BBA is connected in order to get your BBA mac address.

Once the green screen appears, note down your MAC address. It should look something like: 10:04:5d:2b:0f:4d

Computer side (not necessary if using pre-built DHCP version)

We'll use the arp fonction to get your computer to "give" an IP address to your Dreamcast based on its mac address. In a terminal, enter:

sudo arp -s [IP address] [MAC address]
  • [IP address] is any valid IP address that you want to assign to your Dreamcast
  • [MAC address] is your dreamcast's MAC address, look at step 2.

The IP address should be in the same range as your local network. In my setup, my ethernet port is set on port 192.168.5.100 and my [IP address] is 192.168.5.99. If you don't know your network range, you can use ifconfig in a terminal to find out. I won't cover this here.

At this point, you should be able to see if your Dreamcast is connected.

A simple ping command should do the job.

ping [IP address]

You should get a message like: 64 byte from [IP address] .... blabla ... time=xx ms

Testing your code

You can now use the dc-tool-ip program to send your file to the DC. Make sure your Dreamcast is running dc-load-ip.

dc-tool-ip -t [IP address] -x /path/to/your/.bin/or/.elf/file

You can always run dc-tool-ip without any command to get some info on how to run it. The -c option is useful if you need to use files that are located on your pc. You can use them with the '/pc' path.

Notes (for non-DHCP use)

arp

The arp command used on step 3 will need to be entered every time you re log/shut down the dreamcast. I've added it to my environ.sh script.

Adding a host name

Also, you can add a line to your host file in order to replace [local IP address] to a more friendly name.

sudo nano /etc/hosts

then adding the line: dreamcast [IP address]

You can now refer to dreamcast instead of your usual [IP address]