Home
JAQForum Ver 20.06
Log In or Join  
Active Topics
Local Time 14:59 24 Apr 2024 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : Introducing the Pi-cromite: first steps

     Page 2 of 16    
Author Message
plasma
Guru

Joined: 08/04/2012
Location: Germany
Posts: 437
Posted: 09:48am 06 Apr 2017
Copy link to clipboard 
Print this post

great Matherp , i like this project
 
CaptainBoing

Guru

Joined: 07/09/2016
Location: United Kingdom
Posts: 1985
Posted: 10:13pm 06 Apr 2017
Copy link to clipboard 
Print this post

this is a revolution in use of this device.

one thing that always clouded the Pi from my side of things was the languages used - this makes it so accessible. Think I will dig out my Pi and give this a go - I have no application for now but just having the capability opens up possibilities.

Possibly a "standard" hardware expansion needs to be agreed - more bits, Analogue etc. A board that "back-packs" the Pi and provides all|most of the hardware compatibility via fast SPI with a firmware abstraction layer to make it transparent to the MMBasic code perhaps?Edited by CaptainBoing 2017-04-08
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 3650
Posted: 11:23pm 06 Apr 2017
Copy link to clipboard 
Print this post

Maybe an alternative (to the Pi) would be another uC that has ADC etc (and more I/Os)?

Lots are available...

Cost - from a bit more than the Pi (but ADC etc would increase the Pi's cost). Some are faster, though how fast is fast enough...

John
 
hitsware
Guru

Joined: 23/11/2012
Location: United States
Posts: 535
Posted: 05:13am 07 Apr 2017
Copy link to clipboard 
Print this post

  JohnS said   Maybe an alternative (to the Pi) would be another uC that has ADC etc (and more I/Os)?

Lots are available...

Cost - from a bit more than the Pi (but ADC etc would increase the Pi's cost). Some are faster, though how fast is fast enough...

John


An Arduino socket would make lots available.
Most boards don't use the same uP as the Pi-3 though.
 
Tinine
Guru

Joined: 30/03/2016
Location: United Kingdom
Posts: 1646
Posted: 09:35am 07 Apr 2017
Copy link to clipboard 
Print this post

Very interesting and exciting stuff. How much of the Pi's memory would be accessible?

Tinine
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 3650
Posted: 09:38am 07 Apr 2017
Copy link to clipboard 
Print this post

Probably as much as you want - did you look at the amount already shown in the screen shot(s)?

How much more did you want?

John
 
Tinine
Guru

Joined: 30/03/2016
Location: United Kingdom
Posts: 1646
Posted: 10:05am 07 Apr 2017
Copy link to clipboard 
Print this post

  JohnS said   Probably as much as you want - did you look at the amount already shown in the screen shot(s)?


Precisely why I asked. It's showing, what, a 1000th of the Pi's total memory?

Tinine
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 3650
Posted: 10:25am 07 Apr 2017
Copy link to clipboard 
Print this post

As I posted: probably as much as you want.

How much more did you want?

Or, how much more did you want or expect reasonably to see in Peter's very first post of something newly built?

John
 
Tinine
Guru

Joined: 30/03/2016
Location: United Kingdom
Posts: 1646
Posted: 10:44am 07 Apr 2017
Copy link to clipboard 
Print this post

My question was a simple one-liner, based on the observation that, from the screen-shot, MM-Basic appears to recognize only 512K. Nothing about my wants/needs.

I don't see why you have to respond as if this was a dumb question. The fact that I asked shows that I haven't made any assumptions about this product, knowing full-well that this is "Peter's very first post of something newly built".

I'm kinda new here....are you the forum's smart-a$$? There's usually always at least one.

Tinine
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 5896
Posted: 11:39am 07 Apr 2017
Copy link to clipboard 
Print this post

Problem with the latest version
  Quote  pi@PiB2-1:~/MMBasic$ ./mmbasic
./mmbasic: error while loading shared libraries: libpigpio.so: cannot open shared object file: No such file or directory


Running as root made no difference.

JimEdited by TassyJim 2017-04-08
VK7JH
MMedit   MMBasic Help
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8573
Posted: 11:52am 07 Apr 2017
Copy link to clipboard 
Print this post

  Quote  Running as root made no difference.


You can fix this by installing this but I'd hoped that by using the C library and not the daemon it wasn't needed - obviously not the case.

I'm still playing with the various options for controlling I/O so this may all changes
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 3650
Posted: 11:57am 07 Apr 2017
Copy link to clipboard 
Print this post

  Tinine said   My question was a simple one-liner, based on the observation that, from the screen-shot, MM-Basic appears to recognize only 512K. Nothing about my wants/needs.


I cannot see why you don't understand about the memory: probably as much as you want.

Peter probably just made any version with a decent amount for testing so something could be done - like testing I/O.

You could do with being a lot less impatient. It's new. New versions of anything are normally missing some things someone would like. The alternative is we wait for maybe months with nothing at all posted - certainly not the ones that have been - so a fully-featured version could just spring forth. Not a great idea.

Truly no good deed goes unpunished!

JohnEdited by JohnS 2017-04-08
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 5896
Posted: 02:03pm 07 Apr 2017
Copy link to clipboard 
Print this post

Running it on a different PI solved the dependency problem but the second time I ran it gave another problem
  Quote  
pi@cumulus:~/mmbasic$ sudo ./mmbasic
2017-04-08 09:54:23 initInitialise: Can't lock /var/run/pigpio.pid

Also,
the FILES command lists files (including hidden ones) but not directories.

Jim
VK7JH
MMedit   MMBasic Help
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9059
Posted: 03:43pm 07 Apr 2017
Copy link to clipboard 
Print this post

@ matherp - do you see this being able to run on the Pi-Zero-W at any time in the future? You know what they say about assumptions - they being the mother of all........

I also understand that this is very much alpha tinkering, but do you have plans to be able to support GUI and drawing controls via HDMI as the current MM's do on the LCD's?

Just curious.
Still love the TFT-based mites, but the pi-based one could open up MMBASIC for a whole heap of other things that need the speed that the Pi can provide over the PIC32 series of chips.
Smoke makes things work. When the smoke gets out, it stops!
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 5896
Posted: 04:23pm 07 Apr 2017
Copy link to clipboard 
Print this post

@grogster
Pi Zero 'should' be OK.

@Peter
After the problem with " initInitialise: Can't lock /var/run/pigpio.pid", I found mmbasic still running and consuming 99% of the CPU.
Killing that process and deleting the /var/run/pigpio.pid file gave me another error
  Quote  pi@cumulus:~/mmbasic$ sudo ./mmbasic
2017-04-08 12:01:41 initInitialise: bind to port 8888 failed (Address already in use)
LINUX MMBasic Version 5.3
Copyright 2011-2017 Geoff Graham
Copyright 2017 Peter Mather


I found another instance of mmbasic running (but this time using 0% CPU.
Killing that process and finally I could run mmbasic again.

Jim
VK7JH
MMedit   MMBasic Help
 
Tinine
Guru

Joined: 30/03/2016
Location: United Kingdom
Posts: 1646
Posted: 09:27pm 07 Apr 2017
Copy link to clipboard 
Print this post

  JohnS said  
  Tinine said   My question was a simple one-liner, based on the observation that, from the screen-shot, MM-Basic appears to recognize only 512K. Nothing about my wants/needs.


I cannot see why you don't understand about the memory: probably as much as you want.

Peter probably just made any version with a decent amount for testing so something could be done - like testing I/O.

You could do with being a lot less impatient. It's new. New versions of anything are normally missing some things someone would like. The alternative is we wait for maybe months with nothing at all posted - certainly not the ones that have been - so a fully-featured version could just spring forth. Not a great idea.

Truly no good deed goes unpunished!

John



What is there to "understand" about "probably"?

Nothing to do with being "impatient". I have never owned/used a Pi. For now, I have settled on the E-100, for a product that is already selling and it's already overkill for the application.

My question was merely a techical curiosity, the response could well have been along the lines of; MM-Basic was intended for microcontrollers and has some form of 9 bit memory addressing limitation.

For the same reason given above, "probably" is right up there with "assumption".

Tinine


 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8573
Posted: 09:54pm 07 Apr 2017
Copy link to clipboard 
Print this post

Jim

Thanks for your efforts in testing.

I need to work on the FILES command to make it compatible with the Micromite syntax. Currently it is just a hack version.

I'm going to try moving to the pigpio daemon in the next version. This will mean there is just one privileged process run at startup and then the mmbasic process can be run without root access. I think it will also mean multiple copies of mmbasic can be run at the same time but this needs proving.

I'm currently working on timed I/O which provides the basis for many of the commands and functions. DISTANCE and PULSIN are working but need tidying up. I hope to post a new version later today.

Re the 512K issue:

I don't intend to re-invent the MMBasic memory model and we don't want the MMBasic application to page so the memory size should be appropriate to the Pi in use. In my case a Pi3 has 1M of memory so 512K seems sensible. I'll make the memory size a parameter when running mmbasic so it can be tuned to the target pi and application.

e.g mmbasic -m512

 
cdeagle
Senior Member

Joined: 22/06/2014
Location: United States
Posts: 261
Posted: 11:26pm 07 Apr 2017
Copy link to clipboard 
Print this post

Tindie has a bunch of Raspberry PI hardware add-ons at the following link

https://www.tindie.com/browse/raspberry-pi/?page=1&pt=ac_cat_search
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 3650
Posted: 12:00am 08 Apr 2017
Copy link to clipboard 
Print this post

  matherp said   In my case a Pi3 has 1M of memory so 512K seems sensible.

Fair chance it has 1GB :)

Not today's task I expect, but you may want to lock pages in memory so it doesn't page in on what may be quite late but urgent usage of some part (e.g. an "interrupt").

JohnEdited by JohnS 2017-04-09
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 3650
Posted: 12:52am 08 Apr 2017
Copy link to clipboard 
Print this post

  Tinine said   the response could well have been along the lines of; MM-Basic was intended for microcontrollers and has some form of 9 bit memory addressing limitation

What a bizarre "could well" "9 bit memory addressing" would have been!!

Besides, had it been so I would have said so.

John
 
     Page 2 of 16    
Print this page
© JAQ Software 2024