Questions tagged [68000]

The 68000 is a 16/32 bit CISC CPU, originally designed by Motorola, Inc.

The 68000 is a 16/32 bit CISC CPU, originally designed by Motorola, Inc.

After its introduction in 1979, it rapidly became popular among the system designers of its time. In its heyday, the 68000 was used in computers from Hewlett-Packard, Apollo/Domain, Sun Microsystems, Commodore (Amiga), Atari (ST), and Apple, among others.

Today, the 68000 and its derivatives are primarily used in embedded systems.

232 questions
3
votes
1 answer

Pass a memory address by register

How do I pass a memory address from a register to other? My following routine receive the string memory address from stack (yes, it's necessary) and then try to put into D1 registers but it doesn't work and EASy68k emulator crash (or goes in an…
The Mask
  • 17,007
  • 37
  • 111
  • 185
3
votes
2 answers

What is the best graphical simulator for 68K microprocessor?

I am a beginner and I need a graphical simulator to write assembly programs based on 68000 microprocessor. I have found Easy68K simulator. It works and the features are good, but is there any newer/better graphical simulator than Easy68K? I need the…
3
votes
2 answers

How to make an if-else control structure in 68k language?

I'm writing a program for 68k processor in ASM. And I need to make something like that if (D0 > D1) { do_some_stuff(); do_some_stuff(); do_some_stuff(); do_some_stuff(); } else { do_some_stuff(); do_some_stuff(); …
NewProger
  • 2,945
  • 9
  • 40
  • 58
3
votes
2 answers

Converting my solution from decimal to Hex

My goal is to display the solution of 2 numbers entered by the user in Hexadecimal. As of right now my code gets 2 numbers from the user, then returns the solution in decimal. What i think i should do is just to get my decimal solution and convert…
The Tokenizer
  • 1,564
  • 3
  • 29
  • 46
3
votes
1 answer

What will the instruction "move #>$3,var" mean in 68k assembly?

What will the instruction move #>$3,var mean in 68k assembly ?
Bleamer
  • 637
  • 9
  • 24
3
votes
1 answer

I'm having trouble getting this addition subroutine to work

I am writing an addition program for my assembly language class in Easy68k but I keep having the same issue. Whenever I run the program it allows me to input up to 10 numbers (the allotted size of my array) and then it outputs the message saying…
TheTrain
  • 31
  • 2
2
votes
4 answers

What does the ORG directive do in assembly code?

For reference, the code is for the motorola 68008. Say I have code such as the following: org 200 sequenceO: ds.b 5 sequenceN: ds.b 5 move.w #sequenceO, A0 move.w #sequenceN, A1 Am I correct in thinking that A0 will hold the value 200 and A1 the…
Isaac
2
votes
2 answers

Assembly Random Number within Range using Easy 68K (68000)

I'm creating a simple black jack game using the Easy 68K simulator and need to use a random number to assign the cards. My cards must be in the range 2 to 11. I seem to be getting the same number every time, and it isn't within the range I expect.…
kelly
  • 139
  • 3
  • 9
2
votes
1 answer

Insert a line break into Assembly code Easy 68k (68000)

I am very new to assembly, and I'm trying to build a small program. I can't figure out how to insert a line break in assembly using the Easy68k. For example, I am starting to write basic black jack simulator, and I need to do a line break after…
kelly
  • 139
  • 3
  • 9
2
votes
2 answers

I keep receiving and address error for my assembly language

So I am creating an assembly language for the following: X = 5 Y = 7 FOR I = 1 TO 9 Y = Y + I IF T(I) = J(I) + X THEN J(I) = T(I) * 4 - Y ELSE J(I) = J(I) - T(I) END_FOR and keep recieving a "Address Error: Instruction…
tehman
  • 828
  • 2
  • 11
  • 34
2
votes
1 answer

Trying to compare and count array elements greater, less, or equal to a value

I am trying to iterate an array and find numbers less than, equal to, and more than to be stored. I want to store the count in the three results and if possible display the result ORG $1000 START: ORG $2000 ; first…
amolc
  • 33
  • 1
  • 7
2
votes
1 answer

Fastest way to copy sign value among 68k data registers. (Branchless conditional negation of an integer)

I'm looking for an optimized way to change the sign of a value contained in a Data Register using the sign from a value in another Data Register. Source register will contain either 1 or -1 and destination be always positive therefore all is needed…
KONEY
  • 73
  • 6
2
votes
1 answer

Is GCC inline asm goto supported in the m68k-elf target?

I'm working on a project with lots of C wrappers around M68000 asm calls. A few of these calls return a success/fail status on the condition code register, so it would be ideal to 'goto' a C label depending on the status of CC. However, no matter…
Ryou
  • 57
  • 4
2
votes
3 answers

Call subroutine by dynamic value

I'm quite new to 68k and I was wondering if it's possible to call a specific subroutine by values held in memory. pseudo code example: X: dc.w 0 routine1: code rts routine2: more code rts and somewhere in the code something like: move.w #2,X JSR…
KONEY
  • 73
  • 6
2
votes
0 answers

gcc's assembler and variable type (length, sign)

I'm using an 'm68k-elf-as' compiler (https://gnutoolchains.com/m68k-elf/) for assembly code that I'm patching into my car's ECU (CPU32 ISA, MC68376 processor). Is there a simple way to control typecasting in the gnu assembler? I'm having trouble…
Obeisance
  • 21
  • 3