Username:     
Password:     
            Register  

Projects
Tutorial (Cubic) 1.1
 
A simple tutorial in 5 steps to show how to build an application based on CircleOS. The very first step shows how to create an empty skeleton within a few clicks. Then, the other steps guide you until reaching a true application (a bubble level).

Code size:2KB Author:Benoit
Source files included:yes Version:1.1
Use circleOS:yes (1.5) Creation date:2007-09-24 14:28:57
Hardware modification:no Modification date:2009-03-16 16:32:32
Based on the STM32 Primer:All
   
Downloads:4684 Views:10184
   
Vote:
Average ratings:2.99/5 (1118 rates)

Download:    Tutorial-Cubic-1.1.zip (321 KB)

Description:

This tutorial explains in a few steps how to build a CircleOS application, how to correclty return to the Circle_OS main menu and how to use some of the functions in the OS to get data from the sensors and draw on the LCD.

Step0

Building an empty application shell

Step1

Creating a limited application to draw a square to the LCD

Step2

Using information from the MEMs sensor to resize the square

Step3

Using optimised MEMs data and graphic routines

Step4

Developing Step3 into a ‘Bubble Level’ on 2 axis

See the included PDF document for detailed information.

Revision 1.1 is an update of the tutorial to make it work with CircleOS v1.5.

 ...



Project comments

Small errors left...                                                                                                             Please, log you to post a reply.
#1   2008-07-22 13:29:05
qwertzguy
New member

Offline

Hello Francis,

There are still some little mistakes left in your excellent tutorial.
As Dale had said:
Page 9, section 2.2, 3rd paragraph:  "definition/declations" should be "definitions/declarations"
Page 12, 4th code example:  "Int Current_Height - SQUARE_WIDTH;" should be "int Current_Height = SQUARE_WIDTH;" and should be placed on page 15 below the line: "s16 Current_Pos = ( SCREEN_HEIGHT - SQUARE_WIDTH ) / 2;".

New errors:
Page 15, code section: "DRAW_SetDefaultColor ();" and "DRAW_Clear();" should be removed.
Page 18, since there is only one extra carriage returns I suggest you put the comment on two lines like:
"LCD_SetScreenOrientation ( V12 ) ; //Fix the orientation to
  //match with the MEMS information."

And I suggest to add after each paragraph saying to copy the previous stepX.c that the person should also modify the name of the application in the source code, otherwise the old name is shown in the menu and the persons might think it is a bug.


A very good tutorial! Thank you.

 
#2   2008-07-28 09:08:35
Francis
Administrator

Offline

Thanks for your feedback. I am going to report these fixes.

Francis

 
#3   2008-07-28 10:22:42
Francis
Administrator

Offline

I fixed the language errors.
For the last one:
  <<Page 15, code section: "DRAW_SetDefaultColor ();" and "DRAW_Clear();" should be removed.>>

These lines are present in the step3.c file.  Do you mean that these lines are useless ? Does the code work 'better' without these lines ?

Thanks

Francis

 

problem found                                                                                                             Please, log you to post a reply.
#1   2008-05-21 19:31:39
janling
New member

Offline

when I loaded the code, STM32 says version 1.5 is needed while the code is of version 1.3.

 
#2   2008-05-22 08:52:52
Francis
Administrator

Offline

You need to update your CircleOS. Version 1.7 is available here:
    http://www.stm32circle.com/projects/project.php?id=10

 

no draw text at step 4 ?                                                                                                             Please, log you to post a reply.
#1   2008-05-01 16:42:35
klorydryk
New member

Offline

Hi !
Thank for this tutorial.
At the step 4, the code that you give does'nt draw the text that you speak and show on the screenshot. Why ?

 
#2   2008-05-02 09:07:59
Francis
Administrator

Offline

Which text? Do you mean that the calls to "DRAW_DisplayString" are not in the source of the tutorial document (but present in the source files of step4.c) ?

Anyway, step 4 is not so important... Just to reach something that makes sense, looking like a real application. The 3 first steps are simpler but more useful.

 

Typographical corrections to the application note (number 53)                                                                                                             Please, log you to post a reply.
#1   2007-10-20 16:02:26
dalewheat
Member

Offline

Working through the excellent tutorial (thanks, Francis!), I found some small, typographical errors that could be corrected in the next (if any) revision.  My suggestions are based on American English usage.

Page 1, above the Table of Contents:  "correclty" should be "correctly"
Page 3, 2nd bullet point:  "int the application" should be "in the application" (program C much? smile
Page 3, section 1.4:  "an USB port" should be "a USB port"
Page 4, 1st bullet point:  "how to use it's functions" should be "how to use its functions"
Page 8, section 2.2, 3rd paragraph:  "definition/declations" should be "definitions/declarations"
Page 8, section 2.2, 6th paragraph:  "Thats all" should be "That's all"
Page 8, section 2.2, 7th paragraph:  "tha application" should be "the application", "that sould" should be "that should"
Page 9, paragraph 2:  "Bild the application" should be "Build the application"
Page 11, paragraph 1:  "we use can use" should be "we can use"
Page 11, 4th code example:  "Int Current_Height - SQUARE_WIDTH;" should be "int Current_Height = SQUARE_WIDTH;"
Page 11, 4th code example:  "S16 Initial_MEMS_Y;" should be "s16 Initial_MEMS_Y;"
Page 12, paragraph 3:  "Build tha application" should be "Build the application"
Page 12, paragraph 4 seems to be a reworded repetiton of paragraph 3
Page 13, chapter heading:  "making the moves more fluent" should be "making the moves more fluid"
Page 13, paragraph 2:  "so it wouldbe" should be "so it would be"
Page 13, paragraph 2:  "parts of the rectangle that has changed" should be "parts of the rectangle that have changed"
Page 13, paragraph 3:  "the part of the LCD monitor that need to be" should be "the part of the LCD monitor that needs to be"
Page 15, paragraph 1:  "have lees to draw for each movememnt" should be "have less to draw for each movement"
Page 15, paragraph 2:  "This colcludes step3" should be "This concludes step3"
Page 15, paragraph 2:  "more practicle" should be "more practical"
Page 16, paragraph 1:  "As withthe previous" should be "As with the previous"
Page 16, paragraph 1:  "to the porject" should be "to the project"
Page 16, paragraph 2:  "two axis" should be "two axes"
Page 16, paragraph 2:  "show thedirection" should be "show the direction"
Page 16, paragraph 5:  "will be null" should be "will be zero" (not the same thing in English or in C)
Page 16, paragraph 8:  "two axis" should be "two axes"
Page 20, paragraph 1:  "into oyur application" should be "into your application"
Page 20, paragraph 1:  "whatch out for" should be "watch out for"
Page 20, paragraph 1:  "inserted ot show" should be "inserted to show"
Page 20, paragraph 2:  "need ot build" should be "need to build"
Page 20, paragraph 2:  "and the Run" should be "and then Run"

These are all just simple typos.  The content of the tutorial is excellent and I appreciate the detail that was put into this project.

Thanks,

Dale Wheat

 
#2   2007-10-20 19:29:16
Francis
Administrator

Offline

Thanks Dale!
I will fix these errors as soon as possible.

 
#3   2007-10-22 11:59:04
Francis
Administrator

Offline

The errors have been fixed ... Thanks again!

 


To add comments, please register you.



replica handbags Wholesale China Replica Purses Louis Vuitton Handbags Burberry handbags louis vuitton replica handbags Replica LOUIS VUITTON Gucci Handbags Prada Handbags Burberry Handbag Hermes Handbags Hermes Belts Gucci Belts Louis Vuitton Belts Louis Vuitton Wallets Hermes Wallets Gucci Wallets Burberry ScarfLouis Vuitton ScarfHermes Scarf Louis Vuitton Bracelets Louis Vuitton handbags Gucci handbags Prada handbags Prada Wallets Louis Vuitton Wallets Gucci Wallets Prada Wallets Wholesale Jewelry Replica handbags replica watches Louis Vuitton Bikini Burberry BikiniMiu Miu Handbags Hermes Bracelets