EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

Project with "IF" function and timer

Started by Iron-Sim May 27, 2015
On Mon, 15 Jun 2015, rickman wrote:

> On 6/15/2015 1:13 PM, Ed Prochak wrote: >> On Sunday, June 14, 2015 at 5:50:34 PM UTC-4, rickman wrote: >> [] >>> >>> I don't think he is trying to learn really. I expect this is an >>> assignment and he is trying to get something to work as quickly as >>> possible. It's not a difficult assignment really, but he needs to >>> *learn* about the issues involved rather than just copying code from the >>> Internet.
>> yes, he seems to be doing on the job learning, poorly. That seems to be the >> modern mentality: "I don't need to understand how it works. I'll just >> throw code at it until something happens." >> >> I hope he follows your advice. > > I remember being in a hurry myself when I was in school. I thought I was > learning everything I needed and the actual practice of the craft was just an > "exercise". lol. I'm still learning the practice of the craft.
Yes, there are still a few of us old timers out here who not only programmed "right down on the iron" in assembly language, we may have set bootstrap loaders with toggle switches(!!!) and even did a little programming in straight octal/hexadecimal, not even assembly language. It seems that these days to too many young whippersnappers, CPUs are just black boxes about which they have little understanding how they really work under the covers. I wonder even about embedded systems in which people code in C? Do they really understand what is going on in the hardware layer? Do they need to? -- Paul Bartlett
On Tue, 16 Jun 2015 13:59:56 -0400, Paul Bartlett <bartlett@panix.com>
wrote:

>On Mon, 15 Jun 2015, rickman wrote: > >> On 6/15/2015 1:13 PM, Ed Prochak wrote: >>> On Sunday, June 14, 2015 at 5:50:34 PM UTC-4, rickman wrote: >>> [] >>>> >>>> I don't think he is trying to learn really. I expect this is an >>>> assignment and he is trying to get something to work as quickly as >>>> possible. It's not a difficult assignment really, but he needs to >>>> *learn* about the issues involved rather than just copying code from the >>>> Internet. > >>> yes, he seems to be doing on the job learning, poorly. That seems to be the >>> modern mentality: "I don't need to understand how it works. I'll just >>> throw code at it until something happens." >>> >>> I hope he follows your advice. >> >> I remember being in a hurry myself when I was in school. I thought I was >> learning everything I needed and the actual practice of the craft was just an >> "exercise". lol. I'm still learning the practice of the craft. > >Yes, there are still a few of us old timers out here who not only >programmed "right down on the iron" in assembly language, we may have >set bootstrap loaders with toggle switches(!!!) and even did a little >programming in straight octal/hexadecimal, not even assembly language.
Some architectures like PDP-11 and 8080 are naturally octal (three bit groups) while others, such as IBM360/370 as well as VAX-11 series are essentially hexadecimal (4 bit groups). Doing front panel programming with toggle switches was not a big deal. On some architectures calculating the branch relative offset required pen and paper, otherwise programming with toggle switches or 8/16 position rotary swathes was quite easy. I still do not understand why intel swathes from octal ( 2 bit opcode and 3 bit destination address and 3 bit source address) to hexadecimal on 8080 and 8085.
On 2015-06-16, upsidedown@downunder.com <upsidedown@downunder.com> wrote:

> I still do not understand why intel swathes from octal ( 2 bit opcode > and 3 bit destination address and 3 bit source address) to > hexadecimal on 8080 and 8085.
IIRC, Heathkit's assembler used octal instead of hex by default for 8080/8085/Z80. Probably due to the previous work with PDP-11 kits. -- Grant Edwards grant.b.edwards Yow! And then we could sit at on the hoods of cars at gmail.com stop lights!
upsidedown@downunder.com wrote:

(snip)

> Some architectures like PDP-11 and 8080 are naturally octal (three bit > groups) while others, such as IBM360/370 as well as VAX-11 series are > essentially hexadecimal (4 bit groups).
> Doing front panel programming with toggle switches was not a big deal. > On some architectures calculating the branch relative offset required > pen and paper, otherwise programming with toggle switches or 8/16 > position rotary swathes was quite easy.
The Altair 8800 front panel has the LEDs grouped in threes. More than one I have known has sticky labels to divide them into groups of four, instead. Even if it is more natural as octal, if you are more used to hex, it is easier that way. Also, the PDP-11 with 16 its, and the 8080 with eight, don't map to whole numbers of octal digits. That complicates working with them in octal.
> I still do not understand why intel swathes from octal ( 2 bit opcode > and 3 bit destination address and 3 bit source address) to > hexadecimal on 8080 and 8085.
-- glen -- glen
On 6/16/2015 1:59 PM, Paul Bartlett wrote:
> On Mon, 15 Jun 2015, rickman wrote: > >> On 6/15/2015 1:13 PM, Ed Prochak wrote: >>> On Sunday, June 14, 2015 at 5:50:34 PM UTC-4, rickman wrote: >>> [] >>>> >>>> I don't think he is trying to learn really. I expect this is an >>>> assignment and he is trying to get something to work as quickly as >>>> possible. It's not a difficult assignment really, but he needs to >>>> *learn* about the issues involved rather than just copying code from >>>> the >>>> Internet. > >>> yes, he seems to be doing on the job learning, poorly. That seems to >>> be the modern mentality: "I don't need to understand how it works. >>> I'll just throw code at it until something happens." >>> >>> I hope he follows your advice. >> >> I remember being in a hurry myself when I was in school. I thought I >> was learning everything I needed and the actual practice of the craft >> was just an "exercise". lol. I'm still learning the practice of the >> craft. > > Yes, there are still a few of us old timers out here who not only > programmed "right down on the iron" in assembly language, we may have > set bootstrap loaders with toggle switches(!!!) and even did a little > programming in straight octal/hexadecimal, not even assembly language. > It seems that these days to too many young whippersnappers, CPUs are > just black boxes about which they have little understanding how they > really work under the covers. I wonder even about embedded systems in > which people code in C? Do they really understand what is going on in > the hardware layer? Do they need to?
How about microcode? Anyone else done that? -- Rick
On 6/16/2015 4:59 PM, glen herrmannsfeldt wrote:
> upsidedown@downunder.com wrote: > > (snip) > >> Some architectures like PDP-11 and 8080 are naturally octal (three bit >> groups) while others, such as IBM360/370 as well as VAX-11 series are >> essentially hexadecimal (4 bit groups). > >> Doing front panel programming with toggle switches was not a big deal. >> On some architectures calculating the branch relative offset required >> pen and paper, otherwise programming with toggle switches or 8/16 >> position rotary swathes was quite easy. > > The Altair 8800 front panel has the LEDs grouped in threes. > > More than one I have known has sticky labels to divide them into > groups of four, instead. Even if it is more natural as octal, > if you are more used to hex, it is easier that way. > > Also, the PDP-11 with 16 its, and the 8080 with eight, don't map > to whole numbers of octal digits. That complicates working with > them in octal.
It does? I have seen many a listing in octal and it works wonderfully with the LSI-11. Who cares about the left digit being just one bit? -- Rick
On 2015-06-16, rickman <gnuarm@gmail.com> wrote:
> On 6/16/2015 4:59 PM, glen herrmannsfeldt wrote: > >> Also, the PDP-11 with 16 its, and the 8080 with eight, don't map to >> whole numbers of octal digits. That complicates working with them in >> octal. > > It does?
Not that I recall.
> I have seen many a listing in octal and it works wonderfully with the > LSI-11. Who cares about the left digit being just one bit?
I remember seeing Z80 listings that used split octal notation for addresses and other 16-bit values: 000_000 to 377_377. I thought that a bit odd, but never worked with that notation enough to comment on it's utility. -- Grant Edwards grant.b.edwards Yow! I left my WALLET in at the BATHROOM!! gmail.com
On 6/16/2015 5:57 PM, Grant Edwards wrote:
> On 2015-06-16, rickman <gnuarm@gmail.com> wrote: >> On 6/16/2015 4:59 PM, glen herrmannsfeldt wrote: >> >>> Also, the PDP-11 with 16 its, and the 8080 with eight, don't map to >>> whole numbers of octal digits. That complicates working with them in >>> octal. >> >> It does? > > Not that I recall. > >> I have seen many a listing in octal and it works wonderfully with the >> LSI-11. Who cares about the left digit being just one bit? > > I remember seeing Z80 listings that used split octal notation for > addresses and other 16-bit values: 000_000 to 377_377. I thought that > a bit odd, but never worked with that notation enough to comment on > it's utility.
If you've never used a flat bladed screw driver I expect you wouldn't be very good with that either. -- Rick
On Tue, 16 Jun 2015 20:59:51 +0000 (UTC), glen herrmannsfeldt
<gah@ugcs.caltech.edu> wrote:

>upsidedown@downunder.com wrote: > >(snip) > >> Some architectures like PDP-11 and 8080 are naturally octal (three bit >> groups) while others, such as IBM360/370 as well as VAX-11 series are >> essentially hexadecimal (4 bit groups). > >> Doing front panel programming with toggle switches was not a big deal. >> On some architectures calculating the branch relative offset required >> pen and paper, otherwise programming with toggle switches or 8/16 >> position rotary swathes was quite easy. > >The Altair 8800 front panel has the LEDs grouped in threes. > >More than one I have known has sticky labels to divide them into >groups of four, instead. Even if it is more natural as octal, >if you are more used to hex, it is easier that way. > >Also, the PDP-11 with 16 its, and the 8080 with eight, don't map >to whole numbers of octal digits. That complicates working with >them in octal.
If you just enter a program from a listing (generated by assembler or manually assembled) with toggle switches, it is quite irrelevant if octal or hex is used. Of course, if you have a hex keypad, using hex will save a lot of keystrokes. My original point was about writing a program into memory through front panel toggle switches without any paper listing. In this case it is essential that the mode (octal/hex) matches the machine architecture. Using hex on a PDP-11/8080/Z80 requires remember the whole 8 or 16 bit opcode. For PDP-11 dual operand instructions, you only needed to remember a 3 bit opcode, then use the byte/word bit (most significant bit) the addressing mode (3 bits), (base)register (3 bits) for the first operand and 3+3 bits for the other operand.
On Tue, 16 Jun 2015 13:59:56 -0400, Paul Bartlett <bartlett@panix.com>
wrote:

>Yes, there are still a few of us old timers out here who not only >programmed "right down on the iron" in assembly language, we may have >set bootstrap loaders with toggle switches(!!!) and even did a little
Sometimes also called key-in loader -)

The 2024 Embedded Online Conference