Friday, December 5, 2008

What Does 25 Cm Look Like

BASIC Programming Guide

As a last contribution to the blog and its readers, we are proud to announce that we have created a guide as complete as possible to learn to program in BASIC. Was developed in the interim by the authors of this Blog (Matías Ezequiel Maravankin and Wajs). It has 57 pages divided and sub-divided into sections that divide it believed relevant. Each explanation includes an illustrative example. They are also all programs developed by us. All except the last, were tested and proved effective.
Without further ado, I leave the cover of the Guide:

I want to comment that this guide was made non-profit and that is entirely the product of our work. Not a translation, all material is original.
So this guide is completely free for anyone who needs or wishes to have it. The guide is not on the Internet and we lack a ftp server itself and because we want to keep track of this, ie know who are those who ask our guide.
is why anyone who wants it can send a mail to me (Ezekiel) to Matthias to mmaravankin@gmail.com ezewajs@gmail.com or phone to ask to be sent shortly. The weight of it is 381kb, so it can be safely sent by e-mail. The guide has a hierarchical menu and you can navigate Bookmarks for it more easily. Simply clicking the desired title in the menu to the guide automatically place the desired sheet.

hope it is helpful to anyone who requests it.
No more we said goodbye.

Matías Ezequiel Wajs

Monday, November 17, 2008

Comments Woman Carring Man

Day of Flight - 30/10/2008

We meet at school early to prepare the last details. Rescheduled some PIC 's charging them programs made the night before, hoping that some of them can make the flight.
After the trip about an hour and a half, we came to San Vicente where we met with two schools more and different members of the ACEMA .
The land belongs to William Barefoot, also a member of the ACEMA .
soon as we arrived we set up the tent would put all our instruments. Once unpacked
all brought the bus, witness some shots from his total success until destruction on the ground.
Later, along with Leandro Arcusin we set out to test the emergency programs made the night before.
At the beginning and without knowing why, the PIC 's too hot to connect on the plate and apply pressure . That is why we redid the auxiliary connections (cables and resistors were added at the last moment in a rudimentary way) with more care.
The connections consisted auxiliary cables and a resistance directly out of the shafts used for power (bronze long screws that pass through all the plates) and were to some port PIC to return in the same way the other axis.
After this touch, the auxiliary program HPWM 8 began to function properly.
The way we use to detect the operation, was used a satellite created by students from 4 to year electronic who came with us to the field. This antenna received a signal and a tone emitting the same frequency headphones. That way when varying the pressure , varied sound. The higher was the rocket should sharpest tone sounds of the antenna and the more bass, more serious.
Happy with what we were able to improvise, we went to lunch a good roast.
After lunch, we continue giving final touches to the plate. Our biggest challenge
, was to assemble some kind of sensor that allowed us to detect the launch. To do this, use two metal contacts , separated by a makeshift insulation cut. This cut through a wire, the rocket went out and tied to the base, so the rocket takeoff tear the insulation and the two plates enter into contact, detecting and takeoff. This task was not easy because we were constrained by the structure of the rocket and the absence of a strong thread to pull takeoff. Such was the uncertainty, we did not know if it would work until the time of takeoff. When the time
take-off of our rocket barely throw the absence of heads that fit into our rocket. After solving this problem, we take up the launch base, place it and retired to a safe distance.
The launch was a success and we hear the rise and fall of the rocket through the antenna named above. Happy
so accomplished, we returned to school, finishing the day not the best way (because we preferred to shoot the rocket program), but still happy. I can see some photos of this memorable event:

Preparing the "fuel" of rockets.

Armando carp Maravankin points us to the North.

Secrets MEETING ON bad education.

One of the takeoffs.

roast.

Leandro Thanks for everything you taught us.
With love and Wajs Mati.

Students who made the antenna ... and antenna.

Ezequiel Leandro and putting the finishing touches. Matias
monitors than any asteroid we ruin the evening.

All.


to get our share here in CanSat project, begun in March and carried out throughout the 2008 school year. We are grateful to our teachers Edgardo Baez, Leandro Mariano Arcusin and Foullier by knowledge and good humor transmitted to Nostra. Close this time that was certainly rewarding for us hope that this blog is useful for anyone who needs it or find it. Without more we take for closing this blog that contains all of our experiences, successes and failures.

Maravankin and Matias Ezequiel Wajs.

Tuesday, November 11, 2008

Is Northface Outlet For Real

Night Pre-Flight - 29/10/2008

We meet at the house of Ezekiel the night before the flight to see if we could do something useful before the flight and to give it a culmination of hard work this year. That is why we stayed until the wee hours preparing some "emergency program" to avoid the use of division and multiplication. The programs were much simpler than the Final Programme V3, but we expected that even fulfill their purpose. This is why it emerged that night 3 programs:

  • HPWM10
The program takes a measurement in 10 bits, the output from a PWM, where the frequency of is 1000 plus 2 times the measured data (as in the protocol), also reduced to 8 Bit's using a very crude operation (as had been right to divide the data by 4) and stored in the EEPROM.
  • HPWM8
The program takes a measurement of 8 bits, the output from a PWM, where the frequency of this is 1000 plus 4 times the measured data (similar to the protocol) and then stored in the EEPROM. Storage
The program takes measurements and stores 8 bits


programs here: Last Chance



* Note that to avoid multiply add several times the record.

Monday, November 10, 2008

Does Walmart Sell Rubber Ducks

thirty-second day (32 º) - 10/24/1908 Thirty-first Day

The 30/10 would be the rocket that would launch the final program that we have been preparing throughout the year (not literally preparing the program and develop it in the last month, but this program is the culmination of learning all the programming that we tested during the year). Edgardo
told us he was not very satisfied with working ranges with our board altimeter and preferred use of last year that had included a regular potentiometer allowing the output range. That is why we use the same method explained in the previous post to calibrate the altimeter old, we get a range down to the 5V (Limit Analog-Digital converters CIP) and started from a lower voltage than the Altimeter manufactured by us. We set out to record 5 PICs, 2 with auxiliary programs which merely transmit antenna the data that were measured (in 8 Bit's, to simplify the operation, since it is only an auxiliary program) already stored in EEPROM and other 3 with the main program contains the following functions, all integrated and funcionamieto quasi-simultaneous:
  • Recording in 10 Bit's (1024 possible values)
  • Detection and Warning Takeoff and Height Measurement Home
  • Averaged Data (He makes an average of 3 consecutive data, low error)
  • Data Processing (For program ground level becomes 0)
  • Data Processing for Streaming RF (To adapt to the Protocol)
  • Data Processing for Storage (Reduced to 8 Bit's)
  • Saved Data in the EEPROM (8-Bit's)
  • Apogee Search (constantly chequenado ballistic trajectory)
  • Subroutine Apogee (Simplified to work better in the fall)
  • 2 Programs in 1 ("Phase of Flight" and "Computer Connection")
  • Interactive Program Connection PC Data Recovery
This day closed the transmission protoclo was as follows:
  1. The data would be mounted on a PWM and would be proportional to the frequency of this.
  2. The Duty Cycle (Duty Cycle) discriminate if the rocket was in flight or on land.
  3. would Frequencies of 1000Hz to 3048Hz no more than
  4. The data (between 0 and 1024, actually less for the processing received at the PIC) would be multiplied by 2 and then would add 1000 and thus obtain the PWM frequency.
    Here the equation: F (d) = d * 2 + 1000

  5. A measured frequency is subtracted from 1000 and divided by 2 and get the data (between 0 and 1024, actually less for the processing received at the PIC).
    Here the equation: D (f) = (f - 1000) / 2

RESULT: Only frequencies are supported PAIRS in this protocol (due to the multiplication by 2), odd should be rounded as they are not possible.
programming code here: Final Program
V3

The "Final Program V3" (as we call it, since he had two previous versions that were modified) was too complex to test in the laboratory because there were many conditions and variables to pretend to measure the Breadboard and receiving antennas was too cumbersome, they needed the rocket with its infrastructure (the program was designed with this philosophy and therefore there is where it should be tested), and beyond that we did not have the rocket at that time, would have required that this be raised, which could not simulate. That is why we tried lots of specially tailored program to be tested in the laboratory regardless of the others.
Unfortunately we got the surprise of the emission of radio frequency data was not working at all well. Since we could not find the error in programming, even with the help and expertise of Edgardo Baez and Arcusin Leandro (2 faculty scholars in the field) made several consecutive changes of transmission antennas and reception antennas (the latter laboratory to test whether the data actually issued PIC) and yet we could not get things consistent, but more noise.
After a while Leandro Arcusin noted that the PWM was changing constantly and steadily, and referred us to a pause after modify it to not be constantly depressed by the fact that the current case. The correction you gave us was correct, but the program was not working. Importantly, we stayed until well after school was for us, in fact it was more than double the time we had that day at school. After much time had decided to assume that errors may operate with the data to implement the protocol, after testing, we realized that somehow external to us the compiler does not properly handled multiplication and division, making the records are loaded with values \u200b\u200bthat were not allowed in the protocol and that the antennas could not be issued by a disability. Thus ended our day with a very disappointing end, we had a useful program for loading into the Rocket could not do anything in our power to fix our program, we had scheduled assuming that the compiler would do exactly what we said. We retired to our homes because we had stayed up so late starting classes Institute of Technology that works in our school at night and we had to release the Classroom. We thank Edgardo Leandro and for having stayed with us and helping us.

Friday, November 7, 2008

Canon Mp145 Error 5010

(31 º) - 17/10/08

Once the altimeter , we set out to calibrate it.
To calibrate the circuit we had simulate pressure levels for which happen once the rocket in flight, that is why we use a bell to create empty and generate the possible values of pressure.
The original idea is based on the method found on page of William Barefoot . This is a completely sealed bottle, except for two holes through which pass hoses, which suck the air to simulate different levels of pressure. To suck, the water breaks through the hose and using a meter, determine the height reached by water. The system used is quite similar to that proposed by Barefoot, only instead of using a bottle and an altimeter under test, use a vacuum chamber and the altimeter done for us.
Based on the levels of water present, using a conversion table by William Barefoot where set a height for each level of water. This is the table of equivalences of William Barefoot:
The pressure sensor is responsible for assigning a value of tension to a certain value of atmospheric pressure. The circuit consisted of a resistance that were fed back to the amplifier reaches the 5v output, but when we practice we got not or 4v and after analyze the possible values \u200b\u200band test with a resistance that saturated the track, we reach an output of 4.70 v.

Monday, November 3, 2008

What Is Inside Vergina

Thirty Day (30 th) - 10/10/1908 Twenty-Day

The circuit we had some errors printed using Protel 99 SE's correct. We proceeded to make the whole process that allows us to have the final product of a printed circuit (copper plate used is made of copper on one side and a fiberglass )

1. Cleaning and sanding of the face plate on copper.
2. Steaming Toner printed circuit and on a special sheet on the copper plate.
3. Separate sheet of copper plate into a container of cold water.
-product: copper plate Toner tracks covering part of its surface.
4. Submerged plate tracks in a ferric chloride tank for 20 minutes.
5. Removed from the tank plate chloride.
6. Rinsing the plate.
Byproduct: Plate with dissolved copper, except in the parts under the toner.
7. Removed by sanding of the parts with toner.
Byproduct: Plate with copper traces.
8. Coated copper face ContacFlux .
9. Leaky pads and other necessary holes.
Byproduct: End plate empty.
10. Components assembled in their respective places.
11. Soldier of the components.
Final Product: Printed Circuit.

Dora The Explorer Invite Wording

(29 º) - 10/03/1908 Twenty-Day

Since we did not get a sensor and we needed to launch an urgent, desolder the sensor a plate of previous years. We replace the connectors
cut the sensor, new wires and place it on the breadboard, to see the whole system performance.
got amplify pressure variations measured by translating them into voltage variations that are more significant than the sensor output is a few millivolts (mV), so the PIC can be seen with less measurement error that being made, as the PIC measures from 0 to 5 Volt and a resolution of at most 10 bit's, ie 1024 steps as the smallest step is 5V/1024 that is approximately 4 mV. If we had not amplified sensor output measurement would be really very vague. Amplifying get a higher degree of certainty.

Friday, October 31, 2008

Pokemon Light Platinum Cheat

(28 º) - 09/26/1908 Twenty-seventh Day

When testing altimeters earlier, were not going well, that's why the days from the date we are dedicated to design your own.
First we designed a circuit that is a schematic drawing from scratch, I used 4 operational and for that reason, 2 integrated (each has 2 integrated operational). But when compared with last year's design, which once went well but not our disposal it because the oxide is responsible for ruining it, we noticed that the design had 2 operational, ie, a single integrated diagram being much smaller. Thus
recreate last year's circuit in a breadboard , as it was more compact ( important feature when putting it inside the rocket), and we wanted to try, but not our disposal a sensor pressure as that needed . Also
knew the circuit worked the results obtained last year, and although we could not test in the breadboard, printed circuit board to make in the future.

Where Can You Buy Island Oasis Drink Mix

(27 º) - 09/19/2008

We redesigned a bit Apogee 2.0 program and prepared to try using the method described above which is a system RC (Resistance-Capacitor ). The program was activate a LED , making flashing, when it detects capacitor discharge not detect the load, only the voltage drop.
We got the program to the PIC and test different scenarios initial system in breadboard. In absolutely all the PIC detected only capacitor discharge , complying with the provisions of the program. We

Test Drive Crash How Responsible

Day twenty-sixth (26 th) - 12/09/08

in Bariloche!

Armstrong Ultra 90 Diagram

Day Twenty-fifth (25 th) - 05/09/2008

After studying so hard for 6 years we deserved a little relaxation, overlooking the mountains and spending time with our friends.
is so we paused the project and we bid farewell to Buenos Aires, to go to San Carlos de Bariloche!


Make Homemade Roofies

twenty-fourth day (24 º) - 08/29/1908 Twenty-Third Day

Unable to solve the problem of transmitter made a new attempt, but again we encounter the same problem, namely that the recipient received only noise. The PIC
utilizing distorted signal transmitter, which is why We did a short with a cable from a PIC leg to another, solving and the alleged problem, but still try without issue. We did another test
programmer up a program more complex than before and it worked very well.

Lg Voyager Water Damage Sticker?

(23 º) - 22/08/2008

Professor Edgardo Baez transmitter brought us last year and we tried to see if still working. When connected to the computer to through the serial port with an oscilloscope to the receiver input signal to see if he could, we could only see noise as the data output never reached.
were trying to solve this problem without any achievement.
tested the program over the previous class, but we find the problem that the cable done before, ranging from programmer to board breadboard had a length greater than necessary and this caused a problem of signal attenuation.
After solving the problem, we tried a program passing basic the PIC , previously made to flash an LED , and everything worked to perfection .

Monday, October 6, 2008

Mexicanas Famosa Follano

Day Twenty (22 º) - 15/08/1908 Twenty-first Day

Coming back to school premises, after an absence of 15 days, continue with the project.
finished preparing the cables, ie crimp and solder the parallel port connector and it ended the cable from the computer programmer and plate matches the plate programmer breadboard where is the PIC programming.
finished soldering the last programmer board components and put the PIC . We

Tuesday, September 23, 2008

Least Expensive Swing Set

(21 º) - 08/08/2008

another. It is clear that the above photo was merely illustrative. It is winter here and there are no beaches to be even remotely resemble the one pictured here.

Watch Free Full Movies En Espanol

Day Twenty (20 º) - 08/01/2008

celebrate our twentieth day of work taking us a well deserved holiday. 08/15/2008 be back.

Fisher Stove Csa Grand Papa

Nineteenth Day (19 th) - 07/25/2008

started the class engaged in redesigning the program height class we created earlier. We proposed another approach to program because the other method was based on a rather more rude and prone to failure (recall that ever feature). We thank Professor Mariano Foullier by the idea.

The first program, called apogee 1.0, consisted of the following programming sequence:

  • It creates a single byte variable called Index and a 16 Byte array called Array Index is
  • initialized to 00 and is used to direct a
  • Array data is entered in an Array {}
  • Index Index Increase
  • other data is entered in Array
  • {Index} {Index array is compared with Array} {Index " 1} if greater Array Index-1} {start again, but continued
  • Index is increased again
  • a third data is entered in array} {Index
  • same comparison is performed if greater Array {Index -1} start again, but continued
  • Apogee Detected (Sub-routine Apogee)

is, the program took a sample, then another, and compared, if the first was greater than the second, rocket was descending, to prevent noise then activate the swing routine third sample was taken to verify definitively the decline of the rocket. This program was highly fallible and in fact never went as it should.

is why we schedule the program we call Apogee 2.0, the sequence of programming was:

  • It creates an array of 16 bytes and 1 byte variable that directs you are Array and Index.
  • It creates a variable used to count 1 Byte Cont call initialized to 0.
  • all elements are initialized to 0
  • the first data is entered in Array {0}
  • all data are rotated towards the end of Array (Array {0} Array becomes {1}, etc..) the last data is lost.
  • contiguous data are compared from the beginning of the array to the end, if the values \u200b\u200bare rising is because the rocket is falling, every time there is a decrease of adding value to the next Cont.
  • If at the end comparison of the entire Array Cont is 3 or more, you run the subroutine peak. If not, enter other data into Array {0} and it follows from that step.

This program was much more effective. I did was go entering data one by one in an empty array and compare it with others. Thus, whenever data is entered, it runs the full comparison of Array. Until there is 3 drops followed, do not jump to the sub-routine of Apogee. This program will operate properly and meet our needs.

Monday, September 22, 2008

Breast Soreness Pregnancy Vs. Pms

Eighteenth Day ( 18 °) - 07/18/2008

Met another year of impunity and are still guilty of the bombing of the AMIA.
attend the opening ceremony held in memory of the victims.

Friday, September 19, 2008

Howmany Mg Of Meclizine

Seventeenth Day (17 th) - 11/07/2008

started the day with a swing program that previously had scheduled over the Internet. In order to simulate the rise and subsequent decline of the rocket utitilizamos a potentiometer we regulate manually, first up their resistance and then making it down, so we wanted the program to confuse our actions with the rocket in flight. The program failed at all times operated before time or activity at any time. Our tutor, Edgardo, told us that the method we were using to simulate the height of the rocket was not appropriate for the shape of the input signal corresponded were generating very little with the actual shape of the signal, which is why We recommended a RC circuit (we recommend entering the link, an applet is very explanatory of the operation and signal shape), which is more in line with what the program should be interpreted. However, after this change, the program did not work.

RC Circuit:

Chart during the Cargo signal (switch closed) versus discharge (open switch):


On the other hand, finished soldering the circuit would allow us to program the PIC without using the ChipMax or out of the Breadboard (mentioned in the post above).
Finally we set out to test the circuit altimeter to see how this would work. In order to do so request a Bell Jar that allows us to reduce the air pressure inside it and thus simulate the altimeter height (remember that the altimeter is actually a pressure gauge circuit).

Bell Jar: None of the two sensors worked properly in the future we redesign.

Monday, September 1, 2008

Heart Palpitations And Uti

Sixteenth Day (16 th) - 04/07/2008

From this date Ezequiel Wajs retires for the first time until August 30 to training for XII Iberoamerican Physics Olympiad (OIF) to be held in Morelia, Mexico from September 27 to 3 October. The Argentina team training week are carried through the National University of Rio Cuarto (UNRC) in Rio Cuarto, Córdoba Province.
is why the project will be slowed due to lack other week one of the two members. Matias
gotten down to developing a board and its corresponding set of cables that will definitely replace the memory module programmer ChipMax because this usually does not work on the new computer lab and forces us to use a notebook that is uncomfortable to work in the classroom because of wiring required to function as any machine on the network. This board programmer communicates with the computer using the parallel port . The new board allows us to program the PIC without removing even the Breadboard making programming much faster. He spent the rest of the day in the development of the copper plate / glass fiber and then submit to treatment with ferric chloride which later give rise to printed circuit on which to mount the components of the platelet.
Despite being more than 800Km. the group was in contact via the Internet. Ezequiel borrowed a computer while Matias University used a Laboratory, the communication was made possible by an instant messaging client allowed a return of ideas and data in vivo. Ezequiel Wajs held in Rio Cuarto a program that will detect the peak rocket that is the highest point reached in flight. Assuming that gravity is the only force acting on the rocket after initial boost PROVIDED by the explosive fuel (and discarding the time changes will cause the loss of mass as the fuel burn), the flight of the rocket can be represented as a function of time of a parabola, whose apex is the highest point path. Here's an example of the parable aunitario representing the trajectory of the rocket: Notably what you see in the chart is the height function of time, displacement (theoretically) be done completely on the same straight line which is that vertical in which the rocket is launched and not a graph axis denotes displacement in X and Y.

Friday, August 29, 2008

Spiker And Got2b Glued?

Fifteenth Day (15 °) - 27/06/2008

We meet to discuss how to send the data were obtained on devices that were installed inside the receiver coehete the land, which in this case would be a computer.
data are needed to transmit the gas and the altimeter, in order to detect the height of the rocket and to expel the airtight box that would take an air sample at that point, and then to analyze it.

order to transmit data as faithfully as possible, was thinking of a code that consisted of sending two bytes, the first with the first part of the altitude data, preceded by a protocol that identified the beginning of the data 010 XXXXX, and the second part followed by another protocol bits, data identifying the end of XXXXX 101

By having the code to send, then design a system reliable enough, it started with the programming code that required this to be transmitted. Also
Rinemberg Martin spoke to some of the protocols we use, the frequency and code it was decided to use, so that he can apply in your project.

After finishing the program that used the code, use the Realterm because the Windows HyperTerminal is not programmed to decode binary signal.
is so after connecting to the pc board, we implemented our program and noticed it was a total success.

Friday, June 27, 2008

Letters Suspended From Work

Day Fourteenth (14 th) - 06/20/2008

We met with Martin Rinemberg (Student Information) who informed us that he who would take over the PC interface, so the work done in the previous class with Mariano Foullier was discarded. We were testing some prototype programs that Martin brought. He opted to use the language C # (or C Sharp) for programming the interface. The first programs did not work. Martin had to go back and forth from building up in order to test our programs so we devote a class to arm him cable DB-9 invested for the 2 computers can communicate and save having to go to the floor electronics to test their programs. In addition were the rest of the class as they would be discussing with him the data he was to receive, how to interpret and process. The 2 Block
approached Martin saying that he could not communicate the PC's in any way. That is why we open the cable and we realized that we had read the pins backwards. Fixed cable and its programs became operational.

Have To Pee Lots And Stomach Pains

Day Thirteen (13 °) - 13.06.1908 Twelfth Day

We met with Mariano Foullier and try to begin to develop what would be the graphical interface to receive data in a PC. Mariano We recommended using the IDE (Integrated Development Environment) called Microsoft Visual Basic 6.0. We already had prior knowledge of this programming language because we use in our first year of specialization and in the second basic cycle. However, completely unaware management serial port using this language. Mariano showed us how to configure the component that handles such port and made a simple program that allowed us to do what we did with the HyperTerminal so far, but obviously most likely to process the data (functionality that does not have HyperTerminal). We spent the rest of the class testing programs with the interface that we created and trying to process some data. Thing we accomplished successfully. We could display the midpoint voltage of the potentiometer, which had not previously been able to do because he had to multiply the value of byte by the value of Run (0.02 V) and demanded that we use Floating Point system is very complex and demands lots of memory. The calculation error that carry both the measurement of the ADC (CDA) of the PIC and the computer calculation left us with an error of ± 0.04 V or 2 steps, measurement is quite reliable.

Friday, June 20, 2008

Memorial On Wedding Program



In this section we discuss everything about programming the PIC and include the complete list of programs you have loaded (which could be found in the days when they were made). How well clarified
previously, we will schedule our PIC (by choice) in a programming language called BASIC .
programming language is a language that is used to control the behavior of a machine, in our case the PIC. consists of a set of symbols, instructions and rules of syntax and semantics that define its structure, operation, interpretation and meaning of its elements and expressions.

The syntax rules are those that tell us how it should be written a program in this nguaje him. For example:

In C all instructions, declarations and / or functions must end with a semicolon, and control structures and routines mark their start and end with brackets so a good C program could be well:

void main (void) {

char variable;
printf ("Hello world!");
getch ();}
semantics gives the notion of such statements should be written instructions and / or functions. For example:

variables in C are declared as follows: NAME data_type, "so a good variable declaration in C is:

char variable;
programming languages \u200b\u200bcan be classified according to their" level " , where a high level language is one that is closer to human notions of syntax and semantics and a lower level language is one that departs most of these notions. Therefore a lower level language is more difficult to interpret for a human (obviously the best interpretation for the machine). BASIC is a high-level language (the C language is given in the exemplifications also high level but not as much as BASIC). Programming languages \u200b\u200bare translated into machine code (1's and 0's) to then be actually performed by the machine, this sometimes is done through a program called "compiler program" . Ours is the PIC BASIC PRO (PBP). We'll explain the basics of the language applied to programming PIC's.

BASIC COMMENTS: can be made for the programmer or someone who read the program guide, absolutely no bearing on anything in the program, the compiler discards them when they have to translate the program. to make a comment you must specify the start and this is valid for the rest of the line. The onset may be marked (in BASIC) by a semicolon or an apostrophe. Example: INDEX = 0; Pongo index to 0.

VARIABLES: serve to store and manage data can have varying sizes, from one bit to a couple of bytes. Must be declared as follows: NAME SIZE VAR. Example: DOG VAR BYTE . We just created a variable to which the rest of the program as DOG call when we want to use and its size is 1 Byte (8 BIT's).

INPUT / OUTPUT: These are usually pin PIC ports or channels can be named according to their location and position. Example: portb.2 . Where what goes after the dot indicates the port B Bit used (the ports are generally 8 bits, so is 0 to 7). Also you can name them as variables. Example: VAR BUTTON portb.2 . In this way each time you say BUTTON compiler interprets it as the Bit 2 of port B.

CONTROL STRUCTURES: are those that allow us to interpret and compare data and act according to these interpretations. There are several very intuitive and therefore not dwell in each, which are used IF, WHILE and REPEAT-UNTIL and its structure is:

IF (CONDITION) THEN

DECLARATION STATEMENT A Z B

ELSE STATEMENT
1
DECLARATION DECLARATION DECLARATION N 2

ENDIF
Explanation: If it happens running condition A, B and Z. If not, run 1. 2 and N, then ended and the program continues normally. REPEAT


Declaration1
Declaration2
DECLARACIONx
UNTIL (CONDITION)

Explanation: Repeat statements 1, 2 and x until the condition indicated. This condition usually go giving in to the statements in the loop (a variable that increases to a certain value, etc..).

WHILE (CONDITION)
Declaration1
Declaration2
DECLARACIONx
WEND

Explanation: When the condition is executed statements 1, 2 and x, once it no longer meets the condition, exits the loop.
STATEMENTS: are those who work in the program by changing variables, statements and reports, ie the action commands that trigger a sequence of steps in the microcontroller. Example1: Example2 portb.1 HIGH: DOG = DOG +1.

This was the basic introduction that we hope will understand the programs that we will be doing. Below are all the programs made by the group:



this document on Scribd: All programs

Friday, June 6, 2008

How Toknit A Male Beanie

Programming (12 °) - 06/06/1908

continue with the intent to make a program that would handle the EEPROM. First of all we want to clarify that we try to learn the management of this memory because we planned the module mounted on the CAN-SAT not only send their data to land acquisition but also store a few to read once recovered the form ground (in case the RF link with breaking ground for a period of time or for the entire flight). The PIC has 256 EEPROM memory locations so the amount of data that can save quite safely bounded.

Now, continue writing with regard to the day's activity.
during the week and separately investigated in our homes (with HelpTopics of microcode) and discover our error. We were using the incorrect instructions or misinterpreting its operation. We managed to determine the performance of the 3 previous instructions:

EEPROM:
used to store data in compilation times. Tells the memory recorder setee the addresses indicated in the EEPROM with the given values. Done only once (when you program the PIC).

READ:
used to read data at times execution. That is, to read the data stored in the EEPROM and store them in variables that are in the main memory and are erased once you cut the power of the PIC.

WRITE:
Used to write data to runtimes. That is, to store data temporarily stored in variables that are in the main memory and erased once the power is cut PIC.

So we needed were instructions READ and WRITE EEPROM, not because we want to save data will be obtained while the PIC is active (In fact the PIC is the device responsible for collecting the data).

decided that the use of arrays was unnecessary and in fact could be replaced by only 2 variables (remembering that an array is an addressable set of variables and is therefore more memory space using only 2 variables). We made a program using regular variables (of a Byte size or 8 Bit 's) that could be compiled and passed to the PIC. The program went smoothly. Here is the schedule .

is the most complex program so far and consists of several stages to explain:

The PIC is connected to the PC using the cable that we put together and once turned on it sends the following text being read by HyperTerminal :

After pressing a key has 2 secs. Pressing
LEE, IF NO RECORD.
RESTART THE PIC WHEN YOU TURN ON THE LED BY 2 TIME.

This tells the user what to do:

Once the user presses a key on the keyboard (any), the PIC gives you 2 seconds to decide what to do. If you press the button on the Breadboard (connected to PIC) will read what is stored in the first 10 sectors of the EEPROM, if not pressed for 10 seconds to make acquisitions analog midpoint of a potentiometer and saves in the first 10 sectors of the EEPROM. All times are listed in Breadboard by an LED that turns on or off depending on the time and activity. After any activity must disconnect and reconnect power to the PIC, to be reset and thus demonstrate that the stored data were actually stored in the EEPROM (any other information is erased when power cut). When you restart the process begins again allowing acquiring data stored in the previous session or save new.
The program went well and represented the biggest breakthrough to date. We're ready to begin scheduling the final program, ie the one to go really CAN-SAT module.