The time now is Mon 23 Apr 2018, 17:24
All times are UTC - 4 |
Page 29 of 36 [526 Posts] |
Goto page: Previous 1, 2, 3, ..., 27, 28, 29, 30, 31, ..., 34, 35, 36 Next |
Author |
Message |
sunburnt

Joined: 08 Jun 2005 Posts: 5087 Location: Arizona, U.S.A.
|
Posted: Sat 17 Dec 2011, 01:33 Post subject:
|
|
Installed the latest Puppy528-3 so Firefox could have a working Flash player.
As usual, BaCon doesn`t work in the new install.
I need to write another setup script to get it running for every new Save file.
Error:
Code: | Symbol not found in library /usr/share/BaCon/hug.so: undefined symbol: METHOD |
hug.so has the METHOD function in it of course...
### Also I posted about getting mouse info. 2 posts above here.
|
Back to top
|
|
 |
vovchik

Joined: 23 Oct 2006 Posts: 1447 Location: Ukraine
|
Posted: Sat 17 Dec 2011, 06:03 Post subject:
|
|
Dear Terry,
I know it slows the compile/debug process, but I just use hug.bac as an INCLUDE for everything. Later I go and determine which functions I use from the HUG lib. That way I never run in to your type of problem - where the system may have an old hug.so or can't find the right one. And if you have a working BaCon or BaConGui, the program with the hug.bac INCLUDE will compile. Later you can make your hug.so and recompile, once you know that everything is working.
With kind regards,
vovchik
|
Back to top
|
|
 |
sunburnt

Joined: 08 Jun 2005 Posts: 5087 Location: Arizona, U.S.A.
|
Posted: Sat 17 Dec 2011, 08:53 Post subject:
|
|
I replaced /usr/lib/hug.so with a link to the newer hug.so
Barry should make /usr/lib/hug.so a link to /root/my-applications/lib/hug.so
Puppy`s Save file is it`s biggest problem, it corrupts occasionally.
So I replaced the dirs. my-applications and my-documents with links to /apps and /docs dirs. on a partition so nothing`s lost.
Keep a backup Save file, to restore just copy it over the old one.
This should be a menu item, to make a gzip backup Save file, and have an option to restore it at the bootup menu.
|
Back to top
|
|
 |
vovchik

Joined: 23 Oct 2006 Posts: 1447 Location: Ukraine
|
Posted: Sat 17 Dec 2011, 20:57 Post subject:
New HUG with sliders |
|
Dear puppians,
Peter has just posted a new HUG (0.66) that now has support for vscale and hscale sliders. If you want to use these widgets, please download the latest HUG http://www.basic-converter.org/hug.bac. The documentation will be updated in due course.
With kind regards,
vovchik
|
Back to top
|
|
 |
GatorDog

Joined: 12 Sep 2006 Posts: 136
|
Posted: Sun 18 Dec 2011, 02:21 Post subject:
|
|
vovchik,
Thanks for update
gatordog
_________________

|
Back to top
|
|
 |
vovchik

Joined: 23 Oct 2006 Posts: 1447 Location: Ukraine
|
Posted: Sun 18 Dec 2011, 06:18 Post subject:
|
|
Dear puppians,
Here is a little demo to show how to use the new slider widgets, done some time ago by 2lss and modded by me a bit:
Code: | ' ************************
' INCLUDES
' ************************
' INCLUDE ../hug-slider.bac
INCLUDE "hug.bac", ATTACH, CALLBACK, \
DISPLAY, ENTRY, GET, HUGOPTIONS, \
INIT, SET, \
TEXT, WINDOW, HUGLIB$, HSLIDE, VSLIDE
' ************************
' END INCLUDES
' ************************
' ************************
' SUBS & FUNCTIONS
' ************************
' -----------------
SUB update_hslide_entry()
' -----------------
num = GET(hslide)
TEXT(hentry, STR$(num))
END SUB
' -----------------
SUB update_vslide_entry()
' -----------------
num = GET(vslide)
TEXT(ventry, STR$(num))
END SUB
' -----------------
SUB make_gui()
' -----------------
HUGOPTIONS("TABLE 20 20")
win = WINDOW("Hug Slide Test", 300, 300)
hslide = HSLIDE(12, 3, 1, 20, 1)
ATTACH(win, hslide, 1, 1)
SET(hslide, 5)
vslide = VSLIDE(3, 12, 1, 30, 2)
ATTACH(win, vslide, 15, 1)
SET(vslide, 10)
hentry = ENTRY(STR$(GET(hslide)), 2, 2)
ATTACH(win, hentry, 4, 6)
ventry = ENTRY(STR$(GET(vslide)), 2, 2)
ATTACH(win, ventry, 15, 14)
CALLBACK(hslide, update_hslide_entry)
CALLBACK(vslide, update_vslide_entry)
END SUB
' ************************
' END SUBS & FUNCTIONS
' ************************
' ************************
' MAIN
' ************************
' Start hug
INIT
' Make gui
make_gui
' Show gui
DISPLAY
' ************************
' END MAIN
' ************************ |
With kind regards,
vovchik
|
Back to top
|
|
 |
sunburnt

Joined: 08 Jun 2005 Posts: 5087 Location: Arizona, U.S.A.
|
Posted: Sun 15 Jan 2012, 21:46 Post subject:
|
|
I`m writing a function file to do file I/O for text and arrays.
Strange problem with writing an array to a file.
Code: | SUB OUTARRAY(STRING Txt$[Size], int Size)
OPEN File$ FOR WRITING AS file
FOR i = 0 TO Size-1
WRITELN Txt$[i] TO file
NEXT
CLOSE FILE file
END SUB |
Error is: Cause: 'Size' undeclared here (not in a function)
It looks like the Size needs to be declared in the SUB.
If so, then passing an array to a SUB can`t be done.
The Bacon docs say the array dimension isn`t needed to pass it to a SUB.
But that errors saying:
ERROR: cannot pass string array without dimension at line 54 in file 'test_FileIO.bac'!
So you can pass a numerical array without a dimension, but not a string array?
If that`s the case, then the Bacon docs should mention that little detail...
.
|
Back to top
|
|
 |
Mobeus

Joined: 26 Aug 2010 Posts: 94
|
Posted: Fri 04 May 2012, 12:20 Post subject:
|
|
Some of you may find this interesting so I thought it deserves a post here.
I just had an educational experience over at the BaCon forum http://basic-converter.proboards.com/index.cgi?board=general&action=display&thread=254
BaCon can use gtkbuilder with *.glade files in Puppy!
_________________ /root for the home team
|
Back to top
|
|
 |
Mobeus

Joined: 26 Aug 2010 Posts: 94
|
Posted: Sun 06 May 2012, 10:58 Post subject:
|
|
In Wary 5.3 you cannot use a compile command like Code: |
bacon -o -export-dynamic -o `pkg-config --cflags --libs gtk+-2.0` test.bac |
You will get an error of Code: | /usr/lib/gcc/i486-t2-linux-gnu/4.3.4/../../../../i486-t2-linux-gnu/bin/ld: cannot find -lfontconfig
collect2: ld returned 1 exit status |
You can work around this by echoing the command and copying the output to a bash script, then use the script to compile with. This is what I am using.
Code: | #! /bin/bash
bacon -o -export-dynamic -pthread -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng12 -I/usr/X11R7/include/pixman-1 -I/usr/X11R7/include -pthread -L/usr/X11R7/lib -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lpangocairo-1.0 -lgdk_pixbuf-2.0 -lm -lcairo -lpng12 -lpango-1.0 -lfreetype -lgobject-2.0 -lgmodule-2.0 -lgthread-2.0 -lrt -lglib-2.0 test.bac |
Everything after -export-dynamic up to the test.bac file name is the output from `pkg-config --cflags --libs gtk+-2.0` with the offending -lfontconfig removed. You could also remove some unnecessary linkage this way.
Regards
_________________ /root for the home team
|
Back to top
|
|
 |
linuph

Joined: 03 Jun 2012 Posts: 128 Location: Philippines
|
Posted: Tue 20 Nov 2012, 06:38 Post subject:
|
|
Running Dpup Exprimo 5.X.3.4.12
I'm a bit stuck with Bacon.... I wrote a screensaver (see http://www.murga-linux.com/puppy/viewtopic.php?t=76247&start=1275) more as an exercise than an useful project. But it got me underway. Thus motivated, I started on a more complex project concerning GPS.
I use a Bluetooth GPS module. I connect to it with 'rfcomm /dev/rfcomm 0 > pipe &' in BASH. Then I read the GPS data from the other end of the pipe.
In Bacon it should be, as I understand it 'SYSTEM "rfcomm /dev/rfcomm0 > pipe &". But it cannot connect ('host is down') while in BASH (terminal) all is OK.
I registered with the BACON forum 2-3 weeks ago but sofar no reply. I hope someone here can help and give me some pointers?
|
Back to top
|
|
 |
vovchik

Joined: 23 Oct 2006 Posts: 1447 Location: Ukraine
|
Posted: Tue 20 Nov 2012, 13:17 Post subject:
|
|
Dear linuph,
I haven't seen any questions from you on the Bacon forum. Please try there and post your source code. People will advise or suggest things. Lots of helpful people there....like here.
With kind regards,
vovchik
|
Back to top
|
|
 |
linuph

Joined: 03 Jun 2012 Posts: 128 Location: Philippines
|
Posted: Wed 21 Nov 2012, 00:53 Post subject:
|
|
@vovchik
I registered on 31 October at Proboards but cannot access. It awaits confirmation by an administrator since then....
|
Back to top
|
|
 |
vovchik

Joined: 23 Oct 2006 Posts: 1447 Location: Ukraine
|
Posted: Wed 21 Nov 2012, 07:39 Post subject:
|
|
Dear linuph,
I cannot understand why your registration failed. BaCon's author, Peter van Eerten, allows everybody except spammers, so I don't think he has blocked your registration. Try again. It is a good place to see code and to get advice from many people doing BaCon projects.
http://basic-converter.proboards.com/
With kind regards,
vovchik
PS. You may want to do this using another handle, since there may have been a previous "linuph", and not you.
|
Back to top
|
|
 |
e_mattis

Joined: 20 Dec 2012 Posts: 114 Location: Williamston, SC
|
Posted: Mon 28 Jan 2013, 18:20 Post subject:
BaCon Help! Subject description: Getting BaCon started |
|
Hey all,
I decided to try out BaCon and see if I can write some programs that I need so I can run them on Puppy rather than the M$-crap. I started reading what I could to find out how to set it up and get it started on Precise 5.4.3. I followed the tutorial here http://bkhome.org/bacon/gettingstarted.htm.
Wrote the program in leafpad, downloaded the devx.sfs, opened the term, made sure I was in the correct directory, entered 'bacon demo.bac' and got an error - "could not parse line 1 in file 'demo.bac'"
Did I miss something? Do I need to "turn on" something? Totally lost as to why it would not parse.
Any help appreciated!
Thanks!
E
|
Back to top
|
|
 |
sunburnt

Joined: 08 Jun 2005 Posts: 5087 Location: Arizona, U.S.A.
|
Posted: Mon 28 Jan 2013, 18:56 Post subject:
|
|
Hi e_mattis; What was line one in the file? Better yet, post the file here.
It seems like you have the needed BaCon and system files installed.
|
Back to top
|
|
 |
|
Page 29 of 36 [526 Posts] |
Goto page: Previous 1, 2, 3, ..., 27, 28, 29, 30, 31, ..., 34, 35, 36 Next |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|