Re: [fpc-pascal] Be careful of too many features

2022-05-30 Thread Brian via fpc-pascal
space that you could just about debug 'Hello, world' and that was it. Hopefully Whitesmiths improved in the couple of years before you started with it, or there was a better implementation if you used it on a machine other than a PDP-11. Brian. ___ fpc

[fpc-pascal] Linux Yad

2021-06-06 Thread Brian via fpc-pascal
Has anyone called Yad (linux file manager) as an external program form a main program ? If so can you provide an example of how to do it and retrieve the selected file name? Thanks Brian -- Sent from: http://free-pascal-general.1045716.n5.nabble.com

Re: [fpc-pascal] 50 years of Pascal, by the the author himself

2021-05-12 Thread Brian via fpc-pascal
that VAX Pascal is still alive and kicking, albeit very much a minority compiler. Brian. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Sending Hex codes over TCP/IP

2020-09-13 Thread Brian via fpc-pascal
Use Ararat Synapse . http://synapse.ararat.cz/doc/help/ Unit blcksock Class TTCPBlockSocket Then send and receive byte arrays using : Public function SendBuffer(Buffer: TMemory; Length: Integer): Integer; override; Public function RecvBuffer(Buffer: TMemory; Len: Integer): Integer;

Re: [fpc-pascal] How to implement a circular buffer object in pascal?

2020-09-08 Thread Brian via fpc-pascal
>Bo, > >Most of the users on this forum have never interfaced with hardware , as you >can see from the responses. Those who have interfaced with hardware have >developed circular buffers which they know work , and they reuse them again >and again. I did this about 10 years ago when working on a

Re: [fpc-pascal] How to implement a circular buffer object in pascal?

2020-09-07 Thread Brian via fpc-pascal
send you code snippets showing exactly how to implement the circular buffer. Regards Brian -- Sent from: http://free-pascal-general.1045716.n5.nabble.com/ ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org https://lists.freepascal.or

Re: [fpc-pascal] Writing to a drive which may be spun down

2019-11-21 Thread Brian
On 11/21/19 2:38 PM, Winfried Bartnick wrote: <...> > > writeln (txt,'I''m so tired ...'); > closeFile(txt); > io := ioResult; Thanks Winni, that sounds the sort of idea I'm looking for... Brian. ___ fpc-pascal maill

Re: [fpc-pascal] Writing to a drive which may be spun down

2019-11-21 Thread Brian
On 11/21/19 7:12 AM, wkitt...@windstream.net wrote: > On 11/21/19 1:16 AM, Brian wrote: >> My question: Is there a standard method for handling this situation, >> i.e. making sure that a drive has not spun down, or is it just a case >> of writing a wrapper round the write

[fpc-pascal] Writing to a drive which may be spun down

2019-11-20 Thread Brian
round the write function and handling the 'No such file' error with a wait and a retry? Thanks, Brian. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] USB Human Interface Devices

2019-08-29 Thread Brian
Yes , and it works well on Linux. I use it on a circular (ring) buffer where the main program reads data from the circular buffer and increments the read index while a totally random thread reads data from an incoming Ethernet UDP , serial port or a custom hardware port , writes to the circular

Re: [fpc-pascal] USB Human Interface Devices

2019-08-29 Thread Brian
A bit of clarification .. Also rather than using critical sections , use syncobs to ensure that you are not trying to /SIMULTANEOUSLY/ read and write to the same USB address or your data memory. Try using an Ethernet UDP connection to simulate the USB connection as it may illuminate an issue in

Re: [fpc-pascal] USB Human Interface Devices

2019-08-29 Thread Brian
A few general thoughts. Having been in similar situations when dealing with hardware interfaces .. the hardware is what it is .. and annoying as it is you have to work around it , as the hardware isn't going to change. It seems you have two problems 1) the USB hardware and 2) your program , in

Re: [fpc-pascal] USB Human Interface Devices

2019-07-25 Thread Brian
Try the libusb library Free Pascal interface .. but be aware of his license requirements. It works well. http://johann-glaser.blogspot.com/2012/07/libusb-for-pascal.html -- Sent from: http://free-pascal-general.1045716.n5.nabble.com/ ___ fpc-pascal

Re: [fpc-pascal] USB Human Interface Devices

2019-07-25 Thread Brian
If you can find a controller with an Ethernet input then Synapse is simple and works well. I have used it for RS-232 and Ethernet , but it claims to work with USB http://www.ararat.cz/synapse/doku.php/start -- Sent from: http://free-pascal-general.1045716.n5.nabble.com/

Re: [fpc-pascal] USB Human Interface Devices

2019-07-25 Thread Brian
If you can find a controller with an Ethernet input , the Synapse is simple to use and works well. http://www.ararat.cz/synapse/doku.php/start It also works well for RS-232. It also claims to work with USB but I haven't tried it on USB. -- Sent from:

Re: [fpc-pascal] Realtime and freepascal???

2018-06-06 Thread Brian
, or some special hardware , then preconditioning the data using buffers removes the need for hard real-time and Free Pascal running under vanilla Linux will more than suffice. Brian -- Sent from: http://free-pascal-general.1045716.n5.nabble.com/ ___

Re: [fpc-pascal] Linux getifaddrs

2018-03-01 Thread Brian
/msg03470/getlocalips.lpr It is a bit odd that something like this isn't incorporated into Free Pascal sockets. Thanks Brian -- Sent from: http://free-pascal-general.1045716.n5.nabble.com/ ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http

Re: [fpc-pascal] Linux getifaddrs

2018-03-01 Thread Brian
Do you know of any kernel functions that would return the current IP address ? Thanks Brian -- Sent from: http://free-pascal-general.1045716.n5.nabble.com/ ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi

[fpc-pascal] Linux getifaddrs

2018-02-28 Thread Brian
Has anyone translated* getifaddrs* function to Free Pascal ? http://man7.org/linux/man-pages/man3/getifaddrs.3.html Thanks Brian -- Sent from: http://free-pascal-general.1045716.n5.nabble.com/ ___ fpc-pascal maillist - fpc-pascal

Re: [fpc-pascal] FORTRAN from FreePascal

2017-11-13 Thread brian
On 11/13/2017 10:20 AM, Adriaan van Os wrote: > brian wrote: >> Anyone with any past experience here? It seems I have two choices, to >> try to call the FORTRAN subroutines from FreePascal or to port the >> FORTRAN code to Pascal, I'm looking for advice... > > It is

[fpc-pascal] FORTRAN from FreePascal

2017-11-13 Thread brian
, that long ago ): ). Anyone with any past experience here? It seems I have two choices, to try to call the FORTRAN subroutines from FreePascal or to port the FORTRAN code to Pascal, I'm looking for advice... Thanks, Brian. ___ fpc-pascal maillist

Re: [fpc-pascal] BlockWrite() version 2.6.4

2017-08-14 Thread Brian
Ok. Many thanks guys. Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/BlockWrite-version-2-6-4-tp5729418p5729456.html Sent from the Free Pascal - General mailing list archive at Nabble.com. ___ fpc-pascal

Re: [fpc-pascal] BlockWrite() version 2.6.4

2017-08-14 Thread Brian
Thanks Charlie. I notice the Do_Write() uses repeat .. until where fpWrite() does a direct call. What was the reasoning for the repeat..until in Do_Write() ? Thanks Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/BlockWrite-version-2-6-4

[fpc-pascal] BlockWrite() version 2.6.4

2017-08-05 Thread Brian
can the source code specific to BlockWrite() version 2.6.4 be found ? Thanks Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/BlockWrite-version-2-6-4-tp5729418.html Sent from the Free Pascal - General mailing list archive at Nabble.com

[fpc-pascal] Syncobjs Event and BlockWrite() question

2017-08-01 Thread Brian
-main loop-- MySemaphore.ResetEvent; doing something MySemaphore.SetEvent - Thread MySemaphore.WaitFor(10); BlockWrite() - Thanks Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Syncobjs

Re: [fpc-pascal] FPC for AVR

2017-06-14 Thread Brian
mikroPascal (not free) supports AVR and many other chips. https://shop.mikroe.com/compilers/mikropascal/avr-electronic-license Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/FPC-for-AVR-tp5729005p5729056.html Sent from the Free Pascal - General

Re: [fpc-pascal] FPC Graphics options?

2017-05-18 Thread Brian
hichever thread in which you create the window , all subsequent function calls to SDL2.0 must be made from within that thread , including events otherwise strange behavior or crashes will ensue. Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/FPC-Graphics-op

Re: [fpc-pascal] FPC Graphics options?

2017-05-11 Thread Brian
/ Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/FPC-Graphics-options-tp5728513p5728519.html Sent from the Free Pascal - General mailing list archive at Nabble.com. ___ fpc-pascal maillist - fpc-pascal

Re: [fpc-pascal] FPC Graphics options?

2017-05-11 Thread Brian
to the graphics card at say 60Hz frame rate which make things appear faster than the eye can perceive. Here is basically how to do it. http://gigi.nullneuron.net/gigilabs/sdl2-pixel-drawing/ There is a nice Image and TTF library with SDL 2.0 Brian -- View this message in context: http

Re: [fpc-pascal] Threading vs Parallelism ?

2017-05-09 Thread Brian
e. Another approach is to abandon the add-in (PCIe) card approach and use gigabit Ethernet with a dedicated CPU core as the I/O. This what was done on the current project. Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Threading-vs-Parallelism-tp57280

Re: [fpc-pascal] Threading vs Parallelism ?

2017-05-06 Thread Brian
; function pthread_getaffinity_np(pid : Ptruint; cpusetsize : longint; cpuset : pointer) : longint; cdecl; external; Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Threading-vs-Parallelism-tp5728018p5728443.html Sent from the Free Pascal - General mailing list

Re: [fpc-pascal] Threading vs Parallelism ?

2017-05-05 Thread Brian
the affinity for threads : pthread_setaffinity_np (pthread_t thread, size_t cpusetsize, const cpu_set_t *cpuset); pthread_getaffinity_np (pthread_t thread, size_t cpusetsize, cpu_set_t *cpuset); They are very simple to translate into Free Pascal Brian -- View this message

Re: [fpc-pascal] Warning for anybody else using Linux Mint Debian ('Betsy')

2017-03-08 Thread brian
On 03/07/2017 07:10 PM, Mattias Gaertner wrote: > >> brian <br...@meadows.pair.com> hat am 8. März 2017 um 00:16 geschrieben: >> [...] >>> /usr/bin/ld: /usr/lib/fpc/3.0.2/units/x86_64-linux/rtl/cprt0.o: >>> unrecognized relocation (0x2a) in section `.text'

[fpc-pascal] Warning for anybody else using Linux Mint Debian ('Betsy')

2017-03-07 Thread brian
s 1.6.2-1 means that everything works again as expected. I don't pretend to understand what has happened to cause this error on a system based on stable rather than testing, but as far as users with my configuration are concerned, there appears to be a barrier to

Re: [fpc-pascal] changes to include file do not trigger recompilation of unit

2016-09-11 Thread Brian
, the recompile whatever you are working on. Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/changes-to-include-file-do-not-trigger-recompilation-of-unit-tp5726310p5726323.html Sent from the Free Pascal - General mailing list archive at Nabble.com

Re: [fpc-pascal] Free Delphi 10.1 Berlin Starter Edition

2016-08-24 Thread brian
On Wed, 24 Aug 2016 05:12:54 -0700, you wrote: >On 8/24/2016 1:04 AM, brian wrote: >> On Tue, 23 Aug 2016 23:40:06 +0800, you wrote: >> >> It should maybe be noted that this download apparently requires that >> you have Windows 10? >Negative. I downloaded and install

Re: [fpc-pascal] Free Delphi 10.1 Berlin Starter Edition

2016-08-24 Thread brian
On Tue, 23 Aug 2016 23:40:06 +0800, you wrote: It should maybe be noted that this download apparently requires that you have Windows 10? Brian. > > >Maciej Izak wrote: >> Hi, >> >> finally we have simple way to test new syntax to improve FPC quality / >&

Re: [fpc-pascal] Ararat Synapse UDP Rx Speed (Mbps)

2016-02-04 Thread Brian
with no errors or lost data. Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Ararat-Synapse-UDP-Rx-Speed-Mbps-tp5723972p5723992.html Sent from the Free Pascal - General mailing list archive at Nabble.com

Re: [fpc-pascal] Ararat Synapse UDP Rx Speed (Mbps)

2016-02-03 Thread Brian
Forgot to mention : Running on Linux / Ubuntu -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Ararat-Synapse-UDP-Rx-Speed-Mbps-tp5723972p5723973.html Sent from the Free Pascal - General mailing list archive at Nabble.com.

[fpc-pascal] Ararat Synapse UDP Rx Speed (Mbps)

2016-02-03 Thread Brian
Does anyone have any benchmark speed tests using Synapse to receive UDP data ? (ie Mbps transfer). Thanks -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Ararat-Synapse-UDP-Rx-Speed-Mbps-tp5723972.html Sent from the Free Pascal - General mailing list archive

[fpc-pascal] Question C to Pascal translation ....Re: Wraper for libpciaccess ?

2015-02-05 Thread Brian
Ref libpciaccess.h Any suggestions on the conversions below ? Thanks in advance. Brian C Union --- 00043 struct pci_device_iterator { unsigned next_index; enum { match_any, match_slot, match_id } mode; union { struct pci_slot_match slot

Re: [fpc-pascal] SDL 2.xx

2015-02-03 Thread Brian
Threading SDL 2.03 is not particularly difficult if you observe the rules that a texture/renderer must reside in the same thread that created the window and (it appears) there is only one event (which as you mentioned makes sense) , and in my case the event handler is in a thread. SDL 2.03 has

Re: [fpc-pascal] SDL 2.xx

2015-02-02 Thread Brian
in the main thread (program) , by using SDL_GetWindowID() to get the identify of a window (WindowID) and later use it to recognize which window generated the event. Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/SDL-2-xx-tp5720887p5720900.html Sent from

[fpc-pascal] SDL 2.xx

2015-01-30 Thread Brian
easily create another window / renderer / handler in the main program for the new window , but the question is can there be two event handlers in SDL 2.xx ? Thanks in advance Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/SDL-2-xx-tp5720887.html Sent

[fpc-pascal] Cross-compile vs native

2015-01-27 Thread Brian
A question to those who must maintain a Linux version and a Windows versions application. Do you tend to cross-compile from Linux or do you compile native (with separate projects) on each OS (Linux and Windows)? Thanks Brian -- View this message in context: http://free-pascal-general.1045716

Re: [fpc-pascal] SDL_Net vs Synapse

2015-01-05 Thread Brian
SDL2 Headers also available here ... http://sourceforge.net/projects/sdl2fpc/ -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/SDL-Net-vs-Synapse-tp5720715p5720720.html Sent from the Free Pascal - General mailing list archive at Nabble.com.

[fpc-pascal] SDL_Net vs Synapse

2015-01-05 Thread Brian
Any opinions/experience pro/con using SDL2 (SDL_Net) vs Synapse (http://synapse.ararat.cz/doku.php) ? Thanks Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/SDL-Net-vs-Synapse-tp5720715.html Sent from the Free Pascal - General mailing list archive

[fpc-pascal] FPC Heap Management : sub-allocation ?

2014-10-31 Thread Brian
? ... sorry for the long winded sentence. Thanks in advance Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/FPC-Heap-Management-sub-allocation-tp5720419.html Sent from the Free Pascal - General mailing list archive at Nabble.com

Re: [fpc-pascal] FPC Heap Management : sub-allocation ?

2014-10-31 Thread Brian
Thanks Sven. Do you know how it behaves when running under Linux? -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/FPC-Heap-Management-sub-allocation-tp5720419p5720423.html Sent from the Free Pascal - General mailing list archive at Nabble.com.

Re: [fpc-pascal] FPC Heap Management : sub-allocation ?

2014-10-31 Thread Brian
Frederic Da Vitoria wrote I think that Brian is asking if a memory leak could eat the system's memory irreversibly. IIUC in Windows, when the program is stopped, all it's memory is freed, even if the program leaked memory. I don't know about Linux, but I'd be surprised if it weren't the same

[fpc-pascal] fpGUI Thread-safe

2014-10-15 Thread Brian
Is fpGUI running under X11 thread-safe? Thanks Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/fpGUI-Thread-safe-tp5720361.html Sent from the Free Pascal - General mailing list archive at Nabble.com. ___ fpc

Re: [fpc-pascal] fpGUI Thread-safe

2014-10-15 Thread Brian
Sorry , I meant fpGUI created applications , not the toolkit. Thanks Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/fpGUI-Thread-safe-tp5720361p5720365.html Sent from the Free Pascal - General mailing list archive at Nabble.com

Re: [fpc-pascal] Free Pascal Directories

2014-10-02 Thread Brian
directory path such as : {$UNITPATH /home/mydir/fpgui/fpgui-1.2/src/units/i386-linux} and then it only finds the first unit in the uses list and cannot find the rest of the units in i386-linux. Why doesn't FPC continue to look for units in the directory specified by $UNITPATH ? Regards Brian

Re: [fpc-pascal] Free Pascal Directories

2014-10-02 Thread Brian
files. Searching file /usr/lib/fpc/2.6.4/fpg_impl.pas... not found Fatal: Can't find unit fpg_impl used by fpg_base Is there any way to tell the compiler to just link existing .ppu and .o files ? Thanks Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Free

Re: [fpc-pascal] Free Pascal Directories

2014-10-02 Thread Brian
(interface) unit FPG_IMPL [0.058] Loading unit FPG_IMPL [0.058] Unitsearch: fpg_impl.ppu [0.058] Searching file fpg_impl.ppu... not found ... FPC then begins searching for the source file fpg_impl.pas which is not in the directory and eventually fails. Any suggestions ? Thanks Brian -- View

Re: [fpc-pascal] Free Pascal Directories

2014-10-02 Thread Brian
The compiler accepts the directory and loads the first unit fpg_base , but then fails to load the next unit that is called by fpg_base which is fpg_impl . Then it fails. Regards Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Free-Pascal-Directories

Re: [fpc-pascal] Free Pascal Directories

2014-10-02 Thread Brian
My mistake ... Using directive -Va I can see that PFC cannot find fpg_base also. Question : Does the directive $UNITPATH acvtually work ? Regards Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Free-Pascal-Directories-tp5720212p5720266.html Sent from

Re: [fpc-pascal] Free Pascal Directories

2014-10-02 Thread Brian
Conclusion : Using {$UNITPATH /home/some/*} in the main program DOES NOT WORK ! When using Geany if the directive is added in Set Build Command , COMPILE line as -Fu/home/some/* it works properly. Much better than dumping everything into one pot. Regards Brian -- View this message

Re: [fpc-pascal] Free Pascal Directories

2014-10-01 Thread Brian
will find fpg_base but then fail to find the next unit called by fpg_base ... Fatal: Can't find unit fpg_impl used by fpg_base What am I missing? Thanks in Advance Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Free-Pascal-Directories

Re: [fpc-pascal] Free Pascal Directories

2014-10-01 Thread Brian
Mattias Gaertner wrote On Wed, 1 Oct 2014 13:39:39 -0700 (PDT) Brian lt; vmst@ gt; wrote: Sorry , I wasn't specific about my problem. Using the example in the fpGUI distribution (but the following comments are not specific to fpGUI). I want to use Geany as the IDE without using .CFG

[fpc-pascal] Free Pascal Directories

2014-09-30 Thread Brian
code) in a separate directory. Any suggestions ? Thanks in advance Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Free-Pascal-Directories-tp5720212.html Sent from the Free Pascal - General mailing list archive at Nabble.com

[fpc-pascal] Wraper for libpciaccess ?

2014-09-21 Thread Brian
Does anyone know of an FPC wrapper for the library libpciaccess ? Thanks in advance Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Wraper-for-libpciaccess-tp5720127.html Sent from the Free Pascal - General mailing list archive at Nabble.com

Re: [fpc-pascal] Xlib Threads

2014-04-27 Thread Brian
Yes , Xlib has many impressive features , but it is lacking in a simple (and fast) way to independently write to specific bit planes without altering the other bit planes for 2D animation. OpenGL can be used (I think) for 2D automation using the z-buffer , but it really is and end around to a

Re: [fpc-pascal] Xlib Threads

2014-04-27 Thread Brian
An interesting discussion at this link on the subject. http://networkedblogs.com/axUUw *Effectively, the beginning of the main() function is the only really safe place to call XInitThreads(). * -- View this message in context:

[fpc-pascal] Xlib Threads

2014-04-25 Thread Brian
All the Xlib documentation seems to imply that threads can be used , however if I attempt to put XNextEvent() or XPending() in a thread , the rsult is a GP fault . The error message suggests using XInitThreads() but it still generates a GP fault. Tried using XlockDisplay() and XUnlockDisplay() in

[fpc-pascal] SOLVED : Re: GetAffinity\SetAffinity

2013-11-25 Thread Brian
Problem solved ... ironically the solution was from a Windows guy. Faulty Code Core2Thread_ID := BeginThread(@Core2_Thread_Test); InitCriticalSection(CriticalSection_Core2); Set_Thread_CPU_Core(Core2Thread_ID,$01); writeln('Core2 ok'); Core22Thread_ID :=

[fpc-pascal] Re: GetAffinity\SetAffinity

2013-11-22 Thread Brian
Mark ... sorry for the mixup. The program and unit should now be stand alone. The unit links libc (rev6). Regards Brian coret.pas http://free-pascal-general.1045716.n5.nabble.com/file/n5717549/coret.pas test_threads.pas http://free-pascal-general.1045716.n5.nabble.com/file/n5717549

[fpc-pascal] Re: GetAffinity\SetAffinity

2013-11-22 Thread Brian
Attached binary executables which run on Ubuntu 12.04lts , but should be portable. coret_ok sets the process and two threads to core1 coret_fail sets to process to cores1 and 2 , one thread to core 1 and one thread to core 2. It soemtimes runs ok , but usually fails with a GP fault. coret_ok

[fpc-pascal] Re: GetAffinity\SetAffinity

2013-11-22 Thread Brian
... The critical sections you are using only protect each thread against itself, meaning they basically do nothing. Being inside a critical section is not a guarantee that you won't get preempted, but just that no other threads can enter the same section. ... The two threads do not share and

[fpc-pascal] Re: GetAffinity\SetAffinity

2013-11-22 Thread Brian
Mark ... many thanks. Your last comment prompted me to avoid using Write/Writeln to monitor what was happening. By removing Write/Writeln from the threads , ... everything works correctly with two threads , one running on core1 and the other thread running on core2. I think this boils down to

[fpc-pascal] Re: GetAffinity\SetAffinity

2013-11-21 Thread Brian
increases , as the scheduler then starts to try and spread the load between the two cores. If only one core is used everything works fine. Regards Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/GetAffinity-SetAffinity-tp3351231p5717543.html Sent from

[fpc-pascal] Re: GetAffinity\SetAffinity

2013-11-21 Thread Brian
/file/n5717544/test_threads.pas Regards Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/GetAffinity-SetAffinity-tp3351231p5717544.html Sent from the Free Pascal - General mailing list archive at Nabble.com

[fpc-pascal] Re: GetAffinity\SetAffinity

2013-11-20 Thread Brian
Mark, All the documentation seems to indicate that processes and threads are treated alike in Linux , however , even having established that I can apparently select a core to run a thread , I haven't yet been able to make it work. I explain the findings from a dual core Intel CPU. Using the

[fpc-pascal] Re: GetAffinity\SetAffinity

2013-11-19 Thread Brian
After a bit of research , the issue of setting the cpu affinity has been solved , which may be of use to other folks. A bit of info here concerning the data type cpu_set_t , which as far as I can determine (no help from the mess that is the c library source) is essentially an array of DWORD. For

[fpc-pascal] Re: GetAffinity\SetAffinity

2013-11-15 Thread Brian
in advance. Brian -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/GetAffinity-SetAffinity-tp3351231p5717501.html Sent from the Free Pascal - General mailing list archive at Nabble.com. ___ fpc-pascal maillist - fpc-pascal

Re: [fpc-pascal] Linux - ExecuteProcess versus fpSystem

2011-09-09 Thread brian
noted - the idea of needing to wrap parameter AND value in quotes wouldn't have occurred to me in a month of Sundays. Brian. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Linux - ExecuteProcess versus fpSystem

2011-09-08 Thread brian
. I'll give TProcess a whirl. Thanks for the suggestion. Brian. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Linux - ExecuteProcess versus fpSystem

2011-09-08 Thread brian
a separator to the front of ParamString when using ExecuteProcess? It wouldn't seem sensible to require it, since there are the two parameters to ExecuteProcess versus the one for fpSystem, but maybe that's it. Thanks for the assistance so far, everyone. Brian

[fpc-pascal] Linux - ExecuteProcess versus fpSystem

2011-09-07 Thread brian
, I've checked all the file permissions. It's got to be something obvious, or some quirk of Linux programming that I haven't met up with yet (I'm still a novice with FreePascal and Linux, though I've many years experience with Delphi and Windows). What am I missing? Thanks, Brian

[fpc-pascal] Handling recursive symlinks in Linux

2011-02-18 Thread brian
I'm trying to convert a Delphi console-mode program which needs to walk directory trees to FP **and Linux** - is there a standard way to detect and handle recursive symlinks, if the user has been daft enough to create them? Thanks, Brian. ___ fpc

Re: [fpc-pascal] Javascript in Desktop Applications

2011-02-07 Thread Brian Winfrey
On Mon, Feb 7, 2011 at 6:27 AM, michael.vancann...@wisa.be wrote: On Mon, 7 Feb 2011, Andrew Brunner wrote: On Mon, Feb 7, 2011 at 7:35 AM,  michael.vancann...@wisa.be wrote: A cross-platform solution is to use one of libsee or BESEN. The latter is implemented in 100% native Object

Re: [fpc-pascal] Win32 Application Query.

2011-01-31 Thread Brian Winfrey
On Sun, Jan 23, 2011 at 2:25 AM, Justin Smyth delph...@smythconsulting.net wrote: Hi guys I've been working on a application to application communications protocol via named pipes. the basic idea would be for Application A to change a Component Property on Applications B ( ie the visible

Re: [fpc-pascal] JSON - RTTI streaming.

2011-01-20 Thread Brian Winfrey
On Wed, Jan 5, 2011 at 3:12 PM, Michael Van Canneyt mich...@freepascal.org wrote: Hello, For those of you that need JSON support: I have committed support for streaming published properties (properties for which RTTI  is generated) from objects to JSON and vice versa, in a unit fpjsonrtti.

Re: [fpc-pascal] Cannot get TFPTimer to work

2010-12-02 Thread Brian Winfrey
See .../fpcsrc/packages/fcl-base/examples/testtimer.pp for example usage. On Thu, Dec 2, 2010 at 10:39 AM, Darius Blaszyk dhkblas...@zeelandnet.nl wrote: Whatever I tried, I cannot get TFPTimer to work. Can someone help? For some reason the OnTimer even is never fired. Tried on Windows and

Re: [fpc-pascal] make fpc

2010-11-22 Thread Brian Winfrey
On Mon, Nov 22, 2010 at 1:48 AM, Jonas Maebe jonas.ma...@elis.ugent.be wrote: On 21 Nov 2010, at 19:03, Brian Winfrey wrote: What version should fpc display (Revision: 16393). When I get latest and make /usr/bin/fpc is at version 2.4.2. fpc -vut dummy.pas ... Compiler: /usr/lib/fpc/2.4.2

[fpc-pascal] Re: make fpc

2010-11-21 Thread Brian Winfrey
I also tried make cycle as outlined in programmers guide, but results are the same. On Sun, Nov 21, 2010 at 10:03 AM, Brian Winfrey bwcod...@gmail.com wrote: What version should fpc display (Revision: 16393). When I get latest and make /usr/bin/fpc is at version 2.4.2. fpc -vut dummy.pas

Re: [fpc-pascal] TReader.ReadProperty

2010-11-04 Thread Brian Winfrey
See post from about two weeks ago. Building FPC with debug information On Wed, Nov 3, 2010 at 3:39 AM, Roland Turčan - RoTurSoft i...@rotursoft.sk wrote: On Wed, Nov 3, 2010 at 9:17 AM, Michael Van Canneyt mich...@freepascal.org wrote: PS: How can I debug TReader class, because debuger

Re: [fpc-pascal] MSEide+MSEgui rev.2.4

2010-11-02 Thread Brian Winfrey
The fixes_2_4 is already at version 2.4.3 and contains everything from 2.4.2 and more... Thank you. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] MSEide+MSEgui rev.2.4

2010-11-01 Thread Brian Winfrey
Which address should I be using? It looks like the UUID and revision are the same while Last changed revision and path are different. svn info http://svn.freepascal.org/svn/fpc/tags/release_2_4_2 Path: release_2_4_2 URL: http://svn.freepascal.org/svn/fpc/tags/release_2_4_2 Repository Root:

Re: [fpc-pascal] Re: Re: TPLY

2010-10-29 Thread Brian Winfrey
Well, seems like you all have given some material to get me started. As nobody suggested sticking with TPLY or plex/bison I will back-burner that and proceed with crenshaw/oberon. Thanks to everyone. ___ fpc-pascal maillist -

Re: [fpc-pascal] TPLY

2010-10-29 Thread Brian Winfrey
Thanks, I'll look into this as well. On Fri, Oct 29, 2010 at 2:19 AM, Thierry Coq t...@free.fr wrote: Brian, thanks for the diff, I'll take it into account and publish an update. On 28/10/2010 18:50, Brian Winfrey wrote: ... The changes I made in this diff were simply to get it to compile

Re: [fpc-pascal] Re: TPLY

2010-10-28 Thread Brian Winfrey
Thank you, What techiniques have you used in the past that you could share to get me started? On Wed, Oct 27, 2010 at 8:04 PM, leledumbo leledumbo_c...@yahoo.co.id wrote: Learn compilation technique, a recursive descent parser should be easy to understand and code instead of learning automatic

[fpc-pascal] TPLY

2010-10-25 Thread Brian Winfrey
libraries to FPC 2.5.x, and am unfamiliar with the TPLY tools. Thanks, Brian ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Building FPC with debug information

2010-10-20 Thread Brian Winfrey
make OPT=-O- DEBUG=1 all When I ran this I see that both -dDEBUG and -dRELEASE are passed on the fpc command line. Is that correct? ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] IntList

2010-10-19 Thread Brian Winfrey
Take a look at http://code.google.com/p/fprb/. I have just perused it, but it looks pretty good. Brian. Currently, the FPC team is looking at an implementation of Vlado Boza us...@ksp.sk for a standard template library for inclusion in FPC. The code is on http://code.google.com/p

Re: [fpc-pascal] What are the issues involved in threads sharing variables?

2010-10-19 Thread Brian Winfrey
Polling where the list size is highly dynamic you will need protect it.  I think FPC has thread safe list objects too. Yes it does, Classes.TThreadList I think. I thought it was a conatiner for threads, but it is a safe list. ___ fpc-pascal maillist

[fpc-pascal] lNet getting the local IP

2010-10-08 Thread Brian Winfrey
, you should use it as such. I substituted my router's ip for google's and it works.;) Choose a different address that would not fail in a specific situation. As another example, one could read their /etc/resolve file to get the dns server that is assigned. Brian Winfrey

Re: [fpc-pascal] lNet getting the local IP

2010-10-07 Thread Brian Winfrey
On 06/10/10 14:27, Felipe Monteiro de Carvalho wrote: Ok, thanks everyone, it seams that I managed to extract a function from Silvio's code which doesn't use Synapse. I only tested in Windows so far: unit chesstcputils; {$mode objfpc}{$H+} interface uses    {$IFDEF MSWINDOWS}    

Re: [fpc-pascal] lNet getting the local IP

2010-10-07 Thread Brian Winfrey
I think you want to use 127.0.0.1 to return the actual address. In my case I would const CN_GDNS_ADDR = '127.0.0.1'; run the progarm and the output would be 192.168.1.5 as long as there is an active interface. On Thu, Oct 7, 2010 at 3:34 PM, silvioprog silviop...@gmail.com wrote: Hi Brian

Re: [fpc-pascal] lNet getting the local IP

2010-10-07 Thread Brian Winfrey
I don't know if you noticed, but it appears that code has some depracated properties that should be changed. Here are the modifications I made in exploring this issue: program GetPrimaryIpAddress; {$mode objfpc} uses baseunix, unixtype, sockets, SysUtils; procedure Get(out AddrOut:

  1   2   >