FreeBASIC and the Raspberry Pi ?

General discussion for topics related to the FreeBASIC project or its community.
D.J.Peters
Posts: 8586
Joined: May 28, 2005 3:28
Contact:

Re: FreeBASIC and the Raspberry Pi ?

Post by D.J.Peters »

! -s gui Is Windows only !

Joshy
srvaldez
Posts: 3373
Joined: Sep 25, 2005 21:54

Re: FreeBASIC and the Raspberry Pi ?

Post by srvaldez »

BasicCoder2 wrote: Image
if you want F5 to compile and run your source code then you could change the Execute command from
"./%e" to
fbc -w all "%f" && "./%e"
but then if you decided to add compiler flags then you would also need to change the compile command in the Execute command, besides, I don't see an advantage in having F5 compile and execute your program.
warning: in case of error the error is displayed in the terminal and not in the compiler warning/error pane
BasicCoder2
Posts: 3906
Joined: Jan 01, 2009 7:03
Location: Australia

Re: FreeBASIC and the Raspberry Pi ?

Post by BasicCoder2 »

Just tried dodicat's second graphics example in the thread
viewtopic.php?f=7&t=26526
and it turned very slowly in little jerks whereas on my laptop it rotated smoothly and a reasonable rate.
So clearly the Raspberry Pi isn't any replacement for a i5 laptop when it comes to graphics.
St_W
Posts: 1619
Joined: Feb 11, 2009 14:24
Location: Austria
Contact:

Re: FreeBASIC and the Raspberry Pi ?

Post by St_W »

BasicCoder2 wrote:So clearly the Raspberry Pi isn't any replacement for a i5 laptop when it comes to graphics.
The RPi isn't a replacement for a i5 in any regard :-) ... but that is not the aim of the RPi anyway.
BasicCoder2
Posts: 3906
Joined: Jan 01, 2009 7:03
Location: Australia

Re: FreeBASIC and the Raspberry Pi ?

Post by BasicCoder2 »

St_W wrote:
BasicCoder2 wrote:So clearly the Raspberry Pi isn't any replacement for a i5 laptop when it comes to graphics.
The RPi isn't a replacement for a i5 in any regard :-) ... but that is not the aim of the RPi anyway.
I don't know if any of the slow graphics is due to the GPU or the CPU.
I was going to use the RPi to replace the Arduino controlling my robot with the idea of being able to do all the code in the one language, FreeBASIC.
In reality a small laptop probably gives you the most bang for the buck in terms of computing power, software tools and hardware and thus a laptop plus Arduino for low level processing is probably the best option.
dasyar
Posts: 372
Joined: Dec 04, 2008 15:31

Re: FreeBASIC and the Raspberry Pi ?

Post by dasyar »

I was going to use the RPi to replace the Arduino controlling my robot with the idea of being able to do all the code in the one language, FreeBASIC.
As you have found out, there is a very limited amount of people that are using freeBasic with the Raspberry Pi. The main push for the RPi is Python, and in some cases C, so you will not find any fbc code or examples for how to address the GPIO.

I have done some robot experiments where I have used the RPi and a microprocessor, my choice is the Parallax Activity Board. I still think it is a better match to use a microprocessor for the operation of the robot and use the RPi for the actual control and related functions.

One of my goals with the RPi, in use with the robot, was to use the built in WiFi for a headless RPi. Possibly an attached camera with the RPi for remote viewing of the robots line of sight. And of course the multitasking power of the RPi.

I have come to the conclusion that there is no one language that would be a "does it all", you probably have to mix and match too the functionality that is necessary to achieve.
BasicCoder2
Posts: 3906
Joined: Jan 01, 2009 7:03
Location: Australia

Re: FreeBASIC and the Raspberry Pi ?

Post by BasicCoder2 »

dasyar wrote:I have come to the conclusion that there is no one language that would be a "does it all", you probably have to mix and match too the functionality that is necessary to achieve.
Sure but the main program could be written in FreeBASIC (or Python) running on a PC and the hardware i/o carried out by an Arduino.

The idea was to replace the k8055 board I was using with an Arduino. Thus the main computer, a PC programmed in FreeBASIC, would communicate with a programmed Arduino and its associated i/o circuitry to perform particular i/o tasks with the actual hardware. Whereas I am stuck with the fixed commands provided by the k8055 board and its associated circuitry with an Arduino I could program my own commands and wire up my own circuitry.
Last edited by BasicCoder2 on Apr 03, 2018 6:17, edited 1 time in total.
dasyar
Posts: 372
Joined: Dec 04, 2008 15:31

Re: FreeBASIC and the Raspberry Pi ?

Post by dasyar »

@BasicCoder2
WOW, I am impressed, you are way more ambitious than I am.

In your cart configuration, it seems that you could replace the lap top with an RPi, and run it headless. Also, did you ever think about adding an IR component, so you could use a TV remote control to conviently move your cart around?

Do you have a side view shot of your round configuration, that also looks interesting.
BasicCoder2
Posts: 3906
Joined: Jan 01, 2009 7:03
Location: Australia

Re: FreeBASIC and the Raspberry Pi ?

Post by BasicCoder2 »

dasyar wrote:In your cart configuration, it seems that you could replace the lap top with an RPi, and run it headless. Also, did you ever think about adding an IR component, so you could use a TV remote control to conveniently move your cart around?
The wireless keyboard gives remote control as well as a means to send commands or program the PC.
Do you have a side view shot of your round configuration, that also looks interesting.
That was put together to test Arduino code with regards to reading the encoders, reading other sensors and controlling the motors.
It was a gutted sweeper robot base. I used its motors, battery and battery charging circuit. I also used some of its sensors (not shown).
That was a year ago and it has since been replaced with another base.
Pitto
Posts: 122
Joined: Nov 19, 2012 19:58

Re: FreeBASIC and the Raspberry Pi ?

Post by Pitto »

Hi all,

I've tanken some shots of my Raspberry PI 3 (Raspian OS) running Freebasic code:
https://youtu.be/e9kTKmUbG-A

Using this hardware I've compiled many code without problems.

It is working reasonably well. And it's fun :)
Post Reply