Pumpkin, Inc.

Pumpkin User Forums

Error in HT-PIC

For issues specific to Microchip's PICmicro® MCUs, including compilers (e.g. HI-TECH PICC & PICC-18, Microchip MPLAB®-C18) and IDEs (e.g. Microchip MPLAB®).

Error in HT-PIC

Postby Vijay S » Mon Dec 01, 2008 8:59 am

hello friends
i'm using salvo lite 3.2.3 and HT-PIC18 compiler 9.50.when i try to compile example coding i'm getting error
Error[924]:missing argument to "-I" option

what is the problem.. help please

------------------
Vijay S

Vijay S
Vijay S
 
Posts: 2
Joined: Mon Dec 01, 2008 12:00 am
Location: Coimbatore,TN,india

Re: Error in HT-PIC

Postby aek » Tue Dec 02, 2008 9:14 am

IIRC -I is a directive to the compiler to identify (system) include paths ... so, you need to look at what's being sent to the command line of the compiler, and then modify MPLAB's build settings to include some additional path. Normally that's C:SalvoInc and the directory that your project's salvocfg.h is located in.

------------------

-------
aek
aek
 
Posts: 1888
Joined: Sat Aug 26, 2000 11:00 pm

Re: Error in HT-PIC

Postby Vijay S » Thu Dec 11, 2008 11:48 am

how to make the Task run on periodic intervals..for ex if i need Task1 to be executed every 10ms,how to achieve this
Vijay S
Vijay S
 
Posts: 2
Joined: Mon Dec 01, 2008 12:00 am
Location: Coimbatore,TN,india

Re: Error in HT-PIC

Postby aek » Fri Dec 12, 2008 7:03 am

Use OS_Delay() or OS_DelayTS(). OS_DelayTS() gives timing that is jitter-free over the long term.

Assuming a system timer of 100Hz (i.e. OSTimer() is called every 10ms), then OS_Delay(1) will give a delay that ranges from 0 to 20ms (+/- 1 tick is the standard resolution of timing functions in the API).

So, for more accurate 10ms periodicity, you need to call OSTimer() at a higher rate. E.g. call it at 500Hz, and use OS_Delay(5) -- this gives you 10ms +/- 2ms, which is reasonably accurate. Note that calling OSDelay() at 500Hz suggests that you should be running your PIC at 20MHz or so for best performance.

code:
void my_periodic_task (void) {
while (1) {
OS_DelayTS(5, label);
.... //do something
}
}

results in do something happening every 5 system ticks.

------------------

-------
aek
aek
 
Posts: 1888
Joined: Sat Aug 26, 2000 11:00 pm


Return to PICmicro MCUs

Who is online

Users browsing this forum: No registered users and 2 guests

cron