Go to Post Don't be affraid of trying new things... Even if people say you are crazy, even if you get insulted, even if it involves a lot of time and money, try it. You can't know if it'll work or not if you didn't try it yet. - EDesbiens [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

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #13   Spotlight this post!  
Unread 09-02-2008, 20:03
Kevin Watson's Avatar
Kevin Watson Kevin Watson is offline
La Caņada High School
FRC #2429
Team Role: Mentor
 
Join Date: Jan 2002
Rookie Year: 2001
Location: La Caņada, California
Posts: 1,335
Kevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond repute
Re: printf() inside interrupt routine?

Quote:
Originally Posted by Nathan View Post
I thought that's what printf did?
As Adam pointed out, and assuming you're using my serial port driver, it's as simple as this:

Code:
 // first, find out how much data, if any, is present in 
 // serial port 1's received data queue?
 byte_count = Serial_Port_One_Byte_Count();
 
 // have we received any data?
 if(byte_count > 0)
 {
  // we have fresh data, so read each received byte one at a time
  for(j = 0; j < byte_count; j++)
  {
   // get the next data byte
   data = Read_Serial_Port_One();
 
   // send it out the other serial port
   Write_Serial_Port_Two(data);
 
  // work with camera data here
  }
}
-Kevin
__________________
Kevin Watson
Engineer at stealth-mode startup
http://kevin.org
 


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
Routine declaration syntax error (Or: Where's wlado?) Astronouth7303 Programming 15 24-03-2004 05:51
printf isn't printf-ing. Help! Meandmyself Programming 14 15-02-2004 16:27
Pre-Match/Post- Match Pit Routine Mark_lyons General Forum 14 31-03-2002 15:19
Master uP Initialization Routine Ulibrium Technical Discussion 5 24-01-2002 16:43


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

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