Go to advanced search

by LizardLad_1
Thu Jul 04, 2019 2:58 am
Forum: Bare metal, Assembly language
Topic: Raspbery Pi 3 Undefined instruction
Replies: 11
Views: 641

Re: Raspbery Pi 3 Undefined instruction

Thanks to both of you for helping. DavidS my stacks are set up almost the same as LdB and are as follows: //"================================================================" // Set up stack pointers //"================================================================" mrs x1, mpidr_el1 // Read core ...
by LizardLad_1
Wed Jul 03, 2019 5:30 am
Forum: Bare metal, Assembly language
Topic: Raspbery Pi 3 Undefined instruction
Replies: 11
Views: 641

Re: Raspbery Pi 3 Undefined instruction

I'm sorry I wasn't clear about the last update. I forgot to mention that the same error occurs and that I thought surely it would have worked. So clearly something in the table is broken and if anyone can see what it is please point it out.
by LizardLad_1
Wed Jul 03, 2019 12:32 am
Forum: Bare metal, Assembly language
Topic: Raspbery Pi 3 Undefined instruction
Replies: 11
Views: 641

Re: Raspbery Pi 3 Undefined instruction

Thanks for the info. I put in a branch to what will become a handler but it doesn't seem to work. Here is the handler: .global _UND_handler _UND_handler: //Dump the stack from here somehow wfe b _UND_handler Here is the vector table // important, code has to be properly aligned .balign 0x800 _vector...
by LizardLad_1
Tue Jul 02, 2019 1:16 am
Forum: Bare metal, Assembly language
Topic: Raspbery Pi 3 Undefined instruction
Replies: 11
Views: 641

Raspbery Pi 3 Undefined instruction

Hello all, I'm back! I've has an issue which I haven't been able to pinpoint for a month or so now soi I was wondering if any of you would be willing to help. While running my kernel in QEMU I've come across a strange error. Taking exception 1 [Undefined Instruction] ...from EL2 to EL2 ...with ESR 0...
by LizardLad_1
Wed Apr 17, 2019 12:26 am
Forum: Bare metal, Assembly language
Topic: LdB's mailbox_tag_message funtion usage
Replies: 4
Views: 676

Re: LdB's mailbox_tag_message funtion usage

Thanks that was quite helpful however I'm still stuck on more complex ones like fetching the EDID, fetching a framebuffer, and get clocks with tag id 0x00010007.

EDIT 1: What is the call get command line used for?
by LizardLad_1
Sat Apr 13, 2019 11:33 pm
Forum: Bare metal, Assembly language
Topic: LdB's mailbox_tag_message funtion usage
Replies: 4
Views: 676

LdB's mailbox_tag_message funtion usage

Hello it's been a while since I was last on here and I'm starting to get back into this after taking a break. I've gone back to my codebase and I've found that there are mixed forms of mailbox calls and I would like to try and standardise them within my code. I really like that LdB's function reduce...
by LizardLad_1
Mon Dec 31, 2018 12:13 am
Forum: Bare metal, Assembly language
Topic: Writing to the framebuffer is slow
Replies: 24
Views: 6936

Re: Writing to the framebuffer is slow

With the help of LdB I've gotten this working so hopefully I can help. First question do you have the caches enabled and if not may I see your mbox code and your calls?
by LizardLad_1
Thu Oct 18, 2018 8:04 am
Forum: Bare metal, Assembly language
Topic: Multicore Code works on QEMU not on real hardware
Replies: 19
Views: 3874

Re: Multicore Code works on QEMU not on real hardware

Yes I didn't see the enumerated type thanks. I have been testing the code and it is very close to working. It executes the function forever until a new call comes through. I tried to fix it because I thought you had made an error by writing a zero to the read/clr register so I tried to write 0xFFFF ...
by LizardLad_1
Wed Oct 17, 2018 10:09 pm
Forum: Bare metal, Assembly language
Topic: Multicore Code works on QEMU not on real hardware
Replies: 19
Views: 3874

Re: Multicore Code works on QEMU not on real hardware

Also it says LONG_LONG_SIZE undefined how did you make it work?
by LizardLad_1
Wed Oct 17, 2018 8:57 pm
Forum: Bare metal, Assembly language
Topic: Multicore Code works on QEMU not on real hardware
Replies: 19
Views: 3874

Re: Multicore Code works on QEMU not on real hardware

Thank you it makes more sense now. The reason I wanted to be able to pass a void * is because I was going almost for a pthread interface. Yes on Monday I switched over to Linaro so I also changed all of the headers to the standard headers. I think when you forked my repo I hadn't pushed that change ...
by LizardLad_1
Wed Oct 17, 2018 8:43 am
Forum: Bare metal, Assembly language
Topic: Multicore Code works on QEMU not on real hardware
Replies: 19
Views: 3874

Re: Multicore Code works on QEMU not on real hardware

I tried implementing it to no avil it appears now even in qemu it doesn't work. I have pushed to github if you want to check my main and multicore files.
by LizardLad_1
Wed Oct 17, 2018 8:24 am
Forum: Bare metal, Assembly language
Topic: Multicore Code works on QEMU not on real hardware
Replies: 19
Views: 3874

Re: Multicore Code works on QEMU not on real hardware

Yep that makes sense, as a side note why did you choose that address for your mailbox?

UPDATE:
I have implemented exactly what you have written but it only shows a black screen.
by LizardLad_1
Wed Oct 17, 2018 6:07 am
Forum: Bare metal, Assembly language
Topic: Multicore Code works on QEMU not on real hardware
Replies: 19
Views: 3874

Re: Multicore Code works on QEMU not on real hardware

Thank you for that it is actually 30% faster than my original print function in QEMU so I would guess there would be larger speed improvements on the actual pi. Only minor edits were required to make your code compile. Mostly how you try and set the address of an array index to null. UPDATE: I reali...
by LizardLad_1
Tue Oct 16, 2018 9:39 am
Forum: Bare metal, Assembly language
Topic: Multicore Code works on QEMU not on real hardware
Replies: 19
Views: 3874

Re: Multicore Code works on QEMU not on real hardware

Thanks for your assistance however on testing the new printf implementation is more time consuming. Instead of printing all of what was passed to printf console_print is being called potentially hundreds of times to be able to print 3 lines. Is there a way to speed this up or not. If there isn't my ...
by LizardLad_1
Mon Oct 15, 2018 9:04 pm
Forum: Bare metal, Assembly language
Topic: Schematics/address map
Replies: 3
Views: 1766

Re: Schematics/address map

Hello there, Yes you are very close. The BCM2835 is almost identical to the BCM2836 only the peripheral address has been moved. Its new location is at 0x3F000000. This means you are able to use the BCM2835 peripherals document. Just substitute the MMIO base address and use the offsets from there. Th...
by LizardLad_1
Mon Oct 15, 2018 8:57 pm
Forum: Bare metal, Assembly language
Topic: Multicore Code works on QEMU not on real hardware
Replies: 19
Views: 3874

Re: Multicore Code works on QEMU not on real hardware

Thanks for the ideas about printing. I knew the error occurs in the core_wait_for_instruction part and I used that to keep the cores there when they aren't doing anything. When I call core_execute() a function pointer is set and the specified core is then taken from that function and executes someth...
by LizardLad_1
Mon Oct 15, 2018 10:55 am
Forum: Bare metal, Assembly language
Topic: Multicore Code works on QEMU not on real hardware
Replies: 19
Views: 3874

Re: Multicore Code works on QEMU not on real hardware

Thanks LdB for finding the mailbox message bugs. On a side note the malloc and free are there because I need them for my eventual use of this kernel. I'm eventually going to be recording gigabytes of sensor data on an autonomous bot. I'm just used to using malloc and free since I've mostly only prog...
by LizardLad_1
Sat Oct 13, 2018 10:14 am
Forum: Advanced users
Topic: Mesuring current
Replies: 3
Views: 611

Re: Mesuring current

Thanks for the info. I needed to get the stats of power consumption to make a portable pi.
by LizardLad_1
Sat Oct 13, 2018 10:03 am
Forum: Bare metal, Assembly language
Topic: Multicore Code works on QEMU not on real hardware
Replies: 19
Views: 3874

Multicore Code works on QEMU not on real hardware

Hello all, I have written a method of controlling other cores from core 0. It works in QEMU and in my x86 port of my code (the x86 port runs on posix compatible systems). When I try to run it on real hardware the function to initialize the cores hangs. I'm guessing this occurs because it only releas...
by LizardLad_1
Sat Oct 13, 2018 8:41 am
Forum: C/C++
Topic: compilation error in raspberry pi 3
Replies: 4
Views: 1916

Re: compilation error in raspberry pi 3

Hi,

No it isn't possible because who knows which one you might want? I know they do the same thing but imagine you had two functions named foo(). If one funcion printed "foo" and one printed "bar" how does the compiler know which one you wanted? That is why it can't happen.
by LizardLad_1
Sat Oct 13, 2018 12:01 am
Forum: Bare metal, Assembly language
Topic: Taking exception 3 [Prefetch Abort]
Replies: 12
Views: 4485

Re: Taking exception 3 [Prefetch Abort]

In reply to LdB's last comment, it turns out I was using linaro but I was using the linux targeted toolchain because that was provided by my host OS.
by LizardLad_1
Wed Oct 10, 2018 8:58 pm
Forum: Bare metal, Assembly language
Topic: Bare metal graphics : hardware acceleration ?
Replies: 11
Views: 4119

Re: Bare metal graphics : hardware acceleration ?

If you are interested in OpenGL ES 2 LdB is doing some really cool stuff check out this link: https://www.raspberrypi.org/forums/view ... 2&t=192440

If you aren't ready to do this the NEON way should be faster.
by LizardLad_1
Wed Oct 10, 2018 8:40 pm
Forum: Bare metal, Assembly language
Topic: Accelerated graphics
Replies: 53
Views: 17433

Re: Accelerated graphics

I have been trying the new GLES code and rendering it once the mmu is on and it worked. However there is a problem where if I render to the screen I cannot print to the screen and if I call another render the image is corrupted and I just get random green pixels everywhere. Is there a reason for thi...
by LizardLad_1
Wed Oct 10, 2018 10:30 am
Forum: Bare metal, Assembly language
Topic: Arm Core Clock Speeds
Replies: 3
Views: 1886

Re: Arm Core Clock Speeds

Thanks LdB that is quite useful information. My question was actually how do I control the clock speed of a particular core for example have core 0 set to max clock speed and cores 1, 2, 3 at min?
by LizardLad_1
Wed Oct 10, 2018 9:38 am
Forum: Advanced users
Topic: Mesuring current
Replies: 3
Views: 611

Mesuring current

Is it possible for the pi to measure the amount of current it is consuming. I don't mean how do I hook up an ammeter to the power supply but does the pi have an on-board measurement unit?

Go to advanced search