OCCRA
Go to Post Well, are comedy and sarcasm COTS items? - Karibou [more]
Home
Go Back   Chief Delphi > Technical > Programming > Java
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 05-18-2010, 08:03 AM
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
New Programming Manual

Hi Everyone!
I am creating a programming manual/tutorial/ how-to book for people getting started in Java.

I want to make sure that I am including all of the important points and references.
So far, I have
- link to FIRST's instructions on how to download NetBeans
-How to open and download Default code
-Set IP Address and reimage
-download your code
-Creating your own Drive code (This section needs work. I bring up all the premade functions, but am working on how to describe other possible drivetrains)
-Basic custom control (Joystick to motor. -- might end up including Joystick to servo)
-Set up your radio/wireless system
-inverting a motor
-Basic vocabulary (syntax, servo... Things that a rookie might not know)
-How to set up your own motors,sensors, and other objects. Along with Variables and constants

Is there anything more that people want to see? (I have more sections that I plan to add, but these are the ones I am working on or have finished)

Eventually, I plan to post the completed thing here and on our website (It's not on this computer.)
__________________
ALWAYS a mechanical problem!

Last edited by rhoads2234 : 05-18-2010 at 10:52 AM.
Reply With Quote
  #2   Spotlight this post!  
Unread 05-18-2010, 07:58 PM
DonRotolo's Avatar
DonRotolo DonRotolo is offline
Broke a hundred!
FRC #0832
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Atlanta GA
Posts: 7,371
DonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond repute
Re: New Programming Manual

Quote:
Originally Posted by rhoads2234 View Post
Eventually, I plan to post the completed thing here and on our website
Think about posting draft versions of each section as you go along; we'll critique it for you, no charge.

Let me start out by saying that I know almost nothing about programming an FRC robot. And even less about Java.

The section on hardware- driver station, wireless, IP, and such should also include a troubleshooting guide, what are common problems one might see and where can I start looking. Include info on what to do when the router (for example) is totally farkled. Also, links to detailed info about the item, such as voltage and other specs (owners manuals?)

Consider the real beginner who might have nothing but your guide. Spend 3 or 4 pages on a step by step going from nothing to installing some code (supplied) that will at least make one motor respond to a joystick. And a basic wiring diagram (or link to one) so the programmer has some basis in reality.

How to read a digital input (and a sample circuit), how to set a digital output, how to read an analog input (and a sample circuit - use a potentiometer). Knowing that, I can read any sensor on the planet.

Last but not least, a half page on good programming practice: Commenting code as you write it, compartmentalizing/modularizing code, etc.
__________________

*All comments are mine and do not represent my place of employment*
Reply With Quote
  #3   Spotlight this post!  
Unread 05-19-2010, 08:35 AM
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
Re: New Programming Manual

So here it is so far. It still need a lot of help with wording, and I am concerned that I don't have all the major points. Please comment on anything you think would be good to include, change or take out!

The last section is only half done, and I think if I rearranged the Sections, it would make more sense. (But I don't know what order would make the most sense. - Help please?)
Attached Files
File Type: doc ManualBasics.doc (1.47 MB, 196 views)
__________________
ALWAYS a mechanical problem!

Last edited by rhoads2234 : 05-19-2010 at 08:45 AM. Reason: Update information
Reply With Quote
  #4   Spotlight this post!  
Unread 05-19-2010, 09:46 AM
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
Re: New Programming Manual

Has anyone worked out Version Control on Netbeans? I know its built-in, but I didn't quite figure it out, instead I just made a new project....
__________________
ALWAYS a mechanical problem!
Reply With Quote
  #5   Spotlight this post!  
Unread 05-20-2010, 09:49 AM
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
Re: New Programming Manual

I've just begun adding section on how to read a sensor to control a motor (analog or digital and on the driverstation or off of it)
Sensors included are limit switches, potentiometers, general analog, analog sensor on DS, and buttons on the DS. Is there anything else I should include?

It includes code. I haven't worked with an accelerometer myself, so I don't know when or how you would use it. How it is normally used?
__________________
ALWAYS a mechanical problem!
Reply With Quote
  #6   Spotlight this post!  
Unread 05-21-2010, 06:52 AM
Jared Russell's Avatar
Jared Russell Jared Russell is offline
4933T15
FRC #0254 (The Cheesy Poofs), FRC #0341 (Miss Daisy)
Team Role: Engineer
 
Join Date: Nov 2002
Rookie Year: 2001
Location: San Francisco, CA
Posts: 3,549
Jared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond repute
Re: New Programming Manual

Quote:
Originally Posted by rhoads2234 View Post
I've just begun adding section on how to read a sensor to control a motor (analog or digital and on the driverstation or off of it)
Sensors included are limit switches, potentiometers, general analog, analog sensor on DS, and buttons on the DS. Is there anything else I should include?

It includes code. I haven't worked with an accelerometer myself, so I don't know when or how you would use it. How it is normally used?
There are three "common" uses for accelerometers that I know of:

1. Setting an "acceleration threshold" and getting alerted when the vehicle experiences a sudden acceleration greater than this. This is how they are used for deploying airbags, for example.

2. With a 3-axis accelerometer that is stationary, you can determine the direction of gravity. Accelerometers measure acceleration relative to a free fall, so on a stationary platform, you will always read a total acceleration of +1G upwards (the normal force of the ground pushing back on you). If the Z axis is the up-down axis, then when your accelerometer is flat on the ground you expect to read +1G on the Z accelerometer, and 0G on the X and Y accelerometers. But if you are pitched 45 degrees into the X axis, you would instead expect to read +sqrt(2) G in both the X and Z axes, and 0G in Y.

3. By integrating the output of an accelerometer, you obtain a speed estimate (since acceleration is the time derivative of velocity). If you integrate it again, you obtain position (since velocity is the time derivative of position). So accelerometers can be used (typically along with gyros, magnetometers, and/or compasses for angular measurements) as part of an IMU, or inertial measurement unit. However, these systems tend to drift over time - if your acceleration measurement is noisy at all, the noise will be compounded over time by your (double) integration.
Reply With Quote
  #7   Spotlight this post!  
Unread 05-21-2010, 09:13 AM
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
Re: New Programming Manual

It seems to me that an accelerometer wouldn't be a common sensor for a beginner programmer to use.
- That said, does anyone have an excerpt of code I could use?

And here is a more recent copy of the manual. (accelerometer section is blank. Working on a good way to explain it. I think I might use Jared's explanation)
Attached Files
File Type: doc ManualBasicsv2.doc (1.33 MB, 62 views)
__________________
ALWAYS a mechanical problem!
Reply With Quote
  #8   Spotlight this post!  
Unread 05-21-2010, 09:32 AM
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
Re: New Programming Manual

Sorry. I didn't realize that moving the document from word 2007 to 2003 compatable would make the page numbers be all funky. I've fixed it for the next version, but I am going to wait until I have a few more changes before post the new one.
__________________
ALWAYS a mechanical problem!
Reply With Quote
  #9   Spotlight this post!  
Unread 05-21-2010, 10:39 AM
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
Re: New Programming Manual

I realized I forgot to add encoders on the sensor list. They are now included!
__________________
ALWAYS a mechanical problem!
Reply With Quote
  #10   Spotlight this post!  
Unread 05-21-2010, 09:00 PM
Robototes2412's Avatar
Robototes2412 Robototes2412 is offline
1 * 4 != 14
FRC #2412 (Robototes)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2007
Location: Bellevue
Posts: 312
Robototes2412 is on a distinguished road
Re: New Programming Manual

I know this is a nerd turf war thing (http://xkcd.com/743), but can you please use a more open document format? It is about 1.5 times faster for Word to read OpenDocument Text than its own format (ROFL).

And I use OO.O, and disabled m$ compatibility.
Reply With Quote
  #11   Spotlight this post!  
Unread 05-24-2010, 08:30 AM
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
Re: New Programming Manual

Here's the newest version - I've started adding in pictures.

Note: I will move the Tabbing section. I just wrote it, so right now it is at the bottom. It will soon be higher up.

I'm still looking for accelerometer code - If you have it in C++, I can just do the small changes to make it into Java.

If you have anything you'd like to see added or clarified, please PLEASE tell me!
Attached Files
File Type: doc ManualBasicsv4.doc (1.82 MB, 83 views)
Reply With Quote
  #12   Spotlight this post!  
Unread 05-24-2010, 08:33 AM
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
Re: New Programming Manual

Quote:
Originally Posted by Robototes2412 View Post
I know this is a nerd turf war thing (http://xkcd.com/743), but can you please use a more open document format? It is about 1.5 times faster for Word to read OpenDocument Text than its own format (ROFL).

And I use OO.O, and disabled m$ compatibility.
How do you convert it from a Word doc to OpenDocument? I didn't see how.
I can easily convert it to a pdf if that would work for you. - Why would you disable ms compatablity? A lot of places send their stuff in MS office formats.
__________________
ALWAYS a mechanical problem!
Reply With Quote
  #13   Spotlight this post!  
Unread 05-24-2010, 08:44 AM
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
Re: New Programming Manual

I don't recommend printing it out yet, I thought that the page references would automatically update, but turns out that they don't, they still link to the right spots in the text, but the numbers themselves are wrong. That'll be difficult to fix, but it should be good (mostly) by the next version.
__________________
ALWAYS a mechanical problem!
Reply With Quote
  #14   Spotlight this post!  
Unread 05-24-2010, 01:20 PM
Robototes2412's Avatar
Robototes2412 Robototes2412 is offline
1 * 4 != 14
FRC #2412 (Robototes)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2007
Location: Bellevue
Posts: 312
Robototes2412 is on a distinguished road
Re: New Programming Manual

hit ctrl-shirt-s, choose odt
Reply With Quote
  #15   Spotlight this post!  
Unread 05-24-2010, 02:17 PM
Daniel_LaFleur's Avatar
Daniel_LaFleur Daniel_LaFleur is offline
Mad Scientist
AKA: Me
FRC #2040 (DERT)
Team Role: Engineer
 
Join Date: Apr 2005
Rookie Year: 2003
Location: Peoria, IL
Posts: 2,319
Daniel_LaFleur has a reputation beyond reputeDaniel_LaFleur has a reputation beyond reputeDaniel_LaFleur has a reputation beyond reputeDaniel_LaFleur has a reputation beyond reputeDaniel_LaFleur has a reputation beyond reputeDaniel_LaFleur has a reputation beyond reputeDaniel_LaFleur has a reputation beyond reputeDaniel_LaFleur has a reputation beyond reputeDaniel_LaFleur has a reputation beyond reputeDaniel_LaFleur has a reputation beyond reputeDaniel_LaFleur has a reputation beyond repute
Send a message via MSN to Daniel_LaFleur
Re: New Programming Manual

Quote:
Originally Posted by rhoads2234 View Post
How do you convert it from a Word doc to OpenDocument? I didn't see how.
I can easily convert it to a pdf if that would work for you. - Why would you disable ms compatablity? A lot of places send their stuff in MS office formats.
You seem to be using an older version of Word (hence the .Doc and not .Docx format). Word 2003 and prior doesnt convert to OpenDoc format. I'd suggest you not convert to openDoc anyways as the formatting can become Borked, and instead convert it to a .PDF (use CutePDF writer, it's free and works great ... to the PC it's just another printer) and post it in that format since most can get an acrobat reader free, if they don't alreadyt have it.
__________________
"We are not now that strength which in old days moved earth and heaven; that which we are, we are;
One equal temper of heroic hearts, Made weak by time and fate, but strong in will
To strive, to seek, to find, and not to yield. "
- Tennyson, Ulysses
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Changes in the New Revision of the Control System Manual mcf747 General Forum 2 12-07-2008 09:10 PM
Completely new to programming robots... Comatose Programming 4 09-19-2008 06:22 PM
The complete FIRST Programming manual project David55 Programming 3 07-02-2006 08:38 PM
Is there a manual for the new default code somwhere? Anton Programming 1 01-16-2005 03:34 PM
New programming resource rbayer Programming 0 12-02-2002 11:14 PM


All times are GMT -5. The time now is 11:02 AM.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi