what's a callback? - Page 3

Do you have a question? Post it now! No Registration Necessary

Translate This Thread From English to

Threaded View
Re: what's a callback?
"I have a theory that all Scottish food is based on a dare"
(Mike Meyers)

I've tried haggis and it doesn't taste as disgusting as the ingredients
suggest.
The sheep's stomach is as thin and inoffensive as a sausage skin, and does
the same job of holding it all together. Sausage skins were traditionally
pigs intestines, but few people think sausages are disgusting.

As for the rest, only lamb's liver sounds bad but even that is okay if
cooked well (e.g. as a small part of a grilled lamb chop)

IMHO it just looks like a poor but canny Scots lass faced with a Spartan
pantry had a good go at stretching a small cheap cut of offal into
flavouring the largest portion of sausage-substitute.

I found it a bit dry. Needs a good gravy, or dampening with a splash of
whisky (oh yes, it's not just for cornflakes).


Quoted text here. Click to load it

That is made of cow stomach, and is about 7 mm thick.
I hear it can be edible if cooked properly and even made to look okay (fried
in breadcrumbs like plaice).

But as you may know, we English are famous for boiling food to leach out the
flavour and vitamins into the water, then throwing the water away and eating
what is left.

Quoted text here. Click to load it

That counts as child abuse IMHO.

Along with school dinners. The people responsible should have their livers
boiled for hours until grey and rubbery, then made to eat them. Dr. Lecter,
we have a job for you!

Quoted text here. Click to load it

My mate has to go to Taiwan. He hates the endless kimchi.
I advised him not to ask for hot dog.


Quoted text here. Click to load it

Sea cucumber is much the same as squid.

The guy who first looked at a squid/octopus/oyster and thought "I'll try
eating that". I bet he was bloody hungry.

And what is the deal with oysters?
It's a fish built like a nut...




Re: what's a callback?

Quoted text here. Click to load it

Actually, I've heard it compared to something else altogether.



Re: what's a callback?

Quoted text here. Click to load it


I would think all the beef fat (suet) would keep it moist.

Quoted text here. Click to load it

Menudo, a traditional Mexican tripe soup and miraculous hangover cure.
Quoted text here. Click to load it


I don't think they are anything like squid.  Squid are like tubes
with tentacles and if no prepared correctly can be quite rubbery.  Sea
cucumbers are more like really stiff gelatin in texture and have no taste
of their own and take on the taste of whatever sauce they are cooked in.



Re: what's a callback?
On Sun, 19 Dec 2004 20:36:53 -0500, Spehro Pefhany

 
Quoted text here. Click to load it
 
 Looks like a giant maggot..  Fancy some geoduck?

http://www.quitbuddies.org/Qb/geoduck.jpg



Regards,

Boris Mohar

Got Knock? - see:
Viatrack Printed Circuit Designs http://www3.sympatico.ca/borism /

Re: what's a callback?
I read in sci.electronics.design that Boris Mohar <borism_-void-
about 'what's a callback?', on Mon, 20 Dec 2004:
Quoted text here. Click to load it
I can't even pronounce it.
--
Regards, John Woodgate, OOO - Own Opinions Only.
The good news is that nothing is compulsory.
We've slightly trimmed the long signature. Click to see the full one.
Re: what's a callback?
On Mon, 20 Dec 2004 18:46:48 +0000, John Woodgate

Quoted text here. Click to load it

http://www.olywa.net/cook/faq.htm




Regards,

Boris Mohar

Got Knock? - see:
Viatrack Printed Circuit Designs http://www3.sympatico.ca/borism /

Re: what's a callback?
Quoted text here. Click to load it

It is.  Gooey-Duck.  

Tried to dig one once, but the sucker was about three feet down under a
strata of clay on it's way to shale.  Probably how it managed to survive
on a beach about 4 miles from Seattle.  I was probably the 10th guy
to try to dig up that damn clam.  (The commercial stuff is dug by divers
below the tide line).

Hot stuff for sushi, I hear.  Didn't used to be, then some marketeer,
about 10-15 years ago, decided to boost its supposed aphrodisiac
qualities based on its appearance.  (Selling stuff is what this town
is really good at. Started with those gold miners.  Coffee, anyone).

Mark Zenier   snipped-for-privacy@eskimo.com  Washington State resident


Re: what's a callback?
Quoted text here. Click to load it

A callback is a function you register (store a pointer in a table, for
example) with some sort of scheduling routine that you want run when
some event occurs.
 
Quoted text here. Click to load it

In the purest sense of things, ISRs are pieces of code that are called
when some (physical) event occurs and are run 'outside' of the scheduled
tasks. In many OSs, ISRs are actually split into two parts, the 'bottom'
and 'top' halfs. The bottom half is the code that must be run at
interrupt time to save I/O data, reset h/w for the next event and set a
flag or schedule a task to do further processing for the event. The 'top
half' is the scheduled task that completes the processing necessary to
handle the event. This might be referred to as a 'callback' in some
systems.

--
Paul Hovnanian     mailto: snipped-for-privacy@Hovnanian.com
------------------------------------------------------------------
We've slightly trimmed the long signature. Click to see the full one.
Re: what's a callback?
Quoted text here. Click to load it

That's a flag. Here's a good explanation of callbacks:

  http://www.tutok.sk/fastgl/callback.html

Best,

Mike Monett

Re: what's a callback?

Quoted text here. Click to load it
Ah. Thanks. I didn't stop to think that templates are the way to
deal with unknown return types. Problem is that you can't actually
use that kind of function without passing the type as a template
parameter.

I had a prob with a template in a dll. It wouldn't link because the
implementation wasn't there.

Like

dll header
template class <T> MyClass{}

The program wouldn't link because there was no implementation.

I couldn't declare

MyClass myClass<int>;
--
Best Regards,
Mike

Re: what's a callback?

Quoted text here. Click to load it

Good grief, but that's hairy stuff. No wonder Windows is such a flakey
pos. Makes me glad I program in assembly, where everything's in plain
sight.

As I now recall, the first time I encountered the "callback" concept
it was in a realtime assembly-language app. If an ISR didn't have time
to finish something, it poked a pointer to the "rest" of its code
somewhere and let the RTOS execute that later when resources were
available. DECs later OSs (RSXnn and VMS, I think) had a "fork"
facility that was similar.

John


John


Re: what's a callback?
Quoted text here. Click to load it

[...]

Quoted text here. Click to load it

Yes, assembly rocks. High level languages don't let you see what is
actually happening in the registers, so you miss good ways to optimize
the code. Although I prefer to let a good HLL to handle most of the
interface stuff, and focus my attention on the places where assembly can
really pay off in performance.

Another thing - it's amazing what can be accomplished in a few hundred
bytes of assembly. So how on earth can Windows consume hundreds of
megabytes to do basically the same thing? I mean, when a printer driver
requires 600 megabytes, something is seriously broken. There's no way a
cpu could be executing all that code all the time - in fact, there is
nothing that could possibly be that complex. So what is the reason for
the bloat???

Best,

Mike Monett

Re: what's a callback?

Quoted text here. Click to load it

Yeah, this is snipped from the "tutok" web page you referenced...



MemberTranslator1(Callee &c,const MemFunc &m):
        Functor1<P1>(thunk,&c,&m,sizeof(MemFunc)){}
    static void thunk(const FunctorBase &ftor,P1 p1)
        {
        Callee *callee = (Callee *)ftor.callee;
        MemFunc &memFunc(*(MemFunc*)(void *)(ftor.memFunc));
        (callee->*memFunc)(p1);
        }
};



OK, imagine trying to understand and maintain 100 millions lines of
code like this. If you passed it through triple-DES encryption, it
couldn't look much worse.

John


Re: what's a callback?
Quoted text here. Click to load it

Well, you write, test, approve and forget ;) Most of the code is
pretty harmless and straight forward anyway.

There's a lot of things behind the scenes. Nobody is amazed when
he/she hits the print button and a printer dialog pops up. And I
have no idea how *your* printer dialog looks like. And neither
has a windows application, when it happens. And the printer driver
has no idea where your printer is, at lpt1, com2, usb or somewhere
on your ethernet network. And of course you expect a gentle warning
that it might be turned off, or has run out of paper or ink.
And you want to run it from 7 applications at the same time, each
using different papersizes, while your secretary wants the same
printer to print a sheet of labels that she has put in the manual
feed tray...

That is just one example. It is a lot easier to write robust code
for a full featured pinball machine.

--
Thanks, Frank.
(remove 'q' and 'invalid' when replying by email)




Re: what's a callback?

[...]

Quoted text here. Click to load it

  > OK, imagine  trying to understand and maintain 100  millions lines
  > of code like this. If you passed it through triple-DES encryption,
  > it couldn't look much worse.

  > John

  100 million lines? Sad, but Windows is probably getting close.

  I think  part  of the reason for code bloat is  programmers  have no
  restrictions on  their code size or  performance  requirements. They
  should be  given 200MHz Pentium computers with an 8  gig  hard drive
  and 64 megs of ram. That would fix slow, bloated code real fast.

  For example, my editor uses Borland SPRINT, which was  last released
  in 1988  and  was designed to run on an 8080 with  640k  of  ram. It
  handles 11  different types of files, including  html,  plain ascii,
  pascal, c, assembly, email, newsgroup postings, google groups, etc.

  It can load up to 27 files simultaneously and  automatically detects
  the file  type  when  switching  from one  window  to  the  next. It
  switches the command functions as appropriate for the type  of file,
  so I  don't  have  to  memorize  different  commands  and keystrokes
  depending on the file type in the current window.

  The editor  is  very  compact and  and  loads  instantly.  It rarely
  crashes, except when Windows crashes on a bad pointer and  messes up
  memory. It  is  blazingly  fast on a  200MHz  Pentium,  so  there is
  little need  for a 2GHz machine (except to read  those  #$%@&* Adobe
  pdf files:)

  Of course,  this  style  of thinking would  probably  put  a  lot of
  programmers and  maybe  some  companies out  of  business.  For some
  strange reason, making things overly complex is good for business.

Best,

Mike Monett

Re: what's a callback?
Quoted text here. Click to load it

Windows isn't bloated at all. There's just a lot of things to be dealt
with, but that happens so incredibly transparent to the casual observer,
that we take it all for granted and assume the code is bloated or something.

Quoted text here. Click to load it

[snip]

Quoted text here. Click to load it

This style of thinking would probably kept us all back in 1988, the release
date of your editor ;)

--
Thanks, Frank.
(remove 'q' and 'invalid' when replying by email)





Re: what's a callback?

Quoted text here. Click to load it

There's a difference between doing something because it can
be done and doing something because it's needed.  Microsoft
can throw the problem of hardware resources over the wall
to the users at no cost to themselves.

Quoted text here. Click to load it

This is precisely the thinking that's needed and necessary
for /embedded/ computing.  Reliability and hardware resources
are directly impacted by keeping things as simple as possible.

Re: what's a callback?
On Wed, 22 Dec 2004 09:44:50 PST, the renowned

Quoted text here. Click to load it

How about this analogy?

I often need to shave dimes and pennies off of hardware for production
purposes (corresponding, of course to a multiple of that in the
selling price), but when I buy a *tool* for *business use*, an extra
$10 or $100 is often no big deal if I get something valuable in
return.

Spending a certain amount of today's bountiful desktop disk space and
processor processor bandwidth to get a tool that's as feature-rich as
makes sense to the authors of the program (hopefully) and easy to
install and configure (again) is not silly at all. Even on inexpensive
products, we sure don't write everything in tightly crafted assembler
any more. It's not as simple as possible, but rather as simple as
makes sense with the resources at hand.


Best regards,
Spehro Pefhany
--
"it's the network..."                          "The Journey is the reward"
snipped-for-privacy@interlog.com             Info for manufacturers: http://www.trexon.com
We've slightly trimmed the long signature. Click to see the full one.
Re: what's a callback?
Quoted text here. Click to load it
something.

Nobody forces you to use the latest windows software. If DOS3.22
works for you, why upgrade?

Quoted text here. Click to load it

For simple middle-of-the-road embedded computing, yes.

--
Thanks, Frank.
(remove 'q' and 'invalid' when replying by email)



Re: what's a callback?

[...]

Quoted text here. Click to load it

[...]

Actually, it's a complete operating system that runs on top of DOS, the same as
earlier versions of Windows. Here's a partial screen shot:

 ..\          2F87BA86           Previous Directory
\IE50REG      2F87BA86           Backup Copy of MSIE REG16x2.DAT
\REGDATA      2F87BA87           Explorer 5.0 Verisign Certificates 93% slack
\SYSTEM       2F87BA88           System Files
\ZIP          2F87BB39           Backup Directory
 NISTIMEW CFG 310B6F05        31 Configure NIST Time
 LMOUSE   COM 186A1940    34,658 Logitech Mouse
 WIN      COM 28FA792A    44,170 Win 3.1 Original
 ANIMOUSE DAT 30FB555D        28 AniMouse Config
 REG      DAT 3196691D    55,922 Win 3.1 Original
 REG16X2  DAT 2CCD8EFA    58,730 Explorer 5.0 Keep a backup copy in IE50REG
 NISTIME  DIF 3193BD23     1,079 Nist Time Log
 WINSOCK  DLL 20489086    30,516 Moved Here From G:\SYMPATIC
 HK       DOC 2EC67370     9,757 HotKey
 ANIMOUSE EXE 1ED12800   378,464 AniMouse
 CALC     EXE 186A1940    43,072 Win 3.1 Accessories
 CALENDAR EXE 186A1940    59,824 Win 3.1 Accessories

The columns show the file or directory name, extension, date in hex format,
filesize, and a comment field that contains information about the file. This
information goes with the file when I move or copy it to a different directory,
and the information can be changed as needed without breaking links to other
programs, such as image links in html files.

The cursor (not shown) hilites a file in yellow. Pressing various function or
command keys will erase the file, copy  or move it to a different directory, or
execute a specific program associated with the file. For example, it loads an
editor or file viewer as needed, or starts Windows and loads the appropriate
program all with a single keystroke.

I have numerous search programs that can index the entire disk in minutes and
locate any file in seconds. I never have to type in a filename or directory, and
all the needed commands are under control of the cursor and function keys. I
never have to remember all the options needed with various programs, such as
PKZIP or PKUNZIP. They are all encoded and attached when the program loads.

This method is the opposite of the Windows procedure, where you load a program
first, then search for the desired file. It is several orders of magnitude
faster than Windows, and completely avoids the confusion and errors when you
cannot locate the desired file or load the wrong one.

IMHO, this is the way Windows should have been designed from the beginning.

Best,

Mike Monett

Site Timeline