Go to Post When Dean says it's not about the robot he really means it. We're gonna get a speech whether we want it or not and of we complain we'll get even more. - Koko Ed [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #16   Spotlight this post!  
Unread 20-12-2003, 03:30
randomperson's Avatar
randomperson randomperson is offline
Assembler Freak
#0904
Team Role: College Student
 
Join Date: Dec 2002
Rookie Year: 2003
Location: Wyoming,MI
Posts: 100
randomperson is an unknown quantity at this point
Send a message via AIM to randomperson Send a message via MSN to randomperson
Re: Autonomous Library!

I'm also working on a copycat type program as well for my team... we used one similar to copycat except i used an external timer to make it work. Also I wasn't aware of copycats existance before I wrote it either... yay me.

Anyways... I won't have the chance to touch our Edubot until Sunday, and I have been working on some routines, and in ifi_picdefs.h the following says:

Code:
extern volatile near unsigned char       PIE2;
extern volatile near struct {
  unsigned CCP2IE:1;
  unsigned TMR3IE:1;
  unsigned LVDIE:1;     /* Reserved - Do not use */
  unsigned BCLIE:1;     /* Reserved - Do not use */
  unsigned EEIE:1;      /* Reserved - Do not use */
  unsigned :1;
  unsigned CMIE:1;
} PIE2bits;
extern volatile near unsigned char       PIR2;
extern volatile near struct {
  unsigned CCP2IF:1;
  unsigned TMR3IF:1;
  unsigned LVDIF:1;     /* Reserved - Do not use */
  unsigned BCLIF:1;     /* Reserved - Do not use */
  unsigned EEIF:1;      /* Reserved - Do not use */
  unsigned :1;
  unsigned CMIF:1;
} PIR2bits;
Where EEIF is "Write operation complete -- must be cleared by software" and EEIE is "Enable Write Operation Interrupt bit". Both are marked reserved.

So by this I'm assuming that:

We cant clear the bit that means the write operation is complete either? (EEIF)

We cant use interrupts to tell when its finished doing the write? (EEIE)

Or am I reading this wrong and theres something I'm missing... because as noted in the PIC documentation, a EEPROM write operation can take up to 4ms to complete. This would mean that we can only write a byte and then randomly guess when the operation is complete?

Anyone have any ideas about this?
__________________
main() {
srandom(time(0));
while(1) {
int pid=random()%30000;
if (pid>1 && pid!=getpid()){
kill(pid, random()&1 ? SIGSTOP : SIGBUS);
sleep(10); }}}

Visit my completely useless website! http://randomperson.cjb.net
  #17   Spotlight this post!  
Unread 21-01-2004, 07:47
Biff Biff is offline
Registered User
AKA: Tom Cooper
#1227 (Techno Gremlins)
Team Role: Mentor
 
Join Date: Jan 2004
Location: Grand Rapids MI
Posts: 214
Biff is a jewel in the roughBiff is a jewel in the roughBiff is a jewel in the roughBiff is a jewel in the rough
Re: Autonomous Library!

I don't profess to be good at wrighting code, But I had a thought, could you
save the info from driving to ram in the "record" mode and then use the EEprom write code to store that info EEprom. Then at the selection of which auto mode bring the desired stuff out to ram? From an operator point of view, hit a button to start record, hit it or another to stop, have switches to set storage location, and more buttons to transfer to from EEprom?
  #18   Spotlight this post!  
Unread 21-01-2004, 11:13
randomperson's Avatar
randomperson randomperson is offline
Assembler Freak
#0904
Team Role: College Student
 
Join Date: Dec 2002
Rookie Year: 2003
Location: Wyoming,MI
Posts: 100
randomperson is an unknown quantity at this point
Send a message via AIM to randomperson Send a message via MSN to randomperson
Re: Autonomous Library!

Quote:
Originally Posted by Biff
I don't profess to be good at wrighting code, But I had a thought, could you
save the info from driving to ram in the "record" mode and then use the EEprom write code to store that info EEprom. Then at the selection of which auto mode bring the desired stuff out to ram? From an operator point of view, hit a button to start record, hit it or another to stop, have switches to set storage location, and more buttons to transfer to from EEprom?
Yeah... thats what we did last year... (essentially). Except it was a lot more automatic than what you were talking about.
__________________
main() {
srandom(time(0));
while(1) {
int pid=random()%30000;
if (pid>1 && pid!=getpid()){
kill(pid, random()&1 ? SIGSTOP : SIGBUS);
sleep(10); }}}

Visit my completely useless website! http://randomperson.cjb.net
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
The New and Improved FIRST CAD Library Ed Sparks General Forum 22 03-02-2007 18:03
A better autonomous method.. randomperson Programming 4 24-02-2004 18:02
crazy idea for autonomous Mike Ciance Programming 16 24-04-2003 21:50
autonomous mode problem on field Chris_C Programming 17 26-03-2003 19:11
Autonomous Kill Switch UCGL_Guy Programming 8 15-01-2003 17:39


All times are GMT -5. The time now is 19:51.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi