How to change initialise value?

LINIX Brushless, VEXTA Brushless, RC Servo, DC Geared, Linear, Stepper, Tamiya.....

How to change initialise value?

Postby BoyU » Tue Dec 28, 2010 5:38 pm

Hi,
I need help here. I'm using pic16f877a and use HIGH-TECH C PRO as compiler.

I've initialise an array bellow.
unsigned char stalled_char[6]="123456";
for keypad lock. After I key in correct password, I want to safe new password.
How to change/overwrite the value above.
BoyU
Freshie
 
Posts: 5
Joined: Wed Dec 08, 2010 9:10 pm

Re: How to change initialise value?

Postby shiyan » Tue Dec 28, 2010 10:02 pm

You need to assign new keys?

The nature of array, accessing it will require element by element.

stalled_char[0]= K1; // 1st Key
stalled_char[1]= K2; // 2nd Key
..
..
..
.. // until you replace all 6 key.
User avatar
shiyan
Amateur
 
Posts: 189
Joined: Wed Jun 09, 2010 10:59 am


Return to DC Motor

Who is online

Users browsing this forum: No registered users and 7 guests

cron