Search found 3592 matches

by TJF
Aug 03, 2020 19:51
Forum: General
Topic: simple stack-based eval
Replies: 11
Views: 477

Re: simple stack-based eval

Float parsing is not trivial
? .-5

-5
rpn = . 5 -
by TJF
Aug 03, 2020 6:36
Forum: General
Topic: simple stack-based eval
Replies: 11
Views: 477

Re: simple stack-based eval

? 1e-5

-4
rpn = 1E 5 -
by TJF
Aug 02, 2020 15:58
Forum: General
Topic: simple stack-based eval
Replies: 11
Views: 477

Re: simple stack-based eval

srvaldez wrote:I added E to the numeric character list and entering a number in exponential format will now works but there's no checking for valid number entry
Wanna fix further problems?
? (1+2)*3

Aborting due to runtime error 6 (out of bounds array access) at line 204 of eval.bas::FACTOR()
Regards
by TJF
Aug 02, 2020 8:18
Forum: General
Topic: simple stack-based eval
Replies: 11
Views: 477

Re: simple stack-based eval

srvaldez wrote:not a tip or a trick, just for fun
No fun yet :-(
? 1e5

Syntax Error
by TJF
Jul 26, 2020 10:21
Forum: Hardware Interfaces / Communication
Topic: TP-Link HS110
Replies: 159
Views: 17021

Re: TP-Link HS110

There is no way I could improve on 18 sec's, or come anywhere near it. The uSD alone takes 45 + sec's, but i guess you are not running on a uSD. Booting from uSD. The eMMC boot sector is erased -> no access to eMMC. I find the hardest part is researching what is needed and what is not. Then testing...
by TJF
Jul 25, 2020 12:17
Forum: Libraries
Topic: ttf examples on 64-bit systems?
Replies: 4
Views: 251

Re: ttf examples on 64-bit systems?

Hi N3trunn3r! On 64 bit systems take care sending a proper stride value to function cairo_image_surface_create_for_data(): #DEFINE CAIRO_HAS_PDF_SURFACE 1 #DEFINE CAIRO_HAS_PS_SURFACE 1 #DEFINE CAIRO_HAS_SVG_SURFACE 1 #INCLUDE ONCE "cairo/cairo.bi" #INCLUDE ONCE "cairo/cairo-pdf.bi&qu...
by TJF
Jul 25, 2020 11:24
Forum: Hardware Interfaces / Communication
Topic: TP-Link HS110
Replies: 159
Views: 17021

Re: TP-Link HS110

You are preaching to the converted. I may not handle them the way you are, but I have error trapping everywhere in my code. In the case of the error "Cannot open /dev/uio5" , that doesn't mean anything to me, so by numbering the error and trapping it on the return of the function allows m...
by TJF
Jul 24, 2020 13:14
Forum: Hardware Interfaces / Communication
Topic: TP-Link HS110
Replies: 159
Views: 17021

Re: TP-Link HS110

In particular the plot command is something I have been looking for. systemd-analyse has further options for your task, it's worth to check them. The plot is the most easy to interpret. What's the result of ?*io->Errr after the io=pruio() call? Cannot open /dev/uio5 What's the result of ?*io->Errr ...
by TJF
Jul 24, 2020 6:57
Forum: Hardware Interfaces / Communication
Topic: TP-Link HS110
Replies: 159
Views: 17021

Re: TP-Link HS110

Hi Dinosaur! For me there're a couple of unanswered questions here: ⋅ What's the result of ?*io->Errr after the io=pruio() call? ⋅ What's the result of ?*io->Errr after the .Gpio->config(IOCtrl.OPpinNbr(Xq) , PRUIO_GPIO_OUT0) call? Note: As long as you don't reset the error messa...
by TJF
Jul 22, 2020 23:42
Forum: Beginners
Topic: Automatic set ERR for error
Replies: 16
Views: 463

Re: Automatic set ERR for error

But a reasonable language would simply return zero instead of making a fuss about it (and that's what FB does btw). However, the real problem here is that Err () is not being set for serious errors, such as an overflow or a blabla text returning zero. ⋅ An overflow returns inf -> no probl...
by TJF
Jul 22, 2020 13:51
Forum: Beginners
Topic: Automatic set ERR for error
Replies: 16
Views: 463

Re: Automatic set ERR for error

The task as defined by OP was not to check if the input was a valid single value. Besides, 1e-40 is a valid single value. The first task by the OP was checking for an INTEGER value. In the second post the OP changed to checking for a SINGLE value. My mistake, 1e-40 is a valid SINGLE. Test 1e-48 .
by TJF
Jul 22, 2020 11:48
Forum: Beginners
Topic: Automatic set ERR for error
Replies: 16
Views: 463

Re: Automatic set ERR for error

Hi mere mortal from the Eternal City. The task is checking if the input is a valid SINGLE value. Just try 1e-40 in your code.
by TJF
Jul 22, 2020 9:43
Forum: Beginners
Topic: Automatic set ERR for error
Replies: 16
Views: 463

Re: Automatic set ERR for error

Now this is a much, much better way to handle the problem, right? Not really! CONST AS DOUBLE _ MinN = 1.401298e-45 _ , MaxN = 3.402823e+38 VAR number = 0.0 ' must use double!! DO INPUT "Type number"; number SELECT CASE ABS(number) CASE 0 : EXIT DO CASE IS > MaxN : ?"Overflow"; ...
by TJF
Jul 22, 2020 7:59
Forum: Beginners
Topic: Automatic set ERR for error
Replies: 16
Views: 463

Re: Automatic set ERR for error

Single is a 32-bit, floating point data type used to store decimal numbers. They can hold positive values in the range 1.401298e-45 to 3.402823e+38, or negative values in the range -1.401298e-45 to -3.402823e+38, or zero (0). They contain at most 24 bits of precision, or about 6 decimal digits. And...
by TJF
Jul 14, 2020 14:41
Forum: General
Topic: GPX file processing
Replies: 6
Views: 443

Re: GPX file processing

It's a bad idea to differentiate the speed as distance vs. time. The position may have a deviation of more then ten meters each. In your case it seems to be even more. I don't understand your function deltaPos() , where the elevation is unconsidered. I get FUNCTION distance( _ BYVAL lat1 AS ...

Go to advanced search