Gecko dotNET mono discussion

Started by dcx2, April 17, 2010, 02:42:59 AM

Previous topic - Next topic

dcx2

This is how you get to the dialog that changes the project file.  There's the menu bar

[spoiler][/spoiler]

Or the project file's context menu

[spoiler][/spoiler]

Once there, add ;MONO (highlighted) to the symbols defined, and that should be it.  No adding#define's to files.

[spoiler][/spoiler]

EDIT:  The Debug configuration is for running with a debugger attached.  It has no optimizations, which make it harder to find bugs.  If you're running from the command line, you should use the Release configuration (and make sure the MONO symbol is defined for it, too)

hawkeye2777

#16
Awesome, I'll test this out right away.

Quote from: dcx2 on April 19, 2010, 12:09:46 PM
I don't know why the context menu is missing, but I can look into that (it's important!)  Perhaps we should use mono 3.5...there might be improvements that mono 2.0 is missing.  I also can't find if monodevelop has a form designer, which makes it so much easier to navigate around the app source code...

Don't recall a form designer for WinForms, only for GTK#. If you can help sort out the GUI specific functions, classes, and files; I can work on making a GTK# version.

QuoteI also don't know why it breaks /dev/ttyUSB0, or why it doesn't read/write /dev/ttyUSB0 instead of using libftdi.  Most of this was written by Link, and there might be reasons he did it this way.  But, hopefully, hawkeye will post a guide on modifying udev rules so we don't need root.

Well, the way I got WiiRd console (should also work w/ Gecko dotNET) was not through udev rules; that seems pretty kernel specific from the quick glance I took at it. The method I used is partially dependent on specific distros, but it should work on most of them. To be honest, it isn't my method (saw it in these forums somewhere), but with some work I should be able to make a general Linux version that will give the normal users permission to read and write to the USB Gecko.


EDIT: Some questions/comments...

1. Does it matter if powerpc-eabi tools are used (e.g. powerpc-eabi-objcopy), or does it have to be powerpc-gekko? In the case of the latter, I'll have to hunt down both Mac and Linux versions of those respective binaries.

2. I'll have to make a configuration script for GDN (Mono)... so that proper configurations can be made for Mac and Linux versions as far as getting the proper external binary names for each.

I'll post more as I think of them; hopefully I can get a quick guide to allow you to run GDN as a normal user made tonight too.

EDIT (2):

Follow this to be able to run GDN as normal user: http://wiird.l0nk.org/forum/index.php/topic,3127.msg33453.html#msg33453
Currently "retired" from hacking codes.

dcx2

Did you run as root or follow hawkeye's most recent EDIT2 link?

hawkeye2777

Few basic questions first: What distro do you run? Do you have libftdi installed?

Currently "retired" from hacking codes.

dcx2

You can use the libftdi that's in the repositories.  I normally use Synaptic Package Manager, but I'm sure hawkeye could drop by with the appropriate apt-get kungfu.

giantpune

make sure youre running it with root (sudo).

hawkeye2777

It'll be a bit easier to install GDN once I get a proper ppa set up, but for now, download this: http://www.mediafire.com/file/gmtytkhyqwo/gdnb-mono.tar.bz2

Unfortunately, this is more geared towards Ubuntu, so you'll need knowledge of your own distro if you do not run Ubuntu. Otherwise, these instructions should work for Ubuntu users (tested on Ubuntu 10.04 Lucid Lynx).

First off, download the tarbell linked above. Extract it to a directory of your choice. In this tutorial, I'll use the directory '/home/user/bin/gecko-dotnet', and I'll place gdnb-mono.tar.bz2 in ~/bin. Open up a terminal and enter the following:

cd bin
tar -xjf gdnb-mono.tar.bz2
cd gecko-dotnet
chmod +x configure gecko-dotnet


While my configuration script may not be very good, it should work well enough. Run this and follow the prompts (should just be one sudo authentication):

./configure

Once that's done, you should be all set. Mono is installed by default in GNOME, so that should not be an issue. If you run Jaunty (9.04) or earlier, you will have to build libftdi from source. I can provide instructions for this too if necessary. Other than that, all you'll need to run is this following to execute GDN:

/home/user/bin/gecko-dotnet/gecko-dotnet #Replace user with your account username

If you need anything else, just ask. I think I covered everything.
Currently "retired" from hacking codes.

memememememe

Hi, im new to linux and pretty new to the whole USB Gecko thing but i can find my way around.
After changing my laptop from XP to Ubuntu 10.04 Lucid, i thought that i could have the same gecko experience... How wrong i was :p

Being restricted to using the terminal is not an option for me as i dont know my way around the linux terminal and using wine to use the windows version will not work for me because of the lack of drivers. Or is there a way around that?

So when i read this i was filled with joy that someone finally did something about this.
Although like i said i am new to this so...

If someone would be so kind as to give me a noob tutorial and crash cource on getting this to run i would be forever greatful.

Please get back to me,
.:Thanks:.

hawkeye2777

Quote from: memememememe on May 15, 2010, 01:22:39 PM
Being restricted to using the terminal is not an option for me as i dont know my way around the linux terminal...

So bash scripts are out of the question? Even if this was packaged into a .deb, you still might have to run a bash script.

The reason why primarily solutions using the terminal are given is that it is easier and faster. All you have to do (usually) is just copy and paste the commands given to you; just be careful before running them for security reasons, in case the commands are malicious (this is a useful read if you are a new Linux user).

Anyway, I'll try to get a deb package for GDN... just haven't had the time to do so yet.
Currently "retired" from hacking codes.

memememememe

Thanks heaps, i guess ill give the terminal a go seeing as i have to.

But how do i get my gecko to connect?

hawkeye2777

#25
I'm almost done with the deb package, if I can get post-install scripts to work right, then you shouldn't need to run any bash script.

I'll also upload a standard tarbell of the binaries and the changed sources (my Mono/Linux specific edits) too.

EDIT: I'll upload it tomorrow; just have to test it on a mint install (probably a Live CD of Lucid). No bash script is required, all you should need to do is connect your USB gecko to your computer and run the deb installer.

For those with a *.rpm based distro, I'll get a tarbell of binaries and sources uploaded too, although it may not be tomorrow.

EDIT2: I had a working deb, but I have to reconfigure the program to put the config files in a different location before I can distribute the deb.
Currently "retired" from hacking codes.

hawkeye2777

#26
Here's the deb package: gecko-dotnet_0.61-4.deb (1.2 MiB)

Instructions:

*Make sure you have your USB Gecko connected to your computer when you install this.

1. Download the file to your Desktop (or another location), then double click the deb file (this should launch GDebi).
2. Review any details you may want before installing, then click 'Install Package' and type in your password.
3. Click the "show terminal button" on the installation dialog (Progress bar, etc.), click in the terminal screen, read the statement and then press enter. Failure to do this step will leave GDebi idle (it won't install Gecko dotNET).
4. Sit back for a minute or two for the install to finish.

OR you can install using the terminal. Here's a set of commands that should work:

cd $HOME/Desktop
wget -c "http://ubuntuone.com/p/4My/" -O gecko-dotnet_0.61-4.deb
sudo dpkg -i gecko-dotnet_0.61-4.deb


Just press enter when it asks, then it should install just as fine as GDebi would.

When the install is complete, you can find the menu entry in Applications -> Programming (under the name of "Gecko dotNET") or by running the command "gecko-dotnet".

All config files should be placed in "/home/[yourusername]/.gecko-dotnet".

This should hopefully work without problems; let me know if it doesn't (the only issue might occur with dependencies). Also, this was tested on Ubuntu 10.04 Lucid Lynx only, and will probably only work on this version (due to older versions of libftdi that were shipped in previous versions).

Enjoy!

EDIT: I just realized I forgot something important; run this command in a terminal:

sudo ln -s /usr/lib/libftdi.so.1 /usr/lib/libftdi.so

This creates a necessary symbolic link so that Gecko dotNET can access libftdi (otherwise GDN is useless). I'll try to include this in the next revision of the deb package.
Currently "retired" from hacking codes.

giantpune

i tried to try the deb, but its only for i386.

memememememe

THANKYOU SOOO MUCH,

Ill try it now,
rep 4 u!!

hawkeye2777

As a FYI, that package doesn't work on a default install; I missed a package in the dependencies. I'll try to make a new one tonight.

Still kinda new to deb packaging. :p
Currently "retired" from hacking codes.