Sonsivri
 
*
Welcome, Guest. Please login or register.
Did you miss your activation email?
December 02, 2016, 08:48:32 20:48


Login with username, password and session length


Pages: [1]
Print
Author Topic: mikroC compiler + winavr  (Read 4728 times)
0 Members and 1 Guest are viewing this topic.
powermosfet
Newbie
*
Offline Offline

Posts: 11

Thank You
-Given: 6
-Receive: 9


« on: May 01, 2010, 12:26:14 12:26 »

hello,

I will like to know if its possible to use winavr libraries with mikroC compiler if yes than how do I include stuff.

for example #include <avr/io.h> or #include <util/delay.h>

thankyou.


Logged
sam_des
Active Member
***
Offline Offline

Posts: 221

Thank You
-Given: 47
-Receive: 111


« Reply #1 on: May 01, 2010, 07:32:48 19:32 »

Hi,
Quote
I will like to know if its possible to use winavr libraries with mikroC compiler if yes than how do I include stuff.

for example #include <avr/io.h> or #include <util/delay.h>

Most certainly NOT Embarrassed
mikroC & WinAVR have different formats for their binary(compiled but not linked) data. While WinAVR uses elf mikroC uses it's own proprietary format. Also as far as I know mikroC does NOT have seperate linker/librarian. It has only two executables - preprocessor & (compiler+linker+librarian).

So you can't use winavr's libs directly. You can have source code for winavr's libs & port them to mikroC, but remember these libs make full use of preprocessor & other ANSI & gcc specific exetensions, mikroC doesn't even claim to be ANSI compliant. And winavr's libs are mostly GPLed.

regards,
sam_des
Logged

Never be afraid to do something new. Remember Amateurs built the Ark, Professionals built the Titanic !
powermosfet
Newbie
*
Offline Offline

Posts: 11

Thank You
-Given: 6
-Receive: 9


« Reply #2 on: May 03, 2010, 10:29:08 22:29 »

it's kinda sucks using avr studio with its boring interface.

thank you for the input.
Logged
metal
Global Moderator
Hero Member
*****
Offline Offline

Posts: 2018

Thank You
-Given: 513
-Receive: 477


Top Topic Starter


« Reply #3 on: May 04, 2010, 12:10:50 00:10 »

I think you can use codeblocks, use ultraedit or even UEStudio. They all work excellent indeed. I use them to write code, program interface too. It's easy to use them, especially codeblocks.
Logged

nothing to say..
Thiru09
Cracking Team
Active Member
****
Offline Offline

Posts: 246

Thank You
-Given: 285
-Receive: 815



« Reply #4 on: May 04, 2010, 12:45:05 12:45 »

Quote
it's kinda sucks using avr studio with its boring interface.

thank you for the input.

If that is the only problem, try to use Eclipse with WinAVR.
I am sure that Eclipse interface is marvelous.

For more details, please visit the following websites.

Step by step configuration:

http://winavr.scienceprog.com/other-valuable-tools/using-eclipse-as-ide-for-winavr-compiler.html

The AVR Eclipse Plugin:

http://avr-eclipse.sourceforge.net/wiki/index.php/The_AVR_Eclipse_Plugin

And finally, Eclipse+CDT:

http://www.eclipse.org/cdt/

Regards,
Thiru

Logged
sam_des
Active Member
***
Offline Offline

Posts: 221

Thank You
-Given: 47
-Receive: 111


« Reply #5 on: May 04, 2010, 04:20:44 16:20 »

Ya, Eclipse is good. But I find that too heavy for my work. Besides running damn slow, it eats my hard-disk and I am not into Java app development and certainly not easy to setup.

I feel much at home using Code::Blocks. Nearly does everything I wish for, cross-dev, pc dev. Has all the features I care for in an IDE & that too with small footprint & good speed.

And When I feel really wacky, I use good old Vim  Grin

sam_des
Logged

Never be afraid to do something new. Remember Amateurs built the Ark, Professionals built the Titanic !
metal
Global Moderator
Hero Member
*****
Offline Offline

Posts: 2018

Thank You
-Given: 513
-Receive: 477


Top Topic Starter


« Reply #6 on: May 04, 2010, 08:46:08 20:46 »

This eclipse winavr project has not been updated for a longtime..
Logged

nothing to say..
powermosfet
Newbie
*
Offline Offline

Posts: 11

Thank You
-Given: 6
-Receive: 9


« Reply #7 on: May 04, 2010, 09:26:18 21:26 »

hi,

eclipse is a great application which I have been and using for a quite long time now. I have done many of my school projects using eclipse without any problems. I do recommend eclipse.


about ultraedit & UEStudio looks nice but how do i compile the code? I guess it should be outside of ultraedit and or UEStudio.


codeblocks + winavr  guide

Make sure to install WinAVR first.

Download and install Code::Blocks next

Create a new AVR GCC project

Go to Tools->Compiler and Debugger Settings
Change "Selected Compiler" to "GNU AVR GCC Compiler"
Alter the "Compiler's installation directory" to the WinAVR directory (should be on the C: drive root)

Go to Project -> Build Options
Under Compiler Flags->Categories->AVR CPU architecture specific Select your uC as a flag

Could save all of this as a user project template
« Last Edit: May 04, 2010, 10:40:50 22:40 by powermosfet » Logged
pickit2
Moderator
Hero Member
*****
Offline Offline

Posts: 3816

Thank You
-Given: 567
-Receive: 2049


There is no evidence that I muted SoNsIvRi


« Reply #8 on: May 04, 2010, 10:02:05 22:02 »

about ultraedit & UEStudio looks nice but how do i compile the code? I guess it should be outside of ultraedit and or UEStudio.
Most if not all Compilers allow you to use any Text editor. UltraEdit as most profile Templates too.
Logged

Note: If you have no posts other than, I want or reporting a dead link Then you can't complain If I remove your post So Stop Leeching
metal
Global Moderator
Hero Member
*****
Offline Offline

Posts: 2018

Thank You
-Given: 513
-Receive: 477


Top Topic Starter


« Reply #9 on: May 04, 2010, 11:19:01 23:19 »

Here you go, this is from UEStudio..
« Last Edit: May 04, 2010, 11:21:29 23:21 by metal » Logged

nothing to say..
powermosfet
Newbie
*
Offline Offline

Posts: 11

Thank You
-Given: 6
-Receive: 9


« Reply #10 on: May 05, 2010, 08:03:28 08:03 »

alright Im convinced. It absolutely deserves a try
Logged
Pages: [1]
Print
Jump to:  


DISCLAIMER
WE DONT HOST ANY ILLEGAL FILES ON THE SERVER
USE CONTACT US TO REPORT ILLEGAL FILES
ADMINISTRATORS CANNOT BE HELD RESPONSIBLE FOR USERS POSTS AND LINKS

... Copyright 2003-2999 Sonsivri.to ...
Powered by SMF 1.1.18 | SMF © 2006-2009, Simple Machines LLC | HarzeM Dilber MC