Jump to content

Recommended Posts

Hello

 

After spending many happy hours with assembly language in MPLAB I bit the bullet and started to learn C++.

I have the full license for SourceBoost C++ and using the MPLAB IDE with an ICD2 programmer.

I've come unstuck as I need to program 16F54 devices. The MPLAB allows the device to be selected, but not SourceBoost.

My code runs happily on the sourceboost simulator if I change the device type to something like 16F84, but I can't get it onto my 16F54 devices via MPLAB.

Is it possible to add the 16F54 to C++ or perhaps give instructions as to how to add new devices?

 

Thanks

Mike

Link to post
Share on other sites

MikeK,

 

Is it possible to add the 16F54 to C++ or perhaps give instructions as to how to add new devices?
Sadly the PIC16F54 is really a PIC12, ie it has a stack that is only 2 deep and 12bit instructions.

This means it can't be readily supported by the BoostC compiler as it only supports PICs with 14bit (PIC16) and 16bit (PIC18) instructions.

 

Regards

Dave

Link to post
Share on other sites

Thanks for the reply Dave.

The devices are on dinky little demo boards from Sure Electronics: http://www.sureelectronics.net/goods.php?id=665

These come free with some of their lcd modules, or can be bought separately. I bought some just to mess around with, and for some projects I have in mind.

The notes with the boards: http://www.sureelectronics.net/pdfs/DE-LD007_Ver1.0_EN.pdf

show the circuit etc. but the last few pages are a C program which they have used to program the on board pic.

I spent some time as a bit of a learning exercise translating this code to C++ and have got it to run ok with the lcd simulator in sourceboost, using a16F84 as the target, and it mimics the board with a display connected.

If anybody has time, could they look at this code and tell me what version of C it is? and how they get it on the device?

 

My other question is given that I can't program a 16F54 via sourceboostC++ directly, could I program for another device, generate the hex file and then program the device with the hex file in MPLAB? If so, could anyone suggest the bet target device to use?

 

Thanks

Mike

Link to post
Share on other sites

MikeK,

My other question is given that I can't program a 16F54 via sourceboostC++ directly, could I program for another device, generate the hex file and then program the device with the hex file in MPLAB? If so, could anyone suggest the bet target device to use?
That won't work as the devices will have different instruction opcodes, in simple terms "they speak slightly different languages".

 

Regards

Dave

Link to post
Share on other sites
  • 9 months later...
MikeK,
My other question is given that I can't program a 16F54 via sourceboostC++ directly, could I program for another device, generate the hex file and then program the device with the hex file in MPLAB? If so, could anyone suggest the bet target device to use?
That won't work as the devices will have different instruction opcodes, in simple terms "they speak slightly different languages".

 

Regards

Dave

 

I've checked the migration document for compatibility and apart from some code protect config bits the 'f54 is fully code compatible with the 'c54 which was supported by your retired C2C compilers. Unfortunately those of us who joined the SourceBoost community after you stopped selling it and who installed the IDE more than 14 days ago can only use the C2C tool suites for the 'F84. :-(

 

I know that you have moved on, but as it seems unlikely that, with the PIC range continuously moving upwards and onwards, you will ever be able to justify cutting BoostC down to suit a 12 bit core; Perhaps you might see your way clear to making C2C-plus licences available to those of us with a paid up BoostC licence, and C2C++ licences to BoostC++ licencees, perhaps for a nominal fee to ensure you are adequately compensated for the work involved in issuing them.

 

It could be quite clearly understood that this is a legacy product and that NO SUPPORT from the SourceBoost team is to be included. I believe this forum has sufficient experienced and welcoming long term members and deep enough archives that we can manage without official support.

 

I don't want to have to trawl through your competitor's products when I want to do something quick and cheap with a 12 bitter . . . .

 

Ian M

Edited by IanM
Link to post
Share on other sites
...I know that you have moved on, but as it seems unlikely that, with the PIC range continuously moving upwards and onwards, you will ever be able to justify cutting BoostC down to suit a 12 bit core; Perhaps you might see your way clear to making C2C-plus licences available to those of us with a paid up BoostC licence, and C2C++ licences to BoostC++ licencees, perhaps for a nominal fee to ensure you are adequately compensated for the work involved in issuing them...

 

Good point. We'll take look at this. Probably a separate download package will be the most convenient way for both sides.

 

Regards,

Pavel

Link to post
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...