looping problems using picbasicpro

Status
Not open for further replies.

pouchito

New Member
hi all,

please i need your help using picbasic pro

i want to add the number x=1 with the following numbers

for i=0 to i=100

and i want to display the result on an LCD

i must check if the result is greater than 1500, the loop must exit and the final number will be frozen on the LCD or disappeared.

What is happening is that the loop when it reaches 1500 it is restarting automatically, please can anyone help me by writing the corresponding code using picbasic pro


thanks in advance
 
You have an error on line 1931.

Seriously. Unless you post your code there is no way anyone can help you.
 
You r right, but the problem is that i forgot the code at home, and i am trying to benefit from the user experience maybe they faced similar problem.
 
pouchito said:
you are totally right.

it is 50 and not 1500 , i made a unacceptable mistake

hi pouchito,
Does your Basic have 'Do While' or 'Do Until' Loops?
If so, lookup some of these types of Looping examples.

If not,look at 'For X=...... Next', 'If X= ... then Exit For'

Regards
 
thanks a lot, i will try to work on it,
i think i m facing a problem cz in the other part of my project, i m reading t\from the serial ...i will try to post my code so you can correct me
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…