Author Topic: sb buoy plot  (Read 26209 times)

RONB

  • Guest
sb buoy plot
« on: March 27, 2014, 10:45:35 PM »
Wrote a scricptbasic program to plot buoy data and land stations on a satellite image.
example
http://i58.tinypic.com/30wt3s9.png

Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #1 on: March 27, 2014, 10:56:57 PM »
That is pretty slick!

Did you use the GD extension module or one of the other (SDL GFX, BBC or SDL_draw) modules?

Is this something you can share?


Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #2 on: March 28, 2014, 07:45:07 AM »
Thanks!

BTW: How do the bouy's retain their designated position?

Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #3 on: March 28, 2014, 08:54:34 AM »
Amazon EC2 has dropped their prices again as of April 1st. You could run a 64 bit Linux instance 24/7 for less than $60 / year.

Something to consider ...

Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #4 on: March 28, 2014, 09:41:51 AM »
It's fine where it's at. I plan to do a bit of house cleaning after April 1st. I will be focusing most of my efforts after the 2.2 release towards the commercial / business / research use of Script BASIC. That was the focus from the beginning, not hobbyists.
« Last Edit: March 28, 2014, 12:56:38 PM by support »

Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #5 on: March 28, 2014, 12:46:05 PM »
Script BASIC has been used in embedded controllers for years. (ARM/POSIX) I have the current 2.2 version of Script BASIC running native on Android Linux. (ARM) I think Script BASIC and tablets make a great mobile application development environment. The beauty of Script BASIC is it can morph into about anything you need it to.

It wouldn't be too hard to convert your GD based web app to a desktop app with the Script BASIC GFX SDL extension. You could use the alpha channel for more granularity with intensity and pop an info box with the retrieved values if the user clicks on a buoy station. Just saying ...  ;)

« Last Edit: March 28, 2014, 07:47:03 PM by support »

Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #6 on: April 09, 2014, 09:17:56 PM »
Do you have the libSDL_gfx.so in the /usr/lib and SDL 1.2 (64 bit) installed?


Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #7 on: April 10, 2014, 09:40:47 AM »
My guess is the version of SDL 1.2 in the RPM is not compatible with Debian.

I have attached my Ubuntu 64 bit version of the GFX extension module, libSDL_gfx.so and libSDL.so for you to try.

« Last Edit: April 10, 2014, 10:54:09 AM by support »

Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #8 on: April 12, 2014, 08:37:35 PM »
Here is a Script BASIC GFX example for you to test your system with.

Script BASIC GFX - Ubuntu 12.04 LTS 64 bit



Code: [Select]
' Lorenz Curtian

IMPORT gfx.inc

scrn = gfx::Window(600, 800, "ScriptBasic GFX - Lorenz Curtian")
ts = gfx::Time()
FOR t = 0 TO 7000 STEP 0.006
  x = SIN(0.99 * t) - 0.7 * COS(3.01 * t)
  y = COS(1.01 * t) + 0.1 * SIN(15.03 * t)
  x = x * 200 + 400
  y = y * 200 + 300
  gfx::pixelRGBA scrn, FIX(y), FIX(x), 250, 250, 250, 255
NEXT
te = gfx::Time()
gfx::stringColor scrn, 20, 20, "Time: " & FORMAT("%.4f",(te-ts)/1000) & " Seconds." & CHR(0), 0xffffffff
gfx::Update
WHILE gfx::KeyName(1) <> "+escape"
WEND
gfx::Close

Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #9 on: April 12, 2014, 10:32:07 PM »
I sent you everything you needed in the last zip to make the Script BASIC GFX extension module work. What is it saying you're missing?


Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #10 on: April 12, 2014, 10:59:44 PM »
GD is a cool module and can be used on the web as you have demonstrated.

It looks like Debian is using a earlier version of GLIB. This is why I stick with main stream distributions like Ubuntu. I thought that was the direction you were going. The source to the GFX module is on C BASIC Bitbucket site if you want to try and compile it yourself for Debian. I have a Amazon EC2 instance I built what you have. I have no way to test GUI related modules. (ssh connection only)

Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #11 on: April 12, 2014, 11:42:12 PM »
I'll see if I can compile the GFX module on EC2 tomorrow. (getting late here) You will have to test it if I can get it built.  :)

Support

  • Administrator
  • *****
  • Posts: 19
    • View Profile
Re: sb buoy plot
« Reply #12 on: April 13, 2014, 11:15:52 AM »
Ron,

I installed libSDL 1.2 and libSDL_gfx (dev) on my EC2 instance and tried to compile the Script BASIC GFX extension module. I get this BS error that means nothing to me and seems to be a bug with Debian's kernel.

Debian SDL repository

Code: [Select]
admin@ip-10-188-36-190:~/sb22/source/extensions/gfx$ make -B
gcc -w -fPIC -static -m64 -c -I/usr/include/SDL -o ../../bin/mod/obj/gfx/s_interface.o interface.c
interface.c: In function ‘gfx_SDL_framerateDelay’:
interface.c:2240:15: error: void value not ignored as it ought to be
make: *** [../../bin/mod/obj/gfx/s_interface.o] Error 1
admin@ip-10-188-36-190:~/sb22/source/extensions/gfx$

I would try to install SDL and SDL_gfx from the above link and see if the current Ubuntu Script BASIC extension module will work.
The problem may be that I have no X-server running on this instance and therefore unable to detect a GUI device driver.


« Last Edit: April 13, 2014, 11:28:39 AM by support »