LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices



Reply
 
Search this Thread
Old 07-27-2010, 11:54 AM   #1
computer_freak_8
Member
 
Registered: Jul 2008
Location: Iowa
Distribution: Ubuntu 12.04 LTS 64-bit (Primary)
Posts: 80

Rep: Reputation: 15
Need a push in the right direction.


I can't seem to figure it out with Google, so it's time to post it in forums. I don't know what the best route to take is, and I don't know how to word it appropriately for a Google search, even if it would know. Here is an overview of where I'm at, and where I'd like to be; any help would be appreciated.



I know a little bit of Perl, a decent amount of HTML and CSS. I am very bad at JavaScript and know nothing in PHP. I can usually put Bash scripts together quickly. I can usually understand things if there is a sufficient analogy, or if there are enough examples given. I don't know much of the proper terminology (classes, variables, array, list, literal, lexical, et cetera) for the things in programming.

So far, I seem to be best at autonomous scripts, or scripts with some user interaction. My biggest struggles seem to happen when I need things to "talk" to each other (inter-process communication??). Usually, I can kludge together enough code to get the software communicating, but I still have lots of trouble with hardware/software interfacing.

I don't know the best order to go about these things, mostly because I'm sure some of them "build upon" knowledge learned in others, but not necessarily vice-versa.

I'd like to be able to:
  • Create simple GUIs (a window with a few buttons, each with a picture or text as a label).
  • Code in C++.
  • Have software and hardware stay "in sync" with each other (eventually to create a music and light synchronized display).
  • Be able to use AJAX at least somewhat proficiently (probably just a simple read settings from/write settings to an XML file or something).
  • Use Perl for CGI scripts.
  • Understand enough about hardware/software interaction to be able to use my Arduino Duemilanove as a "generic" USB-HID (essentially be able to use the digital I/O pins as a somewhat "permanent" attachment to my system, without having to worry about whether it showed up at /dev/ttyUSB0, /dev/ttyUSB, et cetera; I could "assign" pins to send/recieve certain "signals" that my computer could decide what to do with, without having to re-flash the firmware on the Arduino).
Eventually, but probably not until I've accomplished the stuff above:
  • Be able to run a Debian package repository on my server (for my own personal use; I just want it to help simplify maintenance amongst my computers).
  • Be able to understand the *why* of LinuxFromScratch (not just "what to do", but "why to do it, and how it affects the overall, end-result system").
  • Understand Assembly language.

Any ideas on what to do next/where to look?
 
Old 07-27-2010, 12:38 PM   #2
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 729Reputation: 729Reputation: 729Reputation: 729Reputation: 729Reputation: 729Reputation: 729
My first reaction is: "One step at a time."

Start with what you said about HTML, CSS, and JavaScript: I am in the same boat---I can put together a simple site in basic HTML+CSS, and I have read the book on Javascript. If I ever need to do something in a website using JavaScript, I'll go back and figure out how to do it.

Once you understand the basic concepts of programming, it may be best to figure out specific things as you need them. If you're going for a degree in CS, that's a different story.
 
1 members found this post helpful.
Old 07-27-2010, 02:05 PM   #3
orgcandman
Member
 
Registered: May 2002
Location: dracut MA
Distribution: Ubuntu; PNE-LE; LFS (no book)
Posts: 594

Rep: Reputation: 102Reputation: 102
My gut reaction would be to start from the thing you think will be the hardest, and immerse yourself in it. If you think learning assembly would be hardest then give yourself a bunch of incremental assignments (for instance, get 'hello world' working; move on to Fibonacci; write some linked list processing) in assembly. One of the more easy to understand books on the subject might be Structured Computer Organization by Andrew S. Tanenbaum.

The reason I say to do it this way is you'll get the fundamentals down first. Everything else flows from understanding the _how_ and _why_ of the computer in front of you.
 
1 members found this post helpful.
Old 07-27-2010, 02:29 PM   #4
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 115Reputation: 115
A shotgun approach won't work. Well...ultimately it will, but you'll spend many years before you think you know anything.

As the others have said, you need to focus on one aspect of it, drill into that, then expand from the base this gives you. You'll still be years at it, but you won't feel nearly as lost along the way.

From the list you gave I would say you should start by mastering C/C++. I think this would give you the maximum leverage for what you want to do.

Find yourself a project that you can do with either C or C++, then make it work. You'll learn a lot.
 
1 members found this post helpful.
Old 07-27-2010, 03:27 PM   #5
zirias
Member
 
Registered: Jun 2010
Posts: 361

Rep: Reputation: 59
In fact, these are a LOT of different directions.

Quote:
Originally Posted by computer_freak_8 View Post
[*]Create simple GUIs (a window with a few buttons, each with a picture or text as a label).
There are MANY options. I like very well using Windows.Forms with C# in Visual Studio, but you'd need a Windows host for that. The final result will run on linux using mono if you care not to use the newest (.NET 3.5 and newer) features.

But as you probably want to create native linux code, you should take a look at QT. Although this requires learning C++ first, which leads to:

Code:
[*]Code in C++.
C++ is a very powerful and very complex language. Unfortunately there are a lot of people using it, but not understanding it, which leads to poor code quality. I know there are people who will disagree with me, but I'd suggest: learn ISO C first. When you move to C++ later, take your time to truly uinderstand the features (including the esoteric ones not present in other OOP langauges).

Quote:
[*]Have software and hardware stay "in sync" with each other (eventually to create a music and light synchronized display).
Maybe take a look at SDL? The libs are usable from ISO C as well as from C++ and abstract direct hardware access in a reasonably portable way.

Quote:
[*]Be able to use AJAX at least somewhat proficiently (probably just a simple read settings from/write settings to an XML file or something).
I started some fiddling with AJAX from scratch (writing all the JS code). It finally worked and it was a beast just for one AJAX-enabled mail form. Didn't follow that path any further.

So, my tip would be: Use an existing framework. jQuery seems to be quite popular.

Quote:
[*]Use Perl for CGI scripts.
Do it! perl is fun Maybe you also want to take a look at mod_perl, this enables you to intercept the request processing inside apache at different stages using perl (much more powerful than just CGI)

Quote:
[*]Understand enough about hardware/software interaction to be able to use my Arduino Duemilanove as a "generic" USB-HID (essentially be able to use the digital I/O pins as a somewhat "permanent" attachment to my system, without having to worry about whether it showed up at /dev/ttyUSB0, /dev/ttyUSB, et cetera; I could "assign" pins to send/recieve certain "signals" that my computer could decide what to do with, without having to re-flash the firmware on the Arduino).
Uhm ... errr ... well ....
Probably kernel hacking, see threads about getting started with this

Quote:
[*]Be able to run a Debian package repository on my server (for my own personal use; I just want it to help simplify maintenance amongst my computers).
This is much easier than you might think. You can setup a simple repo (one architecture, no /pool) using dpkg-scanpackages -- for a full featured repo, look at the reprepro tool.

Quote:
[*]Be able to understand the *why* of LinuxFromScratch (not just "what to do", but "why to do it, and how it affects the overall, end-result system").
Well, there ARE explanations in the book... Maybe you could ask what you don't understand here in specific threads.

Quote:
[*]Understand Assembly language.
Uhm. I stopped at 6510 assembler (C64), but THIS is still fun. You probably won't need it nowadays, unless you want to code some drivers or platform-dependent parts of an operating system
 
1 members found this post helpful.
Old 07-27-2010, 03:54 PM   #6
computer_freak_8
Member
 
Registered: Jul 2008
Location: Iowa
Distribution: Ubuntu 12.04 LTS 64-bit (Primary)
Posts: 80

Original Poster
Rep: Reputation: 15
Sweet! Thanks, folks. I figured learning Assembly and working my way up would provide the most "thorough" experience, but I didn't think that would be the most practical. I don't mind so much about cross-platform compatibility; I plan to use some form of Linux as my primary operating system until I'm forced to do otherwise... But that's where the AJAX would come in (web interfaces for the non-Linux users).

I think I'll start with C++, at least for now, and see how things go from there. I'm still quite unfamiliar with the concepts of headers, libraries, classes, objects, et cetera, but I think I can find what I need now that I've got a sort of starting point.

For now, I think I just have one more question: Would I be better off using Ubuntu, Debian, or Slackware as a "main" development workstation OS? (I'm thinking in terms of compatibility and ease-of-use regarding libraries/IDEs/SDKs/et cetera...)

Right now, I'm using Kubuntu, simply because that's what I currently have installed on one of my larger partitions.
 
Old 07-27-2010, 04:14 PM   #7
zirias
Member
 
Registered: Jun 2010
Posts: 361

Rep: Reputation: 59
Quote:
Originally Posted by computer_freak_8 View Post
I think I'll start with C++, at least for now, and see how things go from there. I'm still quite unfamiliar with the concepts of headers, libraries, classes, objects, et cetera, but I think I can find what I need now that I've got a sort of starting point.
I'd still suggest you start with plain ISO C. You'll learn the concept of headers, includes, linking, symbols etc that way. When you move to C++ later, you can learn the concepts used by THAT language for implementing OOP "on top of" C.

Quote:
For now, I think I just have one more question: Would I be better off using Ubuntu, Debian, or Slackware as a "main" development workstation OS? (I'm thinking in terms of compatibility and ease-of-use regarding libraries/IDEs/SDKs/et cetera...)
I'm pretty sure this doesn't matter at all. Use whatever distribution you like best, those mentioned by you all contain anything needed for software development.
 
Old 07-27-2010, 05:52 PM   #8
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 115Reputation: 115
If kubuntu suits you, just use it.
 
Old 07-27-2010, 08:01 PM   #9
tonyfreeman
Member
 
Registered: Sep 2003
Location: Fort worth, TX
Distribution: Debian testing 64bit at home, EL5 32/64bit at work.
Posts: 187

Rep: Reputation: 30
Quote:
Originally Posted by orgcandman View Post
My gut reaction would be to start from the thing you think will be the hardest, and immerse yourself in it.
I agree with this quote. At one point in my life I wanted to learn to program in C and also to make a game. I did this task by immersing myself in libSDL for a few months and poped out the other end with a playable game. The book that helped me through the entire process of programming (not just game programming but Makefiles, etc) is Programming Linux Games. With this background I was then able to create a program for work using glib/gtk/glade. Currently I'm trying to learn python ... I'm using pyGTK and glade. Good luck!
 
Old 07-31-2010, 01:10 PM   #10
TimothyEBaldwin
Member
 
Registered: Mar 2009
Posts: 249

Rep: Reputation: 27
Quote:
Originally Posted by zirias View Post
I'd still suggest you start with plain ISO C. You'll learn the concept of headers, includes, linking, symbols etc that way. When you move to C++ later, you can learn the concepts used by THAT language for implementing OOP "on top of" C.
I disagree, C forces the beginner to learn complex low level ideas (eg. explicit memory management) early, notably it lacks a string type. To quote Bjarne Stroustrup:
Quote:
The common subset of C and C++ is easier to learn than C. There will be less type errors to catch manually (the C++ type system is stricter and more expressive), fewer tricks to learn (C++ allows you to express more things without circumlocution), and better libraries available. The best initial subset of C++ to learn is not "all of C".
For more detail see: http://www.research.att.com/~bs/new_learning.pdf
 
1 members found this post helpful.
Old 07-31-2010, 01:14 PM   #11
zirias
Member
 
Registered: Jun 2010
Posts: 361

Rep: Reputation: 59
Stroustrup is just awfully wrong there. You can't write good C++ code without exactly knowing what happens in terms of memory management, you are forced to understand the new and delete operators, the differences between data/bss segments, heap and stack, otherwise you will fail. C teaches you this without added complexity.

If you want to learn something simpler, without having to care about these issues, better start with java or C#.NET. C++ is NOT suitable for this.
 
1 members found this post helpful.
Old 08-01-2010, 07:01 AM   #12
bigearsbilly
Senior Member
 
Registered: Mar 2004
Location: england
Distribution: FreeBSD, Debian, Mint, Puppy
Posts: 3,314

Rep: Reputation: 175Reputation: 175
C#.NET ???????????

then the OP would have to work with a crap OS.
this is a linux forum.

Learn C and C++, a scripting language (perl?), and shell scripting.

learn to use the vi editor. (vim)
learn sed, grep, sort, uniq, cat, fmt, join, paste,
make, tar, cpio, find, fold, wc, xargs etc. (unix utilites)
 
1 members found this post helpful.
Old 08-01-2010, 07:06 AM   #13
Sergei Steshenko
Senior Member
 
Registered: May 2005
Posts: 4,481

Rep: Reputation: 453Reputation: 453Reputation: 453Reputation: 453Reputation: 453
Quote:
Originally Posted by bigearsbilly View Post
C#.NET ???????????

then the OP would have to work with a crap OS.
this is a linux forum.
...
In "Programming" one can ask questions regardless of OS - explicitly allowed by the rules. C# is not a bad language.
 
Old 08-01-2010, 07:15 AM   #14
bigearsbilly
Senior Member
 
Registered: Mar 2004
Location: england
Distribution: FreeBSD, Debian, Mint, Puppy
Posts: 3,314

Rep: Reputation: 175Reputation: 175
Quote:
Originally Posted by Sergei Steshenko View Post
C# is not a bad language.
maybe, never tried it, but the OP would still need a crap OS.
unless there's a linux or open source version?
 
Old 08-01-2010, 07:22 AM   #15
Sergei Steshenko
Senior Member
 
Registered: May 2005
Posts: 4,481

Rep: Reputation: 453Reputation: 453Reputation: 453Reputation: 453Reputation: 453
Quote:
Originally Posted by bigearsbilly View Post
maybe, never tried it, but the OP would still need a crap OS.
unless there's a linux or open source version?
http://www.mono-project.com/Main_Page
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Need some direction twistedpair Linux - Server 2 06-20-2010 03:36 PM
A little direction please heideL Programming 5 11-17-2008 04:03 AM
Need Direction Billn Linux - Newbie 1 09-11-2007 10:50 AM
X windows re-direction zugvogel Linux - General 1 11-24-2005 03:56 PM
pinging in one direction but not the other dehuszar Linux - Networking 5 01-20-2005 02:05 PM


All times are GMT -5. The time now is 06:37 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration