Not totally true: there has to be a file on the boot partition that we write, but it could just be another level of boot-loader.nick.mccloud wrote:On the Pi, the kernel HAS to be on the SD card
Got bare bones graphics working
58 posts
Page 2 of 3 1, 2, 3
rurwin wrote:Not totally true: there has to be a file on the boot partition that we write, but it could just be another level of boot-loader.
Which is basically what he says in the rest of the sentence you didn't quote.
- Posts: 150
- Joined: Wed Nov 23, 2011 1:29 pm
toxibunny wrote:
google 'sd slot extender'
Thanks, As these look ideal, but i can not find a UK suppler.
Batteries not included, Some assembly required.
nick.mccloud wrote:On the Pi, the kernel HAS to be on the SD card - once it's got started it can then look for the rest of the files where ever you tell it to, if it has the code and drivers to do so.
There two choses for this, write code to read/write SD card (not too hard) or as a temple measure, stick a floppy.img to end of kernel (kernel is very small anyway) and read from it with a basic fat driver.
Something like winimage could be used to add files to the image.
Batteries not included, Some assembly required.
Just a screenshot of DexOS working with Hdmi, plus my new R PI setup.




Batteries not included, Some assembly required.
Cool - can Joe Public get this?
Ostendo ignarus addo scientia.
- Posts: 1553
- Joined: Sun Mar 04, 2012 12:49 am
pygmy_giant wrote:Cool - can Joe Public get this?
If you mean, can Joe Public download a kernel.img and config.txt to test it sure, if anyone wants to test it, i can upload it to my site (read below).
But as it does nothing much yet, other than set display mode, display image and print to screen and turn led on/off.
I was waiting for it to be ably to do more, like interact with users.
Which i hope to get working in the coming days.
If you mean will the code be available then yes, but not until OS is use able too.
Batteries not included, Some assembly required.
DexOS wrote:pygmy_giant wrote:Cool - can Joe Public get this?
If you mean, can Joe Public download a kernel.img and config.txt to test it sure, if anyone wants to test it, i can upload it to my site (read below).
I'd love to test it if possible, I assume your site is http://www.dex-os.com, but I couldn't find it on there
Thanks
- Posts: 4
- Joined: Fri Jun 15, 2012 12:58 am
I class myself more of a nooby end user than developer but would help where I can with testing - I look forward to future release at your convenience.
Ostendo ignarus addo scientia.
- Posts: 1553
- Joined: Sun Mar 04, 2012 12:49 am
Here is the files if anyone wants to test
http://www.dex-os.com/DexOS_R_PI/DexOS_R_PI.zip
To test, just format a SD card to fat32 and add all the files in the "Put on SD card" folder, that's in the zip file.
Then just startup your raspberry pi with the SD card in.
Simple
.
Note: i have only tested with 2 GB SD card.
Any ?, just ask.
And thanks for testing.
Dex.
http://www.dex-os.com/DexOS_R_PI/DexOS_R_PI.zip
To test, just format a SD card to fat32 and add all the files in the "Put on SD card" folder, that's in the zip file.
Then just startup your raspberry pi with the SD card in.
Simple
Note: i have only tested with 2 GB SD card.
Any ?, just ask.
And thanks for testing.
Dex.
Batteries not included, Some assembly required.
Did as you said and got what you described - it set the display mode, correctly displayed an image on my Sharp 1024 x 768 monitor, printed to the screen (via an HDMI - > DVI adapter) and turned the led on/off. It booted in the blink of an eye and worked first time - my testing is successfully completed.
I did not waste an age 'burning' an 'image' to my SD card - I just copied the files from my windows PC! Legend has it that God handed moses the 10 commandments on the (50x 2gb Kingston elite) SD card that I used. This card was manufactured before the classification system was implimented, so I cannot tell you what 'class' it is - just that it is shaped like an SD card and behaves accordingly.
Good work
I did not waste an age 'burning' an 'image' to my SD card - I just copied the files from my windows PC! Legend has it that God handed moses the 10 commandments on the (50x 2gb Kingston elite) SD card that I used. This card was manufactured before the classification system was implimented, so I cannot tell you what 'class' it is - just that it is shaped like an SD card and behaves accordingly.
Good work
Ostendo ignarus addo scientia.
- Posts: 1553
- Joined: Sun Mar 04, 2012 12:49 am
pygmy_giant wrote:Did as you said and got what you described - it set the display mode, correctly displayed an image on my Sharp 1024 x 768 monitor, printed to the screen (via an HDMI - > DVI adapter) and turned the led on/off. It booted in the blink of an eye and worked first time - my testing is successfully completed.
I did not waste an age 'burning' an 'image' to my SD card - I just copied the files from my windows PC! Legend has it that God handed moses the 10 commandments on the (50x 2gb Kingston elite) SD card that I used. This card was manufactured before the classification system was implimented, so I cannot tell you what 'class' it is - just that it is shaped like an SD card and behaves accordingly.
Good work
Cool thanks for testing, hope to get a new image out soon with more functions.
Batteries not included, Some assembly required.
I wouldn't bother with the "encryption" stage next time. If someone can be bothered to fold your binary into something that can be disassembled, anything you can do is broken before you bother to start
It took me 2 minutes, but that's largely because I'm typing on a french keyboard but using an english keymap ;)
Hint :
Oh, yeah, works here too. Nice one
Simon
It took me 2 minutes, but that's largely because I'm typing on a french keyboard but using an english keymap ;)
Hint :
- Code: Select all
$ irb
>> out =File.new "dex.img","w+"
=> #<File:dex.img>
>> i = 0
=> 0
>> File.new("kernel.img").each_byte do |b|
?> if i < 0x803c|| i > 0x803c + 0x1494
>> out.putc b
>> else
?> out.putc b ^ 0xaa
>> end
>> i = i + 1
>> end
=> #<File:kernel.img>
>> out.close
=> nil
>> ^D
$ touch foo.c
$ arm-none-eabi-gcc -c foo.c -o foo
$ arm-none-eabi-objcopy --add-section dex=dex.img foo
$ arm-none-eabi-objdump -D foo | less
Oh, yeah, works here too. Nice one
Simon
- Posts: 1206
- Joined: Sun Sep 11, 2011 2:32 pm
tufty wrote:I wouldn't bother with the "encryption" stage next time. If someone can be bothered to fold your binary into something that can be disassembled, anything you can do is broken before you bother to start
It took me 2 minutes, but that's largely because I'm typing on a french keyboard but using an english keymap
Hint :
- Code: Select all
$ irb
>> out =File.new "dex.img","w+"
=> #<File:dex.img>
>> i = 0
=> 0
>> File.new("kernel.img").each_byte do |b|
?> if i < 0x803c|| i > 0x803c + 0x1494
>> out.putc b
>> else
?> out.putc b ^ 0xaa
>> end
>> i = i + 1
>> end
=> #<File:kernel.img>
>> out.close
=> nil
>> ^D
$ touch foo.c
$ arm-none-eabi-gcc -c foo.c -o foo
$ arm-none-eabi-objcopy --add-section dex=dex.img foo
$ arm-none-eabi-objdump -D foo | less
Oh, yeah, works here too. Nice one
Simon
Thanks tufty for testing.
And the simple xor did its job, not to stop, but to see who would want to disassemble it
Batteries not included, Some assembly required.
Critique time
I'd probably think about changing your function pre/postambles, you're wasting a word on every function.
Rather than this
you'd probably be better off using something like this
(or do the same using stmdb/ldmia, but push and pop are easier to read)
This not only saves you a word (which you could save in your postamble by simply moving rX to the pc), but also enables you to save any regs that might get smashed 'for free'. For a function that doesn't call any others, and doesn't smash any regs you care about (your wait routine springs to mind, all you have to do is move the loop counter to a 'smashable' register), I wouldn't even bother saving the link register, instead just exit with a simple
I'd probably think about changing your function pre/postambles, you're wasting a word on every function.
Rather than this
- Code: Select all
mov rX, lr
...
mov lr, rX
mov pc, lr
you'd probably be better off using something like this
- Code: Select all
push {rX-rY,lr}
...
pop {rX-rY, pc}
(or do the same using stmdb/ldmia, but push and pop are easier to read)
This not only saves you a word (which you could save in your postamble by simply moving rX to the pc), but also enables you to save any regs that might get smashed 'for free'. For a function that doesn't call any others, and doesn't smash any regs you care about (your wait routine springs to mind, all you have to do is move the loop counter to a 'smashable' register), I wouldn't even bother saving the link register, instead just exit with a simple
- Code: Select all
bx lr
- Posts: 1206
- Joined: Sun Sep 11, 2011 2:32 pm
DexOS wrote:toxibunny wrote:
google 'sd slot extender'
Thanks, As these look ideal, but i can not find a UK suppler.
Found 1 or 2 on ebay (but not cheap at £10+)
http://www.ebay.co.uk/itm/SD-card-extension-Cable-/110903317130?pt=UK_Photography_MemoryCardReaders_RL&hash=item19d25a528a
walney wrote:DexOS wrote:toxibunny wrote:
google 'sd slot extender'
Thanks, As these look ideal, but i can not find a UK suppler.
Found 1 or 2 on ebay (but not cheap at £10+)
http://www.ebay.co.uk/itm/SD-card-extension-Cable-/110903317130?pt=UK_Photography_MemoryCardReaders_RL&hash=item19d25a528a
Thanks walney, i will get one, i seen them at £35, so the price is OK.
Batteries not included, Some assembly required.
Hi Dex - some people like me who are interested in robotics/automation just want to access the GPIO pins and are not bothered about mouse/keyboard/display/usb (although an I2C / SPI driver would be useful). Could this be easily achieved by adapting your demo using a binary compiled from c libraries? I guess what I'm after is just a launch pad to boot straight into some compiled code with I2C / GPIO support.
For projects like a balancing robot or autonomous helicopter/drone less-is more as real-time control is critical.
Do you know how this could be done?
For projects like a balancing robot or autonomous helicopter/drone less-is more as real-time control is critical.
Do you know how this could be done?
Ostendo ignarus addo scientia.
- Posts: 1553
- Joined: Sun Mar 04, 2012 12:49 am
pygmy_giant wrote:Hi Dex - some people like me who are interested in robotics/automation just want to access the GPIO pins and are not bothered about mouse/keyboard/display/usb (although an I2C / SPI driver would be useful). Could this be easily achieved by adapting your demo using a binary compiled from c libraries? I guess what I'm after is just a launch pad to boot straight into some compiled code with I2C / GPIO support.
For projects like a balancing robot or autonomous helicopter/drone less-is more as real-time control is critical.
Do you know how this could be done?
You can take a look at the work of dwelch67
https://github.com/dwelch67/raspberrypi
Batteries not included, Some assembly required.
I don't have my Pi yet (hopefully soon). Just wanted to say great work so far on the "bare bones" approach, and I'm looking forward to being able to use this code! I'd like to be able to do some realtime stuff without too much extra overhead.
Edit: the github stuff from dwelch67 is very informative; he has some good info in the README files there.
Edit: the github stuff from dwelch67 is very informative; he has some good info in the README files there.
- Posts: 944
- Joined: Tue Nov 22, 2011 11:51 pm
jbeale wrote:I don't have my Pi yet (hopefully soon). Just wanted to say great work so far on the "bare bones" approach, and I'm looking forward to being able to use this code! I'd like to be able to do some realtime stuff without too much extra overhead.
Edit: the github stuff from dwelch67 is very informative; he has some good info in the README files there.
Thanks jbeale, i hope you find it useful.
Batteries not included, Some assembly required.
So as far as I can tell, the pi seems to ignore whatever values you pass it in the FB struct (e.g. for width/height) and just use the values from config.txt. Is this what's supposed to happen, or am I doing something wrong? I've not tried the linux framebuffer driver, but I assume that can switch modes on the fly, so it must be possible.
- Posts: 4
- Joined: Fri Jun 15, 2012 12:58 am
gillespie wrote:So as far as I can tell, the pi seems to ignore whatever values you pass it in the FB struct (e.g. for width/height) and just use the values from config.txt. Is this what's supposed to happen, or am I doing something wrong? I've not tried the linux framebuffer driver, but I assume that can switch modes on the fly, so it must be possible.
It should not ignore the values pass to FB struct and yes you can switch modes on the fly, has the above demo does.
Batteries not included, Some assembly required.
DexOS wrote:gillespie wrote:So as far as I can tell, the pi seems to ignore whatever values you pass it in the FB struct (e.g. for width/height) and just use the values from config.txt. Is this what's supposed to happen, or am I doing something wrong? I've not tried the linux framebuffer driver, but I assume that can switch modes on the fly, so it must be possible.
It should not ignore the values pass to FB struct and yes you can switch modes on the fly, has the above demo does.
Yeah sorry, it was just me being an idiot and using the wrong bit of memory... all is well now, thanks
- Posts: 4
- Joined: Fri Jun 15, 2012 12:58 am
A cool fractal demo by krom.
Running bare metal on Raspberry Pi.
Using FasmArm of cause.

Running bare metal on Raspberry Pi.
Using FasmArm of cause.

Batteries not included, Some assembly required.
