It is currently Fri Apr 19, 2019 6:50 pm

All times are UTC

Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Fri Nov 09, 2018 3:20 pm 

Joined: Sun Nov 01, 2009 4:02 pm
Posts: 20
Location: Belgium
Hallo prof Kelly,

I did a lot of programming in 68K ASM, since my youth.
So, I have a lot of old well working asm files I like to use for my small robots.
They are all created with an old ASM assembler who uses other controls.
And one of the things are the use of other commands for the old $, %, &
the program used to determine hexadecimal, binary, decimal and octal values,
h', b', d', o'.

So, is it possible to change this in the Easy68K environment ?
And if so, where can I change this in the source code to replace them ?

decimal become d'
binary becomes b'
hexadecimal becomes h'
octal becomes o'

Some examples:

AND.B #d'31,d0 * clear D5...D7
AND.B #h'1F,d0 * clear D5...D7
AND.B #b'00011111,d0 * clear D5...D7


Greetings from Belgium
Hobby robot builder

PostPosted: Sat Nov 10, 2018 12:35 pm 
User avatar

Joined: Thu Dec 16, 2004 6:42 pm
Posts: 1093
    EVAL.CPP contains the parser code that evaluates numeric literals. Currently in EASy68K:
    $ = hexadecimal
    % = binary
    @ = base 8
    default = base 10
  else if (*p == '$' && isxdigit(*(p+1))) {
    /* Convert hex digits until another character is
       found. (At least one hex digit is present.) */
    x = 0;
    while (isxdigit(*++p)) {
      if ((unsigned int)x > (unsigned int)LONGLIMIT/16)
      if (*p > '9')
   x = 16 * x + (*p - 'A' + 10);
   x = 16 * x + (*p - '0');
    *numberPtr = x;
    return p;
  else if (*p == '%' || *p == '@' || isdigit(*p)) {
    /* Convert digits in the appropriate base (binary,
       octal, or decimal) until an invalid digit is found. */
    if (*p == '%') {
      base = 2;
    else if (*p == '@') {
      base = 8;
      base = 10;

Modifying EASy68K would require an old copy of Borland C++ Builder 6.x.

Prof. Kelly

PostPosted: Thu Mar 21, 2019 2:09 pm 
User avatar

Joined: Wed Jan 06, 2016 9:24 am
Posts: 9
You'd likely be easier to change your files marc_256, unless there is good reason not to?

Programs like Notepad++ or Visual Studio Code can quickly search and replace even through multiple files.

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC

Who is online

Users browsing this forum: No registered users and 1 guest

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group