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 support@ccsinfo.com

MachX and #Serilize don't work

 
Post new topic   Reply to topic    CCS Forum Index -> CCS ICD / Mach X / Load-n-Go
View previous topic :: View next topic  
Author Message
nurquhar



Joined: 05 Aug 2006
Posts: 149
Location: Redditch, UK

View user's profile Send private message Visit poster's website

MachX and #Serilize don't work
PostPosted: Wed Aug 23, 2006 7:43 am     Reply with quote

I have just reported the following problem to CCS Suuport :

I am using the following #serialise in my source code for a 16F648A to put an const int32 at the top of memory, in this case 0xFF0

Code:
// Determine the location at the top of memory to locate the UID
#define PROGRAM_SIZE getenv("PROGRAM_MEMORY")
 
#define CONST_SIZE  16
#define CONST_BEGIN  (PROGRAM_SIZE - CONST_SIZE)
#define CONST_END  (PROGRAM_SIZE - 1)
 

//Retrieves serial number from serials.txt
//const uint32 ROM_UID = 1 ;
#org CONST_BEGIN,CONST_END
unsigned int32 const ROM_UID = SET_ROM_UID ;
#serialize(id=ROM_UID,file="serials.txt",log="seriallog.txt")   

This produces the following comment in the hex file that MachX will be looking for :

:10128000AE008A11831273258A1504308316AD00CF
:10129000AE018A11831273258A150000AC28630001
:0A1FE000820701340034003400349D
:02400E00023F6F
:00000001FF
;BURNTIME 00FF1,00FF4 BINARY NEXTFILE="SERIALS.TXT" LOG="SERIALLOG.TXT"
;PIC16F648A


Every thing is fine so far, however when it programs the chip it puts RETLW's at 0x8CD, bang in the middle of me code !! Also where the values should be at 0xFF1 there is no change to the default value. ie the MachX has put the value in completley the wrong place.

This is what I read back from the chip with the programmer when using with and without Auto Serial No :

2241 08C0 3003 MOVLW 0x3
2242 08C1 00AE MOVWF 0x2e
2243 08C2 118A BCF 0xa, 0x3
2244 08C3 1283 BCF 0x3, 0x5
2245 08C4 2573 CALL 0x573
2246 08C5 158A BSF 0xa, 0x3
2247 08C6 3001 MOVLW 0x1
2248 08C7 1683 BSF 0x3, 0x5
2249 08C8 00AD MOVWF 0x2d
2250 08C9 01AE CLRF 0x2e
2251 08CA 118A BCF 0xa, 0x3
2252 08CB 1283 BCF 0x3, 0x5
- 2253 08CC 340A RETLW 0xa
- 2254 08CD 3400 RETLW 0
- 2255 08CE 3400 RETLW 0
- 2256 08CF 3400 RETLW 0

2257 08D0 01AD CLRF 0x2d
2258 08D1 01AE CLRF 0x2e
2259 08D2 118A BCF 0xa, 0x3
2260 08D3 1283 BCF 0x3, 0x5
2261 08D4 2573 CALL 0x573

It should have been

2241 08C0 3003 MOVLW 0x3
2242 08C1 00AE MOVWF 0x2e
2243 08C2 118A BCF 0xa, 0x3
2244 08C3 1283 BCF 0x3, 0x5
2245 08C4 2573 CALL 0x573
2246 08C5 158A BSF 0xa, 0x3
2247 08C6 3001 MOVLW 0x1
2248 08C7 1683 BSF 0x3, 0x5
2249 08C8 00AD MOVWF 0x2d
2250 08C9 01AE CLRF 0x2e
2251 08CA 118A BCF 0xa, 0x3
2252 08CB 1283 BCF 0x3, 0x5
- 2253 08CC 2573 CALL 0x573
- 2254 08CD 158A BSF 0xa, 0x3
- 2255 08CE 28DF GOTO 0xdf
- 2256 08CF 1683 BSF 0x3, 0x5
- 2257 08D0 01AD CLRF 0x2d

2258 08D1 01AE CLRF 0x2e
2259 08D2 118A BCF 0xa, 0x3
2260 08D3 1283 BCF 0x3, 0x5
2261 08D4 2573 CALL 0x573

As when support get back with an explanation/solution I will post again.
nurquhar



Joined: 05 Aug 2006
Posts: 149
Location: Redditch, UK

View user's profile Send private message Visit poster's website

PostPosted: Thu Sep 07, 2006 4:41 am     Reply with quote

The story makes a side shoot here :- http://www.ccsinfo.com/forum/viewtopic.php?p=68985#68985
nurquhar



Joined: 05 Aug 2006
Posts: 149
Location: Redditch, UK

View user's profile Send private message Visit poster's website

PostPosted: Wed Sep 13, 2006 1:12 am     Reply with quote

Hooray ! Very Happy

CCS Have provided a fix.

They email me a new ccsicdu.dll file.

I guess this will be generaly available in a new release soon.
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> CCS ICD / Mach X / Load-n-Go 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