flat assembler
Message board for the users of flat assembler.
![]() Goto page Previous 1, 2, 3, 4 |
Author |
|
kalambong
I suspect the gooseberry is nothing other than a reference design which ARM provides to white box cellphone manufacturers in China and India
|
|||
![]() |
|
farrier
For a few dollars more:
http://www.bit-tech.net/news/hardware/2012/05/23/via-apc-8750/1 http://apc.io/about/ Choice, variety is good! _________________ Some Assembly Required It's a good day to code! U.S.Constitution; Bill of Rights; Amendment 1: ... the right of the people peaceably to assemble, ... The code is dark, and full of errors! |
|||
![]() |
|
farrier
An interview with a founder and principal in the Raspberry Pi project.
Eben Upton http://twit.tv/show/triangulation/61 Get the video version to see some of the user generated cases. Why the name? Why are there no version A's available? Version 60 of this series was with Nolan Bushnell of Atari. farrier _________________ Some Assembly Required It's a good day to code! U.S.Constitution; Bill of Rights; Amendment 1: ... the right of the people peaceably to assemble, ... The code is dark, and full of errors! |
|||
![]() |
|
Dex4u
I have uploaded a new tutorial (3) using DexBasic in bare metal on the Pi.
http://www.dex-os.com/DexBasic/Lesson3.htm This tutorial is on using the GPIO's. I will update the language part of the site tomorrow with the new functions. Note: I have implement the functions to be the same as the equivalent Arduino commands, so anyone who as programmed the arduino or tut available for the arduino, will be easy to convert. |
|||
![]() |
|
kalambong
Now they are claiming that Raspian OS runs 40% faster than Debian
http://techpp.com/2012/07/18/download-raspbian-os/ |
|||
![]() |
|
malpolud
I glanced at your webpage and it seems I've been looking for something like DexBasic. Cool, I'll check it out.
|
|||
![]() |
|
Dex4u
malpolud wrote: I glanced at your webpage and it seems I've been looking for something like DexBasic. Cool, I'll check it out. Also working on a add-on board for OS dev's, that adds keyboard and mouse support to the pi, without the need to write usb stack. |
|||
![]() |
|
f2
Great job, Dex! That give me the idea to restart osdeving again
![]() I'm curious to see the source code of the OS... just to know how it is made... ![]() |
|||
![]() |
|
Dex4u
f2 wrote: Great job, Dex! That give me the idea to restart osdeving again Thanks f2, You do not need to wait long, as once my pcb to add ps2 keyboard/mouse support to the pi, are done i will be releasing code ![]() |
|||
![]() |
|
Dex4u
Great link for bare metal raspberry pi coders http://www.cl.cam.ac.uk/freshers/raspberrypi/tutorials/os/
|
|||
![]() |
|
f2
Dex4u wrote: Great link for bare metal raspberry pi coders http://www.cl.cam.ac.uk/freshers/raspberrypi/tutorials/os/ Thank you for the link, Dex. This website contains all the things I needed to start coding for the RasPi. |
|||
![]() |
|
kalambong
http://www.cl.cam.ac.uk/freshers/raspberrypi/tutorials/os/
University of Cambridge is offering a 12-step online course on Ras-Pi The course, Baking Pi - Operating Systems Development, is aimed at students of 16 and over with some prior programming experience, "although younger readers may still find some of it accessible, particularly with assistance" |
|||
![]() |
|
Dex4u
kalambong wrote: http://www.cl.cam.ac.uk/freshers/raspberrypi/tutorials/os/ Thats what the above link is to ![]() |
|||
![]() |
|
krom
Hi All,
I am releasing my Mandelbrot fractal code as it will show you how to turn on the Floating Point unit of the Raspberry Pi. Rename this source code to kernel.asm and compile it with FASMARM to create a 408byte kernel.img file =D Code: ; Raspberry Pi 'Bare Metal' Mandelbrot Fractal Demo: ; 1. Turn on Vector Floating Point Unit ; 2. Setup Frame Buffer ; 3. Plot Fractal using Double-Precision ; ; Developers: ; Dex (Craig Bamford) - Original Frame Buffer Code ; krom (Peter Lemon) - Optimized Frame Buffer & Fractal Code ; ; Thanks to revolution for the FASMARM Assembler: http://arm.flatassembler.net/ ; ; To Run: ; Copy kernel.img to SD-Card (bootcode.bin, loader.bin, start.elf are also required) ; For best results create a config.txt file that contains the line: disable_overscan=1 ; ; For HDMI video output you can add config.txt lines to force a specific HDMI mode: ; hdmi_group=2, hdmi_mode=16 format binary as 'img' ; Setup Frame Buffer SCREEN_X = 640 SCREEN_Y = 480 BITS_PER_PIXEL = 32 ; Setup VFP VFPEnable = $40000000 VFPSingle = $300000 VFPDouble = $C00000 org $8000 ; Enable Vector Floating Point Calculations mrc p15,0,r0,c1,c0,2 ; R0 = Access Control Register orr r0,VFPSingle + VFPDouble ; Enable Single & Double Precision mcr p15,0,r0,c1,c0,2 ; Access Control Register = R0 mov r0,VFPEnable ; Enable VFP fmxr fpexc,r0 ; FPEXC = R0 FB_Init: adr r0,FB_STRUCT orr r0,1 ; MAIL_FB ldr r1,[MB_WRITE] str r0,[r1] ; Mail Box Write MBox_Read: ldr r1,[MB_READ] ldr r0,[r1] and r0,$F ; Load Channel Number cmp r0,1 ; Compare Frame Buffer Channel 1 bne MBox_Read ; Wait For Frame Buffer Channel 1 Data ldr r0,[FB_POINTER] ; R0 = Frame Buffer Pointer cmp r0,0 ; Compare Frame Buffer Pointer to Zero beq FB_Init ; IF Zero Re-Initialize Frame Buffer ldr r1,[LAST_PIXEL] add r0,r1 ; R0 = Frame Buffer Pointer Last Pixel mov r1,SCREEN_X ; Load Double Screen X fmsr s31,r1 fsitod d0,s31 ; D0 = X% fcpyd d2,d0 ; D2 = SX mov r1,SCREEN_Y ; Load Double Screen Y fmsr s31,r1 fsitod d1,s31 ; D1 = Y% fcpyd d3,d1 ; D3 = SY fldd d4,[XMAX] ; D4 = XMax fldd d5,[YMAX] ; D5 = YMax fldd d6,[XMIN] ; D6 = XMin fldd d7,[YMIN] ; D7 = YMin fldd d8,[RMAX] ; D8 = RMax fldd d9,[ONE] ; D9 = 1.0 ldr r12,[COL_MUL] ; R12 = Multiply Colour LoopY: fcpyd d0,d2 ; D0 = X% LoopX: fsubd d10,d4,d6 ; CX = XMin + ((X% * (XMax - XMin)) / SX) fmuld d10,d0 fdivd d10,d2 faddd d10,d6 ; D10 = CX fsubd d11,d5,d7 ; CY = YMin + ((Y% * (YMax - YMin)) / SY) fmuld d11,d1 fdivd d11,d3 faddd d11,d7 ; D11 = CY mov r1,192 ; R1 = IT (Iterations) fsubd d12,d12 ; D12 = ZX fsubd d13,d13 ; D13 = ZY Iterate: fmuld d14,d13,d13 ; XN = ((ZX * ZX) - (ZY * ZY)) + CX fmscd d14,d12,d12 faddd d14,d10 ; D14 = XN fmuld d15,d12,d13 ; YN = (2 * ZX * ZY) + CY faddd d15,d15 faddd d15,d11 ; D15 = YN fcpyd d12,d14 ; Copy XN & YN To ZX & ZY For Next Iteration fcpyd d13,d15 fmuld d14,d12,d12 ; R = (XN * XN) + (YN * YN) fmacd d14,d13,d13 ; D14 = R fcmpd d14,d8 ; IF R > 4 THEN GOTO Plot fmstat bgt Plot subs r1,1 ; IT -= 1 bne Iterate ; IF IT != 0 THEN GOTO Iterate Plot: mul r1,r12 ; R1 = Pixel Colour orr r1,$FF000000 ; Force Alpha To $FF str r1,[r0],-4 ; Store Pixel Colour into the Frame Buffer fsubd d0,d9 ; Decrement X% fcmpzd d0 fmstat bne LoopX ; IF X% != 0 LoopX fsubd d1,d9 ; Decrement Y% fcmpzd d1 fmstat bne LoopY ; IF Y% != 0 LoopY Loop: b Loop XMAX: dd 1.0 YMAX: dd 1.0 XMIN: dd -2.0 YMIN: dd -1.0 RMAX: dd 4.0 ONE: dd 1.0 COL_MUL: dw $231AF9 ; Multiply Colour LAST_PIXEL: dw (SCREEN_X * SCREEN_Y * (BITS_PER_PIXEL / 8)) - (BITS_PER_PIXEL / 8) MB_READ: dw $2000B880 ; PERIPHERAL_BASE + MAIL_BASE + MAIL_READ MB_WRITE: dw $2000B8A1 ; PERIPHERAL_BASE + MAIL_BASE + MAIL_WRITE + MAIL_FB align 16 FB_STRUCT: ; Frame Buffer Structure dw SCREEN_X ; Frame Buffer Pixel Width dw SCREEN_Y ; Frame Buffer Pixel Height dw SCREEN_X ; Frame Buffer Virtual Pixel Width dw SCREEN_Y ; Frame Buffer Virtual Pixel Height dw 0 ; Frame Buffer Pitch (Set By GPU) dw BITS_PER_PIXEL ; Frame Buffer Bits Per Pixel dw 0 ; Frame Buffer Offset In X Direction dw 0 ; Frame Buffer Offset In Y Direction FB_POINTER: dw 0 ; Frame Buffer Pointer (Set By GPU) dw 0 ; Frame Buffer Size (Set By GPU) |
|||
![]() |
|
Dex4u
Here is the latest DexOS port to the Pi, you will need a usb keyboard pluged in to test it.
http://www.dex-os.com/MinDos/PiDexOS.zip Its not finished yet, but it gives you a idea of what its like. Just format a SD card to fat32 and add the files from boot folder and the kernel.img and start you pi. Menu keys are enter, left, right arrow key and type help in cli. Note: Not all usb keyboards work about 50% so far. |
|||
![]() |
|
Dex4u
The source code (fasmarm) to the RPI port, is now open source:
http://www.dex-os.com/DexOS_R_PI/DexBasicSource.zip |
|||
![]() |
|
krom
I have made a Git Hub for all my complete R-Pi projects in bare metal:
https://github.com/PeterLemon/RaspberryPi This includes minimal Hello World CPU & DMA Demos, Tags Channel Demo, VFP Fractal Demos, NES & SNES Input Demos & Sound Demos. Screenshots of Input Demos: https://github.com/PeterLemon/RaspberryPi/blob/master/Input/NES/Controller/NESController.png https://github.com/PeterLemon/RaspberryPi/blob/master/Input/SNES/Controller/SNESController.png I have more to come: N64,PSX,PS2 Controller & SNES Mouse input. VFP software 3D engine. & some other surprises!! This should be a nice start... I hope this helps people out =D |
|||
![]() |
|
Goto page Previous 1, 2, 3, 4 < Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.
Website powered by rwasa.