Re: New to RISC OS? Read this!
thanks Tank I give it a look
-
- Posts: 1562
- Joined: Sun Mar 04, 2012 12:49 am
Re: New to RISC OS? Read this!
So to set GPIO 17 to read and print its value would I:
SYS "GPIO_Mode" ,17 ,0
PRINT SYS "GPIO_ReadData" ,17
?
SYS "GPIO_Mode" ,17 ,0
PRINT SYS "GPIO_ReadData" ,17
?
Re: New to RISC OS? Read this!
SYS "GPIO_WriteMode" ,17,0pygmy_giant wrote:So to set GPIO 17 to read and print its value would I:
SYS "GPIO_Mode" ,17 ,0
PRINT SYS "GPIO_ReadData" ,17
?
SYS "GPIO_ReadData" ,17 TO a%
PRINT a%
You need to get the value from the SWI into a variable and then display the variable.
SWI's just give you a simple way of sending commands to various parts of the OS/hardware.
They take the values you give them (EG the 17 above) and put them into the processors registers r0,r1,r2 ETC.
Then when the SWI has done its thing, the register values are returned to variables you add after the TO in the same order r0,r1 ETC.
Some SWI's need lots of things telling to them, others need nothing.
Some SWI's return lots of things, others nothing, depending what they do.
Last edited by tank on Tue Nov 06, 2012 9:05 pm, edited 1 time in total.
Re: New to RISC OS? Read this!
tank can I use a single call to the GPIO module if I wish to use pulse width modulation?
-
- Posts: 1562
- Joined: Sun Mar 04, 2012 12:49 am
Re: New to RISC OS? Read this!
Thanks.
SYS "GPIO_Mode" ,17,0
generates
'SWI name not known' on my machine
?!
SYS "GPIO_Mode" ,17,0
generates
'SWI name not known' on my machine
?!
Re: New to RISC OS? Read this!
No sorry, it only provides on/off SWI's.stylx wrote:tank can I use a single call to the GPIO module if I wish to use pulse width modulation?
You could program an on/off loop with variable delays between the on/off/on states though.
Re: New to RISC OS? Read this!
Sorry, dont know my own software.pygmy_giant wrote:Thanks.
SYS "GPIO_Mode" ,17,0
generates
'SWI name not known' on my machine
?!
SYS "GPIO_WriteMode" ,17,0
I'll edit the original post!!
-
- Posts: 1562
- Joined: Sun Mar 04, 2012 12:49 am
Re: New to RISC OS? Read this!
Thanks - I forgive you.
You have helped me successfully test my robot's wheel encoders
You have helped me successfully test my robot's wheel encoders

Re: New to RISC OS? Read this!
Their are two operating systems that I remember enjoying using in the past, one was Apollo's Aegis and the other was RISC OS.
Last time I was using an Archimedes, the big argument was that it was not 'true' multitasking. It is interesting that one the arguments for RISC OS are that it uses cooperative multitasking.
RISC OS used to come with a pretty good 'C' compiler. I never used BASIC but wrote several programmes using C.
The power of Linux is that it comes with a whole range of components that can be combined in new ways using scripting, so it is quite easy to build quite complex applications using any one of a number of scripting languages. I use Javascript, PHP and Bash predominantly.
Last time I was using an Archimedes, the big argument was that it was not 'true' multitasking. It is interesting that one the arguments for RISC OS are that it uses cooperative multitasking.
RISC OS used to come with a pretty good 'C' compiler. I never used BASIC but wrote several programmes using C.
The power of Linux is that it comes with a whole range of components that can be combined in new ways using scripting, so it is quite easy to build quite complex applications using any one of a number of scripting languages. I use Javascript, PHP and Bash predominantly.
RPi running Rasbian, SheevaPlug and DreamPlug both running Debian Wheezy, 2 netbooks both running Debian Wheezy with Gnome 3.
-
- Posts: 33
- Joined: Fri Sep 09, 2011 10:04 am
- Location: Perth WA
Re: New to RISC OS? Read this!
Get nut Pi its all you will need with the addition of a free down load of fireworks.
Re: New to RISC OS? Read this!
Not sure this is the right place, or should I have started a new thread? To late now, I'm putting it here!
Ok, it's working well - I knew it would - thanks for all the hard work!
One question:
I set up the network, and I can see all my other ShareFS drives.
I set up the RamDisc, and I can see where to share it, and Lo! I can see that on my RiscPC, etc.
But I can't share anything else! There's no menu item for sharing on any folder.
I think I saw it one time - but that was with the monitor over the other side of the room, where I couldn't really see what I was doing. now my monitor's where I can see it, it's gone!
I've done the quick 'n dirty by putting an obey file in choices.boot.predesk, and it works fine.
But it'd be nice to know what I'm doing wrong.
Ok, it's working well - I knew it would - thanks for all the hard work!
One question:
I set up the network, and I can see all my other ShareFS drives.
I set up the RamDisc, and I can see where to share it, and Lo! I can see that on my RiscPC, etc.
But I can't share anything else! There's no menu item for sharing on any folder.
I think I saw it one time - but that was with the monitor over the other side of the room, where I couldn't really see what I was doing. now my monitor's where I can see it, it's gone!
I've done the quick 'n dirty by putting an obey file in choices.boot.predesk, and it works fine.
But it'd be nice to know what I'm doing wrong.
Re: New to RISC OS? Read this!
can we make it use the full size of the screen
i.e.
1920x1200
or even in portrait mode
1200x1920
i.e.
1920x1200
or even in portrait mode
1200x1920
How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.html
WARNING - some parts of this post may be erroneous YMMV
1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe
WARNING - some parts of this post may be erroneous YMMV
1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe
Re: New to RISC OS? Read this!


-
- Posts: 4
- Joined: Tue Nov 13, 2012 1:41 pm
Re: New to RISC OS? Read this!
Hi. I'm new to Pi and very new to RISCOS. I have Pi running Rasbian, which I started by using the preloaded SD card from Maplin. I have upgraded the software over the web, and it is running fine. Last week I downloaded RISCOS, using the instructions I found on the Pi site, and I created an SD card. I am getting some results, but not all that I expected. Any idea what I might be doing wrong?
So far:
1. From Win 7 laptop: downloaded RISCOS zip file and unzipped it to about 2GB file.
2. Downloaded Win32diskimager .exe and ran it, identifying unzipped filed as input and G: (SD card) as output.
3. Finished up with six files on zip card:
BOOTCODE.BIN
CONFIG
FIXUP.DAT
LICENCE.BROADCOM
RISCOS
START.ELF
4. Loaded SD card into slot on RASPI and powered up.
5. There was a flash of splash screen in colour, then got a panel saying: Message from desktop - Machine startup has not completed successfully: 'the disk drive is empty' - CANCEL/RETRY
6. RETRY cycles back through 5.
7. CANCEL brings up the RISCOS desktop, with four icons in the bar ar the bottom: SD card, Apps, Monitor, Raspberry symbol.
8. SD card symbol is labelled 0 and clicking tells you there's no data.
9. Apps symbol shows six application symbols, and you can invoke them: draw, text, etc.
10. Monitor symbol allows you to resize display.
11. Raspberry symbol presents: task list, dynamic areas list, system memory allocation.
12. After that I have no other tools or applications visible, and no controls that allow me to do anything, even shut down. I have to disconnect power supply to shut down.
So, I have installed and powered up a subset of RISCOS, but don't know how to make it usable. Any suggestions?
The only other information I can give you is that I have been using a large (16GB) SD card.
Thanks
So far:
1. From Win 7 laptop: downloaded RISCOS zip file and unzipped it to about 2GB file.
2. Downloaded Win32diskimager .exe and ran it, identifying unzipped filed as input and G: (SD card) as output.
3. Finished up with six files on zip card:
BOOTCODE.BIN
CONFIG
FIXUP.DAT
LICENCE.BROADCOM
RISCOS
START.ELF
4. Loaded SD card into slot on RASPI and powered up.
5. There was a flash of splash screen in colour, then got a panel saying: Message from desktop - Machine startup has not completed successfully: 'the disk drive is empty' - CANCEL/RETRY
6. RETRY cycles back through 5.
7. CANCEL brings up the RISCOS desktop, with four icons in the bar ar the bottom: SD card, Apps, Monitor, Raspberry symbol.
8. SD card symbol is labelled 0 and clicking tells you there's no data.
9. Apps symbol shows six application symbols, and you can invoke them: draw, text, etc.
10. Monitor symbol allows you to resize display.
11. Raspberry symbol presents: task list, dynamic areas list, system memory allocation.
12. After that I have no other tools or applications visible, and no controls that allow me to do anything, even shut down. I have to disconnect power supply to shut down.
So, I have installed and powered up a subset of RISCOS, but don't know how to make it usable. Any suggestions?
The only other information I can give you is that I have been using a large (16GB) SD card.
Thanks
Re: New to RISC OS? Read this!
Sounds like your SD card is the problem:
Discussion heretheom wrote:'Disk drive is empty' means that the RISC OS partition on your SD card can't be detected. This either means you didn't write the SD card right, or RISC OS doesn't like your SD card, or you have power supply problems.
To see if RISC OS can at least find your SD card, press F12 and type
*SDIODevices
and see if anything is listed.
If your SD card is OK but badly written, it should show up. If RISC OS can't talk to it at all, it'll report no cards
-
- Posts: 4
- Joined: Tue Nov 13, 2012 1:41 pm
Re: New to RISC OS? Read this!
Thanks Theom. Also, thanks to UKScone on the Error on Boot thread. Although I was getting a partial boot, it clearly was mostly a failure. UKScone's pointer to the www.sdcard.org/downloads/formatter got me the utility to fix the SD card. Only when I ran that did I realise that the card appeared to have only 32 MB, not the 16GB I paid for! The formatter fixed that when I had selected FULL format. I downloaded RISCOS onto the card, as recommended, and it now boots fully (though I still have to play with it to find out all the stuff I've got). But there are no error messages, and there seems to be lots to play with.
Thanks all!
Thanks all!

-
- Posts: 4277
- Joined: Sun Jan 15, 2012 1:11 pm
Re: New to RISC OS? Read this!
It should be pointed out, once again, that this whole "It shrunk my card! It's only 32M!" idea is completely bogus. It has nothing to do with anything in the Linux world or the Linux side of things. It is merely an artifact of Windows. Repeat: It has nothing to do with anything relevant to the Pi; it is only when you load the SD card onto a machine running that other OS that you see this effect.Only when I ran that did I realise that the card appeared to have only 32 MB, not the 16GB I paid for! The formatter fixed that when I had selected FULL format.
A couple of other points related to this:
1) It is not necessary to reformat the card before re-writing the image to it. I've never had to do that, and I've had my share of "bad image writes". It may be necessary in some pathological cases, but it is certainly not necessary in the general case.
2) It does seem pretty common - this basic problem when writing the RISCOS image to the card. I wonder why... I also wish the error message were a bit clearer - and made it clear that this is a fatal error - it is not just a spurious thing that you can click past and get on with your work.
And some folks need to stop being fanboys and see the forest behind the trees.
(One of the best lines I've seen on this board lately)
(One of the best lines I've seen on this board lately)
-
- Posts: 4
- Joined: Tue Nov 13, 2012 1:41 pm
Re: New to RISC OS? Read this!
Hey Joe. (I am old enough to want to sing that as I type). I agree: Linux is in no way implicated. It all happened under Windows. I don't know why, but it refused to see the whole card.
Cheers, Jim
Cheers, Jim
Re: New to RISC OS? Read this!
Actually, you can use RISC OS without an SD card - all you need is riscos.img from the FAT partition to get you started. It's a bit like Safe Mode in Windows in that it's a bit limited, but it's generally more usable. It also boots very fast because it doesn't need to interact with the SD at all beyond loading the initial 2.2MB ROM image. You can configure your machine to not boot off SD at all (*Configure NoBoot) if you want to do things without loading the startup stuff - it'll still be useful.
So it's a bit awkward to declare this a fatal error, because it isn't. However I agree that it's not what a first-time RISC OS user expects.
So it's a bit awkward to declare this a fatal error, because it isn't. However I agree that it's not what a first-time RISC OS user expects.
-
- Posts: 4277
- Joined: Sun Jan 15, 2012 1:11 pm
Re: New to RISC OS? Read this!
Heh heh...
And some folks need to stop being fanboys and see the forest behind the trees.
(One of the best lines I've seen on this board lately)
(One of the best lines I've seen on this board lately)
-
- Posts: 20
- Joined: Mon Dec 31, 2012 6:19 pm
Re: New to RISC OS? Read this!
very new to RISCOS and have 2 questions
1. how do you shut down? I just pulled the plug which seemed to work fine, but I imagine that's not a good idea
2.is there a way to zoom in on desktop? i can barely read application names etc.
thanks
1. how do you shut down? I just pulled the plug which seemed to work fine, but I imagine that's not a good idea
2.is there a way to zoom in on desktop? i can barely read application names etc.
thanks
Re: New to RISC OS? Read this!
To shut down either press CTRL-SHIFT-F12 or Select 'Shutdown' from the switcher menu (the menu obtained by pressing 'MENU' (the central mouse button) over the task manager icon (the raspberry at the right of the icon bar).
Use a different screen resolution to make text bigger.
Use a different screen resolution to make text bigger.
-
- Posts: 20
- Joined: Mon Dec 31, 2012 6:19 pm
Re: New to RISC OS? Read this!
how do I change screen resolution?
Re: New to RISC OS? Read this!
http://www.raspberrypi.org/phpBB3/viewt ... 55&t=25739newuser3000 wrote:how do I change screen resolution?
Re: New to RISC OS? Read this!
Has anyone been able to solve this problem?jiminhursley wrote:5. There was a flash of splash screen in colour, then got a panel saying: Message from desktop - Machine startup has not completed successfully: 'the disk drive is empty' - CANCEL/RETRY
I've tried multiple SD cards of varying size. I've tried writing them in different ways. I've varied the power supply.
Is it the Pi? I really don't want to have to order a new one just to see the same problem.