Society of Robots - Robot Forum

Software => Software => Topic started by: Alhazar on July 30, 2008, 09:41:25 PM

Title: Omni Robot Sourcecode
Post by: Alhazar on July 30, 2008, 09:41:25 PM
I am planning on building a omni bot and was looking at this page. The source at the bottom is for PIC is there a way to decompile it and load it onto an axon?
Title: Re: Omni Robot Sourcecode
Post by: izua on July 30, 2008, 10:35:41 PM
There's no source posted :) There's also no link posted.
Anyway, you can decompile it, but you'll get assembly code.. As long as it uses no hardware functions (PWM, timers, interrupts) it can be ported manually to the AVR platform. With a lot of knowledge of both platforms, you can probably also port the hardware functions.

I've done it once, and it was the last time I will attempt such an endeavour.
Title: Re: Omni Robot Sourcecode
Post by: Alhazar on July 30, 2008, 11:18:06 PM
Opps forgot to add the links Page http://www.societyofrobots.com/robot_omni_wheel.shtml Source http://www.societyofrobots.com/downloads/fuzzy_C_source_code.zip
Title: Re: Omni Robot Sourcecode
Post by: izua on July 31, 2008, 08:46:41 AM
That's C dude. No decompiling needed, just porting.
I was talking about a hex level port.
Title: Re: Omni Robot Sourcecode
Post by: Alhazar on July 31, 2008, 09:06:48 AM
i didnt have visual studio on this system i was browsing on my ppc and couldnt open the file my bad
Title: Re: Omni Robot Sourcecode
Post by: izua on July 31, 2008, 09:09:14 AM
You don't need Visual Studio to open C code for PIC.
Any editor such as VIM would do. What you need is a compiler, actually.
Title: Re: Omni Robot Sourcecode
Post by: Admin on August 02, 2008, 05:15:48 PM
Just study the file fuzzy.c for a bit until it makes sense.

If I remember right, the code was written so that I give it three control variables:
maximum servo speed
robot rotational speed (about its axis)
angle to translate to (move straight or sideways)

There is also a trig lookup table. The Axon also has a lookup table in SoR_utils.h, but its mostly untested.
Title: Re: Omni Robot Sourcecode
Post by: Alhazar on August 06, 2008, 05:17:26 PM
i've been looking thought the code and jsp2_Util_fuz.h is including 3 headers that weren't in the zip file, 16f877.h and adc.h which i got off of online but its also calling for a 877reg.h but i cant seem to find that file or references to it using google at all....
Title: Re: Omni Robot Sourcecode
Post by: pomprocker on August 06, 2008, 06:02:22 PM
are you going to be using an avr?



some of those  your refering to may be pic specific
Title: Re: Omni Robot Sourcecode
Post by: Alhazar on August 06, 2008, 06:05:13 PM
I was using bloodshed, i dl'd avr but havent played with it yet. i found the 2 others just cant find the 877reg.h


I installed AVR and did a search for the 877reg.h file but found nothing.
Title: Re: Omni Robot Sourcecode
Post by: pomprocker on August 06, 2008, 06:20:40 PM
no i mean what mcu will you be using?

atmega?

16f877.h and  877reg.h  are pic specific you wont find them around avr stuff

to get all the avr files download avrlib
Title: Re: Omni Robot Sourcecode
Post by: Admin on August 06, 2008, 07:00:25 PM
877reg.h is just for PIC's and doesn't contain any algorithms specific for omni-wheel robots.

I've attached the files.
Title: Re: Omni Robot Sourcecode
Post by: Alhazar on August 06, 2008, 08:38:14 PM
Ok, i was just curious as to what was all in it Thanks ^_^