Go to advanced search

by cleverca22
Fri Dec 06, 2019 4:17 am
Forum: Bare metal, Assembly language
Topic: BCM2711B0
Replies: 34
Views: 5668

Re: BCM2711B0

That 512KB boot EEPROM is so calling to me :D How much of an OS can fit in that? That depends on how big the OS is, and how much is leftover after the firmware is in it. [clever@amd-nixos:~/apps/rpi/rpi-eeprom/firmware/beta]$ ls -lh main-body.bin bootconf.txt memsys0?.bin mcb.bin -rw-r--r-- 1 cleve...
by cleverca22
Fri Dec 06, 2019 12:59 am
Forum: Bare metal, Assembly language
Topic: [Solved] multicore confusion
Replies: 6
Views: 262

Re: multicore confusion

https://github.com/raspberrypi/tools/tr ... r/armstubs

the official stubs are also available in source form

you can read those to get ideas, or just to understand how to interact with them and leave them as-is
by cleverca22
Sat Nov 30, 2019 3:58 pm
Forum: Graphics programming
Topic: 8 bits-per-pixel mode on the R4b
Replies: 2
Views: 214

Re: 8 bits-per-pixel mode on the R4b

another option you could look into is the dispmanx api https://github.com/raspberrypi/firmware/blob/master/opt/vc/src/hello_pi/hello_dispmanx/dispmanx.c https://github.com/raspberrypi/firmware/blob/64b5649a41b69d09bfe0ed05448d28a66be3edfd/hardfp/opt/vc/include/interface/vctypes/vc_image_types.h#L63 ...
by cleverca22
Sat Nov 30, 2019 3:53 pm
Forum: Graphics programming
Topic: Best way to handle sprites
Replies: 10
Views: 426

Re: Best way to handle sprites

if you dont mind it being raspberry pi specific, you should look into dispmanx

that api lets you draw rgba images at any xy coordinate you want, and it can draw ontop of the framebuffer or even x11

https://github.com/raspberrypi/firmware ... dispmanx.c
by cleverca22
Sat Oct 24, 2015 11:53 am
Forum: Bare metal, Assembly language
Topic: Only Core 1 is running. Not able to get Core 0,2 and 3 run
Replies: 3
Views: 1221

Re: Only Core 1 is running. Not able to get Core 0,2 and 3 r

i believe each bank of 32 GPIO also has a dedicated set and clear register, where writting a 1 to any bit will set or clear that pin, allowing you to turn an LED on or off with a single atomic write, rather then read+or+write and risk race conditions (2 cores read, both or'd, one write wins)
by cleverca22
Fri Oct 23, 2015 8:14 am
Forum: Troubleshooting
Topic: Headless heating control system hangs
Replies: 5
Views: 1358

Re: Headless heating control system hangs

another option is to use "setterm -blank 0 -powerdown 0" in rc.local to disable the power saving features (they don't save power anyways)

then the screen will work when you plug in a tv, even if it has locked up fully
by cleverca22
Sat May 09, 2015 10:20 pm
Forum: General discussion
Topic: There are some errors to build a kernel module.
Replies: 16
Views: 2411

Re: There are some errors to build a kernel module.

the Module.symvers must be from the same version as the kernel.img you are running, and the same for the linux source itself
you should find the github revisions for that somewhere in /boot/
by cleverca22
Wed May 06, 2015 7:26 pm
Forum: Off topic discussion
Topic: Buck regulators and funny little pots
Replies: 8
Views: 1361

Re: Buck regulators and funny little pots

doesnt the uno still have a usb input it can run from?
by cleverca22
Wed May 06, 2015 7:20 pm
Forum: Troubleshooting
Topic: Boot Files?
Replies: 3
Views: 918

Re: Boot Files?

the kernel.img version must match the .ko files for all of the modules, so if you get the wrong one, you loose all of the 'optional' drivers i think your simplest option is to get the 'latest' kernel.img you had deleted (must be the one from the day you updated), and the older start.elf/bootcode.bin...
by cleverca22
Wed May 06, 2015 1:41 am
Forum: Off topic discussion
Topic: Roadblocks to the future
Replies: 9
Views: 1704

Re: Roadblocks to the future

what about the older USB plugs that you often find on scanners and printers?, that should have more current capacity, still a common cable people are likely to have, and its still locked to 5v so no pi-killer It's physically huge. Either it takes too much space on the PCB, or the PCB must be embigg...
by cleverca22
Wed May 06, 2015 1:13 am
Forum: Off topic discussion
Topic: Roadblocks to the future
Replies: 9
Views: 1704

Re: Roadblocks to the future

what about the older USB plugs that you often find on scanners and printers?, that should have more current capacity, still a common cable people are likely to have, and its still locked to 5v so no pi-killer
by cleverca22
Thu Apr 16, 2015 6:30 am
Forum: Advanced users
Topic: Connecting Unity to Raspberry Pi
Replies: 10
Views: 10403

Re: Connecting Unity to Raspberry Pi

simplest solution i can see is to just open a tcp or udp socket between unity and the pi, then fire commands over that instead of a serial port
by cleverca22
Mon Mar 09, 2015 12:35 pm
Forum: Bare metal, Assembly language
Topic: Running bare metal code on only one core?
Replies: 6
Views: 2273

Re: Running bare metal code on only one core?

i think it would be much simpler to just use a custom kernel driver to run a chunk of baremetal code in linux's kernel space and maybe turn off preemption on that core so whatever program ran your custom ioctl on the custom device, will basically hijack an entire core until your job is done running ...
by cleverca22
Wed Feb 25, 2015 2:54 pm
Forum: Advanced users
Topic: RPI2 Issue with GPU threads
Replies: 6
Views: 1959

Re: RPI2 Issue with GPU threads

/dev/fb0 is also a dispmanx layer, the GPU hides all of the dispmanx api from you when using it
by cleverca22
Tue Feb 24, 2015 1:37 pm
Forum: General discussion
Topic: Ethernet connector concern
Replies: 12
Views: 2000

Re: Ethernet connector concern

thats the usb hub and ethernet controller, seperate from the magjack
by cleverca22
Tue Feb 10, 2015 10:50 pm
Forum: Advanced users
Topic: Pi2 qemu choot?
Replies: 5
Views: 5788

Re: Pi2 qemu choot?

rasbian on the pi2 is still compiled in armv6 mode, to keep backwards compat with the pi1, so the old mode should keep working

the kernel is the only part that has been fixed, and qemu-user skips the kernel
by cleverca22
Tue Feb 10, 2015 6:59 am
Forum: Advanced users
Topic: Pi2 qemu choot?
Replies: 5
Views: 5788

Re: Pi2 qemu choot?

and thats not how you chroot, thats a full emulation of the entire system

if you want a true chroot, you need something like https://github.com/cleverca22/crosspiroot (note, scripts may need updating)
by cleverca22
Sun Feb 08, 2015 3:41 am
Forum: Other projects
Topic: Power button that does a clean shutdown?
Replies: 6
Views: 5251

Re: Power button that does a clean shutdown?

http://spritesmods.com/?art=rpi_arcade&page=5

complete battery based solution here, may need to modify it some to get it to fit your case, it also includes an app that monitors the gpio pin to run shutdown, and cut its own power
by cleverca22
Thu Feb 05, 2015 11:23 pm
Forum: Bare metal, Assembly language
Topic: BCM 2836 and the RPi 2 ?
Replies: 95
Views: 30559

Re: BCM 2836 and the RPi 2 ?

urm, as my interests mainly lie in 'bare-metal' programming (and my development work is done in a debian VM with a cross compiler and a serial link upload gizmo) this 'device tree' stuff isn't going to work for me so like the rest of us 'bare-metal' nerds I am going to have to use a #define for the...
by cleverca22
Thu Feb 05, 2015 7:06 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: Connect Capactive Touch Screen to Raspberry Pi B Type (I2C)
Replies: 25
Views: 9035

Re: Connect Capactive Touch Screen to Raspberry Pi B Type (I

just stumbled upon the code i was using #include <linux/input.h> #include <linux/i2c/mpr121_touchkey.h> #include <linux/i2c.h> #include <mach/gpio.h> unsigned short keymap[] = { KEY_ENTER }; struct mpr121_platform_data touch_data = { .keymap = keymap, .keymap_size = ARRAY_SIZE(keymap) }; static stru...
by cleverca22
Wed Feb 04, 2015 6:38 pm
Forum: Off topic discussion
Topic: DRAM + NAND Chip
Replies: 4
Views: 1176

Re: DRAM + NAND Chip

the compute module solves that by letting you turn the whole thing into a usb drive, so you can re-flash the onboard chip over usb

but getting that on a model a/b would require some more complex changes to the usb area
by cleverca22
Wed Feb 04, 2015 6:15 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: Connect Capactive Touch Screen to Raspberry Pi B Type (I2C)
Replies: 25
Views: 9035

Re: Connect Capactive Touch Screen to Raspberry Pi B Type (I

Hi, after getting the connector for the touchscreen, unfortunately it does not work. The module edt_ft5x06 is loaded but does not seem to be used (with lsmod). And when I try i2cdetect -y 1, I see there is something on address 38, but the company who sold the touchscreen says that it has to be 70. ...
by cleverca22
Wed Feb 04, 2015 6:10 pm
Forum: Bare metal, Assembly language
Topic: Task switching
Replies: 2
Views: 1155

Re: Task switching

if i remember the stuff i found when exploring the linux kernel correctly the task switching is implemented in a very simple way, all it does is change the stack pointer, so return goes to the 'wrong' place (into another thread that had previously given up the cpu) just create a schedule() function ...
by cleverca22
Tue Feb 03, 2015 11:16 pm
Forum: Bare metal, Assembly language
Topic: BCM2835 Serial Number
Replies: 5
Views: 2060

Re: BCM2835 Serial Number

though thats still not really reading it directly from a register, its just asking the GPU blob to fetch it for you
by cleverca22
Mon Jan 26, 2015 9:50 pm
Forum: HATs and other add-ons
Topic: Battery connected to GPIO
Replies: 2
Views: 711

Re: Battery connected to GPIO

i know the usb devices will refuse to work on 3.7 volts i'm not sure how well the cpu would run on 3.7 but there is another route that i have used on my pi, https://www.sparkfun.com/products/11231 this will boost the 3.7 up to 5v, so you can just power it from 5v normally and everything will work fine

Go to advanced search