Re: [Haifux] Implementing read() like UNIX guys like it
Hi Eli, Since I don't think that there is a definite answer to your dilemma, I suggest a common solution to it, which you might not like, but here it goes: implement all three behaviors and use module parameters to select and configure each mode. Then you can play and experiment with each of them and decide what's best. I understand that this might be a waste of time, but I doubt you can find a good answer otherwise. Emil Quoting Eli Billauer e...@billauer.co.il: Hello Guy, guy keren wrote: first - it does not seem that you have a notion of end of file for your input - is there? As a matter of fact there is: An extra line (in hardware) will say no more data from hardware which will cause an end of file condition on the Linux side. This is not mandatory to use, but I figured this could be a useful feature. And if we're at it, there will also be a (hardware) line which will be asserted as long as the file is open on the Linux side, so that some hardware logic can reset itself between file sessions. Now, if you decide that your read will not block indefinitely (which is against the posix definition, as far as i know) Oh, no. I wouldn't even think about going that far. The issue in question was not whether to block or not given the lack of data, but whether to return a partial buffer immediately or to wait until the requested data count has arrived. Or to wait a bit trying to increase the length of the chunks (as TCP/IP does in order to support both data and terminal connections). if the user calls read and there is data - return what you have to the user without blocking. That is one of the options I considered. The drawback of doing this exactly like this, is that if data arrives at a slow rate (say, 100 kB/sec) it's likely that every read() operation will yield one byte of data, making the CPU spin around this instead of doing something useful. 1. is there some kind of protocol in which the data arrives from this FIFO, or is it just an unrelated stream of octets? Yes. (That is, the user can do this or that. I can't know in advance). in the former case - you can return from read() when you've read a full message. Then again, I don't know what's going through the lines. in the later case - if a user will use fgets() - the user is a complete fool - since fgets expects to read until end-of-line (and it blocks until this happens). As I said, I try to make things work even for less qualified programmers. 2. if question 1 is irrelevant - what kind of data does the user get from this FIFO? does the user control the data that is written into the FIFO from the hardware - or is it completely not in the user's control? The user gets a way to connect to the FIFO on the hardware end, and is free to use it as he likes. Then I want him to be able to open the device file any way he sees fit, read from it like he sees fit, and the whole thing should work like a clockwork. The whole point of this project is to make the communication between the FPGA and a sophisticated OS really simple (for the user). Thanks for trying. :) Eli -- Web: http://www.billauer.co.il ___ Haifux mailing list Haifux@haifux.org http://hamakor.org.il/cgi-bin/mailman/listinfo/haifux ___ Haifux mailing list Haifux@haifux.org http://hamakor.org.il/cgi-bin/mailman/listinfo/haifux
Re: [Haifux] [HAIFUX LECTURE] UniversAAL - Open Source platform for Ambient Assisted Living and Smart Home Environment - Vadim Eisenberg
Hi, There is a minor (I guess spell-checker induced, but really funny IMO) typo in your abstract. s/deceases/diseases/ Or maybe I got it wrong ;-) Emil Quoting Orna Agmon Ben-Yehuda ladyp...@gmail.com: On Monday, February 28th (TODAY) at 18:30, Haifux will gather to hear Vadim Eisenberg talk about UniversAAL - Open Source platform for Ambient Assisted Living and Smart Home Environment http://haifux.org/lectures/251 Abstract I will present two presentations about an EU FP7 IP project I work on, UniversAAL - http://universaal.org/. The goal of the project is to develop an open source platform for Ambient Assisted Living (AAL). Ambient Assisted Living is a kind of Smart Home environment for elderly people - for example, a house equipped with different sensors and in which different devices, sensors and home appliances are networked together and managed by software applications. In addition, the platform could be used for monitoring of chronic deceases, providing healthcare services at home, supporting people with disabilities. I will present the project and will talk about technologies involved in the project: OSGi, Middleware, (Semantic) SOA, Security, Android, Living Labs. About me: I work in IBM, IT for Healthcare Life Sciences group, and do my M.Sc. studies at the Technion, Computer Science Department. My research interests are Semantic Web, Software Engineering and Programming Languages. I made my first Open Source contribution two months ago - http://d2rqupdate.cs.technion.ac.il/, Apache 2.0 license (on my personal time, it is not related to IBM). I developed D2RQ/Update and D2R Server/Update prototype extensions to a popular RDF-to-RDB mapping platform - D2RQ http://www4.wiwiss.fu-berlin.de/bizer/d2rq/ (it is related to Semantic Web technologies). We meet in Taub (CS Faculty) building, room 6. For instructions see: http://www.haifux.org/where.html Attendance is free, and you are all invited! Future Haifux talks include: 14/3/2011 The story of Alice and Bob - the I/O requests by guy keren (part i) 28/3/2011 The story of Alice and Bob - the I/O requests by guy keren (part ii) We are always interested in hearing your talks and ideas. If you wish to give a talk, hold a discussion, or just plan some event haifux might be interested in, please contact us at webmas...@haifux.org -- Orna Agmon Ben-Yehuda. http://ladypine.org ___ Haifux mailing list Haifux@haifux.org http://hamakor.org.il/cgi-bin/mailman/listinfo/haifux
Re: [Haifux] Job offer: SW developer
Quoting Shachar Shemesh shac...@shemesh.biz: SNIPPED NLP as in Natural Language Processing? The list of intersection of Linguists and programmers I know consists of exactly one person, Hmmm... Are you talking about Larry Wall? ;-)) ___ Haifux mailing list Haifux@haifux.org http://hamakor.org.il/cgi-bin/mailman/listinfo/haifux
Re: [Haifux] [OT][NON-JOB OFFER] Beauty and the Geek 3 (Channel 10)
Quoting Hetz Ben Hamo het...@gmail.com: Yeah, great way to become a joke in the geek community, and a bigger joke if you're looking for a new job/project.. Unless your job is in TV/entertainment, which is where most participants in [pseudo]reality shows go anyway. Hetz 2011/1/16 Orna Agmon Ben-Yehuda ladyp...@gmail.com Hello all, I am forwarding this as a non-job offer, since participants are not paid (though they have a chance of winning a monetary prize). Orna. -- Forwarded message -- Following the Success of the second season of Beauty and the Geek we are now beginning the search for our next contestants who are willing to take part in an adventure of a lifetime! Thinking it's about Time to Make a Change? Always Wanted to Transform Someone Else? Come and take part in Beauty and the Geek, the Most Humane Reality Show on Television If you are a girl and look amazing and you are sure that you are able to teach brilliant geeks a thing or two ג€¦ take this opportunity to show everyone what you worth! If you are a young intelligent guy who would like to try and step out of his boundaries, break free, change and yes ג€¦ to have some good time with some amazing beauties ג€“ join us in an experience of a lifetime You can leave your details: Voice Mail ג€“ 052-999 Mail - yafa.g...@gmail.com -- Orna Agmon Ben-Yehuda. http://ladypine.org ___ Linux-il mailing list linux...@cs.huji.ac.il http://mailman.cs.huji.ac.il/mailman/listinfo/linux-il -- *׳—׳¥ ׳‘׳� ׳—׳�׳• ׳—׳¥-׳‘׳™׳– (׳”׳•׳¡׳˜׳™׳ ׳’) *׳”׳©׳›׳¨׳” ׳•׳�׳™׳¨׳•׳— ׳©׳� ׳©׳¨׳×׳™׳� ׳₪׳™׳–׳™׳™׳� ׳”׳©׳›׳¨׳× ׳©׳¨׳×׳™׳� ׳•׳™׳¨׳˜׳•׳�׳�׳™׳™׳� ׳�׳§׳¦׳•׳¢׳™׳™׳� ׳•׳’׳“׳•׳�׳™׳� ׳‘׳�׳—׳™׳¨׳™׳� *׳§׳˜׳ ׳™׳�* ׳‘׳§׳¨׳• ׳‘׳�׳×׳¨׳ ׳• ׳‘׳›׳×׳•׳‘׳× hetz.biz http://www.hetz.biz/ ׳•׳‘׳‘׳�׳•׳’ ׳©׳�׳ ׳•: blog.hetz.biz ׳˜׳�׳₪׳•׳�׳�: 078113/4/5, ׳�׳™׳�׳™׳™׳�: sa...@hetz.biz ׳�׳¡׳ ׳’'׳¨: sa...@hetz.biz - ׳¡׳§׳™׳™׳₪: heunique ___ Haifux mailing list Haifux@haifux.org http://hamakor.org.il/cgi-bin/mailman/listinfo/haifux
Re: [Haifux] some addendums to today's gdb meeting
Hi, SNIPPED 6. regarding re-creating a live process from a core file - some people already thought about this (as usual). here is an example (i didn't try this yet): http://www.geocities.com/asimshankar/checkpointing/ A long time ago, there was a [n almost] standard UNIX command called undump which would re-create an executable out of a core file. I think PERL users might be familiar with that. If I recall correctly this was one of the first ways to compile a perl script to an executable. You start PERL, and make it dump core straight at the beginning. Then you would recreate the perl process via undump. I'm really sorry I missed your lecture. I'm sure it was a excellent one, like always. Emil i think there was something else we wanted an answer for - does anyone remember? --guy ___ Haifux mailing list Haifux@haifux.org http://hamakor.org.il/cgi-bin/mailman/listinfo/haifux ___ Haifux mailing list Haifux@haifux.org http://hamakor.org.il/cgi-bin/mailman/listinfo/haifux
Re: [Haifux] Mandrake 10.1 Installation lecture
Hi, I do not know if you are aware of the problem of the missing g++ in Mandrake 10.1 CE. If you install from CDs, even if you select Development Tools, g++ will not be installed. In fact the g++ compiler RPM is not present at all on the Mandrake 10.1 CDs. For a developer, the missing C++ compiler can be quite annoying. The workaround is (assuming that your network is working) to log on as root and type: urpmi gcc-c++ The problem is quite old, I have written about it earlier. Look at: http://www.mail-archive.com/haifux@haifux.org/msg01598.html Regards, Emil Quoting Adir Abraham [EMAIL PROTECTED]: Hi, Lecture slides of today are available here: http://vipe.technion.ac.il/~adir/lectures/MandrakeInstLect.pdf And also as an openoffice template (stw): http://vipe.technion.ac.il/~adir/lectures/MandrakeInstLect.stw Regards, Adir. -- Haifa Linux Club Mailing List (http://www.haifux.org) To unsub send an empty message to [EMAIL PROTECTED] -- Haifa Linux Club Mailing List (http://www.haifux.org) To unsub send an empty message to [EMAIL PROTECTED]
Re: [Haifux] Question :argument from File or Command line ; LDAP
Hi, I am neither a Perl nor an LDAP expert, but here are some hints: 1) it's better to use chomp instead of chop 2) I think it's better if you pass just a single space (' ') as the first parameter to split() (without slashes, i.e. the call would be split(' ',$line); ). This means that split() will split using *any whitespace character*, which is probably what you want. Hope this helps, Emil Quoting Nir Abulaffio [EMAIL PROTECTED]: Hi all, This is a problem we have come across. Any suggestions? Nir. when I read from a file $line=file ; chop($line); and split : ($uid,$fname,$sname) = split(/\s+/,$line); After a call to function of LDAP (add),I receive an endless loop in function of LDAP . If I get variable $uid as argument from command line : Prompt: Program.pl uid Then the function of LDAP works OK ! Why ? If I check variable $uid from command line and from file with function cmp, I receive 0 . Prompt uname -a Linux radiatora 2.4.20-8 #1 Thu Mar 13 17:54:28 EST 2003 i686 i686 i386 GNU/Linux Prompt perl -v This is perl, v5.8.0 built for i386-linux-thread-multi (with 1 registered patch, see perl -V for more detail) Copyright 1987-2002, Larry Wall Perl may be copied only under the terms of either the Artistic License or the GNU General Public License, which may be found in the Perl 5 source kit. Complete documentation for Perl, including FAQ lists, should be found on this system using `man perl' or `perldoc perl'. If you have access to the Internet, point your browser at http://www.perl.com/, the Perl Home Page. Prompt perl -V Summary of my perl5 (revision 5.0 version 8 subversion 0) configuration: Platform: osname=linux, osvers=2.4.20-2.48smp, archname=i386-linux-thread-multi uname='linux str' config_args='-des -Doptimize=-O2 -march=i386 -mcpu=i686 -g -Dmyhostname=localhost [EMAIL PROTECTED] -Dcc=gcc -Dcf_by=Red Hat, Inc. -Dinstallprefix=/usr -Dprefix=/usr -Darchname=i386-linux -Dvendorprefix=/usr -Dsiteprefix=/usr -Dotherlibdirs=/usr/lib/perl5/5.8.0 -Duseshrplib -Dusethreads -Duseithreads -Duselargefiles -Dd_dosuid -Dd_semctl_semun -Di_db -Ui_ndbm -Di_gdbm -Di_shadow -Di_syslog -Dman3ext=3pm -Duseperlio -Dinstallusrbinperl -Ubincompat5005 -Uversiononly -Dpager=/usr/bin/less -isr' hint=recommended, useposix=true, d_sigaction=define usethreads=define use5005threads=undef' useithreads=define usemultiplicity= useperlio= d_sfio=undef uselargefiles=define usesocks=undef use64bitint=undef use64bitall=un uselongdouble= usemymalloc=, bincompat5005=undef Compiler: cc='gcc', ccflags ='-D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBUGGING -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm', optimize='', cppflags='-D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBUGGING -fno-strict-aliasing -I/usr/local/include -I/usr/include/gdbm' ccversion='', gccversion='3.2.2 20030213 (Red Hat Linux 8.0 3.2.2-1)', gccosandvers='' gccversion='3.2.2 200302' intsize=e, longsize= , ptrsize=p, doublesize=8, byteorder=1234 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12 ivtype='long' k', ivsize=4' ivtype='long' known_ext, nvtype='double' o_nonbl', nvsize=, Off_t='', lseeksize=8 alignbytes=4, prototype=define Linker and Libraries: ld='gcc' l', ldflags =' -L/usr/local/lib' ldf' libpth=/usr/local/lib /lib /usr/lib libs=-lnsl -lgdbm -ldb -ldl -lm -lpthread -lc -lcrypt -lutil perllibs= libc=/lib/libc-2.3.1.so, so=so, useshrplib=true, libperl=libper gnulibc_version='2.3.1' Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=so', d_dlsymun=undef, ccdlflags='-rdynamic -Wl,-rpath,/usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE' cccdlflags='-fPIC' ccdlflags='-rdynamic -Wl,-rpath,/usr/lib/perl5', lddlflags='s Unicode/Normalize XS/A' Characteristics of this binary (from libperl): Compile-time options: DEBUGGING MULTIPLICITY USE_ITHREADS USE_LARGE_FILES PERL_IMPLICIT_CONTEXT Locally applied patches: MAINT18379 Built under linux Compiled at Feb 18 2003 22:19:53 @INC: /usr/lib/perl5/5.8.0/i386-linux-thread-multi /usr/lib/perl5/5.8.0 /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.0 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.0 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.0/i386-linux-thread-multi /usr/lib/perl5/5.8.0 . -- Haifa Linux Club Mailing List (http://www.haifux.org) To unsub send an empty message to [EMAIL PROTECTED]