Changeset 4b63bf3 in buchla-68k


Ignore:
Timestamp:
11/12/2017 07:48:33 PM (6 years ago)
Author:
Thomas Lopatic <thomas@…>
Branches:
master
Children:
7f5fa1b
Parents:
7c05959
Message:

Fixed ettpch.c.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • ram/ettpch.c

    r7c05959 r4b63bf3  
    126126        cnvc2p(dspbuf, (val >> 1));
    127127
    128         dspbuf[0] += '0';
    129         dspbuf[1] += 'A';
     128        dspbuf[0] = (int8_t)(dspbuf[0] + '0');
     129        dspbuf[1] = (int8_t)(dspbuf[1] + 'A');
    130130        dspbuf[2] = sfdsp[dspbuf[2] - 7];
    131         dspbuf[3] += '0';
    132         dspbuf[4] += '0';
     131        dspbuf[3] = (int8_t)(dspbuf[3] + '0');
     132        dspbuf[4] = (int8_t)(dspbuf[4] + '0');
    133133        dspbuf[5] = '\0';
    134134
     
    171171        case 0:
    172172
    173                 ebuf[0] = k;
    174                 dspbuf[0] = k + '0';
     173                ebuf[0] = (int8_t)k;
     174                dspbuf[0] = (int8_t)(k + '0');
    175175                break;
    176176
     
    180180                        return(FAILURE);
    181181
    182                 ebuf[1] = k;
    183                 dspbuf[0] = k + 'A';
     182                ebuf[1] = (int8_t)k;
     183                dspbuf[0] = (int8_t)(k + 'A');
    184184                break;
    185185
     
    188188                if (k EQ 7) {           /* blank */
    189189
    190                         ebuf[2] = k;
     190                        ebuf[2] = (int8_t)k;
    191191                        dspbuf[0] = sfdsp[0];
    192192                        break;
     
    194194                } else if (k EQ 8) {    /* flat */
    195195
    196                         ebuf[2] = k;
     196                        ebuf[2] = (int8_t)k;
    197197                        dspbuf[0] = sfdsp[1];
    198198                        break;
     
    200200                } else if (k EQ 9) {    /* sharp */
    201201
    202                         ebuf[2] = k;
     202                        ebuf[2] = (int8_t)k;
    203203                        dspbuf[0] = sfdsp[2];
    204204                        break;
     
    210210        case 4:
    211211
    212                 ebuf[col] = k;
    213                 dspbuf[0] = k + '0';
     212                ebuf[col] = (int8_t)k;
     213                dspbuf[0] = (int8_t)(k + '0');
    214214                break;
    215215        }
Note: See TracChangeset for help on using the changeset viewer.