pgmfi.org

Hacking up Honda's ECU
It is currently Fri Mar 29, 2024 4:08 am

All times are UTC - 5 hours [ DST ]




Post new topic Reply to topic  [ 11 posts ] 
Author Message
PostPosted: Wed Jun 01, 2005 4:30 pm 
Offline
Senior Developer

Joined: Tue Jul 27, 2004 2:10 am
Posts: 421
Location: Eisenstadt/Austria/Europe
Hi,

I wanna learn Visual C++, better said eMbedded Visual C++.
I've good knowledge of Pascal & Delphi Programming.

Has anyone a good suggestion of a site or good book where i can learn it in a crash-course?


TIA

Doc


Top
 Profile  
Reply with quote  
 Post subject: tutorials listed
PostPosted: Sun Jun 05, 2005 2:10 pm 
http://www.cprogramming.com/tutorial.html

http://www.glenmccl.com/tutor.htm

http://www.cplusplus.com/doc/tutorial/

Heres a few tutorials and i would recommend getting a book of commands if you already have programming knowledge it should be easy to pick up as most languages are similar. Im not great at creating objects in C++ but as far as basic C++ im good .. just practice making simple loop programs and see the differences in code between the languages. Hope this helps.


Top
  
Reply with quote  
 Post subject:
PostPosted: Wed Aug 10, 2005 1:32 am 
I'd recommend taking a look at some of the O'Reilly & Associates books. I believe that Practical C++ Programming & C++ in a Nutshell might be useful just to give yourself a quick tutorial into C++. I do not have any experience with Delphi, but Pascal is similar in structure to C/C++, so it should not take a great deal to move to C/C++ and then add on to get to Visual/Embedded C++.


Top
  
Reply with quote  
 Post subject:
PostPosted: Wed Aug 10, 2005 5:07 am 
Offline

Joined: Tue Jul 27, 2004 2:45 am
Posts: 107
Visual Studio is a great development environment, but the MS compiler is severly broken. A perfectly legal construct like this

for (int i=0;i<10;i++){
}
for (int i=0;i<10;i++){
}


That statement yields some error 'like variable i used twice in the same scope'. (This bug is still present in the .NET compilers, I've reported this bug to MS over 8 years ago)

A couple of years ago there where lots of plugins that used another (gcc/intel) compiler instead of the msvc compiler. Another suggestion would be using the Eclipse CDT environment (http://www.eclipse.org/cdt/). But then again, I don't know what your motivations are for choosing MSVC. If you use it to learn C++, it's a bad choice, because the C++ dialect used by MSVC is severly bastardized.[/url]


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Oct 24, 2005 8:05 am 
http://support.microsoft.com/kb/167748/en-us


Top
  
Reply with quote  
 Post subject:
PostPosted: Mon Oct 24, 2005 11:09 am 
Offline

Joined: Tue Jul 27, 2004 2:45 am
Posts: 107
FastHatch wrote:


Funny :). I reported this bug back in (I think) 1997 and a fix was promised..

It's a shame such fixes are needed. And I wonder what 'fix' they have for C#, it has the same bug, and doesn't support #ifdef's..

Anyway, if you want to learn C++ (and not Micorsofts broken version), use GCC...


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Oct 24, 2005 11:50 am 
Offline

Joined: Sat Jul 31, 2004 3:19 am
Posts: 427
i know i'll get flamed over this, but i recomend you dont.

you should lean to use GCC and pick whatever dev system you want.

all this stuff comes as standard with most linux install's together with the manuals.

once you can use GCC you can compile your code for windows, linux, osx and anything else.

better that than limiting yourself to windows.

visual is buggy anyway.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Oct 24, 2005 4:30 pm 
AllGo wrote:
Anyway, if you want to learn C++ (and not Micorsofts broken version), use GCC...


GCC is not a good compiler to start learning C++. The way how the vtable of virtual methods is implemented is a mess. Line concatenation doesn't work with CR+LF etc. etc. Linking objects created with gcc and g++ also often doesn't work. GCC throws too many confusing errors.

Packing alignment also behaves odd, #pragma pack ( 1 ) has to be used in conjunction with __attribute__ ((packed)), otherwise GCC uses default alignment.

We're using GCC for our multimillion LOC (automotive / multimedia) projects and gcc has so many odds you have to be aware of.

Microsoft promised that the new 2005 Studio fully complies the C++ standard.

Btw. the Borland compiler has the same for-init-statement bug as MSVC.


Top
  
Reply with quote  
 Post subject:
PostPosted: Mon Oct 24, 2005 5:36 pm 
Offline

Joined: Tue Jul 27, 2004 3:03 am
Posts: 1235
Location: Salem, OR
FastHatch wrote:
Btw. the Borland compiler has the same for-init-statement bug as MSVC.



Ahah! More proof that M$ steals all of the code they use! :lol:


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Oct 26, 2005 10:09 am 
Offline

Joined: Sat Jul 31, 2004 3:19 am
Posts: 427
FastHatch wrote:
Microsoft promised that the new 2005 Studio fully complies the C++ standard.


:lol:

microsoft making a promise? that's about as trustable as bush/blair saying war is a final option or macdonalds making a healthy meal!

call me untrusting, but i'v seen gates speaking shit about upcoming products since the 80's and he still hasnt followed through.

my fav' quotes: "windows is dead, os2 is the future!" & "nobody will use blue-ray because the DRM is so anti-consumer" :D


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Nov 27, 2005 3:04 pm 
AllGo wrote:
Visual Studio is a great development environment, but the MS compiler is severly broken. A perfectly legal construct like this

for (int i=0;i<10;i++){
}
for (int i=0;i<10;i++){
}



As said this is perfectly valid with VS2005 now. Just tested it with my VS2005 Professional installation.

The downside is, many projects rely on this bug and now you have to fix it everywhere. And if you put an 'int' in front of all declarations it can't be compiled with any previous version. I suggest to put the declaration somewhere before the first for-loop.

Andre


Top
  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 11 posts ] 

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group