dev-cpp-users Mailing List for Dev-C++
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
You can subscribe to this list here.
2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(15) |
Oct
(115) |
Nov
(154) |
Dec
(258) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2001 |
Jan
(377) |
Feb
(260) |
Mar
(249) |
Apr
(188) |
May
(152) |
Jun
(150) |
Jul
(195) |
Aug
(202) |
Sep
(200) |
Oct
(286) |
Nov
(242) |
Dec
(165) |
2002 |
Jan
(245) |
Feb
(241) |
Mar
(239) |
Apr
(346) |
May
(406) |
Jun
(369) |
Jul
(418) |
Aug
(357) |
Sep
(362) |
Oct
(597) |
Nov
(455) |
Dec
(344) |
2003 |
Jan
(446) |
Feb
(397) |
Mar
(515) |
Apr
(524) |
May
(377) |
Jun
(387) |
Jul
(532) |
Aug
(364) |
Sep
(294) |
Oct
(352) |
Nov
(295) |
Dec
(327) |
2004 |
Jan
(416) |
Feb
(318) |
Mar
(324) |
Apr
(249) |
May
(259) |
Jun
(218) |
Jul
(212) |
Aug
(259) |
Sep
(158) |
Oct
(162) |
Nov
(214) |
Dec
(169) |
2005 |
Jan
(111) |
Feb
(165) |
Mar
(199) |
Apr
(147) |
May
(131) |
Jun
(163) |
Jul
(235) |
Aug
(136) |
Sep
(84) |
Oct
(88) |
Nov
(113) |
Dec
(100) |
2006 |
Jan
(85) |
Feb
(119) |
Mar
(33) |
Apr
(31) |
May
(56) |
Jun
(68) |
Jul
(18) |
Aug
(62) |
Sep
(33) |
Oct
(55) |
Nov
(19) |
Dec
(40) |
2007 |
Jan
(22) |
Feb
(49) |
Mar
(34) |
Apr
(51) |
May
(66) |
Jun
(43) |
Jul
(116) |
Aug
(57) |
Sep
(70) |
Oct
(69) |
Nov
(97) |
Dec
(86) |
2008 |
Jan
(32) |
Feb
(47) |
Mar
(106) |
Apr
(67) |
May
(28) |
Jun
(39) |
Jul
(31) |
Aug
(25) |
Sep
(18) |
Oct
(25) |
Nov
(5) |
Dec
(21) |
2009 |
Jan
(33) |
Feb
(27) |
Mar
(27) |
Apr
(22) |
May
(22) |
Jun
(10) |
Jul
(17) |
Aug
(9) |
Sep
(21) |
Oct
(13) |
Nov
(4) |
Dec
(11) |
2010 |
Jan
(10) |
Feb
(8) |
Mar
(4) |
Apr
(1) |
May
|
Jun
(2) |
Jul
|
Aug
(1) |
Sep
(8) |
Oct
(26) |
Nov
(9) |
Dec
(1) |
2011 |
Jan
(21) |
Feb
(16) |
Mar
(4) |
Apr
(19) |
May
(26) |
Jun
(9) |
Jul
(6) |
Aug
|
Sep
(4) |
Oct
(3) |
Nov
(2) |
Dec
(1) |
2012 |
Jan
(4) |
Feb
(7) |
Mar
(4) |
Apr
|
May
(1) |
Jun
(10) |
Jul
(1) |
Aug
(1) |
Sep
(18) |
Oct
(3) |
Nov
(1) |
Dec
(1) |
2013 |
Jan
(4) |
Feb
(2) |
Mar
(15) |
Apr
(6) |
May
(1) |
Jun
(3) |
Jul
(1) |
Aug
(2) |
Sep
(4) |
Oct
|
Nov
(9) |
Dec
|
2014 |
Jan
(4) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(5) |
Aug
(4) |
Sep
|
Oct
(2) |
Nov
(1) |
Dec
(4) |
2015 |
Jan
(2) |
Feb
(3) |
Mar
(1) |
Apr
(2) |
May
(1) |
Jun
(2) |
Jul
|
Aug
(1) |
Sep
(2) |
Oct
(9) |
Nov
(35) |
Dec
(6) |
2016 |
Jan
(7) |
Feb
(10) |
Mar
(10) |
Apr
(9) |
May
(13) |
Jun
(9) |
Jul
(1) |
Aug
(3) |
Sep
(3) |
Oct
(1) |
Nov
(1) |
Dec
|
2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2018 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2019 |
Jan
(1) |
Feb
|
Mar
|
Apr
(2) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2020 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
|
|
|
|
|
1
|
2
|
3
|
4
(2) |
5
(5) |
6
(12) |
7
(9) |
8
(2) |
9
|
10
(6) |
11
(6) |
12
(7) |
13
(3) |
14
(8) |
15
(1) |
16
(2) |
17
(3) |
18
|
19
(10) |
20
(4) |
21
|
22
(3) |
23
(1) |
24
(1) |
25
|
26
(1) |
27
|
28
|
29
|
30
|
31
|
|
|
|
|
|
From: <ta...@fe...> - 2007-12-26 14:30:45
|
------------------------------------------------------------------------ ------------------------ (Apologies for cross-posting) EUROMEDIA 2008, APRIL 9-11, 2008, FEUP-UNIVERSITY OF PORTO, PORTUGAL http://www.eurosis.org/cms/?q=3Dtaxonomy/term/100 We would appreciate if you could distribute this information by your colleagues and co-workers. ------------------------------------------------------------------------ ------------------------ 2ND Call for Papers EUROMEDIA 2008 14TH ANNUAL MULTIMEDIA CONFERENCE WEBSITE http://www.eurosis.org/cms/?q=3Dtaxonomy/term/100 UNIVERSITY OF PORTO PORTUGAL APRIL 9-11, 2008 Organized by ETI Sponsored by EUROSIS Delft University of Technology Belgacom TTVI Ghent University DG-INFSO Dear Colleague, this is a reminder that the abstract submission deadline for EUROMEDIA 2008 is next January 20. As a reminder also please find enclosed the list of the conference topics: [] WEBTEC * Internet Viewers and Programs * Visual Programming Languages * 3D Web Programs * Video and Audio Streaming on the Web * AI on the Web * Software for Web-based Business Applications [] MEDIATEC * Multimedia Techniques and Telecom * Multimedia Authoring Tools and Software * Multimedia Building Blocks [] COMTEC * Telecommunications Technologies * Networks * Network Security * Mobile Communications * TV Technology * QoS [] APTEC * Telematics Consumer Applications * Cooperative Consumer Application * Tele-Education * Integrated Enterprise Software and Groupware * Telemedicine * Ubiquitous Computing Applications * Embedded Systems and Future Product Market Combinations * Multimodal communication [] ETEC * Tele-X and E-Commerce * Knowledge Management and E-Mobility Special Tracks: [] Knowledge Management and e-Mobility [] In-Car Applications [] Facial Recognition or Non Verbal Communication [] Virtual Reality 2.0 Applications Special Workshops: [] Medical Imaging Systems In recent years, extensive research has been performed to develop more and more efficient and powerful medical imaging systems. Such systems are crucial for medical specialists, allowing a deeper analysis and to understand what is going inside the human body, and therefore they play an essential role for adequate medical diagnosis and treatments. To accomplish efficient and powerful medical imaging systems, many research works have being done in many domains, like the ones related with medical image devices, signal processing, image processing and analysis, biomechanical simulation and data visualization. The main goal of the Workshop =93Medical Imaging Systems=94 is to bring together researchers involved in the related domains, in order to set the major lines of development for the near future. Therefore, the proposed Workshop will consist of researchers representing various fields related to Medical Devices, Signal Processing, Computational Vision, Computer Graphics, Computational Mechanics, Scientific Visualization, Mathematics and Medical Imaging. The Workshop endeavors to contribute to obtain better solutions for more efficient and powerful medical imaging systems, and attempts to establish a bridge between clinicians and researchers from these diverse fields. The proposed Workshop will cover topics related with medical imaging systems, such as: =95 image acquisition =95 signal processing =95 image processing and analysis =95 modelling and simulation =95 computer aided diagnosis =95 surgery, therapy, and treatment =95 computational bioimaging and visualization =95 software development = =95 virtual reality =95 telemedicine systems and their applications=20 [] D-TV Scope: In contrast to traditional TV DTV is a telecommunication system for broadcasting and receiving moving pictures and sound by means of digital signals. It uses digitally compressed modulation data, which requires decoding by a specially designed television set or a standard receiver (set-top box) as well as via PC-TV based on ADLS (VDSL). Digital Television has several advantages regarding technically as well as content and programme related aspects. One of the most significant is the use of a smaller channel bandwidth. This frees up space for more digital channels, other non-television services such as pay-multimedia services and the generation of new revenue models based on interactive advertisement and marketing features. Furthermore there are special services such as multicasting (more than one programme on the same channel), electronic programme guides and interactivity providing a wider range of application. Accordingly within the last year a growing up of specialised digital TV channels (Special Interest Channels) has to be observed European wide. This new growing up stream is mainly characterised by the phenomena of merging television (TV) and information technology (IT) know how, methods and techniques. In this context the workshop targets to show up the development in both directions: the technically aspects as well as the content and programme issues. It provides a presentation and discussion platform for exchanging experiences made within the establishment as well as the maintenance of digital special interest channels. Main focus will be to point out the interdependencies and the mutual influences of technically streams and content respectively service related issues. Topics: * Broadband Television * Interactive Television * IPTV - Web-TV * DVB-H, DVB-T, DVB-S, DVB-C * MHP & Interactive Television * Set-Top-Boxes * Full Digital Production Chain Management * Digital-Video-Journalism * DMB (Digital Multimedia Broadcasting) * FreeTV & PayTV * Interactive Video * Interactive Advertising Formats * Event Oriented Interview Formats * Event Driven Program Schemes & Formats * Mobile Content * Cross-Format Content & Knowledge Pooling * Cross-Media Content Production & Distribution * Indexing and Retrieval of Digital Content * Semantically Enrichment of Digital Content * Security & Digital Rights Management (DRM) * Watermarking & Copyrights & Protection * Cross-platform productions on TV Media-Convergence * Peer-to-peer Grid TV Applications For more information on the workshops see: http://www.eurosis.org/cms/index.php?q=3Dnode/476 Conference Committee General Conference Chair Jo=E3o Manuel R. S. Tavares, FEUP, University of Porto, Porto, Portugal Renato Natal Jorge, FEUP, University of Porto, Porto, Portugal WEBTEC Programme Committee Sameh Abdel-Naby, University of Trento, Trento, Italy Dr. Paul Dowland, University of Plymouth, Plymouth, United Kingdom Dipl.-Inf. Steffen Harneit, CUTEC-Institute GmbH, Clausthal-Zellerfeld, Germany Ass. Prof. Qingping Lin, Nanyang Technological University, Singapore Prof. Dr. J=F6rn Loviscach, Hochschule Bremen, University of Applied Sciences, Bremen, Germany Assoc. Prof. Wenji Mao, Institute of Automation, Chinese Academy of Sciences, Beijing, P.R. China Lorenzo Motta, Ansaldo Segnalamento Ferroviaro s.p.a. Genova, Italy Dr. H. Joachim Nern, Aspasia Knowledge Systems, Dusseldorf, Germany Dr. Carlos E. Palau, Universidad Politecnica de Valencia, Valencia, Spain Prof. Paola Salomoni, Universita di Bologna, Bologna, Italy Dr. Elpida Tzafestas, National Technical University of Athens, Athens, Greece Dr. Matthew Warren, Deakin University Geelong, Victoria, Australia MEDIATEC Programme Committee Assoc. Prof. Vincent Charvillat, IRIT-ENSEEIHT, Toulouse cedex, France Dr. Fernando Boronat Segui, Universidad Politecnica de Valencia, Gran de Gandia, Spain Ignazio Infantino, ICAR-CNR, Palermo (PA), Italy PhD. Jens Mueller-Iden, University of M=FCnster, M=FCnster, Germany Dr. Ana = Pajares, Universidad Politecnica de Valencia, Valencia, Spain Jehan Francois Paris, University of Houston, Houston, USA Prof. Marco Roccetti, Universita' di Bologna, Bologna, Italy Dr. Leon Rothkrantz, Delft University of Technology, Delft, The Netherlands Dr. Leonid Smalov, Coventry University, Coventry, United Kingdom Prof. Rik Van de Walle, Ghent University, Ghent, Belgium COMTEC Programme Committee Prof. Dr. Marwan Al-Akaidi, De Montfort University, Leicester, United Kingdom Boguslaw Butrylo, Bialystok Technical University, Bialystok, Poland Dr. Nathan Clarke, University of Plymouth, Plymouth, United Kingdom Dr. Steven Furnell, University of Plymouth, Plymouth, United Kingdom Prof. Chris Guy, The University of Reading, Reading, United Kingdom PhD Mohammad Riaz Moghal, Ali Ahmad Shah-University College of Engineering and Technology, Mirpur, Pakistan PhD Roberto Montemanni, IDSIA, Manno-Lugano, Switzerland Maria Papadaki, University of Plymouth, Plymouth, United Kingdom Ph. D. Oryal Tanir, Bell Canada, Montreal, Canada Ass. Prof. Vassilis Triantafillou, ?echnological Educational Institution of Messolonghi Applied, Greece APTEC Programme Committee Prof. Dr. J. Broeckhove, RUCA-UA, Antwerp, Belgium Dr. Juan Carlos Guerri Cebollada, Universidad Politecnica de Valencia, Valencia, Spain Hatice Gunes, University of Technology, Sydney (UTS), NSW Australia Carsten Magerkurth, SAP RESEARCH, St. Gallen, Switzerland Dr.ir. Johan Opsommer, Belgacom - BUS, Brussels, Belgium Prof. Matthias Rauterberg, Eindhoven University of Technology, Eindhoven, The Netherlands. Francisco Reinaldo, FEUP, University of Porto, Porto, Portugal Zasriati Azla Sabot, University College Jubail, Jubail Industrial City, Saudi Arabia Prof. Jeanne Schreurs. Hasselt University, Diepenbeek, Belgium Ass. Prof. Ramiro Vel=E1zquez, Universidad Panamericana, Aguascalientes, Mexico Dr. Charles van der Mast, Delft University of Technology, Delft, The Netherlands E-TEC Programme Committee Dr.Steven Furnell, University of Plymouth, Plymouth, United Kingdom Dr. Paul Dowland, University of Plymouth, Plymouth, United Kingdom Knowledge Management and E-Mobility Prof. Ricardo Chalmeta, Universidad Jaume I, Castellon, Spain Prof. Dr.-Ing. Stephan Kassel, University of Applied Sciences Zwickau, Germany Workshops Medical Imaging Systems General Chair Jo=E3o Manuel R. S. Tavares, FEUP, University of Porto, Porto, Portugal General Co-Chair Renato Natal Jorge, FEUP, University of Porto, Porto, Portugal International Programme Committee Alberto De Santis, Universit=E0 degli Studi di Roma "La Sapienza", Italy Arrate Mu=F1oz Barrutia, University of Navarra, Spain Behnam Heidari, University College Dublin, Ireland Bernard Gosselin, Faculte Polytechnique de Mons, Belgium Chandrajit Bajaj, University of Texas, USA Christos E. Constantinou, Stanford University School of Medicine, USA Daniela Iacoviello, Universit=E0 degli Studi di Roma "La Sapienza", Italy Dinggang Shen, University of Pennsylvania, USA Djemel Ziou, University of Sherbrooke, Canada Gerald Schaefer Aston University, United Kingdom Jo=E3o Krug Noronha, Dr. Krug Noronha Clinic, Portugal = Jo=E3o Manuel R. S. Tavares, Faculty of Engineering of University of Porto, Portugal Jo=E3o Paulo Costeira, Instituto Superior T=E9cnico, Portugal = Jorge M. G. Barbosa, Faculty of Engineering of University of Porto, Portugal Lyuba Alboul, Sheffield Hallam University, United Kingdom Manuel Gonz=E1lez Hidalgo, Balearic Islands University, Spain Maria Elizete Kunkel, Universit=E4t Ulm, Germany M=E1rio Forjaz Secca, Universidade = Nova de Lisboa, Portugal Miguel Angel L=F3pez, Faculty University of Ciego de Avila, Cuba Miguel Velhote Correia, Faculty of Engineering of University of Porto, Portugal Patrick Dubois, Institut de Technologie M=E9dicale, France Reneta Barneva, State University of New York, USA Renato M. Natal Jorge, Faculty of Engineering of University of Porto, Portugal Sabina Tangaro, University of Bari, Italy Valentin Brimkov, State University of New York, USA Yongjie Zhan, Carnegie Mellon University, USA D-TV Workshop Dr. Hans-Joachim Nern, TTVI, Germany CORRESPONDENCE ADDRESS Philippe Geril Ghent University Faculty of Engineering Dept. of Industrial Management Technologiepark 803 B-9062 Ghent-Zwijnaarde, Belgium Tel: +32 9 2645509 Fax: + 32 9 2645824 Email: phi...@eu...=20 -- Philippe Geril Tel: +32.9.264.55.09 EUROSIS -ETI Fax: +32.9.264.58.25 Ghent University E-mail: phi...@eu... Dept.of Industrial Mgmt. E-mail: pg...@ya... Technologiepark 903 URL: http://www.eurosis.org Campus Ardoyen B-9052 Ghent-Zwijnaarde Belgium ********************************************************************* * Your Scientific information site on * * Computer Simulation - Concurrent Engineering - Multimedia- Games * * WWW.EUROSIS.ORG * ********************************************************************* |
From: <and...@su...> - 2007-12-24 14:53:24
|
Dear Users, Happy Cristmas and Happy 2008 for all of you. Thank you for the unconstrained help! Regards Andre Barros No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.5.516 / Virus Database: 269.17.7/1194 - Release Date: 23/12/2007 17:27 |
From: angel d. <sci...@ho...> - 2007-12-23 05:19:57
|
I already got the answer to the message question. thanks to you all. _________________________________________________________________ Share life as it happens with the new Windows Live. http://www.windowslive.com/share.html?ocid=3DTXT_TAGHM_Wave2_sharelife_1220= 07= |
From: metty <mts...@ya...> - 2007-12-22 20:10:29
|
Hi All, If there are some unallocated memory that are heap allocated by a DLL, are these released automatically when the DLL is detached from the calling process or do they remain in the heap as long as the application calling the DLL is running? I have the same question regarding global variables declared and used in a DLL. I have a confusion in this area and I appreciate any helpful reply. Thank you in advance! Best regards, Metty ____________________________________________________________________________________ Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ |
From: Per W. <pw...@ia...> - 2007-12-22 18:57:28
|
Too little information given! If the image is in any known image format (GIF, JPEG, TIFF, PCX, BMP, ...) then you need to locate a graphics library that contains code to read that format. If the data is in a raw binary file or stored as ASCII, then you have to write your own code. There is no way anyone can help you, if you don't take your time and clearly specify your problem! /pwm On Sat, 22 Dec 2007, Benson Mwangi wrote: > Hello Everyone, > > Is anyone aware of how to read a greyscale image and convert it into a 2D > array of 256 by 256 in C++. > > I would appreciate your contribution on this. > > Kind regards > Benson. > |
From: Benson M. <ben...@gm...> - 2007-12-22 18:03:53
|
Hello Everyone, Is anyone aware of how to read a greyscale image and convert it into a 2D array of 256 by 256 in C++. I would appreciate your contribution on this. Kind regards Benson. |
From: Per W. <pw...@ia...> - 2007-12-20 15:19:11
|
Yes, strdup() is a nice function to know. If doing the allocation on program startup, you can normally ignore to release the memory. If doing it in a loop or not needing the results when your function ends, then you should do free() on all pointers returned from strdup(). Try to google for "man strdup". /pwm On Thu, 20 Dec 2007, Jessica Chen wrote: > yep.. i will change 4096*256=1M part. that is too big for saving serial > port info. > > the function of strdup is equal to strlen() + malloc() + memcpy()? > so, i don't need to do memalloc for strSerialList as what i did, since > strdup() will do? > is this a correct understanding? > > > > On Dec 20, 2007 9:23 AM, Per Westermark <pw...@ia...> wrote: > > > Now, you are preallocating 4096 bytes for 256 serial ports. That is 1MB of > > memory. That is not something you want in production code. > > > > My change with strdup() would have performed a strlen() + an optimum-sized > > malloc() + memcpy() for any detected serial ports, i.e. it will end up > > needing at the most a couple of hundred bytes of memory for the names. > > > > /pwm > > > > On Thu, 20 Dec 2007, Jessica Chen wrote: > > > > > Hi, Per, > > > > > > Thanks. I asked my friend to see. He gave me the suggestion. The > > > RegEnumValue can recognize the com and USB->COM. The problem solved > > now, I > > > got the correct result: COM1(com), COM7(usb->com). In front of > > > RegEnumValue, add: > > > dwName = sizeof(Name); > > > dwSizeofPortName = sizeof(szPortName); > > > So the whole code is as follows (a bug in it: didn't release memalloc, > > but > > > doesn't influence the result here). > > > > > > #include <windows.h> > > > #include <stdio.h> > > > #include <tchar.h> > > > > > > int main(void) > > > { > > > int z; > > > char *strSerialList[256]; > > > for (z=0; z<=256; z++) > > > { > > > strSerialList[z] = (char*)malloc(4096*sizeof(char)); > > > } > > > HKEY hKey; > > > > > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > > > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > > > 0, > > > KEY_READ, > > > &hKey) != ERROR_SUCCESS) > > > { > > > return -1; > > > } > > > > > > int i=0; > > > CHAR Name[4096]; > > > UCHAR szPortName[4096]; > > > LONG Status; > > > DWORD dwIndex = 0; > > > DWORD dwName; > > > DWORD dwSizeofPortName; > > > DWORD Type; > > > dwName = sizeof(Name); > > > dwSizeofPortName = sizeof(szPortName); > > > > > > do > > > { > > > dwName = sizeof(Name); > > > dwSizeofPortName = sizeof(szPortName); > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, > > &Type, > > > szPortName, &dwSizeofPortName); > > > printf("Name=%s,szPortName=%s \n", Name, szPortName); > > > if((Status == ERROR_SUCCESS) ) > > > { > > > strcpy(strSerialList[i],(char*)szPortName); > > > //strSerialList[i] = (char*) szPortName; > > > printf("%s ",strSerialList[i]); > > > printf("i=%d,dwIndex=%d\n",i,dwIndex); > > > i++; > > > } > > > } while((Status == ERROR_SUCCESS) ); > > > RegCloseKey(hKey); > > > > > > printf("\n\n"); > > > for(int j=0;j<i;j++) > > > { > > > printf("%s\n",strSerialList[j]); > > > } > > > > > > return 0; > > > } > > > > > > > > > > > > On Dec 19, 2007 6:02 PM, Per Westermark <pw...@ia...> wrote: > > > > > > > On an old test machine I have, the original code produces: > > > > COM1 > > > > COM1 > > > > COM1 > > > > COM1 > > > > COM1 > > > > COM1 > > > > > > > > After adding strdup(), I get: > > > > COM5 > > > > COM6 > > > > COM7 > > > > COM7 > > > > COM4 > > > > COM1 > > > > > > > > Are you sure that your change was correct, and that you remembered to > > > > recompile? > > > > > > > > One interesting thing here is that COM7 is printed twice, while my > > much > > > > used COM3 is not enumerated. > > > > > > > > The two COM7 seems to be a stupid M$ bug with an USB serial adapter :( > > > > > > > > /pwm > > > > > > > > On Wed, 19 Dec 2007, Jessica Chen wrote: > > > > > > > > > Hi, Per, > > > > > > > > > > for your second method, i modified like this. i doesn't solve the > > > > > problem. the result is the same as before. > > > > > for the first method, i tried to change strSerialList[i] = > > > > > (char*)(szPortName); to strSerialList[i] = > > strdup((char*)(szPortName));, > > > > but > > > > > it seems doesn't work too. :-( > > > > > > > > > > Regards, > > > > > Jessica > > > > > > > > > > do > > > > > { > > > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, > > > > &Type, > > > > > szPortName, &dwSizeofPortName); > > > > > if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) > > > > > { > > > > > strSerialList[i] = (char*)(szPortName); > > > > > printf("%s\n",strSerialList[i]); > > > > > i++; > > > > > } > > > > > } while((Status == ERROR_SUCCESS) || (Status == > > ERROR_MORE_DATA)); > > > > > RegCloseKey(hKey); > > > > > > > > > > On Dec 19, 2007 2:44 PM, Per Westermark <pw...@ia...> > > wrote: > > > > > > > > > > > The test code is buggy. It uses the same buffer to retrieve the > > device > > > > > > names, which means that the name will be overwritten. > > > > > > > > > > > > A quicky (with a memory leak that doesn't matter here) is to do > > > > > > strSerialList[i] = strdup((char*)szPortName); > > > > > > > > > > > > Another alternative is to print the devices one-by-one directly > > when > > > > they > > > > > > are found. > > > > > > > > > > > > /pwm > > > > > > > > > > > > On Wed, 19 Dec 2007, Jessica Chen wrote: > > > > > > > > > > > > > Name Type Data > > > > > > > (Default) REG_SZ (value not set) > > > > > > > \Device\Serial0 REG_SZ COM1 > > > > > > > \Device\U2SPORT1 REG_SZ COM7 > > > > > > > > > > > > > > if i used on my computer, i can see: > > > > > > > COM1 > > > > > > > COM1 > > > > > > > > > > > i> > > when i used my .exe on my colleagues computer. > > > > > > > he has 2 serial port and 1 usb->serial. > > > > > > > but we can only see "COM4" for 3 times. > > > > > > > > > > > > > > so at least, the code can recognize how many COM on computer, > > > > whatever > > > > > > real > > > > > > > com port or usb-com. > > > > > > > but cannot read right com port number. > > > > > > > > > > > > > > > > > > > > > On Dec 19, 2007 1:57 PM, Rafael Menezes <so...@gm...> > > wrote: > > > > > > > > > > > > > > > Hi Jessica. > > > > > > > > > > > > > > > > Can you, for start, list what is on > > > > "HARDWARE\\DEVICEMAP\\SERIALCOMM" > > > > > > in > > > > > > > > your computer? > > > > > > > > > > > > > > > > Regards > > > > > > > > Rafael > > > > > > > > > > > > > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm...> wrote: > > > > > > > > > > > > > > > > > > Hi, thanks for ur email, Rafael. > > > > > > > > > > > > > > > > > > I researched myself. > > > > > > > > > I wrote a code. I will list it as follows. > > > > > > > > > The problem seems it can recognize the real serial com port > > (Com > > > > 1 > > > > > > in my > > > > > > > > > computer, registry). > > > > > > > > > But on my computer, I have a USB->serial com port (Com 7 in > > my > > > > > > > > > computer, registry). > > > > > > > > > The code cannot recognize the USB->serial com port. > > > > > > > > > Is there any experienced persons can give any idea about > > that? > > > > > > > > > > > > > > > > > > #include <windows.h> > > > > > > > > > #include <stdio.h> > > > > > > > > > #include <tchar.h> > > > > > > > > > > > > > > > > > > int main(void) > > > > > > > > > { > > > > > > > > > char *strSerialList[256]; > > > > > > > > > HKEY hKey; > > > > > > > > > > > > > > > > > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > > > > > > > > > > > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > > > > > > > > > 0, > > > > > > > > > KEY_READ, > > > > > > > > > &hKey) != ERROR_SUCCESS) > > > > > > > > > { > > > > > > > > > return -1; > > > > > > > > > } > > > > > > > > > > > > > > > > > > int i=0; > > > > > > > > > CHAR Name[25]; > > > > > > > > > UCHAR szPortName[25]; > > > > > > > > > LONG Status; > > > > > > > > > DWORD dwIndex = 0; > > > > > > > > > DWORD dwName; > > > > > > > > > DWORD dwSizeofPortName; > > > > > > > > > DWORD Type; > > > > > > > > > dwName = sizeof(Name); > > > > > > > > > dwSizeofPortName = sizeof(szPortName); > > > > > > > > > > > > > > > > > > do > > > > > > > > > { > > > > > > > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, > > > > NULL, > > > > > > > > > &Type, > > > > > > > > > szPortName, &dwSizeofPortName); > > > > > > > > > if((Status == ERROR_SUCCESS) || (Status == > > > > ERROR_MORE_DATA)) > > > > > > > > > { > > > > > > > > > strSerialList[i] = (char*)(szPortName); > > > > > > > > > i++; > > > > > > > > > } > > > > > > > > > } while((Status == ERROR_SUCCESS) || (Status == > > > > > > ERROR_MORE_DATA)); > > > > > > > > > RegCloseKey(hKey); > > > > > > > > > > > > > > > > > > for(int j=0;j<i;j++) > > > > > > > > > { > > > > > > > > > printf("%s\n",strSerialList[j]); > > > > > > > > > } > > > > > > > > > > > > > > > > > > return 0; > > > > > > > > > } > > > > > > > > > > > > > > > > > > > > > > > > > > > On Dec 19, 2007 12:34 PM, Rafael Menezes <so...@gm...> > > > > wrote: > > > > > > > > > > > > > > > > > > > You can send mails. Can you search on google? > > > > > > > > > > > > > > > > > > > > > > > > http://www.google.com.br/search?hl=pt-BR&q=c%2B%2B+com+port&meta = > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > http://www.google.com.br/search?num=30&hl=pt-BR&q=c%2B%2B+serial+port&meta > > > > > > > > > > = > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm... > > > wrote: > > > > > > > > > > > > > > > > > > > > > is there anyone have the experience for writing code of > > > > getting > > > > > > the > > > > > > > > > > > serial port info from windows? > > > > > > > > > > > can u give me an sample code? > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > > > > > > > > > > > > > > > > > > > SF.Net email is sponsored by: > > > > > > > > > > > Check out the new SourceForge.net Marketplace. > > > > > > > > > > > It's the best place to buy or sell services > > > > > > > > > > > for just about anything Open Source. > > > > > > > > > > > > > > > > > > > > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > > > > > > > > Dev-cpp-users mailing list > > > > > > > > > > > Dev...@li... > > > > > > > > > > > TO UNSUBSCRIBE: > > > > http://www23.brinkster.com/noicys/devcpp/ub.htm > > > > > > > > > > > > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > > > > > Regards > > > > > > > > > > Rafael Menezes > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > > > Regards > > > > > > > > Rafael Menezes > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > |
From: Jessica C. <jes...@gm...> - 2007-12-20 15:02:39
|
yep.. i will change 4096*256=1M part. that is too big for saving serial port info. the function of strdup is equal to strlen() + malloc() + memcpy()? so, i don't need to do memalloc for strSerialList as what i did, since strdup() will do? is this a correct understanding? On Dec 20, 2007 9:23 AM, Per Westermark <pw...@ia...> wrote: > Now, you are preallocating 4096 bytes for 256 serial ports. That is 1MB of > memory. That is not something you want in production code. > > My change with strdup() would have performed a strlen() + an optimum-sized > malloc() + memcpy() for any detected serial ports, i.e. it will end up > needing at the most a couple of hundred bytes of memory for the names. > > /pwm > > On Thu, 20 Dec 2007, Jessica Chen wrote: > > > Hi, Per, > > > > Thanks. I asked my friend to see. He gave me the suggestion. The > > RegEnumValue can recognize the com and USB->COM. The problem solved > now, I > > got the correct result: COM1(com), COM7(usb->com). In front of > > RegEnumValue, add: > > dwName = sizeof(Name); > > dwSizeofPortName = sizeof(szPortName); > > So the whole code is as follows (a bug in it: didn't release memalloc, > but > > doesn't influence the result here). > > > > #include <windows.h> > > #include <stdio.h> > > #include <tchar.h> > > > > int main(void) > > { > > int z; > > char *strSerialList[256]; > > for (z=0; z<=256; z++) > > { > > strSerialList[z] = (char*)malloc(4096*sizeof(char)); > > } > > HKEY hKey; > > > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > > 0, > > KEY_READ, > > &hKey) != ERROR_SUCCESS) > > { > > return -1; > > } > > > > int i=0; > > CHAR Name[4096]; > > UCHAR szPortName[4096]; > > LONG Status; > > DWORD dwIndex = 0; > > DWORD dwName; > > DWORD dwSizeofPortName; > > DWORD Type; > > dwName = sizeof(Name); > > dwSizeofPortName = sizeof(szPortName); > > > > do > > { > > dwName = sizeof(Name); > > dwSizeofPortName = sizeof(szPortName); > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, > &Type, > > szPortName, &dwSizeofPortName); > > printf("Name=%s,szPortName=%s \n", Name, szPortName); > > if((Status == ERROR_SUCCESS) ) > > { > > strcpy(strSerialList[i],(char*)szPortName); > > //strSerialList[i] = (char*) szPortName; > > printf("%s ",strSerialList[i]); > > printf("i=%d,dwIndex=%d\n",i,dwIndex); > > i++; > > } > > } while((Status == ERROR_SUCCESS) ); > > RegCloseKey(hKey); > > > > printf("\n\n"); > > for(int j=0;j<i;j++) > > { > > printf("%s\n",strSerialList[j]); > > } > > > > return 0; > > } > > > > > > > > On Dec 19, 2007 6:02 PM, Per Westermark <pw...@ia...> wrote: > > > > > On an old test machine I have, the original code produces: > > > COM1 > > > COM1 > > > COM1 > > > COM1 > > > COM1 > > > COM1 > > > > > > After adding strdup(), I get: > > > COM5 > > > COM6 > > > COM7 > > > COM7 > > > COM4 > > > COM1 > > > > > > Are you sure that your change was correct, and that you remembered to > > > recompile? > > > > > > One interesting thing here is that COM7 is printed twice, while my > much > > > used COM3 is not enumerated. > > > > > > The two COM7 seems to be a stupid M$ bug with an USB serial adapter :( > > > > > > /pwm > > > > > > On Wed, 19 Dec 2007, Jessica Chen wrote: > > > > > > > Hi, Per, > > > > > > > > for your second method, i modified like this. i doesn't solve the > > > > problem. the result is the same as before. > > > > for the first method, i tried to change strSerialList[i] = > > > > (char*)(szPortName); to strSerialList[i] = > strdup((char*)(szPortName));, > > > but > > > > it seems doesn't work too. :-( > > > > > > > > Regards, > > > > Jessica > > > > > > > > do > > > > { > > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, > > > &Type, > > > > szPortName, &dwSizeofPortName); > > > > if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) > > > > { > > > > strSerialList[i] = (char*)(szPortName); > > > > printf("%s\n",strSerialList[i]); > > > > i++; > > > > } > > > > } while((Status == ERROR_SUCCESS) || (Status == > ERROR_MORE_DATA)); > > > > RegCloseKey(hKey); > > > > > > > > On Dec 19, 2007 2:44 PM, Per Westermark <pw...@ia...> > wrote: > > > > > > > > > The test code is buggy. It uses the same buffer to retrieve the > device > > > > > names, which means that the name will be overwritten. > > > > > > > > > > A quicky (with a memory leak that doesn't matter here) is to do > > > > > strSerialList[i] = strdup((char*)szPortName); > > > > > > > > > > Another alternative is to print the devices one-by-one directly > when > > > they > > > > > are found. > > > > > > > > > > /pwm > > > > > > > > > > On Wed, 19 Dec 2007, Jessica Chen wrote: > > > > > > > > > > > Name Type Data > > > > > > (Default) REG_SZ (value not set) > > > > > > \Device\Serial0 REG_SZ COM1 > > > > > > \Device\U2SPORT1 REG_SZ COM7 > > > > > > > > > > > > if i used on my computer, i can see: > > > > > > COM1 > > > > > > COM1 > > > > > > > > > i> > > when i used my .exe on my colleagues computer. > > > > > > he has 2 serial port and 1 usb->serial. > > > > > > but we can only see "COM4" for 3 times. > > > > > > > > > > > > so at least, the code can recognize how many COM on computer, > > > whatever > > > > > real > > > > > > com port or usb-com. > > > > > > but cannot read right com port number. > > > > > > > > > > > > > > > > > > On Dec 19, 2007 1:57 PM, Rafael Menezes <so...@gm...> > wrote: > > > > > > > > > > > > > Hi Jessica. > > > > > > > > > > > > > > Can you, for start, list what is on > > > "HARDWARE\\DEVICEMAP\\SERIALCOMM" > > > > > in > > > > > > > your computer? > > > > > > > > > > > > > > Regards > > > > > > > Rafael > > > > > > > > > > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm...> wrote: > > > > > > > > > > > > > > > > Hi, thanks for ur email, Rafael. > > > > > > > > > > > > > > > > I researched myself. > > > > > > > > I wrote a code. I will list it as follows. > > > > > > > > The problem seems it can recognize the real serial com port > (Com > > > 1 > > > > > in my > > > > > > > > computer, registry). > > > > > > > > But on my computer, I have a USB->serial com port (Com 7 in > my > > > > > > > > computer, registry). > > > > > > > > The code cannot recognize the USB->serial com port. > > > > > > > > Is there any experienced persons can give any idea about > that? > > > > > > > > > > > > > > > > #include <windows.h> > > > > > > > > #include <stdio.h> > > > > > > > > #include <tchar.h> > > > > > > > > > > > > > > > > int main(void) > > > > > > > > { > > > > > > > > char *strSerialList[256]; > > > > > > > > HKEY hKey; > > > > > > > > > > > > > > > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > > > > > > > > > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > > > > > > > > 0, > > > > > > > > KEY_READ, > > > > > > > > &hKey) != ERROR_SUCCESS) > > > > > > > > { > > > > > > > > return -1; > > > > > > > > } > > > > > > > > > > > > > > > > int i=0; > > > > > > > > CHAR Name[25]; > > > > > > > > UCHAR szPortName[25]; > > > > > > > > LONG Status; > > > > > > > > DWORD dwIndex = 0; > > > > > > > > DWORD dwName; > > > > > > > > DWORD dwSizeofPortName; > > > > > > > > DWORD Type; > > > > > > > > dwName = sizeof(Name); > > > > > > > > dwSizeofPortName = sizeof(szPortName); > > > > > > > > > > > > > > > > do > > > > > > > > { > > > > > > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, > > > NULL, > > > > > > > > &Type, > > > > > > > > szPortName, &dwSizeofPortName); > > > > > > > > if((Status == ERROR_SUCCESS) || (Status == > > > ERROR_MORE_DATA)) > > > > > > > > { > > > > > > > > strSerialList[i] = (char*)(szPortName); > > > > > > > > i++; > > > > > > > > } > > > > > > > > } while((Status == ERROR_SUCCESS) || (Status == > > > > > ERROR_MORE_DATA)); > > > > > > > > RegCloseKey(hKey); > > > > > > > > > > > > > > > > for(int j=0;j<i;j++) > > > > > > > > { > > > > > > > > printf("%s\n",strSerialList[j]); > > > > > > > > } > > > > > > > > > > > > > > > > return 0; > > > > > > > > } > > > > > > > > > > > > > > > > > > > > > > > > On Dec 19, 2007 12:34 PM, Rafael Menezes <so...@gm...> > > > wrote: > > > > > > > > > > > > > > > > > You can send mails. Can you search on google? > > > > > > > > > > > > > > > > > > > > > http://www.google.com.br/search?hl=pt-BR&q=c%2B%2B+com+port&meta = > > > > > > > > > > > > > > > > > > > > > > > > > > > http://www.google.com.br/search?num=30&hl=pt-BR&q=c%2B%2B+serial+port&meta > > > > > > > > > = > > > > > > > > > > > > > > > > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm... > > wrote: > > > > > > > > > > > > > > > > > > > is there anyone have the experience for writing code of > > > getting > > > > > the > > > > > > > > > > serial port info from windows? > > > > > > > > > > can u give me an sample code? > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > > > > > > > > > > > > > > > > > SF.Net email is sponsored by: > > > > > > > > > > Check out the new SourceForge.net Marketplace. > > > > > > > > > > It's the best place to buy or sell services > > > > > > > > > > for just about anything Open Source. > > > > > > > > > > > > > > > > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > > > > > > > Dev-cpp-users mailing list > > > > > > > > > > Dev...@li... > > > > > > > > > > TO UNSUBSCRIBE: > > > http://www23.brinkster.com/noicys/devcpp/ub.htm > > > > > > > > > > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > > > > Regards > > > > > > > > > Rafael Menezes > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > > Regards > > > > > > > Rafael Menezes > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > |
From: Per W. <pw...@ia...> - 2007-12-20 14:23:57
|
Now, you are preallocating 4096 bytes for 256 serial ports. That is 1MB of memory. That is not something you want in production code. My change with strdup() would have performed a strlen() + an optimum-sized malloc() + memcpy() for any detected serial ports, i.e. it will end up needing at the most a couple of hundred bytes of memory for the names. /pwm On Thu, 20 Dec 2007, Jessica Chen wrote: > Hi, Per, > > Thanks. I asked my friend to see. He gave me the suggestion. The > RegEnumValue can recognize the com and USB->COM. The problem solved now, I > got the correct result: COM1(com), COM7(usb->com). In front of > RegEnumValue, add: > dwName = sizeof(Name); > dwSizeofPortName = sizeof(szPortName); > So the whole code is as follows (a bug in it: didn't release memalloc, but > doesn't influence the result here). > > #include <windows.h> > #include <stdio.h> > #include <tchar.h> > > int main(void) > { > int z; > char *strSerialList[256]; > for (z=0; z<=256; z++) > { > strSerialList[z] = (char*)malloc(4096*sizeof(char)); > } > HKEY hKey; > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > 0, > KEY_READ, > &hKey) != ERROR_SUCCESS) > { > return -1; > } > > int i=0; > CHAR Name[4096]; > UCHAR szPortName[4096]; > LONG Status; > DWORD dwIndex = 0; > DWORD dwName; > DWORD dwSizeofPortName; > DWORD Type; > dwName = sizeof(Name); > dwSizeofPortName = sizeof(szPortName); > > do > { > dwName = sizeof(Name); > dwSizeofPortName = sizeof(szPortName); > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, &Type, > szPortName, &dwSizeofPortName); > printf("Name=%s,szPortName=%s \n", Name, szPortName); > if((Status == ERROR_SUCCESS) ) > { > strcpy(strSerialList[i],(char*)szPortName); > //strSerialList[i] = (char*) szPortName; > printf("%s ",strSerialList[i]); > printf("i=%d,dwIndex=%d\n",i,dwIndex); > i++; > } > } while((Status == ERROR_SUCCESS) ); > RegCloseKey(hKey); > > printf("\n\n"); > for(int j=0;j<i;j++) > { > printf("%s\n",strSerialList[j]); > } > > return 0; > } > > > > On Dec 19, 2007 6:02 PM, Per Westermark <pw...@ia...> wrote: > > > On an old test machine I have, the original code produces: > > COM1 > > COM1 > > COM1 > > COM1 > > COM1 > > COM1 > > > > After adding strdup(), I get: > > COM5 > > COM6 > > COM7 > > COM7 > > COM4 > > COM1 > > > > Are you sure that your change was correct, and that you remembered to > > recompile? > > > > One interesting thing here is that COM7 is printed twice, while my much > > used COM3 is not enumerated. > > > > The two COM7 seems to be a stupid M$ bug with an USB serial adapter :( > > > > /pwm > > > > On Wed, 19 Dec 2007, Jessica Chen wrote: > > > > > Hi, Per, > > > > > > for your second method, i modified like this. i doesn't solve the > > > problem. the result is the same as before. > > > for the first method, i tried to change strSerialList[i] = > > > (char*)(szPortName); to strSerialList[i] = strdup((char*)(szPortName));, > > but > > > it seems doesn't work too. :-( > > > > > > Regards, > > > Jessica > > > > > > do > > > { > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, > > &Type, > > > szPortName, &dwSizeofPortName); > > > if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) > > > { > > > strSerialList[i] = (char*)(szPortName); > > > printf("%s\n",strSerialList[i]); > > > i++; > > > } > > > } while((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)); > > > RegCloseKey(hKey); > > > > > > On Dec 19, 2007 2:44 PM, Per Westermark <pw...@ia...> wrote: > > > > > > > The test code is buggy. It uses the same buffer to retrieve the device > > > > names, which means that the name will be overwritten. > > > > > > > > A quicky (with a memory leak that doesn't matter here) is to do > > > > strSerialList[i] = strdup((char*)szPortName); > > > > > > > > Another alternative is to print the devices one-by-one directly when > > they > > > > are found. > > > > > > > > /pwm > > > > > > > > On Wed, 19 Dec 2007, Jessica Chen wrote: > > > > > > > > > Name Type Data > > > > > (Default) REG_SZ (value not set) > > > > > \Device\Serial0 REG_SZ COM1 > > > > > \Device\U2SPORT1 REG_SZ COM7 > > > > > > > > > > if i used on my computer, i can see: > > > > > COM1 > > > > > COM1 > > > > > > > i> > > when i used my .exe on my colleagues computer. > > > > > he has 2 serial port and 1 usb->serial. > > > > > but we can only see "COM4" for 3 times. > > > > > > > > > > so at least, the code can recognize how many COM on computer, > > whatever > > > > real > > > > > com port or usb-com. > > > > > but cannot read right com port number. > > > > > > > > > > > > > > > On Dec 19, 2007 1:57 PM, Rafael Menezes <so...@gm...> wrote: > > > > > > > > > > > Hi Jessica. > > > > > > > > > > > > Can you, for start, list what is on > > "HARDWARE\\DEVICEMAP\\SERIALCOMM" > > > > in > > > > > > your computer? > > > > > > > > > > > > Regards > > > > > > Rafael > > > > > > > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm...> wrote: > > > > > > > > > > > > > > Hi, thanks for ur email, Rafael. > > > > > > > > > > > > > > I researched myself. > > > > > > > I wrote a code. I will list it as follows. > > > > > > > The problem seems it can recognize the real serial com port (Com > > 1 > > > > in my > > > > > > > computer, registry). > > > > > > > But on my computer, I have a USB->serial com port (Com 7 in my > > > > > > > computer, registry). > > > > > > > The code cannot recognize the USB->serial com port. > > > > > > > Is there any experienced persons can give any idea about that? > > > > > > > > > > > > > > #include <windows.h> > > > > > > > #include <stdio.h> > > > > > > > #include <tchar.h> > > > > > > > > > > > > > > int main(void) > > > > > > > { > > > > > > > char *strSerialList[256]; > > > > > > > HKEY hKey; > > > > > > > > > > > > > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > > > > > > > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > > > > > > > 0, > > > > > > > KEY_READ, > > > > > > > &hKey) != ERROR_SUCCESS) > > > > > > > { > > > > > > > return -1; > > > > > > > } > > > > > > > > > > > > > > int i=0; > > > > > > > CHAR Name[25]; > > > > > > > UCHAR szPortName[25]; > > > > > > > LONG Status; > > > > > > > DWORD dwIndex = 0; > > > > > > > DWORD dwName; > > > > > > > DWORD dwSizeofPortName; > > > > > > > DWORD Type; > > > > > > > dwName = sizeof(Name); > > > > > > > dwSizeofPortName = sizeof(szPortName); > > > > > > > > > > > > > > do > > > > > > > { > > > > > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, > > NULL, > > > > > > > &Type, > > > > > > > szPortName, &dwSizeofPortName); > > > > > > > if((Status == ERROR_SUCCESS) || (Status == > > ERROR_MORE_DATA)) > > > > > > > { > > > > > > > strSerialList[i] = (char*)(szPortName); > > > > > > > i++; > > > > > > > } > > > > > > > } while((Status == ERROR_SUCCESS) || (Status == > > > > ERROR_MORE_DATA)); > > > > > > > RegCloseKey(hKey); > > > > > > > > > > > > > > for(int j=0;j<i;j++) > > > > > > > { > > > > > > > printf("%s\n",strSerialList[j]); > > > > > > > } > > > > > > > > > > > > > > return 0; > > > > > > > } > > > > > > > > > > > > > > > > > > > > > On Dec 19, 2007 12:34 PM, Rafael Menezes <so...@gm...> > > wrote: > > > > > > > > > > > > > > > You can send mails. Can you search on google? > > > > > > > > > > > > > > > > > > http://www.google.com.br/search?hl=pt-BR&q=c%2B%2B+com+port&meta = > > > > > > > > > > > > > > > > > > > > > > http://www.google.com.br/search?num=30&hl=pt-BR&q=c%2B%2B+serial+port&meta > > > > > > > > = > > > > > > > > > > > > > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm... > wrote: > > > > > > > > > > > > > > > > > is there anyone have the experience for writing code of > > getting > > > > the > > > > > > > > > serial port info from windows? > > > > > > > > > can u give me an sample code? > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > > > > > > > > > > > > > > > SF.Net email is sponsored by: > > > > > > > > > Check out the new SourceForge.net Marketplace. > > > > > > > > > It's the best place to buy or sell services > > > > > > > > > for just about anything Open Source. > > > > > > > > > > > > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > > > > > > Dev-cpp-users mailing list > > > > > > > > > Dev...@li... > > > > > > > > > TO UNSUBSCRIBE: > > http://www23.brinkster.com/noicys/devcpp/ub.htm > > > > > > > > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > > > Regards > > > > > > > > Rafael Menezes > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > Regards > > > > > > Rafael Menezes > > > > > > > > > > > > > > > > > > > > > |
From: Jessica C. <jes...@gm...> - 2007-12-20 14:04:17
|
Hi, Per, Thanks. I asked my friend to see. He gave me the suggestion. The RegEnumValue can recognize the com and USB->COM. The problem solved now, I got the correct result: COM1(com), COM7(usb->com). In front of RegEnumValue, add: dwName = sizeof(Name); dwSizeofPortName = sizeof(szPortName); So the whole code is as follows (a bug in it: didn't release memalloc, but doesn't influence the result here). #include <windows.h> #include <stdio.h> #include <tchar.h> int main(void) { int z; char *strSerialList[256]; for (z=0; z<=256; z++) { strSerialList[z] = (char*)malloc(4096*sizeof(char)); } HKEY hKey; if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), 0, KEY_READ, &hKey) != ERROR_SUCCESS) { return -1; } int i=0; CHAR Name[4096]; UCHAR szPortName[4096]; LONG Status; DWORD dwIndex = 0; DWORD dwName; DWORD dwSizeofPortName; DWORD Type; dwName = sizeof(Name); dwSizeofPortName = sizeof(szPortName); do { dwName = sizeof(Name); dwSizeofPortName = sizeof(szPortName); Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, &Type, szPortName, &dwSizeofPortName); printf("Name=%s,szPortName=%s \n", Name, szPortName); if((Status == ERROR_SUCCESS) ) { strcpy(strSerialList[i],(char*)szPortName); //strSerialList[i] = (char*) szPortName; printf("%s ",strSerialList[i]); printf("i=%d,dwIndex=%d\n",i,dwIndex); i++; } } while((Status == ERROR_SUCCESS) ); RegCloseKey(hKey); printf("\n\n"); for(int j=0;j<i;j++) { printf("%s\n",strSerialList[j]); } return 0; } On Dec 19, 2007 6:02 PM, Per Westermark <pw...@ia...> wrote: > On an old test machine I have, the original code produces: > COM1 > COM1 > COM1 > COM1 > COM1 > COM1 > > After adding strdup(), I get: > COM5 > COM6 > COM7 > COM7 > COM4 > COM1 > > Are you sure that your change was correct, and that you remembered to > recompile? > > One interesting thing here is that COM7 is printed twice, while my much > used COM3 is not enumerated. > > The two COM7 seems to be a stupid M$ bug with an USB serial adapter :( > > /pwm > > On Wed, 19 Dec 2007, Jessica Chen wrote: > > > Hi, Per, > > > > for your second method, i modified like this. i doesn't solve the > > problem. the result is the same as before. > > for the first method, i tried to change strSerialList[i] = > > (char*)(szPortName); to strSerialList[i] = strdup((char*)(szPortName));, > but > > it seems doesn't work too. :-( > > > > Regards, > > Jessica > > > > do > > { > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, > &Type, > > szPortName, &dwSizeofPortName); > > if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) > > { > > strSerialList[i] = (char*)(szPortName); > > printf("%s\n",strSerialList[i]); > > i++; > > } > > } while((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)); > > RegCloseKey(hKey); > > > > On Dec 19, 2007 2:44 PM, Per Westermark <pw...@ia...> wrote: > > > > > The test code is buggy. It uses the same buffer to retrieve the device > > > names, which means that the name will be overwritten. > > > > > > A quicky (with a memory leak that doesn't matter here) is to do > > > strSerialList[i] = strdup((char*)szPortName); > > > > > > Another alternative is to print the devices one-by-one directly when > they > > > are found. > > > > > > /pwm > > > > > > On Wed, 19 Dec 2007, Jessica Chen wrote: > > > > > > > Name Type Data > > > > (Default) REG_SZ (value not set) > > > > \Device\Serial0 REG_SZ COM1 > > > > \Device\U2SPORT1 REG_SZ COM7 > > > > > > > > if i used on my computer, i can see: > > > > COM1 > > > > COM1 > > > > > i> > > when i used my .exe on my colleagues computer. > > > > he has 2 serial port and 1 usb->serial. > > > > but we can only see "COM4" for 3 times. > > > > > > > > so at least, the code can recognize how many COM on computer, > whatever > > > real > > > > com port or usb-com. > > > > but cannot read right com port number. > > > > > > > > > > > > On Dec 19, 2007 1:57 PM, Rafael Menezes <so...@gm...> wrote: > > > > > > > > > Hi Jessica. > > > > > > > > > > Can you, for start, list what is on > "HARDWARE\\DEVICEMAP\\SERIALCOMM" > > > in > > > > > your computer? > > > > > > > > > > Regards > > > > > Rafael > > > > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm...> wrote: > > > > > > > > > > > > Hi, thanks for ur email, Rafael. > > > > > > > > > > > > I researched myself. > > > > > > I wrote a code. I will list it as follows. > > > > > > The problem seems it can recognize the real serial com port (Com > 1 > > > in my > > > > > > computer, registry). > > > > > > But on my computer, I have a USB->serial com port (Com 7 in my > > > > > > computer, registry). > > > > > > The code cannot recognize the USB->serial com port. > > > > > > Is there any experienced persons can give any idea about that? > > > > > > > > > > > > #include <windows.h> > > > > > > #include <stdio.h> > > > > > > #include <tchar.h> > > > > > > > > > > > > int main(void) > > > > > > { > > > > > > char *strSerialList[256]; > > > > > > HKEY hKey; > > > > > > > > > > > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > > > > > > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > > > > > > 0, > > > > > > KEY_READ, > > > > > > &hKey) != ERROR_SUCCESS) > > > > > > { > > > > > > return -1; > > > > > > } > > > > > > > > > > > > int i=0; > > > > > > CHAR Name[25]; > > > > > > UCHAR szPortName[25]; > > > > > > LONG Status; > > > > > > DWORD dwIndex = 0; > > > > > > DWORD dwName; > > > > > > DWORD dwSizeofPortName; > > > > > > DWORD Type; > > > > > > dwName = sizeof(Name); > > > > > > dwSizeofPortName = sizeof(szPortName); > > > > > > > > > > > > do > > > > > > { > > > > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, > NULL, > > > > > > &Type, > > > > > > szPortName, &dwSizeofPortName); > > > > > > if((Status == ERROR_SUCCESS) || (Status == > ERROR_MORE_DATA)) > > > > > > { > > > > > > strSerialList[i] = (char*)(szPortName); > > > > > > i++; > > > > > > } > > > > > > } while((Status == ERROR_SUCCESS) || (Status == > > > ERROR_MORE_DATA)); > > > > > > RegCloseKey(hKey); > > > > > > > > > > > > for(int j=0;j<i;j++) > > > > > > { > > > > > > printf("%s\n",strSerialList[j]); > > > > > > } > > > > > > > > > > > > return 0; > > > > > > } > > > > > > > > > > > > > > > > > > On Dec 19, 2007 12:34 PM, Rafael Menezes <so...@gm...> > wrote: > > > > > > > > > > > > > You can send mails. Can you search on google? > > > > > > > > > > > > > > > http://www.google.com.br/search?hl=pt-BR&q=c%2B%2B+com+port&meta = > > > > > > > > > > > > > > > > > > http://www.google.com.br/search?num=30&hl=pt-BR&q=c%2B%2B+serial+port&meta > > > > > > > = > > > > > > > > > > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm... > wrote: > > > > > > > > > > > > > > > is there anyone have the experience for writing code of > getting > > > the > > > > > > > > serial port info from windows? > > > > > > > > can u give me an sample code? > > > > > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > > > > > > > > > > > > > SF.Net email is sponsored by: > > > > > > > > Check out the new SourceForge.net Marketplace. > > > > > > > > It's the best place to buy or sell services > > > > > > > > for just about anything Open Source. > > > > > > > > > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > > > > > > > > > > > > > > > _______________________________________________ > > > > > > > > Dev-cpp-users mailing list > > > > > > > > Dev...@li... > > > > > > > > TO UNSUBSCRIBE: > http://www23.brinkster.com/noicys/devcpp/ub.htm > > > > > > > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > > Regards > > > > > > > Rafael Menezes > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > Regards > > > > > Rafael Menezes > > > > > > > > > > > > > > |
From: Per W. <pw...@ia...> - 2007-12-19 23:02:28
|
On an old test machine I have, the original code produces: COM1 COM1 COM1 COM1 COM1 COM1 After adding strdup(), I get: COM5 COM6 COM7 COM7 COM4 COM1 Are you sure that your change was correct, and that you remembered to recompile? One interesting thing here is that COM7 is printed twice, while my much used COM3 is not enumerated. The two COM7 seems to be a stupid M$ bug with an USB serial adapter :( /pwm On Wed, 19 Dec 2007, Jessica Chen wrote: > Hi, Per, > > for your second method, i modified like this. i doesn't solve the > problem. the result is the same as before. > for the first method, i tried to change strSerialList[i] = > (char*)(szPortName); to strSerialList[i] = strdup((char*)(szPortName));, but > it seems doesn't work too. :-( > > Regards, > Jessica > > do > { > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, &Type, > szPortName, &dwSizeofPortName); > if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) > { > strSerialList[i] = (char*)(szPortName); > printf("%s\n",strSerialList[i]); > i++; > } > } while((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)); > RegCloseKey(hKey); > > On Dec 19, 2007 2:44 PM, Per Westermark <pw...@ia...> wrote: > > > The test code is buggy. It uses the same buffer to retrieve the device > > names, which means that the name will be overwritten. > > > > A quicky (with a memory leak that doesn't matter here) is to do > > strSerialList[i] = strdup((char*)szPortName); > > > > Another alternative is to print the devices one-by-one directly when they > > are found. > > > > /pwm > > > > On Wed, 19 Dec 2007, Jessica Chen wrote: > > > > > Name Type Data > > > (Default) REG_SZ (value not set) > > > \Device\Serial0 REG_SZ COM1 > > > \Device\U2SPORT1 REG_SZ COM7 > > > > > > if i used on my computer, i can see: > > > COM1 > > > COM1 > > > i> > > when i used my .exe on my colleagues computer. > > > he has 2 serial port and 1 usb->serial. > > > but we can only see "COM4" for 3 times. > > > > > > so at least, the code can recognize how many COM on computer, whatever > > real > > > com port or usb-com. > > > but cannot read right com port number. > > > > > > > > > On Dec 19, 2007 1:57 PM, Rafael Menezes <so...@gm...> wrote: > > > > > > > Hi Jessica. > > > > > > > > Can you, for start, list what is on "HARDWARE\\DEVICEMAP\\SERIALCOMM" > > in > > > > your computer? > > > > > > > > Regards > > > > Rafael > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm...> wrote: > > > > > > > > > > Hi, thanks for ur email, Rafael. > > > > > > > > > > I researched myself. > > > > > I wrote a code. I will list it as follows. > > > > > The problem seems it can recognize the real serial com port (Com 1 > > in my > > > > > computer, registry). > > > > > But on my computer, I have a USB->serial com port (Com 7 in my > > > > > computer, registry). > > > > > The code cannot recognize the USB->serial com port. > > > > > Is there any experienced persons can give any idea about that? > > > > > > > > > > #include <windows.h> > > > > > #include <stdio.h> > > > > > #include <tchar.h> > > > > > > > > > > int main(void) > > > > > { > > > > > char *strSerialList[256]; > > > > > HKEY hKey; > > > > > > > > > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > > > > > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > > > > > 0, > > > > > KEY_READ, > > > > > &hKey) != ERROR_SUCCESS) > > > > > { > > > > > return -1; > > > > > } > > > > > > > > > > int i=0; > > > > > CHAR Name[25]; > > > > > UCHAR szPortName[25]; > > > > > LONG Status; > > > > > DWORD dwIndex = 0; > > > > > DWORD dwName; > > > > > DWORD dwSizeofPortName; > > > > > DWORD Type; > > > > > dwName = sizeof(Name); > > > > > dwSizeofPortName = sizeof(szPortName); > > > > > > > > > > do > > > > > { > > > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, > > > > > &Type, > > > > > szPortName, &dwSizeofPortName); > > > > > if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) > > > > > { > > > > > strSerialList[i] = (char*)(szPortName); > > > > > i++; > > > > > } > > > > > } while((Status == ERROR_SUCCESS) || (Status == > > ERROR_MORE_DATA)); > > > > > RegCloseKey(hKey); > > > > > > > > > > for(int j=0;j<i;j++) > > > > > { > > > > > printf("%s\n",strSerialList[j]); > > > > > } > > > > > > > > > > return 0; > > > > > } > > > > > > > > > > > > > > > On Dec 19, 2007 12:34 PM, Rafael Menezes <so...@gm...> wrote: > > > > > > > > > > > You can send mails. Can you search on google? > > > > > > > > > > > > http://www.google.com.br/search?hl=pt-BR&q=c%2B%2B+com+port&meta = > > > > > > > > > > > > > > http://www.google.com.br/search?num=30&hl=pt-BR&q=c%2B%2B+serial+port&meta > > > > > > = > > > > > > > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm... > wrote: > > > > > > > > > > > > > is there anyone have the experience for writing code of getting > > the > > > > > > > serial port info from windows? > > > > > > > can u give me an sample code? > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > > > > > > > > > > > SF.Net email is sponsored by: > > > > > > > Check out the new SourceForge.net Marketplace. > > > > > > > It's the best place to buy or sell services > > > > > > > for just about anything Open Source. > > > > > > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > > > > > > > > > > > > > _______________________________________________ > > > > > > > Dev-cpp-users mailing list > > > > > > > Dev...@li... > > > > > > > TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm > > > > > > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > Regards > > > > > > Rafael Menezes > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > Regards > > > > Rafael Menezes > > > > > > > > |
From: Jessica C. <jes...@gm...> - 2007-12-19 20:10:48
|
Hi, Per, for your second method, i modified like this. i doesn't solve the problem. the result is the same as before. for the first method, i tried to change strSerialList[i] = (char*)(szPortName); to strSerialList[i] = strdup((char*)(szPortName));, but it seems doesn't work too. :-( Regards, Jessica do { Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, &Type, szPortName, &dwSizeofPortName); if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) { strSerialList[i] = (char*)(szPortName); printf("%s\n",strSerialList[i]); i++; } } while((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)); RegCloseKey(hKey); On Dec 19, 2007 2:44 PM, Per Westermark <pw...@ia...> wrote: > The test code is buggy. It uses the same buffer to retrieve the device > names, which means that the name will be overwritten. > > A quicky (with a memory leak that doesn't matter here) is to do > strSerialList[i] = strdup((char*)szPortName); > > Another alternative is to print the devices one-by-one directly when they > are found. > > /pwm > > On Wed, 19 Dec 2007, Jessica Chen wrote: > > > Name Type Data > > (Default) REG_SZ (value not set) > > \Device\Serial0 REG_SZ COM1 > > \Device\U2SPORT1 REG_SZ COM7 > > > > if i used on my computer, i can see: > > COM1 > > COM1 > > > > when i used my .exe on my colleagues computer. > > he has 2 serial port and 1 usb->serial. > > but we can only see "COM4" for 3 times. > > > > so at least, the code can recognize how many COM on computer, whatever > real > > com port or usb-com. > > but cannot read right com port number. > > > > > > On Dec 19, 2007 1:57 PM, Rafael Menezes <so...@gm...> wrote: > > > > > Hi Jessica. > > > > > > Can you, for start, list what is on "HARDWARE\\DEVICEMAP\\SERIALCOMM" > in > > > your computer? > > > > > > Regards > > > Rafael > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm...> wrote: > > > > > > > > Hi, thanks for ur email, Rafael. > > > > > > > > I researched myself. > > > > I wrote a code. I will list it as follows. > > > > The problem seems it can recognize the real serial com port (Com 1 > in my > > > > computer, registry). > > > > But on my computer, I have a USB->serial com port (Com 7 in my > > > > computer, registry). > > > > The code cannot recognize the USB->serial com port. > > > > Is there any experienced persons can give any idea about that? > > > > > > > > #include <windows.h> > > > > #include <stdio.h> > > > > #include <tchar.h> > > > > > > > > int main(void) > > > > { > > > > char *strSerialList[256]; > > > > HKEY hKey; > > > > > > > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > > > > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > > > > 0, > > > > KEY_READ, > > > > &hKey) != ERROR_SUCCESS) > > > > { > > > > return -1; > > > > } > > > > > > > > int i=0; > > > > CHAR Name[25]; > > > > UCHAR szPortName[25]; > > > > LONG Status; > > > > DWORD dwIndex = 0; > > > > DWORD dwName; > > > > DWORD dwSizeofPortName; > > > > DWORD Type; > > > > dwName = sizeof(Name); > > > > dwSizeofPortName = sizeof(szPortName); > > > > > > > > do > > > > { > > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, > > > > &Type, > > > > szPortName, &dwSizeofPortName); > > > > if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) > > > > { > > > > strSerialList[i] = (char*)(szPortName); > > > > i++; > > > > } > > > > } while((Status == ERROR_SUCCESS) || (Status == > ERROR_MORE_DATA)); > > > > RegCloseKey(hKey); > > > > > > > > for(int j=0;j<i;j++) > > > > { > > > > printf("%s\n",strSerialList[j]); > > > > } > > > > > > > > return 0; > > > > } > > > > > > > > > > > > On Dec 19, 2007 12:34 PM, Rafael Menezes <so...@gm...> wrote: > > > > > > > > > You can send mails. Can you search on google? > > > > > > > > > > http://www.google.com.br/search?hl=pt-BR&q=c%2B%2B+com+port&meta = > > > > > > > > > > > http://www.google.com.br/search?num=30&hl=pt-BR&q=c%2B%2B+serial+port&meta > > > > > = > > > > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm... > wrote: > > > > > > > > > > > is there anyone have the experience for writing code of getting > the > > > > > > serial port info from windows? > > > > > > can u give me an sample code? > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > > > > > > > > > SF.Net email is sponsored by: > > > > > > Check out the new SourceForge.net Marketplace. > > > > > > It's the best place to buy or sell services > > > > > > for just about anything Open Source. > > > > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > > > > > > > > > > > _______________________________________________ > > > > > > Dev-cpp-users mailing list > > > > > > Dev...@li... > > > > > > TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm > > > > > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > Regards > > > > > Rafael Menezes > > > > > > > > > > > > > > > > > > > > > -- > > > Regards > > > Rafael Menezes > > > > |
From: Per W. <pw...@ia...> - 2007-12-19 19:44:38
|
The test code is buggy. It uses the same buffer to retrieve the device names, which means that the name will be overwritten. A quicky (with a memory leak that doesn't matter here) is to do strSerialList[i] = strdup((char*)szPortName); Another alternative is to print the devices one-by-one directly when they are found. /pwm On Wed, 19 Dec 2007, Jessica Chen wrote: > Name Type Data > (Default) REG_SZ (value not set) > \Device\Serial0 REG_SZ COM1 > \Device\U2SPORT1 REG_SZ COM7 > > if i used on my computer, i can see: > COM1 > COM1 > > when i used my .exe on my colleagues computer. > he has 2 serial port and 1 usb->serial. > but we can only see "COM4" for 3 times. > > so at least, the code can recognize how many COM on computer, whatever real > com port or usb-com. > but cannot read right com port number. > > > On Dec 19, 2007 1:57 PM, Rafael Menezes <so...@gm...> wrote: > > > Hi Jessica. > > > > Can you, for start, list what is on "HARDWARE\\DEVICEMAP\\SERIALCOMM" in > > your computer? > > > > Regards > > Rafael > > > > > > On 19/12/2007, Jessica Chen <jes...@gm...> wrote: > > > > > > Hi, thanks for ur email, Rafael. > > > > > > I researched myself. > > > I wrote a code. I will list it as follows. > > > The problem seems it can recognize the real serial com port (Com 1 in my > > > computer, registry). > > > But on my computer, I have a USB->serial com port (Com 7 in my > > > computer, registry). > > > The code cannot recognize the USB->serial com port. > > > Is there any experienced persons can give any idea about that? > > > > > > #include <windows.h> > > > #include <stdio.h> > > > #include <tchar.h> > > > > > > int main(void) > > > { > > > char *strSerialList[256]; > > > HKEY hKey; > > > > > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > > > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > > > 0, > > > KEY_READ, > > > &hKey) != ERROR_SUCCESS) > > > { > > > return -1; > > > } > > > > > > int i=0; > > > CHAR Name[25]; > > > UCHAR szPortName[25]; > > > LONG Status; > > > DWORD dwIndex = 0; > > > DWORD dwName; > > > DWORD dwSizeofPortName; > > > DWORD Type; > > > dwName = sizeof(Name); > > > dwSizeofPortName = sizeof(szPortName); > > > > > > do > > > { > > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, > > > &Type, > > > szPortName, &dwSizeofPortName); > > > if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) > > > { > > > strSerialList[i] = (char*)(szPortName); > > > i++; > > > } > > > } while((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)); > > > RegCloseKey(hKey); > > > > > > for(int j=0;j<i;j++) > > > { > > > printf("%s\n",strSerialList[j]); > > > } > > > > > > return 0; > > > } > > > > > > > > > On Dec 19, 2007 12:34 PM, Rafael Menezes <so...@gm...> wrote: > > > > > > > You can send mails. Can you search on google? > > > > > > > > http://www.google.com.br/search?hl=pt-BR&q=c%2B%2B+com+port&meta = > > > > > > > > http://www.google.com.br/search?num=30&hl=pt-BR&q=c%2B%2B+serial+port&meta > > > > = > > > > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm... > wrote: > > > > > > > > > is there anyone have the experience for writing code of getting the > > > > > serial port info from windows? > > > > > can u give me an sample code? > > > > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > > > > > > > SF.Net email is sponsored by: > > > > > Check out the new SourceForge.net Marketplace. > > > > > It's the best place to buy or sell services > > > > > for just about anything Open Source. > > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > > > > > > > > > _______________________________________________ > > > > > Dev-cpp-users mailing list > > > > > Dev...@li... > > > > > TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm > > > > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > > > > > > > > > > > > > > > > > > > -- > > > > Regards > > > > Rafael Menezes > > > > > > > > > > > > > > > -- > > Regards > > Rafael Menezes > |
From: Jessica C. <jes...@gm...> - 2007-12-19 19:18:38
|
Name Type Data (Default) REG_SZ (value not set) \Device\Serial0 REG_SZ COM1 \Device\U2SPORT1 REG_SZ COM7 if i used on my computer, i can see: COM1 COM1 when i used my .exe on my colleagues computer. he has 2 serial port and 1 usb->serial. but we can only see "COM4" for 3 times. so at least, the code can recognize how many COM on computer, whatever real com port or usb-com. but cannot read right com port number. On Dec 19, 2007 1:57 PM, Rafael Menezes <so...@gm...> wrote: > Hi Jessica. > > Can you, for start, list what is on "HARDWARE\\DEVICEMAP\\SERIALCOMM" in > your computer? > > Regards > Rafael > > > On 19/12/2007, Jessica Chen <jes...@gm...> wrote: > > > > Hi, thanks for ur email, Rafael. > > > > I researched myself. > > I wrote a code. I will list it as follows. > > The problem seems it can recognize the real serial com port (Com 1 in my > > computer, registry). > > But on my computer, I have a USB->serial com port (Com 7 in my > > computer, registry). > > The code cannot recognize the USB->serial com port. > > Is there any experienced persons can give any idea about that? > > > > #include <windows.h> > > #include <stdio.h> > > #include <tchar.h> > > > > int main(void) > > { > > char *strSerialList[256]; > > HKEY hKey; > > > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > > 0, > > KEY_READ, > > &hKey) != ERROR_SUCCESS) > > { > > return -1; > > } > > > > int i=0; > > CHAR Name[25]; > > UCHAR szPortName[25]; > > LONG Status; > > DWORD dwIndex = 0; > > DWORD dwName; > > DWORD dwSizeofPortName; > > DWORD Type; > > dwName = sizeof(Name); > > dwSizeofPortName = sizeof(szPortName); > > > > do > > { > > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, > > &Type, > > szPortName, &dwSizeofPortName); > > if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) > > { > > strSerialList[i] = (char*)(szPortName); > > i++; > > } > > } while((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)); > > RegCloseKey(hKey); > > > > for(int j=0;j<i;j++) > > { > > printf("%s\n",strSerialList[j]); > > } > > > > return 0; > > } > > > > > > On Dec 19, 2007 12:34 PM, Rafael Menezes <so...@gm...> wrote: > > > > > You can send mails. Can you search on google? > > > > > > http://www.google.com.br/search?hl=pt-BR&q=c%2B%2B+com+port&meta = > > > > > > http://www.google.com.br/search?num=30&hl=pt-BR&q=c%2B%2B+serial+port&meta > > > = > > > > > > > > > On 19/12/2007, Jessica Chen <jes...@gm... > wrote: > > > > > > > is there anyone have the experience for writing code of getting the > > > > serial port info from windows? > > > > can u give me an sample code? > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > > > > > SF.Net email is sponsored by: > > > > Check out the new SourceForge.net Marketplace. > > > > It's the best place to buy or sell services > > > > for just about anything Open Source. > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > > > > > > > _______________________________________________ > > > > Dev-cpp-users mailing list > > > > Dev...@li... > > > > TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm > > > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > > > > > > > > > > > > > > -- > > > Regards > > > Rafael Menezes > > > > > > > > > -- > Regards > Rafael Menezes |
From: Rafael M. <so...@gm...> - 2007-12-19 18:57:56
|
Hi Jessica. Can you, for start, list what is on "HARDWARE\\DEVICEMAP\\SERIALCOMM" in your computer? Regards Rafael On 19/12/2007, Jessica Chen <jes...@gm...> wrote: > > Hi, thanks for ur email, Rafael. > > I researched myself. > I wrote a code. I will list it as follows. > The problem seems it can recognize the real serial com port (Com 1 in my > computer, registry). > But on my computer, I have a USB->serial com port (Com 7 in my computer, > registry). > The code cannot recognize the USB->serial com port. > Is there any experienced persons can give any idea about that? > > #include <windows.h> > #include <stdio.h> > #include <tchar.h> > > int main(void) > { > char *strSerialList[256]; > HKEY hKey; > > if( RegOpenKeyEx(HKEY_LOCAL_MACHINE, > TEXT("HARDWARE\\DEVICEMAP\\SERIALCOMM"), > 0, > KEY_READ, > &hKey) != ERROR_SUCCESS) > { > return -1; > } > > int i=0; > CHAR Name[25]; > UCHAR szPortName[25]; > LONG Status; > DWORD dwIndex = 0; > DWORD dwName; > DWORD dwSizeofPortName; > DWORD Type; > dwName = sizeof(Name); > dwSizeofPortName = sizeof(szPortName); > > do > { > Status = RegEnumValue(hKey, dwIndex++, Name, &dwName, NULL, &Type, > szPortName, &dwSizeofPortName); > if((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)) > { > strSerialList[i] = (char*)(szPortName); > i++; > } > } while((Status == ERROR_SUCCESS) || (Status == ERROR_MORE_DATA)); > RegCloseKey(hKey); > > for(int j=0;j<i;j++) > { > printf("%s\n",strSerialList[j]); > } > > return 0; > } > > > On Dec 19, 2007 12:34 PM, Rafael Menezes <so...@gm...> wrote: > > > You can send mails. Can you search on google? > > > > http://www.google.com.br/search?hl=pt-BR&q=c%2B%2B+com+port&meta= > > > > > > http://www.google.com.br/search?num=30&hl=pt-BR&q=c%2B%2B+serial+port&meta > > = > > > > > > On 19/12/2007, Jessica Chen <jes...@gm...> wrote: > > > > > is there anyone have the experience for writing code of getting the > > > serial port info from windows? > > > can u give me an sample code? > > > > > > > > > > > > ------------------------------------------------------------------------- > > > SF.Net email is sponsored by: > > > Check out the new SourceForge.net Marketplace. > > > It's the best place to buy or sell services > > > for just about anything Open Source. > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > > > > > _______________________________________________ > > > Dev-cpp-users mailing list > > > Dev...@li... > > > TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm > > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > > > > > > > > > -- > > Regards > > Rafael Menezes > > > -- Regards Rafael Menezes |
From: Jessica C. <jes...@gm...> - 2007-12-19 15:54:14
|
is there anyone have the experience for writing code of getting the serial port info from windows? can u give me an sample code? |
From: Per W. <pw...@ia...> - 2007-12-19 15:26:04
|
But I do have the answer. But I think you would have it too, if you look at the header file where the WM_CLOSE message is defined. You will find a huge number of other messages that you really want to know about, and a lot of status and configuration flags. Whenever you find an interesting message (or other symbol), it will then be trivial to google or directly visit MSDN to get the _exact_ information about when and how it is generated, or if there are version-specific notices about it, i.e. a level of information that we can't take the time to give you on this list. In short: My answer is about methodology. Few things are as giving as looking through the available header files. One hour with a couple of header files will pop your head full with ideas what you can do. After that, it is then trivial to flesh out the exact details about the solutions. You say that you have looked. My guess is that you forgot to look in the header files, in which case my previous mail did specifically point you in a very important direction. Life isn't always about getting explicit answers. The best answers you can get on mailing lists or forums are not explicit. The best answers you can get are the answers that solves a number of future problems too. In this case: where to look. In this case: google on "minimize size event" should as first match have told you about OnSizeChanged(). This might feel like a side track, but the word SIZE should feel very important. A bit closer look at the WM_SIZE message should have informed you that wParam can be SIZE_MINIMIZED. On the other hand: Looking for WM_CLOSE in the include files would have noticed it in winuser.h. Searching for MINIMIZE in winuser.h would match: #define WS_MINIMIZE 0x20000000 #define WS_MINIMIZEBOX 0x20000 #define SW_SHOWMINIMIZED 2 #define SW_MINIMIZE 6 #define SW_FORCEMINIMIZE 11 #define SM_CXMINIMIZED 57 #define SM_CYMINIMIZED 58 #define SPI_GETMINIMIZEDMETRICS 43 #define SPI_SETMINIMIZEDMETRICS 44 #define SIZE_MINIMIZED 1 #define SC_MINIMIZE 0xF020 #define HBMMENU_MBAR_MINIMIZE ((HBITMAP)3) #define HBMMENU_MBAR_MINIMIZE_D ((HBITMAP)7) #define HBMMENU_POPUP_MINIMIZE ((HBITMAP)11) typedef struct tagMINIMIZEDMETRICS { UINT cbSize; int iWidth; int iHorzGap; int iVertGap; int iArrange; } MINIMIZEDMETRICS,*LPMINIMIZEDMETRICS; A quick scan at these matches should also give a very good idea how to continue with google. They tell you such thing as how to configure a window to show a minimuze button, to allow minimizing, to make it minimized, to get the size of a minimized window, to catch the event when it gets minimized etc... Internet is large. To find something, you must develop a method how to search and where to start searching. Only then can you quickly drill down to the interesting parts. You are of course free to consider my answers bad, but learning how to search to be able to find the needed information in less than 5 minutes is quite a lot better than to have to spend 5 minutes writing a question and then have to wait hours or days for a possibly useful answer. /pwm On Wed, 19 Dec 2007, angel dario wrote: > The reason why i ask is not because i didn't took time to look it up on books, MSDN, or whatever comes to your mind. The reason i ask is because after i made a big search i couldn't find anything. GOT IT???????? > > And if you don't have the answer please don't answer with something else. > > thanks anyways. > _________________________________________________________________ > Share life as it happens with the new Windows Live. > http://www.windowslive.com/share.html?ocid=TXT_TAGHM_Wave2_sharelife_122007 |
From: angel d. <sci...@ho...> - 2007-12-19 14:28:50
|
The reason why i ask is not because i didn't took time to look it up on boo= ks, MSDN, or whatever comes to your mind. The reason i ask is because after= i made a big search i couldn't find anything. GOT IT???????? =20 And if you don't have the answer please don't answer with something else.=20 =20 thanks anyways. _________________________________________________________________ Share life as it happens with the new Windows Live. http://www.windowslive.com/share.html?ocid=3DTXT_TAGHM_Wave2_sharelife_1220= 07= |
From: Per W. <pw...@ia...> - 2007-12-19 09:23:44
|
Have you spent any time on the MSDN site, reading up on the documentation available there? Have you bought yourslf a good book on Win32 programming? Have you spent any time reading through the relevant header files - for example looking for all constants starting with WM_? /pwm On Tue, 18 Dec 2007, angel dario wrote: > > I want to know what's the message that is sended to the window when i cli= ck on the minimize button. > > For example: > When i click on the X button, it sends a WM_QUIT message to the procedu= re. > > _________________________________________________________________ > i=92m is proud to present Cause Effect, a series about real people making= a difference. > http://im.live.com/Messenger/IM/MTV/?source=3Dtext_Cause_Effect |
From: angel d. <sci...@ho...> - 2007-12-19 03:15:58
|
=20 I want to know what's the message that is sended to the window when i click= on the minimize button. =20 For example: When i click on the X button, it sends a WM_QUIT message to the procedure= . =20 _________________________________________________________________ i=92m is proud to present Cause Effect, a series about real people making a= difference. http://im.live.com/Messenger/IM/MTV/?source=3Dtext_Cause_Effect= |
From: Brad W. <c_b...@ya...> - 2007-12-17 04:08:14
|
Thank you very much, that fixed the problem. adrian <ad...@la...> wrote: Äîáðîãî âðåìåíè ñóòîê, c_b...@ya...! Âàìè, Brad Woosley áûëî íàïèñàíî: >I attempted to include , but I am told that there is no such file when I complie it. > Does this not come with Dev and I need to get it, or is there something else wrong with my code? > You can define IDC_STATIC as: #ifndef IDC_STATIC #define IDC_STATIC (-1) #endif Ñ óâàæåíèåì, ×óðèí. --------------------------------- Looking for last minute shopping deals? Find them fast with Yahoo! Search. |
From: Brad W. <c_b...@ya...> - 2007-12-17 03:50:54
|
I attempted to include <afxres.h>, but I am told that there is no such file when I complie it. Does this not come with Dev and I need to get it, or is there something else wrong with my code? adrian <ad...@la...> wrote: Äîáðîãî âðåìåíè ñóòîê, c_b...@ya...! Âàìè, Brad Woosley áûëî íàïèñàíî: >I have another problem with creating a dialog box using Win32. I am trying to get text to appear on the dialog box. Each time that I try to compile I am told that I am having a problem with 2 lines in the resource file. > > //LINE 1: > > GROUPBOX "Help for this program...",IDC_STATIC,7,7,225,52 > > //LINE 2: > > CTEXT "Insert help info here",IDC_STATIC,16,18,144,33 > > I am told that there is a parse error in these lines. I have windows.h included. > > Could some one tell me what I am doing wrong here. If needed, I will provide more of the program. I test your code by Resource Workshop and it found not any errors. But in dev-cpp you have to include , 'cos ID_STATIC implemented in this file. Ñ óâàæåíèåì, ×óðèí. --------------------------------- Never miss a thing. Make Yahoo your homepage. |
From: Unknown N. <unk...@gm...> - 2007-12-17 00:18:43
|
I decided to go 98 (found an old dusty copy in my attic...) Works fine n= ow. On Sun, 16 Dec 2007 09:58:20 -0500, <rus...@ao...> wrote: > > I can't speak with any > certainty, but I'd say that the win95 os is too old to run any of the > more recent versions (post 2000). You'd need to look at the versions > that were out at the time. In all honesty it'd be much better to pick > up win98/2000/xp. > > here's a good link for os (at pricewatch): > > http://www.pricewatch.com/software_oper_system/ > > > > > > > here's newegg's pricing: > > http://www.newegg.com/Store/SubCategory.aspx?SubCategory=3D368&name=3D= Operating-Systems > > > > > > > > btw.. does this feel like a loop to anyone else? ;) > > > > -----Original Message----- > From: Unknown Name <unk...@gm...> > To: dev...@li... > Sent: Sat, 15 Dec 2007 12:36 pm > Subject: [Dev-C++] Problem with Windows 95 > > > > > > > > > > > When I downloaded and installed Dev-Cpp 4.9.9.2 on my Windows 95 machi= ne, > which is version 4.0.950A, it said there were several DLL's missing, s= o I > downloaded and installed them. It didn't work after I did that, so I > uninstalled it and installed the older version avliable. Can someone > please help me. Any help would be glady appreciated. > > Thanks, > "Unknown Name" > -- = Using Opera's revolutionary e-mail client: http://www.opera.com/mail/ |
From: <rus...@ao...> - 2007-12-16 14:58:39
|
I can't speak with any certainty, but I'd say that the win95 os is too old to run any of the more recent versions (post 2000). You'd need to look at the versions that were out at the time. In all honesty it'd be much better to pick up win98/2000/xp. here's a good link for os (at pricewatch): http://www.pricewatch.com/software_oper_system/ here's newegg's pricing: http://www.newegg.com/Store/SubCategory.aspx?SubCategory=368&name=Operating-Systems btw.. does this feel like a loop to anyone else? ;) -----Original Message----- From: Unknown Name <unk...@gm...> To: dev...@li... Sent: Sat, 15 Dec 2007 12:36 pm Subject: [Dev-C++] Problem with Windows 95 When I downloaded and installed Dev-Cpp 4.9.9.2 on my Windows 95 machine, which is version 4.0.950A, it said there were several DLL's missing, so I downloaded and installed them. It didn't work after I did that, so I uninstalled it and installed the older version avliable. Can someone please help me. Any help would be glady appreciated. Thanks, "Unknown Name" -- Using Opera's revolutionary e-mail client: http://www.opera.com/mail/ ------------------------------------------------------------------------- SF.Net email is sponsored by: Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace _______________________________________________ Dev-cpp-users mailing list Dev...@li... TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm https://lists.sourceforge.net/lists/listinfo/dev-cpp-users ________________________________________________________________________ More new features than ever. Check out the new AOL Mail ! - http://webmail.aol.com |
From: Brad W. <c_b...@ya...> - 2007-12-16 05:54:53
|
I have another problem with creating a dialog box using Win32. I am trying to get text to appear on the dialog box. Each time that I try to compile I am told that I am having a problem with 2 lines in the resource file. //LINE 1: GROUPBOX "Help for this program...",IDC_STATIC,7,7,225,52 //LINE 2: CTEXT "Insert help info here",IDC_STATIC,16,18,144,33 I am told that there is a parse error in these lines. I have windows.h included. Could some one tell me what I am doing wrong here. If needed, I will provide more of the program. --------------------------------- Never miss a thing. Make Yahoo your homepage. |