CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Help! strange problem with zero ram? or something else

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
btokarchuk
Guest







Help! strange problem with zero ram? or something else
PostPosted: Tue Mar 25, 2003 11:24 am     Reply with quote

Hello,

I seem to be encountering a strange phenomenon. A while back we had added the #zero_ram directive into one of our projects. Now we have removed it but the compiler is still burning up memory by performing a CLRF instruction on every ram location (or so it seems)

I have pasted here the section of the LST file that contains the main program. It seems that this ram initialization occurs before executing anything else in the main program.

Any help would be greatly appreciated as we're currently trying to optimize our code and free up some ROM space. I've searched my included files and there are no other instances of #zero_ram anywhere... could there be something else that is causing this phenomenon?

Thanks

Brent

----------------------

.................... void main()
.................... {
*
5C1A: NOP(FFFF)
5C1C: CLRF FF8
5C1E: BCF FD0.7
5C20: BSF 0D.7
5C22: CLRF FEA
5C24: CLRF FE9
5C26: MOVLW 07
5C28: MOVWF FC1
5C2A: CLRF 1A
5C2C: CLRF 1B
5C2E: CLRF 1C
5C30: CLRF 1D
5C32: CLRF 1E
5C34: CLRF 1F
5C36: CLRF 20
5C38: CLRF 21
5C3A: CLRF 22
5C3C: CLRF 23
5C3E: CLRF 24
5C40: CLRF 25
5C42: CLRF 26
5C44: CLRF 27
5C46: CLRF 28
5C48: CLRF 29
5C4A: CLRF 2A
5C4C: CLRF 2B
5C4E: CLRF 2C
5C50: CLRF 2D
5C52: CLRF 2E
5C54: CLRF 2F
5C56: CLRF 30
5C58: CLRF 31
5C5A: CLRF 32
5C5C: CLRF 33
5C5E: CLRF 34
5C60: CLRF 35
5C62: CLRF 36
5C64: CLRF 37
5C66: CLRF 38
5C68: CLRF 39
5C6A: CLRF 3A
5C6C: CLRF 3B
5C6E: CLRF 3C
5C70: CLRF 3D
5C72: CLRF 3E
5C74: CLRF 3F
5C76: CLRF 40
5C78: CLRF 41
5C7A: CLRF 42
5C7C: CLRF 43
5C7E: CLRF 44
5C80: CLRF 45
5C82: CLRF 46
5C84: CLRF 47
5C86: CLRF 48
5C88: CLRF 49
5C8A: CLRF 4A
5C8C: CLRF 4B
5C8E: CLRF 4C
5C90: CLRF 4D
5C92: CLRF 4E
5C94: CLRF 4F
5C96: CLRF 50
5C98: CLRF 51
5C9A: CLRF 52
5C9C: CLRF 53
5C9E: CLRF 54
5CA0: CLRF 55
5CA2: CLRF 56
5CA4: CLRF 57
5CA6: CLRF 58
5CA8: CLRF 59
5CAA: CLRF 5A
5CAC: CLRF 5B
5CAE: CLRF 5C
5CB0: CLRF 5D
5CB2: CLRF 5E
5CB4: CLRF 5F
5CB6: CLRF 60
5CB8: CLRF 61
5CBA: CLRF 62
5CBC: CLRF 63
5CBE: CLRF 64
5CC0: CLRF 65
5CC2: CLRF 66
5CC4: CLRF 67
5CC6: CLRF 68
5CC8: CLRF 69
5CCA: CLRF 6A
5CCC: CLRF 6B
5CCE: CLRF 6C
5CD0: CLRF 6D
5CD2: CLRF 6E
5CD4: CLRF 6F
5CD6: CLRF 70
5CD8: CLRF 71
5CDA: CLRF 72
5CDC: CLRF 73
5CDE: CLRF 74
5CE0: CLRF 75
5CE2: CLRF 76
5CE4: CLRF 77
5CE6: CLRF 78
5CE8: CLRF 79
5CEA: CLRF 7A
5CEC: CLRF 7B
5CEE: CLRF 7C
5CF0: CLRF 7D
5CF2: CLRF 7E
5CF4: CLRF 7F
5CF6: CLRF x80
5CF8: CLRF x81
5CFA: CLRF x82
5CFC: CLRF x83
5CFE: CLRF x84
5D00: CLRF x85
5D02: CLRF x86
5D04: CLRF x87
5D06: CLRF x88
5D08: CLRF x89
5D0A: CLRF x8A
5D0C: CLRF x8B
5D0E: CLRF x8C
5D10: CLRF x8D
5D12: CLRF x8E
5D14: CLRF x8F
5D16: CLRF x90
5D18: CLRF x91
5D1A: CLRF x92
5D1C: CLRF x93
5D1E: CLRF x94
5D20: CLRF x95
5D22: CLRF x96
5D24: CLRF x97
5D26: CLRF x98
5D28: CLRF x99
5D2A: CLRF x9A
5D2C: CLRF x9B
5D2E: CLRF x9C
5D30: CLRF x9D
5D32: CLRF x9E
5D34: CLRF x9F
5D36: CLRF xA0
5D38: CLRF xA1
5D3A: CLRF xA2
5D3C: CLRF xA3
5D3E: CLRF xA4
5D40: CLRF xA5
5D42: CLRF xA6
5D44: CLRF xA7
5D46: CLRF xA8
5D48: CLRF xA9
5D4A: CLRF xAA
5D4C: CLRF xAB
5D4E: CLRF xAC
5D50: CLRF xAD
5D52: CLRF xAE
5D54: CLRF xAF
5D56: CLRF xB0
5D58: CLRF xB1
5D5A: CLRF xB2
5D5C: CLRF xB3
5D5E: CLRF xB4
5D60: CLRF xB5
5D62: CLRF xB6
5D64: CLRF xB7
5D66: CLRF xB8
5D68: CLRF xB9
5D6A: CLRF xBA
5D6C: CLRF xBB
5D6E: CLRF xBC
5D70: CLRF xBD
5D72: CLRF xBE
5D74: CLRF xBF
5D76: CLRF xC0
5D78: CLRF xC1
5D7A: CLRF xC2
5D7C: CLRF xC3
5D7E: CLRF xC4
5D80: CLRF xC5
5D82: CLRF xC6
5D84: CLRF xC7
5D86: CLRF xC8
5D88: CLRF xC9
5D8A: CLRF xCA
5D8C: CLRF xCB
5D8E: CLRF xCC
5D90: CLRF xCD
5D92: CLRF xCE
5D94: CLRF xCF
5D96: CLRF xD0
5D98: CLRF xD1
5D9A: CLRF xD2
5D9C: CLRF xD3
5D9E: CLRF xD4
5DA0: CLRF xD5
5DA2: CLRF xD6
5DA4: CLRF xD7
5DA6: CLRF xD8
5DA8: CLRF xD9
5DAA: CLRF xDA
5DAC: CLRF xDB
5DAE: CLRF xDC
5DB0: CLRF xDD
5DB2: CLRF xDE
5DB4: CLRF xDF
5DB6: CLRF xE0
5DB8: CLRF xE1
5DBA: CLRF xE2
5DBC: CLRF xE3
5DBE: CLRF xE4
5DC0: CLRF xE5
5DC2: CLRF xE6
5DC4: CLRF xE7
5DC6: CLRF xE8
5DC8: CLRF xE9
5DCA: CLRF xEA
5DCC: CLRF xEB
5DCE: CLRF xEC
5DD0: CLRF xED
5DD2: CLRF xEE
5DD4: CLRF xEF
5DD6: CLRF xF0
5DD8: CLRF xF1
5DDA: CLRF xF2
5DDC: CLRF xF3
5DDE: CLRF xF4
5DE0: CLRF xF5
5DE2: CLRF xF6
5DE4: CLRF xF7
5DE6: CLRF xF8
5DE8: CLRF xF9
5DEA: CLRF xFA
5DEC: CLRF xFB
5DEE: CLRF xFC
5DF0: CLRF xFD
5DF2: CLRF xFE
5DF4: CLRF xFF
5DF6: MOVLB 1
5DF8: CLRF x00
5DFA: CLRF x01
5DFC: CLRF x02
5DFE: CLRF x03
5E00: CLRF x04
5E02: CLRF x05
5E04: CLRF x06
5E06: CLRF x07
5E08: CLRF x08
5E0A: CLRF x09
5E0C: CLRF x0A
5E0E: CLRF x0B
5E10: CLRF x0C
5E12: CLRF x0D
5E14: CLRF x0E
5E16: CLRF x0F
5E18: CLRF x10
5E1A: CLRF x11
5E1C: CLRF x12
5E1E: CLRF x13
5E20: CLRF x14
5E22: CLRF x15
5E24: CLRF x16
5E26: CLRF x17
5E28: CLRF x18
5E2A: CLRF x19
5E2C: CLRF x1A
5E2E: CLRF x1B
5E30: CLRF x1C
5E32: CLRF x1D
5E34: CLRF x1E
5E36: CLRF x1F
5E38: CLRF x20
5E3A: CLRF x21
5E3C: CLRF x22
5E3E: CLRF x23
5E40: CLRF x24
5E42: CLRF x25
5E44: CLRF x26
5E46: CLRF x27
5E48: CLRF x28
5E4A: CLRF x29
5E4C: CLRF x2A
5E4E: CLRF x2B
5E50: CLRF x2C
5E52: CLRF x2D
5E54: CLRF x2E
5E56: CLRF x2F
5E58: CLRF x30
5E5A: CLRF x31
5E5C: CLRF x32
5E5E: CLRF x33
5E60: CLRF x34
5E62: CLRF x35
5E64: CLRF x36
5E66: CLRF x37
5E68: CLRF x38
5E6A: CLRF x39
5E6C: CLRF x3A
5E6E: CLRF x3B
5E70: CLRF x3C
5E72: CLRF x3D
5E74: CLRF x3E
5E76: CLRF x3F
5E78: CLRF x40
5E7A: CLRF x41
5E7C: CLRF x42
5E7E: CLRF x43
5E80: CLRF x44
5E82: CLRF x45
5E84: CLRF x46
5E86: CLRF x47
5E88: CLRF x48
5E8A: CLRF x49
5E8C: CLRF x4A
5E8E: CLRF x4B
5E90: CLRF x4C
5E92: CLRF x4D
5E94: CLRF x4E
5E96: CLRF x4F
5E98: CLRF x50
5E9A: CLRF x51
5E9C: CLRF x52
5E9E: CLRF x53
5EA0: CLRF x54
5EA2: CLRF x55
5EA4: CLRF x56
5EA6: CLRF x57
5EA8: CLRF x58
5EAA: CLRF x59
5EAC: CLRF x5A
5EAE: CLRF x5B
5EB0: CLRF x5C
5EB2: CLRF x5D
5EB4: CLRF x5E
5EB6: CLRF x5F
5EB8: CLRF x60
5EBA: CLRF x61
5EBC: CLRF x62
5EBE: CLRF x63
5EC0: CLRF x64
5EC2: CLRF x65
5EC4: CLRF x66
5EC6: CLRF x67
5EC8: CLRF x68
5ECA: CLRF x69
5ECC: CLRF x6A
5ECE: CLRF x6B
5ED0: CLRF x6C
5ED2: CLRF x6D
5ED4: CLRF x6E
5ED6: CLRF x6F
5ED8: CLRF x70
5EDA: CLRF x71
5EDC: CLRF x72
5EDE: CLRF x73
5EE0: CLRF x74
5EE2: CLRF x75
5EE4: CLRF x76
5EE6: CLRF x77
5EE8: CLRF x78
5EEA: CLRF x79
5EEC: CLRF x7A
5EEE: CLRF x7B
5EF0: CLRF x7C
5EF2: CLRF x7D
5EF4: CLRF x7E
5EF6: CLRF x7F
5EF8: CLRF x80
5EFA: CLRF x81
5EFC: CLRF x82
5EFE: CLRF x83
5F00: CLRF x84
5F02: CLRF x85
5F04: CLRF x86
5F06: CLRF x87
5F08: CLRF x88
5F0A: CLRF x89
5F0C: CLRF x8A
5F0E: CLRF x8B
5F10: CLRF x8C
5F12: CLRF x8D
5F14: CLRF x8E
5F16: CLRF x8F
5F18: CLRF x90
5F1A: CLRF x91
5F1C: CLRF x92
5F1E: CLRF x93
5F20: CLRF x94
5F22: CLRF x95
5F24: CLRF x96
5F26: CLRF x97
5F28: CLRF x98
5F2A: CLRF x99
5F2C: CLRF x9A
5F2E: CLRF x9B
5F30: CLRF x9C
5F32: CLRF x9D
5F34: CLRF x9E
5F36: CLRF x9F
5F38: CLRF xA0
5F3A: CLRF xA1
5F3C: CLRF xA2
5F3E: CLRF xA3
5F40: CLRF xA4
5F42: CLRF xA5
5F44: CLRF xA6
5F46: CLRF xA7
5F48: CLRF xA8
5F4A: CLRF xA9
5F4C: CLRF xAA
5F4E: CLRF xAB
5F50: CLRF xAC
5F52: CLRF xAD
5F54: CLRF xAE
5F56: CLRF xAF
5F58: CLRF xB0
5F5A: CLRF xB1
5F5C: CLRF xB2
5F5E: CLRF xB3
5F60: CLRF xB4
5F62: CLRF xB5
5F64: CLRF xB6
5F66: CLRF xB7
5F68: CLRF xB8
5F6A: CLRF xB9
5F6C: CLRF xBA
5F6E: CLRF xBB
5F70: CLRF xBC
5F72: CLRF xBD
5F74: CLRF xBE
5F76: CLRF xBF
5F78: CLRF xC0
5F7A: CLRF xC1
5F7C: CLRF xC2
5F7E: CLRF xC3
5F80: CLRF xC4
5F82: CLRF xC5
5F84: CLRF xC6
5F86: CLRF xC7
5F88: CLRF xC8
5F8A: CLRF xC9
5F8C: CLRF xCA
5F8E: CLRF xCB
5F90: CLRF xCC
5F92: CLRF xCD
5F94: CLRF xCE
5F96: CLRF xCF
5F98: CLRF xD0
5F9A: CLRF xD1
5F9C: CLRF xD2
5F9E: CLRF xD3
5FA0: CLRF xD4
5FA2: CLRF xD5
5FA4: CLRF xD6
5FA6: CLRF xD7
5FA8: CLRF xD8
5FAA: CLRF xD9
5FAC: CLRF xDA
5FAE: CLRF xDB
5FB0: CLRF xDC
5FB2: CLRF xDD
5FB4: CLRF xDE
5FB6: CLRF xDF
5FB8: CLRF xE0
5FBA: CLRF xE1
5FBC: CLRF xE2
5FBE: CLRF xE3
5FC0: CLRF xE4
5FC2: CLRF xE5
5FC4: CLRF xE6
5FC6: CLRF xE7
5FC8: CLRF xE8
5FCA: CLRF xE9
5FCC: CLRF xEA
5FCE: CLRF xEB
5FD0: CLRF xEC
5FD2: CLRF xED
5FD4: CLRF xEE
5FD6: CLRF xEF
5FD8: CLRF xF0
5FDA: CLRF xF1
5FDC: CLRF xF2
5FDE: CLRF xF3
5FE0: CLRF xF4
5FE2: CLRF xF5
5FE4: CLRF xF6
5FE6: CLRF xF7
5FE8: CLRF xF8
5FEA: CLRF xF9
5FEC: CLRF xFA
5FEE: CLRF xFB
5FF0: CLRF xFC
5FF2: CLRF xFD
5FF4: CLRF xFE
5FF6: CLRF xFF
5FF8: MOVLB 2
5FFA: CLRF x00
5FFC: CLRF x01
5FFE: CLRF x02
6000: CLRF x03
6002: CLRF x04
6004: CLRF x05
6006: CLRF x06
6008: CLRF x07
600A: CLRF x08
600C: CLRF x09
600E: CLRF x0A
6010: CLRF x0B
6012: CLRF x0C
6014: CLRF x0D
6016: CLRF x0E
6018: CLRF x0F
601A: CLRF x10
601C: CLRF x11
601E: CLRF x12
6020: CLRF x13
6022: CLRF x14
6024: CLRF x15
6026: CLRF x16
6028: CLRF x17
602A: CLRF x18
602C: CLRF x19
602E: CLRF x1A
6030: CLRF x1B
6032: CLRF x1C
6034: CLRF x1D
6036: CLRF x1E
6038: CLRF x1F
603A: CLRF x20
603C: CLRF x21
603E: CLRF x22
6040: CLRF x23
6042: CLRF x24
6044: CLRF x25
6046: CLRF x26
6048: CLRF x27
604A: CLRF x28
604C: CLRF x29
604E: CLRF x2A
6050: CLRF x2B
6052: CLRF x2C
6054: CLRF x2D
6056: CLRF x2E
6058: CLRF x2F
605A: CLRF x30
605C: CLRF x31
605E: CLRF x32
6060: CLRF x33
6062: CLRF x34
6064: CLRF x35
6066: CLRF x36
6068: CLRF x37
606A: CLRF x38
606C: CLRF x39
606E: CLRF x3A
6070: CLRF x3B
6072: CLRF x3C
6074: CLRF x3D
6076: CLRF x3E
6078: CLRF x3F
607A: CLRF x40
607C: CLRF x41
607E: CLRF x42
6080: CLRF x43
6082: CLRF x44
6084: CLRF x45
6086: CLRF x46
6088: CLRF x47
608A: CLRF x48
608C: CLRF x49
608E: CLRF x4A
6090: CLRF x4B
6092: CLRF x4C
6094: CLRF x4D
6096: CLRF x4E
6098: CLRF x4F
609A: CLRF x50
609C: CLRF x51
609E: CLRF x52
60A0: CLRF x53
60A2: CLRF x54
60A4: CLRF x55
60A6: CLRF x56
60A8: BCF x57.0
60AA: CLRF x58
60AC: CLRF x59
60AE: CLRF x5A
60B0: CLRF x5B
60B2: CLRF x5C
60B4: CLRF x5D
60B6: CLRF x5E
60B8: CLRF x5F
60BA: CLRF x60
60BC: CLRF x61
60BE: CLRF x62
60C0: CLRF x63
60C2: CLRF x64
60C4: CLRF x65
60C6: CLRF x66
60C8: CLRF x67
60CA: CLRF x68
60CC: CLRF x69
60CE: CLRF x6A
60D0: CLRF x6B
60D2: CLRF x6C
60D4: CLRF x6D
60D6: CLRF x6E
60D8: CLRF x6F
60DA: CLRF x70
60DC: CLRF x71
60DE: CLRF x72
60E0: CLRF x73
60E2: CLRF x74
60E4: CLRF x75
60E6: CLRF x76
60E8: CLRF x77
60EA: CLRF x78
60EC: CLRF x79
60EE: CLRF x7A
60F0: CLRF x7B
60F2: CLRF x7C
60F4: CLRF x7D
60F6: CLRF x7E
60F8: CLRF x7F
60FA: CLRF x80
60FC: CLRF x81
60FE: CLRF x82
6100: CLRF x83
6102: CLRF x84
6104: CLRF x85
6106: CLRF x86
6108: CLRF x87
610A: CLRF x88
610C: CLRF x89
610E: CLRF x8A
6110: CLRF x8B
6112: CLRF x8C
6114: CLRF x8D
6116: CLRF x8E
6118: CLRF x8F
611A: CLRF x90
611C: CLRF x91
611E: CLRF x92
6120: CLRF x93
6122: CLRF x94
6124: CLRF x95
6126: CLRF x96
6128: CLRF x97
612A: CLRF x98
612C: CLRF x99
612E: CLRF x9A
6130: CLRF x9B
6132: CLRF x9C
6134: CLRF x9D
6136: CLRF x9E
6138: CLRF x9F
613A: CLRF xA0
613C: CLRF xA1
613E: CLRF xA2
6140: CLRF xA3
6142: CLRF xA4
6144: CLRF xA5
6146: CLRF xA6
6148: CLRF xA7
614A: CLRF xA8
614C: CLRF xA9
614E: CLRF xAA
6150: CLRF xAB
6152: CLRF xAC
6154: CLRF xAD
6156: CLRF xAE
6158: CLRF xAF
615A: CLRF xB0
615C: CLRF xB1
615E: CLRF xB2
6160: CLRF xB3
6162: CLRF xB4
6164: CLRF xB5
6166: CLRF xB6
6168: CLRF xB7
616A: CLRF xB8
616C: CLRF xB9
616E: CLRF xBA
6170: CLRF xBB
6172: CLRF xBC
6174: CLRF xBD
6176: CLRF xBE
6178: CLRF xBF
617A: CLRF xC0
617C: CLRF xC1
617E: CLRF xC2
6180: CLRF xC3
6182: CLRF xC4
6184: CLRF xC5
6186: CLRF xC6
6188: CLRF xC7
618A: CLRF xC8
618C: CLRF xC9
618E: CLRF xCA
6190: CLRF xCB
6192: CLRF xCC
6194: CLRF xCD
6196: CLRF xCE
6198: CLRF xCF
619A: CLRF xD0
619C: CLRF xD1
619E: CLRF xD2
61A0: CLRF xD3
61A2: CLRF xD4
61A4: CLRF xD5
61A6: CLRF xD6
61A8: CLRF xD7
61AA: CLRF xD8
61AC: CLRF xD9
61AE: CLRF xDA
61B0: CLRF xDB
61B2: CLRF xDC
61B4: CLRF xDD
61B6: CLRF xDE
61B8: CLRF xDF
61BA: CLRF xE0
61BC: CLRF xE1
61BE: CLRF xE2
61C0: CLRF xE3
61C2: CLRF xE4
61C4: CLRF xE5
61C6: CLRF xE6
61C8: CLRF xE7
61CA: CLRF xE8
61CC: CLRF xE9
61CE: CLRF xEA
61D0: CLRF xEB
61D2: CLRF xEC
61D4: CLRF xED
61D6: CLRF xEE
61D8: CLRF xEF
61DA: CLRF xF0
61DC: CLRF xF1
61DE: CLRF xF2
61E0: CLRF xF3
61E2: CLRF xF4
61E4: CLRF xF5
61E6: CLRF xF6
61E8: CLRF xF7
61EA: CLRF xF8
61EC: CLRF xF9
61EE: CLRF xFA
61F0: CLRF xFB
61F2: CLRF xFC
61F4: CLRF xFD
61F6: CLRF xFE
61F8: CLRF xFF
61FA: MOVLB 3
61FC: CLRF x00
61FE: CLRF x01
6200: CLRF x02
6202: CLRF x03
6204: CLRF x04
6206: CLRF x05
6208: CLRF x06
620A: CLRF x07
620C: CLRF x08
620E: CLRF x09
6210: CLRF x0A
6212: CLRF x0B
6214: CLRF x0C
6216: CLRF x0D
6218: CLRF x0E
621A: CLRF x0F
621C: CLRF x10
621E: CLRF x11
6220: CLRF x12
6222: CLRF x13
6224: CLRF x14
6226: CLRF x15
6228: CLRF x16
622A: CLRF x17
622C: CLRF x18
622E: CLRF x19
6230: CLRF x1A
6232: CLRF x1B
6234: CLRF x1C
6236: CLRF x1D
6238: CLRF x1E
623A: CLRF x1F
623C: CLRF x20
623E: CLRF x21
6240: CLRF x22
6242: CLRF x23
6244: CLRF x24
6246: CLRF x25
6248: CLRF x26
624A: CLRF x27
624C: MOVLW 02
624E: MOVWF x28
6250: CLRF x29
6252: CLRF x2A
6254: CLRF x2B
6256: MOVLB 2
6258: BSF x57.1
625A: BCF x57.4
625C: BCF x57.5
625E: BCF x57.6
6260: MOVLB 3
6262: CLRF x2D
6264: MOVLW 01
6266: MOVWF x66
6268: CLRF x85
626A: CLRF x86
626C: CLRF x87
626E: MOVWF x88
6270: CLRF x89
6272: CLRF x8A
6274: CLRF x8B
6276: MOVLW 15
6278: MOVWF FAF
627A: MOVLW 26
627C: MOVWF FAC
627E: MOVLW 90
6280: MOVWF FAB
6282: CLRF x8C
6284: CLRF x8D
6286: CLRF x8E
6288: CLRF x8F
628A: CLRF x90
628C: CLRF x91
628E: CLRF x92
6290: CLRF x93
6292: CLRF x94
6294: CLRF x95
6296: CLRF x96
6298: CLRF x97
629A: CLRF x98
629C: CLRF x99
629E: CLRF x9A
62A0: CLRF x9B
62A2: CLRF x9C
62A4: CLRF x9D
62A6: CLRF x9E
62A8: CLRF x9F
62AA: CLRF xA0
62AC: CLRF xA1
62AE: CLRF xA2
62B0: CLRF xA3
62B2: CLRF xA4
.................... //v1.1 - Removed in this version to provide additional ROM space.
.................... // why_did_i_reset();
.................... setup_micro();
62B4: MOVLB 0
62B6: GOTO 04EA
....................
.................... while(1)
.................... {
.................... restart_wdt();
62BA: CLRWDT
....................
.................... // v1.1 - Advanced cluster allocation and card detection
.................... auto_start_check();
62BC: GOTO 353C
.................... card_state();
62C0: GOTO 3DB6
.................... next_free_cluster_seek();
62C4: GOTO 3EFC
.................... check_for_command();
62C8: GOTO 51F6
.................... ONE_second_service();
62CC: GOTO 5BE0
.................... }
62D0: GOTO 62BA
.................... }
....................
62D4: SLEEP
....................

Configuration Fuses:
Word 1: 2200 HS NOOSCSEN
Word 2: 0E0D NOBROWNOUT WDT128 NOWDT BORV20 NOPUT
Word 3: 0100 CCP2C1
Word 4: 0081 STVREN NODEBUG NOLVP
Word 5: C00F NOPROTECT NOCPD NOCPB
Word 6: E00F NOWRT NOWRTD NOWRTB NOWRTC
Word 7: 400F NOEBTR NOEBTRB

---------------------
___________________________
This message was ported from CCS's old forum
Original Post ID: 13054
Barry Gershenfeld
Guest







Re: Help! strange problem with zero ram? or something else
PostPosted: Tue Mar 25, 2003 1:24 pm     Reply with quote

:=the compiler is still burning up memory by performing a CLRF instruction on every ram location (or so it seems)

The way variables are declared in C can affect this. Obviously int x=0; will get zeroed. Global and static might get it automatically. Since the areas are big I would look at any buffers you have created. I don't see huge blocks of CLRFs in my object code but I never asked why.

Barry
___________________________
This message was ported from CCS's old forum
Original Post ID: 13058
btokarchuk
Guest







Re: Help! strange problem with zero ram? or something else
PostPosted: Tue Mar 25, 2003 1:53 pm     Reply with quote

Thanks for the reply Barry, I did also get a reply from CCS themselves saying:

Variables declared like this:
int x = 0;

Or like this:

static int x;

Will get the CLRF in main().

So considering i had a number of variables declared static and a 512 byte buffer declared static it is no wonder I received so many in my code. It's all better now Smile
:=:=the compiler is still burning up memory by performing a CLRF instruction on every ram location (or so it seems)
:=
:=The way variables are declared in C can affect this. Obviously int x=0; will get zeroed. Global and static might get it automatically. Since the areas are big I would look at any buffers you have created. I don't see huge blocks of CLRFs in my object code but I never asked why.
:=
:=Barry
___________________________
This message was ported from CCS's old forum
Original Post ID: 13060
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
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 vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group