Go to advanced search

by rplantz
Thu Feb 13, 2020 2:49 am
Forum: C/C++
Topic: Procedure linkage table
Replies: 0
Views: 271

Procedure linkage table

In x86-64 when I compile to assembly language: #include <stdio.h> int main(void) { printf("Hello.\n"); return 0; } gcc produces a call puts@plt to do the output. The @plt is required because puts is dynamically loaded from a C standard library. If I delete the @plt, I get a segmentation fa...
by rplantz
Wed Jun 26, 2019 2:45 am
Forum: General discussion
Topic: 64-bit OS for RPi?
Replies: 3
Views: 834

64-bit OS for RPi?

Okay, "best" is relative, so I'll explain my application. I have written a book about ARM assembly language using the RPi (http://bob.cs.sonoma.edu/IntroCompOrg-RPi/intro-co-rpi.html). It uses the GNU programming tools -- gcc, as, make, gdb, etc. The book is used at several colleges. I'm a...
by rplantz
Mon Jan 21, 2019 5:29 pm
Forum: General discussion
Topic: 64-bit operating system
Replies: 358
Views: 156067

Re: 64-bit operating system

Most still probably don't need 64bit, those that want 64bit, why? Let's face it, I don't need most of the things I have, including my Raspberry Pis. I'm rewriting my assembly language book that uses the Raspberry Pi, and I would like to use AARCH64 because it's a cleaner architecture. I want to kee...
by rplantz
Fri Sep 21, 2018 3:31 am
Forum: Teaching and learning resources
Topic: Free assembly language book available online
Replies: 41
Views: 41688

Re: Free assembly language book available online

I'm sorry that the book does not meet your needs. I have some contractual agreements regarding use of the material, so there isn't much I can do at this time. The contract does allow me to maintain a free copy online, but I cannot share the source. As stated on my website, I am retired, so all the w...
by rplantz
Fri Feb 02, 2018 4:03 am
Forum: Bare metal, Assembly language
Topic: assembly language programming
Replies: 7
Views: 4189

Re: assembly language programming

I have a chapter in my online book that provides an introduction to programming the GPIO in assembly language: http://bob.cs.sonoma.edu/IntroCompOrg-RPi/chp-gpio.html . The rest of the book is an introduction to assembly language programming on the RPi using the GNU development tools. I make extensi...
by rplantz
Wed Apr 12, 2017 4:17 pm
Forum: Raspberry Pi OS
Topic: Raspbian Jessie (64bit) for RPi3?
Replies: 145
Views: 143189

Re: Raspbian Jessie (64bit) for RPi3?

Excellent points by jamesh and jahboater. If you read the short Preface to my book, http://bob.cs.sonoma.edu/IntroCompOrg-RPi/sec-preface.html , I think you will see that I agree with your philosophy. You're right that moving to a different environment means learning new things, and that the main th...
by rplantz
Tue Apr 11, 2017 6:56 pm
Forum: Raspberry Pi OS
Topic: Raspbian Jessie (64bit) for RPi3?
Replies: 145
Views: 143189

Re: Raspbian Jessie (64bit) for RPi3?

I think its probably a bad idea to teach A32. Well despite the fact that I'm substantially in sympathy with your interest in AArch64 etc, I would point out that there are around a gazillion(*) ARM32 systems out there that are likely to be part of the world of students going into the not-desktop sof...
by rplantz
Mon Apr 10, 2017 2:14 pm
Forum: Raspberry Pi OS
Topic: Raspbian Jessie (64bit) for RPi3?
Replies: 145
Views: 143189

Re: Raspbian Jessie (64bit) for RPi3?

My other concern was with students getting reliant on features such as "most instructions being conditional", or being able to write random values to the PC, or ldm/stm, and so on. They will get a rude shock when they move to x86, or A64, or other ISA's, where that sort of thing is not po...
by rplantz
Sun Apr 09, 2017 7:57 pm
Forum: Raspberry Pi OS
Topic: Raspbian Jessie (64bit) for RPi3?
Replies: 145
Views: 143189

Re: Raspbian Jessie (64bit) for RPi3?

Rather than wishing for something, which may or may not happen sometime in the future. Use an AArch64 Linux Operating System which is available today :) Yes, I'm looking. One of the nice things about Raspbian is its stability and ease of use. From my very limited investigation of the others, they a...
by rplantz
Sun Apr 09, 2017 6:49 pm
Forum: Raspberry Pi OS
Topic: Raspbian Jessie (64bit) for RPi3?
Replies: 145
Views: 143189

Re: Raspbian Jessie (64bit) for RPi3?

64 bits = no difference whatsoever to educational market. There are very few areas, if any, where you NEED a 64 bit device/OS. Any and all teaching, TBH, could be done in 8 or 16 bits. This depends on which education market. As I noted above, my university uses the RPi to teach introduction to comp...
by rplantz
Wed Apr 05, 2017 6:39 pm
Forum: Raspberry Pi OS
Topic: Raspbian Jessie (64bit) for RPi3?
Replies: 145
Views: 143189

Re: Raspbian Jessie (64bit) for RPi3?

My interest in 64-bit is in the classroom. We use the RPi for teaching introduction to computer organization at our university (bob.cs.sonoma.edu). The subsequent class uses the Arm Edition of Patterson & Hennessy's "Computer Organization and Design." This book uses a subset of AARCH64...
by rplantz
Wed Jan 04, 2017 12:52 am
Forum: Beginners
Topic: ssh security
Replies: 2
Views: 797

Re: ssh security

Thank you for your very quick response, DougieLawson. I thought that was the case, but network security is not my expertise. Elections are safe from me. :-)
by rplantz
Wed Jan 04, 2017 12:20 am
Forum: Beginners
Topic: ssh security
Replies: 2
Views: 797

ssh security

I use ssh to get to my RPi on my LAN using name.local. I often access it headless, so it boots into the pi account. Do I need to worry about someone accessing it from beyond my router? I'm running Raspbian.
by rplantz
Mon Dec 05, 2016 1:58 am
Forum: Raspberry Pi OS
Topic: /dev/gpiomem versus /dev/mem
Replies: 1
Views: 2353

/dev/gpiomem versus /dev/mem

I posted the following on "Bare Metal" and was told that it is a Linux question, so I'm reposting here: Can someone point me to a discussion of the difference between using /dev/gpiomem and /dev/mem to access the GPIO? I've tried both. They both work, and both require sudo to run the progr...
by rplantz
Sun Dec 04, 2016 11:58 pm
Forum: General discussion
Topic: /dev/gpiomem versus /dev/mem
Replies: 2
Views: 832

Re: /dev/gpiomem versus /dev/mem

Thank you, Joan, for (a) correcting my posting location, and (b) answering my question.
by rplantz
Sun Dec 04, 2016 11:49 pm
Forum: General discussion
Topic: /dev/gpiomem versus /dev/mem
Replies: 2
Views: 832

/dev/gpiomem versus /dev/mem

Can someone point me to a discussion of the difference between using /dev/gpiomem and /dev/mem to access the GPIO? I've tried both. They both work, and both require sudo to run the program they're used in. I'm doing this for my textbook. I'm inclined to use /dev/mem because that seems more general. ...
by rplantz
Wed Nov 16, 2016 9:34 pm
Forum: Raspberry Pi OS
Topic: AARCH64 version of Raspbian?
Replies: 19
Views: 8303

Re: AARCH64 version of Raspbian?

I sincerely appreciate the many comments here. Very helpful. I will play with SUSE and Fedora to see if they are stable enough for a classroom setting. I don't want students to be spending a lot of time getting the OS to work. I do make a few remarks about 64-bit in the current book, but I need to b...
by rplantz
Tue Nov 15, 2016 11:34 pm
Forum: Raspberry Pi OS
Topic: AARCH64 version of Raspbian?
Replies: 19
Views: 8303

Re: AARCH64 version of Raspbian?

jahboater wrote:The register may be omitted and in which case x30 is used.
GCC just does a plain "ret"
As god intended. :-) Thanks again for the help.
by rplantz
Tue Nov 15, 2016 11:11 pm
Forum: Raspberry Pi OS
Topic: AARCH64 version of Raspbian?
Replies: 19
Views: 8303

Re: AARCH64 version of Raspbian?

For example, gcc uses ldmfd to pop the return address off the stack into the pc, but AARCH64 doesn't have this instruction. So I use the AARCH64 idiom -- move the stack pointer, load the return address into the link register, then branch via the link register. Are you sure? GCC uses the "ret&q...
by rplantz
Tue Nov 15, 2016 10:07 pm
Forum: Raspberry Pi OS
Topic: AARCH64 version of Raspbian?
Replies: 19
Views: 8303

Re: AARCH64 version of Raspbian?

Sounds like an excellent reason to teach about assembler macros. Well, my book is about how computers are organized at the assembly language level (with a peak at the hardware level), not how to solve problems in assembly language. These days, almost all code should be written in a high-level langu...
by rplantz
Tue Nov 15, 2016 9:40 pm
Forum: Raspberry Pi OS
Topic: AARCH64 version of Raspbian?
Replies: 19
Views: 8303

Re: AARCH64 version of Raspbian?

Raspbian is staying 32 bit for compatibility across all models of the Pi. There is 64 bit Debian code for testing on the Pi 3. The 64 bit testing time frame is mentioned as "years". Yeah, I was afraid of that. Perhaps on the Raspberry Pi 6? I knew about the SUSE version. Fedora says, &quo...
by rplantz
Mon Nov 14, 2016 9:42 pm
Forum: Raspberry Pi OS
Topic: AARCH64 version of Raspbian?
Replies: 19
Views: 8303

AARCH64 version of Raspbian?

Has there been any decision whether or not to create an AARCH64 version of Raspbian? If there will be one, any time line? My textbook, Introduction to Computer Organization: ARM Assembly Language Using the Raspberry Pi (free at http://bob.cs.sonoma.edu ) is being used in the classroom for the first ...
by rplantz
Wed Nov 09, 2016 11:59 pm
Forum: Bare metal, Assembly language
Topic: Assembly Language Access to UART on Rpi3
Replies: 11
Views: 6198

Re: Assembly Language Access to UART on Rpi3

Great book, but how about ridding it of the negativity toward assembly programming language? I quote your preface, "You should avoid writing in assembly language except when absolutely necessary." Let us be a bit more positive. Regardless of the advances of the C (and Python) languages, s...
by rplantz
Mon Oct 10, 2016 6:42 pm
Forum: Teaching and learning resources
Topic: Free assembly language book available online
Replies: 41
Views: 41688

Re: Free assembly language book available online

Thank you for the kind words, scruss. I hope that the book does provide a good place to start learning about the ARM for people like you. I imagine you will skim over the first part of the book, until you get to the assembly language programming. Then when I describe the instructions, I use notation...
by rplantz
Mon Oct 10, 2016 2:54 pm
Forum: Teaching and learning resources
Topic: Free assembly language book available online
Replies: 41
Views: 41688

Re: Free assembly language book available online

That's odd, I just clicked on the link (Chrome, Windows 10) and it opened right away. Have you tried typing in the url by hand? I used Chromium on my RPi3 (running PIXEL) to open the site last night. The book is in HTML, created by Mathbook XML ( https://mathbook.pugetsound.edu/ ), so is not downloa...

Go to advanced search