To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.handyboardOpen lugnet.robotics.handyboard in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / Handy Board / 145
144  |  146
Subject: 
Max poke rate?
Newsgroups: 
lugnet.robotics.handyboard
Date: 
Mon, 11 Mar 1996 21:55:59 GMT
Original-From: 
Franklin Ranier Roller <roller@ix.netcom.comAVOIDSPAM>
Viewed: 
2407 times
  
Hi,
    I've been trying to write to PD2 using the following:

    int write_port(int port, int value, int mask)
    {
    poke(port,(value & mask)|(peek(port) & ~mask));
    }

    It works fine except that the fastest cycle that I can get out of
PD2 is about 242 Hz. I need 1.6 kHz. In between PD2_on and PD2_off
I put a msleep(1L) or a sleep(0.001) and the sleep function is faster,
but still not a 1 mS or 1kHz. I've even tried sleep(0.0006) with same
result. Any recommendations? Do I have to hog the processor or what.

Frank



Message has 2 Replies:
  Re: Max poke rate?
 
(...) I think the Interactive-C overhead will prevent such fast repetition. Simple statements take about a millisecond, with printf's taking 10 msec. You'll probably have to do it in assembler, and use an .icb file. Hope this helps... -mike * (...) (29 years ago, 11-Mar-96, to lugnet.robotics.handyboard)
  Re: Max poke rate?
 
(...) One option might be to try Kurt Konolige's IC compiler. I believe it only runs on a Unix machine, but you are able to compile programs for greater speed. Check out (URL) ___...___ Tom Cicatelli cica@tiac.net Melrose, Massachusetts ___...___ (29 years ago, 12-Mar-96, to lugnet.robotics.handyboard)

3 Messages in This Thread:


Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR